/* Méridien : styles du site (mode cinéma + récit vertical) */
@property --hud {
  syntax: '<color>';
  inherits: true;
  initial-value: #5ad1ff;
}

:root {
  --ink: #f4f4f2;
  --void: #050505;
  --void-2: #0d0d0d;
  --line: #3a3a3a;
  --mute: #9a9a95;
  --cyan: #5ad1ff;
  --gold: #f0c36a;
  --red: #e53935;
  --serif: 'Fraunces', Georgia, 'Times New Roman', serif;
  --sans: 'Space Grotesk', -apple-system, 'Segoe UI', sans-serif;
  --mono: 'Space Mono', ui-monospace, Consolas, monospace;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body {
  background: var(--void);
  color: var(--ink);
  font-family: var(--sans);
  width: 100%;
  overflow-x: hidden;
}
::selection { background: var(--ink); color: var(--void); }
a { color: inherit; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
[hidden] { display: none !important; }

body.mode-cinema { height: 100svh; overflow: hidden; }
body.mode-recit .cine { display: none !important; }

/* Avance rapide (saut d'étape) : aucune transition */
body.instant *, body.instant *::before, body.instant *::after { transition: none !important; animation: none !important; }

/* ---------------------------------------------------------------- Scène */
#stars, #stage, #fx { position: fixed; inset: 0; width: 100%; height: 100%; display: block; }
#stars { z-index: 0; }
#stage { z-index: 1; }
#fx { z-index: 0; pointer-events: none; } /* sous les globes : les fils d'or passent derrière */

.grain {
  position: fixed; inset: 0; pointer-events: none; z-index: 20;
  opacity: 0.035; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='100' height='100'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

#hud { position: fixed; inset: 0; z-index: 3; pointer-events: none; }
.pane { position: absolute; overflow: hidden; --hud: var(--cyan); transition: --hud 2.4s ease; }
.pane.lit { --hud: var(--gold); }
#pane-u { inset: 0; }
body[data-mode="split"] #pane-u { display: none; }
body[data-mode="uni"] #pane-a, body[data-mode="uni"] #pane-b { display: none; }

.divider {
  position: absolute; left: 50%; top: 10%; bottom: 10%; width: 1px;
  background: linear-gradient(transparent, rgba(244, 244, 242, 0.2), transparent);
  opacity: 0; transition: opacity 1s ease;
}
.divider.on { opacity: 1; }
body.portrait .divider { left: 8%; right: 8%; top: 50%; bottom: auto; width: auto; height: 1px; background: linear-gradient(90deg, transparent, rgba(244, 244, 242, 0.2), transparent); }

/* Grand nom de lieu, en haut du volet */
.place {
  position: absolute; z-index: 6; top: 6%; left: var(--gx, 50%);
  transform: translateX(-50%) translateY(-10px);
  font-family: var(--serif); font-style: italic; font-weight: 500;
  font-size: clamp(2.2rem, 6vw, 4.4rem);
  letter-spacing: -0.01em; white-space: nowrap;
  opacity: 0; transition: opacity 1s ease, transform 1s ease;
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.6);
}
.place.on { opacity: 1; transform: translateX(-50%) translateY(0); }
body.portrait .place { font-size: clamp(1.6rem, 7vw, 2.6rem); top: 4%; }

/* Lignes reliant le point du globe à la fiche */
#links { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; z-index: 6; }
#links path { fill: none; stroke: var(--cyan); stroke-width: 1; stroke-dasharray: 1; stroke-dashoffset: 1; transition: stroke-dashoffset 0.7s ease; }
#links path.on { stroke-dashoffset: 0; }
#links circle { fill: var(--cyan); opacity: 0; transition: opacity 0.4s ease; }
#links circle.on { opacity: 1; }
#links .lit { stroke: var(--gold); }
#links circle.lit { fill: var(--gold); }

/* ---------------------------------------------------------------- Fiches */
.card {
  position: absolute; z-index: 7;
  top: 20%; right: 5%;
  width: min(360px, 84%);
  background: rgba(6, 14, 18, 0.84);
  border: 1px solid color-mix(in srgb, var(--hud) 55%, transparent);
  clip-path: polygon(0 0, calc(100% - 14px) 0, 100% 14px, 100% 100%, 0 100%);
  padding: 0.9rem 1rem 1.1rem;
  opacity: 0; transform: scale(0.96);
  transition: opacity 0.5s ease, transform 0.5s ease;
  backdrop-filter: blur(3px);
}
.card.on { opacity: 1; transform: scale(1); }

.card.dossier { display: flex; align-items: flex-start; gap: 0.8rem; font-family: var(--mono); }
.dossier-photo {
  width: 38%; flex-shrink: 0; aspect-ratio: 4 / 4.6; overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--hud) 40%, transparent);
  opacity: 0; transform: scale(0.9);
  transition: opacity 0.5s ease, transform 0.5s ease;
  background: #0a1418;
}
.dossier-photo.on { opacity: 1; transform: scale(1); }
.dossier-photo img, .dossier-photo svg { width: 100%; height: 100%; object-fit: cover; display: block; }
.dossier-fields {
  flex: 1; min-width: 0;
  font-size: 0.72rem; line-height: 1.75; letter-spacing: 0.01em;
  color: #e8f8ff; white-space: pre-line;
}

