/* ══════════════════════════════════════════════════════════════════
   benbrimble.com — main stylesheet
   Direction: "Sage & stone" — light editorial, warm and calm.
   Editorial serif (Newsreader) for display + voice; humanist sans
   (Hanken Grotesk) for body and UI. Source of truth for color is
   :root; every other color is an rgba() derivative of these hues.
═══════════════════════════════════════════════════════════════════ */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  /* ── Ground & structure ── */
  --bg:          #F3F2EC;   /* oat white */
  --surface:     #FBFAF6;   /* lifted paper (cards)   */
  --surface-2:   #ECEADF;   /* sunken / hover         */
  --border:      #DDD8CB;
  --border-lt:   #CBC5B4;

  /* ── Ink ── */
  --text:        #22302A;   /* forest ink            */
  --text-2:      #4C5C52;   /* body secondary        */
  --text-muted:  #647061;   /* labels (~4.5:1 on bg) */

  /* ── Signals: sage primary, clay for film, ochre for podcast ── */
  --accent:      #5C7C58;   --accent-ink: #46613E;   --accent-dim: rgba(92,124,88,0.10);
  --clay:        #A75D42;   --clay-ink:   #8C4C34;    --clay-dim:   rgba(167,93,66,0.10);
  --ochre:       #B08238;   --ochre-ink:  #7F5D22;    --ochre-dim:  rgba(176,130,56,0.12);

  /* ── Type ── */
  --f-display:   'Newsreader', Georgia, 'Times New Roman', serif;
  --f-sc:        'Newsreader', Georgia, serif;   /* serif alias kept for essay/now pages */
  --f-ui:        'Hanken Grotesk', system-ui, -apple-system, 'Segoe UI', sans-serif;

  /* ── Motion vocabulary ── */
  --ease-lux:    cubic-bezier(0.22, 1, 0.36, 1);      /* luxurious settle */
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);   /* bouncy overshoot */
  --ease-bounce: cubic-bezier(0.16, 1.36, 0.4, 1);    /* playful pop      */
  --ease-swift:  cubic-bezier(0.55, 0, 0.1, 1);       /* quick, decisive  */

  --pad-x: 68px;
}

html { scroll-behavior: smooth; }
html.lenis, html.lenis body { height: auto; }
html.lenis { scroll-behavior: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--f-ui);
  font-weight: 400;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Paper grain: a fixed, nearly-subliminal tooth. */
body::after {
  content: '';
  position: fixed; inset: -50%;
  width: 200%; height: 200%;
  pointer-events: none;
  z-index: 2000;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  opacity: 0.028;
  mix-blend-mode: multiply;
}

::selection { background: rgba(92,124,88,0.22); color: var(--text); }
::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--border-lt); border-radius: 6px; border: 3px solid var(--bg); }

/* Keyboard focus: the custom cursor hides the pointer, so a clear
   focus ring is the only affordance keyboard users get. */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 2px;
}
:focus:not(:focus-visible) { outline: none; }

/* ══ CUSTOM CURSOR ═════════════════════════════════════════════════ */
@media (pointer: fine) {
  .cursor-dot, .cursor-ring {
    position: fixed; top: 0; left: 0;
    pointer-events: none; z-index: 3000;
    border-radius: 50%;
    will-change: transform;
  }
  .cursor-dot {
    width: 6px; height: 6px;
    background: var(--accent);
    transform: translate(-50%, -50%);
  }
  .cursor-ring {
    width: 30px; height: 30px;
    border: 1.5px solid rgba(92,124,88,0.45);
    transform: translate(-50%, -50%);
    transition: width 0.32s var(--ease-spring), height 0.32s var(--ease-spring),
                border-color 0.28s, background 0.28s;
  }
  .cursor-ring.is-hover {
    width: 46px; height: 46px;
    border-color: rgba(92,124,88,0.9);
    background: rgba(92,124,88,0.07);
  }
  .cursor-ring.is-card {
    width: 52px; height: 52px;
    border-color: rgba(92,124,88,0.5);
    background: rgba(92,124,88,0.12);
  }
  .cursor-hidden .cursor-dot, .cursor-hidden .cursor-ring { opacity: 0; }
  body.has-cursor, body.has-cursor a, body.has-cursor button { cursor: none; }
}
@media (pointer: coarse) {
  .cursor-dot, .cursor-ring { display: none; }
}

/* ══ NAV ═══════════════════════════════════════════════════════════ */
#nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 22px var(--pad-x);
  transition: background 0.4s, backdrop-filter 0.4s, border-color 0.4s, padding 0.4s;
  border-bottom: 1px solid transparent;
}
#nav.scrolled {
  background: rgba(243,242,236,0.82);
  backdrop-filter: blur(16px) saturate(1.1);
  -webkit-backdrop-filter: blur(16px) saturate(1.1);
  border-bottom-color: var(--border);
  padding-top: 16px; padding-bottom: 16px;
}
.nav-logo {
  font-family: var(--f-display);
  font-size: 22px; font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--text); text-decoration: none;
  transition: color 0.2s;
}
.nav-logo:hover { color: var(--accent-ink); }
.nav-links { display: flex; gap: 34px; list-style: none; }
.nav-links a {
  font-family: var(--f-ui); font-size: 11px; font-weight: 500;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--text-muted); text-decoration: none;
  position: relative; padding: 2px 0;
  transition: color 0.2s;
}
.nav-links a::after {
  content: ''; position: absolute; left: 0; right: 100%; bottom: -3px;
  height: 1.5px; background: var(--accent);
  transition: right 0.32s var(--ease-lux);
}
.nav-links a:hover { color: var(--accent-ink); }
.nav-links a:hover::after { right: 0; }

/* Reading progress: hairline above the nav. */
#progress {
  position: fixed; top: 0; left: 0; z-index: 101;
  height: 2px; width: 100%;
  transform: scaleX(0); transform-origin: left;
  background: linear-gradient(90deg, var(--accent), rgba(92,124,88,0.4));
  pointer-events: none;
  opacity: 0; transition: opacity 0.4s;
}
#progress.on { opacity: 1; }

.nav-now, .footer-now {
  font-family: var(--f-ui); font-size: 11px; font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--accent-ink); text-decoration: none;
  transition: opacity 0.2s;
}
.nav-now:hover, .footer-now:hover { opacity: 0.6; }
.footer-now { font-size: 10px; letter-spacing: 0.14em; }

/* Mobile menu button */
#menu-btn {
  display: none;
  background: none; border: none;
  width: 40px; height: 40px;
  position: relative; z-index: 202;
  cursor: pointer;
}
#menu-btn span {
  position: absolute; left: 8px; right: 8px; height: 1.5px;
  background: var(--text);
  transition: transform 0.4s var(--ease-spring), opacity 0.25s, background 0.25s;
}
#menu-btn span:nth-child(1) { top: 15px; }
#menu-btn span:nth-child(2) { top: 24px; }
#menu-btn.open span:nth-child(1) { transform: translateY(4.5px) rotate(45deg); background: var(--accent); }
#menu-btn.open span:nth-child(2) { transform: translateY(-4.5px) rotate(-45deg); background: var(--accent); }

