/* ==========================================================================
   Southern Flavours — dark, warm, cinematic.
   Inspired by the Yamazato mood: deep warm blacks, ivory type, spaced serif
   capitals. One hot accent (ember) is reserved for "reward" moments; sage is
   the calm secondary.
   ========================================================================== */

:root {
  --bg: #0F0D0B;
  --bg-2: #171410;
  --surface: rgba(243, 237, 227, 0.045);
  --ink: #F3EDE3;
  --ink-soft: #C9C0B2;
  --muted: #8C8376;
  --line: rgba(243, 237, 227, 0.12);
  --ember: #E8643C;
  --ember-soft: rgba(232, 100, 60, 0.18);
  --sage: #8AA37B;

  --serif: "Cormorant Garamond", Georgia, serif;
  --sans: "Work Sans", system-ui, sans-serif;

  --wrap: 720px;
  --wide: 1180px;
  --gutter: clamp(18px, 4vw, 32px);
  --ease: cubic-bezier(.2, .7, .1, 1);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink-soft);
  font: 400 17px/1.75 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, video { display: block; max-width: 100%; }
a { color: inherit; }
::selection { background: var(--ember); color: var(--bg); }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.wide { max-width: var(--wide); margin: 0 auto; padding: 0 var(--gutter); }

h1, h2, h3, h4 { font-family: var(--serif); font-weight: 500; color: var(--ink); line-height: 1.1; margin: 0; }
h3 { font-size: clamp(28px, 4vw, 38px); margin-bottom: 18px; }
h4 { font-size: 24px; }
p { margin: 0 0 1.2em; }

.caps {
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .28em;
  text-transform: uppercase;
}
.eyebrow { composes: caps; }
.eyebrow, .kicker {
  font-family: var(--sans); font-size: 12px; font-weight: 500;
  letter-spacing: .28em; text-transform: uppercase; color: var(--sage);
}
.kicker { color: var(--ember); }
.venue { color: var(--ink); font-weight: 500; }

/* ---- Skip link -------------------------------------------------------- */
.skip { position: absolute; left: -999px; top: 8px; z-index: 200; background: var(--ink); color: var(--bg); padding: 8px 14px; }
.skip:focus { left: 8px; }

/* ---- Scroll progress (thin ember line) -------------------------------- */
.progress {
  position: fixed; inset: 0 0 auto 0; height: 2px; z-index: 90;
  background: var(--ember); transform-origin: 0 50%; transform: scaleX(var(--progress, 0));
  box-shadow: 0 0 12px var(--ember);
}

/* ---- Header: brand + floating pill nav -------------------------------- */
.top {
  position: fixed; inset: 0 0 auto 0; z-index: 80;
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px var(--gutter);
  pointer-events: none;
}
.top > * { pointer-events: auto; }
/* Once scrolled: a crisp dark-glass strip with a hairline, no smeared tail,
   so the header sits cleanly on both dark and ivory sections. */
.top::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: rgba(15, 13, 11, .78);
  backdrop-filter: blur(16px) saturate(1.2); -webkit-backdrop-filter: blur(16px) saturate(1.2);
  border-bottom: 1px solid rgba(243, 237, 227, .07);
  opacity: 0; transition: opacity .5s var(--ease);
}
.scrolled .top::before { opacity: 1; }
.brand {
  display: inline-flex; align-items: center; gap: 12px;
  font-family: var(--serif); font-size: 20px; font-weight: 600; letter-spacing: .14em;
  text-transform: uppercase; color: var(--ink); text-decoration: none; white-space: nowrap;
}
.brand .mark { width: 38px; height: 38px; flex: none; transition: transform .6s var(--ease); }
.brand:hover .mark { transform: rotate(-6deg) translateY(-1px); }
.pill {
  position: absolute; left: 50%; transform: translateX(-50%);
  display: flex; gap: 2px; padding: 5px;
  background: rgba(23, 20, 16, .55);
  border: 1px solid var(--line);
  border-radius: 999px;
  backdrop-filter: blur(14px) saturate(1.3);
  -webkit-backdrop-filter: blur(14px) saturate(1.3);
  box-shadow: 0 8px 30px rgba(0, 0, 0, .35);
  view-transition-name: pill;
}
.pill a {
  position: relative; padding: 8px 16px; border-radius: 999px;
  font-size: 13px; font-weight: 500; letter-spacing: .04em; color: var(--ink-soft);
  text-decoration: none; white-space: nowrap; transition: color .25s, background .25s;
}
.pill a:hover { color: var(--ink); background: var(--surface); }
.pill a[aria-current="page"] { color: var(--bg); background: var(--ink); }
.top .cta-mini {
  font-size: 12px; font-weight: 500; letter-spacing: .2em; text-transform: uppercase;
  color: var(--ink); text-decoration: none; padding: 10px 18px; border: 1px solid var(--line); border-radius: 999px;
  background: rgba(23, 20, 16, .35); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  transition: background .25s, color .25s, border-color .25s;
}
.top .cta-mini:hover { background: var(--ember); border-color: var(--ember); color: var(--bg); }

