/* Russell Darling
   Palette: screening room ink, light table paper, non photo blue (the
   col-erase pencil every storyboard artist works in), playhead amber. */

:root {
  --ink: #0e1419;
  --ink-2: #151f28;
  --ink-3: #1d2b36;
  --paper: #dce1de;
  --paper-2: #cbd2ce;
  --chalk: #f4f6f5;
  --muted: #8ea0ac;
  --muted-ink: #4d5b58;
  --blue: #6fcbe0;
  --amber: #e7b44e;
  --rule: rgba(142, 160, 172, 0.24);

  --display: 'Archivo', 'Helvetica Neue', sans-serif;
  --body: 'IBM Plex Sans', system-ui, sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, monospace;

  --gutter: clamp(1.25rem, 5vw, 5.5rem);
  --measure: 62ch;

  /* Timeline geometry. The ruler, the lanes and the playhead all start
     at the same x position, after the track labels. */
  --track-label: 13rem;
  --track-gap: 1rem;
  --lane-start: calc(var(--track-label) + var(--track-gap));
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--ink);
  color: var(--chalk);
  font-family: var(--body);
  font-size: clamp(1rem, 0.96rem + 0.2vw, 1.0625rem);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.display {
  font-family: var(--display);
  font-variation-settings: 'wdth' 118, 'wght' 700;
  font-weight: 700;
  letter-spacing: -0.015em;
  line-height: 1.02;
  margin: 0;
  text-wrap: balance;
}

.eyebrow {
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--blue);
  margin: 0 0 0.9rem;
}

.lede { max-width: var(--measure); color: var(--muted); margin: 0.9rem 0 0; }

a { color: inherit; }

:focus-visible {
  outline: 2px solid var(--amber);
  outline-offset: 3px;
}

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--amber);
  color: var(--ink);
  padding: 0.6rem 1rem;
  z-index: 20;
}
.skip:focus { left: 0; }

.page { overflow-x: clip; }

/* ---------- Hero ---------- */

.hero {
  padding: clamp(3rem, 9vw, 7rem) var(--gutter) clamp(2rem, 5vw, 3.5rem);
  border-bottom: 1px solid var(--rule);
  background:
    radial-gradient(120% 80% at 12% 0%, rgba(111, 203, 224, 0.1), transparent 60%),
    var(--ink);
}

.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: end;
}

.hero__name {
  font-size: clamp(2.9rem, 11vw, 8.5rem);
  font-variation-settings: 'wdth' 122, 'wght' 800;
  text-transform: uppercase;
  line-height: 0.88;
}

.hero__role {
  font-family: var(--mono);
  font-size: clamp(0.85rem, 1.6vw, 1rem);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--amber);
  margin: 1.1rem 0 0;
}

.hero__tagline {
  max-width: 48ch;
  margin: 1.4rem 0 0;
  font-size: clamp(1.05rem, 1.6vw, 1.28rem);
  color: var(--chalk);
}

.hero__links { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 1.8rem; }

.link-chip {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 0.55rem 0.95rem;
  border: 1px solid var(--rule);
  color: var(--muted);
  transition: color 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}
.link-chip:hover { color: var(--ink); background: var(--blue); border-color: var(--blue); }

.link-chip--solid {
  color: var(--ink);
  background: var(--blue);
  border-color: var(--blue);
  margin-top: 1.6rem;
  display: inline-block;
}
.link-chip--solid:hover { background: var(--amber); border-color: var(--amber); }

/* the slate */
.slate { border: 1px solid var(--rule); background: var(--ink-2); }

.slate__clapper {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  height: 26px;
  transform: skewX(-14deg);
  overflow: hidden;
}
.slate__clapper span { background: var(--chalk); }
.slate__clapper span:nth-child(odd) { background: var(--ink-3); }

.slate__body { padding: 1.1rem 1.25rem 1.3rem; }

.slate__row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.55rem 0;
  border-bottom: 1px dashed var(--rule);
  font-family: var(--mono);
  font-size: 0.78rem;
}
.slate__row:last-child { border-bottom: 0; }
.slate__label { color: var(--muted); text-transform: uppercase; letter-spacing: 0.12em; font-size: 0.68rem; }
.slate__value { color: var(--chalk); text-align: right; }

.hero__roles {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.6rem;
  list-style: none;
  margin: clamp(2rem, 5vw, 3.5rem) 0 0;
  padding: 0;
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}
.hero__roles li::before { content: '/ '; color: var(--blue); }

/* ---------- Section frame ---------- */

.section { padding: clamp(3.5rem, 8vw, 6.5rem) var(--gutter); }
.section__head { margin-bottom: clamp(2rem, 4vw, 3rem); }
.section__head h2 { font-size: clamp(1.9rem, 4.6vw, 3.3rem); }