/* Mobile menu panel */
#mobile-menu {
  position: fixed; inset: 0; z-index: 201;
  background: rgba(243,242,236,0.97);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  display: flex; flex-direction: column; justify-content: center;
  padding: 0 32px;
  opacity: 0; visibility: hidden;
  transition: opacity 0.45s var(--ease-lux), visibility 0s 0.45s;
}
#mobile-menu.open {
  opacity: 1; visibility: visible;
  transition: opacity 0.45s var(--ease-lux);
}
#mobile-menu ul { list-style: none; }
#mobile-menu li { overflow: hidden; }
#mobile-menu a {
  display: block;
  font-family: var(--f-display); font-weight: 400;
  font-size: clamp(38px, 9vw, 54px); line-height: 1.32;
  color: var(--text); text-decoration: none;
  transform: translateY(110%);
  transition: transform 0.6s var(--ease-lux), color 0.2s;
}
#mobile-menu.open a { transform: translateY(0); }
#mobile-menu a:hover, #mobile-menu a:active { color: var(--accent-ink); font-style: italic; }
#mobile-menu li:nth-child(1) a { transition-delay: 0.05s; }
#mobile-menu li:nth-child(2) a { transition-delay: 0.10s; }
#mobile-menu li:nth-child(3) a { transition-delay: 0.15s; }
#mobile-menu li:nth-child(4) a { transition-delay: 0.20s; }
#mobile-menu li:nth-child(5) a { transition-delay: 0.25s; }
#mobile-menu li:nth-child(6) a { transition-delay: 0.30s; }
#mobile-menu li:nth-child(7) a { transition-delay: 0.35s; }
.mobile-menu-foot {
  position: absolute; bottom: 36px; left: 32px;
  font-family: var(--f-ui); font-size: 10px; font-weight: 500;
  letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--text-muted);
}

/* ══ HERO ══════════════════════════════════════════════════════════
   A layered "soft abstract" scene: depth blobs drift with mouse and
   scroll (parallax) and breathe on their own. Driven by js/hero.js.  */
#hero {
  /* Centred, not bottom-anchored: flex-end dumped every spare pixel of a
     tall viewport into one void above the name. Centring splits it, and
     the top pad clears the fixed nav. */
  min-height: 100vh; min-height: 100svh;
  display: flex; flex-direction: column; justify-content: center;
  padding: 104px var(--pad-x) 112px;
  position: relative; overflow: hidden;
  background:
    radial-gradient(120% 90% at 72% 8%, #FBFAF4 0%, transparent 55%),
    linear-gradient(168deg, #F6F5EF 0%, #EFEEE5 58%, #E9E9DE 100%);
}
.hero-bg { position: absolute; inset: 0; z-index: 0; }
.hero-scene { position: absolute; inset: -8%; }
/* Parallax layers (transformed by js/hero.js); the blob inside keeps
   its own idle "breathing" float so the two never fight. */
.p-layer { position: absolute; inset: 0; will-change: transform; }

.blob {
  position: absolute; border-radius: 50%;
  pointer-events: none; will-change: transform;
  filter: blur(2px);
  mix-blend-mode: multiply;
}
.blob-1 {
  width: 60vw; height: 60vw; max-width: 780px; max-height: 780px;
  top: -14%; right: -8%;
  background: radial-gradient(circle at 38% 38%, rgba(122,150,110,0.32) 0%, rgba(122,150,110,0.10) 42%, transparent 68%);
  animation: float-a 15s ease-in-out infinite;
}
.blob-2 {
  width: 40vw; height: 40vw; max-width: 520px; max-height: 520px;
  bottom: -12%; left: -6%;
  background: radial-gradient(circle at 50% 50%, rgba(176,130,56,0.20) 0%, transparent 66%);
  animation: float-b 19s ease-in-out infinite;
}
.blob-3 {
  width: 30vw; height: 30vw; max-width: 380px; max-height: 380px;
  top: 26%; left: 16%;
  background: radial-gradient(circle at 50% 50%, rgba(70,97,62,0.16) 0%, transparent 64%);
  animation: float-a 21s ease-in-out infinite 1.5s;
}
.blob-4 {
  width: 16vw; height: 16vw; max-width: 220px; max-height: 220px;
  top: 16%; right: 24%;
  background: radial-gradient(circle at 50% 50%, rgba(167,93,66,0.16) 0%, transparent 62%);
  animation: float-b 13s ease-in-out infinite 0.6s;
}
@keyframes float-a {
  0%,100% { transform: translate(0,0) scale(1); }
  40%     { transform: translate(-26px, 22px) scale(1.05); }
  70%     { transform: translate(18px, -20px) scale(0.96); }
}
@keyframes float-b {
  0%,100% { transform: translate(0,0) scale(1); }
  50%     { transform: translate(24px, -18px) scale(1.06); }
}

.hero-inner { position: relative; z-index: 2; }
.hero-eyebrow {
  font-family: var(--f-ui); font-size: 11px; font-weight: 600;
  letter-spacing: 0.24em; text-transform: uppercase;
  color: var(--accent-ink); margin-bottom: 26px;
  display: inline-flex; align-items: center; gap: 12px;
}
.hero-eyebrow::before {
  content: ''; width: 22px; height: 1.5px; background: var(--accent);
}
h1.hero-name {
  font-family: var(--f-display);
  font-size: clamp(74px, 11vw, 158px);
  font-weight: 400; line-height: 0.94;
  letter-spacing: -0.03em; color: var(--text);
}
h1.hero-name em {
  font-style: italic; color: var(--accent-ink); font-weight: 400;
}
.hero-tagline {
  font-family: var(--f-display); font-style: italic;
  font-size: clamp(19px, 2.3vw, 27px); font-weight: 400;
  color: var(--text-2); margin-top: 26px;
  max-width: 30ch; line-height: 1.45;
}
.hero-links { display: flex; gap: 28px; margin-top: 46px; flex-wrap: wrap; }
.hero-link {
  font-family: var(--f-ui); font-size: 11px; font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--text-2); text-decoration: none;
  padding-bottom: 5px; border-bottom: 1.5px solid var(--border-lt);
  transition: color 0.2s, border-color 0.2s;
}
.hero-link:hover { color: var(--accent-ink); border-color: var(--accent); }

.scroll-cue {
  position: absolute; bottom: 32px; left: var(--pad-x); z-index: 2;
  font-family: var(--f-ui); font-size: 10px; font-weight: 500;
  letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--text-muted);
  display: flex; align-items: center; gap: 12px;
}
.scroll-cue::before {
  content: ''; width: 30px; height: 1.5px; background: var(--text-muted);
  animation: cue-sweep 2.6s var(--ease-lux) infinite;
  transform-origin: left;
}
@keyframes cue-sweep {
  0%   { transform: scaleX(0.3); opacity: 0.4; }
  50%  { transform: scaleX(1);   opacity: 1; }
  100% { transform: scaleX(0.3); opacity: 0.4; }
}

