/* ═══════════════════════════════════════════════
   LYON HUANG — SHARED CASE STUDY STYLESHEET
   Matches portfolio dark design system exactly
   ═══════════════════════════════════════════════ */

/* ── TOKENS (page overrides; shared tokens live in assets/base.css) ── */
:root {
  --accent-dim: rgba(245,183,49,0.10);
  --max-w:      860px;        /* narrower for long-form reading */
  --max-w-wide: 1100px;
}

/* ── BASE — reset, ::selection, a, and cursor styling are shared via assets/base.css.
   Only the case-study-specific body (long-form line-height) and rounded img stay here. ── */
body {
  background-color: var(--bg);
  background-image: var(--grain-tile);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-weight: 300;
  line-height: 1.75;
  overflow-x: hidden;
  cursor: none;
}
img { display: block; max-width: 100%; border-radius: var(--radius); }

/* ── NAV — now shared via assets/nav.css + assets/nav.js (injected into #site-nav) ── */

/* ── CASE STUDY HERO ── */
.cs-hero {
  min-height: 72vh;
  display: flex; flex-direction: column; justify-content: flex-end;
  align-items: center;
  padding: 0 3rem 5rem;
  position: relative; overflow: hidden;
  border-bottom: 1px solid var(--border);
  text-align: center;
}
.cs-hero::before {
  content: '';
  position: absolute; bottom: 0; left: 0; right: 0; top: 0;
  background: radial-gradient(ellipse at 20% 80%, rgba(245,183,49,.05) 0%, transparent 60%);
  pointer-events: none;
}
.cs-back {
  display: inline-flex; align-items: center; gap: .6rem;
  font-family: var(--font-mono); font-size: .7rem;
  letter-spacing: .16em; text-transform: uppercase;
  color: var(--text-secondary);
  margin-bottom: 3.5rem;
  transition: color .2s;
  opacity: 0; animation: fadeUp .6s .1s var(--ease-out) forwards;
}
.cs-back:hover { color: var(--accent); }
.cs-client-badge {
  display: inline-flex; align-items: center; gap: .5rem;
  font-family: var(--font-mono); font-size: .65rem;
  letter-spacing: .2em; text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.5rem;
  opacity: 0; animation: fadeUp .7s .2s var(--ease-out) forwards;
}
.cs-client-badge::before {
  content: ''; display: block; width: 20px; height: 1px; background: var(--accent);
}
.cs-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 6vw, 6rem);
  line-height: 1.0; letter-spacing: -.025em;
  color: var(--text-primary);
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 2.5rem;
  opacity: 0; animation: fadeUp .8s .3s var(--ease-out) forwards;
}
.cs-hero h1 em { font-style: italic; color: var(--accent); }
.cs-meta-row {
  display: flex; gap: 3rem; flex-wrap: wrap;
  justify-content: center;
  opacity: 0; animation: fadeUp .7s .45s var(--ease-out) forwards;
}
.cs-meta-item { display: flex; flex-direction: column; gap: .25rem; align-items: center; }
.cs-meta-label {
  font-family: var(--font-mono); font-size: .6rem;
  letter-spacing: .2em; text-transform: uppercase; color: var(--text-secondary);
}
.cs-meta-value { font-size: .9rem; color: var(--text-primary); }

/* ── BODY CONTENT ── */
.cs-body {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 6rem 3rem;
}

/* intro lead paragraph */
.cs-lead {
  font-family: var(--font-display);
  font-size: clamp(1.3rem, 2.5vw, 1.7rem);
  line-height: 1.55; letter-spacing: -.01em;
  color: var(--text-primary);
  margin-bottom: 3rem;
}
.cs-lead em { font-style: italic; color: var(--accent); }

.cs-p {
  font-size: 1.05rem; color: var(--text-secondary);
  line-height: 1.85; margin-bottom: 1.5rem;
}
.cs-p strong { color: var(--text-primary); font-weight: 400; }
.cs-p a { color: var(--accent); border-bottom: 1px solid rgba(245,183,49,.3); transition: border-color .2s; }
.cs-p a:hover { border-color: var(--accent); }

