/* ==========================================================================
   Jamie Mason-Wright — personal site
   Dark & cinematic. Type: Archivo (variable), Instrument Serif, JetBrains Mono.
   ========================================================================== */

:root {
  --bg: #070708;
  --bg-2: #0d0d0f;
  --bg-3: #151517;
  --ink: #f3eee6;
  --ink-dim: #a6a199;
  --ink-faint: #5f5b55;
  --line: rgba(243, 238, 230, 0.12);
  --line-2: rgba(243, 238, 230, 0.24);
  --ember: #ff5a1f;
  --ember-2: #ff9a52;
  --ember-glow: rgba(255, 90, 31, 0.35);
  --ok: #7be0a4;
  --bad: #ff7a6b;

  --display: "Archivo", system-ui, -apple-system, "Segoe UI", sans-serif;
  --serif: "Instrument Serif", Georgia, "Times New Roman", serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --pad: clamp(1.25rem, 4vw, 3.5rem);
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  -webkit-text-size-adjust: 100%;
}
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }
html.is-loading { overflow: hidden; }
main { overflow-x: clip; }

body {
  margin: 0;
  font-family: var(--display);
  font-size: clamp(1rem, 0.35vw + 0.92rem, 1.125rem);
  line-height: 1.55;
  overflow-x: hidden;
}

