/* ══════════════════════════════════════════════════════════
   Zulkernain Tasin, personal site
   Timeline-first. Four colour-coded threads.
   ══════════════════════════════════════════════════════════ */

/* ---------- Tokens ---------- */
:root {
  /* Era palette: the spine of the whole design */
  --roots:  #F59E0B;   /* engineering  : amber  */
  --motion: #EC4899;   /* film / dance : magenta*/
  --impact: #22C55E;   /* activism     : green  */
  --build:  #8B5CF6;   /* founding     : violet */
  --side:   #7C8598;   /* side track   : slate  */
  --accent: #22D3EE;   /* cyan highlight        */

  /* Dark (default) */
  --bg:        #08080C;
  --bg-alt:    #0D0D14;
  --surface:   #12121B;
  --surface-2: #171722;
  --line:      rgba(255,255,255,.09);
  --line-2:    rgba(255,255,255,.14);
  --text:      #F4F4F6;
  --text-2:    #A8A8B8;
  --text-3:    #6E6E82;

  --radius: 18px;
  --maxw: 1140px;
  --ease: cubic-bezier(.22,.68,0,1);

  --font-display: 'Space Grotesk', ui-sans-serif, system-ui, sans-serif;
  --font-body: 'Inter', ui-sans-serif, system-ui, -apple-system, sans-serif;
}

:root[data-theme="light"] {
  --bg:        #FBFBF9;
  --bg-alt:    #F3F3EF;
  --surface:   #FFFFFF;
  --surface-2: #F7F7F4;
  --line:      rgba(10,10,20,.10);
  --line-2:    rgba(10,10,20,.16);
  --text:      #12121A;
  --text-2:    #55556A;
  --text-3:    #8A8A9E;
  --roots:  #D97706;
  --motion: #DB2777;
  --impact: #16A34A;
  --build:  #7C3AED;
  --side:   #6B7280;
  --accent: #0891B2;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16.5px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  transition: background .4s var(--ease), color .4s var(--ease);
}

img, svg { max-width: 100%; display: block; }
a { color: inherit; }

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 999;
  background: var(--text); color: var(--bg); padding: .7rem 1.1rem; border-radius: 0 0 10px 0;
}
.skip:focus { left: 0; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

/* Colour dots: reused everywhere */
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; flex: none; }
.dot--roots  { background: var(--roots);  box-shadow: 0 0 12px var(--roots); }
.dot--motion { background: var(--motion); box-shadow: 0 0 12px var(--motion); }
.dot--impact { background: var(--impact); box-shadow: 0 0 12px var(--impact); }
.dot--build  { background: var(--build);  box-shadow: 0 0 12px var(--build); }
.dot--cocurricular { background: var(--accent); box-shadow: 0 0 12px var(--accent); }
.dot--side   { background: var(--side); }
/* the career dot mixes the threads: "all of the professional track" */
.dot--career { background: linear-gradient(135deg, var(--roots), var(--impact) 55%, var(--build)); }

