:root {
  --bg: #07111f;
  --bg-soft: #0d1b2f;
  --panel: #10213a;
  --panel-2: #142844;
  --text: #f7fbff;
  --muted: #c7d2e5;
  --subtle: #94a8c4;
  --line: #31435f;
  --brand: #7dd3fc;
  --brand-strong: #38bdf8;
  --gold: #ffd166;
  --accent: #c4b5fd;
  --focus: #ffd166;
  --danger: #ffb4c0;
  --ok: #86efac;
  --shadow: 0 24px 60px rgb(0 0 0 / 0.28);
  --radius-lg: 28px;
  --radius-md: 18px;
  color-scheme: dark;
}
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --bg: #fffaf0;
    --bg-soft: #f5efe4;
    --panel: #ffffff;
    --panel-2: #f2eadf;
    --text: #172033;
    --muted: #41516b;
    --subtle: #5f708a;
    --line: #c9d2df;
    --brand: #005e8f;
    --brand-strong: #014f7a;
    --gold: #8a5700;
    --accent: #5b21b6;
    --focus: #7c3aed;
    --danger: #9f1239;
    --ok: #166534;
    --shadow: 0 24px 60px rgb(40 30 20 / 0.14);
    color-scheme: light;
  }
}
:root[data-theme="light"] {
  --bg: #fffaf0;
  --bg-soft: #f5efe4;
  --panel: #ffffff;
  --panel-2: #f2eadf;
  --text: #172033;
  --muted: #41516b;
  --subtle: #5f708a;
  --line: #c9d2df;
  --brand: #005e8f;
  --brand-strong: #014f7a;
  --gold: #8a5700;
  --accent: #5b21b6;
  --focus: #7c3aed;
  --danger: #9f1239;
  --ok: #166534;
  --shadow: 0 24px 60px rgb(40 30 20 / 0.14);
  color-scheme: light;
}
* { box-sizing: border-box; }
html { min-width: 0; scroll-behavior: smooth; }
body {
  margin: 0;
  min-width: 0;
  overflow-x: clip;
  background:
    radial-gradient(circle at 15% 0%, rgb(125 211 252 / 0.22), transparent 34rem),
    radial-gradient(circle at 82% 12%, rgb(255 209 102 / 0.14), transparent 32rem),
    linear-gradient(145deg, var(--bg), var(--bg-soft));
  color: var(--text);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.6;
  text-rendering: optimizeLegibility;
}
a { color: inherit; }
a:hover { color: var(--brand); }
p, h1, h2, h3, a, dd, dt, td, th, strong { overflow-wrap: anywhere; }
img, svg { max-width: 100%; height: auto; }
button, input, select { font: inherit; }
button, .button, nav a, input, select, .chip, .tag-link { min-height: 44px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 8px; }
.skip-link {
  position: absolute;
  left: 12px;
  top: 12px;
  z-index: 1000;
  transform: translateY(-160%);
  background: var(--gold);
  color: #06101e;
  padding: 10px 14px;
  border-radius: 999px;
  font-weight: 900;
  text-decoration: none;
}
.skip-link:focus { transform: translateY(0); }
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px clamp(14px, 4vw, 40px);
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(16px);
}
.brand { display: inline-flex; align-items: center; gap: 12px; min-width: 0; color: var(--text); text-decoration: none; }
.brand-mark {
  width: 44px;
  min-width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 15px;
  background: linear-gradient(135deg, var(--brand), var(--gold));
  color: #07111f;
  font-weight: 1000;
  letter-spacing: -0.04em;
}
.brand strong { display: block; line-height: 1.1; overflow-wrap: anywhere; }
.brand small { display: block; color: var(--muted); font-size: 0.78rem; margin-top: 1px; }
.site-nav { display: flex; align-items: center; gap: 6px; }
.site-nav a, .theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: 999px;
  color: var(--muted);
  padding: 9px 12px;
  font-weight: 800;
  text-decoration: none;
}
.site-nav a[aria-current="page"], .site-nav a:hover, .theme-toggle:hover {
  border-color: var(--line);
  background: var(--panel);
  color: var(--text);
}
.theme-toggle { cursor: pointer; background: transparent; }
main { width: min(1180px, calc(100% - 32px)); margin: 0 auto; min-width: 0; }
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.36fr) minmax(280px, 0.64fr);
  gap: 22px;
  padding: clamp(38px, 7vw, 82px) 0 34px;
}
.surface, .hero-copy, .stat-panel, .panel, .browser, .item-hero, .notice-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, rgb(255 255 255 / 0.055), rgb(255 255 255 / 0.025)), var(--panel);
  box-shadow: var(--shadow);
}
.hero-copy { padding: clamp(26px, 5vw, 54px); }
.eyebrow {
  margin: 0 0 10px;
  color: var(--gold);
  font-size: 0.76rem;
  font-weight: 950;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}