/* Hero entrance: plays once on load, with a little spring. */
.hero-in { opacity: 0; transform: translateY(30px); }
.loaded .hero-in {
  opacity: 1; transform: translateY(0);
  transition: opacity 1s var(--ease-lux), transform 1s var(--ease-bounce);
}
.loaded .hero-in.h2delay { transition-delay: 0.15s; }
.loaded .hero-in.h3delay { transition-delay: 0.32s; }
.loaded .hero-in.h4delay { transition-delay: 0.52s; }

/* ══ SHARED SECTION LANGUAGE ═══════════════════════════════════════ */
.eyebrow {
  font-family: var(--f-ui); font-size: 10px; font-weight: 600;
  letter-spacing: 0.24em; text-transform: uppercase;
  color: var(--accent-ink);
  display: flex; align-items: center; gap: 14px;
  margin-bottom: 28px;
}
.eyebrow::after {
  content: ''; height: 1.5px; background: var(--accent);
  width: 0; transition: width 0.6s var(--ease-lux) 0.3s; opacity: 0.5;
}
.reveal.visible .eyebrow::after, .eyebrow.visible::after { width: 56px; }

.section-h2 {
  font-family: var(--f-display);
  font-size: clamp(40px, 4.2vw, 62px);
  font-weight: 400; line-height: 1.06;
  letter-spacing: -0.02em;
  margin-bottom: 32px; text-wrap: balance;
  color: var(--text);
}
.section-h2 em { font-style: italic; color: var(--accent-ink); }

/* ══ REVEAL SYSTEM ═════════════════════════════════════════════════
   .reveal          rise + settle (default)
   .reveal.rv-spring  bouncy pop with overshoot
   .reveal.rv-slow    long, gentle fade for large display text
   .rv-left / .rv-right  directional                                  */
.reveal {
  opacity: 0; transform: translateY(46px);
  transition: opacity 0.82s var(--ease-lux), transform 0.86s var(--ease-lux);
}
.reveal.rv-spring {
  transform: translateY(34px) scale(0.96);
  transition: opacity 0.55s var(--ease-swift), transform 0.7s var(--ease-bounce);
}
.reveal.rv-slow {
  transform: translateY(30px);
  transition: opacity 1.15s var(--ease-lux), transform 1.15s var(--ease-lux);
}
.reveal.rv-left  { transform: translateX(-46px); }
.reveal.rv-right { transform: translateX(46px); }
.reveal.visible  { opacity: 1; transform: none; }
.d1 { transition-delay: 0.10s; }
.d2 { transition-delay: 0.24s; }
.d3 { transition-delay: 0.40s; }
.d4 { transition-delay: 0.56s; }

/* Blur-to-sharp: body copy and cards resolve into focus. */
.about-body p, .ctcaf-body p, .writing-body p, .contact-body p,
.culture-desc {
  transition: filter 0.9s var(--ease-lux);
}
.reveal:not(.visible) .about-body p,
.reveal:not(.visible) .ctcaf-body p,
.reveal:not(.visible) .writing-body p,
.reveal:not(.visible) .contact-body p,
.reveal.culture-desc:not(.visible),
.reveal:not(.visible) .pick-ranked,
.reveal:not(.visible) .essay-card { filter: blur(6px); }

/* Heading character stagger */
/* Words are atomic: they hold their characters together across a wrap. */
.section-h2 .word { display: inline-block; }
.section-h2 .ch {
  display: inline-block;
  opacity: 0; transform: translateY(0.4em) rotate(2deg);
  transition: opacity 0.5s var(--ease-lux), transform 0.6s var(--ease-bounce);
  transition-delay: calc(var(--ci, 0) * 16ms);
}
.section-h2.chars-in .ch { opacity: 1; transform: none; }

/* Dividers: the line draws left to right, a spark travels ahead. */
.divider { height: 1px; margin: 0 var(--pad-x); position: relative; }
.divider::before {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(90deg,
    transparent 0%, var(--border) 15%,
    rgba(92,124,88,0.5) 50%,
    var(--border) 85%, transparent 100%);
  transform: scaleX(0); transform-origin: left;
  transition: transform 1.05s var(--ease-swift);
}
.divider::after {
  content: ''; position: absolute; top: -1.5px;
  width: 28px; height: 4px; border-radius: 3px;
  background: radial-gradient(ellipse, rgba(92,124,88,0.85), transparent 70%);
  left: 0; opacity: 0;
}
.divider.visible::before { transform: scaleX(1); }
.divider.visible::after  { animation: spark 1.05s var(--ease-swift) forwards; }
@keyframes spark {
  0%   { left: 0;    opacity: 0; }
  12%  { opacity: 1; }
  88%  { opacity: 1; }
  100% { left: calc(100% - 28px); opacity: 0; }
}

/* Scroll-driven letterform drift for section headings (progressive
   enhancement; ignored by browsers without scroll timelines). */
@supports (animation-timeline: view()) {
  .section-h2 {
    animation: h2-drift linear both;
    animation-timeline: view();
    animation-range: entry 0% entry 90%;
  }
  @keyframes h2-drift {
    from { letter-spacing: 0.01em; opacity: 0.78; }
    to   { letter-spacing: -0.02em; opacity: 1; }
  }
}

/* ══ SECTION AMBIENCE ══════════════════════════════════════════════
   Soft orbs that drift on scroll (js: [data-parallax]) to give the
   space between sections real depth. They sit behind the content;
   every direct child of these sections is lifted above them.        */
#about, #work, #culture, #contact { position: relative; }
#about  > *:not(.sec-orb),
#work   > *:not(.sec-orb),
#culture > *:not(.sec-orb),
#contact > *:not(.sec-orb) { position: relative; z-index: 1; }
.sec-orb {
  position: absolute; border-radius: 50%;
  pointer-events: none; z-index: 0;
  filter: blur(8px); mix-blend-mode: multiply;
  will-change: transform;
}
.sec-orb.s1 { width: 560px; height: 560px; top: -180px; right: -150px;
  background: radial-gradient(circle, rgba(92,124,88,0.16) 0%, transparent 66%); }
.sec-orb.s2 { width: 460px; height: 460px; bottom: -150px; left: -160px;
  background: radial-gradient(circle, rgba(70,97,62,0.14) 0%, transparent 64%); }
.sec-orb.s3 { width: 520px; height: 520px; top: 4%; right: -180px;
  background: radial-gradient(circle, rgba(176,130,56,0.15) 0%, transparent 64%); }
.sec-orb.s4 { width: 440px; height: 440px; bottom: -130px; left: -120px;
  background: radial-gradient(circle, rgba(92,124,88,0.15) 0%, transparent 64%); }

/* ══ ABOUT ═════════════════════════════════════════════════════════ */
#about {
  padding: 120px var(--pad-x) 104px;
  display: grid; grid-template-columns: 1.12fr 0.88fr; gap: 100px;
  align-items: start;
}
.about-body p {
  font-family: var(--f-ui); font-size: 18px;
  font-weight: 400; line-height: 1.75;
  color: var(--text-2); margin-bottom: 20px; max-width: 60ch;
}
.about-body p:last-child { margin-bottom: 0; }