/* ══════════════ NAV ══════════════ */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  display: flex; align-items: center; gap: 1.5rem;
  padding: .9rem clamp(1rem, 4vw, 2.5rem);
  transition: background .35s var(--ease), backdrop-filter .35s, border-color .35s;
  border-bottom: 1px solid transparent;
}
.nav.is-stuck {
  background: color-mix(in srgb, var(--bg) 78%, transparent);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  border-bottom-color: var(--line);
}
.nav__brand {
  display: flex; align-items: center; gap: .6rem;
  font-family: var(--font-display); font-weight: 600; font-size: .95rem;
  letter-spacing: -.01em; text-decoration: none; margin-right: auto;
}
.nav__mark {
  width: 15px; height: 15px; border-radius: 5px;
  background: conic-gradient(from 210deg, var(--roots), var(--motion), var(--build), var(--accent), var(--impact), var(--roots));
  animation: spin 9s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.nav__links { display: flex; gap: 1.6rem; }
.nav__links a {
  font-size: .875rem; color: var(--text-2); text-decoration: none;
  position: relative; padding: .25rem 0; transition: color .25s;
}
.nav__links a::after {
  content: ''; position: absolute; left: 0; bottom: 0; height: 1.5px; width: 0;
  background: linear-gradient(90deg, var(--motion), var(--accent));
  transition: width .3s var(--ease);
}
.nav__links a:hover { color: var(--text); }
.nav__links a:hover::after { width: 100%; }

.theme {
  width: 36px; height: 36px; border-radius: 50%;
  border: 1px solid var(--line-2); background: var(--surface); color: var(--text);
  cursor: pointer; font-size: .85rem; display: grid; place-items: center;
  transition: border-color .25s, transform .25s;
}
.theme:hover { border-color: var(--accent); transform: rotate(-15deg); }
.theme__moon { display: none; }
:root[data-theme="light"] .theme__sun { display: none; }
:root[data-theme="light"] .theme__moon { display: block; }

@media (max-width: 720px) {
  .nav__links { display: none; }
}

/* ══════════════ HERO ══════════════ */
.hero {
  position: relative; min-height: 100svh;
  display: grid; place-items: center;
  /* minmax(0,1fr): an `auto` track would size to max-content and blow past
     the viewport on narrow screens. */
  grid-template-columns: minmax(0, 1fr);
  padding: 7rem clamp(1.2rem, 5vw, 2.5rem) 4rem;
  overflow: hidden;
}
.hero__glow {
  position: absolute; inset: -25%; z-index: 0; pointer-events: none;
  background:
    radial-gradient(48% 42% at 18% 22%, color-mix(in srgb, var(--motion) 26%, transparent), transparent 68%),
    radial-gradient(44% 40% at 82% 30%, color-mix(in srgb, var(--build)  26%, transparent), transparent 68%),
    radial-gradient(52% 46% at 55% 88%, color-mix(in srgb, var(--accent) 20%, transparent), transparent 70%),
    radial-gradient(38% 34% at 88% 76%, color-mix(in srgb, var(--roots)  18%, transparent), transparent 70%);
  filter: blur(52px);
  animation: drift 22s ease-in-out infinite alternate;
}
@keyframes drift {
  0%   { transform: translate3d(0,0,0) scale(1); }
  50%  { transform: translate3d(2.5%, -2%, 0) scale(1.07); }
  100% { transform: translate3d(-2%, 2.5%, 0) scale(1.02); }
}

.hero__inner { position: relative; z-index: 1; width: 100%; min-width: 0; max-width: var(--maxw); }

.hero__eyebrow {
  display: inline-flex; align-items: center; gap: .55rem;
  font-size: .78rem; letter-spacing: .16em; text-transform: uppercase;
  color: var(--text-2); font-weight: 500;
  border: 1px solid var(--line); border-radius: 100px;
  padding: .45rem 1rem; background: color-mix(in srgb, var(--surface) 60%, transparent);
  backdrop-filter: blur(10px);
}
.hero__arrow { color: var(--text-3); margin: 0 .1rem; }

.hero__name {
  font-family: var(--font-display);
  font-size: clamp(3.4rem, 13vw, 9.5rem);
  font-weight: 700; line-height: .88; letter-spacing: -.045em;
  margin: 1.4rem 0 1.2rem;
}
.hero__line { display: block; }
.hero__line--accent {
  /* palette repeated so the shimmer never lands on a single flat colour */
  background: linear-gradient(100deg,
    var(--motion), var(--build), var(--accent), var(--impact),
    var(--motion), var(--build), var(--accent), var(--impact));
  background-size: 200% auto;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  animation: shimmer 9s linear infinite;
}
@keyframes shimmer { to { background-position: 220% center; } }

.hero__roles {
  display: flex; flex-wrap: wrap; align-items: center; gap: .55rem .75rem;
  font-family: var(--font-display); font-size: clamp(.85rem, 2vw, 1.05rem);
  font-weight: 500; color: var(--text-2); margin-bottom: 1.5rem;
}
.hero__roles [data-era="roots"]  { color: var(--roots); }
.hero__roles [data-era="motion"] { color: var(--motion); }
.hero__roles [data-era="impact"] { color: var(--impact); }
.hero__roles [data-era="build"]  { color: var(--build); }
.hero__roles .sep { color: var(--text-3); opacity: .5; }

.hero__blurb {
  max-width: 60ch; color: var(--text-2); font-size: clamp(1rem, 1.6vw, 1.15rem);
  line-height: 1.72;
}

.hero__cta { display: flex; flex-wrap: wrap; gap: .8rem; margin: 2.2rem 0 3.4rem; }

.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  font-family: var(--font-display); font-size: .92rem; font-weight: 500;
  padding: .8rem 1.5rem; border-radius: 100px; text-decoration: none;
  border: 1px solid var(--line-2); color: var(--text);
  background: color-mix(in srgb, var(--surface) 70%, transparent);
  backdrop-filter: blur(10px);
  transition: transform .25s var(--ease), border-color .25s, background .25s, box-shadow .25s;
}
.btn:hover { transform: translateY(-2px); border-color: var(--accent); }
.btn--primary {
  background: linear-gradient(100deg, var(--motion), var(--build) 55%, var(--accent));
  border-color: transparent; color: #fff;
  box-shadow: 0 8px 30px -10px color-mix(in srgb, var(--build) 70%, transparent);
}
.btn--primary:hover { box-shadow: 0 14px 40px -10px color-mix(in srgb, var(--build) 85%, transparent); }

