diff --git a/index.html b/index.html index b6e28fb..2941f72 100644 --- a/index.html +++ b/index.html @@ -13,63 +13,170 @@ -
-
-
-

스크롤만으로 장면을 여는 CSS 항해

-

- JavaScript 없이 sticky layout, scroll snap, view timeline, mask를 조합해 밝고 읽기 쉬운 - 인터랙티브 랜딩 페이지를 실험합니다. -

+
+
+
+
+

CSS scroll-driven narrative

+

CSS로 이어지는 네 장면

+

+ 스크롤 위치를 장면의 시간축으로 삼아 신호부터 읽기 fallback까지 연결합니다. 모든 흐름은 + HTML과 CSS만으로 작동합니다. +

+
+
장면
4
+
런타임 JS
0
+
읽기 모드
2
+
+ 첫 장면 보기 +
+
-
-
- 01 / 04 -

신호 수집

-

view timeline이 지원되는 브라우저에서는 카드가 viewport 진입률에 맞춰 또렷해집니다.

+
+
+

01 / 04

+

Signal

+

신호를 포착하다

+

+ 첫 장면이 viewport에 들어오면 view timeline이 원의 간격과 신호점의 농도를 조절합니다. + 지원하지 않는 환경에서는 완성된 정적 지도가 그대로 보입니다. +

+
    +
  • 텍스트와 시각 효과를 독립적으로 유지
  • +
  • 장면 진입률은 CSS timeline으로만 계산
  • +
+ 궤도 이동 +
+
-
- 02 / 04 -

궤도 이동

-

sticky 배치와 scroll snap이 JavaScript 없는 화면 전환 리듬을 만듭니다.

+
+
+

02 / 04

+

Drift

+

궤도를 따라 이동하다

+

+ sticky 장면 안에서 항해점이 경로를 따라 이동합니다. 페이지 스크롤은 브라우저가 그대로 + 소유하며, 별도의 scroll hijacking은 없습니다. +

+
    +
  • scroll snap은 가까운 장면 정렬만 보조
  • +
  • 키보드와 anchor 이동 순서를 그대로 보존
  • +
+ 도착 지점 +
+
-
- 03 / 04 -

도착

-

중앙 maintainer bot이 다음 장면, 접근성, fallback 개선을 작은 PR로 제안합니다.

+
+
+

03 / 04

+

Arrival

+

하나의 지점에 도착하다

+

+ 여러 궤도가 한 좌표로 수렴하면서 앞선 장면의 흐름을 정리합니다. 진행 표시줄은 전체 + 문서에서 현재 위치를 계속 보여 줍니다. +

+
    +
  • 전체 진행률과 장면 번호를 함께 제공
  • +
  • 색상 외에도 선, 크기, 문장으로 상태 전달
  • +
+ 읽기 유지 +
+
-
- 04 / 04 -

읽기 유지

-

- scroll-driven animation이 꺼져도 장면 순서와 문장이 그대로 남아 여정을 끝까지 읽을 수 - 있습니다. -

-
    -
  • 모션은 기능 향상으로만 적용
  • -
  • 정적 환경에서도 모든 장면 유지
  • -
+
+
+

04 / 04

+

Fallback

+

효과가 없어도 읽히다

+

+ 상단의 정적 읽기를 켜면 장면 애니메이션과 snap이 멈춥니다. 브라우저가 scroll timeline을 + 지원하지 않아도 제목, 순서, 설명은 사라지지 않습니다. +

+
    +
  • 사용자가 선택하는 정적 읽기 모드
  • +
  • reduced motion 환경의 자동 모션 축소
  • +
  • 런타임 JavaScript 없이 동일한 문서 유지
  • +