h1, h2, h3 { margin: 0; line-height: 1.08; text-wrap: balance; }
h1 { font-size: clamp(2.38rem, 7vw, 5.3rem); letter-spacing: -0.07em; }
h2 { font-size: clamp(1.55rem, 3vw, 2.45rem); letter-spacing: -0.045em; }
h3 { font-size: 1.08rem; letter-spacing: -0.018em; }
.lede { max-width: 780px; color: var(--muted); font-size: clamp(1.04rem, 2vw, 1.24rem); }
.hero-search, .search-row { display: flex; gap: 10px; flex-wrap: wrap; }
.hero-search { margin: 26px 0 18px; }
.field { display: grid; gap: 7px; color: var(--muted); font-weight: 850; }
.hero-search .field, .search-row .field { flex: 1 1 260px; }
input, select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--bg-soft);
  color: var(--text);
  padding: 12px 14px;
}
.button, button, .chip, .tag-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--panel-2);
  color: var(--text);
  padding: 10px 14px;
  font-weight: 850;
  text-decoration: none;
}
button { cursor: pointer; }
.button.primary, button.primary { border-color: transparent; background: linear-gradient(135deg, var(--brand-strong), var(--accent)); color: #ffffff; }
.hero-actions, .item-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.stat-panel { padding: 22px; display: grid; gap: 12px; align-content: center; }
.stat { padding: 16px; border: 1px solid var(--line); border-radius: 20px; background: rgb(255 255 255 / 0.035); }
.stat strong { display: block; font-size: clamp(1.7rem, 4vw, 2.9rem); line-height: 1; }
.stat span { color: var(--muted); }
.mini-stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.mini-stats .stat strong { font-size: 1.4rem; }
.section, .page { padding: 34px 0; }
.page { padding-bottom: 70px; }
.section-head { max-width: 760px; margin-bottom: 18px; }
.section-head.split { display: flex; align-items: end; justify-content: space-between; gap: 16px; max-width: none; }
.section-head p, .card p, .muted, .page-title p, .note { color: var(--muted); }
.page-title { max-width: 850px; margin: 34px 0 22px; }
.page-title h1 { font-size: clamp(2.1rem, 5vw, 4.5rem); }
.shelf-grid, .card-grid, .pathway-grid { display: grid; gap: 16px; }
.shelf-grid, .pathway-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.card-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.shelf-card, .pathway-card, .card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--panel);
  color: var(--text);
  overflow: clip;
  text-decoration: none;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}