::selection { background: var(--ember); color: #0a0a0a; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
ul, ol, dl, dd, figure { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, p { margin: 0; }
canvas { display: block; }
em { font-style: normal; }
:focus-visible { outline: 2px solid var(--ember); outline-offset: 4px; border-radius: 4px; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* ---------- Film grain + vignette ---------- */
.grain {
  position: fixed; inset: -50%; width: 200%; height: 200%;
  z-index: 90; pointer-events: none; opacity: 0.075;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0 0 0 .9 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  animation: grain 0.9s steps(6) infinite;
}
@keyframes grain {
  0% { transform: translate(0, 0); }
  20% { transform: translate(-4%, 3%); }
  40% { transform: translate(3%, -5%); }
  60% { transform: translate(-2%, 5%); }
  80% { transform: translate(5%, 2%); }
  100% { transform: translate(0, 0); }
}
.vignette {
  position: fixed; inset: 0; z-index: 89; pointer-events: none;
  background: radial-gradient(ellipse at center, transparent 55%, rgba(0, 0, 0, 0.55) 100%);
}

/* ---------- Intro curtain ---------- */
.loader { display: none; position: fixed; inset: 0; z-index: 100; }
.is-loading .loader { display: block; }
.loader__bar { position: absolute; left: 0; right: 0; height: 50.5%; background: #000; }
.loader__bar--top { top: 0; }
.loader__bar--bottom { bottom: 0; }
.loader__inner {
  position: absolute; inset: 0; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 1.25rem;
}
.loader__name { font-family: var(--mono); font-size: 0.75rem; letter-spacing: 0.32em; color: var(--ink-dim); }
.loader__num {
  font-size: clamp(5rem, 16vw, 12rem); font-weight: 800; font-stretch: 78%;
  line-height: 0.9; letter-spacing: -0.03em; font-variant-numeric: tabular-nums;
}
.loader__line { width: min(20rem, 60vw); height: 1px; background: var(--line); overflow: hidden; }
.loader__fill { display: block; height: 100%; background: var(--ember); transform: scaleX(0); transform-origin: left; }

/* ---------- Custom cursor (fine pointers only) ---------- */
.cursor { display: none; position: fixed; top: 0; left: 0; z-index: 95; pointer-events: none; mix-blend-mode: difference; opacity: 0; transition: opacity 0.3s; }
.has-cursor .cursor { display: block; }
.has-cursor .cursor.is-on { opacity: 1; }
.has-cursor, .has-cursor a, .has-cursor button { cursor: none; }
.cursor__dot, .cursor__ring { position: absolute; top: 0; left: 0; border-radius: 50%; }
.cursor__dot { width: 6px; height: 6px; background: #fff; }
.cursor__ring {
  width: 38px; height: 38px; border: 1px solid #fff;
  transition: width 0.4s var(--ease), height 0.4s var(--ease), background-color 0.4s var(--ease);
}
.cursor.is-hover .cursor__ring { width: 84px; height: 84px; background: #fff; }

/* ---------- Shared bits ---------- */
.section { position: relative; padding: clamp(6rem, 16vh, 12rem) var(--pad); }

.label {
  display: flex; align-items: center; gap: 1rem;
  font-family: var(--mono); font-size: 0.75rem; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--ember); margin-bottom: 2rem;
}
.label::after { content: ""; flex: 0 0 3.5rem; height: 1px; background: currentColor; opacity: 0.55; }

.h2 {
  font-size: clamp(2.6rem, 6.4vw, 6.25rem); line-height: 0.96; letter-spacing: -0.035em;
  font-weight: 800; font-stretch: 84%;
}
.h2 em, .contact__title em, .about__text em {
  font-family: var(--serif); font-style: italic; font-weight: 400;
  font-stretch: 100%; letter-spacing: -0.01em; color: var(--ember);
}
.h2 em { white-space: nowrap; }

/* word masks for heading reveals */
.mask { display: inline-block; overflow: hidden; vertical-align: top; padding: 0 0.06em 0.14em; margin: 0 -0.06em -0.14em; }
.mask > .hw { display: inline-block; will-change: transform; }

.pulse {
  display: inline-block; flex: none; width: 8px; height: 8px; border-radius: 50%;
  background: var(--ember); animation: pulse 2.2s ease-out infinite;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 var(--ember-glow); }
  70% { box-shadow: 0 0 0 10px rgba(255, 90, 31, 0); }
  100% { box-shadow: 0 0 0 0 rgba(255, 90, 31, 0); }
}

.tags { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.tags li {
  font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.06em; text-transform: uppercase;
  padding: 0.4rem 0.7rem; border: 1px solid var(--line-2); border-radius: 999px; color: var(--ink-dim);
}

/* rolling-text hover */
.roll { display: inline-block; overflow: hidden; vertical-align: top; }
.roll > span { display: block; position: relative; transition: transform 0.5s var(--ease); }
.roll > span::after { content: attr(data-text); position: absolute; left: 0; top: 100%; color: var(--ember); }
.roll:hover > span, .roll:focus-visible > span { transform: translateY(-100%); }

/* buttons */
.btn {
  position: relative; display: inline-flex; align-items: center; justify-content: center;
  padding: 0.95rem 1.6rem; border-radius: 999px; border: 1px solid var(--line-2);
  font-weight: 600; font-size: 0.95rem; letter-spacing: 0.01em; overflow: hidden; isolation: isolate;
  transition: color 0.45s var(--ease), border-color 0.45s var(--ease);
}
.btn::before {
  content: ""; position: absolute; inset: -1px; z-index: -1; border-radius: inherit;
  background: var(--ink); transform: translateY(101%); transition: transform 0.55s var(--ease);
}
.btn:hover, .btn:focus-visible { color: #0a0a0a; border-color: var(--ink); }
.btn:hover::before, .btn:focus-visible::before { transform: translateY(0); }
.btn--solid { background: var(--ember); border-color: var(--ember); color: #0a0a0a; }
.btn--small { padding: 0.6rem 1.1rem; font-size: 0.85rem; }

/* ---------- Plain-language line (the recruiter's read) ---------- */
.plain {
  max-width: 34rem; margin-top: 1.75rem;
  font-size: clamp(1.15rem, 1.5vw, 1.4rem); line-height: 1.35; letter-spacing: -0.01em; color: var(--ink);
}
.plain b {
  display: block; margin-bottom: 0.55rem; font-family: var(--mono); font-weight: 400;
  font-size: 0.68rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ember);
}

/* ---------- Bridges: the thread from one section to the next ---------- */
.bridge {
  display: grid; grid-template-columns: 11px minmax(0, 1fr); column-gap: 1.4rem; align-items: center;
  padding: 0 var(--pad);
}
.bridge__line, .bridge__tail { grid-column: 1; justify-self: center; width: 1px; background: var(--line-2); }
.bridge__line { grid-row: 1; height: clamp(4.5rem, 13vh, 8rem); }
.bridge__tail { grid-row: 3; height: clamp(2.5rem, 7vh, 4.5rem); }
.bridge__line i, .bridge__tail i {
  display: block; width: 100%; height: 100%; background: var(--ember);
  box-shadow: 0 0 10px var(--ember); transform-origin: top;
}
.bridge__node {
  grid-column: 1; grid-row: 2; width: 11px; height: 11px; margin: 7px 0; border-radius: 50%;
  border: 1px solid var(--ember); background: var(--ember);
  box-shadow: 0 0 0 5px rgba(255, 90, 31, 0.12), 0 0 18px var(--ember-glow);
}
.bridge__body { grid-column: 2; grid-row: 2; display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.35rem 1.5rem; }
.bridge__text { font-family: var(--serif); font-style: italic; font-size: clamp(1.35rem, 2.3vw, 2rem); line-height: 1.15; }
.bridge__next {
  font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--ink-dim); transition: color 0.4s;
}
.bridge__next b { margin: 0 0.3em; font-weight: 500; color: var(--ember); }
.bridge__next span { display: inline-block; margin-left: 0.3em; transition: transform 0.5s var(--ease); }
.bridge:hover .bridge__next, .bridge:focus-visible .bridge__next { color: var(--ink); }
.bridge:hover .bridge__next span { transform: translateY(4px); }

/* the thread lands on the next section's label, so close the gap around it */
.section:has(+ .bridge) { padding-bottom: clamp(3rem, 7vh, 5rem); }
.work:not(.is-pinned):has(+ .bridge) { padding-bottom: clamp(3rem, 7vh, 5rem); }
.bridge + .section, .bridge + .work:not(.is-pinned) { padding-top: 1.5rem; }

/* ---------- Signal rail (desktop) and progress bar (phones) ---------- */
.rail {
  display: none; position: fixed; z-index: 70; top: 50%; right: clamp(0.55rem, 1.35vw, 1.35rem);
  height: min(46vh, 24rem); width: 11px; margin-top: calc(min(46vh, 24rem) / -2);
}
.rail__track { position: absolute; left: 5px; top: 0; bottom: 0; width: 1px; background: var(--line-2); }
.rail__fill { position: absolute; inset: 0; background: var(--ember); transform: scaleY(0); transform-origin: top; }
.rail ol { position: relative; height: 100%; display: flex; flex-direction: column; justify-content: space-between; align-items: center; }
.rail a {
  position: relative; display: block; width: 9px; height: 9px; border-radius: 50%;
  background: var(--bg); border: 1px solid var(--ink-faint);
  transition: background-color 0.4s, border-color 0.4s, box-shadow 0.4s, scale 0.4s var(--ease);
}
.rail a::before { content: ""; position: absolute; inset: -9px; }
.rail a.is-past { background: var(--ember); border-color: var(--ember); }
.rail a.is-active {
  background: var(--ember); border-color: var(--ember); scale: 1.35;
  box-shadow: 0 0 0 4px rgba(255, 90, 31, 0.18), 0 0 16px var(--ember);
}
.rail a span {
  position: absolute; right: calc(100% + 0.9rem); top: 50%; translate: 6px -50%; white-space: nowrap;
  padding: 0.32rem 0.6rem; border-radius: 999px; background: rgba(13, 13, 15, 0.92); border: 1px solid var(--line-2);
  font-family: var(--mono); font-size: 0.66rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink);
  opacity: 0; pointer-events: none; transition: opacity 0.35s, translate 0.45s var(--ease);
}
.rail a:hover span, .rail a:focus-visible span, .rail a.is-flash span { opacity: 1; translate: 0 -50%; }
.rail a.is-active span { scale: 0.74; transform-origin: right center; } /* undo the dot's scale on its label */

.progress { display: none; position: fixed; top: 0; left: 0; right: 0; z-index: 85; height: 2px; pointer-events: none; }
.progress__fill { display: block; height: 100%; background: var(--ember); transform: scaleX(0); transform-origin: left; }

@media (min-width: 901px) { .has-motion .rail { display: block; } }
@media (max-width: 900px) { .has-motion .progress { display: block; } }

/* ---------- Nav ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 80;
  display: flex; align-items: center; gap: 2rem; padding: 1.1rem var(--pad);
  /* transform is animated by GSAP (intro + hide on scroll): no CSS transition on it */
  transition: background-color 0.4s, backdrop-filter 0.4s;
}
.nav.is-scrolled { background: rgba(7, 7, 8, 0.6); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.nav__logo { font-weight: 900; font-stretch: 110%; font-size: 1.15rem; letter-spacing: 0.02em; }
.nav__logo span { color: var(--ember); }
.nav__links { display: flex; gap: 1.75rem; margin-left: auto; font-size: 0.9rem; font-weight: 500; }
.nav__time {
  display: flex; align-items: center; gap: 0.6rem;
  font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-dim);
}

/* ---------- Hero ---------- */
.hero {
  position: relative; min-height: 100vh; min-height: 100svh; isolation: isolate; overflow: hidden;
  display: flex; flex-direction: column; justify-content: center;
  padding: 7rem var(--pad) 7.5rem;
}
.hero__canvas {
  position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1;
  /* quieter behind the text column, full strength on the right */
  -webkit-mask-image: linear-gradient(90deg, rgba(0, 0, 0, 0.55) 0%, #000 60%);
  mask-image: linear-gradient(90deg, rgba(0, 0, 0, 0.55) 0%, #000 60%);
}
.hero__glow {
  position: absolute; z-index: -2; left: 50%; top: 58%; width: 75vmax; height: 75vmax;
  margin: -37.5vmax 0 0 -37.5vmax; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(255, 90, 31, 0.26), rgba(255, 90, 31, 0.07) 55%, transparent 72%);
  animation: breathe 9s ease-in-out infinite;
}
@keyframes breathe { 0%, 100% { scale: 1; opacity: 0.85; } 50% { scale: 1.12; opacity: 1; } }

.hero__eyebrow {
  display: flex; align-items: center; gap: 0.8rem; margin-bottom: 1.75rem;
  font-family: var(--mono); font-size: 0.75rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-dim);
}
.hero__eyebrow i { font-style: normal; color: var(--ember); }
.hero__eyebrow .pulse { margin-top: 0.1em; }

.hero__name {
  font-weight: 800; font-stretch: 80%; text-transform: uppercase;
  font-size: clamp(3rem, 12.6vw, 14rem); line-height: 0.86; letter-spacing: -0.02em;
  user-select: none;
}
.hero__name .line { display: block; overflow: hidden; padding: 0.04em 0 0.02em; perspective: 900px; }
.hero__name .char { display: inline-block; transform-origin: 50% 100%; will-change: transform; }

.hero__tag {
  margin-top: 2.25rem; font-size: clamp(1.35rem, 2.9vw, 2.6rem); line-height: 1.2;
  font-weight: 400; letter-spacing: -0.015em; color: var(--ink);
}
.hero__tag em { position: relative; font-family: var(--serif); font-style: italic; font-size: 1.12em; color: var(--ember); }
.roller {
  display: inline-block; height: 1.2em; overflow: hidden; vertical-align: bottom;
  font-family: var(--serif); font-style: italic; font-size: 1.12em; line-height: 1.2; color: var(--ember); white-space: nowrap;
}
.roller__track { display: flex; flex-direction: column; align-items: flex-start; }
.roller__track > span { display: block; width: max-content; height: 1.2em; padding-right: 0.12em; }

.hero__actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 2.5rem; }

.hero__meta {
  position: absolute; left: var(--pad); right: var(--pad); bottom: 2rem;
  display: flex; gap: 3rem; align-items: flex-end;
  font-size: 0.9rem; border-top: 1px solid var(--line); padding-top: 1.1rem;
}
.hero__meta dt { font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-faint); margin-bottom: 0.25rem; }
.hero__meta dd { color: var(--ink-dim); }
.hero__scroll { margin-left: auto; text-align: right; }
.hero__scroll-line { display: block; width: 5rem; height: 1px; margin-top: 0.7rem; background: var(--line); position: relative; overflow: hidden; }
.hero__scroll-line::after { content: ""; position: absolute; inset: 0; background: var(--ember); animation: scrollLine 2.2s var(--ease) infinite; }
@keyframes scrollLine { 0% { transform: translateX(-100%); } 60%, 100% { transform: translateX(100%); } }

/* ---------- Tapes (marquees) ---------- */
.tapes { position: relative; height: clamp(13rem, 26vw, 20rem); overflow: hidden; display: grid; place-items: center; }
.tape {
  position: absolute; left: -5%; width: 110%; overflow: hidden; white-space: nowrap;
  padding: clamp(0.7rem, 1.4vw, 1.2rem) 0; font-weight: 800; font-stretch: 88%; text-transform: uppercase;
  font-size: clamp(1.3rem, 3vw, 2.7rem); letter-spacing: -0.01em; line-height: 1;
}
.tape--a { background: var(--ember); color: #0a0a0a; transform: rotate(-3deg); z-index: 2; box-shadow: 0 20px 60px rgba(255, 90, 31, 0.18); }
.tape--b { background: var(--bg-3); color: var(--ink); transform: rotate(2.5deg); border-block: 1px solid var(--line); }
.tape__track { display: inline-flex; align-items: center; gap: clamp(1.25rem, 2.5vw, 2.5rem); padding-right: clamp(1.25rem, 2.5vw, 2.5rem); will-change: transform; }
.tape__track i { font-style: normal; font-size: 0.6em; opacity: 0.7; }
.tape--b .tape__track i { color: var(--ember); opacity: 1; }
.tape--b .o { color: transparent; -webkit-text-stroke: 1px var(--ink-dim); }

/* ---------- About ---------- */
.about__text {
  max-width: 70rem; font-size: clamp(1.65rem, 3.7vw, 3.6rem); line-height: 1.12;
  letter-spacing: -0.025em; font-weight: 500; font-stretch: 92%;
}

/* track record: specific outcomes, each ticked off like a passing check */
.proof { margin-top: clamp(4rem, 10vh, 7rem); }
.proof__head {
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
  padding-bottom: 1.1rem; border-bottom: 1px solid var(--line-2);
  font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-dim);
}
.proof__status { display: inline-flex; align-items: center; gap: 0.6rem; color: var(--ok); }
.proof__dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 10px rgba(123, 224, 164, 0.7); }
.proof__row {
  position: relative; isolation: isolate;
  display: grid; grid-template-columns: 3rem minmax(0, 1.35fr) minmax(0, 1fr); gap: 1.25rem 2.5rem; align-items: center;
  padding: 2rem 0; border-bottom: 1px solid var(--line);
}
.proof__row::before {
  content: ""; position: absolute; inset: 0 -1rem; z-index: -1; border-radius: 14px;
  background: linear-gradient(90deg, rgba(255, 90, 31, 0.09), transparent 72%);
  opacity: 0; transition: opacity 0.5s var(--ease);
}
.proof__row:hover::before { opacity: 1; }
.proof__check {
  width: 2.5rem; height: 2.5rem; fill: none; stroke: var(--ember); stroke-width: 1.6;
  stroke-linecap: round; stroke-linejoin: round; overflow: visible;
}
.proof__check circle, .proof__check path { stroke-dasharray: 1; }
.proof__check circle { transform: rotate(-90deg); transform-box: fill-box; transform-origin: center; stroke-opacity: 0.55; }
.proof__row.is-pass .proof__check { filter: drop-shadow(0 0 8px var(--ember-glow)); }
.proof__row h3 { font-size: clamp(1.45rem, 2.6vw, 2.45rem); font-weight: 700; font-stretch: 86%; line-height: 1.08; letter-spacing: -0.025em; text-wrap: balance; }
.proof__row h3 em { font-family: var(--serif); font-style: italic; font-weight: 400; font-stretch: 100%; letter-spacing: -0.01em; color: var(--ember); }
.proof__ev { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.proof__ev li {
  padding: 0.45rem 0.75rem; border: 1px solid var(--line-2); border-radius: 999px;
  font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.05em; text-transform: uppercase; color: var(--ink-dim);
  transition: color 0.4s, border-color 0.4s;
}
.proof__row:hover .proof__ev li { color: var(--ink); border-color: rgba(255, 90, 31, 0.5); }

/* ---------- Work ---------- */
.work { position: relative; padding: clamp(5rem, 12vh, 9rem) 0; overflow: hidden; }
.work__head {
  display: flex; justify-content: space-between; align-items: flex-end; gap: 2rem;
  padding: 0 var(--pad); margin-bottom: clamp(2rem, 5vh, 3.5rem);
}
.work__head .label { margin-bottom: 1.25rem; }
.work__aside { max-width: 21rem; color: var(--ink-dim); font-size: 0.95rem; }
.work__progress { display: none; height: 2px; margin-top: 1.25rem; background: var(--line); }
.work__progress-fill { display: block; height: 100%; background: var(--ember); transform: scaleX(0); transform-origin: left; }

.work__track { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 24rem), 1fr)); gap: 1.25rem; padding: 0 var(--pad); }