+ 처음으로 +
+
diff --git a/styles.css b/styles.css index 9edb1c3..448f7e1 100644 --- a/styles.css +++ b/styles.css @@ -1,6 +1,6 @@ @import './design-system/base.css'; -@layer reset, base, layout, scenes; +@layer reset, base, header, chapters, visuals, motion, responsive; @layer reset { * { @@ -13,14 +13,22 @@ scroll-padding-top: var(--header-offset); } - body { + body, + figure, + h1, + h2, + p, + dl, + dd { margin: 0; } } @layer base { :root { - --header-offset: 76px; + --header-offset: 72px; + --chapter-inline: clamp(24px, 5vw, 72px); + --chapter-block: 112px; color: var(--color-text); background: var(--color-bg); @@ -31,9 +39,7 @@ body { min-width: 320px; min-height: 100vh; - background: - radial-gradient(circle at 50% 18%, rgb(0 127 140 / 6%), transparent 34%), - linear-gradient(180deg, #ffffff, var(--color-bg) 48%, var(--color-bg-2)); + background: var(--color-bg); } a { @@ -41,302 +47,765 @@ text-decoration: none; } - a:focus-visible { - outline: 3px solid rgb(0 127 140 / 42%); - outline-offset: 5px; - border-radius: 6px; + a:focus-visible, + input:focus-visible { + outline: 3px solid color-mix(in srgb, var(--color-cyan) 38%, transparent); + outline-offset: 4px; } } -@layer layout { +@layer header { .site-header { position: fixed; inset: 0 0 auto; z-index: 20; - display: flex; - justify-content: space-between; - gap: 24px; - padding: 18px clamp(20px, 5vw, 56px); - color: var(--color-text); - background: rgb(255 255 255 / 86%); + min-height: var(--header-offset); + display: grid; + grid-template-columns: minmax(220px, auto) minmax(0, 1fr) auto; + align-items: center; + gap: 28px; + padding: 10px var(--chapter-inline); border-bottom: 1px solid var(--color-border); - backdrop-filter: blur(16px); + background: color-mix(in srgb, var(--color-surface) 94%, white); + backdrop-filter: blur(14px); } - .site-header > a { - font-weight: 900; + .brand { + min-width: 0; + display: flex; + align-items: center; + gap: 10px; } - nav { + .brand-mark { + width: 24px; + height: 24px; + flex: 0 0 auto; + border: 5px solid var(--color-cyan); + border-right-color: var(--color-primary); + border-radius: 50%; + } + + .brand strong, + .brand small { + display: block; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; + } + + .brand strong { + font-size: 14px; + line-height: 1.2; + } + + .brand small { + margin-top: 2px; + color: var(--color-muted); + font-size: 10px; + } + + .scene-nav { display: flex; - flex-wrap: wrap; - gap: 16px; + justify-content: center; + gap: 6px; + min-width: 0; + } + + .scene-nav a { + min-height: 34px; + display: inline-flex; + align-items: center; + gap: 5px; + padding: 0 10px; + border-radius: 6px; color: var(--color-muted); - font-size: 14px; + font-size: 12px; + white-space: nowrap; } + .scene-nav a:hover, + body:has(#signal:target) .scene-nav a[href='#signal'], + body:has(#drift:target) .scene-nav a[href='#drift'], + body:has(#arrival:target) .scene-nav a[href='#arrival'], + body:has(#fallback:target) .scene-nav a[href='#fallback'] { + color: var(--color-cyan); + background: color-mix(in srgb, var(--color-cyan) 7%, transparent); + } + + .scene-nav span { + color: var(--color-cyan); + font-size: 10px; + font-weight: 900; + } + + .reading-toggle { + min-height: 38px; + display: inline-flex; + align-items: center; + gap: 8px; + padding: 0 11px; + border: 1px solid var(--color-border); + border-radius: var(--radius-frame); + color: var(--color-muted); + background: var(--color-surface); + cursor: pointer; + font-size: 12px; + white-space: nowrap; + } + + .reading-toggle input { + width: 15px; + height: 15px; + margin: 0; + accent-color: var(--color-cyan); + } + + .site-header:has(#reading-mode:checked) .reading-toggle { + border-color: color-mix(in srgb, var(--color-cyan) 40%, transparent); + color: var(--color-cyan); + background: color-mix(in srgb, var(--color-cyan) 7%, white); + } + + .story-progress { + position: absolute; + inset: auto 0 0; + height: 3px; + overflow: hidden; + background: color-mix(in srgb, var(--color-text) 7%, transparent); + } + + .story-progress span { + display: block; + width: 100%; + height: 100%; + transform: scaleX(0); + transform-origin: left; + background: var(--color-cyan); + animation: story-progress linear both; + animation-timeline: scroll(root block); + } +} + +@layer chapters { .chapter { min-height: 100vh; min-block-size: 100svh; - scroll-snap-align: start; - scroll-snap-stop: always; position: relative; display: grid; - place-items: center; - padding: var(--space-page); + align-items: center; + scroll-snap-align: start; + scroll-snap-stop: always; overflow: clip; + padding: var(--chapter-block) var(--chapter-inline) 64px; + border-bottom: 1px solid var(--color-border); } - .hero { - grid-template-columns: minmax(0, 0.85fr) minmax(260px, 0.6fr); - gap: clamp(28px, 6vw, 80px); + .chapter-layout { + width: min(1320px, 100%); + margin-inline: auto; + display: grid; + grid-template-columns: minmax(280px, 0.72fr) minmax(420px, 1.28fr); + gap: clamp(48px, 7vw, 112px); + align-items: center; } - .copy { - max-width: 860px; + .chapter-copy { + max-width: 560px; } - h1, - h2, - p { - margin: 0; + .eyebrow, + .scene-index { + color: var(--color-cyan); + font-size: 11px; + font-weight: 900; + line-height: 1.4; + text-transform: uppercase; } - h1 { - font-size: clamp(42px, 7vw, 84px); - line-height: 1.02; + .scene-index { + width: max-content; + margin-bottom: 16px; + padding-bottom: 6px; + border-bottom: 2px solid currentColor; + } + + h1, + h2 { + margin-top: 10px; letter-spacing: 0; + line-height: 1.12; word-break: keep-all; overflow-wrap: break-word; } - .copy p, - .scene-card p { - margin-top: 24px; + h1 { + font-size: 48px; + } + + h2 { + font-size: 44px; + } + + .chapter-lead { + margin-top: 20px; color: var(--color-muted); - font-size: 18px; - line-height: 1.75; + font-size: 17px; + line-height: 1.72; word-break: keep-all; overflow-wrap: break-word; } -} -@layer scenes { - .sun, - .scene-card { - animation: var(--scroll-animation) var(--motion-scroll); - animation-timeline: view(); - animation-range: var(--scroll-animation-range); + .story-facts { + display: grid; + grid-template-columns: repeat(3, minmax(0, 1fr)); + margin-top: 30px; + border-block: 1px solid var(--color-border); } - .sun { - --scroll-animation: float-sun; - --scroll-animation-range: entry 0% exit 100%; + .story-facts div { + padding: 13px 10px; + } - width: min(42vw, 420px); - aspect-ratio: 1; - border-radius: 999px; - background: - radial-gradient(circle, #ffe7a3 0 22%, #f8a84d 23% 44%, transparent 45%), - repeating-linear-gradient(0deg, transparent 0 18px, rgb(255 255 255 / 52%) 19px 20px); - filter: drop-shadow(0 18px 52px rgb(183 121 0 / 22%)); - } - - .scene { - --scene-glow-alpha: 10%; - --scene-sweep-alpha: 9%; - --scene-sweep-stop: 48%; - --scene-bg: var(--color-bg); - - background: - radial-gradient( - circle at var(--scene-glow-position), - rgb(var(--scene-accent) / var(--scene-glow-alpha)), - transparent 34% - ), - linear-gradient( - 135deg, - rgb(var(--scene-accent) / var(--scene-sweep-alpha)), - transparent var(--scene-sweep-stop) - ), - var(--scene-bg); + .story-facts div + div { + border-left: 1px solid var(--color-border); } - .scene-a { - --scene-accent: 0 127 140; - --scene-glow-position: 28% 24%; - --scene-progress: 25%; + .story-facts dt { + color: var(--color-muted); + font-size: 10px; + } + + .story-facts dd { + margin-top: 5px; + font-size: 21px; + font-weight: 900; + font-variant-numeric: tabular-nums; } - .scene::before { + .scene-notes { + display: grid; + gap: 9px; + margin: 24px 0 0; + padding: 0; + color: var(--color-text); + font-size: 13px; + line-height: 1.5; + list-style: none; + } + + .scene-notes li { + display: grid; + grid-template-columns: 8px minmax(0, 1fr); + gap: 10px; + } + + .scene-notes li::before { content: ''; - position: absolute; - inset: 12%; - border: 1px solid var(--color-border); + width: 6px; + height: 6px; + margin-top: 0.55em; border-radius: 50%; - transform: rotate(18deg); + background: var(--scene-color, var(--color-cyan)); + } + + .chapter-next { + width: max-content; + min-height: 40px; + display: inline-flex; + align-items: center; + gap: 10px; + margin-top: 30px; + border-bottom: 1px solid currentColor; + color: var(--scene-color, var(--color-cyan)); + font-size: 13px; + font-weight: 800; + } + + .chapter-next span { + font-size: 16px; + } + + .scene-a { + --scene-color: var(--color-cyan); + background: #f8fcfd; } .scene-b { - --scene-accent: 110 87 216; - --scene-glow-position: 72% 22%; - --scene-sweep-stop: 52%; - --scene-bg: #fbfaff; - --scene-progress: 50%; + --scene-color: var(--color-violet); + background: #fbfaff; } .scene-c { - --scene-accent: 183 121 0; - --scene-glow-position: 68% 18%; - --scene-glow-alpha: 12%; - --scene-sweep-alpha: 8%; - --scene-sweep-stop: 50%; - --scene-bg: #fffdf7; - --scene-progress: 75%; + --scene-color: var(--color-primary); + background: #fffdf7; } .scene-d { - --scene-accent: 47 132 91; - --scene-glow-position: 30% 20%; - --scene-glow-alpha: 11%; - --scene-sweep-alpha: 8%; - --scene-sweep-stop: 54%; - --scene-bg: #f8fff9; - --scene-progress: 100%; + --scene-color: #2f845b; + background: #f8fff9; } - .scene-card { - --scroll-animation: reveal-card; - --scroll-animation-range: entry 8% cover 42%; + .scene .eyebrow, + .scene .scene-index { + color: var(--scene-color); + } +} +@layer visuals { + .chapter-visual { + min-width: 0; + min-height: 540px; position: relative; overflow: hidden; - width: min(720px, 100%); - border: 1px solid var(--color-border); - border-radius: var(--radius-frame); - padding: clamp(28px, 5vw, 52px); - background: var(--color-surface); - box-shadow: var(--shadow-panel); - backdrop-filter: blur(16px); + border-left: 1px solid var(--color-border); } - .scene-card::before, - .scene-card::after { - content: ''; + .hero-visual { + background: #f2f9ff; + } + + .hero-sun, + .hero-orbit, + .hero-node, + .hero-horizon, + .signal-core, + .signal-ring, + .signal-point, + .drift-track, + .drift-marker, + .arrival-axis, + .arrival-ring, + .arrival-core { position: absolute; - top: 0; - left: 0; - height: 6px; - pointer-events: none; + display: block; + } + + .hero-sun { + top: 19%; + left: 50%; + width: 116px; + aspect-ratio: 1; + border: 18px solid #ffe7a3; + border-radius: 50%; + background: #f8a84d; + transform: translateX(-50%); + } + + .hero-orbit { + top: 48%; + left: 50%; + border: 1px solid color-mix(in srgb, var(--color-cyan) 36%, transparent); + border-radius: 50%; + transform: translate(-50%, -50%) rotate(-8deg); } - .scene-card::before { - right: 0; - background: rgb(var(--scene-accent) / 13%); + .orbit-one { + width: 44%; + aspect-ratio: 1.8; } - .scene-card::after { - width: var(--scene-progress); - background: linear-gradient( - 90deg, - rgb(var(--scene-accent) / 92%), - rgb(var(--scene-accent) / 54%) - ); - box-shadow: 0 10px 28px rgb(var(--scene-accent) / 18%); + .orbit-two { + width: 67%; + aspect-ratio: 2.15; } - .scene-card span { - display: inline-grid; + .orbit-three { + width: 88%; + aspect-ratio: 2.5; + } + + .hero-node { + width: 12px; + height: 12px; + border: 3px solid white; + border-radius: 50%; + background: var(--color-cyan); + box-shadow: 0 0 0 1px var(--color-cyan); + } + + .node-one { top: 41%; left: 31%; } + .node-two { top: 57%; left: 68%; background: var(--color-violet); box-shadow: 0 0 0 1px var(--color-violet); } + .node-three { top: 37%; left: 76%; background: var(--color-primary); box-shadow: 0 0 0 1px var(--color-primary); } + + .hero-horizon { + inset: auto 8% 18%; + height: 1px; + background: var(--color-border); + } + + .signal-visual { + background: #effafb; + } + + .signal-core, + .signal-ring { + top: 50%; + left: 50%; + border-radius: 50%; + transform: translate(-50%, -50%); + } + + .signal-core { + width: 34px; + aspect-ratio: 1; + border: 9px solid white; + background: var(--color-cyan); + box-shadow: 0 0 0 1px color-mix(in srgb, var(--color-cyan) 32%, transparent); + } + + .signal-ring { + border: 1px solid color-mix(in srgb, var(--color-cyan) 44%, transparent); + } + + .ring-one { width: 26%; aspect-ratio: 1; } + .ring-two { width: 52%; aspect-ratio: 1; } + .ring-three { width: 80%; aspect-ratio: 1; } + + .signal-point { + width: 9px; + height: 9px; + border-radius: 50%; + background: var(--color-cyan); + } + + .point-one { top: 28%; left: 31%; } + .point-two { top: 66%; left: 69%; } + .point-three { top: 18%; left: 71%; } + + .drift-visual { + background: #f6f3ff; + } + + .drift-track { + top: 50%; + left: 50%; + border: 1px dashed color-mix(in srgb, var(--color-violet) 50%, transparent); + border-radius: 50%; + transform: translate(-50%, -50%) rotate(-12deg); + } + + .track-one { width: 78%; aspect-ratio: 2; } + .track-two { width: 48%; aspect-ratio: 1.55; } + + .drift-marker { + top: 48%; + left: 16%; + width: 24px; + aspect-ratio: 1; + border: 7px solid white; + border-radius: 50%; + background: var(--color-violet); + box-shadow: 0 0 0 1px var(--color-violet); + } + + .drift-coordinate { + position: absolute; + display: grid; place-items: center; - min-width: 46px; - min-height: 34px; - padding: 0 10px; - color: rgb(var(--scene-accent)); - font-size: 14px; + width: 36px; + height: 26px; + border: 1px solid color-mix(in srgb, var(--color-violet) 24%, transparent); + border-radius: 5px; + color: var(--color-violet); + background: white; + font-size: 10px; font-weight: 900; - border: 1px solid rgb(var(--scene-accent) / 22%); - border-radius: var(--radius-frame); - background: rgb(var(--scene-accent) / 10%); } - .scene-card h2 { - margin-top: 12px; - font-size: clamp(40px, 7vw, 84px); - line-height: 0.95; + .coordinate-one { top: 24%; left: 28%; } + .coordinate-two { top: 67%; left: 54%; } + .coordinate-three { top: 31%; left: 77%; } + + .arrival-visual { + background: #fff9eb; } - .scene-notes { + .arrival-axis { + top: 50%; + left: 50%; + background: color-mix(in srgb, var(--color-primary) 24%, transparent); + } + + .axis-horizontal { width: 78%; height: 1px; transform: translate(-50%, -50%); } + .axis-vertical { width: 1px; height: 78%; transform: translate(-50%, -50%); } + + .arrival-ring { + top: 50%; + left: 50%; + border: 1px solid color-mix(in srgb, var(--color-primary) 46%, transparent); + border-radius: 50%; + transform: translate(-50%, -50%); + } + + .arrival-one { width: 18%; aspect-ratio: 1; } + .arrival-two { width: 42%; aspect-ratio: 1; } + .arrival-three { width: 70%; aspect-ratio: 1; } + + .arrival-core { + top: 50%; + left: 50%; + width: 22px; + aspect-ratio: 1; + border-radius: 2px; + background: var(--color-primary); + transform: translate(-50%, -50%) rotate(45deg); + } + + .arrival-label { + position: absolute; + right: 12%; + bottom: 14%; + color: var(--color-primary); + font-size: 10px; + font-weight: 900; + } + + .fallback-visual { display: grid; - gap: 10px; - margin: 28px 0 0; + place-items: center; + background: #f0fbf3; + } + + .document-sheet { + width: min(62%, 380px); + min-height: 390px; + padding: 44px 38px; + border: 1px solid color-mix(in srgb, #2f845b 28%, transparent); + border-radius: 4px; + background: white; + box-shadow: 16px 16px 0 color-mix(in srgb, #2f845b 9%, transparent); + } + + .document-title, + .document-line { + display: block; + height: 9px; + background: color-mix(in srgb, #2f845b 22%, transparent); + } + + .document-title { + width: 48%; + height: 16px; + margin-bottom: 38px; + background: #2f845b; + } + + .document-line + .document-line { margin-top: 13px; } + .line-long { width: 100%; } + .line-mid { width: 78%; } + .line-short { width: 54%; } + + .document-scenes { + display: grid; + grid-template-columns: repeat(4, 1fr); + gap: 8px; + margin: 54px 0 0; padding: 0; - color: var(--color-text); - font-size: 16px; - line-height: 1.55; list-style: none; } - .scene-notes li { + .document-scenes span { + min-height: 54px; display: grid; - grid-template-columns: 10px minmax(0, 1fr); - gap: 12px; - align-items: start; + place-items: center; + border: 1px solid color-mix(in srgb, #2f845b 24%, transparent); + color: #2f845b; + font-size: 11px; + font-weight: 900; } +} - .scene-notes li::before { - content: ''; - width: 8px; - height: 8px; - margin-top: 0.65em; - border-radius: 50%; - background: rgb(var(--scene-accent)); - box-shadow: 0 0 0 4px rgb(var(--scene-accent) / 12%); +@layer motion { + .chapter-copy, + .chapter-visual { + animation: reveal-chapter var(--motion-scroll); + animation-timeline: view(); + animation-range: entry 8% cover 36%; } -} -@keyframes float-sun { - from { - transform: translateY(20vh) scale(0.86); + .hero-sun { + animation: sun-drift linear both; + animation-timeline: scroll(root block); } - to { - transform: translateY(-18vh) scale(1.08); + + .signal-ring { + animation: signal-expand var(--motion-scroll); + animation-timeline: view(); + animation-range: entry 0% cover 45%; } -} -@keyframes reveal-card { - from { - opacity: 0.32; - transform: translateY(80px) scale(0.94); + .drift-marker { + animation: marker-drift var(--motion-scroll); + animation-timeline: view(); + animation-range: entry 0% cover 70%; } - to { - opacity: 1; - transform: translateY(0) scale(1); + + .arrival-ring { + animation: arrival-focus var(--motion-scroll); + animation-timeline: view(); + animation-range: entry 0% cover 48%; } -} -@supports not (animation-timeline: view()) { - .sun, - .scene-card { - animation: none; + @keyframes story-progress { + to { transform: scaleX(1); } } -} -@media (max-width: 820px) { - :root { - --header-offset: 126px; + @keyframes reveal-chapter { + from { opacity: 0.42; transform: translateY(34px); } + to { opacity: 1; transform: translateY(0); } } - .site-header { - align-items: flex-start; - flex-direction: column; + @keyframes sun-drift { + from { transform: translate(-50%, 28vh); } + to { transform: translate(-50%, -12vh); } + } + + @keyframes signal-expand { + from { scale: 0.68; opacity: 0.18; } + to { scale: 1; opacity: 1; } } - .hero { - grid-template-columns: 1fr; - align-content: center; + @keyframes marker-drift { + from { translate: 0 72px; } + to { translate: 430px -90px; } } - .sun { - width: min(72vw, 360px); + @keyframes arrival-focus { + from { scale: 1.2; opacity: 0.24; } + to { scale: 1; opacity: 1; } + } + + @supports not (animation-timeline: view()) { + .chapter-copy, + .chapter-visual, + .signal-ring, + .drift-marker, + .arrival-ring { + animation: none; + } + } + + @supports not (animation-timeline: scroll()) { + .story-progress { + display: none; + } + + .hero-sun { + animation: none; + } + } + + html:has(#reading-mode:checked) { + scroll-behavior: auto; + scroll-snap-type: none; + } + + body:has(#reading-mode:checked) .chapter-copy, + body:has(#reading-mode:checked) .chapter-visual, + body:has(#reading-mode:checked) .hero-sun, + body:has(#reading-mode:checked) .signal-ring, + body:has(#reading-mode:checked) .drift-marker, + body:has(#reading-mode:checked) .arrival-ring { + animation: none; + opacity: 1; + scale: 1; + translate: 0; + } +} + +@layer responsive { + @media (max-width: 920px) { + :root { + --header-offset: 136px; + --chapter-block: 156px; + } + + .site-header { + grid-template-columns: minmax(0, 1fr) auto; + gap: 8px 16px; + padding-block: 10px 8px; + } + + .scene-nav { + grid-column: 1 / -1; + justify-content: flex-start; + overflow-x: auto; + padding-bottom: 2px; + } + + .chapter-layout { + grid-template-columns: 1fr; + gap: 48px; + } + + .chapter-copy { + max-width: 680px; + } + + .chapter-visual { + width: calc(100% + (var(--chapter-inline) * 2)); + min-height: 480px; + margin-inline: calc(var(--chapter-inline) * -1); + border-block: 1px solid var(--color-border); + border-left: 0; + } + + .chapter { + min-height: auto; + } + } + + @media (max-width: 560px) { + :root { + --chapter-inline: 20px; + } + + .brand small { + display: none; + } + + .scene-nav a { + padding-inline: 7px; + } + + .reading-toggle { + padding-inline: 8px; + } + + h1 { + font-size: 36px; + } + + h2 { + font-size: 34px; + } + + .chapter-lead { + font-size: 16px; + } + + .story-facts div { + padding-inline: 7px; + } + + .chapter-visual { + min-height: 390px; + } + + .document-sheet { + width: min(78%, 320px); + min-height: 300px; + padding: 34px 26px; + } + + .document-scenes { + margin-top: 40px; + } + + @keyframes marker-drift { + from { translate: 0 54px; } + to { translate: 230px -56px; } + } } }