/* dylanmacgregor.com - one stylesheet.
   Tokens match lcastudios.ca (V157) so the two sites read as one family:
   black page, Poppins at 400/500 (no bold), LCA action blue, glass panels. */

:root {
  color-scheme: dark;
  --ink:        #f5f5f5;
  --ink-soft:   #a3a3a3;
  --paper:      #000000;
  --surface:    #141414;
  --rule:       #2a2a2a;
  --action:       #2563eb;
  --action-hover: #1d4ed8;
  --on-action:    #ffffff;
  --link-hover:   #7cb3ff;
  --ok:         #22c55e;
  --bad:        #ef4444;

  --glass:        rgba(20, 20, 20, 0.55);
  --glass-edge:   rgba(255, 255, 255, 0.14);
  --glass-blur:   blur(18px) saturate(140%);

  --radius:     10px;
  --radius-lg:  14px;
  --measure:    36rem;
  --wide:       72rem;
  --gutter:     clamp(1.125rem, 0.75rem + 1.5vw, 1.75rem);
  --bar-h:      4rem;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: var(--bar-h); }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
h1, h2, h3, h4, strong, b, th { font-weight: 500; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Poppins", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 1rem;
  line-height: 1.6;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
}
main { flex: 1; }
img, video, iframe { max-width: 100%; display: block; }

a {
  color: var(--ink);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.25em;
  text-decoration-color: color-mix(in srgb, currentColor 35%, transparent);
}
a:hover { color: var(--link-hover); text-decoration-color: currentColor; }
:focus-visible { outline: 2px solid var(--link-hover); outline-offset: 3px; }

p { margin: 0 0 1em; }
.soft { color: var(--ink-soft); }
.wrap { width: 100%; max-width: var(--wide); margin: 0 auto; padding: 0 var(--gutter); }
.measure { max-width: var(--measure); }