.job {
  position: relative; overflow: hidden; display: flex; flex-direction: column;
  padding: clamp(1.5rem, 2.2vw, 2.25rem); border-radius: 22px; border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.045), rgba(255, 255, 255, 0.012));
  transition: border-color 0.5s var(--ease), background-color 0.5s;
}
.job:hover { border-color: rgba(255, 90, 31, 0.55); }
.job__ghost {
  position: absolute; right: -0.06em; bottom: -0.2em; z-index: 0; pointer-events: none;
  font-size: clamp(9rem, 17vw, 16rem); font-weight: 900; font-stretch: 75%; line-height: 1; letter-spacing: -0.05em;
  color: transparent; -webkit-text-stroke: 1px rgba(243, 238, 230, 0.07);
}
.job > *:not(.job__ghost) { position: relative; z-index: 1; }
.job__top {
  display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.75rem;
  font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-dim);
}
.job__idx { color: var(--ember); }
.job__co { font-size: clamp(1.6rem, 2.25vw, 2.15rem); font-weight: 800; font-stretch: 82%; line-height: 1.02; letter-spacing: -0.03em; text-wrap: balance; }
.job__role { margin-top: 0.6rem; font-family: var(--serif); font-style: italic; font-size: 1.3rem; line-height: 1.2; color: var(--ember-2); }
.job__list { margin: 1.4rem 0 1.5rem; display: grid; gap: 0.6rem; font-size: 0.9rem; line-height: 1.45; color: var(--ink-dim); }
.job__list li { position: relative; padding-left: 1.1rem; }
.job__list li::before { content: ""; position: absolute; left: 0; top: 0.6em; width: 5px; height: 5px; border-radius: 50%; background: var(--ember); }
.job .tags { margin-top: auto; }

