:root {
  --white: #ffffff;
  --black: #111111;
  --oat: #ede4d3;
  --vanilla: #f6ebc8;
  --butter: #f8e48f;
  --marine: #0b2545;
  --marine-deep: #081b33;
  --red: #c8102e;
  --blue: #2f6bff;
  --forest: #2e5e3e;
  --pink: #ff3ea5;
  --turquoise: #1fc8c1;
  --burgundy: #7a1e33;

  --fg: var(--oat);
  --heading: var(--white);
  --muted: rgba(237, 228, 211, 0.75);
  --line: rgba(237, 228, 211, 0.18);
  --sans: "Inter Tight", system-ui, -apple-system, sans-serif;
  --serif: "Instrument Serif", Georgia, serif;
  --pad: clamp(16px, 5vw, 72px);
  color-scheme: dark;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; overflow-x: clip; }
body {
  background: var(--marine);
  color: var(--fg);
  font-family: var(--sans);
  font-size: 18px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
a { color: inherit; }
em { font-family: var(--serif); font-style: italic; font-size: 1.08em; }
::selection { background: var(--vanilla); color: var(--marine); }

/* NAV */
.nav {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 18px var(--pad);
  background: color-mix(in srgb, var(--marine) 85%, transparent);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav__mark { font-weight: 900; font-size: 22px; letter-spacing: -0.04em; text-decoration: none; color: var(--white); }
.nav__mark span, .accent { color: var(--red); }
.nav__links { display: flex; gap: 28px; }
.nav__links a { text-decoration: none; white-space: nowrap; font-size: 15px; font-weight: 500; color: var(--oat); transition: color .2s; }
.nav__links a:hover { color: var(--white); }

/* BUTTONS */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 16px 28px; border-radius: 999px;
  background: var(--white); color: var(--marine);
  font-weight: 600; font-size: 16px; text-decoration: none;
  border: 2px solid var(--white);
  transition: transform .2s, background .2s, color .2s, border-color .2s;
}
.btn:hover { background: var(--red); border-color: var(--red); color: var(--white); transform: translateY(-2px); }
.btn--ghost { background: transparent; color: var(--oat); border-color: var(--oat); }
.btn--ghost:hover { background: var(--vanilla); border-color: var(--vanilla); color: var(--marine); }
.btn--small { padding: 9px 18px; font-size: 14px; white-space: nowrap; }

/* HERO */
.hero { padding: clamp(64px, 12vw, 160px) var(--pad) clamp(48px, 8vw, 96px); }
.eyebrow {
  font-size: 14px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--vanilla); margin-bottom: 24px;
}
.hero__title {
  font-size: clamp(64px, 15vw, 220px);
  font-weight: 900; line-height: 0.86; letter-spacing: -0.055em;
  color: var(--white);
}
.hero__title .line { display: block; }
.hero__lede {
  max-width: 640px; margin-top: 40px;
  font-size: clamp(20px, 2.2vw, 26px); line-height: 1.4; color: var(--oat);
}
.hero__lede em { color: var(--white); }
.hero__cta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 40px; }

/* MARQUEE */
.marquee {
  background: var(--vanilla); color: var(--marine);
  overflow: hidden; padding: 18px 0;
  transform: rotate(-1.5deg); margin: 0 -20px;
}
.marquee__track {
  display: flex; gap: 32px; width: max-content;
  font-size: clamp(28px, 4vw, 48px); font-weight: 800; letter-spacing: -0.03em; text-transform: uppercase;
  animation: scroll 30s linear infinite;
}
.marquee__track span:nth-child(8n+2) { color: var(--red); }
.marquee__track span:nth-child(8n+4) { color: var(--forest); }
.marquee__track span:nth-child(8n+6) { color: var(--blue); }
.marquee__track span:nth-child(8n+8) { color: var(--burgundy); }
@keyframes scroll { to { transform: translateX(-50%); } }