/* ---------- Identity tabs ---------- */
.tabs { margin: 1.6rem 0 1.8rem; position: relative; }
/* on narrow screens the row scrolls, fade the right edge so that reads as an affordance */
@media (max-width: 760px) {
  .tabs::after {
    content: ''; position: absolute; right: -3px; top: 0; bottom: 6px; width: 42px;
    pointer-events: none; background: linear-gradient(90deg, transparent, var(--bg));
    transition: opacity .25s;
  }
  /* once the row is scrolled to the end there is nothing left to hint at,
     and the fade would otherwise dim the active pill */
  .tabs.is-end::after { opacity: 0; }
}
.tabs__row {
  display: flex; gap: .5rem; align-items: center;
  /* horizontal scroll on narrow screens instead of wrapping into a block */
  flex-wrap: nowrap; overflow-x: auto; overscroll-behavior-x: contain;
  scrollbar-width: none; -webkit-overflow-scrolling: touch;
  padding: 3px 3px 6px;               /* room for focus ring + shadow */
  margin: -3px -3px -6px;
  scroll-padding-inline: 3px;
}
/* the tablist stays its own element so the ARIA stays valid with the
   outbound links sitting beside it in the same scrolling row */
.tabs__list { display: flex; gap: .5rem; flex: none; }
.tabs__sep { flex: none; width: 1px; height: 22px; background: var(--line-2); margin-inline: .3rem; }

/* outbound links, not filters: no dot, quieter, and they never look selected */
.tab--link { color: var(--text-3); border-style: dashed; }
.tab--link:hover { color: var(--accent); border-color: var(--accent); border-style: solid; }
.tabs__row::-webkit-scrollbar { display: none; }

.tab {
  display: inline-flex; align-items: center; gap: .5rem; flex: none;
  font-family: var(--font-display); font-size: .875rem; font-weight: 500;
  white-space: nowrap; cursor: pointer;
  padding: .6rem 1.1rem; border-radius: 100px;
  border: 1px solid var(--line-2); color: var(--text-2);
  background: color-mix(in srgb, var(--surface) 70%, transparent);
  backdrop-filter: blur(10px);
  transition: color .25s, border-color .25s, background .25s, transform .2s var(--ease), box-shadow .25s;
}
.tab:hover { color: var(--text); transform: translateY(-1px); }
.tab.is-active { color: var(--text); background: var(--surface-2); border-color: currentColor; }
.tab[data-thread="career"].is-active { color: var(--text); box-shadow: 0 0 0 1px var(--text-2) inset, 0 8px 24px -14px var(--text-2); }
.tab[data-thread="build"].is-active  { color: var(--build);  box-shadow: 0 0 0 1px var(--build)  inset, 0 8px 24px -14px var(--build); }
.tab[data-thread="impact"].is-active { color: var(--impact); box-shadow: 0 0 0 1px var(--impact) inset, 0 8px 24px -14px var(--impact); }
.tab[data-thread="motion"].is-active { color: var(--motion); box-shadow: 0 0 0 1px var(--motion) inset, 0 8px 24px -14px var(--motion); }
.tab[data-thread="cocurricular"].is-active { color: var(--accent); box-shadow: 0 0 0 1px var(--accent) inset, 0 8px 24px -14px var(--accent); }