.card.journal { width: min(390px, 82%); }
.card .ph {
  position: relative; aspect-ratio: 4 / 3; overflow: hidden;
  margin-bottom: 0.9rem; background: #0a1418;
  border: 1px solid color-mix(in srgb, var(--hud) 35%, transparent);
}
.card h3 {
  font-family: var(--serif); font-style: italic; font-weight: 400;
  font-size: 1.45rem; line-height: 1.12; letter-spacing: -0.005em;
}
.card .meta { margin-top: 0.5rem; font-family: var(--mono); font-size: 0.72rem; line-height: 1.6; color: var(--hud); }
.card .meta span { display: block; }
.card .meta em { font-style: normal; opacity: 0.7; margin-left: 0.4rem; }
.card p { margin-top: 0.6rem; font-size: 0.98rem; line-height: 1.5; color: #dfe7ea; }
.card blockquote {
  margin-top: 1rem; padding-top: 0.9rem;
  border-top: 1px solid color-mix(in srgb, var(--hud) 30%, transparent);
  font-family: var(--serif); font-style: italic; font-weight: 300;
  font-size: 1.15rem; line-height: 1.4;
}
.card blockquote cite { display: block; margin-top: 0.5rem; font-family: var(--mono); font-style: normal; font-size: 0.72rem; color: var(--hud); }
.card.photo-only { padding: 0.6rem; }
.card.photo-only .ph { margin: 0; }

#pane-u .card {
  top: 0; bottom: 0; margin: auto 0; height: fit-content;
  right: 5vw; width: min(470px, 38vw);
  max-height: 88vh; overflow: hidden;
}
#pane-u .card.final { width: min(520px, 42vw); }

/* Diapositive : la photo entière sur un fond flouté d'elle-même */
.slide { position: absolute; inset: 0; opacity: 0; transition: opacity 1.1s ease; }
.slide.on { opacity: 1; }
.slide img { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.slide .bg { object-fit: cover; filter: blur(18px) brightness(0.42) saturate(1.1); transform: scale(1.2); }
.slide .fg { object-fit: contain; transform: scale(1); transition: transform var(--kb, 6s) linear; }
.slide.on .fg { transform: scale(1.05); }

/* ---------------------------------------------------------------- Textes */
#caption {
  position: absolute; z-index: 8; bottom: 13vh; left: var(--gx, 50%);
  transform: translateX(-50%); width: min(88vw, 1100px);
  text-align: center;
}
body[data-focus="side"] #caption { width: 54vw; }
#caption .c-text {
  font-family: var(--serif); font-style: italic; font-weight: 400;
  font-size: clamp(1.6rem, 3.3vw, 2.9rem); line-height: 1.15;
  text-shadow: 0 2px 30px rgba(0, 0, 0, 0.85), 0 0 60px rgba(0, 0, 0, 0.6);
}
#caption span { display: inline-block; opacity: 0; transform: translateY(0.3em); transition: opacity 0.7s ease, transform 0.7s ease; }
#caption.on span { opacity: 1; transform: none; }
#caption:not(.on) span { transition-delay: 0s !important; }
#caption .c-sub { margin-top: 0.7rem; font-size: 1.05rem; color: var(--ink); opacity: 0; transition: opacity 0.8s ease 0.6s; }
#caption.on .c-sub { opacity: 0.85; }