.shelf-card, .pathway-card { min-height: 170px; padding: 20px; justify-content: space-between; }
.shelf-card:hover, .pathway-card:hover, .card:hover { transform: translateY(-3px); border-color: var(--brand); }
.shelf-card span, .pathway-card span { color: var(--gold); font-weight: 950; }
.shelf-card strong, .pathway-card strong { font-size: 1.33rem; letter-spacing: -0.03em; }
.shelf-card small, .pathway-card small { color: var(--muted); font-size: 0.95rem; }
.meta-strip { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.meta-strip span, .status-badge { display: inline-flex; align-items: center; min-height: 30px; border: 1px solid var(--line); border-radius: 999px; padding: 4px 9px; color: var(--muted); font-size: 0.84rem; background: rgb(255 255 255 / 0.035); }
.status-badge.core { color: var(--ok); border-color: color-mix(in srgb, var(--ok) 45%, var(--line)); }
.status-badge.review { color: var(--gold); border-color: color-mix(in srgb, var(--gold) 45%, var(--line)); }
.editorial-map { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.editorial-map div { border: 1px solid var(--line); border-radius: 18px; padding: 14px; background: rgb(255 255 255 / 0.035); }
.editorial-map strong { display: block; font-size: 1.6rem; line-height: 1; }
.spotlight-list { display: grid; gap: 12px; }
.spotlight-list a { display: block; border: 1px solid var(--line); border-radius: 18px; padding: 14px; background: rgb(255 255 255 / 0.035); text-decoration: none; }
.spotlight-list small { display: block; color: var(--muted); margin-top: 3px; }
.card-media {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, rgb(125 211 252 / 0.18), rgb(255 209 102 / 0.13));
  overflow: hidden;
}
.card-media img { width: 100%; height: 100%; object-fit: cover; opacity: 0.93; }
.media-pill {
  position: absolute;
  top: 12px;
  right: 12px;
  min-height: 32px;
  border-radius: 999px;
  background: rgb(0 0 0 / 0.68);
  color: #fff;
  padding: 5px 10px;
  font-size: 0.82rem;
  font-weight: 950;
}
.card-body { padding: 18px; flex: 1; }
.card h3 a { text-decoration: none; }
.card-footer { display: flex; justify-content: space-between; gap: 12px; padding: 13px 18px; border-top: 1px solid var(--line); color: var(--muted); font-size: 0.88rem; }
.tag-row, .chip-row { display: flex; flex-wrap: wrap; gap: 8px; }
.tag-row { margin-top: 12px; }
.tag-link, .chip {
  min-height: 34px;
  border-radius: 999px;
  color: var(--muted);
  background: rgb(255 255 255 / 0.035);
  font-size: 0.84rem;
  padding: 6px 10px;
}
.chip[aria-pressed="true"], .chip.active { background: var(--brand); border-color: transparent; color: #06101e; }
.notice-card { padding: 18px; border-color: color-mix(in srgb, var(--gold) 45%, var(--line)); }
.notice-card strong { color: var(--gold); }
.two-column, .content-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 18px; }
.two-column > *, .content-grid > *, .browser > *, .hero > *, .item-hero > * { min-width: 0; }
.panel { padding: 22px; min-width: 0; }
.prose p, .prose li, .prose dd, .prose td { color: var(--muted); }
.prose code { border: 1px solid var(--line); border-radius: 8px; padding: 2px 6px; background: var(--bg-soft); color: var(--text); }
.browser { display: grid; grid-template-columns: 310px minmax(0, 1fr); gap: 18px; padding: 18px; }
.filters { display: grid; gap: 17px; align-content: start; }
.filter-group strong { display: block; margin-bottom: 8px; }
.results-bar { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 16px; }
.results-bar output { font-weight: 950; }
.empty-state { padding: 42px; text-align: center; border: 1px dashed var(--line); border-radius: 24px; color: var(--muted); }
[hidden] { display: none !important; }
.timeline-list { list-style: none; padding: 0; margin: 18px 0 0; display: grid; gap: 12px; }
.timeline-list li { display: grid; grid-template-columns: 140px minmax(0, 1fr) auto; gap: 14px; align-items: start; padding: 14px; border: 1px solid var(--line); border-radius: 18px; background: rgb(255 255 255 / 0.035); }
.timeline-list time { color: var(--gold); font-weight: 900; font-size: 0.9rem; }
.timeline-list a { font-weight: 900; text-decoration: none; }
.timeline-list p { margin: 4px 0 0; }
.timeline-list .badge { white-space: nowrap; }
.badge { display: inline-flex; align-items: center; min-height: 30px; border: 1px solid var(--line); border-radius: 999px; padding: 4px 9px; color: var(--muted); font-size: 0.84rem; }
.tag-cloud { display: flex; flex-wrap: wrap; gap: 10px; }
.tag-cloud .tag-link { min-height: 40px; }
.tag-size-1 { font-size: 0.85rem; }
.tag-size-2 { font-size: 0.92rem; }
.tag-size-3 { font-size: 1rem; }
.tag-size-4 { font-size: 1.08rem; }
.tag-size-5 { font-size: 1.16rem; }
.item-hero { display: grid; grid-template-columns: minmax(0, 1fr) 310px; gap: 24px; align-items: center; padding: clamp(22px, 5vw, 42px); margin-top: 34px; }
.item-cover { margin: 0; border: 1px solid var(--line); border-radius: 24px; overflow: clip; background: var(--bg-soft); }
.item-cover img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; }
.item-cover figcaption { padding: 10px; color: var(--muted); border-top: 1px solid var(--line); font-size: 0.82rem; overflow-wrap: anywhere; }
.embed-frame { position: relative; width: 100%; aspect-ratio: 16 / 10; border: 1px solid var(--line); border-radius: 18px; overflow: clip; background: var(--bg-soft); }
.embed-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.embed-placeholder { position: static; display: grid; place-items: center; min-height: 240px; padding: 24px; text-align: center; }
.embed-placeholder p { max-width: 560px; margin-inline: auto; }
.reader-actions { display: flex; flex-wrap: wrap; justify-content: end; gap: 8px; }
.player-shell, .reader-page-layout, .watch-page-layout { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(260px, 0.65fr); gap: 16px; align-items: start; }
.reader-page-intro, .watch-page-intro { padding-bottom: 0; }
.reader-page-layout .player-stage iframe { min-height: min(80vh, 1040px); }
.reader-page-layout .playlist, .watch-page-layout .playlist { max-height: min(80vh, 1040px); }
.watch-page-layout .player-stage video { max-height: min(80vh, 1040px); }
.player-stage { border: 1px solid var(--line); border-radius: 22px; padding: 14px; background: var(--bg-soft); min-width: 0; }
.document-browser { margin: 0 0 12px; border: 1px solid var(--line); border-radius: 16px; overflow: clip; background: var(--panel-2); }
.document-browser-bar { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 9px; }
.document-browser-controls { display: flex; gap: 6px; }
.document-browser button { min-height: 38px; padding: 7px 10px; border-radius: 10px; line-height: 1; }
.document-browser button:disabled { cursor: not-allowed; opacity: 0.48; }
.document-address { min-width: 0; min-height: 38px; display: flex; align-items: center; gap: 8px; padding: 7px 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg-soft); color: var(--muted); font-size: 0.84rem; overflow: hidden; }
.document-address::before { content: "●"; color: var(--brand); font-size: 0.7rem; }
.document-address span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.document-browser-note { margin: 0; padding: 0 13px 11px; color: var(--muted); font-size: 0.78rem; }
.player-stage:fullscreen { width: 100%; height: 100%; max-width: none; padding: 14px; border-radius: 0; display: flex; flex-direction: column; background: var(--bg); }
.player-stage:fullscreen .document-browser { flex: 0 0 auto; }
.player-stage:fullscreen iframe[data-document-player] { flex: 1 1 auto; min-height: 0; height: 100%; }
.player-stage video, .player-stage audio, .player-stage iframe, .player-stage img { width: 100%; border: 0; border-radius: 16px; background: #000; }
.player-stage video { aspect-ratio: 16 / 9; display: block; }
.player-stage audio { display: block; min-height: 54px; background: transparent; }
.player-stage iframe { min-height: min(72vh, 760px); background: #fff; }
.player-stage img { display: block; max-height: 720px; object-fit: contain; background: var(--panel-2); }
.playlist { display: grid; gap: 8px; max-height: min(72vh, 760px); overflow: auto; padding-right: 4px; }
.playlist-button { justify-content: start; text-align: left; display: grid; grid-template-columns: 28px minmax(0, 1fr); grid-template-areas: "icon title" "icon meta"; gap: 2px 8px; width: 100%; border-radius: 16px; }
.playlist-button span { grid-area: icon; align-self: start; }
.playlist-button strong { grid-area: title; overflow-wrap: anywhere; }
.playlist-button small { grid-area: meta; color: var(--muted); }
.playlist-button[aria-current="true"] { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 18%, var(--panel-2)); }
.fact-list { display: grid; gap: 10px; margin: 16px 0 0; }
.fact-list div { display: grid; grid-template-columns: 135px minmax(0, 1fr); gap: 12px; padding-top: 10px; border-top: 1px solid var(--line); }
.fact-list dt { color: var(--muted); font-weight: 900; }
.fact-list dd { margin: 0; overflow-wrap: anywhere; }
.table-wrap { max-width: 100%; overflow-x: auto; border: 1px solid var(--line); border-radius: 18px; }
table { width: 100%; border-collapse: collapse; }
caption { padding: 12px 14px; text-align: left; color: var(--muted); font-weight: 850; }
th, td { padding: 12px 14px; text-align: left; vertical-align: top; border-top: 1px solid var(--line); }
th { color: var(--gold); font-size: 0.83rem; letter-spacing: 0.08em; text-transform: uppercase; }
td { overflow-wrap: anywhere; }
.quality-list { display: grid; gap: 12px; }
.quality-list article { border: 1px solid var(--line); border-radius: 18px; padding: 14px; background: rgb(255 255 255 / 0.035); }
.prev-next { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 22px; }
.prev-next a { border: 1px solid var(--line); border-radius: 18px; padding: 14px; color: var(--muted); text-decoration: none; background: var(--panel); }
.site-footer { width: min(1180px, calc(100% - 32px)); margin: 42px auto 24px; padding-top: 22px; border-top: 1px solid var(--line); display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 18px; color: var(--muted); }
.site-footer strong { color: var(--text); }
.footer-links { display: flex; gap: 10px; flex-wrap: wrap; align-content: start; justify-content: end; }
.footer-links a { color: var(--text); font-weight: 850; text-decoration: none; }
.medical-notice { margin-top: 10px; color: var(--gold); font-weight: 800; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
@media (max-width: 980px) {
  .hero, .two-column, .content-grid, .browser, .item-hero, .player-shell, .reader-page-layout, .watch-page-layout { grid-template-columns: 1fr; }
  .shelf-grid, .pathway-grid, .card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .editorial-map { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .item-cover { max-width: 360px; }
}
@media (max-width: 680px) {
  body { overflow-x: hidden; }
  main, .site-footer { width: min(100% - 24px, 1180px); }
  .site-header { flex-wrap: wrap; padding-inline: 12px; }
  .brand { flex: 1 1 auto; }
  .brand strong { font-size: 0.96rem; }
  .site-nav { order: 3; width: 100%; overflow-x: auto; padding-bottom: 3px; }
  .site-nav a { flex: 0 0 auto; }
  h1 { letter-spacing: -0.045em; }
  .hero { padding-top: 24px; }
  .shelf-grid, .pathway-grid, .card-grid, .prev-next, .editorial-map { grid-template-columns: 1fr; }
  .timeline-list li { grid-template-columns: 1fr; }
  .fact-list div { grid-template-columns: 1fr; }
  .site-footer { grid-template-columns: 1fr; }
  .footer-links { justify-content: start; }
  .mini-stats { grid-template-columns: 1fr 1fr; }
  .button, button, .chip, .tag-link, nav a, input, select { min-height: 44px; }
  .document-browser-bar { grid-template-columns: 1fr auto; }
  .document-address { grid-column: 1 / -1; grid-row: 2; }
}
@media (max-width: 390px) {
  .document-browser-bar { display: flex; flex-wrap: wrap; }
  .document-address { order: 3; width: 100%; }
  .document-browser-controls { flex: 1; }
  .document-browser-controls button { flex: 1; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; transition-duration: 0.01ms !important; }
}
/* Archive atelier refresh — local system font pairing, no external font request. */
:root {
  --bg: #12110f;
  --bg-soft: #1b1915;
  --panel: #1e1c18;
  --panel-2: #28241e;
  --text: #f7f0e2;
  --muted: #c9c0b0;
  --subtle: #9e9381;
  --line: #4d473d;
  --brand: #aee3d1;
  --brand-strong: #5eaa98;
  --gold: #e6bf7d;
  --accent: #c6a0d9;
  --focus: #f3cb86;
  --danger: #ffb2a0;
  --ok: #a7e4b7;
  --shadow: 0 24px 70px rgb(0 0 0 / 0.30);
  --serif: Iowan Old Style, Palatino Linotype, Book Antiqua, Georgia, ui-serif, serif;
  --sans: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --radius-lg: 30px;
  --radius-md: 18px;
}
:root[data-theme="light"] {
  --bg: #f5efe4;
  --bg-soft: #ebe1d0;
  --panel: #fffaf0;
  --panel-2: #f4eadb;
  --text: #2a251e;
  --muted: #62594c;
  --subtle: #817563;
  --line: #d2c3ae;
  --brand: #176d64;
  --brand-strong: #07594f;
  --gold: #9b5e19;
  --accent: #75538e;
  --focus: #8c4f09;
  --danger: #ad3e30;
  --ok: #216a44;
  --shadow: 0 22px 55px rgb(70 52 28 / 0.13);
}
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --bg: #f5efe4;
    --bg-soft: #ebe1d0;
    --panel: #fffaf0;
    --panel-2: #f4eadb;
    --text: #2a251e;
    --muted: #62594c;
    --subtle: #817563;
    --line: #d2c3ae;
    --brand: #176d64;
    --brand-strong: #07594f;
    --gold: #9b5e19;
    --accent: #75538e;
    --focus: #8c4f09;
    --danger: #ad3e30;
    --ok: #216a44;
    --shadow: 0 22px 55px rgb(70 52 28 / 0.13);
  }
}
body {
  font-family: var(--sans);
  font-weight: 450;
  letter-spacing: 0.002em;
  background:
    radial-gradient(circle at 9% -8%, rgb(230 191 125 / 0.18), transparent 31rem),
    radial-gradient(circle at 92% 2%, rgb(174 227 209 / 0.15), transparent 28rem),
    repeating-linear-gradient(90deg, transparent 0, transparent 95px, rgb(255 255 255 / 0.012) 96px),
    linear-gradient(145deg, var(--bg), var(--bg-soft));
  background-attachment: fixed;
}
a { text-underline-offset: 0.18em; text-decoration-thickness: 0.08em; }
a:hover { color: var(--brand); }
h1, h2, h3, .brand strong, .shelf-card strong, .pathway-card strong {
  font-family: var(--serif);
  font-weight: 600;
  letter-spacing: -0.038em;
}
h1 { font-size: clamp(2.75rem, 6.6vw, 5.75rem); line-height: 0.98; }
h2 { font-size: clamp(1.75rem, 3vw, 2.7rem); line-height: 1.02; }
h3 { font-size: 1.2rem; line-height: 1.16; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 4px; box-shadow: 0 0 0 7px rgb(230 191 125 / 0.14); }

.site-header {
  min-height: 78px;
  padding: 12px clamp(16px, 4vw, 54px);
  border-bottom: 1px solid color-mix(in srgb, var(--line) 74%, transparent);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  box-shadow: 0 8px 30px rgb(0 0 0 / 0.08);
  backdrop-filter: blur(22px) saturate(1.1);
}
.brand { gap: 13px; }
.brand-mark {
  width: 48px;
  min-width: 48px;
  height: 48px;
  border: 1px solid color-mix(in srgb, var(--gold) 68%, transparent);
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 50%, transparent 0 33%, rgb(20 18 15 / 0.24) 34% 36%, transparent 37%),
    conic-gradient(from 18deg, var(--gold), #f4dfad, var(--brand), var(--gold));
  color: #17130e;
  box-shadow: inset 0 0 0 4px rgb(255 255 255 / 0.23), 0 9px 20px rgb(0 0 0 / 0.18);
  font-family: var(--serif);
  font-size: 1.3rem;
  font-weight: 800;
}
.brand strong { font-size: 1.08rem; letter-spacing: -0.03em; }
.brand small { font-size: 0.7rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--subtle); }
.site-nav { gap: 2px; padding: 4px; border: 1px solid color-mix(in srgb, var(--line) 72%, transparent); border-radius: 999px; background: rgb(255 255 255 / 0.025); }
.site-nav a, .theme-toggle {
  position: relative;
  min-height: 38px;
  padding: 8px 12px;
  border: 1px solid transparent;
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 760;
  letter-spacing: 0.015em;
  transition: color 180ms ease, background 180ms ease, border-color 180ms ease, transform 180ms ease;
}
.site-nav a[aria-current="page"], .site-nav a:hover, .theme-toggle:hover {
  border-color: color-mix(in srgb, var(--brand) 36%, var(--line));
  background: color-mix(in srgb, var(--brand) 13%, var(--panel));
  color: var(--text);
}
.site-nav a:hover, .theme-toggle:hover { transform: translateY(-1px); }
.theme-toggle { min-width: 46px; margin-left: 2px; }