/* Panels swapped by the tabs (stat strips + work grids) */
.tabpanel[hidden] { display: none; }
.tabpanel.is-in { animation: panelIn .28s var(--ease) both; }
@keyframes panelIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .tabpanel.is-in { animation: none; } }

/* Stat strip */
.stats-wrap { margin-bottom: .5rem; }
.stats {
  list-style: none;
  display: grid; gap: 1px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  background: var(--line); border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden;
}
@media (max-width: 760px) { .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* One tile = one phrase, top-aligned, same type size in every cell.
   Uniformity is the point: a mixed strip reads as a broken table. */
.stat {
  background: color-mix(in srgb, var(--surface) 82%, transparent);
  backdrop-filter: blur(10px); padding: 1.25rem 1.3rem;
  display: flex; min-width: 0;
}
.stat__val {
  font-family: var(--font-display); font-weight: 500;
  font-size: .98rem; line-height: 1.45; letter-spacing: -.012em;
  color: var(--text-2); margin: 0; overflow-wrap: anywhere; text-wrap: pretty;
}
.stat__val b { font-weight: 700; color: var(--text); }
/* thread colour per column, same rhythm as the original strip */
.stat:nth-child(1) .stat__val b { color: var(--impact); }
.stat:nth-child(2) .stat__val b { color: var(--motion); }
.stat:nth-child(3) .stat__val b { color: var(--build); }
.stat:nth-child(4) .stat__val b { color: var(--roots); }

.scrollcue {
  position: absolute; bottom: 1.6rem; left: 50%; transform: translateX(-50%);
  width: 22px; height: 34px; border: 1.5px solid var(--line-2); border-radius: 12px; z-index: 1;
}
.scrollcue span {
  position: absolute; top: 7px; left: 50%; margin-left: -2px;
  width: 4px; height: 6px; border-radius: 2px; background: var(--accent);
  animation: cue 1.9s ease-in-out infinite;
}
@keyframes cue { 0%,100% { transform: translateY(0); opacity: 1; } 60% { transform: translateY(11px); opacity: 0; } }
@media (max-width: 720px) { .scrollcue { display: none; } }

/* ══════════════ SECTIONS ══════════════ */
.section {
  padding: clamp(4.5rem, 10vw, 8rem) clamp(1.2rem, 5vw, 2.5rem);
  max-width: var(--maxw); margin-inline: auto;
}
.section--alt {
  max-width: none; background: var(--bg-alt);
  border-block: 1px solid var(--line);
}
.section--alt > * { max-width: var(--maxw); margin-inline: auto; }

.kicker {
  font-size: .75rem; letter-spacing: .18em; text-transform: uppercase;
  font-weight: 600; color: var(--accent); margin-bottom: .8rem;
}
.section__title {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(2rem, 5.5vw, 3.4rem); letter-spacing: -.035em; line-height: 1.05;
}
.section__lede { color: var(--text-2); max-width: 58ch; margin-top: 1rem; font-size: 1.05rem; }
.section__head { margin-bottom: 2.8rem; }

/* ---------- Filters ---------- */
.filters { display: flex; flex-wrap: wrap; gap: .55rem; margin-bottom: 3rem; }
.chip {
  display: inline-flex; align-items: center; gap: .5rem;
  font-family: var(--font-display); font-size: .85rem; font-weight: 500;
  padding: .55rem 1.05rem; border-radius: 100px; cursor: pointer;
  border: 1px solid var(--line-2); background: var(--surface); color: var(--text-2);
  transition: color .25s, border-color .25s, background .25s, transform .2s var(--ease);
}
.chip:hover { transform: translateY(-1px); color: var(--text); }
.chip.is-active { color: var(--text); border-color: currentColor; background: var(--surface-2); }
.chip--roots.is-active  { color: var(--roots);  box-shadow: 0 0 0 1px var(--roots)  inset, 0 6px 20px -12px var(--roots); }
.chip--motion.is-active { color: var(--motion); box-shadow: 0 0 0 1px var(--motion) inset, 0 6px 20px -12px var(--motion); }
.chip--impact.is-active { color: var(--impact); box-shadow: 0 0 0 1px var(--impact) inset, 0 6px 20px -12px var(--impact); }
.chip--build.is-active  { color: var(--build);  box-shadow: 0 0 0 1px var(--build)  inset, 0 6px 20px -12px var(--build); }
.chip--cocurricular.is-active { color: var(--accent); box-shadow: 0 0 0 1px var(--accent) inset, 0 6px 20px -12px var(--accent); }
.chip--career.is-active { color: var(--text); box-shadow: 0 0 0 1px var(--text-2) inset, 0 6px 20px -12px var(--text-2); }

/* ══════════════ TIMELINE ══════════════ */
.tl__legend { display: none; }
@media (min-width: 900px) {
  .tl__legend {
    display: grid; grid-template-columns: minmax(0,1fr) 64px minmax(0,1fr);
    margin-bottom: 1.4rem; font-family: var(--font-display);
    font-size: .72rem; letter-spacing: .14em; text-transform: uppercase; color: var(--text-3);
  }
  .tl__legend span:first-child { text-align: right; }
}

.tl { list-style: none; position: relative; padding-left: 0; }

/* the coloured spine */
.tl::before {
  content: ''; position: absolute; top: 6px; bottom: 6px; left: 7px; width: 2px;
  /* 0deg: the timeline runs newest at the top, so the palette runs the same way */
  background: linear-gradient(0deg, var(--roots) 0%, var(--motion) 30%, var(--impact) 58%, var(--build) 100%);
  opacity: .55; border-radius: 2px;
}
@media (min-width: 900px) {
  /* two lanes need more room than a prose column: let the timeline breathe
     wider than the rest of the page on big screens. Wider cards are also
     shorter cards, which takes vertical air out of the lanes. */
  #timeline { max-width: clamp(var(--maxw), 94vw, 1460px); }
  /* two lanes: side track left of the spine, career track right of it */
  .tl { display: grid; grid-template-columns: minmax(0,1fr) 64px minmax(0,1fr); align-items: start; }
  .tl::before { left: calc(50% - 1px); }
  /* fine implicit rows so main.js can give every entry its own row in strict
     date order; grid's own placement would pair entries across the lanes */
  .tl.is-sequenced { grid-auto-rows: 8px; }

  /* when a filter empties one lane there is no reason to keep a dead column:
     drop to a single lane with the spine on the left. */
  .tl.is-solo { grid-template-columns: 64px minmax(0, 1fr); }
  .tl.is-solo::before { left: 31px; }
  .tl.is-solo .tl__item { grid-column: 2; padding-left: 2.6rem; padding-right: 0; }
  .tl.is-solo .tl__item[data-track="side"]::before { left: -40px; right: auto; }
  .tl.is-solo .tl__year,
  .tl.is-solo .tl__item[data-track="side"] .tl__year { text-align: left; }
  .tl.is-solo .tl__chapter { justify-content: flex-start; text-align: left; padding-left: 2.6rem; }
  .tl.is-solo .tl__chapter::before { left: 25px; margin-left: 0; }
  .tl__legend.is-solo { visibility: hidden; }
}

/* chapter divider, sits on the spine, not a timeline node */
.tl__chapter {
  position: relative; list-style: none;
  padding-left: 2.4rem; padding-bottom: 1.6rem; margin-top: .6rem;
  display: flex; flex-wrap: wrap; align-items: baseline; gap: .3rem .8rem;
  transition: opacity .35s, filter .35s;
}
.tl__chapter:first-child { margin-top: 0; }
.tl__chapter h3 {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(1.15rem, 2.6vw, 1.5rem); letter-spacing: -.025em; line-height: 1.2;
}
.tl__chapter span {
  font-family: var(--font-display); font-size: .8rem; font-weight: 500;
  letter-spacing: .1em; text-transform: uppercase; color: var(--text-3);
}
/* a bar on the spine to break the flow between chapters */
.tl__chapter::before {
  content: ''; position: absolute; left: 1px; top: 2px;
  width: 14px; height: 3px; border-radius: 3px;
  background: linear-gradient(90deg, var(--accent), var(--build));
}
@media (min-width: 900px) {
  .tl__chapter {
    grid-column: 1 / -1; padding-left: 0; justify-content: center;
    text-align: center; padding-top: 1.6rem; padding-bottom: 2rem;
    /* opaque so it cuts the spine cleanly between chapters */
    background: var(--bg);
  }
  .tl__chapter::before { left: 50%; margin-left: -7px; top: .6rem; }
}

.tl__item {
  position: relative;
  padding-left: 2.4rem;
  padding-bottom: 2.2rem;
  opacity: 0; transform: translateY(22px);
  transition: opacity .7s var(--ease), transform .7s var(--ease), filter .35s, max-height .4s;
}
.tl__item.is-in { opacity: 1; transform: none; }
/* filtered out = removed from the flow, so the two lanes close up */
.tl__item.is-out, .tl__chapter.is-out { display: none; }
/* legend labels stay in place so the two columns don't shift */
.tl__legend span.is-out { visibility: hidden; }

@media (min-width: 900px) {
  .tl__item[data-track="main"] { grid-column: 3; padding-left: 2.6rem; }
  .tl__item[data-track="side"] { grid-column: 1; padding-left: 0; padding-right: 2.6rem; }
}

/* node on the spine */
.tl__item::before {
  content: ''; position: absolute; left: 0; top: 6px;
  width: 16px; height: 16px; border-radius: 50%;
  background: var(--bg); border: 2.5px solid var(--text-3);
  transition: border-color .3s, box-shadow .3s, transform .3s var(--ease);
}
@media (min-width: 900px) {
  .tl__item[data-track="main"]::before { left: -40px; }
  .tl__item[data-track="side"]::before { left: auto; right: -40px; }
}

.tl__item[data-era="roots"]::before  { border-color: var(--roots);  box-shadow: 0 0 0 5px color-mix(in srgb, var(--roots) 14%, transparent); }
.tl__item[data-era="motion"]::before { border-color: var(--motion); box-shadow: 0 0 0 5px color-mix(in srgb, var(--motion) 14%, transparent); }
.tl__item[data-era="impact"]::before { border-color: var(--impact); box-shadow: 0 0 0 5px color-mix(in srgb, var(--impact) 14%, transparent); }
.tl__item[data-era="build"]::before  { border-color: var(--build);  box-shadow: 0 0 0 5px color-mix(in srgb, var(--build) 14%, transparent); }
.tl__item[data-era="side"]::before   { border-color: var(--side); }
.tl__item:hover::before { transform: scale(1.22); }

.tl__item.is-award::before {
  background: linear-gradient(140deg, var(--impact), var(--accent));
  border-color: transparent;
  box-shadow: 0 0 0 6px color-mix(in srgb, var(--impact) 20%, transparent), 0 0 22px var(--impact);
}

/* year gutter */
.tl__year {
  font-family: var(--font-display); font-weight: 600;
  font-size: .82rem; letter-spacing: .04em; color: var(--text-3);
  margin-bottom: .5rem; text-transform: uppercase;
}
@media (min-width: 900px) {
  .tl__year { font-size: .9rem; }
  .tl__item[data-track="side"] .tl__year { text-align: right; }
}

/* card */
.tl__card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.5rem 1.6rem;
  transition: transform .3s var(--ease), border-color .3s, box-shadow .3s;
  position: relative; overflow: hidden;
}
.tl__card::before {
  content: ''; position: absolute; inset: 0 auto 0 0; width: 3px; background: var(--text-3); opacity: .75;
}
.tl__item[data-era="roots"]  .tl__card::before { background: var(--roots); }
.tl__item[data-era="motion"] .tl__card::before { background: var(--motion); }
.tl__item[data-era="impact"] .tl__card::before { background: var(--impact); }
.tl__item[data-era="build"]  .tl__card::before { background: var(--build); }
.tl__item[data-era="side"]   .tl__card::before { background: var(--side); }