/* ── Photo cluster: layered tiles at three depths ────────────────────
   Height is driven by padding-bottom on the frame, so the tiles can be
   absolutely positioned without the column collapsing. */
.photo-frame {
  position: relative;
  margin-bottom: 30px;
  padding-bottom: 118%;
}
.pc {
  position: absolute;
  border-radius: 3px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: 0 22px 50px -28px rgba(34,48,42,0.5);
  /* --py (scroll) and --mx/--my (mouse) are written by initPhotoCluster. */
  transform: translate3d(var(--mx, 0px), calc(var(--py, 0px) + var(--my, 0px)), 0);
  transition: box-shadow 0.5s var(--ease-lux);
  will-change: transform;
  margin: 0;
}
.pc img {
  width: 100%; height: 100%; display: block;
  object-fit: cover;
  filter: contrast(1.02) saturate(0.94);
}
.pc:hover { box-shadow: 0 30px 64px -26px rgba(34,48,42,0.62); }

/* Lead portrait: back layer, drifts least. */
.pc-1 { top: 0;    left: 0;   width: 62%; height: 62%; z-index: 1; }
/* Tux: back-right, sits above the lead's shoulder. */
.pc-4 { top: 4%;   right: 0;  width: 34%; height: 40%; z-index: 2; }
/* Fishing: mid layer, overlaps toward the right. */
.pc-2 { top: 48%;  right: 4%; width: 44%; height: 36%; z-index: 3; }
/* Water: front layer, drifts most. */
.pc-3 { bottom: 0; left: 6%;  width: 46%; height: 34%; z-index: 4; }

.photo-glow {
  position: absolute; width: 260px; height: 260px; border-radius: 50%;
  background: radial-gradient(circle, rgba(92,124,88,0.14) 0%, transparent 70%);
  bottom: -34px; right: -34px; pointer-events: none;
}

.stats { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.stat-wide { grid-column: 1 / -1; }
.stat-wide .stat-n { font-size: 27px; }
.stat {
  padding: 20px 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 2.5px solid var(--accent);
  border-radius: 3px;
  transition: background 0.2s, transform 0.35s var(--ease-bounce), box-shadow 0.35s var(--ease-lux);
}
.stat:hover {
  background: var(--surface-2); transform: translateY(-4px);
  box-shadow: 0 14px 30px -18px rgba(34,48,42,0.4);
}
.stat-n {
  display: block;
  font-family: var(--f-display); font-size: 34px;
  font-weight: 400; letter-spacing: -0.02em;
  line-height: 1; color: var(--text);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;   /* "400 GWh" must never break across lines */
}
.stat-l {
  display: block; margin-top: 7px;
  font-family: var(--f-ui); font-size: 10px;
  font-weight: 500; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--text-muted);
}

/* ══ WORK ══════════════════════════════════════════════════════════ */
#work { padding: 104px var(--pad-x); max-width: 1120px; }

.timeline { position: relative; padding-left: 34px; margin-top: 56px; }
.timeline::before {
  content: ''; position: absolute;
  left: 0; top: 6px; bottom: 0; width: 1.5px;
  background: linear-gradient(to bottom,
    var(--accent) 0%, var(--border-lt) 32%, transparent 100%);
  transform: scaleY(0); transform-origin: top;
  transition: transform 1.4s var(--ease-lux) 0.2s;
}
.timeline.visible::before { transform: scaleY(1); }

.t-item { position: relative; padding-bottom: 56px; }
.t-item:last-child { padding-bottom: 0; }

/* Band label that sets a group (e.g. "Projects & Initiatives") apart from
   the paid roles above it, mirroring the resume's section break. */
.t-group-label {
  font-family: var(--f-ui); font-size: 10px; font-weight: 600;
  letter-spacing: 0.24em; text-transform: uppercase;
  color: var(--accent-ink);
  display: flex; align-items: center; gap: 14px;
  margin: 6px 0 36px; padding-top: 40px;
  border-top: 1px solid var(--border-lt);
}
.t-group-label::after {
  content: ''; height: 1.5px; background: var(--accent);
  width: 0; transition: width 0.6s var(--ease-lux) 0.3s; opacity: 0.5;
}
.t-group-label.visible::after { width: 56px; }

.t-dot {
  position: absolute; left: -38px; top: 7px;
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--bg); border: 1.5px solid var(--accent);
  transform: scale(0);
  transition: transform 0.5s var(--ease-bounce) 0.35s;
}
.t-item.visible .t-dot { transform: scale(1); }
.t-item:first-child .t-dot {
  background: var(--accent);
  box-shadow: 0 0 0 5px rgba(92,124,88,0.14);
}

/* The whole headline is the hit target; bullets live in .t-panel. */
.t-toggle {
  display: flex; align-items: flex-start; gap: 20px;
  width: 100%; padding: 4px 0; border: 0; background: none;
  text-align: left; cursor: pointer; color: inherit;
  transition: transform 0.35s var(--ease-lux);
}
.t-toggle:hover { transform: translateX(3px); }
.t-toggle:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 6px; border-radius: 2px;
}
.t-head-main { flex: 1; min-width: 0; }

.t-header {
  display: flex; align-items: baseline;
  flex-wrap: wrap; gap: 14px; margin-bottom: 6px;
}
.t-company {
  font-family: var(--f-display); font-size: 27px;
  font-weight: 500; color: var(--text); letter-spacing: -0.01em;
  transition: color 0.25s var(--ease-swift);
}
.t-toggle:hover .t-company { color: var(--accent-ink); }
.t-dates {
  font-family: var(--f-ui); font-size: 10px;
  font-weight: 500; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--text-muted);
}
.t-title {
  display: block;
  font-family: var(--f-display); font-style: italic;
  font-size: 17px; font-weight: 400;
  color: var(--accent-ink);
}

/* Company logo: muted to greyscale so BMO's red/blue and Gallagher's
   globe don't shout over the sage palette; true colour on hover only. */
.t-logo {
  flex: none;
  display: flex; align-items: center; justify-content: center;
  width: 74px; height: 40px;
  margin-top: 2px;
  opacity: 0.42;
  filter: grayscale(1) contrast(0.9);
  transition: opacity 0.35s var(--ease-lux), filter 0.35s var(--ease-lux),
              transform 0.4s var(--ease-bounce);
}
.t-logo img {
  max-width: 100%; max-height: 100%;
  object-fit: contain; display: block;
}
.t-toggle:hover .t-logo {
  opacity: 1; filter: grayscale(0) contrast(1);
  transform: translateY(-2px);
}

/* External link out of an expanded entry (Highstorm). */
.t-link {
  display: inline-block; margin-top: 18px;
  font-family: var(--f-ui); font-size: 13px; font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--accent-ink); text-decoration: none;
  border-bottom: 1px solid rgba(70,97,62,0.32);
  padding-bottom: 2px;
  transition: border-color 0.25s, transform 0.35s var(--ease-lux);
}
.t-link:hover { border-color: var(--accent-ink); transform: translateX(3px); }