.job--end { justify-content: space-between; gap: 2rem; background: var(--ember); border-color: var(--ember); color: #0a0a0a; min-height: 18rem; }
.job--end:hover { border-color: var(--ink); }
.job__endlabel { font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.14em; text-transform: uppercase; }
.job__endtext { font-size: clamp(1.8rem, 2.6vw, 2.5rem); font-weight: 800; font-stretch: 82%; line-height: 1; letter-spacing: -0.03em; }
.job__endcta { font-weight: 700; display: inline-flex; gap: 0.5rem; }
.job__endcta span { transition: transform 0.5s var(--ease); }
.job--end:hover .job__endcta span { transform: translateX(8px); }

/* pinned horizontal mode (set by JS on large screens) */
.work.is-pinned { height: 100vh; padding: 5.5rem 0 2rem; display: flex; flex-direction: column; justify-content: center; }
.work.is-pinned .work__progress { display: block; }
.work.is-pinned .work__track { display: flex; gap: 1.5rem; width: max-content; padding-right: 12vw; will-change: transform; }
.work.is-pinned .job { flex: 0 0 clamp(25rem, 31vw, 31rem); min-height: min(60vh, 34rem); }
.work.is-pinned .job--end { flex-basis: clamp(20rem, 24vw, 25rem); }

/* ---------- AI & ML ---------- */
/* the orbit's chips swing outside its box; clip so they never widen the page */
.aiml { overflow: hidden; overflow: clip; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(2.5rem, 6vw, 6rem); align-items: center; }
.aiml__copy > p:not(.label):not(.plain) { max-width: 36rem; margin-top: 1.5rem; color: var(--ink-dim); }
.aiml__copy .h2 { font-size: clamp(2.5rem, 5.4vw, 5.25rem); }
.tags--loose { margin-top: 2.25rem; }
.tags--loose li { border-color: var(--line); }

/* the model scene: a 3D canvas with a caption card that explains the lit-up part */
.orbit { position: relative; width: min(100%, 42rem); margin: 0 auto; }
.orbit__stage { position: relative; aspect-ratio: 1; }
.orbit__canvas { position: absolute; left: -6%; top: -6%; width: 112%; height: 112%; touch-action: pan-y; }

.orbit__caption {
  position: relative; z-index: 1; width: min(100%, 31rem); min-height: 11rem; margin: -1.25rem auto 0;
  padding: 1.1rem 1.35rem 1.4rem; border-radius: 18px; overflow: hidden;
  background: rgba(13, 13, 15, 0.78); border: 1px solid var(--line-2);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.5);
}
.orbit__meta {
  display: flex; justify-content: space-between; align-items: center; gap: 1rem; margin-bottom: 1rem;
  font-family: var(--mono); font-size: 0.64rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-faint);
}
.orbit__groups { display: flex; align-items: center; gap: 0.4rem; }
.orbit__groups b {
  font-weight: 400; padding: 0.28rem 0.6rem; border-radius: 999px; border: 1px solid var(--line); color: var(--ink-dim);
  transition: color 0.4s, border-color 0.4s, background-color 0.4s;
}
.orbit__groups b.is-on { color: var(--ember-2); border-color: rgba(255, 90, 31, 0.6); background: rgba(255, 90, 31, 0.1); }
.orbit__groups i { font-style: normal; color: var(--ink-faint); }
.orbit__key { font-size: clamp(1.5rem, 2.3vw, 2rem); font-weight: 800; font-stretch: 84%; letter-spacing: -0.02em; line-height: 1; }
.orbit__text { margin-top: 0.55rem; font-size: 1.02rem; line-height: 1.4; }
.orbit__tech { margin-top: 0.55rem; font-family: var(--mono); font-size: 0.72rem; line-height: 1.55; color: var(--ink-dim); }
.orbit__timer { position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--line); }
.orbit__timer i { display: block; height: 100%; background: var(--ember); transform: scaleX(0); transform-origin: left; }
.orbit__caption.is-swap .orbit__key,
.orbit__caption.is-swap .orbit__text,
.orbit__caption.is-swap .orbit__tech { animation: capIn 0.6s var(--ease) both; }
.orbit__caption.is-swap .orbit__text { animation-delay: 0.06s; }
.orbit__caption.is-swap .orbit__tech { animation-delay: 0.12s; }
@keyframes capIn { from { opacity: 0; transform: translateY(10px); } }