/* The side lane is deliberately quieter: the career track is the headline. */
.tl__item[data-track="side"] .tl__card { padding: 1.15rem 1.25rem; background: transparent; }
.tl__item[data-track="side"] .tl__card h3 { font-size: 1.02rem; line-height: 1.35; }
.tl__item[data-track="side"] .tl__card p { font-size: .9rem; }
.tl__item[data-track="side"] .tl__card--feature { background: var(--surface); }
.tl__item[data-track="side"] { padding-bottom: 1.6rem; }

.tl__card:hover { transform: translateY(-3px); border-color: var(--line-2); box-shadow: 0 18px 45px -22px rgba(0,0,0,.7); }

.tl__card h3 {
  font-family: var(--font-display); font-weight: 600;
  font-size: clamp(1.1rem, 2.4vw, 1.4rem); letter-spacing: -.02em;
  line-height: 1.3; margin-bottom: .7rem;
}
.tl__card p { color: var(--text-2); font-size: .97rem; margin-bottom: .65rem; }
.tl__card p:last-of-type { margin-bottom: 0; }
.tl__card strong { color: var(--text); font-weight: 600; }
.tl__card em { color: var(--text); font-style: italic; }

.tl__tag {
  font-size: .7rem !important; letter-spacing: .14em; text-transform: uppercase;
  font-weight: 600; margin-bottom: .55rem !important;
}
.tl__item[data-era="roots"]  .tl__tag { color: var(--roots) !important; }
.tl__item[data-era="motion"] .tl__tag { color: var(--motion) !important; }
.tl__item[data-era="impact"] .tl__tag { color: var(--impact) !important; }
.tl__item[data-era="build"]  .tl__tag { color: var(--build) !important; }
.tl__item[data-era="side"]   .tl__tag { color: var(--side) !important; }