#bigtitle {
  position: absolute; inset: 0; z-index: 8;
  display: grid; place-content: center; text-align: center; padding: 0 6vw;
  opacity: 0; transition: opacity 1.2s ease;
}
#bigtitle.on { opacity: 1; }
#bigtitle::before {
  content: ''; position: absolute; left: 50%; top: 50%; width: min(1100px, 96vw); height: 46vh;
  transform: translate(-50%, -50%); z-index: -1;
  background: radial-gradient(closest-side, rgba(5, 5, 5, 0.72), rgba(5, 5, 5, 0.4) 55%, rgba(5, 5, 5, 0));
}
#bigtitle h2 {
  font-family: var(--serif); font-weight: 300; font-style: italic;
  font-size: clamp(3rem, 9vw, 8.5rem); line-height: 0.95; letter-spacing: -0.02em;
  text-shadow: 0 0 40px rgba(240, 195, 106, 0.35), 0 4px 40px rgba(0, 0, 0, 0.7);
}
#bigtitle .second { margin-top: 0.6rem; font-size: clamp(1.4rem, 3vw, 2.6rem); color: var(--gold); font-family: var(--serif); }
#bigtitle .sub { margin-top: 1.2rem; font-size: clamp(1rem, 1.6vw, 1.35rem); opacity: 0.9; text-shadow: 0 2px 20px rgba(0, 0, 0, 0.8); }