/* ---------- Evals ---------- */
.evals { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(2.5rem, 6vw, 6rem); align-items: center; }
.evals__copy > p:not(.label):not(.plain) { max-width: 34rem; margin-top: 1.5rem; color: var(--ink-dim); }
.steps { margin-top: 2.5rem; border-top: 1px solid var(--line); }
.step { display: grid; grid-template-columns: 3rem 1fr; gap: 1rem; padding: 1.15rem 0; border-bottom: 1px solid var(--line); transition: color 0.4s; }
.step__n { font-family: var(--mono); font-size: 0.75rem; letter-spacing: 0.1em; color: var(--ink-faint); padding-top: 0.3rem; transition: color 0.4s; }
.step h3 { font-size: 1.15rem; font-weight: 700; font-stretch: 92%; letter-spacing: -0.01em; }
.step p { margin-top: 0.25rem; font-size: 0.92rem; color: var(--ink-dim); max-width: 32rem; }
.step.is-active .step__n, .step.is-done .step__n { color: var(--ember); }
.step.is-active h3 { color: var(--ember-2); }

.term {
  border-radius: 18px; border: 1px solid var(--line-2); overflow: hidden;
  background: linear-gradient(180deg, #111113, #0a0a0b);
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 90, 31, 0.06), 0 0 80px rgba(255, 90, 31, 0.08);
}
.term__bar { display: flex; align-items: center; gap: 0.45rem; padding: 0.85rem 1rem; border-bottom: 1px solid var(--line); }
.term__bar i { width: 10px; height: 10px; border-radius: 50%; background: var(--ink-faint); opacity: 0.6; }
.term__bar i:first-child { background: var(--ember); opacity: 1; }
.term__bar span { margin-left: 0.6rem; font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.08em; color: var(--ink-faint); }
.term__lines {
  padding: 1.4rem 1.4rem 1.8rem; min-height: 19.5rem; display: grid; align-content: start; gap: 0.45rem;
  font-family: var(--mono); font-size: clamp(0.72rem, 1.05vw, 0.9rem); line-height: 1.55; white-space: pre-wrap; word-break: break-word;
}
.term__lines li { color: var(--ink-dim); }
.term__lines li::before { content: "→ "; color: var(--ink-faint); }
.term__lines .cmd { color: var(--ink); }
.term__lines .cmd::before { content: "$ "; color: var(--ember); }
.term__lines .ok { color: var(--ok); padding-left: 1.2rem; }
.term__lines .bad { color: var(--bad); padding-left: 1.2rem; }
.term__lines .ok::before, .term__lines .bad::before { content: none; }
.term__lines li.is-typing::after { content: "▍"; color: var(--ember); animation: blink 0.9s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }

/* ---------- Agentic security ---------- */
.secure { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(2.5rem, 6vw, 6rem); align-items: center; }
.secure__list { margin-top: 2.25rem; border-top: 1px solid var(--line); }
.secure__list li { display: grid; grid-template-columns: 3rem 1fr; gap: 1rem; padding: 1.15rem 0; border-bottom: 1px solid var(--line); }
.secure__n { font-family: var(--mono); font-size: 0.75rem; letter-spacing: 0.1em; color: var(--ember); padding-top: 0.3rem; }
.secure__list h3 { font-size: 1.15rem; font-weight: 700; font-stretch: 92%; letter-spacing: -0.01em; }
.secure__plain { margin-top: 0.3rem; font-size: 1rem; line-height: 1.45; }
.secure__tech { margin-top: 0.35rem; font-family: var(--mono); font-size: 0.72rem; line-height: 1.55; color: var(--ink-dim); max-width: 36rem; }