@media (max-width: 860px) {
  .top .cta-mini { display: none; }
  .brand .full { display: none; }
  .brand .mark { width: 40px; height: 40px; }
  .pill { left: auto; right: var(--gutter); transform: none; }
}
@media (max-width: 420px) {
  .pill a { padding: 8px 11px; font-size: 12.5px; }
  .brand { font-size: 18px; }
}

/* ---- Buttons ------------------------------------------------------------ */
.btn {
  --mx: 0px; --my: 0px;
  display: inline-flex; align-items: center; gap: 12px;
  padding: 16px 28px; border-radius: 999px;
  font: 500 13px/1 var(--sans); letter-spacing: .2em; text-transform: uppercase;
  text-decoration: none; color: var(--bg); background: var(--ember);
  box-shadow: 0 0 0 0 var(--ember-soft);
  transform: translate(var(--mx), var(--my));
  transition: transform .35s var(--ease), box-shadow .35s, background .25s;
}
.btn:hover { box-shadow: 0 0 0 10px var(--ember-soft), 0 12px 40px rgba(232, 100, 60, .35); }
.btn .arrow { transition: transform .3s var(--ease); }
.btn:hover .arrow { transform: translateX(4px); }
.btn.ghost { background: transparent; color: var(--ink); border: 1px solid rgba(243, 237, 227, .35); }
.btn.ghost:hover { border-color: var(--ink); box-shadow: 0 0 0 10px rgba(243, 237, 227, .06); }

/* ---- Cinema hero: full-bleed media that shrinks into a frame on scroll -- */
.cinema { position: relative; height: 100vh; height: 100svh; }
.js .cinema.scrolly { height: 230vh; }
.cinema-stage { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; }
.cinema-frame {
  --ix: 0px; --iy: 0px; --r: 0px; --p: 0;
  position: absolute; inset: 0;
  clip-path: inset(var(--iy) var(--ix) var(--iy) var(--ix) round var(--r));
  will-change: clip-path;
}
.cinema-frame video, .cinema-frame img, .cinema-frame picture {
  width: 100%; height: 100%; object-fit: cover;
  transform: scale(calc(1.08 - var(--p) * .08));
  will-change: transform;
}
.cinema-frame picture img { transform: none; }
.cinema-shade {
  position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(120% 90% at 50% 45%, rgba(15, 13, 11, 0) 30%, rgba(15, 13, 11, .75) 100%),
    linear-gradient(180deg, rgba(15, 13, 11, .55) 0%, rgba(15, 13, 11, .15) 35%, rgba(15, 13, 11, .72) 80%, #0F0D0B 100%);
  opacity: calc(1 - var(--p) * .55);
}
.cinema-title {
  --p: 0;
  position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; padding: 90px var(--gutter) 60px;
  opacity: calc(1 - var(--p) * 2.2);
  transform: translateY(calc(var(--p) * -60px));
}
.cinema-title h1 {
  font-size: clamp(44px, 9.5vw, 138px); font-weight: 500;
  letter-spacing: .06em; text-transform: uppercase; line-height: .98;
  text-shadow: 0 4px 40px rgba(0, 0, 0, .45);
}
.cinema-title .lede { max-width: 620px; margin: 26px auto 0; font-size: clamp(16px, 1.6vw, 19px); color: var(--ink); text-shadow: 0 2px 20px rgba(0, 0, 0, .6); }
.cinema-title .eyebrow { margin-bottom: 22px; color: var(--ink); opacity: .85; }
.cinema-title .actions { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; margin-top: 38px; }
.cinema-caption {
  --p: 0;
  position: absolute; left: 0; right: 0; bottom: 5vh; text-align: center;
  opacity: calc((var(--p) - .75) * 4); color: var(--muted);
}
.scroll-cue {
  position: absolute; left: 50%; bottom: 26px; transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 10px; color: var(--ink); opacity: .75;
}
.scroll-cue::after {
  content: ""; width: 1px; height: 46px;
  background: linear-gradient(var(--ink), transparent);
  animation: cue 2.2s var(--ease) infinite;
  transform-origin: top;
}
@keyframes cue { 0% { transform: scaleY(0); } 50% { transform: scaleY(1); } 100% { transform: scaleY(1); opacity: 0; } }

/* ---- Home intro sequence (first visit per session) --------------------- */
.intro {
  position: fixed; inset: 0; z-index: 150; background: #000;
  display: grid; place-items: center; pointer-events: none;
  animation: intro-out .7s .95s var(--ease) forwards;
}
.intro::before {
  content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--ember);
  box-shadow: 0 0 40px 12px rgba(232, 100, 60, .6);
  animation: ember 1.2s var(--ease) forwards;
}
@keyframes ember { 0% { transform: scale(0); opacity: 0; } 35% { transform: scale(1); opacity: 1; } 100% { transform: scale(26); opacity: 0; } }
@keyframes intro-out { to { opacity: 0; visibility: hidden; } }
.seen-intro .intro { display: none; }