main { width: min(1240px, calc(100% - 40px)); }
.hero { gap: 30px; padding: clamp(42px, 7vw, 96px) 0 50px; }
.surface, .hero-copy, .stat-panel, .panel, .browser, .item-hero, .notice-card {
  border-color: color-mix(in srgb, var(--line) 83%, transparent);
  background:
    linear-gradient(135deg, rgb(255 255 255 / 0.075), transparent 46%),
    linear-gradient(180deg, color-mix(in srgb, var(--panel) 94%, transparent), var(--panel));
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
}
.hero-copy { position: relative; overflow: clip; padding: clamp(30px, 5.2vw, 62px); }
.hero-copy::after {
  content: "✦";
  position: absolute;
  right: clamp(18px, 4vw, 50px);
  top: clamp(15px, 3vw, 32px);
  color: color-mix(in srgb, var(--gold) 60%, transparent);
  font: 5.2rem/1 var(--serif);
  opacity: 0.18;
  pointer-events: none;
}
.eyebrow { color: var(--gold); font-size: 0.7rem; letter-spacing: 0.18em; font-weight: 850; }
.eyebrow::before { content: "✦"; margin-right: 0.56em; font-size: 0.85em; }
.lede { max-width: 720px; color: var(--muted); font-size: clamp(1.05rem, 1.8vw, 1.25rem); line-height: 1.7; }
.hero-search { margin: 30px 0 20px; }
.field { font-size: 0.84rem; letter-spacing: 0.02em; }
input, select {
  border-color: color-mix(in srgb, var(--line) 86%, transparent);
  border-radius: 14px;
  background: color-mix(in srgb, var(--bg-soft) 84%, transparent);
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.05);
  transition: border-color 180ms ease, box-shadow 180ms ease, background 180ms ease;
}
input:hover, select:hover { border-color: color-mix(in srgb, var(--brand) 52%, var(--line)); }
input:focus, select:focus { border-color: var(--brand); box-shadow: 0 0 0 4px rgb(174 227 209 / 0.12); outline: none; }
.button, button, .chip, .tag-link {
  border-color: color-mix(in srgb, var(--line) 88%, transparent);
  border-radius: 999px;
  background: linear-gradient(180deg, rgb(255 255 255 / 0.07), rgb(255 255 255 / 0.015)), var(--panel-2);
  font-size: 0.9rem;
  font-weight: 760;
  letter-spacing: 0.01em;
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.07), 0 4px 12px rgb(0 0 0 / 0.08);
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease, background 180ms ease;
}
.button:hover, button:hover, .chip:hover, .tag-link:hover {
  color: var(--text);
  border-color: color-mix(in srgb, var(--brand) 62%, var(--line));
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.12), 0 10px 24px rgb(0 0 0 / 0.16);
  transform: translateY(-2px);
}
.button.primary, button.primary {
  background: linear-gradient(135deg, #2f887a, #7bbfaf 54%, #d2ad70);
  color: #10100d;
  font-weight: 850;
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.42), 0 12px 26px rgb(28 103 90 / 0.2);
}
.button.primary::before, button.primary::before { content: "✦"; font-size: 0.85em; }
.stat-panel { padding: 24px; gap: 13px; }
.stat { border-color: color-mix(in srgb, var(--line) 82%, transparent); border-radius: 18px; background: rgb(255 255 255 / 0.035); }
.stat strong { font-family: var(--serif); color: var(--gold); font-weight: 600; }