.shield {
  position: relative; border-radius: 18px; border: 1px solid var(--line-2); overflow: hidden;
  background: linear-gradient(180deg, #111113, #0a0a0b);
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.6), 0 0 80px rgba(255, 90, 31, 0.07);
  transition: box-shadow 0.8s var(--ease), border-color 0.8s var(--ease);
}
.shield.is-hardened { border-color: rgba(123, 224, 164, 0.35); box-shadow: 0 40px 120px rgba(0, 0, 0, 0.6), 0 0 90px rgba(123, 224, 164, 0.09); }
.shield__bar { display: flex; align-items: center; gap: 0.45rem; padding: 0.85rem 1rem; border-bottom: 1px solid var(--line); }
.shield__bar i { width: 10px; height: 10px; border-radius: 50%; background: var(--ink-faint); opacity: 0.6; }
.shield__bar i:first-child { background: var(--ember); opacity: 1; }
.shield__file { margin-left: 0.6rem; font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.08em; color: var(--ink-faint); }
.shield__file b { font-weight: 400; }

.shield__body { position: relative; overflow: hidden; padding: 1.4rem 1.4rem 1.6rem; }
.shield__code { font-family: var(--mono); font-size: clamp(0.7rem, 1vw, 0.88rem); line-height: 1.75; color: var(--ink-dim); }
.shield__code .ln { display: block; min-height: 1.75em; white-space: pre; }
.shield__code i { font-style: normal; }
.shield__code .kw { color: var(--ember-2); }
.shield__code .fn { color: var(--ink); }
.shield__code .nu { color: var(--ok); }
.shield__code .is-h { color: rgba(255, 90, 31, 0.55); }
.shield__code .is-h:nth-child(3n) { color: rgba(243, 238, 230, 0.26); }
.shield__code .is-h:nth-child(5n) { color: rgba(123, 224, 164, 0.4); }

/* the agent's read head, sweeping the release */
.shield__scan {
  position: absolute; left: 0; right: 0; top: -4rem; height: 4rem; pointer-events: none;
  background: linear-gradient(180deg, transparent, rgba(243, 238, 230, 0.06) 70%, rgba(243, 238, 230, 0.5));
  animation: agentScan 3.4s cubic-bezier(0.45, 0, 0.55, 1) infinite;
}
.shield.is-hardened .shield__scan { background: linear-gradient(180deg, transparent, rgba(255, 122, 107, 0.07) 70%, rgba(255, 122, 107, 0.55)); }
@keyframes agentScan { to { top: 100%; } }

.shield__status {
  display: grid; gap: 0.45rem; padding: 1rem 1.4rem 1.1rem; border-top: 1px solid var(--line);
  font-family: var(--mono); font-size: 0.75rem; color: var(--ink-dim);
}
.shield__status p { display: grid; grid-template-columns: 4.4rem minmax(0, 1fr); align-items: center; }
.shield__k { color: var(--ink-faint); }
.shield__status b { font-weight: 500; }
.shield .is-bad { color: var(--bad); }
.shield .is-ok { color: var(--ok); }
.shield .shield__after { display: none; }
.shield.is-hardened .shield__after { display: inline; }
.shield.is-hardened .shield__before { display: none; }
.shield__meter i { display: block; height: 4px; border-radius: 4px; background: var(--line); overflow: hidden; }
.shield__meter b { display: block; height: 100%; width: calc(var(--p, 0) * 100%); background: linear-gradient(90deg, var(--ember), var(--ok)); }
@media (min-width: 901px) {
  /* the card stays in view while the list scrolls past, hardening as it goes */
  .secure { align-items: start; }
  .shield { position: sticky; top: max(6rem, calc(50vh - 16rem)); }
}
.shield figcaption {
  padding: 0 1.4rem 1.1rem; font-family: var(--mono); font-size: 0.64rem; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--ink-faint);
}