/* STATS */
.stats {
  display: grid; grid-template-columns: repeat(4, 1fr);
  padding: clamp(64px, 9vw, 120px) var(--pad);
  gap: 32px;
}
.stat { border-top: 6px solid var(--red); padding-top: 20px; }
.stat:nth-child(2) { border-color: var(--forest); }
.stat:nth-child(3) { border-color: var(--vanilla); }
.stat:nth-child(4) { border-color: var(--turquoise); }
.stat__num { display: block; font-size: clamp(48px, 6vw, 88px); font-weight: 900; letter-spacing: -0.05em; line-height: 1; color: var(--white); }
.stat__label { display: block; margin-top: 12px; color: var(--muted); font-size: 16px; }

/* SECTIONS */
.section { padding: clamp(72px, 10vw, 140px) var(--pad); border-top: 1px solid var(--line); }
.section__head { display: flex; align-items: baseline; gap: 20px; margin-bottom: clamp(40px, 6vw, 72px); }
.section__num { font-family: var(--serif); font-style: italic; font-size: 28px; color: var(--red); }
.section__title { font-size: clamp(48px, 9vw, 128px); font-weight: 900; letter-spacing: -0.05em; line-height: 0.9; color: var(--heading); }
.section__intro { max-width: 720px; font-size: clamp(20px, 2vw, 24px); color: var(--muted); margin-bottom: 48px; }

/* Light sections share marine-on-light variables */
.section--oat, .section--white {
  --fg: var(--marine); --heading: var(--marine);
  --muted: rgba(11, 37, 69, 0.75); --line: rgba(11, 37, 69, 0.16);
  color: var(--fg); border-top: 0;
}
.section--oat { background: var(--oat); }
.section--white { background: var(--white); }
.section--white .section__num { color: var(--forest); }

.section--forest { background: var(--forest); color: var(--oat); border-top: 0; --muted: rgba(237, 228, 211, 0.8); }
.section--forest .section__num { color: var(--vanilla); }

.section--blue { background: var(--blue); color: var(--white); border-top: 0; --muted: rgba(255, 255, 255, 0.85); }
.section--blue .section__num { color: var(--vanilla); }

.section--oat .card { background: var(--white); border-color: transparent; }
.section--oat .card:hover { border-color: var(--forest); }
.section--oat .card p { color: var(--muted); }
.section--oat .card__date { color: var(--red); }
.section--oat .card__org { color: var(--forest); }

.section--burgundy { background: var(--burgundy); color: var(--oat); border-top: 0; }
.section--burgundy .section__num { color: var(--vanilla); }

/* ROLES */
.role {
  display: grid; grid-template-columns: 220px 1fr; gap: 32px;
  padding: 40px 0; border-top: 1px solid var(--line);
}
.role:last-child { border-bottom: 1px solid var(--line); }
.role__meta { font-size: 15px; font-weight: 600; color: var(--muted); padding-top: 10px; }
.role h3 { font-size: clamp(28px, 3.4vw, 44px); font-weight: 800; letter-spacing: -0.035em; line-height: 1.05; color: var(--heading); }
.role__title {
  display: inline-block; font-weight: 600; font-size: 15px;
  margin: 14px 0 16px; padding: 6px 14px; border-radius: 999px;
  background: var(--red); color: var(--white);
}
.role:nth-of-type(2) .role__title { background: var(--white); color: var(--marine); }
.role:nth-of-type(3) .role__title { background: var(--forest); color: var(--white); }
.role:nth-of-type(4) .role__title { background: var(--oat); color: var(--marine); }
.role__body p:not(.role__title) { max-width: 760px; color: var(--muted); margin-bottom: 12px; }

/* CARDS */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 56px; }
.card { border: 1px solid var(--line); border-radius: 24px; padding: 32px; transition: border-color .25s, transform .25s; }
.card:hover { transform: translateY(-4px); }
.card__date { font-size: 14px; font-weight: 600; }
.card h3 { font-size: 30px; font-weight: 800; letter-spacing: -0.03em; margin-top: 12px; }
.card__org { font-weight: 600; margin: 4px 0 16px; }