/* ---------------------------------------------------------------- Rideau noir */
#curtain {
  position: fixed; inset: 0; z-index: 6;
  background: var(--void);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none;
  transition-property: opacity; transition-timing-function: ease;
}
#curtain.on { opacity: 1; }
.preword {
  position: absolute; text-align: center; padding: 0 1.5rem;
  font-family: var(--serif); font-style: italic; font-weight: 500;
  font-size: clamp(1.8rem, 4.8vw, 3.4rem); letter-spacing: -0.01em;
  opacity: 0; transition: opacity 1s ease;
}
.preword.on { opacity: 1; }
.typed { text-align: center; padding: 0 1.5rem; opacity: 0; transition: opacity 0.4s ease; }
.typed.on { opacity: 1; }
.typed .l1 { display: block; font-weight: 600; font-size: clamp(1.8rem, 4.5vw, 3.2rem); letter-spacing: -0.01em; }
.typed .l2 { display: block; font-weight: 400; font-size: clamp(1.1rem, 2.4vw, 1.7rem); margin-top: 0.6rem; min-height: 1.2em; }
.cursor {
  display: inline-block; width: 0.09em; background: var(--ink);
  margin-left: 0.08em; opacity: 0;
}
.cursor.on { opacity: 1; animation: blink 0.8s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.verse { position: absolute; text-align: center; padding: 0 8vw; opacity: 0; transition: opacity 1.4s ease; }
.verse.on { opacity: 1; }
.verse blockquote { font-family: var(--serif); font-style: italic; font-weight: 300; font-size: clamp(1.8rem, 4vw, 3.2rem); line-height: 1.25; max-width: 24ch; margin: 0 auto; }
.verse figcaption { margin-top: 1.4rem; font-family: var(--mono); font-size: 0.85rem; color: var(--mute); }

#flash {
  position: fixed; inset: 0; z-index: 7; pointer-events: none; opacity: 0;
  background: radial-gradient(circle at 50% 50%, #fffaf0 0%, rgba(255, 236, 190, 0.95) 18%, rgba(240, 195, 106, 0.5) 42%, rgba(5, 5, 5, 0) 75%);
}

/* ---------------------------------------------------------------- Diaporama plein écran */
#photos { position: fixed; inset: 0; z-index: 5; background: rgba(5, 5, 5, 0.96); opacity: 0; pointer-events: none; transition: opacity 0.9s ease; }
#photos.on { opacity: 1; }
#photos .ps-frame { position: absolute; inset: 0; }
#photos .slide .fg { top: 6vh; left: 8vw; width: calc(100% - 16vw); height: calc(100% - 28vh); }
#photos .ps-cap { position: absolute; left: 8vw; right: 26vw; bottom: 5vh; }
#photos .ps-cap h3 { font-family: var(--serif); font-style: italic; font-weight: 400; font-size: clamp(1.8rem, 3.4vw, 3rem); line-height: 1.05; }
#photos .ps-sub { margin-top: 0.5rem; font-family: var(--mono); font-size: 0.8rem; color: var(--mute); }
#photos .ps-text { margin-top: 0.6rem; font-size: 1.05rem; line-height: 1.5; max-width: 60ch; opacity: 0.9; }
#photos .ps-count { position: absolute; right: 8vw; bottom: 5.5vh; font-family: var(--mono); font-size: 0.8rem; color: var(--mute); }
#photos.mosaic .ps-frame { inset: 7vh 6vw 22vh; display: grid; grid-template-columns: repeat(var(--cols, 3), 1fr); grid-auto-rows: 1fr; gap: 8px; }
#photos .tile { overflow: hidden; opacity: 0; transform: scale(0.94); transition: opacity 0.7s ease, transform 0.7s ease; }
#photos .tile.on { opacity: 1; transform: none; }
#photos .tile img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---------------------------------------------------------------- L'équipe grandit */
#team { position: absolute; inset: 0; z-index: 7; opacity: 0; transition: opacity 0.8s ease; }
#team.on { opacity: 1; }
.t-board {
  position: absolute; top: 8vh; left: 6vw; right: 6vw; bottom: 32vh;
  display: flex; flex-wrap: wrap; align-content: center; justify-content: center; gap: 8px;
  transition: opacity 1.2s ease, filter 1.2s ease;
}
.t-board .tile {
  width: var(--tw, 200px); height: calc(var(--tw, 200px) * 0.75);
  overflow: hidden; opacity: 0; transform: scale(0.85);
  transition: width 0.8s ease, height 0.8s ease, opacity 0.7s ease, transform 0.7s ease;
}
.t-board .tile.on { opacity: 1; transform: none; }
.t-board .tile img { width: 100%; height: 100%; object-fit: cover; display: block; }
.t-now { position: absolute; left: 6vw; bottom: 12vh; max-width: 46vw; opacity: 0; transition: opacity 0.5s ease; }
.t-now.on { opacity: 1; }
.t-label { font-family: var(--serif); font-style: italic; font-weight: 300; font-size: clamp(2rem, 4.4vw, 3.8rem); line-height: 1; }
.t-text { margin-top: 0.6rem; font-size: 1.05rem; line-height: 1.45; color: var(--ink); opacity: 0.85; }
.t-units { position: absolute; right: 6vw; bottom: 12vh; width: min(34vw, 420px); }
.t-cap { font-size: 0.78rem; color: var(--mute); margin-bottom: 0.5rem; }
.t-dots { display: flex; flex-wrap: wrap; gap: 3px; }
.t-dots i { width: 10px; height: 10px; border-radius: 50%; background: var(--gold); opacity: 0; transform: scale(0.3); transition: opacity 0.4s ease, transform 0.4s ease; }
.t-dots i.on { opacity: 1; transform: none; }
.t-count { margin-top: 0.5rem; font-size: clamp(1.3rem, 2.2vw, 1.9rem); font-weight: 500; color: var(--ink); }
.t-rail {
  position: absolute; left: 6vw; right: 6vw; bottom: 5vh;
  display: flex; list-style: none; border-top: 1px solid rgba(244, 244, 242, 0.2);
}
.t-rail li { flex: 1; position: relative; padding-top: 0.75rem; font-family: var(--mono); font-size: 0.78rem; color: var(--mute); transition: color 0.5s ease; }
.t-rail li::before {
  content: ''; position: absolute; top: -4px; left: 0; width: 7px; height: 7px; border-radius: 50%;
  background: var(--void); border: 1px solid var(--mute); transition: background 0.5s ease, border-color 0.5s ease;
}
.t-rail li.now { color: var(--ink); }
.t-rail li.now::before, .t-rail li.done::before { background: var(--gold); border-color: var(--gold); }
.t-final {
  position: absolute; inset: 0; display: grid; place-content: center; text-align: center; padding: 0 6vw 12vh;
  font-family: var(--serif); font-style: italic; font-weight: 300;
  font-size: clamp(3rem, 8vw, 7.5rem); line-height: 1; letter-spacing: -0.02em;
  opacity: 0; transition: opacity 1.2s ease;
  text-shadow: 0 0 50px rgba(240, 195, 106, 0.45), 0 4px 30px rgba(0, 0, 0, 0.8);
}
#team.final .t-board { opacity: 0.3; filter: saturate(0.6); }
#team.final .t-now { opacity: 0; }
#team.final .t-final { opacity: 1; }

/* ---------------------------------------------------------------- Écran de départ, fin, commandes */
#start {
  position: fixed; inset: 0; z-index: 12;
  background: var(--void);
  display: grid; place-items: center;
}
#play-button {
  width: 84px; height: 84px; border-radius: 50%;
  border: 1.5px solid var(--ink); background: transparent;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: transform 0.2s ease, background 0.2s ease;
}
#play-button:hover { transform: scale(1.06); background: rgba(244, 244, 242, 0.06); }
#play-button svg { margin-left: 5px; }
.start-alt {
  position: absolute; bottom: 10vh; left: 50%; transform: translateX(-50%);
  background: none; border: 0; cursor: pointer;
  font-size: 0.9rem; color: var(--mute);
  text-decoration: underline; text-underline-offset: 4px; text-decoration-color: rgba(154, 154, 149, 0.4);
}
.start-alt:hover { color: var(--ink); }