.split .ch {
  display: inline-block; opacity: 0; filter: blur(14px); transform: translateY(.35em);
  animation: ch-in 1s var(--ease) forwards;
  animation-delay: calc(1.05s + var(--i) * 55ms);
}
.seen-intro .split .ch { animation-delay: calc(.15s + var(--i) * 35ms); }
@keyframes ch-in { to { opacity: 1; filter: blur(0); transform: none; } }
.intro-late { opacity: 0; animation: fade-up .9s var(--ease) forwards; animation-delay: var(--d, 1.7s); }
.seen-intro .intro-late { animation-delay: calc(var(--d, 1.7s) - .9s); }
@keyframes fade-up { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

/* ---- Reveal on scroll --------------------------------------------------- */
.js .reveal { opacity: 0; transform: translate3d(0, 28px, 0); transition: opacity 1s var(--ease), transform 1s var(--ease); transition-delay: var(--delay, 0s); }
.js .reveal.in { opacity: 1; transform: none; }

/* ---- Text-led page head (The Pass) ------------------------------------- */
.page-head { padding: clamp(150px, 22vh, 220px) 0 30px; text-align: center; }
.page-head h1 { font-size: clamp(56px, 12vw, 160px); text-transform: uppercase; letter-spacing: .05em; line-height: .95; margin: 18px 0 26px; }
.page-head .lede { max-width: 620px; margin: 0 auto; font-family: var(--serif); font-style: italic; font-size: clamp(22px, 2.6vw, 30px); color: var(--ink); }
.center { text-align: center; }

/* ---- Sections ------------------------------------------------------------ */
.section { padding: clamp(80px, 12vw, 150px) 0; position: relative; }
.section.tight { padding-top: 40px; }
.section-head { margin-bottom: 46px; }
.section-head h2 { font-size: clamp(36px, 6vw, 64px); margin-top: 14px; }

.statement {
  font-family: var(--serif); font-style: italic; font-weight: 500;
  font-size: clamp(34px, 6vw, 72px); line-height: 1.08; color: var(--ink); text-align: center;
  max-width: 1000px; margin: 0 auto;
}
.statement em { font-style: italic; color: var(--ember); }

.block { margin-bottom: 64px; }
.block p { color: var(--ink-soft); }
.block-card { background: var(--surface); border: 1px solid var(--line); border-radius: 4px; padding: 40px 40px 18px; }
@media (max-width: 560px) { .block-card { padding: 28px 22px 8px; } }
.dropcap::first-letter {
  font-family: var(--serif); float: left; font-size: 92px; line-height: .78;
  padding: 8px 14px 0 0; color: var(--ember);
}
.pull-quote {
  margin: 0 0 64px; padding: 44px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  font-family: var(--serif); font-style: italic; font-size: clamp(28px, 4.2vw, 44px); line-height: 1.2; color: var(--ink); text-align: center;
}

/* ---- Home hero: leave a sliver of the next section visible -------------- */
/* Home hero fills the screen: nothing of the next section peeks in on arrival;
   the video dissolves into the page's warm black at its lower edge. */
.cinema:not(.scrolly) { height: 100vh; height: 100svh; min-height: 560px; }
/* Layers: video < smoke < title. The stage is a plain box here (not sticky),
   so the smoke can sit between the film and the title and spill below it. */
.cinema:not(.scrolly) .cinema-stage { position: absolute; inset: 0; }
.cinema:not(.scrolly) .cinema-title,
.cinema:not(.scrolly) .scroll-cue { z-index: 2; }
.smoke {
  position: absolute; left: 0; top: 0; width: 100%; height: calc(100% + 28vh);
  z-index: 1; pointer-events: none;
  opacity: 0; transition: opacity 3s var(--ease) .6s;
}
.smoke.on { opacity: 1; }
.cinema:not(.scrolly) .cinema-stage { height: 100%; }

/* ---- At a glance ---------------------------------------------------------- */
.glance { display: grid; grid-template-columns: 1.6fr 1fr; gap: 28px; align-items: start; }
@media (max-width: 860px) { .glance { grid-template-columns: 1fr; } .contact-card { position: static; } }
.glance-lede { font-family: var(--serif); font-style: italic; font-size: clamp(24px, 3vw, 32px); line-height: 1.25; color: var(--ink); margin: 0 0 26px; }
.facts { margin: 0; border-top: 1px solid var(--line); }
.facts > div { display: grid; grid-template-columns: 140px 1fr; gap: 18px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.facts dt { font-size: 11px; letter-spacing: .22em; text-transform: uppercase; color: var(--sage); padding-top: 4px; }
.facts dd { margin: 0; color: var(--ink); }
.facts a { text-decoration: none; background: linear-gradient(var(--ember), var(--ember)) 0 100% / 0 1px no-repeat; transition: background-size .4s var(--ease), color .3s; }
.facts a:hover { color: var(--ember); background-size: 100% 1px; }
@media (max-width: 520px) { .facts > div { grid-template-columns: 1fr; gap: 2px; } }

.contact-card {
  position: sticky; top: 96px;
  padding: 30px 28px; border: 1px solid var(--line); border-radius: 6px;
  background: radial-gradient(120% 120% at 100% 0%, rgba(232, 100, 60, .14), transparent 55%), var(--bg-2);
}
.contact-card .contact-line { color: var(--ink); font-size: 18px; margin: 12px 0 22px; }
.contact-card .contact-mail { display: block; margin-top: 16px; color: var(--ink-soft); font-size: 14.5px; text-decoration: none; word-break: break-all; }
.contact-card .contact-mail:hover { color: var(--ember); }
.contact-card .contact-more { display: inline-block; margin-top: 10px; font-size: 13px; letter-spacing: .08em; color: var(--muted); text-decoration: none; }
.contact-card .contact-more:hover { color: var(--ink); }

.route-links { margin: 40px 0 0; }
.route-links a { color: var(--muted); text-decoration: none; transition: color .25s; }
.route-links a:hover { color: var(--ember); }
.route-links a.now { color: var(--ink); }

/* ---- Skills hub: every skill links to its chapter ------------------------ */
.skill-groups { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
@media (max-width: 1060px) { .skill-groups { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .skill-groups { grid-template-columns: 1fr; } }
.skill-group h3 { font-size: 22px; margin: 0 0 14px; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.skill {
  position: relative; display: block; padding: 12px 34px 12px 14px; margin-bottom: 8px;
  border: 1px solid var(--line); border-radius: 4px; background: var(--surface);
  color: var(--ink); text-decoration: none; font-size: 15px; line-height: 1.35;
  transition: border-color .25s, background .25s, transform .35s var(--ease);
}
.skill small { display: block; margin-top: 4px; font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); transition: color .25s; }
.skill::after { content: "→"; position: absolute; right: 14px; top: 50%; transform: translate(-4px, -50%); opacity: 0; color: var(--ember); transition: opacity .25s, transform .35s var(--ease); }
.skill:hover { border-color: var(--ember); background: var(--ember-soft); transform: translateX(3px); }
.skill:hover small { color: var(--ink-soft); }
.skill:hover::after { opacity: 1; transform: translate(0, -50%); }

.statement.small { font-size: clamp(26px, 3.6vw, 40px); margin: 0 auto 46px; }

/* ---- Landing on a chapter from a skill link ------------------------------ */
.block, .photo, #contact, #skills, #experience { scroll-margin-top: 110px; }
.block:target h3 { color: var(--ember); transition: color .6s; }
.block:target { animation: landed 2.4s var(--ease); border-radius: 6px; }
@keyframes landed { 0% { box-shadow: 0 0 0 0 rgba(232, 100, 60, 0); } 15% { box-shadow: 0 0 0 14px rgba(232, 100, 60, .16); } 100% { box-shadow: 0 0 0 28px rgba(232, 100, 60, 0); } }

/* ---- Stats -------------------------------------------------------------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.stat { background: var(--bg); padding: 38px 26px 30px; }
.stat .num { font-family: var(--serif); font-size: clamp(46px, 6vw, 76px); line-height: 1; color: var(--ink); font-variant-numeric: lining-nums tabular-nums; }
.stat .num .accent { color: var(--ember); }
.stat .label { margin-top: 14px; font-size: 14px; color: var(--muted); }
@media (max-width: 760px) { .stats { grid-template-columns: repeat(2, 1fr); } }

/* ---- Marquee -------------------------------------------------------------- */
.marquee { overflow: hidden; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 26px 0; }
.marquee-track { display: flex; width: max-content; animation: marquee 38s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee span {
  font-family: var(--serif); font-size: clamp(28px, 4vw, 48px); color: var(--ink); white-space: nowrap; padding: 0 28px;
  text-transform: uppercase; letter-spacing: .06em;
}
.marquee span.dot { color: var(--ember); padding: 0 4px; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---- Course cards (home "menu") ----------------------------------------- */
.courses { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
@media (max-width: 760px) { .courses { grid-template-columns: 1fr; } }
.course {
  position: relative; display: block; min-height: 440px; overflow: hidden; border-radius: 4px;
  text-decoration: none; color: var(--ink); isolation: isolate; border: 1px solid var(--line);
}
.course img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transform: scale(1.04); transition: transform 1.2s var(--ease), filter 1.2s var(--ease); filter: saturate(.85) brightness(.75); }
.course::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(15, 13, 11, .1) 20%, rgba(15, 13, 11, .92) 100%); }
.course:hover img { transform: scale(1.12); filter: saturate(1.1) brightness(.9); }
.course-body { position: absolute; left: 0; right: 0; bottom: 0; padding: 30px 30px 32px; }
.course .kicker { display: block; margin-bottom: 12px; }
.course h3 { font-size: clamp(36px, 4.5vw, 52px); text-transform: uppercase; letter-spacing: .05em; margin-bottom: 10px; }
.course p { margin: 0; font-family: var(--serif); font-style: italic; font-size: 21px; color: var(--ink-soft); }
.course .go {
  position: absolute; top: 26px; right: 26px; width: 48px; height: 48px; border-radius: 50%;
  display: grid; place-items: center; border: 1px solid rgba(243, 237, 227, .35);
  transition: background .35s, border-color .35s, transform .5s var(--ease);
}
.course:hover .go { background: var(--ember); border-color: var(--ember); transform: rotate(-45deg); }

/* ---- Route strip --------------------------------------------------------- */
.route { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; padding: 22px 0; margin-bottom: 64px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); font-size: 13px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.route .arrow { color: var(--ember); }
.route .now { color: var(--ink); }
.route .now::after { content: ""; display: inline-block; width: 7px; height: 7px; margin-left: 10px; border-radius: 50%; background: var(--ember); box-shadow: 0 0 10px var(--ember); vertical-align: middle; animation: pulse 2s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .35; } }

/* ---- Kit strip ------------------------------------------------------------ */
.kit { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); margin: 28px 0 22px; }
.tool { background: var(--bg-2); padding: 18px 18px 16px; }
.tool .where { display: block; font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: var(--sage); margin-bottom: 6px; }
.tool .name { font-family: var(--serif); font-size: 22px; color: var(--ink); }

/* ---- Triptych (three quiet images under a block) ------------------------ */
.triptych { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 6px 0 4px; }
.triptych img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: 3px; filter: brightness(.8) saturate(.85); transition: filter .6s var(--ease), transform .8s var(--ease); }
.triptych img:hover { filter: none; transform: scale(1.02); }

/* ---- Experience list ----------------------------------------------------- */
.role { display: grid; grid-template-columns: 170px 1fr; gap: 24px; padding: 28px 0; border-top: 1px solid var(--line); }
.role:last-child { border-bottom: 1px solid var(--line); }
.role .when { font-family: var(--serif); font-style: italic; font-size: 19px; color: var(--sage); padding-top: 2px; }
.role h4 { margin-bottom: 8px; font-size: 26px; }
.role p { margin: 0; font-size: 15.5px; }
@media (max-width: 560px) { .role { grid-template-columns: 1fr; gap: 6px; } }

/* ---- Tags ------------------------------------------------------------------ */
.tags { display: flex; flex-wrap: wrap; gap: 10px; }
.tag { font-size: 13.5px; padding: 9px 16px; border-radius: 999px; border: 1px solid var(--line); color: var(--ink); background: var(--surface); transition: background .25s, color .25s, border-color .25s; }
.tag:hover { background: var(--sage); border-color: var(--sage); color: var(--bg); }

/* ---- Photo figure ----------------------------------------------------------- */
.photo { margin: 0 auto 64px; max-width: 520px; }
.photo img { width: 100%; border-radius: 4px; }
.photo figcaption { margin-top: 14px; font-family: var(--serif); font-style: italic; font-size: 18px; color: var(--muted); }

/* ---- Contact ---------------------------------------------------------------- */
.contact-hero { text-align: center; }
.contact-hero h2 { font-size: clamp(44px, 9vw, 120px); text-transform: uppercase; letter-spacing: .04em; line-height: .95; margin: 18px 0 28px; }
.contact-hero p { max-width: 560px; margin: 0 auto 40px; font-size: 19px; color: var(--ink); }
.contact-hero .btn { font-size: 14px; padding: 20px 34px; text-transform: none; letter-spacing: .04em; }

/* ---- Next course ------------------------------------------------------------ */
.next {
  display: block; padding: clamp(70px, 10vw, 120px) var(--gutter); text-align: center; text-decoration: none;
  border-top: 1px solid var(--line); position: relative; overflow: hidden; isolation: isolate;
}
.next::before { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--ember); transform: translateY(101%); transition: transform .8s var(--ease); }
.next:hover::before { transform: none; }
.next .kicker { transition: color .4s; }
.next strong { display: block; margin-top: 14px; font-family: var(--serif); font-weight: 500; font-size: clamp(48px, 10vw, 128px); line-height: 1; text-transform: uppercase; letter-spacing: .04em; color: var(--ink); transition: color .4s; }
.next:hover .kicker, .next:hover strong { color: var(--bg); }