.section--credits,
.section--recognition,
.section--bio {
  background: var(--paper);
  color: var(--ink);
}
.section--credits .eyebrow,
.section--recognition .eyebrow,
.section--bio .eyebrow { color: var(--muted-ink); }
.section--credits .lede,
.section--recognition .lede,
.section--bio .lede { color: var(--muted-ink); }

/* ---------- Now ---------- */

.now { max-width: 68ch; }
.now h2 { font-size: clamp(2rem, 5.4vw, 3.6rem); }
.now h2 em { font-style: normal; color: var(--blue); }
.now__since { font-family: var(--mono); font-size: 0.78rem; color: var(--amber); margin: 0.8rem 0 0; letter-spacing: 0.1em; }
.now__list { list-style: none; padding: 0; margin: 1.8rem 0 0; display: grid; gap: 0.7rem; }
.now__list li {
  padding-left: 1.4rem;
  position: relative;
  color: var(--chalk);
}
.now__list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.66em;
  width: 0.55rem;
  height: 1px;
  background: var(--blue);
}

/* ---------- Timeline ---------- */

.section--timeline { border-top: 1px solid var(--rule); background: var(--ink); }

.timeline { position: relative; }

.timeline__scroll {
  overflow-x: auto;
  overflow-y: hidden;
  padding-bottom: 0.75rem;
  scrollbar-color: var(--ink-3) transparent;
}

.timeline__inner {
  position: relative;
  min-width: 900px;
  padding-top: 2.2rem;
}

.ruler {
  position: absolute;
  top: 0;
  right: 0;
  left: var(--lane-start);
  height: 2rem;
  border-bottom: 1px solid var(--rule);
}
.ruler__mark {
  position: absolute;
  bottom: 0.35rem;
  transform: translateX(-50%);
  font-family: var(--mono);
  font-size: 0.68rem;
  color: var(--muted);
}
.ruler__mark i {
  display: block;
  width: 1px;
  height: 0.5rem;
  background: var(--rule);
  margin: 0 auto 0.25rem;
}

.tracks { display: grid; gap: 0.5rem; padding-top: 0.9rem; }

.track { display: grid; grid-template-columns: var(--track-label) minmax(0, 1fr); align-items: center; gap: var(--track-gap); }

.track__label {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  display: flex;
  gap: 0.6rem;
  align-items: baseline;
}
.track__label b { color: var(--amber); font-weight: 500; }

.track__lane {
  position: relative;
  height: 3.2rem;
  background:
    repeating-linear-gradient(90deg, var(--ink-2) 0 1px, transparent 1px 40px),
    var(--ink-2);
  border: 1px solid var(--rule);
}

.clip {
  position: absolute;
  left: var(--left);
  width: var(--width);
  top: 0.3rem;
  bottom: 0.3rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.1rem;
  padding: 0 0.7rem;
  border: 1px solid rgba(111, 203, 224, 0.45);
  border-left: 3px solid var(--blue);
  background: rgba(111, 203, 224, 0.14);
  color: var(--chalk);
  font-family: inherit;
  text-align: left;
  cursor: pointer;
  overflow: hidden;
  transition: background 0.18s ease, transform 0.18s ease;
}
.clip:hover { background: rgba(111, 203, 224, 0.26); }
.clip[aria-pressed='true'] {
  background: var(--blue);
  color: var(--ink);
  border-color: var(--blue);
}
.clip--open { border-left-color: var(--amber); }
.clip--open:not([aria-pressed='true']) { background: rgba(231, 180, 78, 0.18); border-color: rgba(231, 180, 78, 0.5); }

.clip__org {
  font-size: 0.82rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.clip__years { font-family: var(--mono); font-size: 0.66rem; opacity: 0.75; white-space: nowrap; }

.playhead {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 1px;
  background: var(--amber);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}
.timeline:hover .playhead { opacity: 0.9; }
.playhead__year {
  position: absolute;
  top: 0;
  transform: translate(-50%, -100%);
  font-family: var(--mono);
  font-size: 0.66rem;
  background: var(--amber);
  color: var(--ink);
  padding: 0.1rem 0.35rem;
}

.timeline__hint {
  font-family: var(--mono);
  font-size: 0.68rem;
  color: var(--muted);
  margin: 0.8rem 0 0;
}

.monitor {
  margin-top: clamp(1.6rem, 3vw, 2.4rem);
  border: 1px solid var(--rule);
  background: var(--ink-2);
  padding: clamp(1.4rem, 3vw, 2.2rem);
  display: grid;
  gap: 1.4rem;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
}
.monitor__role { font-family: var(--mono); font-size: 0.74rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--amber); margin: 0 0 0.6rem; }
.monitor__org { font-family: var(--display); font-variation-settings: 'wdth' 112, 'wght' 700; font-size: clamp(1.4rem, 3vw, 2.1rem); margin: 0; line-height: 1.05; }
.monitor__years { font-family: var(--mono); font-size: 0.72rem; color: var(--muted); margin: 0.5rem 0 0; }
.monitor__summary { margin: 1rem 0 0; color: var(--chalk); max-width: 50ch; }
.monitor__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.55rem; align-content: start; }
.monitor__list li {
  font-family: var(--mono);
  font-size: 0.76rem;
  color: var(--muted);
  padding-left: 1.3rem;
  position: relative;
}
.monitor__list li::before { content: '+'; position: absolute; left: 0; color: var(--blue); }