.section, .page { padding: 44px 0; }
.section-head { margin-bottom: 24px; }
.section-head h2, .page-title h1 { position: relative; }
.section-head h2::after, .page-title h1::after { content: ""; display: block; width: 56px; height: 2px; margin-top: 16px; border-radius: 99px; background: linear-gradient(90deg, var(--gold), var(--brand)); }
.page-title { margin: 44px 0 28px; }
.page-title p { max-width: 760px; font-size: 1.06rem; line-height: 1.75; }
.shelf-grid, .card-grid, .pathway-grid { gap: 18px; }
.shelf-card, .pathway-card, .card {
  border-color: color-mix(in srgb, var(--line) 84%, transparent);
  border-radius: 26px;
  background: linear-gradient(150deg, rgb(255 255 255 / 0.075), transparent 44%), var(--panel);
  box-shadow: 0 12px 30px rgb(0 0 0 / 0.12);
  transition: transform 210ms cubic-bezier(.2,.75,.2,1), border-color 210ms ease, box-shadow 210ms ease, background 210ms ease;
}
.shelf-card, .pathway-card { min-height: 185px; padding: 23px; }
.shelf-card strong, .pathway-card strong { font-size: 1.52rem; }
.shelf-card:hover, .pathway-card:hover, .card:hover {
  transform: translateY(-6px);
  border-color: color-mix(in srgb, var(--brand) 72%, var(--line));
  box-shadow: 0 24px 48px rgb(0 0 0 / 0.22);
  background: linear-gradient(150deg, rgb(174 227 209 / 0.10), transparent 47%), var(--panel);
}
.card-media { background: linear-gradient(135deg, color-mix(in srgb, var(--brand) 24%, var(--panel)), color-mix(in srgb, var(--gold) 18%, var(--panel))); }
.card-media img { transition: transform 400ms ease, opacity 280ms ease; }
.card:hover .card-media img { transform: scale(1.045); opacity: 1; }
.media-pill { border: 1px solid rgb(255 255 255 / 0.24); background: rgb(18 17 14 / 0.76); backdrop-filter: blur(9px); font-size: 0.74rem; letter-spacing: 0.04em; text-transform: uppercase; }
.card-body { padding: 20px; }
.card-footer { padding: 13px 20px; background: rgb(255 255 255 / 0.018); }
.meta-strip span, .status-badge, .badge { border-color: color-mix(in srgb, var(--line) 86%, transparent); background: rgb(255 255 255 / 0.04); }
.tag-link, .chip { color: var(--muted); font-size: 0.78rem; }