.pill {
  background: rgba(5, 5, 5, 0.35); border: 1px solid rgba(244, 244, 242, 0.3);
  border-radius: 999px; padding: 0.6rem 1.1rem; cursor: pointer;
  font-size: 0.88rem; font-weight: 500; backdrop-filter: blur(6px);
  transition: border-color 0.2s ease, background 0.2s ease;
}
.pill:hover { border-color: var(--ink); background: rgba(244, 244, 242, 0.08); }
.pill.primary { background: var(--ink); color: var(--void); border-color: var(--ink); }
.pill.primary:hover { background: #fff; }

#skip { position: fixed; top: 1.3rem; right: 1.5rem; z-index: 11; transition: opacity 0.5s ease, border-color 0.2s ease, background 0.2s ease; }
body:not(.playing) #skip { display: none; }
body.idle #skip { opacity: 0.55; }

#end {
  position: fixed; inset: 0; z-index: 9;
  display: grid; place-content: center; text-align: center; gap: 2rem; padding: 0 6vw;
  background: radial-gradient(ellipse at center, rgba(5, 5, 5, 0.25), rgba(5, 5, 5, 0.88));
  opacity: 0; transition: opacity 1.5s ease;
}
#end.on { opacity: 1; }
#end.side { justify-content: start; justify-items: start; text-align: left; padding: 0 0 0 7vw; width: 56vw; background: linear-gradient(90deg, rgba(5, 5, 5, 0.8), rgba(5, 5, 5, 0)); }
#end.side .actions { justify-content: flex-start; }
#end .msg { font-family: var(--serif); font-style: italic; font-weight: 300; font-size: clamp(2rem, 5vw, 4rem); line-height: 1.1; text-shadow: 0 2px 30px rgba(0, 0, 0, 0.8); }
#end .actions { display: flex; gap: 0.8rem; justify-content: center; flex-wrap: wrap; }

#controls {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 10;
  display: flex; align-items: center; gap: 0.2rem;
  padding: 1.4rem 1.4rem 1rem;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.6));
  transition: opacity 0.5s ease;
}
body:not(.playing) #controls { display: none; }
body.idle:not(.paused) #controls { opacity: 0; }
body.idle:not(.paused) { cursor: none; }
#controls > button {
  width: 38px; height: 38px; border-radius: 50%; border: 0; background: transparent;
  display: grid; place-items: center; cursor: pointer; flex-shrink: 0;
}
#controls > button:hover { background: rgba(244, 244, 242, 0.1); }
#controls svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
#controls .i-play, #controls .is-paused .i-pause { display: none; }
#controls .is-paused .i-play { display: block; }
#controls .i-muted, #controls .muted .i-sound { display: none; }
#controls .muted .i-muted { display: block; }
.ticks { flex: 1; display: flex; list-style: none; margin: 0 0.8rem; min-width: 0; }
.ticks li { flex: 1; display: flex; min-width: 0; }
.ticks button { flex: 1; height: 30px; border: 0; background: none; cursor: pointer; position: relative; min-width: 0; }
.ticks button::before {
  content: ''; position: absolute; left: 0; right: 3px; top: 50%; height: 2px; transform: translateY(-50%);
  background: rgba(244, 244, 242, 0.2); transition: background 0.3s ease, height 0.3s ease;
}
.ticks button.done::before { background: rgba(244, 244, 242, 0.65); }
.ticks button.now::before { background: var(--gold); height: 4px; }
.ticks button:hover::before { background: var(--ink); }
.tip {
  position: absolute; bottom: 100%; left: 0; margin-bottom: 0.3rem;
  white-space: nowrap; font-size: 0.78rem; padding: 0.35rem 0.55rem;
  background: rgba(5, 5, 5, 0.9); border: 1px solid var(--line);
  opacity: 0; pointer-events: none; transition: opacity 0.2s ease;
}
.ticks li:nth-last-child(-n+4) .tip { left: auto; right: 0; }
.ticks button:hover .tip, .ticks button:focus-visible .tip { opacity: 1; }