/* ---- Footer ------------------------------------------------------------------ */
footer.site {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 18px;
  padding: 34px var(--gutter) 40px; border-top: 1px solid var(--line); font-size: 13px; color: var(--muted);
}
footer.site nav { display: flex; flex-wrap: wrap; gap: 20px; }
footer.site a { text-decoration: none; }
footer.site a:hover { color: var(--ink); }

/* ---- Kitchen wall — endless masonry, focus falloff, lightbox ----------------- */
.wall-section { padding-bottom: 0; }
.wall {
  position: relative; height: 92vh; height: 92svh; min-height: 560px; overflow: hidden;
  background: radial-gradient(90% 80% at 50% 50%, #1b1713 0%, var(--bg) 100%);
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  cursor: grab; touch-action: pan-y; user-select: none; -webkit-user-select: none; outline: none;
}
.wall.dragging { cursor: grabbing; }
@media (hover: hover) and (pointer: fine) { .wall { cursor: none; } }

/* No-JS / reduced-motion fallback: a quiet masonry of all images */
.wall-items { list-style: none; margin: 0; padding: 18px; columns: 4 200px; column-gap: 14px; }
.wall-items li { break-inside: avoid; margin-bottom: 14px; }
.wall-items img { width: 100%; border-radius: 3px; }
.wall.live { }
.wall.live .wall-items {
  position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}

.wall-plane { position: absolute; inset: 0; }
.wall-tile {
  position: absolute; left: 0; top: 0; transform-origin: 50% 50%; will-change: transform, opacity;
  border-radius: 4px; overflow: hidden; cursor: inherit;
  box-shadow: 0 18px 40px -18px rgba(0, 0, 0, .7);
}
.wt-media, .wt-media img, .wt-media video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.wt-media img, .wt-media video { pointer-events: none; transform: scale(1.02); transition: transform 1.1s var(--ease), filter 1.1s var(--ease); filter: saturate(.92); }
.wall-tile video { display: none; }
.wall-tile.is-video video { display: block; }
.wall-tile.is-video img { display: none; }
.wt-shade { position: absolute; inset: 0; background: var(--bg); pointer-events: none; transition: opacity .2s linear; }
.wt-cap {
  position: absolute; left: 12px; right: 12px; bottom: 10px; z-index: 1;
  font-size: 10.5px; letter-spacing: .18em; text-transform: uppercase; color: var(--ink);
  opacity: 0; transform: translateY(6px); transition: opacity .5s var(--ease), transform .5s var(--ease);
  text-shadow: 0 1px 12px rgba(0, 0, 0, .9);
}
.wall-tile::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; border-radius: 4px;
  box-shadow: inset 0 0 0 1px rgba(243, 237, 227, .06);
  background: linear-gradient(180deg, transparent 55%, rgba(15, 13, 11, .75));
  opacity: 0; transition: opacity .5s var(--ease);
}
.wall:not(.dragging) .wall-tile:hover::after { opacity: 1; box-shadow: inset 0 0 0 1px rgba(232, 100, 60, .55); }
.wall:not(.dragging) .wall-tile:hover .wt-cap { opacity: 1; transform: none; }
.wall:not(.dragging) .wall-tile:hover .wt-media img,
.wall:not(.dragging) .wall-tile:hover .wt-media video { transform: scale(1.07); filter: saturate(1.05); }