.browser, .item-hero { border-radius: 30px; }
.item-hero { gap: 34px; padding: clamp(28px, 5vw, 54px); }
.item-cover { border-radius: 22px; box-shadow: 0 16px 35px rgb(0 0 0 / 0.2); }
.panel { border-radius: 24px; padding: 25px; }
.notice-card { border-color: color-mix(in srgb, var(--gold) 50%, var(--line)); }
.timeline-list li, .editorial-map div, .spotlight-list a, .quality-list article, .prev-next a { border-color: color-mix(in srgb, var(--line) 85%, transparent); background: rgb(255 255 255 / 0.032); }
.prev-next a:hover, .spotlight-list a:hover { border-color: var(--brand); color: var(--text); }
.table-wrap { border-color: color-mix(in srgb, var(--line) 88%, transparent); border-radius: 20px; background: rgb(255 255 255 / 0.018); }
th { color: var(--gold); font-size: 0.72rem; letter-spacing: 0.14em; }
tr:hover td { background: rgb(255 255 255 / 0.028); }

.player-stage { border-color: color-mix(in srgb, var(--line) 86%, transparent); background: color-mix(in srgb, var(--bg-soft) 88%, var(--panel)); box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.045); }
.document-browser { border-color: color-mix(in srgb, var(--line) 86%, transparent); background: color-mix(in srgb, var(--panel-2) 92%, transparent); }
.document-address { border-color: color-mix(in srgb, var(--line) 86%, transparent); background: var(--bg-soft); }
.playlist-button { border-radius: 15px; }
.playlist-button[aria-current="true"] { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 14%, var(--panel-2)); }