.tl__meta {
  font-size: .8rem !important; color: var(--text-3) !important;
  margin-top: .8rem !important; line-height: 1.55;
}
.tl__link {
  display: inline-flex; align-items: center; gap: .35rem;
  font-size: .84rem; font-weight: 500; text-decoration: none;
  color: var(--accent); margin-top: .9rem; margin-right: 1rem;
  border-bottom: 1px solid transparent; transition: border-color .25s;
}
.tl__link:hover { border-bottom-color: var(--accent); }

.tl__card--feature { background: var(--surface-2); }
.tl__card--award {
  background:
    linear-gradient(140deg, color-mix(in srgb, var(--impact) 9%, transparent), transparent 55%),
    var(--surface-2);
  border-color: color-mix(in srgb, var(--impact) 32%, transparent);
}
.trophy { font-size: 1.05em; margin-right: .35rem; }

.tl__card--now {
  background: linear-gradient(140deg, color-mix(in srgb, var(--build) 12%, transparent), transparent 60%), var(--surface-2);
  border-color: color-mix(in srgb, var(--build) 30%, transparent);
}

.quote {
  border-left: 2px solid var(--impact);
  padding: .3rem 0 .3rem 1rem; margin: 1rem 0;
  font-family: var(--font-display); font-size: 1.02rem; font-style: italic;
  color: var(--text); line-height: 1.55;
}
.quote cite { display: block; font-style: normal; font-size: .8rem; color: var(--text-3); margin-top: .5rem; font-family: var(--font-body); }