.mini { border-radius: 20px; padding: 28px; color: var(--marine); background: var(--oat); }
.mini h4 { font-size: 20px; font-weight: 800; letter-spacing: -0.02em; margin-bottom: 8px; }
.mini p { font-size: 16px; opacity: 0.85; }

/* CREDITS */
.credits { list-style: none; }
.credits li {
  display: grid; grid-template-columns: 1fr 1.3fr 1fr; gap: 24px; align-items: baseline;
  padding: 22px 0; border-top: 1px solid var(--line);
  transition: padding-left .25s;
}
.credits li:last-child { border-bottom: 1px solid var(--line); }
.credits li:hover { padding-left: 16px; }
.credits__role { font-size: clamp(24px, 3vw, 40px); font-weight: 800; letter-spacing: -0.035em; color: var(--white); transition: color .25s; }
.credits li:hover .credits__role { color: var(--vanilla); }
.credits__show { font-family: var(--serif); font-style: italic; font-size: clamp(22px, 2.4vw, 30px); color: var(--oat); }
.credits__where { color: var(--muted); font-size: 15px; text-align: right; }

/* WRITING */
.writing { display: grid; grid-template-columns: 1.4fr 1fr; gap: 56px; align-items: end; }
.writing blockquote { font-size: clamp(28px, 3.6vw, 52px); font-weight: 700; letter-spacing: -0.035em; line-height: 1.1; color: var(--white); }
.writing blockquote em { color: var(--vanilla); }
.writing__list p { font-size: 18px; padding: 12px 0; border-top: 1px solid rgba(237, 228, 211, 0.3); }
.writing__list p:first-child { border-top: 0; text-transform: uppercase; letter-spacing: .12em; font-size: 13px; color: var(--vanilla); }

/* EDUCATION */
.edu { display: grid; grid-template-columns: repeat(2, 1fr); gap: 40px; }
.edu h3 { font-size: clamp(24px, 2.6vw, 34px); font-weight: 800; letter-spacing: -0.03em; margin-bottom: 10px; color: var(--heading); }
.edu p { color: var(--muted); }
.skills { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 64px; }
.skills span {
  padding: 10px 18px; border-radius: 999px;
  font-size: 15px; font-weight: 600; transition: transform .2s;
  background: var(--white); color: var(--marine);
}
.skills span:nth-child(3n+2) { background: var(--oat); }
.skills span:nth-child(3n+3) { background: var(--vanilla); }
.skills span:hover { transform: translateY(-3px) rotate(-2deg); }

/* CONTACT */
.contact { padding: clamp(96px, 14vw, 200px) var(--pad); background: var(--marine-deep); color: var(--white); }
.contact .eyebrow { color: var(--vanilla); }
.contact__title { font-size: clamp(72px, 16vw, 240px); font-weight: 900; letter-spacing: -0.06em; line-height: 0.85; }
.contact__title .serif { color: var(--pink); }
.serif { font-family: var(--serif); font-style: italic; font-weight: 400; letter-spacing: -0.02em; }
.contact__links { display: flex; flex-wrap: wrap; gap: 16px 48px; margin-top: 56px; }
.contact__links a {
  font-size: clamp(18px, 2.2vw, 28px); font-weight: 600; text-decoration: none;
  border-bottom: 3px solid var(--vanilla); padding-bottom: 4px; overflow-wrap: anywhere;
  transition: color .2s;
}
.contact__links a:nth-child(1) { border-color: var(--turquoise); }
.contact__links a:nth-child(2) { border-color: var(--forest); }
.contact__links a:hover { color: var(--vanilla); }

.footer {
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  padding: 28px var(--pad); font-size: 14px; color: var(--oat);
  background: var(--black);
}