/* Chevron: a rotating caret that points down when there is more to read. */
.t-chev {
  flex: none; width: 11px; height: 11px; margin-top: 11px;
  border-right: 1.5px solid var(--accent);
  border-bottom: 1.5px solid var(--accent);
  transform: rotate(45deg);
  transition: transform 0.45s var(--ease-bounce), opacity 0.25s;
  opacity: 0.65;
}
.t-toggle:hover .t-chev { opacity: 1; }
.t-item.is-open .t-chev { transform: rotate(-135deg); }

.t-panel {
  max-height: 0; overflow: hidden;
  transition: max-height 0.5s var(--ease-lux), opacity 0.4s var(--ease-lux);
  opacity: 0;
}
.t-item.is-open .t-panel { opacity: 1; }
.t-bullets {
  list-style: none; display: flex; flex-direction: column; gap: 9px;
  padding-top: 16px;
}
.t-bullets li {
  font-family: var(--f-ui); font-size: 15.5px;
  font-weight: 400; line-height: 1.62;
  color: var(--text-2); padding-left: 20px; position: relative;
  max-width: 66ch;
}
.t-bullets li::before {
  content: ''; position: absolute; left: 0; top: 0.68em;
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent); opacity: 0.7;
}

/* ── Education: a quiet coda under the timeline ──────────────────────
   UW purple/gold, held back deliberately: the purple lives in the rule
   and the school name, the gold is a hairline. Against oat-white the
   full-strength brand pair would shout, so the ground stays a 3% purple
   wash rather than a purple block. */
.education {
  --uw-purple: #4B2E83;
  --uw-gold:   #B7A57A;
  position: relative;
  display: flex; align-items: center; gap: 24px;
  margin-top: 56px; padding: 26px 28px;
  background:
    linear-gradient(180deg, rgba(75,46,131,0.045) 0%, rgba(75,46,131,0.015) 100%),
    var(--surface);
  border: 1px solid rgba(75,46,131,0.16);
  border-left: 2.5px solid var(--uw-purple);
  border-radius: 3px;
  max-width: 620px;
  overflow: hidden;
}
/* Gold hairline riding just inside the purple edge. */
.education::before {
  content: ''; position: absolute;
  left: 0; top: 0; bottom: 0; width: 1.5px;
  background: linear-gradient(180deg, var(--uw-gold) 0%, rgba(183,165,122,0) 82%);
}
/* Block W keeps its real purple/gold; it is the one saturated mark on the
   page, so it stays small and the tile around it stays quiet. */
.edu-logo {
  flex: none;
  width: 58px; height: 58px;
  display: flex; align-items: center; justify-content: center;
  transition: transform 0.45s var(--ease-bounce);
}
.edu-logo img { max-width: 100%; max-height: 100%; object-fit: contain; display: block; }
.education:hover .edu-logo { transform: translateY(-3px) scale(1.04); }
.edu-text { min-width: 0; }

.edu-label {
  font-family: var(--f-ui); font-size: 10px; font-weight: 500;
  letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--text-muted); margin-bottom: 10px;
}
.edu-school {
  font-family: var(--f-display); font-size: 21px;
  font-weight: 500; color: var(--uw-purple); letter-spacing: -0.01em;
}
.edu-degree {
  font-family: var(--f-display); font-style: italic;
  font-size: 16px; color: var(--text-2); margin-top: 4px;
}
.edu-dates {
  font-family: var(--f-ui); font-size: 10px; font-weight: 500;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--text-muted); margin-top: 9px;
}

/* ══ SKILLS DRAWER ═════════════════════════════════════════════════ */
/* A tab rides the right edge while Work is on screen; it pulls out a
   panel of skill groups. Fixed, so it floats above the section. */
#skills-tab {
  position: fixed; z-index: 60;
  right: 0; top: 50%;
  transform: translate(100%, -50%);
  padding: 16px 13px;
  background: var(--accent); color: #FBFAF6;
  border: 0; border-radius: 4px 0 0 4px;
  cursor: pointer;
  font-family: var(--f-ui); font-size: 10px; font-weight: 600;
  letter-spacing: 0.14em; text-transform: uppercase;
  writing-mode: vertical-rl;
  box-shadow: -6px 0 24px -12px rgba(34,48,42,0.5);
  opacity: 0; pointer-events: none;
  transition: transform 0.55s var(--ease-bounce), opacity 0.35s var(--ease-lux), background 0.25s;
}
#skills-tab.is-live {
  transform: translate(0, -50%);
  opacity: 1; pointer-events: auto;
}
#skills-tab:hover { background: var(--accent-ink); }
#skills-tab:focus-visible { outline: 2px solid var(--accent-ink); outline-offset: 3px; }

#skills-scrim {
  /* Above #nav (100) and the mobile menu (201/202) so nothing paints over it. */
  position: fixed; inset: 0; z-index: 210;
  background: rgba(34,48,42,0.28);
  backdrop-filter: blur(2px);
  opacity: 0; transition: opacity 0.4s var(--ease-lux);
}
#skills-scrim.is-open { opacity: 1; }

#skills-drawer {
  position: fixed; z-index: 220;
  top: 0; right: 0; bottom: 0;
  width: min(430px, 92vw);
  padding: 68px 40px 48px;
  overflow-y: auto;
  /* Don't hand the scroll off to the page once the drawer bottoms out. */
  overscroll-behavior: contain;
  background: var(--surface);
  border-left: 1px solid var(--border);
  box-shadow: -30px 0 70px -40px rgba(34,48,42,0.55);
  transform: translateX(100%);
  /* visibility is delayed off the close so the slide-out stays visible */
  transition: transform 0.6s var(--ease-lux), visibility 0s linear 0.6s;
  visibility: hidden;
}
#skills-drawer.is-open {
  transform: translateX(0); visibility: visible;
  transition: transform 0.6s var(--ease-lux), visibility 0s;
}

#skills-close {
  position: absolute; top: 22px; right: 26px;
  width: 34px; height: 34px;
  background: none; border: 1px solid var(--border);
  border-radius: 50%; cursor: pointer;
  font-size: 20px; line-height: 1; color: var(--text-2);
  transition: background 0.2s, transform 0.3s var(--ease-bounce);
}
#skills-close:hover { background: var(--surface-2); transform: rotate(90deg); }
#skills-close:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.skills-h {
  font-family: var(--f-display); font-size: 30px;
  font-weight: 400; letter-spacing: -0.02em;
  color: var(--text); margin: 8px 0 30px;
}
.skills-h em { font-style: italic; color: var(--accent-ink); }

.sk-group { margin-bottom: 28px; }
.sk-group-t {
  font-family: var(--f-ui); font-size: 10px; font-weight: 600;
  letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--text-muted);
  padding-bottom: 9px; margin-bottom: 13px;
  border-bottom: 1px solid var(--border);
}
.sk-list { list-style: none; display: flex; flex-wrap: wrap; gap: 7px; }
.sk-list li {
  font-family: var(--f-ui); font-size: 13px;
  color: var(--text-2);
  padding: 6px 11px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 100px;
  transition: transform 0.3s var(--ease-bounce), border-color 0.2s, color 0.2s;
}
.sk-list li:hover {
  transform: translateY(-2px);
  border-color: var(--accent); color: var(--accent-ink);
}