/* ---------- Top bar ---------- */
.bar {
  position: sticky; top: 0; z-index: 20;
  height: var(--bar-h);
  background: rgba(0, 0, 0, 0.6);
  -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.bar--over { position: fixed; left: 0; right: 0; background: rgba(0, 0, 0, 0.25); border-bottom-color: transparent; transition: background 0.3s; }
.bar--over.is-solid { background: rgba(10, 10, 10, 0.88); border-bottom-color: var(--rule); }
.bar__in { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.bar__name { font-weight: 500; text-decoration: none; letter-spacing: 0.01em; white-space: nowrap; }
.bar__nav { display: flex; gap: 0.25rem; }
.bar__nav a {
  text-decoration: none; font-size: 0.92rem; color: var(--ink-soft);
  padding: 0.35rem 0.8rem; border-radius: 999px;
}
.bar__nav a:hover { color: var(--ink); background: rgba(255, 255, 255, 0.06); }
.bar__nav a[aria-current="page"] { color: var(--ink); background: rgba(255, 255, 255, 0.1); }
.bar__menu { display: none; }

@media (max-width: 46rem) {
  .bar__menu {
    display: inline-flex; align-items: center; justify-content: center;
    width: 2.6rem; height: 2.6rem; border-radius: 999px;
    background: none; border: 1px solid var(--glass-edge); color: var(--ink); cursor: pointer;
  }
  .bar__menu svg { width: 1.1rem; height: 1.1rem; }
  .bar__nav {
    position: absolute; top: calc(var(--bar-h) + 0.25rem); right: var(--gutter);
    flex-direction: column; min-width: 12rem; padding: 0.5rem;
    background: rgba(16, 16, 16, 0.96); border: 1px solid var(--glass-edge); border-radius: var(--radius-lg);
    -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur);
    display: none;
  }
  .bar__nav.is-open { display: flex; }
  .bar__nav a { padding: 0.6rem 0.9rem; font-size: 1rem; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  font: inherit; font-weight: 500; font-size: 0.98rem;
  padding: 0.7rem 1.35rem; border-radius: 999px; border: 1px solid transparent;
  background: var(--action); color: var(--on-action); text-decoration: none; cursor: pointer;
  transition: background 0.15s;
}
.btn:hover { background: var(--action-hover); color: var(--on-action); }
.btn--ghost { background: rgba(255, 255, 255, 0.06); border-color: var(--glass-edge); color: var(--ink); }
.btn--ghost:hover { background: rgba(255, 255, 255, 0.12); color: var(--ink); }
.btn[disabled] { opacity: 0.6; cursor: progress; }

/* ---------- Home hero (the one bold moment) ---------- */
.hero {
  position: relative; min-height: 100svh;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden; isolation: isolate;
}
.hero__media { position: absolute; inset: 0; z-index: -2; background: #000; }
.hero__media video, .hero__media img { width: 100%; height: 100%; object-fit: cover; transition: filter 0.9s ease, transform 0.9s ease; }
.hero.is-ready .hero__media video, .hero.is-ready .hero__media img { filter: blur(7px) brightness(0.82); transform: scale(1.06); }
.hero--intro .hero__copy { opacity: 0; transform: translateY(12px); transition: opacity 0.6s ease 0.15s, transform 0.6s ease 0.15s;
  animation: copy-failsafe 0s linear 3s forwards; } /* if the script never runs, show the copy anyway */
@keyframes copy-failsafe { to { opacity: 1; transform: none; } }
.hero--intro.is-ready .hero__copy { opacity: 1; transform: none; }
@media (max-width: 46rem) { .hero__media img { object-position: 38% 50%; } } /* keep the subject in frame on phones */
.hero__media--empty {
  background:
    radial-gradient(60rem 30rem at 75% 20%, rgba(37, 99, 235, 0.22), transparent 60%),
    radial-gradient(40rem 26rem at 10% 90%, rgba(255, 255, 255, 0.06), transparent 60%),
    #000;
}
.hero::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(to bottom, rgba(0,0,0,0.35) 0%, rgba(0,0,0,0.2) 45%, rgba(0,0,0,0.6) 100%);
}
.hero__in { width: 100%; padding-top: var(--bar-h); padding-bottom: 0; display: flex; justify-content: center; }

.hero__copy { max-width: 46rem; margin: 0 auto; text-align: center; text-shadow: 0 2px 18px rgba(0, 0, 0, 0.45); }
.hero__copy h1 {
  margin: 0 0 1rem; font-weight: 500; letter-spacing: -0.02em; line-height: 1.1;
  font-size: clamp(2.1rem, 1.2rem + 4vw, 4rem);
}
.hero__copy p { margin: 0 auto 2rem; max-width: 34rem; font-size: clamp(1.05rem, 0.95rem + 0.5vw, 1.3rem); color: #e6e6e6; }
.hero__copy .door { text-shadow: none; }
.door {
  display: inline-flex; align-items: center; justify-content: center; text-align: center;
  min-width: 17rem; padding: 1.05rem 2rem; border-radius: 999px;
  font-size: clamp(1.15rem, 1rem + 0.6vw, 1.45rem); font-weight: 500; line-height: 1.2; text-decoration: none;
  color: #0a0a0a; background: rgba(245, 245, 245, 0.92); border: 1px solid rgba(255, 255, 255, 0.6);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}
.door:hover { color: #0a0a0a; background: #ffffff; }
.door--primary { color: var(--on-action); background: var(--action); border-color: var(--action); }
.door--primary:hover { color: var(--on-action); background: var(--action-hover); }
@media (max-width: 40rem) { .hero__copy .door { min-width: 0; width: 100%; } }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Page sections ---------- */
.page-head { padding: clamp(2.5rem, 6vw, 4.5rem) 0 1.5rem; }
.page-head h1 {
  margin: 0 0 0.75rem; font-weight: 500; letter-spacing: -0.02em; line-height: 1.1;
  font-size: clamp(2rem, 1.3rem + 3vw, 3.4rem); max-width: 22ch;
}
.page-head .lead { font-size: clamp(1.02rem, 0.95rem + 0.35vw, 1.18rem); color: var(--ink-soft); max-width: 38rem; margin: 0; }

.section { padding: clamp(2rem, 5vw, 3.5rem) 0; }
.section + .section { border-top: 1px solid var(--rule); }
.section h2 { margin: 0 0 1rem; font-size: clamp(1.35rem, 1.1rem + 1vw, 1.8rem); letter-spacing: -0.01em; line-height: 1.2; }
.section h3 { margin: 0 0 0.4rem; font-size: 1.05rem; }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(1.5rem, 4vw, 3rem); align-items: start; }
@media (max-width: 52rem) { .split { grid-template-columns: 1fr; } }

.panel {
  background: var(--glass); border: 1px solid var(--glass-edge); border-radius: var(--radius-lg);
  -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur);
  padding: clamp(1.25rem, 3vw, 1.75rem);
}

/* ---------- Video frames ---------- */
.frame {
  position: relative; aspect-ratio: 16 / 9; width: 100%;
  border-radius: var(--radius-lg); overflow: hidden;
  background: var(--surface); border: 1px solid var(--rule);
}
.frame iframe, .frame video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; object-fit: cover; }
.frame--empty {
  display: grid; place-items: center; text-align: center; padding: 1.5rem;
  background: radial-gradient(30rem 18rem at 70% 20%, rgba(37, 99, 235, 0.16), transparent 65%), var(--surface);
  color: var(--ink-soft); font-size: 0.95rem;
}
.narrative-reel { margin: 0 0 2rem; }
.frame__note { display: block; margin-top: 0.6rem; font-size: 0.85rem; color: var(--ink-soft); }

/* Business: VSL then the form directly under it (short scroll). */
.pitch { display: grid; gap: 1.25rem; align-items: start; }
.pitch__more { margin-top: 2rem; }
.pitch__more h2 { font-size: 1.3rem; }
@media (min-width: 60rem) { .pitch { grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); } .pitch .form__row:has(select) { grid-template-columns: 1fr; } }

/* ---------- Package ---------- */
.package { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: clamp(1.5rem, 4vw, 3rem); }
@media (max-width: 52rem) { .package { grid-template-columns: 1fr; } }
.price { font-size: clamp(2.4rem, 1.8rem + 2.5vw, 3.4rem); font-weight: 500; letter-spacing: -0.02em; line-height: 1; margin: 0 0 0.35rem; }
.price small { font-size: 1rem; color: var(--ink-soft); font-weight: 400; letter-spacing: 0; }
.checks { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.6rem; }
.checks li { position: relative; padding-left: 1.6rem; }
.checks li::before {
  content: ""; position: absolute; left: 0.1rem; top: 0.55em;
  width: 0.55rem; height: 0.3rem; border-left: 2px solid var(--link-hover); border-bottom: 2px solid var(--link-hover);
  transform: rotate(-45deg);
}

.steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 1rem; counter-reset: step; }
.steps li { counter-increment: step; padding-top: 0.9rem; border-top: 1px solid var(--rule); }
.steps li::before { content: counter(step); display: block; color: var(--link-hover); font-size: 0.9rem; margin-bottom: 0.3rem; }
.steps p { color: var(--ink-soft); font-size: 0.92rem; margin: 0; }
@media (max-width: 60rem) { .steps { grid-template-columns: 1fr 1fr; } }
@media (max-width: 30rem) { .steps { grid-template-columns: 1fr; } }