/* section dividers within body */
.cs-section {
  margin-top: 5rem; padding-top: 5rem;
  border-top: 1px solid var(--border);
}
.cs-section-label {
  font-family: var(--font-mono); font-size: .65rem;
  letter-spacing: .25em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 1rem;
  display: flex; align-items: center; gap: .75rem;
}
.cs-section-label::before {
  content: ''; display: block; width: 20px; height: 1px; background: var(--accent);
}
.cs-section h2 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  line-height: 1.1; letter-spacing: -.02em;
  color: var(--text-primary); margin-bottom: 1.75rem;
}
.cs-section h2 em { font-style: italic; color: var(--accent); }
.cs-section h3 {
  font-family: var(--font-display);
  font-size: 1.3rem; line-height: 1.2;
  color: var(--text-primary); margin-bottom: .75rem; margin-top: 2.5rem;
}

/* pull quote */
.cs-quote {
  margin: 3rem 0;
  padding: 2rem 2.5rem;
  border-left: 2px solid var(--accent);
  background: var(--accent-dim);
  border-radius: 0 var(--radius) var(--radius) 0;
}
.cs-quote p {
  font-family: var(--font-display); font-style: italic;
  font-size: clamp(1.1rem, 2vw, 1.4rem);
  line-height: 1.55; color: var(--text-primary);
}
.cs-quote cite {
  display: block; margin-top: .75rem;
  font-family: var(--font-mono); font-size: .65rem;
  letter-spacing: .12em; text-transform: uppercase;
  color: var(--text-muted); font-style: normal;
}

/* HMW highlight box */
.cs-hmw {
  margin: 2.5rem 0;
  padding: 2rem 2.5rem;
  border: 1px solid rgba(245,183,49,.25);
  border-radius: var(--radius);
  background: var(--accent-dim);
}
.cs-hmw-label {
  font-family: var(--font-mono); font-size: .6rem;
  letter-spacing: .2em; text-transform: uppercase;
  color: var(--accent); margin-bottom: .75rem;
}
.cs-hmw p {
  font-family: var(--font-display); font-style: italic;
  font-size: clamp(1.1rem, 2vw, 1.35rem);
  line-height: 1.5; color: var(--text-primary);
}

/* numbered list */
.cs-numbered {
  list-style: none; margin: 2rem 0;
  display: flex; flex-direction: column; gap: 1.25rem;
}
.cs-numbered li {
  display: grid; grid-template-columns: 2.5rem 1fr;
  gap: 1rem; align-items: start;
}
.cs-numbered li .num {
  font-family: var(--font-mono); font-size: .7rem;
  letter-spacing: .1em; color: var(--accent);
  padding-top: .25rem;
}
.cs-numbered li .num-text {
  font-size: 1rem; color: var(--text-secondary); line-height: 1.7;
}
.cs-numbered li .num-text strong { color: var(--text-primary); font-weight: 400; }

/* concept cards (3-up) */
.cs-concepts {
  display: grid; grid-template-columns: repeat(3,1fr);
  gap: 1.25rem; margin: 2.5rem 0;
}
.cs-concept-card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.5rem;
  transition: border-color .25s, background .25s;
}
.cs-concept-card:hover { border-color: var(--border-hover); background: var(--bg-card-hover); }
.cs-concept-card .cc-num {
  font-family: var(--font-mono); font-size: .6rem;
  letter-spacing: .18em; color: var(--accent); margin-bottom: .6rem;
}
.cs-concept-card h4 {
  font-family: var(--font-display); font-size: 1.1rem;
  color: var(--text-primary); margin-bottom: .5rem;
}
.cs-concept-card p {
  font-size: .85rem; color: var(--text-secondary); line-height: 1.65;
}

/* image pair (before/after) */
.cs-img-pair {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 1rem; margin: 2.5rem 0;
}
.cs-img-pair figure { display: flex; flex-direction: column; gap: .6rem; }
.cs-img-pair figcaption {
  font-family: var(--font-mono); font-size: .62rem;
  letter-spacing: .14em; text-transform: uppercase;
  color: var(--text-muted);
}