/* ---------- Expertise ---------- */
.skills__head { margin-bottom: clamp(2.5rem, 6vh, 4rem); }
.skills__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.skill {
  position: relative; overflow: hidden; isolation: isolate; min-height: 16rem;
  padding: 1.75rem; border-radius: 20px; background: var(--bg-2);
  display: flex; flex-direction: column;
}
/* cursor-tracking glow: fill + border */
.skill::before, .skill::after { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity 0.5s; }
.skill::before { z-index: -1; background: radial-gradient(26rem circle at var(--mx, 50%) var(--my, 50%), rgba(255, 90, 31, 0.14), transparent 45%); }
.skill::after {
  padding: 1px; background: radial-gradient(18rem circle at var(--mx, 50%) var(--my, 50%), rgba(255, 122, 61, 0.95), transparent 45%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
}
.skills__grid:hover .skill::before, .skills__grid:hover .skill::after { opacity: 1; }
.skill { box-shadow: inset 0 0 0 1px var(--line); }
.skill__n { font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.12em; color: var(--ember); }
.skill h3 { margin-top: auto; padding-top: 2.5rem; font-size: clamp(1.4rem, 2vw, 1.85rem); font-weight: 800; font-stretch: 84%; letter-spacing: -0.02em; line-height: 1.05; }
.skill p { margin-top: 0.55rem; font-size: 0.88rem; line-height: 1.5; color: var(--ink-dim); }
.skill p.skill__plain { margin-top: 0.7rem; font-size: 1.02rem; line-height: 1.35; color: var(--ink); }

/* ---------- Languages ---------- */
.langs__head { margin-bottom: clamp(2.5rem, 6vh, 4rem); }
.langs__intro { max-width: 38rem; margin-top: 1.75rem; color: var(--ink-dim); font-size: 1.1rem; }
.rows { border-top: 1px solid var(--line); }
.row {
  position: relative; display: grid; grid-template-columns: 7rem minmax(0, 1fr) minmax(0, 1.3fr); gap: 2rem; align-items: baseline;
  padding: 1.6rem 1rem; border-bottom: 1px solid var(--line); isolation: isolate;
  transition: color 0.45s var(--ease), padding 0.6s var(--ease);
}
.row::before { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--ember); transform: scaleY(0); transform-origin: bottom; transition: transform 0.55s var(--ease); }
.row:hover { color: #0a0a0a; padding-left: 2rem; }
.row:hover::before { transform: scaleY(1); }
.row__ext { font-family: var(--mono); font-size: 1.05rem; letter-spacing: 0.02em; color: var(--ember); transition: color 0.45s; }
.row__title h3 { font-size: clamp(1.3rem, 2.2vw, 2rem); font-weight: 800; font-stretch: 84%; letter-spacing: -0.025em; line-height: 1.05; }
.row__title span { display: block; margin-top: 0.3rem; font-family: var(--serif); font-style: italic; font-size: 1.15rem; color: var(--ember-2); transition: color 0.45s; }
.row__detail { font-size: 0.95rem; color: var(--ink-dim); transition: color 0.45s; }
.row:hover .row__ext, .row:hover .row__title span, .row:hover .row__detail { color: #0a0a0a; }

/* ---------- Contact ---------- */
.contact { overflow: hidden; isolation: isolate; padding-bottom: clamp(4rem, 10vh, 7rem); }
.contact::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 9rem; z-index: -1; background: linear-gradient(transparent, var(--bg)); }
.contact__glow {
  position: absolute; left: 50%; bottom: -55vmax; width: 110vmax; height: 110vmax; margin-left: -55vmax; border-radius: 50%; z-index: -1;
  background: radial-gradient(closest-side, rgba(255, 90, 31, 0.3), rgba(255, 90, 31, 0.06) 55%, transparent 70%);
}
.contact__title { font-size: clamp(2.9rem, 9.4vw, 10.5rem); line-height: 0.92; letter-spacing: -0.04em; font-weight: 800; font-stretch: 80%; max-width: 12ch; }
.contact__row { display: flex; justify-content: space-between; align-items: center; gap: 2rem; margin-top: clamp(2.5rem, 6vh, 4rem); }
.contact__lede { max-width: 28rem; font-size: 1.15rem; color: var(--ink-dim); }
.orb {
  flex: none; display: grid; place-items: center; width: clamp(9rem, 15vw, 13rem); aspect-ratio: 1; border-radius: 50%;
  background: var(--ember); color: #0a0a0a; font-weight: 800; font-stretch: 90%; font-size: 1.15rem; letter-spacing: -0.01em;
  box-shadow: 0 0 80px var(--ember-glow); transition: background-color 0.45s var(--ease), box-shadow 0.45s;
}
.orb:hover { background: var(--ink); box-shadow: 0 0 100px rgba(243, 238, 230, 0.25); }
.orb > span { display: inline-block; pointer-events: none; }

.contact__links { margin-top: clamp(3rem, 8vh, 5rem); border-top: 1px solid var(--line-2); }
.link {
  display: grid; grid-template-columns: 8rem 1fr auto; gap: 1.5rem; align-items: baseline; width: 100%; text-align: left;
  padding: 1.4rem 0.25rem; border-bottom: 1px solid var(--line); transition: padding 0.6s var(--ease), color 0.4s;
}
.link:hover { padding-left: 1.25rem; padding-right: 1.25rem; color: var(--ember-2); }
.link__k { font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-faint); }
.link__v { font-size: clamp(1.15rem, 2.4vw, 2rem); font-weight: 600; font-stretch: 90%; letter-spacing: -0.02em; overflow-wrap: anywhere; }
.link__a { font-family: var(--mono); font-size: 0.75rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-dim); }

.footer {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem; padding: 1.75rem var(--pad) 2.25rem;
  font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-dim);
}