/* ---------- Credits ---------- */

.credits { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--paper-2); }

.credit {
  display: grid;
  grid-template-columns: 5rem minmax(0, 1fr) auto;
  gap: 1rem;
  align-items: baseline;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--paper-2);
}
.credit__year { font-family: var(--mono); font-size: 0.8rem; color: var(--muted-ink); }
.credit__title {
  font-family: var(--display);
  font-variation-settings: 'wdth' 108, 'wght' 600;
  font-size: clamp(1.05rem, 2.4vw, 1.5rem);
  line-height: 1.15;
}
.credit__company { font-family: var(--mono); font-size: 0.72rem; color: var(--muted-ink); text-align: right; }

/* ---------- Recognition ---------- */

.cards { list-style: none; margin: 0; padding: 0; display: grid; gap: 1px; background: var(--paper-2); border: 1px solid var(--paper-2); grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr)); }
.card { background: var(--paper); padding: 1.5rem 1.4rem 1.7rem; }
.card__kind { font-family: var(--mono); font-size: 0.66rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted-ink); }
.card__title { font-family: var(--display); font-variation-settings: 'wdth' 105, 'wght' 600; font-size: 1.15rem; margin: 0.7rem 0 0.5rem; line-height: 1.2; }
.card__detail { margin: 0; color: var(--muted-ink); font-size: 0.94rem; }

/* ---------- Bio ---------- */

.bio { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr); gap: clamp(2rem, 5vw, 4rem); }
.bio__head h2 { font-size: clamp(1.9rem, 4vw, 2.9rem); }
.bio__body p { margin: 0 0 1.1rem; max-width: var(--measure); }
.bio__body p:first-child::first-letter {
  font-family: var(--display);
  font-variation-settings: 'wdth' 118, 'wght' 800;
  float: left;
  font-size: 3.4rem;
  line-height: 0.82;
  padding: 0.1rem 0.6rem 0 0;
}

/* ---------- Contact ---------- */

.section--contact { border-top: 1px solid var(--rule); }
.contact { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(2rem, 5vw, 4rem); align-items: start; }
.contact__head h2 { font-size: clamp(1.9rem, 4.4vw, 3rem); }

.field { display: grid; gap: 0.35rem; margin-bottom: 1rem; }
.field label { font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }
.field input,
.field textarea {
  background: var(--ink-2);
  border: 1px solid var(--rule);
  color: var(--chalk);
  font-family: inherit;
  font-size: 0.95rem;
  padding: 0.7rem 0.8rem;
  width: 100%;
  resize: vertical;
}
.field input:focus,
.field textarea:focus { border-color: var(--blue); outline: none; }

.pot { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

.send {
  font-family: var(--mono);
  font-size: 0.74rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  background: var(--chalk);
  color: var(--ink);
  border: 0;
  padding: 0.85rem 1.6rem;
  cursor: pointer;
  transition: background 0.18s ease;
}
.send:hover { background: var(--blue); }
.send[disabled] { opacity: 0.55; cursor: not-allowed; }

.form-status { font-family: var(--mono); font-size: 0.74rem; color: var(--muted); min-height: 1.4rem; margin: 0.9rem 0 0; }
.form-status[data-state='error'] { color: var(--amber); }
.form-status[data-state='ok'] { color: var(--blue); }

/* ---------- Footer ---------- */

.footer {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 2rem;
  justify-content: space-between;
  padding: 2rem var(--gutter) 3rem;
  border-top: 1px solid var(--rule);
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--muted);
}
.footer p { margin: 0; }
.footer a { text-decoration: none; }
.footer a:hover { color: var(--blue); }

/* ---------- Reveal ---------- */

.reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.is-in { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */

@media (max-width: 900px) {
  .hero__grid { grid-template-columns: minmax(0, 1fr); align-items: start; }
  .monitor,
  .bio,
  .contact { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 760px) {
  .timeline__scroll { overflow: visible; }
  .timeline__inner { min-width: 0; padding-top: 0; }
  .ruler { display: none; }
  .timeline__hint { display: none; }
  .playhead { display: none; }
  .tracks { display: flex; flex-direction: column; gap: 0.5rem; padding-top: 0; }
  .track { display: contents; }
  .track__label { display: none; }
  .track__lane { display: contents; }
  .clip {
    position: static;
    width: 100%;
    order: var(--order);
    flex-direction: row;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.8rem;
    padding: 0.85rem 0.9rem;
  }
  .credit { grid-template-columns: 3.6rem minmax(0, 1fr); }
  .credit__company { grid-column: 2; text-align: left; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
  .reveal { opacity: 1; transform: none; }
}