/* single wide image */
.cs-img {
  margin: 2.5rem 0;
  background: var(--surface); border-radius: var(--radius);
  border: 1px solid var(--border); overflow: hidden;
}
.cs-img img { width: 100%; }
.cs-img figcaption {
  padding: .85rem 1.25rem;
  font-family: var(--font-mono); font-size: .62rem;
  letter-spacing: .14em; text-transform: uppercase;
  color: var(--text-muted); border-top: 1px solid var(--border);
}

/* image placeholder (grey box with label) */
.cs-img-placeholder {
  aspect-ratio: 16/9;
  background: var(--surface);
  border-radius: var(--radius);
  border: 1px dashed var(--border);
  display: flex; align-items: center; justify-content: center;
}
.cs-img-placeholder span {
  font-family: var(--font-mono); font-size: .65rem;
  letter-spacing: .15em; text-transform: uppercase;
  color: var(--text-muted);
}

/* stat bar */
.cs-stats {
  display: grid; grid-template-columns: repeat(3,1fr);
  gap: 0; margin: 4rem 0;
  border: 1px solid var(--border); border-radius: var(--radius);
  overflow: hidden;
}
.cs-stat {
  padding: 2rem; border-right: 1px solid var(--border);
  display: flex; flex-direction: column; gap: .4rem;
}
.cs-stat:last-child { border-right: none; }
.cs-stat .stat-num {
  font-family: var(--font-display); font-style: italic;
  font-size: clamp(2rem, 4vw, 3rem); color: var(--accent);
  line-height: 1;
}
.cs-stat .stat-label {
  font-family: var(--font-mono); font-size: .65rem;
  letter-spacing: .14em; text-transform: uppercase;
  color: var(--text-secondary);
}

/* outcome/takeaway box */
.cs-outcome {
  margin: 3rem 0; padding: 2.5rem;
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius);
}
.cs-outcome-label {
  font-family: var(--font-mono); font-size: .62rem;
  letter-spacing: .2em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 1rem;
}
.cs-outcome p {
  font-size: 1rem; color: var(--text-secondary); line-height: 1.8;
}
.cs-outcome p strong { color: var(--text-primary); font-weight: 400; }
.cs-outcome-links { margin-top: 1rem; }

/* external link button */
.cs-link-btn {
  display: inline-flex; align-items: center; gap: .6rem;
  font-family: var(--font-mono); font-size: .72rem;
  letter-spacing: .1em; text-transform: uppercase;
  color: var(--accent);
  border: 1px solid rgba(245,183,49,.3);
  padding: .75rem 1.4rem; border-radius: var(--radius);
  transition: background .2s, border-color .2s, transform .2s var(--ease-out);
  margin-right: .75rem; margin-top: .5rem;
}
.cs-link-btn:hover { background: var(--accent-dim); border-color: var(--accent); transform: translateY(-2px); }

/* ── NEXT PROJECT FOOTER ── */
.cs-next {
  border-top: 1px solid var(--border);
  max-width: var(--max-w-wide); margin: 0 auto;
  padding: 5rem 3rem 7rem;
  display: flex; justify-content: center; align-items: center;
  text-align: center;
}
.cs-next-label {
  font-family: var(--font-mono); font-size: .65rem;
  letter-spacing: .2em; text-transform: uppercase; color: var(--accent);
  margin-bottom: .6rem;
}
.cs-next-title {
  font-family: var(--font-display); font-size: clamp(1.5rem, 3vw, 2.4rem);
  color: var(--text-primary); transition: color .2s;
}
.cs-next-link:hover .cs-next-title { color: var(--accent); }

/* ── PAGE FOOTER — now shared via assets/footer.css + assets/footer.js (injected into #site-footer) ── */

/* ── REVEAL ANIMATIONS ── */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .8s var(--ease-out), transform .8s var(--ease-out); }
.reveal.in-view { opacity: 1; transform: none; }
.reveal-group > * { opacity: 0; transform: translateY(20px); transition: opacity .7s var(--ease-out), transform .7s var(--ease-out); }
.reveal-group.in-view > *:nth-child(1) { opacity:1; transform:none; transition-delay:0s; }
.reveal-group.in-view > *:nth-child(2) { opacity:1; transform:none; transition-delay:.1s; }
.reveal-group.in-view > *:nth-child(3) { opacity:1; transform:none; transition-delay:.2s; }