/* ══ CTCAF ═════════════════════════════════════════════════════════ */
#ctcaf {
  padding: 116px var(--pad-x);
  background:
    radial-gradient(90% 60% at 85% 0%, rgba(92,124,88,0.06) 0%, transparent 60%),
    var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  position: relative; overflow: hidden;
}
.ctcaf-bg-orb {
  position: absolute; width: 620px; height: 620px; border-radius: 50%;
  background: radial-gradient(circle, rgba(92,124,88,0.08) 0%, transparent 66%);
  top: -220px; right: -160px; pointer-events: none;
  animation: float-a 24s ease-in-out infinite;
}
.ctcaf-grid {
  position: relative; z-index: 1;
  display: grid; grid-template-columns: 1.1fr 0.9fr;
  gap: 100px; align-items: start;
}
.ctcaf-stats { position: sticky; top: 118px; }
.ctcaf-body p {
  font-family: var(--f-ui); font-size: 17px;
  font-weight: 400; line-height: 1.75;
  color: var(--text-2); margin-bottom: 18px; max-width: 62ch;
}
.ctcaf-body p:last-of-type { margin-bottom: 30px; }
.ctcaf-cta {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--f-ui); font-size: 11px; font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--accent-ink); text-decoration: none;
  padding-bottom: 4px; border-bottom: 1.5px solid var(--accent);
  transition: gap 0.3s var(--ease-spring), opacity 0.2s;
}
.ctcaf-cta:hover { gap: 14px; opacity: 0.75; }

.ctcaf-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.cs {
  padding: 32px 22px; text-align: center;
  background: var(--bg); border: 1px solid var(--border);
  border-radius: 3px;
  transition: border-color 0.25s, transform 0.4s var(--ease-bounce), box-shadow 0.4s var(--ease-lux);
}
.cs:hover {
  border-color: var(--accent); transform: translateY(-5px);
  box-shadow: 0 16px 34px -20px rgba(34,48,42,0.45);
}
.cs-n {
  display: block;
  font-family: var(--f-display); font-size: 48px;
  font-weight: 400; color: var(--accent-ink);
  letter-spacing: -0.02em; line-height: 1;
  font-variant-numeric: tabular-nums;
}
.cs-l {
  display: block; margin-top: 12px;
  font-family: var(--f-ui); font-size: 10px;
  font-weight: 500; letter-spacing: 0.13em;
  text-transform: uppercase; color: var(--text-muted);
}

/* ══ WRITING ═══════════════════════════════════════════════════════ */
#writing {
  padding: 116px var(--pad-x);
  display: grid; grid-template-columns: 0.92fr 1.08fr;
  gap: 100px; align-items: start;
}
#writing .section-h2 { font-size: clamp(46px, 5vw, 76px); }
.writing-body p {
  font-family: var(--f-ui); font-size: 17px;
  font-weight: 400; line-height: 1.75;
  color: var(--text-2); margin-bottom: 18px; max-width: 58ch;
}

/* Essay cards */
.essays-list { display: flex; flex-direction: column; gap: 14px; }
.essay-card {
  display: block; text-decoration: none;
  border: 1px solid var(--border);
  background: var(--surface);
  padding: 30px 32px; border-radius: 4px;
  position: relative;
  transition: border-color 0.25s, transform 0.35s var(--ease-bounce), background 0.25s,
              box-shadow 0.35s var(--ease-lux), filter 0.9s var(--ease-lux);
}
.essay-card:hover {
  border-color: var(--accent);
  background: var(--surface);
  transform: translateY(-3px);
  box-shadow: 0 18px 40px -22px rgba(34,48,42,0.4);
}
.essay-card-meta {
  display: flex; align-items: center; gap: 14px;
  font-family: var(--f-ui); font-size: 10px; font-weight: 500;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--text-muted); margin-bottom: 12px;
}
.essay-card-meta .tag { color: var(--accent-ink); }
.essay-card-title {
  font-family: var(--f-display); font-size: 28px;
  font-weight: 500; line-height: 1.18; color: var(--text);
  margin-bottom: 9px; letter-spacing: -0.01em;
}
.essay-card:hover .essay-card-title { font-style: italic; color: var(--accent-ink); }
.essay-card-excerpt {
  font-family: var(--f-ui); font-size: 15px;
  font-weight: 400; line-height: 1.6; color: var(--text-2);
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical;
  overflow: hidden;
}
.essay-card-arrow {
  position: absolute; right: 28px; top: 30px;
  color: var(--text-muted); font-size: 18px;
  transition: color 0.2s, transform 0.35s var(--ease-spring);
}
.essay-card:hover .essay-card-arrow { color: var(--accent); transform: translateX(5px); }

.sub-card {
  border: 1px solid var(--border);
  padding: 42px 38px; border-radius: 4px;
  background: var(--surface);
  display: flex; flex-direction: column; gap: 26px;
}
.sub-coming {
  font-family: var(--f-display); font-style: italic;
  font-size: 23px; font-weight: 400; color: var(--text-2);
  line-height: 1.4;
}
.sub-coming em { color: var(--accent-ink); font-style: normal; }
.sub-topics { display: flex; flex-wrap: wrap; gap: 8px; }
.topic-tag {
  font-family: var(--f-ui); font-size: 10px; font-weight: 500;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--text-muted); padding: 6px 13px;
  border: 1px solid var(--border); border-radius: 100px;
  transition: color 0.2s, border-color 0.2s, transform 0.3s var(--ease-spring);
}
.topic-tag:hover { color: var(--accent-ink); border-color: var(--accent); transform: translateY(-2px); }
.sub-btn {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--f-ui); font-size: 11px; font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--surface); background: var(--accent);
  text-decoration: none; padding: 15px 30px; border-radius: 100px;
  align-self: flex-start;
  transition: background 0.2s, transform 0.3s var(--ease-bounce), box-shadow 0.3s var(--ease-lux);
}
.sub-btn:hover {
  background: var(--accent-ink); transform: translateY(-3px);
  box-shadow: 0 14px 26px -14px rgba(70,97,62,0.7);
}
.substack-compact {
  display: inline-flex; align-items: center; gap: 10px;
  margin-top: 22px; font-family: var(--f-ui); font-size: 10px;
  font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--text-2); text-decoration: none;
  border-bottom: 1.5px solid var(--border-lt); padding-bottom: 4px;
  transition: color 0.2s, border-color 0.2s;
}
.substack-compact:hover { color: var(--accent-ink); border-color: var(--accent); }