.terms { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
.terms p { color: var(--ink-soft); margin: 0; font-size: 0.95rem; }
@media (max-width: 52rem) { .terms { grid-template-columns: 1fr; } }

/* ---------- Grids of work ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(18rem, 1fr)); gap: 1.25rem; }
.work__cap { margin-top: 0.6rem; }
.work__cap b { display: block; }
.tag {
  display: inline-block; font-size: 0.78rem; padding: 0.1rem 0.55rem; border-radius: 999px;
  border: 1px solid var(--glass-edge); color: var(--ink-soft); margin-left: 0.4rem; vertical-align: 0.1em;
}
.proof { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }
.proof p { color: var(--ink-soft); margin: 0; font-size: 0.95rem; }
@media (max-width: 40rem) { .proof { grid-template-columns: 1fr; } }

.stills { display: grid; grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr)); gap: 0.75rem; }
.stills img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border-radius: var(--radius); }
.stills__empty { aspect-ratio: 3 / 2; border-radius: var(--radius); border: 1px dashed var(--rule); display: grid; place-items: center; color: var(--ink-soft); font-size: 0.85rem; }

/* ---------- Tables (rates, kit) ---------- */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 0.97rem; }
th, td { text-align: left; padding: 0.7rem 0.75rem 0.7rem 0; border-bottom: 1px solid var(--rule); vertical-align: top; }
th { color: var(--ink-soft); font-size: 0.88rem; }
td.num { white-space: nowrap; font-weight: 500; }
td .soft { font-size: 0.88rem; }