/* Film grain + soft vignette over the field */
.wall::before {
  content: ""; position: absolute; inset: -50%; z-index: 3; pointer-events: none; opacity: .045;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
.wall::after { content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none; box-shadow: inset 0 0 160px 60px var(--bg); }

.wall-hint {
  position: absolute; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 4;
  padding: 11px 20px; border-radius: 999px; background: rgba(15, 13, 11, .66); border: 1px solid var(--line);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); pointer-events: none; color: var(--ink);
  transition: opacity .8s; white-space: nowrap;
}
.wall.touched .wall-hint { opacity: 0; }

/* Custom cursor inside the wall (mouse/trackpad only) */
.wall-cursor {
  position: absolute; left: 0; top: 0; z-index: 5; width: 0; height: 0; pointer-events: none;
  opacity: 0; transition: opacity .3s;
}
.wall-cursor.on { opacity: 1; }
.wall-cursor span {
  position: absolute; left: -44px; top: -44px; width: 88px; height: 88px; border-radius: 50%;
  display: grid; place-items: center;
  font: 500 10.5px/1 var(--sans); letter-spacing: .26em; text-transform: uppercase; color: var(--ink);
  background: rgba(15, 13, 11, .35); border: 1px solid rgba(243, 237, 227, .45);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  transition: transform .45s var(--ease), background .3s, border-color .3s, color .3s;
}
.wall.dragging .wall-cursor span { transform: scale(.78); }
.wall-cursor.view span { background: var(--ember); border-color: var(--ember); color: var(--bg); transform: scale(1.08); }