/* ---------------------------------------------------------------- Écrans étroits (mode cinéma) */
body.portrait .pane .card { top: 12%; right: 4%; width: 60%; padding: 0.6rem 0.7rem 0.8rem; }
body.portrait .card h3 { font-size: 1.1rem; }
body.portrait .card p { font-size: 0.85rem; }
body.portrait .card .ph { aspect-ratio: 16 / 10; margin-bottom: 0.6rem; }
body.portrait .dossier-fields { font-size: 0.62rem; }
body.portrait #pane-u .card { left: 5vw; right: 5vw; top: auto; bottom: 12vh; margin: 0; width: auto; max-height: 46vh; }
body.portrait #caption { bottom: 6vh; width: 90vw; }
body.portrait .t-now { max-width: 88vw; bottom: 22vh; }
body.portrait .t-units { left: 6vw; right: 6vw; width: auto; bottom: 11vh; }
body.portrait .t-board { bottom: 40vh; }
@media (max-width: 700px) {
  #skip { top: 0.8rem; right: 0.8rem; }
  #controls { padding: 1rem 0.6rem 0.7rem; }
  .ticks { margin: 0 0.3rem; }
  #photos .ps-cap { right: 8vw; }
}

/* ================================================================ Récit vertical */
#recit { position: relative; z-index: 1; min-height: 100vh; background: var(--void); }
.r-bar {
  position: sticky; top: 0; z-index: 5;
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
  padding: 1rem 2.2rem;
  background: linear-gradient(var(--void) 55%, rgba(5, 5, 5, 0));
}
.r-mark { font-family: var(--serif); font-style: italic; font-size: 1.05rem; }
.r-bar .r-replay, .r-foot .r-replay {
  background: transparent; border: 1px solid rgba(244, 244, 242, 0.3); border-radius: 999px;
  padding: 0.55rem 1.05rem; cursor: pointer; font-size: 0.88rem; font-weight: 500;
}
.r-bar .r-replay:hover, .r-foot .r-replay:hover { border-color: var(--ink); }

.r-hero { max-width: 1180px; margin: 0 auto; padding: 14vh 2.2rem 0; text-align: center; }
.r-hero h1 { font-family: var(--serif); font-weight: 300; font-size: clamp(3rem, 10vw, 8rem); line-height: 0.95; letter-spacing: -0.02em; }
.r-hero > p { margin: 1.4rem auto 0; font-size: clamp(1.05rem, 1.8vw, 1.35rem); color: var(--mute); max-width: 40ch; }
.r-origins { display: grid; grid-template-columns: 1fr 80px 1fr; margin-top: 12vh; }
.r-origins p { font-family: var(--serif); font-style: italic; font-size: clamp(1.4rem, 2.6vw, 2rem); line-height: 1.1; }
.r-origins span { display: block; margin-top: 0.3rem; font-family: var(--mono); font-style: normal; font-size: 0.75rem; color: var(--mute); }
.r-origins .r-a { grid-column: 1; text-align: right; }
.r-origins .r-b { grid-column: 3; text-align: left; }

.r-flow { position: relative; max-width: 1180px; margin: 0 auto; padding: 1.5rem 2.2rem 5rem; }
.r-threads { position: absolute; left: 0; top: 0; pointer-events: none; overflow: visible; }
.r-threads .fil { fill: none; stroke-width: 1.6; stroke-linecap: round; }
.r-threads .fil.uni { stroke-width: 2.6; }
.r-threads .knot { fill: var(--void); stroke: var(--cyan); stroke-width: 1.5; opacity: 0; transition: opacity 0.5s ease; }
.r-threads .knot.gold { stroke: var(--gold); }
.r-threads .knot.big, .r-threads .knot.fusion { fill: var(--gold); stroke: none; }
.r-threads .knot.on { opacity: 1; }

.r-sec { position: relative; padding: 4.5rem 0; }
.r-grid { display: grid; grid-template-columns: 1fr 80px 1fr; align-items: start; }
.r-col { min-width: 0; }
.r-a, .r-when { grid-column: 1; text-align: right; }
.r-b, .r-what { grid-column: 3; text-align: left; }
.r-gut { grid-column: 2; }
.r-a .r-text, .r-when .r-text { margin-left: auto; }

.r-duo-title {
  display: table; margin: 0 auto 3rem; padding: 0.4rem 1rem; position: relative; z-index: 1;
  background: var(--void); text-align: center;
  font-family: var(--serif); font-style: italic; font-weight: 400;
  font-size: clamp(1.8rem, 3.6vw, 2.8rem); line-height: 1.1;
}
.r-who { font-family: var(--mono); font-size: 0.75rem; color: var(--mute); margin-bottom: 0.5rem; }
.r-col h3 { font-family: var(--serif); font-style: italic; font-weight: 400; font-size: clamp(1.5rem, 2.4vw, 2rem); line-height: 1.12; }
.r-date { font-family: var(--mono); font-size: 0.8rem; color: var(--mute); margin-top: 0.6rem; }
.r-place { margin-top: 0.4rem; font-size: 0.98rem; }
.r-place span { margin-left: 0.6rem; font-family: var(--mono); font-size: 0.72rem; color: var(--mute); }
.r-text { margin-top: 1rem; font-size: 1.18rem; line-height: 1.55; font-weight: 300; max-width: 44ch; }