.kit { display: grid; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); gap: 1.25rem 2rem; }
.kit ul { margin: 0; padding-left: 1.1rem; color: var(--ink-soft); }
.kit li { margin-bottom: 0.25rem; }
.kit h3 { color: var(--ink); }

/* ---------- Forms ---------- */
.form { display: grid; gap: 1rem; }
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 36rem) { .form__row { grid-template-columns: 1fr; } }
.field { display: grid; gap: 0.35rem; }
.field label { font-size: 0.9rem; color: var(--ink-soft); }
.field input, .field select, .field textarea {
  font: inherit; color: var(--ink); background: var(--surface);
  border: 1px solid var(--rule); border-radius: var(--radius); padding: 0.7rem 0.85rem; width: 100%;
}
.field textarea { min-height: 7rem; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--link-hover); }
.field--hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form__foot { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem; }
.form__status { margin: 0; font-size: 0.95rem; }
.form__status.is-ok { color: var(--ok); }
.form__status.is-bad { color: var(--bad); }
.form__alt { font-size: 0.9rem; color: var(--ink-soft); margin: 0; }

/* ---------- Narrative: LCA banner ---------- */
.lca {
  position: relative; overflow: hidden; isolation: isolate;
  display: grid; place-items: center; text-align: center;
  min-height: clamp(18rem, 45vw, 28rem); padding: 2.5rem var(--gutter);
  border-radius: var(--radius-lg); border: 1px solid var(--rule);
  background:
    radial-gradient(50rem 22rem at 50% 0%, rgba(37, 99, 235, 0.18), transparent 70%),
    radial-gradient(30rem 20rem at 50% 100%, rgba(255, 255, 255, 0.05), transparent 70%),
    #000;
  text-decoration: none;
}
.lca:hover { color: var(--ink); border-color: rgba(124, 179, 255, 0.5); }
.lca img { width: min(22rem, 70%); height: auto; margin: 0 auto 1.25rem; }
.lca p { color: var(--ink-soft); max-width: 30rem; margin: 0 auto 1.25rem; }

/* ---------- About ---------- */
.about { display: grid; grid-template-columns: minmax(0, 20rem) minmax(0, 1fr); gap: clamp(1.5rem, 4vw, 3rem); align-items: start; }

/* ---------- Trust line + footer ---------- */
.trust { display: flex; flex-wrap: wrap; gap: 0.6rem 2rem; align-items: center; color: var(--ink-soft); }
.trust span { font-size: 1.05rem; color: var(--ink); opacity: 0.8; }

.foot { border-top: 1px solid var(--rule); padding: 2rem 0 2.5rem; color: var(--ink-soft); font-size: 0.9rem; }
.foot__in { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem 2rem; }
.foot a { color: var(--ink-soft); }
.foot a:hover { color: var(--link-hover); }
.foot__links { display: flex; flex-wrap: wrap; gap: 0.4rem 1.25rem; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
  .hero--intro .hero__copy { opacity: 1; transform: none; }
}