/* Lightbox */
.wall-box {
  position: fixed; inset: 0; z-index: 140; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 18px;
  padding: 70px clamp(12px, 3vw, 40px) 40px; background: rgba(10, 9, 8, .94);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  opacity: 0; visibility: hidden; transition: opacity .45s var(--ease), visibility .45s;
}
.wall-box.open { opacity: 1; visibility: visible; }
.wall-box figure { margin: 0; display: flex; flex-direction: column; align-items: center; gap: 16px; min-width: 0; }
.wb-media { display: grid; place-items: center; }
.wb-media img, .wb-media video {
  max-width: min(78vw, 980px); max-height: 74vh; width: auto; height: auto; border-radius: 4px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, .6); transform: scale(.96); transition: transform .6s var(--ease);
}
.wall-box.open .wb-media img, .wall-box.open .wb-media video { transform: none; }
.wall-box figcaption { display: flex; gap: 22px; align-items: baseline; font-size: 12px; letter-spacing: .2em; text-transform: uppercase; color: var(--ink-soft); }
.wb-count { color: var(--ember); font-variant-numeric: tabular-nums; }
.wall-box button {
  width: 52px; height: 52px; border-radius: 50%; border: 1px solid rgba(243, 237, 227, .3); background: transparent;
  color: var(--ink); font-size: 20px; cursor: pointer; transition: background .25s, border-color .25s, color .25s;
}
.wall-box button:hover { background: var(--ember); border-color: var(--ember); color: var(--bg); }
.wb-close { position: absolute; top: 18px; right: 18px; font-size: 26px; }
@media (max-width: 640px) {
  .wall-box { grid-template-columns: 1fr 1fr; grid-template-rows: 1fr auto; }
  .wall-box figure { grid-column: 1 / -1; grid-row: 1; }
  .wb-prev { grid-row: 2; justify-self: end; } .wb-next { grid-row: 2; justify-self: start; }
  .wb-media img, .wb-media video { max-width: 92vw; max-height: 64vh; }
}
/* ---- Low Sun: warm light rising in the bottom-right corner ------------------
   The sun from the logo, as a light source. It sits in the right quarter near
   the bottom, drifts toward the cursor, rises and warms as you scroll down. */