@keyframes fadeUp { to { opacity: 1; transform: none; } }

/* ── RESPONSIVE ── */
@media (max-width: 900px) {
  nav, nav.scrolled { padding: 1rem 1.5rem; }
  .cs-hero { padding: 0 1.5rem 4rem; }
  .cs-body { padding: 4rem 1.5rem; }
  .cs-concepts { grid-template-columns: 1fr; }
  .cs-img-pair { grid-template-columns: 1fr; }
  .cs-stats { grid-template-columns: 1fr; }
  .cs-stat { border-right: none; border-bottom: 1px solid var(--border); }
  .cs-stat:last-child { border-bottom: none; }
  .cs-next { padding: 4rem 1.5rem 5rem; }
}
@media (max-width: 600px) {
  .nav-links { gap: 1.5rem; }
  .cs-hero h1 { font-size: 2.5rem; }
  .cs-meta-row { gap: 1.5rem; }
  #cursor-dot, #cursor-ring { display: none; }
  body { cursor: auto; }
}

/* ── CHAPTERS (shared across all case studies) ───────────────────────────
   Unified chapter system: "Chapter N" label (.cs-section-label) → eyebrow
   (platforms · dates) → .ch-title heading → intro → Problem/Process/Outcome
   cards. Ported out of the Disney case study so every work page shares it. */

/* On this page (TOC) */
.toc {
  margin: 3rem 0 1rem;
  padding: 1.5rem 1.75rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.toc .cs-section-label { margin-bottom: 1.25rem; }
.toc-links {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: .75rem 1.25rem;
}
.toc-links a {
  font-family: var(--font-mono);
  font-size: .7rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--text-secondary);
  padding: .75rem .9rem;
  border: 1px solid var(--border-tag);
  border-radius: var(--radius);
  transition: background .2s, border-color .2s, color .2s, transform .2s var(--ease-out);
}
.toc-links a:hover {
  background: var(--accent-dim);
  border-color: rgba(245,183,49,0.3);
  color: var(--accent);
  transform: translateY(-2px);
}

/* Chapter header */
.chapter { display: block; }
.ch-eyebrow {
  font-family: var(--font-mono);
  font-size: .62rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 1rem;
}
.ch-title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  line-height: 1.1;
  letter-spacing: -.02em;
  color: var(--text-primary);
  margin-bottom: 2rem;
}
.ch-title em { font-style: italic; color: var(--accent); }