/* ---------- Worked with (logos) ---------- */
.logos { display: flex; flex-wrap: wrap; gap: 0.9rem; }
.logo { display: grid; place-items: center; width: 13rem; height: 5.5rem; padding: 0 1.5rem; border-radius: var(--radius-lg); background: #ececec; }
.logo img { max-height: 2.4rem; max-width: 100%; width: auto; height: auto; }
.logo img.logo--tall { max-height: 3.6rem; }
@media (max-width: 40rem) { .logo { width: calc(50% - 0.45rem); padding: 0 1rem; } }

/* ---------- Small print, socials ---------- */
.note { margin: 1.5rem 0 0; font-size: 0.85rem; color: var(--ink-soft); max-width: var(--measure); }
.socials { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem; margin-top: 1.25rem; }
.socials a { display: inline-flex; align-items: center; height: 2.5rem; padding: 0 1rem; border-radius: 999px; border: 1px solid var(--glass-edge); background: rgba(255, 255, 255, 0.06); color: var(--ink); text-decoration: none; font-size: 0.92rem; }
.socials a:hover { background: rgba(255, 255, 255, 0.12); color: var(--ink); }
.socials__lca img { height: 1.6rem; width: auto; }

/* ---------- Photo viewer ---------- */
.stills button { padding: 0; border: 0; background: none; cursor: zoom-in; border-radius: var(--radius); display: block; }
.viewer { border: 0; padding: 0; background: transparent; max-width: 94vw; max-height: 92vh; overflow: visible; }
.viewer::backdrop { background: rgba(0, 0, 0, 0.88); }
.viewer img { display: block; max-width: 94vw; max-height: 88vh; width: auto; height: auto; border-radius: var(--radius); }
.viewer__close { position: fixed; top: 1rem; right: 1rem; width: 2.75rem; height: 2.75rem; border-radius: 999px; border: 1px solid var(--glass-edge); background: rgba(16, 16, 16, 0.9); color: var(--ink); font: inherit; font-size: 1.4rem; line-height: 1; cursor: pointer; }

/* ---------- Booking (Google Calendar appointment schedule, opened in a dialog) ---------- */
.section--book { padding-top: clamp(2.5rem, 6vw, 4.5rem); }
.pitch--book { grid-template-areas: "reel" "book" "more"; }
.pitch--book .pitch__reel { grid-area: reel; }
.pitch--book .booking { grid-area: book; }
.pitch--book .pitch__more { grid-area: more; margin-top: 0.75rem; }
@media (min-width: 60rem) {
  .pitch--book { grid-template-areas: "reel book" "more book"; }
  .pitch--book .booking { align-self: start; }
}
.booking h2 { margin: 0 0 0.5rem; font-size: 1.4rem; }
.booking > p { margin: 0 0 1.25rem; }
.booking__open { width: 100%; padding: 0.95rem 1.35rem; font-size: 1.05rem; }
.booking__alt { margin: 1rem 0 0 !important; font-size: 0.88rem; text-align: center; }
.booker { border: 0; padding: 0; width: min(68rem, 96vw); height: min(56rem, 92vh); max-width: none; max-height: none; border-radius: var(--radius-lg); background: #ffffff; overflow: hidden; }
.booker::backdrop { background: rgba(0, 0, 0, 0.82); }
.booker iframe { display: block; width: 100%; height: 100%; border: 0; }
.booker__close { position: absolute; top: 0.6rem; right: 0.6rem; z-index: 1; width: 2.6rem; height: 2.6rem; border-radius: 999px; border: 1px solid rgba(0, 0, 0, 0.15); background: rgba(255, 255, 255, 0.95); color: #111; font: inherit; font-size: 1.4rem; line-height: 1; cursor: pointer; }
@media (max-width: 40rem) { .booker { width: 100vw; height: 100dvh; border-radius: 0; } }

/* ---------- V009 ---------- */

/* Background glows (site-wide, as on lcastudios.ca): soft blue and white light behind the black page.
   Fixed to the screen, so the page scrolls over them. Sits behind everything; the home hero photo covers it. */
body::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(44rem 36rem at -8% 40%, rgba(37, 99, 235, 0.26), transparent 70%),
    radial-gradient(40rem 30rem at 106% 2%, rgba(79, 70, 229, 0.22), transparent 70%),
    radial-gradient(36rem 26rem at 80% 110%, rgba(255, 255, 255, 0.06), transparent 70%);
}
.foot { background: transparent; }

/* Home hero on phones: centre the copy on the screen (not under the bar), lifted slightly for balance */
@media (max-width: 46rem) {
  .hero__in { padding-top: 0; padding-bottom: 10svh; }
}

/* "Pick a time": a one-second nudge when it first comes into view */
@keyframes nudge {
  0%   { transform: translateX(0); box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.55); }
  12%  { transform: translateX(-3px); }
  24%  { transform: translateX(3px); }
  36%  { transform: translateX(-2px); }
  48%  { transform: translateX(2px); }
  60%  { transform: translateX(0); }
  100% { transform: translateX(0); box-shadow: 0 0 0 12px rgba(37, 99, 235, 0); }
}
.booking__open.is-nudge { animation: nudge 1s ease-out; }

/* Crew: commercial / narrative reel switch */
.reels__tabs { display: inline-flex; gap: 0.25rem; padding: 0.25rem; margin-bottom: 0.75rem; border-radius: 999px; border: 1px solid var(--glass-edge); background: rgba(255, 255, 255, 0.04); }
.reels__tab { font: inherit; font-size: 0.9rem; color: var(--ink-soft); background: none; border: 0; padding: 0.45rem 1rem; border-radius: 999px; cursor: pointer; }
.reels__tab:hover { color: var(--ink); }
.reels__tab[aria-pressed="true"] { color: var(--ink); background: rgba(255, 255, 255, 0.12); }

/* Narrative: reel and LCA banner side by side on desktop */
.narrative-pair { display: grid; gap: 1.25rem; }
.narrative-pair .narrative-reel { margin: 0; }
@media (min-width: 60rem) {
  .narrative-pair { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); align-items: stretch; }
  .narrative-pair .lca { min-height: 0; padding: 1.5rem; }
  .narrative-pair .lca img { width: auto; max-width: 80%; height: 13rem; object-fit: contain; margin: -1.25rem auto -0.5rem; }
  .narrative-pair .lca p { margin-bottom: 1rem; }
}