/* ══════════════ WORK GRID ══════════════ */
.grid { display: grid; gap: 1.1rem; grid-template-columns: repeat(auto-fit, minmax(min(290px, 100%), 1fr)); }
.card {
  display: flex; flex-direction: column;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 1.7rem;
  text-decoration: none; position: relative; overflow: hidden;
  transition: transform .3s var(--ease), border-color .3s, box-shadow .3s;
}
.card::after {
  content: ''; position: absolute; inset: 0; pointer-events: none; opacity: 0;
  transition: opacity .35s;
}
.card--roots::after  { background: radial-gradient(70% 55% at 50% 0%, color-mix(in srgb, var(--roots)  13%, transparent), transparent 70%); }
.card--impact::after { background: radial-gradient(70% 55% at 50% 0%, color-mix(in srgb, var(--impact) 13%, transparent), transparent 70%); }
.card--motion::after { background: radial-gradient(70% 55% at 50% 0%, color-mix(in srgb, var(--motion) 13%, transparent), transparent 70%); }
.card--build::after  { background: radial-gradient(70% 55% at 50% 0%, color-mix(in srgb, var(--build)  13%, transparent), transparent 70%); }
a.card:hover { transform: translateY(-4px); border-color: var(--line-2); box-shadow: 0 22px 50px -26px rgba(0,0,0,.75); }
a.card:hover::after { opacity: 1; }