/* ══ CULTURE ═══════════════════════════════════════════════════════ */
#culture {
  padding: 116px var(--pad-x) 104px;
  background:
    radial-gradient(80% 50% at 12% 0%, rgba(176,130,56,0.05) 0%, transparent 55%),
    var(--bg);
  border-top: 1px solid var(--border);
}
.culture-top {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 100px; align-items: end; margin-bottom: 60px;
}
.culture-desc {
  font-family: var(--f-display); font-style: italic;
  font-size: 21px; font-weight: 400;
  color: var(--text-2); line-height: 1.55;
  padding-top: 6px; max-width: 42ch;
}

/* Live music */
.music-live { margin-bottom: 60px; }
.music-live-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 22px;
}
.music-live-label {
  font-family: var(--f-ui); font-size: 10px; font-weight: 600;
  letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--accent-ink); display: flex; align-items: center; gap: 9px;
}
.music-live-label::before {
  content: ''; width: 7px; height: 7px; border-radius: 50%;
  background: var(--accent);
  animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse {
  0%,100% { opacity: 1; transform: scale(1); }
  50%     { opacity: 0.35; transform: scale(0.8); }
}
.artists-grid { display: flex; gap: 22px; flex-wrap: wrap; }
.artist-chip {
  display: flex; flex-direction: column; align-items: center; gap: 9px;
  width: 76px;
}
.artist-img {
  width: 60px; height: 60px; border-radius: 50%;
  object-fit: cover; border: 1px solid var(--border);
  filter: saturate(0.92);
  transition: filter 0.2s, border-color 0.2s, transform 0.35s var(--ease-bounce);
}
.artist-chip:hover .artist-img {
  filter: saturate(1.05); border-color: var(--accent); transform: scale(1.1) translateY(-2px);
}
.artist-name {
  font-family: var(--f-ui); font-size: 9px; font-weight: 500;
  letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--text-muted); text-align: center;
  white-space: nowrap; overflow: hidden;
  text-overflow: ellipsis; width: 100%;
}
.tracks-list { margin-top: 26px; display: flex; flex-direction: column; gap: 7px; }
.track-row {
  display: flex; align-items: center; gap: 15px;
  padding: 12px 16px; border: 1px solid var(--border);
  background: var(--surface); border-radius: 3px;
  transition: border-color 0.2s, transform 0.3s var(--ease-spring);
}
.track-row:hover { border-color: var(--accent); transform: translateX(4px); }
.track-pos {
  font-family: var(--f-display); font-size: 16px; font-weight: 400;
  color: var(--text-muted); width: 16px; text-align: right; flex-shrink: 0;
  font-variant-numeric: tabular-nums;
}
.track-info { flex: 1; min-width: 0; }
.track-name {
  font-family: var(--f-display); font-size: 17px;
  font-weight: 500; color: var(--text);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.track-artist {
  font-family: var(--f-ui); font-size: 9px; font-weight: 500;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--text-muted); margin-top: 3px;
}
.music-loading, .music-error {
  font-family: var(--f-ui); font-size: 10px; letter-spacing: 0.13em;
  text-transform: uppercase; color: var(--text-muted); padding: 16px 0;
}
.spotify-compact {
  display: inline-flex; align-items: center; gap: 10px;
  margin-top: 24px; font-family: var(--f-ui); font-size: 10px;
  font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--text-2); text-decoration: none;
  border-bottom: 1.5px solid var(--border-lt); padding-bottom: 4px;
  transition: color 0.2s, border-color 0.2s;
}
.spotify-compact:hover { color: #1DB954; border-color: #1DB954; }
.sp-dot { width: 8px; height: 8px; border-radius: 50%; background: #1DB954; flex-shrink: 0; }

/* ══ PICKS GRID ════════════════════════════════════════════════════ */
.picks-sections {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px 22px;
  align-items: start;
  margin-top: 52px;
}
.picks-section { border-top: 2.5px solid var(--border); padding-top: 20px; }
.picks-section--green { border-top-color: var(--accent); }
.picks-section--red   { border-top-color: var(--clay); }
.picks-section--amber { border-top-color: var(--ochre); }

.picks-section-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 16px;
}
.picks-section-title {
  font-family: var(--f-ui); font-size: 12px; font-weight: 600;
  letter-spacing: 0.14em; text-transform: uppercase;
}
.picks-section--green .picks-section-title { color: var(--accent-ink); }
.picks-section--red   .picks-section-title { color: var(--clay-ink); }
.picks-section--amber .picks-section-title { color: var(--ochre-ink); }

.picks-year-tag {
  font-family: var(--f-ui); font-size: 9px; font-weight: 500;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-muted);
}
.picks-geo { display: flex; gap: 4px; align-items: center; }
.picks-geo span { display: block; height: 1.5px; background: currentColor; opacity: 0.4; }
.picks-section--green .picks-geo { color: var(--accent); }
.picks-section--red   .picks-geo { color: var(--clay); }
.picks-section--amber .picks-geo { color: var(--ochre); }
.geo-lines span:nth-child(1) { width: 18px; }
.geo-lines span:nth-child(2) { width: 10px; }
.geo-lines span:nth-child(3) { width: 5px; }
.geo-diagonals span { width: 10px; transform-origin: center; }
.geo-diagonals span:nth-child(1) { transform: rotate(45deg); }
.geo-diagonals span:nth-child(2) { transform: rotate(-45deg); margin-left: -3px; }
.geo-diagonals span:nth-child(3) { transform: rotate(45deg); margin-left: -3px; }
.geo-dots { gap: 5px; }
.geo-dots span {
  width: 5px; height: 5px; border-radius: 50%;
  background: currentColor; opacity: 1;
}
.geo-dots span:nth-child(2) { opacity: 0.5; }
.geo-dots span:nth-child(3) { opacity: 0.22; }

.picks-ranked { display: flex; flex-direction: column; gap: 7px; perspective: 800px; }
.pick-ranked {
  display: flex; align-items: flex-start; gap: 13px;
  padding: 12px 15px; border: 1px solid var(--border);
  background: var(--surface); border-radius: 3px;
  transition: border-color 0.22s, transform 0.28s var(--ease-spring),
              box-shadow 0.3s var(--ease-lux), filter 0.9s var(--ease-lux);
  position: relative; overflow: hidden;
  transform-style: preserve-3d;
}
/* Cursor-following inner highlight for the 3D tilt */
.pick-ranked::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(220px circle at var(--px, 50%) var(--py, 50%),
              rgba(92,124,88,0.10), transparent 60%);
  opacity: 0; transition: opacity 0.3s;
}
.pick-ranked.tilting::after { opacity: 1; }
.pick-ranked.tilting { box-shadow: 0 20px 40px -24px rgba(34,48,42,0.5); }