/* About: photo column stretches to the full height of the text; gallery thumbnails underneath */
.about { align-items: stretch; padding-bottom: 3rem; grid-template-columns: minmax(0, 22rem) minmax(0, 1fr); }
.gallery { display: flex; flex-direction: column; gap: 0.6rem; min-height: 100%; }
.gallery__main {
  position: relative; isolation: isolate; overflow: hidden; display: block; padding: 0; cursor: zoom-in;
  flex: 1 1 0; width: 100%; min-height: 24rem; height: 0;
  border-radius: var(--radius-lg); background: var(--surface); border: 1px solid var(--rule);
}
.gallery__main img { width: 100%; height: 100%; object-fit: cover; }
.gallery__thumbs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.5rem; }
.gallery__thumb { padding: 0; border: 1px solid var(--rule); border-radius: var(--radius); overflow: hidden; background: var(--surface); cursor: pointer; opacity: 0.6; transition: opacity 0.15s, border-color 0.15s; }
.gallery__thumb img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; }
.gallery__thumb:hover { opacity: 0.9; }
.gallery__thumb[aria-pressed="true"] { opacity: 1; border-color: var(--link-hover); }
@media (max-width: 46rem) {
  .about { grid-template-columns: 1fr; }
  .gallery__main { min-height: 0; height: auto; aspect-ratio: 2 / 1; flex: none; }
  .gallery__main img { position: absolute; inset: 0; }
}

/* Back to top */
.to-top {
  position: fixed; z-index: 15; right: calc(1rem + env(safe-area-inset-right, 0px)); bottom: calc(1rem + env(safe-area-inset-bottom, 0px));
  width: 2.6rem; height: 2.6rem; border-radius: 999px; display: grid; place-items: center; cursor: pointer;
  color: var(--ink); background: rgba(16, 16, 16, 0.7); border: 1px solid var(--glass-edge);
  -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur);
  opacity: 0; visibility: hidden; transform: translateY(6px);
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0s linear 0.25s, background 0.15s;
}
.to-top svg { width: 1.05rem; height: 1.05rem; }
.to-top:hover { background: rgba(37, 99, 235, 0.85); }
.to-top.is-on { opacity: 0.85; visibility: visible; transform: none; transition: opacity 0.25s ease, transform 0.25s ease, visibility 0s, background 0.15s; }