/* .card p sets flex:1; the tag must NOT absorb spare height or titles misalign
   across the row, hence the higher-specificity selector. */
.card p.card__tag { flex: none; font-size: .7rem; letter-spacing: .14em; text-transform: uppercase; font-weight: 600; margin-bottom: .7rem; }
.card--roots  .card__tag { color: var(--roots); }
.card--impact .card__tag { color: var(--impact); }
.card--motion .card__tag { color: var(--motion); }
.card--build  .card__tag { color: var(--build); }
.card h3 { font-family: var(--font-display); font-weight: 600; font-size: 1.28rem; letter-spacing: -.02em; margin-bottom: .6rem; }
.card p { color: var(--text-2); font-size: .95rem; flex: 1; }
.card__go { margin-top: 1.2rem; font-size: .85rem; font-weight: 500; color: var(--accent); }
.card__go--muted { color: var(--text-3); }
/* a card carrying a pull-quote needs two columns' worth of room */
@media (min-width: 900px) { .card--wide { grid-column: span 2; } }
.card .quote { font-size: .95rem; margin: .2rem 0 0; border-left-color: var(--accent); }

/* ══════════════ PRESS ══════════════ */
.press { list-style: none; border-top: 1px solid var(--line); }
.press__row {
  display: grid; gap: .35rem 1.5rem; align-items: start;
  grid-template-columns: 1fr; padding: 1.4rem 0;
  border-bottom: 1px solid var(--line);
  transition: background .3s, padding-left .3s var(--ease);
}
.press__row:hover { background: color-mix(in srgb, var(--surface) 60%, transparent); padding-left: .8rem; }
@media (min-width: 780px) {
  .press__row { grid-template-columns: 190px 1fr 90px; }
}
.press__outlet {
  display: flex; align-items: center; gap: .55rem;
  font-family: var(--font-display); font-weight: 600; font-size: .88rem; color: var(--text);
}
.press__body a {
  font-size: 1.03rem; font-weight: 500; text-decoration: none; line-height: 1.4;
  display: inline-block; border-bottom: 1px solid transparent; transition: color .25s, border-color .25s;
}
.press__body a:hover { color: var(--accent); border-bottom-color: var(--accent); }
.press__body p { color: var(--text-3); font-size: .875rem; margin-top: .3rem; }
.press__date { font-size: .8rem; color: var(--text-3); font-family: var(--font-display); text-align: left; }
@media (min-width: 780px) { .press__date { text-align: right; } }

/* ══════════════ CONTACT / FOOTER ══════════════ */
.contact { text-align: center; padding-block: 1rem; }
.contact .section__lede { margin-inline: auto; }
.contact__links { display: flex; flex-wrap: wrap; gap: .75rem; justify-content: center; margin-top: 2rem; }

.footer {
  padding: 2.5rem clamp(1.2rem, 5vw, 2.5rem) 3rem;
  text-align: center; color: var(--text-3); font-size: .85rem;
  display: flex; flex-direction: column; gap: .35rem;
}
.footer__note { opacity: .6; font-size: .78rem; }

/* reveal-on-scroll for non-timeline blocks */
.section__head, .filters, .grid > *, .press__row, .contact { }