.r-person { display: flex; gap: 1.2rem; align-items: flex-start; }
.r-a .r-person { flex-direction: row-reverse; }
.r-portrait { width: 118px; flex-shrink: 0; aspect-ratio: 4 / 4.6 !important; border: 1px solid rgba(90, 209, 255, 0.4) !important; }
.r-dossier { margin-top: 0.8rem; font-family: var(--mono); font-size: 0.78rem; line-height: 1.8; }
.r-dossier div { display: flex; gap: 0.6rem; }
.r-a .r-dossier div { justify-content: flex-end; }
.r-dossier dt { color: var(--cyan); }

.r-route { display: grid; gap: 0.2rem; }
.coord-row { display: grid; grid-template-columns: 2.4rem 1fr auto; align-items: baseline; gap: 1rem; padding: 0.9rem 0; border-bottom: 1px solid var(--line); text-align: left; }
.coord-row .idx { color: var(--mute); font-size: 0.8rem; }
.coord-row .cr-place { font-family: var(--serif); font-weight: 300; font-style: italic; font-size: 1.5rem; }
.coord-row .val { color: var(--mute); font-family: var(--mono); font-size: 0.75rem; }

.r-gal { display: grid; gap: 6px; margin-top: 1.4rem; grid-template-columns: repeat(2, 1fr); }
.r-gal.n1 { grid-template-columns: 1fr; }
.r-gal.n3 .r-ph:first-child { grid-column: span 2; }
.r-gal.n4 { grid-template-columns: repeat(3, 1fr); }
.r-gal.wide { max-width: 980px; margin: 2.4rem auto 0; }
.r-ph { display: block; padding: 0; border: 0; background: var(--void-2); aspect-ratio: 4 / 3; overflow: hidden; cursor: zoom-in; }
.r-ph img { width: 100%; height: 100%; object-fit: cover; display: block; }

.r-statement { padding: 6.5rem 0; text-align: center; }
.r-statement p {
  display: inline-block; position: relative; z-index: 1; background: var(--void); padding: 1rem 0.5rem;
  font-family: var(--serif); font-weight: 300; font-size: clamp(1.7rem, 3.6vw, 2.8rem); line-height: 1.25; max-width: 22ch;
}
.r-statement cite { display: block; margin-top: 0.4rem; font-family: var(--mono); font-style: normal; font-size: 0.8rem; color: var(--mute); position: relative; z-index: 1; }

.r-fusion, .r-final, .r-team-head { text-align: center; }
.r-fusion { padding: 7rem 0 5rem; }
.r-fusion > *:not(.r-knot):not(.r-gal) { position: relative; z-index: 1; }
.r-phrase { display: inline-block; background: var(--void); padding: 0.4rem 0.8rem; font-family: var(--serif); font-style: italic; font-size: clamp(1.4rem, 2.6vw, 2rem); color: var(--mute); }
.r-knot { display: block; width: 14px; height: 14px; margin: 2.2rem auto; }
.r-fusion h2, .r-team-head h2 {
  display: inline-block; background: var(--void); padding: 0.1em 0.3em;
  font-family: var(--serif); font-weight: 300; font-size: clamp(2.8rem, 8vw, 6.5rem); line-height: 0.95; letter-spacing: -0.02em;
}
.r-team-head h2 { font-size: clamp(2.4rem, 6vw, 4.8rem); margin-top: 0.8rem; }
.r-sub { margin-top: 1rem; font-size: 1.3rem; }
.r-fmeta { margin-top: 0.4rem; }
.r-fusion .r-text, .r-final .r-text { margin: 1.4rem auto 0; background: var(--void); }
.r-phrases { margin-top: 0.8rem; font-family: var(--serif); font-style: italic; font-size: 1.35rem; line-height: 1.5; }
.r-count { margin-top: 0.8rem; font-size: 1.1rem; font-weight: 500; }
.r-period { font-family: var(--serif); font-style: italic; font-weight: 300; font-size: clamp(1.8rem, 3.6vw, 2.8rem); line-height: 1; }
.r-team { padding: 2.8rem 0; }
.r-units { display: flex; align-items: center; gap: 0.8rem; flex-wrap: wrap; margin-top: 1rem; }
.r-dots { display: flex; flex-wrap: wrap; gap: 3px; max-width: 320px; }
.r-dots i { width: 9px; height: 9px; border-radius: 50%; background: var(--gold); }
.r-units-n { font-size: 1rem; font-weight: 500; }