/* SEE MORE */
.more { margin-top: 32px; }
.role .more { margin-top: 20px; }
.more > summary {
  list-style: none; display: inline-flex; align-items: center; gap: 10px;
  padding: 11px 22px; border-radius: 999px; border: 2px solid currentColor;
  font-weight: 600; font-size: 15px; cursor: pointer; user-select: none;
  transition: background .2s, color .2s, border-color .2s;
}
.more > summary::-webkit-details-marker { display: none; }
.more > summary::after { content: "+"; font-size: 20px; line-height: 1; }
.more[open] > summary::after { content: "−"; }
.more > summary .less, .more[open] > summary .lbl { display: none; }
.more[open] > summary .less { display: inline; }
.more > summary:hover { background: var(--vanilla); border-color: var(--vanilla); color: var(--marine); }
.section--oat .more > summary:hover { background: var(--marine); border-color: var(--marine); color: var(--white); }
.more > .more__body { margin-top: 32px; animation: fade-in .4s ease; }
@keyframes fade-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

.bullets { list-style: none; max-width: 760px; }
.bullets li { position: relative; padding: 8px 0 8px 22px; color: var(--muted); border-top: 1px solid var(--line); }
.bullets li::before { content: ""; position: absolute; left: 0; top: 18px; width: 8px; height: 8px; border-radius: 50%; background: var(--red); }

/* FULL CREDIT LIST */
.year { display: grid; grid-template-columns: 120px 1fr; gap: 24px; padding: 24px 0; border-top: 1px solid var(--line); }
.year:last-child { border-bottom: 1px solid var(--line); }
.year__label { font-family: var(--serif); font-style: italic; font-size: 34px; line-height: 1; color: var(--vanilla); }
.year ul { list-style: none; display: grid; gap: 12px; }
.year li { display: grid; grid-template-columns: 1fr 1.2fr 1fr; gap: 20px; align-items: baseline; }
.year .r { font-weight: 700; color: var(--white); }
.year .s { font-family: var(--serif); font-style: italic; font-size: 21px; }
.year .c { color: var(--muted); font-size: 15px; text-align: right; }
.year small, .credits small { display: block; font-family: var(--sans); font-style: normal; font-weight: 500; font-size: 13px; color: var(--muted); }
.credits small { display: inline; font-size: .5em; letter-spacing: 0; }
.year small.inline { display: inline; margin-left: 6px; }

.subhead { font-size: clamp(28px, 3.4vw, 44px); font-weight: 800; letter-spacing: -0.035em; color: var(--heading); margin: 88px 0 20px; }
.subhead--first { margin-top: 0; }
.credits--compact .credits__role { font-size: clamp(20px, 2.2vw, 28px); }
.credits--compact .credits__show { font-size: clamp(19px, 2vw, 24px); }
.credits--compact li { padding: 16px 0; }

.grid-3--tight { margin-top: 0; }
.mini__date { font-size: 13px !important; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; margin-bottom: 10px; opacity: .7 !important; }

/* TRAINING BLOCKS */
.block { border: 1px solid var(--line); border-radius: 24px; padding: 28px; }
.block h3 { font-size: 22px; font-weight: 800; letter-spacing: -0.02em; color: var(--heading); margin-bottom: 12px; }
.block ul { list-style: none; }
.block li { padding: 10px 0; border-top: 1px solid var(--line); color: var(--muted); font-size: 16px; }
.block li:first-child { border-top: 0; padding-top: 0; }
.block li strong { color: var(--white); font-weight: 700; }
.edu__sub { font-size: clamp(20px, 2vw, 26px) !important; }

/* REVEAL */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .8s cubic-bezier(.2,.7,.2,1), transform .8s cubic-bezier(.2,.7,.2,1); }
.reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .marquee__track { animation: none; }
  html { scroll-behavior: auto; }
}

/* RESPONSIVE */
@media (max-width: 900px) {
  .nav__links { display: none; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .role { grid-template-columns: 1fr; gap: 8px; }
  .role__meta { padding-top: 0; }
  .grid-2, .grid-3, .edu, .writing { grid-template-columns: 1fr; }
  .credits li { grid-template-columns: 1fr; gap: 4px; }
  .credits__where { text-align: left; }
  .year { grid-template-columns: 1fr; gap: 12px; }
  .year li { grid-template-columns: 1fr; gap: 2px; padding-bottom: 8px; }
  .year .c { text-align: left; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .nav__links { display: none; }
  .stats { grid-template-columns: 1fr; }
  .card { padding: 24px; }
}
