From 914387acb62b79c28635a40ef9f02e3e0941dbcb Mon Sep 17 00:00:00 2001 From: wuyang6 Date: Fri, 14 Aug 2026 12:01:46 +0800 Subject: [PATCH] fix: keep article figures within viewport --- src/styles/global.css | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/styles/global.css b/src/styles/global.css index 61cf652..bd7f50f 100644 --- a/src/styles/global.css +++ b/src/styles/global.css @@ -160,6 +160,16 @@ button, input { font: inherit; } .prose th { color: var(--rust); font-size: 10px; letter-spacing: .08em; text-transform: uppercase; } .prose img, .prose svg { width: min(1100px, calc(100vw - 48px)); max-width: none; margin: 2.6em 0 2.6em 50%; transform: translateX(-50%); } +@media (max-width: 1180px) { + .article-grid { grid-template-columns: 1fr; } + .article-outline { position: static; } + .article-outline ol { display: grid; grid-template-columns: repeat(2, 1fr); } +} + +@media (min-width: 1181px) and (max-width: 1439px) { + .prose img, .prose svg { width: 100%; max-width: 100%; margin-left: 0; transform: none; } +} + @media (max-width: 980px) { .hero { grid-template-columns: 1fr; min-height: auto; } .hero-copy { padding-bottom: 0; }