.pick-thumb {
  width: 46px; height: 46px; flex-shrink: 0;
  object-fit: cover;
  border: 1px solid var(--border); border-radius: 3px;
  filter: saturate(0.9);
  transition: filter 0.25s;
  margin-top: 1px;
}
.pick-ranked:hover .pick-thumb { filter: saturate(1.05); }
.pick-thumb--sports {
  object-fit: contain; padding: 5px;
  background: var(--bg);
}
.picks-section--green .pick-ranked:hover { border-color: var(--accent); transform: translateX(3px); }
.picks-section--red   .pick-ranked:hover { border-color: var(--clay);   transform: translateX(3px); }
.picks-section--amber .pick-ranked:hover { border-color: var(--ochre);  transform: translateX(3px); }
.pick-num {
  font-family: var(--f-display); font-size: 22px; font-weight: 400;
  line-height: 1; flex-shrink: 0; width: 22px; margin-top: 2px;
  font-variant-numeric: tabular-nums;
}
.picks-section--green .pick-num { color: rgba(92,124,88,0.5); }
.picks-section--red   .pick-num { color: rgba(167,93,66,0.5); }
.picks-section--amber .pick-num { color: rgba(176,130,56,0.6); }
.pick-ranked-body { flex: 1; min-width: 0; }
.pick-ranked-title {
  font-family: var(--f-display); font-size: 16px;
  font-weight: 500; color: var(--text); line-height: 1.2;
}
.pick-ranked-sub {
  font-family: var(--f-display); font-style: italic;
  font-size: 13px; font-weight: 400; color: var(--text-muted);
  margin-top: 2px;
}
.pick-ranked-note {
  font-family: var(--f-ui); font-size: 12px; font-weight: 400;
  line-height: 1.6; color: var(--text-2); margin-top: 6px;
}

.picks-empty-state {
  border: 1px dashed var(--border-lt);
  padding: 36px 14px; border-radius: 3px;
  display: flex; flex-direction: column; align-items: center; gap: 12px;
}
.picks-empty-state .geo-mark { opacity: 0.4; }
.picks-empty-state p {
  font-family: var(--f-display); font-style: italic;
  font-size: 16px; font-weight: 400; color: var(--text-muted);
}

/* ══ CONTACT / FOOTER ══════════════════════════════════════════════ */
#contact {
  padding: 116px var(--pad-x) 68px;
  border-top: 1px solid var(--border);
  background:
    radial-gradient(70% 60% at 90% 100%, rgba(92,124,88,0.05) 0%, transparent 60%),
    var(--bg);
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 76px; align-items: start;
}
.contact-body p {
  font-family: var(--f-ui); font-size: 17px;
  font-weight: 400; line-height: 1.7; color: var(--text-2); max-width: 52ch;
}
.contact-links { display: flex; flex-direction: column; gap: 12px; }
.c-link {
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px 24px; border: 1px solid var(--border);
  background: var(--surface); border-radius: 3px;
  text-decoration: none;
  transition: border-color 0.2s, background 0.2s, transform 0.32s var(--ease-spring), box-shadow 0.32s var(--ease-lux);
}
.c-link:hover {
  border-color: var(--accent);
  transform: translateX(5px);
  box-shadow: 0 16px 32px -22px rgba(34,48,42,0.4);
}
.c-label {
  font-family: var(--f-ui); font-size: 10px; font-weight: 500;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--text-muted); display: block; margin-bottom: 5px;
}
.c-value {
  font-family: var(--f-display); font-size: 19px;
  font-weight: 500; color: var(--text); display: block;
}
.c-arrow {
  color: var(--text-muted); font-size: 18px;
  transition: color 0.2s, transform 0.3s var(--ease-spring);
}
.c-link:hover .c-arrow { color: var(--accent); transform: translateX(5px); }

.footer-bar {
  grid-column: 1/-1; margin-top: 52px;
  padding-top: 30px; border-top: 1px solid var(--border);
  display: flex; justify-content: space-between; align-items: center;
}
.footer-sig {
  font-family: var(--f-display); font-size: 18px;
  font-weight: 500; letter-spacing: 0.01em;
  color: var(--text-2);
}
.footer-right { display: flex; align-items: center; gap: 28px; }
.footer-loc {
  font-family: var(--f-ui); font-size: 10px; font-weight: 500;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--text-muted);
}
.back-top {
  font-family: var(--f-ui); font-size: 10px; font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--text-2); text-decoration: none;
  display: inline-flex; align-items: center; gap: 8px;
  transition: color 0.2s;
}
.back-top::after { content: '↑'; transition: transform 0.35s var(--ease-bounce); }
.back-top:hover { color: var(--accent-ink); }
.back-top:hover::after { transform: translateY(-4px); }

/* ══ RESPONSIVE ════════════════════════════════════════════════════ */
@media (max-width: 980px) {
  :root { --pad-x: 34px; }
  #hero { padding: 0 var(--pad-x) 80px; }

  #about { padding: 84px var(--pad-x); grid-template-columns: 1fr; gap: 56px; }
  #work  { padding: 84px var(--pad-x); }
  #ctcaf { padding: 84px var(--pad-x); }
  .ctcaf-grid { grid-template-columns: 1fr; gap: 56px; }
  .ctcaf-stats { position: static; }
  #writing { padding: 84px var(--pad-x); grid-template-columns: 1fr; gap: 48px; }
  #culture { padding: 84px var(--pad-x); }
  .culture-top { grid-template-columns: 1fr; gap: 22px; }
  .picks-sections { grid-template-columns: 1fr 1fr; gap: 30px 20px; }
  #contact { padding: 88px var(--pad-x) 60px; grid-template-columns: 1fr; gap: 48px; }
  .footer-bar { flex-direction: column; gap: 16px; align-items: flex-start; }
}
@media (max-width: 700px) {
  .nav-links { display: none; }
  #menu-btn { display: block; }
  h1.hero-name { font-size: clamp(58px, 15vw, 96px); }
  /* Cluster gets taller and the overlaps loosen so faces stay clear. */
  .photo-frame { padding-bottom: 132%; }
  .pc-1 { width: 66%; height: 58%; }
  .pc-4 { width: 30%; height: 34%; top: 2%; }
  .pc-2 { width: 44%; height: 32%; top: 50%; }
  .pc-3 { width: 46%; height: 28%; left: 4%; }
  .t-logo { width: 54px; height: 32px; }
  .edu-logo { width: 44px; height: 44px; }
  .education { gap: 16px; }
  /* Narrower tiles: shrink the figure rather than let it wrap. */
  .stat-n { font-size: 27px; }
  .stat-wide .stat-n { font-size: 22px; }
  .stat { padding: 16px 14px; }
  .stats { grid-template-columns: 1fr 1fr; }
  .ctcaf-stats { grid-template-columns: 1fr 1fr; }
  .picks-sections { grid-template-columns: 1fr; }
  .essay-card { padding: 26px 24px; }
}

/* ══ REDUCED MOTION ════════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal, .hero-in { opacity: 1 !important; transform: none !important; }
  .divider::before { transform: scaleX(1); }
  .timeline::before { transform: scaleY(1); }
  .t-dot { transform: scale(1); }
  .blob { animation: none !important; }
  .cursor-dot, .cursor-ring { display: none; }
  .about-body p, .ctcaf-body p, .writing-body p, .contact-body p,
  .culture-desc, .pick-ranked, .essay-card { filter: none !important; }
  .section-h2 .ch { opacity: 1 !important; transform: none !important; }
}