.r-final { padding: 7rem 0 3rem; }
.r-final > *:not(.r-knot):not(.r-gal) { position: relative; z-index: 1; }
.r-final h2 { display: inline-block; background: var(--void); padding: 0.1em 0.3em; font-family: var(--serif); font-weight: 300; font-size: clamp(3.2rem, 10vw, 8rem); line-height: 0.9; letter-spacing: -0.02em; }
.r-final h2 span { display: block; margin-top: 0.3rem; font-size: 0.34em; color: var(--gold); letter-spacing: 0.05em; font-family: 'Noto Serif SC', 'Microsoft YaHei', 'PingFang SC', serif; }
.r-final .r-place, .r-final .r-date { display: table; margin: 0.6rem auto 0; background: var(--void); padding: 0 0.4rem; }
.r-final blockquote { max-width: 30ch; margin: 2.6rem auto 0; background: var(--void); padding: 0.6rem; font-family: var(--serif); font-style: italic; font-weight: 300; font-size: clamp(1.4rem, 2.6vw, 2rem); line-height: 1.35; }
.r-final blockquote cite { display: block; margin-top: 0.7rem; font-family: var(--mono); font-style: normal; font-size: 0.8rem; color: var(--mute); }

.r-foot { text-align: center; padding: 4rem 2.2rem; border-top: 1px solid var(--line); display: grid; gap: 1.6rem; justify-items: center; }
.r-end { font-family: var(--serif); font-style: italic; font-weight: 300; font-size: clamp(1.8rem, 4vw, 3rem); }
.r-small { font-size: 0.8rem; color: var(--mute); }

#lightbox { position: fixed; inset: 0; z-index: 50; background: rgba(5, 5, 5, 0.95); display: grid; place-items: center; }
#lightbox img { max-width: 90vw; max-height: 84vh; object-fit: contain; display: block; }
#lightbox button { position: absolute; background: rgba(5, 5, 5, 0.5); border: 1px solid rgba(244, 244, 242, 0.3); border-radius: 999px; width: 46px; height: 46px; cursor: pointer; display: grid; place-items: center; }
#lightbox button:hover { border-color: var(--ink); }
#lightbox svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
#lightbox [data-lb="close"] { top: 1.2rem; right: 1.2rem; }
#lightbox [data-lb="prev"] { left: 1.2rem; top: 50%; transform: translateY(-50%); }
#lightbox [data-lb="next"] { right: 1.2rem; top: 50%; transform: translateY(-50%); }
#lightbox .lb-count { position: absolute; bottom: 1.4rem; left: 50%; transform: translateX(-50%); font-family: var(--mono); font-size: 0.8rem; color: var(--mute); }

@media (max-width: 760px) {
  .r-bar { padding: 0.8rem 1rem; }
  .r-hero { padding: 10vh 1rem 0; text-align: left; padding-left: 44px; }
  .r-hero > p { margin-left: 0; }
  .r-origins { grid-template-columns: 44px 1fr; margin-top: 8vh; margin-left: -44px; }
  .r-origins .r-a, .r-origins .r-b { grid-column: 2; text-align: left; }
  .r-origins .r-b { margin-top: 0.8rem; }
  .r-flow { padding: 1rem 1rem 4rem; }
  .r-grid { grid-template-columns: 44px 1fr; }
  .r-a, .r-b, .r-when, .r-what { grid-column: 2; text-align: left; }
  .r-gut { display: none; }
  .r-b { margin-top: 2.6rem; }
  .r-when { margin-bottom: 0.4rem; }
  .r-a .r-text, .r-when .r-text { margin-left: 0; }
  .r-a .r-person { flex-direction: row; }
  .r-a .r-dossier div { justify-content: flex-start; }
  .r-sec { padding: 3rem 0; }
  .r-statement, .r-fusion, .r-final, .r-team-head { text-align: left; padding-left: 44px; }
  .r-duo-title { margin: 0 0 2rem 44px; padding: 0; text-align: left; }
  .r-knot { margin: 1.6rem 0 1.6rem -32px; }
  .r-gal.wide { margin-left: 0; }
  .r-final .r-place, .r-final .r-date { margin-left: 0; }
  .r-final blockquote { margin-left: 0; }
  .r-portrait { width: 86px; }
}

@media (prefers-reduced-motion: reduce) {
  .slide .fg, .slide.on .fg { transition: none; transform: none; }
}