.sunlight {
  --sx: 0px; --sy: 0px;
  position: fixed; z-index: 60; pointer-events: none;
  width: 72vmax; height: 72vmax; right: -23vmax; bottom: -31vmax;
  border-radius: 50%; contain: strict;
  /* Plain alpha instead of a blend mode: same warmth, no repaint while scrolling. */
  background: radial-gradient(circle,
    rgba(255, 196, 140, .26) 0%, rgba(250, 170, 115, .16) 22%,
    rgba(232, 120, 70, .11) 42%, rgba(232, 100, 60, .035) 58%, rgba(232, 100, 60, 0) 70%);
  opacity: calc(.42 + var(--progress, 0) * .38);
  transform: translate3d(var(--sx), calc(var(--sy) - var(--progress, 0) * 14vh), 0);
  will-change: transform, opacity;
}
.sunlight::after {
  content: ""; position: absolute; inset: 22%; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 186, 125, .16), rgba(255, 186, 125, 0) 70%);
  animation: sun-breathe 9s ease-in-out infinite;
}
@keyframes sun-breathe { 50% { transform: scale(1.12); opacity: .55; } }
@media (max-width: 700px) { .sunlight { width: 110vmax; height: 110vmax; right: -48vmax; bottom: -58vmax; } }

/* ---- Daylight: the logo, as a section ---------------------------------------
   An ivory plane shaped like the mark: a straight horizon on top, lit by a warm
   seam that is brightest on the right (where the Low Sun sits), and a bowl-shaped
   curve at the bottom returning to the dark. No grey fades anywhere. */