/* Three-card grid (Problem / Process / Outcome) */
.ch-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin: 2.5rem 0;
}
.ch-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  transition: border-color .25s, background .25s;
}
.ch-card:hover { border-color: var(--border-hover); background: var(--bg-card-hover); }
.ch-card-tag {
  font-family: var(--font-mono);
  font-size: .58rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  padding: .3rem .7rem;
  border-radius: 2px;
  display: inline-block;
  margin-bottom: .75rem;
}
.tag-problem  { background: rgba(210,80,50,.12);  color: #e07050; }
.tag-process  { background: rgba(80,130,210,.12); color: #6a9fd8; }
.tag-outcome  { background: rgba(80,180,100,.12); color: #60c070; }
.ch-card h4 {
  font-family: var(--font-display);
  font-size: 1.05rem;
  color: var(--text-primary);
  margin-bottom: .5rem;
  line-height: 1.3;
}
.ch-card p {
  font-size: .875rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* Role block */
.ch-role {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-left: 2px solid var(--accent);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 1.25rem 1.5rem;
  margin-top: 2.5rem;
}
.ch-role-label {
  font-family: var(--font-mono);
  font-size: .6rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: .5rem;
}
.ch-role p { font-size: .9rem; color: var(--text-secondary); line-height: 1.75; }
.ch-role p strong { color: var(--text-primary); font-weight: 400; }

/* Section-label dash marker: default on (main chapter headings); the --sub
   variant drops it, for the TOC label and sub-section labels within a chapter. */
.cs-section-label--sub::before { display: none; }

/* Button arrow glyph (shared with the index CTA/resume buttons). */
.btn-arrow { width: .95em; height: .95em; flex: 0 0 auto; }

/* Overview hero video (match app UI white; video fills inset width) */
.cs-img.cs-img--hero-video { background: #fff; }
.cs-img--hero-video .cs-hero-video-frame {
  background: #fff;
  box-sizing: border-box;
  padding: clamp(0.75rem, 2.2vw, 1.75rem);
}
.cs-img--hero-video .cs-hero-video-inset {
  width: 100%;
}
.cs-img--hero-video video {
  width: 100%;
  height: auto;
  display: block;
}
/* Dark variant — for videos with a dark app UI (e.g. Pluto TV) */
.cs-img.cs-img--hero-video--dark,
.cs-img--hero-video--dark .cs-hero-video-frame { background: #000; }

@media (max-width: 900px) {
  .toc { padding: 1.25rem; }
  .toc-links { grid-template-columns: 1fr; }
  .ch-cards { grid-template-columns: 1fr; }
}

/* ── SPLASH HERO — full-bleed photo + scrims ────────────────────────────
   Shared across case studies. Each page sets its own photo via the
   --hero-img custom property: <div class="cs-hero cs-hero--splash"
   style="--hero-img:url('…')">. Photo sits on the element; scrim layers
   live on ::after so one bad gradient can't drop the whole stack. */
.cs-hero--splash {
  border-bottom: 1px solid var(--bg);
  background-color: var(--bg);
  background-image: var(--hero-img);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}
.cs-hero--splash::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  box-shadow: inset 0 -28px 36px -14px rgba(8, 8, 7, 0.32);
  /* Background layers: top = grain (assets/grain.css); ellipses use % only
     (min() can invalidate a whole rule in some engines). */
  background:
    var(--grain-tile) 0 0 / 300px 300px repeat,
    radial-gradient(ellipse 92% 38% at 50% 61%, rgba(8, 8, 7, 0.88) 0%, rgba(8, 8, 7, 0.35) 45%, rgba(8, 8, 7, 0) 72%),
    linear-gradient(to top, rgba(8, 8, 7, 1) 0%, rgba(8, 8, 7, 0.94) 5%, rgba(8, 8, 7, 0.82) 16%, rgba(8, 8, 7, 0.5) 38%, rgba(8, 8, 7, 0.22) 58%, rgba(8, 8, 7, 0) 78%),
    radial-gradient(ellipse at 20% 80%, rgba(245, 183, 49, 0.06) 0%, rgba(8, 8, 7, 0) 60%);
}
.cs-hero--splash > * { position: relative; z-index: 1; }
.cs-hero--splash::before { content: none; }

/* ── CAROUSEL + LIGHTBOX (shared component) ─────────────────────────────
   Data-driven engine lives in assets/carousel.js; pages carry markup +
   a small window.CS_CAROUSELS config. Concept cards (tabbed variant) swap
   the active slide set; single images open the lightbox in zoom-only mode. */

/* Concept cards act as tabs for the shared concept carousel */
.ch1-concept-card {
  cursor: pointer;
  transition: border-color .2s, background .2s, transform .2s var(--ease-out);
}
.ch1-concept-card:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.ch1-concept-card[aria-pressed="true"] {
  border-color: var(--border-hover);
  background: var(--bg-card-hover);
}
.ch1-concept-card[aria-pressed="true"] .cc-num { color: var(--accent); }

/* Media slot: placeholder + carousel stack as absolute layers */
.ch1-concept-media {
  position: relative;
  width: 100%;
  aspect-ratio: 16/10;
  border-radius: var(--radius);
  overflow: hidden;
}
.ch1-concept-media > .ch1-media-layer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  box-sizing: border-box;
}
.ch1-concept-media .cs-img-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: auto;
  width: 100%;
  height: 100%;
  border-radius: 0;
}
/* beat .cs-img img { width:100% } so carousel images stay contained */
.ch1-concept-media .ch1-carousel-img { width: auto; max-width: 100%; }

.ch1-carousel { background: var(--bg-card); display: flex; flex-direction: column; }
.ch1-carousel-subtitle {
  font-family: var(--font-mono); font-size: .65rem; letter-spacing: .18em;
  text-transform: uppercase; color: var(--text-secondary);
  padding: .65rem 1rem .35rem; flex-shrink: 0; margin: 0;
}
.ch1-carousel-viewport {
  flex: 1; min-height: 0; overflow: hidden; position: relative;
  background: var(--surface); display: flex; align-items: center; justify-content: center;
  padding: clamp(1rem, 2.8vw, 1.65rem) clamp(1.1rem, 2.4vw, 1.85rem); box-sizing: border-box;
}
.ch1-carousel-img {
  width: auto; height: auto; max-width: 100%; max-height: 100%;
  object-fit: contain; display: block; transition: opacity .25s ease; cursor: zoom-in;
}
@media (prefers-reduced-motion: reduce) { .ch1-carousel-img { transition: none; } }
.ch1-carousel-controls {
  display: flex; align-items: center; justify-content: center; gap: 1rem;
  padding: .65rem 1.25rem .85rem; border-top: 1px solid var(--border); flex-shrink: 0;
}
.ch1-carousel-btn {
  display: flex; align-items: center; justify-content: center; width: 32px; height: 32px;
  background: var(--surface); border: 1px solid var(--border); border-radius: 50%;
  color: var(--text-secondary); cursor: pointer;
  transition: background .2s, border-color .2s, color .2s;
}
.ch1-carousel-btn:hover { background: var(--accent-dim); border-color: rgba(245,183,49,.3); color: var(--accent); }
.ch1-carousel-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.ch1-carousel-dots {
  display: flex; gap: .5rem; flex-wrap: wrap; justify-content: center;
  max-width: min(100%, 14rem); row-gap: .35rem;
}
.ch1-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--border); transition: background .2s; }
.ch1-dot.is-active { background: var(--accent); }

.ch1-lightbox {
  position: fixed; inset: 0; z-index: 200; display: flex; align-items: center; justify-content: center;
  padding: clamp(1rem, 4vw, 2.5rem); box-sizing: border-box;
  background: rgba(8,8,7,.92); backdrop-filter: blur(8px);
}
.ch1-lightbox[hidden] { display: none !important; }
.ch1-lightbox-close {
  position: absolute; top: 1rem; right: 1rem; width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  background: var(--surface); border: 1px solid var(--border); border-radius: 50%;
  color: var(--text-primary); font-family: var(--font-sans); font-size: 1.35rem; line-height: 1;
  cursor: pointer; z-index: 3; transition: background .2s, border-color .2s, color .2s;
}
.ch1-lightbox-close:hover { background: var(--accent-dim); border-color: rgba(245,183,49,.35); color: var(--accent); }
.ch1-lightbox-close:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.ch1-lightbox-subtitle {
  position: absolute; top: 1.35rem; left: 50%; transform: translateX(-50%); z-index: 2; margin: 0;
  max-width: min(90vw, 28rem); padding: 0 3rem; box-sizing: border-box; text-align: center;
  font-family: var(--font-mono); font-size: .65rem; letter-spacing: .18em; text-transform: uppercase;
  color: var(--text-secondary); pointer-events: none;
}
.ch1-lightbox-nav {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 2;
  display: flex; align-items: center; justify-content: center; width: 48px; height: 48px;
  background: var(--surface); border: 1px solid var(--border); border-radius: 50%;
  color: var(--text-secondary); cursor: pointer; transition: background .2s, border-color .2s, color .2s;
}
.ch1-lightbox-nav:hover { background: var(--accent-dim); border-color: rgba(245,183,49,.3); color: var(--accent); }
.ch1-lightbox-nav:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.ch1-lightbox-prev { left: clamp(.5rem, 2.5vw, 1.35rem); }
.ch1-lightbox-next { right: clamp(.5rem, 2.5vw, 1.35rem); }
.ch1-lightbox-img {
  max-width: min(96vw, 1400px); max-height: 88vh; width: auto; height: auto;
  object-fit: contain; border-radius: var(--radius); box-shadow: 0 24px 80px rgba(0,0,0,.55);
  position: relative; z-index: 1;
}
.ch1-lightbox-dots {
  position: absolute; bottom: clamp(1rem, 3vw, 1.75rem); left: 50%; transform: translateX(-50%);
  z-index: 2; max-width: min(90vw, 14rem); pointer-events: auto;
}
.ch1-lightbox-dots .ch1-dot { cursor: pointer; }