/* ---------- Say hello dialog ---------- */
.hello-open { overflow: hidden; }
.hello {
  width: min(40rem, calc(100vw - 2rem)); max-height: calc(100dvh - 2rem); margin: auto; padding: 0; overflow: auto;
  border: 1px solid var(--line-2); border-radius: 22px; color: var(--ink);
  background: linear-gradient(180deg, #121214, #0b0b0c);
  box-shadow: 0 40px 140px rgba(0, 0, 0, 0.7), 0 0 100px rgba(255, 90, 31, 0.12);
}
.hello[open] { animation: helloIn 0.55s var(--ease) both; }
.hello::backdrop { background: rgba(5, 5, 6, 0.72); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
@keyframes helloIn { from { opacity: 0; transform: translateY(24px) scale(0.98); } }
.hello__form, .hello__done { padding: clamp(1.5rem, 4vw, 2.5rem); }
.hello__head { position: relative; padding-right: 3rem; }
.hello__eyebrow {
  display: flex; align-items: center; gap: 0.7rem;
  font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-dim);
}
.hello__title { margin-top: 0.9rem; font-size: clamp(2rem, 4.5vw, 3rem); font-weight: 800; font-stretch: 84%; line-height: 0.98; letter-spacing: -0.03em; }
.hello__title em { font-family: var(--serif); font-style: italic; font-weight: 400; font-stretch: 100%; letter-spacing: -0.01em; color: var(--ember); }
.hello__close {
  position: absolute; top: -0.25rem; right: -0.25rem; width: 2.5rem; height: 2.5rem; border-radius: 50%;
  border: 1px solid var(--line-2); font-size: 1.3rem; line-height: 1; color: var(--ink-dim);
  transition: color 0.3s, border-color 0.3s, transform 0.5s var(--ease);
}
.hello__close:hover { color: var(--ink); border-color: var(--ink); transform: rotate(90deg); }

.hello__topics { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 1.75rem 0 0; padding: 0; border: 0; }
.hello__topics legend {
  width: 100%; margin-bottom: 0.7rem; padding: 0;
  font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-faint);
}
.hello__topics label { position: relative; }
.hello__topics input { position: absolute; opacity: 0; pointer-events: none; }
.hello__topics span {
  display: inline-block; padding: 0.55rem 0.95rem; border-radius: 999px; border: 1px solid var(--line-2);
  font-size: 0.9rem; color: var(--ink-dim); transition: color 0.3s, border-color 0.3s, background-color 0.3s;
}
.hello__topics label:hover span { color: var(--ink); border-color: var(--ink-dim); }
.hello__topics input:checked + span { color: #0a0a0a; background: var(--ember); border-color: var(--ember); }
.hello__topics input:focus-visible + span { outline: 2px solid var(--ember); outline-offset: 3px; }

.hello__row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 1.5rem; }
.field { position: relative; display: block; margin-top: 1rem; }
.hello__row .field { margin-top: 0; }
.field > span {
  display: block; margin-bottom: 0.45rem;
  font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-faint);
  transition: color 0.3s;
}
.field input, .field textarea {
  width: 100%; padding: 0.85rem 1rem; border-radius: 12px; border: 1px solid var(--line-2);
  background: rgba(255, 255, 255, 0.03); color: var(--ink); font: inherit; font-size: 1rem;
  transition: border-color 0.3s, background-color 0.3s, box-shadow 0.3s;
}
.field textarea { resize: vertical; min-height: 8.5rem; padding-bottom: 1.8rem; line-height: 1.5; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--ember); background: rgba(255, 90, 31, 0.05); box-shadow: 0 0 0 4px rgba(255, 90, 31, 0.12); }
.field:focus-within > span { color: var(--ember); }
.field.is-invalid input, .field.is-invalid textarea { border-color: var(--bad); }
.field__count { position: absolute; right: 0.85rem; bottom: 0.65rem; font-family: var(--mono); font-size: 0.64rem; color: var(--ink-faint); pointer-events: none; }
.hello__trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.hello__foot { display: flex; justify-content: space-between; align-items: center; gap: 1.25rem; margin-top: 1.5rem; }
.hello__note { max-width: 22rem; font-size: 0.88rem; color: var(--ink-dim); }
.hello__note.is-error { color: var(--bad); }
.hello__note a { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.hello__send { flex: none; }
.hello__send:disabled { opacity: 0.65; }
.is-sending .hello__send span::after {
  content: ""; display: inline-block; width: 0.8em; height: 0.8em; margin-left: 0.6em; vertical-align: -0.1em;
  border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: helloSpin 0.8s linear infinite;
}
@keyframes helloSpin { to { transform: rotate(360deg); } }

.hello__check { width: 3.25rem; height: 3.25rem; }
.hello__done p { margin-top: 1rem; font-size: 1.05rem; color: var(--ink-dim); }
.hello__done p span { color: var(--ink); }
.hello__done .btn { margin-top: 1.75rem; }
.hello__done p.hello__later { margin-top: 0.6rem; font-size: 0.92rem; }
.hello__later a { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }

/* the custom cursor sits under the dialog's top layer, so use the native one in here */
.has-cursor .hello, .has-cursor .hello * { cursor: auto; }
.has-cursor .hello button, .has-cursor .hello label { cursor: pointer; }
.has-cursor .hello input, .has-cursor .hello textarea { cursor: text; }
.hello-open .cursor { opacity: 0 !important; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .skills__grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 900px) {
  .nav__links, .nav__time { display: none; }
  .nav .btn { margin-left: auto; }
  .hero { padding-bottom: 9rem; }
  .hero__meta { gap: 1.5rem; }
  .hero__scroll { display: none; }
  .hero__canvas { -webkit-mask-image: none; mask-image: none; opacity: 0.7; }
  .bridge { column-gap: 1rem; }
  .work__head { flex-direction: column; align-items: flex-start; }
  .aiml, .evals, .secure { grid-template-columns: 1fr; }
  .proof__row { grid-template-columns: 2.25rem minmax(0, 1fr); padding: 1.6rem 0; }
  .proof__check { width: 2.1rem; height: 2.1rem; }
  .proof__ev { grid-column: 2; }
  .aiml .orbit { width: min(100%, 32rem); margin-top: 1rem; }
  .orbit__caption { margin-top: -0.5rem; }
  .orbit__groups b { padding: 0.24rem 0.45rem; }
  .row { grid-template-columns: 1fr; gap: 0.6rem; padding: 1.4rem 0.5rem; }
  .row:hover { padding-left: 1rem; }
  .contact__row { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 620px) {
  .skills__grid { grid-template-columns: 1fr; }
  .skill { min-height: 0; }
  .link { grid-template-columns: 1fr auto; }
  .link__k { grid-column: 1 / -1; }
  .hero__meta { flex-direction: column; align-items: flex-start; gap: 0.75rem; }
  .hero__behind { display: none; }
  .hero__eyebrow { font-size: 0.66rem; letter-spacing: 0.1em; }
  .shield__body { padding: 1.1rem 1rem 1.3rem; }
  .shield__code { font-size: 0.62rem; }
  .shield__status { padding: 0.9rem 1rem 1rem; font-size: 0.68rem; }
  .shield__status p { grid-template-columns: 3.6rem minmax(0, 1fr); }
  .shield figcaption { padding: 0 1rem 1rem; }
  .hello { max-height: calc(100dvh - 1rem); overscroll-behavior: contain; }
  .hello__form { padding: 1.25rem 1.2rem 1.4rem; }
  .hello__title { font-size: 1.85rem; }
  .hello__topics { margin-top: 1.25rem; }
  .hello__topics span { padding: 0.45rem 0.8rem; font-size: 0.85rem; }
  .hello__row { grid-template-columns: 1fr; gap: 0.75rem; margin-top: 1.1rem; }
  .field { margin-top: 0.75rem; }
  .field input, .field textarea { padding: 0.75rem 0.9rem; }
  .field textarea { min-height: 6.5rem; }
  .hello__foot { flex-direction: column; align-items: stretch; gap: 0.9rem; margin-top: 1.1rem; }
  .hello__send { width: 100%; }
  .hero { padding-bottom: 11rem; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition-duration: 0.01ms !important; }
  .grain { display: none; }
  .roller { height: auto; }
  .roller__track > span:not(:first-child) { display: none; }
}