.daylight {
  --ink: #1A1714; --ink-soft: #3D3934; --muted: #7A7266;
  --line: rgba(26, 23, 20, .14); --surface: rgba(26, 23, 20, .04);
  --sage: #4F6B44; --ember-text: #B9472A;
  --bowl: clamp(70px, 9vw, 150px);
  position: relative; isolation: isolate; color: var(--ink-soft);
  margin: clamp(40px, 5vw, 70px) 0 clamp(70px, 9vw, 130px);
  border-radius: 0 0 50% 50% / 0 0 var(--bowl) var(--bowl);
  background:
    radial-gradient(70% 85% at 94% 100%, rgba(255, 205, 150, .5), rgba(255, 205, 150, 0) 62%),
    radial-gradient(60% 60% at 0% 0%, rgba(138, 163, 123, .1), rgba(138, 163, 123, 0) 70%),
    linear-gradient(180deg, #F6F1E8 0%, #F3EDE3 40%, #EFE7DA 100%);
  padding-top: clamp(100px, 11vw, 150px);
  padding-bottom: calc(clamp(90px, 10vw, 140px) + var(--bowl) * .5);
  box-shadow: 0 50px 90px -40px rgba(0, 0, 0, .55);
}
/* The horizon seam: a fine line of light, strongest towards the sun. */
.daylight::before {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 1px; pointer-events: none;
  background: linear-gradient(90deg, rgba(255, 226, 196, 0) 0%, rgba(255, 226, 196, .55) 45%, #FFE6C9 78%, rgba(255, 226, 196, .4) 100%);
}
/* First light: a warm haze rising off the horizon into the dark above it. */
.daylight::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 100%; height: clamp(120px, 16vw, 220px);
  pointer-events: none;
  background: radial-gradient(55% 100% at 76% 100%, rgba(232, 128, 78, .26), rgba(232, 100, 60, .08) 45%, rgba(232, 100, 60, 0) 72%);
}
.daylight .kicker { color: var(--ember-text); }
.daylight h2, .daylight .glance-lede, .daylight .facts dd { color: var(--ink); }
.daylight .facts a:hover { color: var(--ember-text); }
.daylight .route-links a { color: var(--muted); }
.daylight .route-links a:hover { color: var(--ember-text); }
.daylight .route .arrow { color: var(--ember-text); }
.daylight .btn.ghost { color: var(--ink); border-color: rgba(26, 23, 20, .35); }
/* The contact card stays dark inside the light section: a firm anchor. */
.daylight .contact-card {
  --ink: #F3EDE3; --ink-soft: #C9C0B2; --muted: #8C8376; --line: rgba(243, 237, 227, .12);
  background: radial-gradient(120% 120% at 100% 0%, rgba(232, 100, 60, .22), transparent 55%), #171410;
  border-color: transparent; box-shadow: 0 30px 60px -24px rgba(26, 23, 20, .45);
}
.daylight .contact-card .kicker { color: var(--ember); }

/* ---- Cursor glow (fine pointers only) --------------------------------------- */
.glow {
  position: fixed; left: 0; top: 0; width: 420px; height: 420px; margin: -210px 0 0 -210px; z-index: 1;
  border-radius: 50%; pointer-events: none; opacity: 0;
  background: radial-gradient(circle, rgba(232, 100, 60, .14), rgba(232, 100, 60, 0) 65%);
  transition: opacity .6s;
}
.glow.on { opacity: 1; }

/* ---- Smooth page changes (cross-document View Transitions) ------------------ */
@view-transition { navigation: auto; }
::view-transition-old(root) { animation: vt-out .35s var(--ease) both; }
::view-transition-new(root) { animation: vt-in .6s var(--ease) both; }
@keyframes vt-out { to { opacity: 0; transform: translateY(-12px); } }
@keyframes vt-in { from { opacity: 0; transform: translateY(18px); } }

/* ---- Images arrive with one shared fade ------------------------------------- */
img.fade { opacity: 0; transition: opacity .7s var(--ease); }
img.fade.ok { opacity: 1; }
.wt-media img { opacity: 0; transition: opacity .7s var(--ease), transform 1.1s var(--ease), filter 1.1s var(--ease); }
.wt-media img.ok { opacity: 1; }

/* ---- Reduced motion: keep everything, drop the movement --------------------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; transition-duration: .01ms !important; }
  .intro { display: none; }
  .js .cinema.scrolly { height: 100vh; }
  .js .reveal { opacity: 1; transform: none; filter: none; }
  .marquee-track { animation: none; }
  ::view-transition-old(root), ::view-transition-new(root) { animation: none; }
}

/* After a bowl-shaped daylight section, the curve itself is the divider. */
.daylight + .next { border-top: 0; }

/* ---- Header fit at every width ------------------------------------------------
   Between phone and wide desktop the full name would run into the centred menu,
   so the header shows the mark alone up to 1180 px. */
@media (max-width: 1180px) { .brand .full { display: none; } }
@media (max-width: 420px) {
  .pill { padding: 4px; }
  .pill a { padding: 8px 9px; font-size: 12px; letter-spacing: .02em; }
  .brand .mark { width: 36px; height: 36px; }
}