.image-gallery { scroll-margin-top: 104px; }
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(158px, 1fr)); gap: 14px; }
.photo-card { display: block; min-width: 0; padding: 0; overflow: hidden; border-radius: 17px; text-align: left; color: var(--text); background: var(--panel-2); }
.photo-card:hover { color: var(--text); }
.photo-card img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; background: var(--bg-soft); transition: transform 240ms ease, filter 240ms ease; }
.photo-card:hover img { transform: scale(1.04); filter: saturate(1.08); }
.photo-caption { display: grid; gap: 3px; padding: 10px 11px 12px; }
.photo-caption strong { overflow: hidden; font-size: 0.78rem; line-height: 1.25; text-overflow: ellipsis; white-space: nowrap; }
.photo-caption small { overflow: hidden; color: var(--subtle); font-size: 0.68rem; text-overflow: ellipsis; white-space: nowrap; }
.image-lightbox { width: min(1040px, calc(100% - 28px)); max-width: 1040px; max-height: min(900px, calc(100dvh - 28px)); margin: auto; padding: 0; overflow: hidden; border: 1px solid color-mix(in srgb, var(--brand) 55%, var(--line)); border-radius: 22px; color: var(--text); background: var(--panel); box-shadow: 0 32px 100px rgb(0 0 0 / 0.58); }
.image-lightbox::backdrop { background: rgb(7 8 7 / 0.78); backdrop-filter: blur(7px); }
.image-lightbox-bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 14px; border-bottom: 1px solid var(--line); background: var(--panel-2); }
.image-lightbox-bar .eyebrow { max-width: calc(100% - 110px); margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.image-lightbox > img { display: block; width: 100%; max-height: calc(100dvh - 116px); object-fit: contain; background: #080806; }
.availability-filters { display: grid; gap: 8px; margin: 0; padding: 13px; border: 1px solid color-mix(in srgb, var(--line) 85%, transparent); border-radius: 16px; background: rgb(255 255 255 / 0.024); }
.availability-filters legend { padding: 0 5px; color: var(--gold); font-size: 0.76rem; font-weight: 800; letter-spacing: 0.07em; text-transform: uppercase; }
.availability-filters label { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 0.84rem; font-weight: 700; }
.availability-filters input { width: 17px; min-height: 17px; accent-color: var(--brand-strong); }
.live-arrivals { scroll-margin-top: 104px; }
.live-arrival-card { border-color: color-mix(in srgb, var(--gold) 44%, var(--line)); }

.site-footer { width: min(1240px, calc(100% - 40px)); margin-top: 62px; padding-top: 28px; border-top-color: color-mix(in srgb, var(--gold) 28%, var(--line)); }
.site-footer strong { font-family: var(--serif); font-size: 1.1rem; }
.footer-links a { color: var(--muted); }
.footer-links a:hover { color: var(--brand); }
.medical-notice { color: var(--gold); }

@media (max-width: 980px) {
  main { width: min(100% - 28px, 1240px); }
  .site-header { gap: 10px; }
  .site-nav a { padding-inline: 10px; }
}
@media (max-width: 680px) {
  .site-header { min-height: 70px; padding: 10px 12px; }
  .site-nav { gap: 3px; padding: 3px; scroll-snap-type: x proximity; }
  .site-nav a { scroll-snap-align: start; font-size: 0.8rem; }
  .theme-toggle { min-width: 42px; padding-inline: 8px; }
  .hero { padding-top: 30px; gap: 18px; }
  .hero-copy { padding: 28px 22px; }
  .section, .page { padding: 31px 0; }
  .section-head.split { align-items: flex-start; flex-direction: column; }
  .reader-actions { justify-content: flex-start; }
  .site-footer { width: min(100% - 28px, 1240px); margin-top: 44px; }
}
