/* =========================================================
   joshuabeverly.com
   Palette: bone / ink / signal orange / olive drab
   ========================================================= */

:root {
  --bg: #ECE8DF;
  --bg-alt: #E5E0D5;
  --surface: #F4F1EA;
  --ink: #161411;
  --ink-2: #3B372F;
  --muted: #6B6458;
  --line: #CDC6B8;
  --line-soft: #DAD4C8;
  --accent: #E4531B;
  --accent-ink: #B13D0D;
  --on-accent: #161411;
  --olive: #5A6336;
  --olive-soft: #8A9460;
  --term-bg: #171512;
  --term-bar: #201E1A;
  --term-ink: #E7E2D6;
  --term-dim: #8E877B;
  --term-line: #2E2B26;
  --grid: rgba(22, 20, 17, 0.055);
  --shadow: 0 1px 0 rgba(22, 20, 17, .04), 0 18px 40px -24px rgba(22, 20, 17, .35);

  --font: "Archivo", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Consolas, monospace;

  --gutter: clamp(16px, 4vw, 40px);
  --maxw: 1240px;
  --ease: cubic-bezier(.2, .7, .1, 1);
  --radius: 4px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #121110;
    --bg-alt: #171614;
    --surface: #1C1A17;
    --ink: #ECE7DC;
    --ink-2: #CBC5B8;
    --muted: #979084;
    --line: #34312B;
    --line-soft: #27251F;
    --accent: #FF6A2B;
    --accent-ink: #FF8148;
    --on-accent: #1A0D05;
    --olive: #A9B472;
    --olive-soft: #7D8752;
    --term-bg: #0C0B0A;
    --term-bar: #161512;
    --term-line: #2A2722;
    --grid: rgba(236, 231, 220, 0.04);
    --shadow: 0 1px 0 rgba(0, 0, 0, .3), 0 18px 40px -20px rgba(0, 0, 0, .7);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #121110;
  --bg-alt: #171614;
  --surface: #1C1A17;
  --ink: #ECE7DC;
  --ink-2: #CBC5B8;
  --muted: #979084;
  --line: #34312B;
  --line-soft: #27251F;
  --accent: #FF6A2B;
  --accent-ink: #FF8148;
  --on-accent: #1A0D05;
  --olive: #A9B472;
  --olive-soft: #7D8752;
  --term-bg: #0C0B0A;
  --term-bar: #161512;
  --term-line: #2A2722;
  --grid: rgba(236, 231, 220, 0.04);
  --shadow: 0 1px 0 rgba(0, 0, 0, .3), 0 18px 40px -20px rgba(0, 0, 0, .7);
  color-scheme: dark;
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 84px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  font-stretch: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
  transition: background-color .35s ease, color .35s ease;
}
img, svg { display: block; max-width: 100%; }
h1, h2, h3, p, ul, ol, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
input { font: inherit; color: inherit; }
::selection { background: var(--accent); color: var(--on-accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 2px; }

.wrap { width: min(var(--maxw), 100% - 2 * var(--gutter)); margin-inline: auto; }

.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; }

.skip {
  position: absolute; left: var(--gutter); top: -60px; z-index: 100;
  background: var(--ink); color: var(--bg); padding: 10px 14px; font-family: var(--mono); font-size: 13px;
}
.skip:focus { top: 12px; }

/* ---------- progress ---------- */
.progress { position: fixed; inset: 0 0 auto 0; height: 2px; z-index: 60; pointer-events: none; }
.progress span { display: block; height: 100%; background: var(--accent); transform-origin: 0 50%; transform: scaleX(0); }

/* ---------- buttons ---------- */
.btn {
  --h: 48px;
  display: inline-flex; align-items: center; gap: 10px;
  height: var(--h); padding: 0 20px;
  font-family: var(--mono); font-size: 13px; font-weight: 500; letter-spacing: .06em; text-transform: uppercase;
  border: 1px solid var(--ink); border-radius: var(--radius);
  transition: background-color .25s var(--ease), color .25s var(--ease), border-color .25s var(--ease), transform .25s var(--ease);
  white-space: nowrap;
}
.btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; transition: transform .3s var(--ease); }
.btn:hover svg { transform: translateX(3px); }
.btn[download]:hover svg { transform: translateY(2px); }
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.btn--primary:hover { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.btn--ghost:hover { background: var(--ink); color: var(--bg); }
.btn--ink { background: var(--ink); color: var(--bg); }
.btn--ink:hover { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.btn--sm { --h: 38px; padding: 0 14px; font-size: 12px; gap: 8px; }
.btn--sm svg { width: 16px; height: 16px; }

.icon-btn {
  width: 38px; height: 38px; display: grid; place-items: center;
  border: 1px solid var(--line); border-radius: var(--radius);
  transition: border-color .2s, background-color .2s;
}
.icon-btn:hover { border-color: var(--ink); }
.icon-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; }
.icon-btn .i-moon { display: none; }
:root[data-theme="dark"] .icon-btn .i-sun { display: none; }
:root[data-theme="dark"] .icon-btn .i-moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .icon-btn .i-sun { display: none; }
  :root:not([data-theme="light"]) .icon-btn .i-moon { display: block; }
}

/* ---------- nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(140%) blur(10px);
  -webkit-backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s, background-color .35s;
}
.nav.is-scrolled { border-bottom-color: var(--line); }
.nav__inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; height: 68px; }
.brand { display: flex; align-items: center; gap: 12px; }
.brand__mark {
  display: grid; place-items: center; width: 34px; height: 34px;
  background: var(--ink); color: var(--bg); border-radius: var(--radius);
  font-weight: 800; font-stretch: 125%; font-size: 13px; letter-spacing: .02em;
  transition: background-color .25s, color .25s, transform .4s var(--ease);
}
.brand:hover .brand__mark { background: var(--accent); color: var(--on-accent); transform: rotate(-6deg); }
.brand__name { font-family: var(--mono); font-size: 13px; font-weight: 500; letter-spacing: .04em; text-transform: uppercase; }
.nav__links { display: flex; gap: 4px; }
.nav__links a {
  position: relative; padding: 8px 12px;
  font-family: var(--mono); font-size: 12.5px; letter-spacing: .05em; text-transform: uppercase; color: var(--muted);
  transition: color .2s;
}
.nav__links a::after {
  content: ""; position: absolute; left: 12px; right: 12px; bottom: 3px; height: 1.5px;
  background: var(--accent); transform: scaleX(0); transform-origin: left; transition: transform .35s var(--ease);
}
.nav__links a:hover, .nav__links a.is-active { color: var(--ink); }
.nav__links a.is-active::after { transform: scaleX(1); }
.nav__actions { display: flex; align-items: center; gap: 10px; }
@media (max-width: 900px) { .nav__links { display: none; } }
@media (max-width: 420px) { .brand__name { display: none; } }

/* ---------- hero ---------- */
.hero { position: relative; padding-top: clamp(28px, 5vw, 56px); overflow: hidden; }
.hero__grid-bg {
  position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 56px 56px;
  background-position: -1px -1px;
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, #000 30%, transparent 75%);
          mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, #000 30%, transparent 75%);
}
.hero .wrap { position: relative; }
.hero__eyebrow {
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  font-family: var(--mono); font-size: 12.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted);
  padding-bottom: 14px; border-bottom: 1px solid var(--line);
}
.hero__eyebrow p { display: flex; align-items: center; gap: 10px; }
.hero__eyebrow p:first-child { color: var(--ink); }
.live-dot { flex: none; }
@media (max-width: 560px) {
  .hero__eyebrow { font-size: 11px; flex-direction: column; gap: 6px; }
  .hero__eyebrow p:first-child { align-items: flex-start; }
  .hero__eyebrow p:first-child .live-dot { margin-top: 5px; }
}
.sep { color: var(--line); }
.live-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--olive); box-shadow: 0 0 0 0 var(--olive); animation: pulse 2.4s ease-out infinite; }
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--olive) 55%, transparent); }
  70%, 100% { box-shadow: 0 0 0 9px transparent; }
}

.name {
  margin: clamp(18px, 3vw, 36px) 0 clamp(26px, 4vw, 48px);
  font-weight: 800; font-stretch: 100%;
  font-size: clamp(2.6rem, 15.2vw, 13.6rem);
  line-height: .84; letter-spacing: -.012em; text-transform: uppercase;
  user-select: none;
  cursor: default;
}
.name__line { display: block; white-space: nowrap; }
.name__line:last-child { margin-left: clamp(0px, 7vw, 120px); }
.name .ch {
  display: inline-block;
  font-variation-settings: "wdth" 100, "wght" 800;
  will-change: font-variation-settings;
  animation: chIn 1s var(--ease) backwards;
  animation-delay: calc(var(--i) * 45ms + 80ms);
}
@keyframes chIn {
  from { opacity: 0; transform: translateY(.32em); font-variation-settings: "wdth" 62, "wght" 300; }
}
.name__cursor {
  display: inline-block; width: .16em; height: .16em; margin-left: .06em;
  background: var(--accent); vertical-align: baseline;
  animation: blink 1.1s steps(1) infinite, chIn .8s var(--ease) .75s backwards;
}
@keyframes blink { 50% { opacity: 0; } }

.hero__row {
  display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(28px, 5vw, 72px);
  align-items: start; padding-bottom: clamp(48px, 7vw, 96px);
}
.lede { font-size: clamp(1.15rem, 1.6vw, 1.4rem); line-height: 1.5; color: var(--ink-2); max-width: 34ch; text-wrap: pretty; }
.lede strong { color: var(--ink); font-weight: 650; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.hero__meta { display: grid; gap: 0; margin-top: 40px; border-top: 1px solid var(--line); }
.hero__meta div { display: grid; grid-template-columns: 96px 1fr; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.hero__meta dt { font-family: var(--mono); font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); padding-top: 2px; }

@media (max-width: 960px) {
  .hero__row { grid-template-columns: minmax(0, 1fr); }
  .lede { max-width: 44ch; }
}
@media (max-width: 480px) {
  .btn { padding: 0 14px; letter-spacing: .03em; font-size: 12.5px; gap: 8px; }
  .hero__cta { gap: 10px; }
  .hero__cta .btn { flex: 1 1 auto; justify-content: center; }
  .hero__meta div { grid-template-columns: 80px 1fr; }
}

/* ---------- terminal ---------- */
.term {
  background: var(--term-bg); color: var(--term-ink);
  border: 1px solid var(--term-line); border-radius: 6px;
  font-family: var(--mono); font-size: 13.5px; line-height: 1.6;
  box-shadow: var(--shadow);
  overflow: hidden;
}
.term__bar {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  padding: 10px 14px; background: var(--term-bar); border-bottom: 1px solid var(--term-line);
  font-size: 11.5px; letter-spacing: .05em; color: var(--term-dim);
}
.term__status { display: inline-flex; align-items: center; gap: 8px; text-transform: uppercase; }
.term__status i { width: 6px; height: 6px; border-radius: 50%; background: var(--olive-soft); }
:root .term__status i { background: #A9B472; }
.term__body { height: 368px; overflow-y: auto; padding: 14px 16px 10px; cursor: text; scrollbar-width: thin; scrollbar-color: #3a362f transparent; overscroll-behavior: contain; }
.term__out { display: grid; gap: 2px; }
.term__line { display: flex; align-items: baseline; gap: 10px; }
.term__prompt { flex: none; cursor: text; }
.term__input {
  flex: 1; min-width: 0; background: transparent; border: 0; outline: 0; padding: 0;
  font-family: var(--mono); font-size: inherit; color: var(--term-ink); caret-color: #FF6A2B;
}
@media (pointer: coarse) { .term__input { font-size: 16px; } }

.t-u { color: #FF7A3D; }
.t-h { color: #B9C383; }
.t-p { color: #E7E2D6; }
.t-dim { color: var(--term-dim); }
.t-cmd { color: var(--term-ink); }
.t-err { color: #FF7A3D; }
.t-ok { color: #B9C383; }
.t-acc { color: #FF7A3D; }
.t-k { color: var(--term-dim); display: inline-block; min-width: 9ch; }
.t-block { white-space: pre-wrap; word-break: break-word; }
.t-block + .t-echo { margin-top: 10px; }
.t-echo { white-space: normal; }
.t-space { height: 6px; }
.t-link {
  color: #FF7A3D; text-decoration: underline; text-decoration-color: rgba(255, 122, 61, .4); text-underline-offset: 3px;
  font-family: inherit; font-size: inherit; line-height: inherit;
}
.t-link:hover { text-decoration-color: currentColor; }
.t-row { display: grid; grid-template-columns: 11ch 1fr; gap: 12px; }
.t-row > :first-child { color: var(--term-dim); }
.t-row em { font-style: normal; color: var(--term-dim); }
.t-cols { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 0 16px; }

.nf { display: flex; gap: 22px; align-items: flex-start; padding: 4px 0 2px; }
.nf__art { margin: 0; color: #FF6A2B; line-height: 1.12; font-size: 12px; font-family: inherit; flex: none; padding-top: 4px; }
.nf__info { display: grid; gap: 0; min-width: 0; }
.nf__info b { color: #FF7A3D; font-weight: 600; }
.nf__sw { display: flex; gap: 0; margin-top: 8px; }
.nf__sw i { width: 22px; height: 12px; }
@media (max-width: 560px) {
  .term { font-size: 12.5px; }
  .term__body { height: 340px; padding: 12px 12px 8px; }
  .nf__art { display: none; }
  .t-row { grid-template-columns: 1fr; gap: 0; }
  .t-row + .t-row { margin-top: 4px; }
}

.term__chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.term__chips button {
  font-family: var(--mono); font-size: 12px; padding: 6px 11px;
  border: 1px solid var(--line); border-radius: 999px; color: var(--ink-2);
  transition: border-color .2s, color .2s, background-color .2s;
}
.term__chips button::before { content: "$ "; color: var(--accent-ink); }
.term__chips button:hover { border-color: var(--ink); color: var(--ink); }

/* ---------- stats ---------- */
.stats { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); position: relative; background: var(--bg); }
.stats__grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.stat { padding: 28px 24px 30px; border-left: 1px solid var(--line); }
.stat:first-child { border-left: 0; padding-left: 0; }
.stat__num { font-weight: 800; font-stretch: 125%; font-size: clamp(2.6rem, 4.6vw, 4rem); line-height: 1; letter-spacing: -.02em; }
.stat__num--text { font-stretch: 112%; }
.stat__label { margin-top: 12px; font-family: var(--mono); font-size: 12px; letter-spacing: .05em; text-transform: uppercase; line-height: 1.55; }
.stat__label span { color: var(--muted); text-transform: none; letter-spacing: .01em; }
@media (max-width: 860px) {
  .stats__grid { grid-template-columns: 1fr 1fr; }
  .stat { padding: 22px 18px; }
  .stat:nth-child(odd) { border-left: 0; padding-left: 0; }
  .stat:nth-child(n+3) { border-top: 1px solid var(--line); }
}

/* ---------- sections ---------- */
.section { padding-block: clamp(76px, 10vw, 140px); border-top: 1px solid var(--line); position: relative; }
.hero + .section { border-top: 0; }
.section--alt { background: var(--bg-alt); }
.sec-head {
  display: grid; grid-template-columns: auto 1fr; column-gap: 20px; row-gap: 18px; align-items: baseline;
  margin-bottom: clamp(40px, 6vw, 72px);
}
.sec-num { font-family: var(--mono); font-size: 13px; color: var(--accent-ink); letter-spacing: .06em; padding: 3px 8px; border: 1px solid currentColor; border-radius: 2px; align-self: center; }
.sec-title { font-weight: 800; font-stretch: 125%; text-transform: uppercase; font-size: clamp(2.2rem, 6.2vw, 5rem); line-height: .95; letter-spacing: -.015em; }
.sec-note { grid-column: 1 / -1; max-width: 58ch; color: var(--muted); font-size: 16px; }
@media (max-width: 560px) {
  .sec-head { grid-template-columns: 1fr; row-gap: 14px; }
  .sec-num { justify-self: start; }
  .sec-title { font-size: 9vw; }
}
@media (min-width: 900px) {
  .sec-head { grid-template-columns: auto auto 1fr; }
  .sec-note { grid-column: 3; justify-self: end; text-align: right; max-width: 42ch; align-self: end; }
}

/* ---------- profile ---------- */
.profile { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: clamp(32px, 6vw, 96px); }
.profile__statement {
  font-weight: 600; font-stretch: 92%; font-size: clamp(1.9rem, 3.8vw, 3.2rem); line-height: 1.08; letter-spacing: -.02em; text-wrap: balance;
}
.profile__body > p { color: var(--ink-2); font-size: 17px; text-wrap: pretty; }
.focus { margin-top: 36px; border-top: 1px solid var(--line); }
.focus li { display: grid; grid-template-columns: 40px 1fr; gap: 14px; padding: 20px 0; border-bottom: 1px solid var(--line); }
.focus__idx { font-family: var(--mono); font-size: 12px; color: var(--accent-ink); padding-top: 4px; }
.focus h3 { font-size: 18px; font-weight: 650; line-height: 1.3; }
.focus p { color: var(--muted); font-size: 15.5px; margin-top: 4px; }
@media (max-width: 900px) { .profile { grid-template-columns: 1fr; } }

/* ---------- timeline ---------- */
.timeline { margin-bottom: 36px; }
.timeline__track {
  position: relative; height: 40px; border-radius: 3px;
  background: var(--line-soft);
  background-image: repeating-linear-gradient(90deg, transparent 0 calc(var(--yr, 7.5%) - 1px), color-mix(in srgb, var(--line) 80%, transparent) calc(var(--yr, 7.5%) - 1px) var(--yr, 7.5%));
}
.seg {
  position: absolute; top: 0; bottom: 0;
  background: var(--ink); border-radius: 2px;
  box-shadow: inset -2px 0 0 var(--bg-alt);
  transform-origin: left center;
  transition: background-color .25s, opacity .3s, transform .5s var(--ease);
}
.seg--contract { background: repeating-linear-gradient(135deg, var(--ink) 0 3px, transparent 3px 6px); }
.seg--military { background: var(--olive); }
.seg.is-hot, .seg:hover, .seg:focus-visible { background: var(--accent); z-index: 2; }
.seg.is-dim { opacity: .18; }
.seg.is-hit { background: var(--accent); }
.seg--now::after {
  content: ""; position: absolute; right: -4px; top: 50%; width: 8px; height: 8px; margin-top: -4px; border-radius: 50%;
  background: var(--accent); animation: pulseAcc 2s ease-out infinite;
}
@keyframes pulseAcc {
  0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 60%, transparent); }
  80%, 100% { box-shadow: 0 0 0 10px transparent; }
}
html.js .timeline:not(.is-in) .seg { transform: scaleX(0); }
.timeline.is-in .seg { transition-delay: calc(var(--k) * 60ms); }
.timeline.is-in .seg:hover { transition-delay: 0s; }

.timeline__tip {
  position: absolute; bottom: calc(100% + 10px); left: 0; transform: translateX(-50%);
  background: var(--ink); color: var(--bg); padding: 6px 10px; border-radius: 3px;
  font-family: var(--mono); font-size: 12px; white-space: nowrap; pointer-events: none;
  opacity: 0; transition: opacity .15s; z-index: 5;
}
.timeline__tip.is-on { opacity: 1; }
.timeline__tip::after { content: ""; position: absolute; top: 100%; left: 50%; margin-left: -5px; border: 5px solid transparent; border-top-color: var(--ink); }
.timeline__axis { position: relative; height: 22px; margin-top: 6px; font-family: var(--mono); font-size: 11px; color: var(--muted); }
.timeline__axis span { position: absolute; top: 0; transform: translateX(-50%); }
.timeline__axis span::before { content: ""; position: absolute; left: 50%; top: -6px; width: 1px; height: 4px; background: var(--line); }
@media (max-width: 640px) { .timeline__axis span:nth-child(even) { visibility: hidden; } }
.timeline__legend { display: flex; flex-wrap: wrap; gap: 18px; margin-top: 8px; font-family: var(--mono); font-size: 11.5px; color: var(--muted); letter-spacing: .04em; text-transform: uppercase; }
.timeline__legend li { display: flex; align-items: center; gap: 8px; }
.lg { width: 16px; height: 10px; border-radius: 1px; display: inline-block; }
.lg--full { background: var(--ink); }
.lg--contract { background: repeating-linear-gradient(135deg, var(--ink) 0 2px, transparent 2px 4px); outline: 1px solid var(--line); }
.lg--mil { background: var(--olive); }

/* ---------- filters ---------- */
.filters { display: grid; grid-template-columns: auto 1fr; gap: 12px 18px; align-items: center; padding: 18px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.filters__label { font-family: var(--mono); font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.filters__chips { display: flex; flex-wrap: wrap; gap: 8px; }
.filters__status { grid-column: 1 / -1; font-family: var(--mono); font-size: 12px; color: var(--muted); min-height: 1.4em; }
.filters__status:empty { display: none; }
@media (max-width: 640px) { .filters { grid-template-columns: 1fr; } }
.chip {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 12px; border: 1px solid var(--line); border-radius: 999px;
  font-size: 14px; font-weight: 500; color: var(--ink-2); background: transparent;
  transition: background-color .2s, color .2s, border-color .2s;
}
.chip:hover { border-color: var(--ink); color: var(--ink); }
.chip__n { font-family: var(--mono); font-size: 11px; color: var(--muted); transition: color .2s; }
.chip.is-active { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.chip.is-active .chip__n { color: var(--accent); }

/* ---------- roles ---------- */
.roles { counter-reset: role; }
.role { border-bottom: 1px solid var(--line); transition: opacity .35s var(--ease); }
.role.is-dim { opacity: .38; }
.role.is-dim:hover { opacity: .75; }
.role.is-flash .role__head { animation: flash 1.2s var(--ease); }
@keyframes flash { 0% { background: color-mix(in srgb, var(--accent) 22%, transparent); } 100% { background: transparent; } }
.role__head {
  width: 100%; text-align: left;
  display: grid; grid-template-columns: 190px minmax(0, 1fr) auto 28px; gap: 20px; align-items: center;
  padding: 22px 0;
  position: relative;
}
.role__head::before {
  content: ""; position: absolute; left: -16px; top: 22px; bottom: 22px; width: 3px; background: var(--accent);
  transform: scaleY(0); transition: transform .35s var(--ease);
}
.role.is-open .role__head::before, .role__head:hover::before { transform: scaleY(1); }
.role__dates { font-family: var(--mono); font-size: 12.5px; color: var(--muted); letter-spacing: .02em; }
.role__main { display: grid; gap: 2px; }
.role__title { font-size: clamp(1.15rem, 2vw, 1.5rem); font-weight: 650; line-height: 1.25; letter-spacing: -.01em; transition: color .2s; }
.role__head:hover .role__title { color: var(--accent-ink); }
.role__kind {
  font-style: normal; font-family: var(--mono); font-size: 10.5px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase;
  color: var(--muted); border: 1px solid var(--line); padding: 2px 6px; border-radius: 2px; vertical-align: 3px; margin-left: 6px; white-space: nowrap;
}
.role__org { font-size: 15.5px; color: var(--ink-2); }
.role__loc { color: var(--muted); }
.role__dur { font-family: var(--mono); font-size: 12px; color: var(--muted); }
.role__toggle { position: relative; width: 28px; height: 28px; border: 1px solid var(--line); border-radius: 50%; transition: border-color .2s, background-color .2s, transform .45s var(--ease); }
.role__toggle::before, .role__toggle::after { content: ""; position: absolute; left: 50%; top: 50%; width: 10px; height: 1.5px; margin: -.75px 0 0 -5px; background: currentColor; transition: transform .45s var(--ease); }
.role__toggle::after { transform: rotate(90deg); }
.role.is-open .role__toggle { transform: rotate(180deg); background: var(--ink); color: var(--bg); border-color: var(--ink); }
.role.is-open .role__toggle::after { transform: rotate(0deg); }
.role__head:hover .role__toggle { border-color: var(--ink); }

.role__body { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .5s var(--ease); }
.role.is-open .role__body { grid-template-rows: 1fr; }
.role__inner { overflow: hidden; min-height: 0; padding-left: 210px; }
.role__points { display: grid; gap: 10px; max-width: 76ch; padding-bottom: 4px; }
.role__points li { position: relative; padding-left: 22px; color: var(--ink-2); font-size: 16px; transition: color .3s, opacity .3s; }
.role__points li::before { content: ""; position: absolute; left: 0; top: .62em; width: 7px; height: 7px; background: var(--line); transition: background-color .3s, transform .3s var(--ease); }
.role.is-open .role__points li::before { background: var(--ink-2); }
.roles.is-filtering .role__points li { opacity: .5; }
.roles.is-filtering .role__points li.is-hit { opacity: 1; color: var(--ink); }
.roles.is-filtering .role__points li.is-hit::before { background: var(--accent); transform: rotate(45deg); }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 18px; padding-bottom: 28px; }
.tags li { font-family: var(--mono); font-size: 11.5px; padding: 3px 8px; border: 1px solid var(--line); border-radius: 2px; color: var(--muted); }

@media (max-width: 760px) {
  .role__head { grid-template-columns: minmax(0, 1fr) auto 28px; grid-template-areas: "dates dur toggle" "main main main"; gap: 8px 12px; padding: 20px 0; }
  .role__dates { grid-area: dates; }
  .role__dur { grid-area: dur; }
  .role__toggle { grid-area: toggle; }
  .role__main { grid-area: main; }
  .role__inner { padding-left: 0; }
  .role__head::before { left: calc(-1 * var(--gutter)); }
}

/* ---------- skills ---------- */
.skill-search {
  display: flex; align-items: center; gap: 12px;
  padding: 0 16px; height: 56px; margin-bottom: 28px;
  border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface);
  transition: border-color .2s, box-shadow .2s;
}
.skill-search:focus-within { border-color: var(--ink); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 25%, transparent); }
.skill-search__prompt { font-family: var(--mono); color: var(--accent-ink); font-weight: 600; }
.skill-search input { flex: 1; min-width: 0; height: 100%; border: 0; outline: 0; background: transparent; font-family: var(--mono); font-size: 15px; }
.skill-search input::placeholder { color: var(--muted); opacity: .85; }
.skill-search input::-webkit-search-cancel-button { filter: grayscale(1); }
.skill-search__status { font-family: var(--mono); font-size: 12px; color: var(--muted); white-space: nowrap; }
@media (max-width: 520px) { .skill-search__status { display: none; } .skill-search input { font-size: 16px; } }

.skill-groups { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.skill-group { background: var(--bg); padding: clamp(22px, 3vw, 34px); transition: opacity .3s; }
.skill-group.is-miss { opacity: .4; }
.skill-group header { display: flex; align-items: baseline; gap: 12px; margin-bottom: 20px; }
.skill-group__idx { font-family: var(--mono); font-size: 12px; color: var(--accent-ink); }
.skill-group h3 { font-size: 19px; font-weight: 650; line-height: 1.25; flex: 1; }
.skill-group__n { font-family: var(--mono); font-size: 12px; color: var(--muted); }
.skills { display: flex; flex-wrap: wrap; gap: 8px; }
.skills li {
  padding: 6px 11px; border: 1px solid var(--line); border-radius: 3px; font-size: 14.5px; color: var(--ink-2); background: var(--bg);
  transition: background-color .25s, color .25s, border-color .25s, opacity .25s, transform .25s var(--ease);
}
.skills li:hover { border-color: var(--ink); color: var(--ink); transform: translateY(-2px); }
.skills li.is-hit { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.skills li.is-miss { opacity: .32; }
@media (max-width: 820px) { .skill-groups { grid-template-columns: 1fr; } }

/* ---------- credentials ---------- */
.creds { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.cred {
  position: relative; display: flex; flex-direction: column;
  padding: 24px; min-height: 300px;
  background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden;
  transition: transform .4s var(--ease), border-color .3s, box-shadow .4s var(--ease);
}
.cred::before { content: ""; position: absolute; left: 0; top: 0; height: 3px; width: 100%; background: var(--accent); transform: scaleX(0); transform-origin: left; transition: transform .5s var(--ease); }
.cred:hover { transform: translateY(-4px); border-color: var(--ink); box-shadow: var(--shadow); }
.cred:hover::before { transform: scaleX(1); }
.cred__glyph {
  font-weight: 800; font-stretch: 125%; font-size: clamp(2.2rem, 3.4vw, 3rem); line-height: 1; letter-spacing: -.02em;
  color: transparent; -webkit-text-stroke: 1.2px var(--ink); margin-bottom: auto; padding-bottom: 28px;
  transition: color .35s;
}
.cred:hover .cred__glyph { color: var(--ink); }
.cred__issuer { font-family: var(--mono); font-size: 11.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.cred__name { font-size: 19px; font-weight: 650; line-height: 1.25; margin-top: 6px; }
.cred__desc { margin-top: 10px; color: var(--muted); font-size: 14.5px; line-height: 1.5; }
.cred__code { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 2px 10px; margin-top: 18px; padding-top: 14px; border-top: 1px dashed var(--line); }
.cred__label { grid-column: 1 / -1; font-family: var(--mono); font-size: 10.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.cred__code code { font-family: var(--mono); font-size: 13px; letter-spacing: .04em; overflow: hidden; text-overflow: ellipsis; }
.cred--edu { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.cred--edu .cred__glyph { -webkit-text-stroke-color: var(--bg); }
.cred--edu:hover .cred__glyph { color: var(--accent); -webkit-text-stroke-color: var(--accent); }
.cred--edu .cred__issuer, .cred--edu .cred__desc { color: color-mix(in srgb, var(--bg) 65%, var(--ink)); }
@media (max-width: 1080px) { .creds { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .creds { grid-template-columns: 1fr; } .cred { min-height: 0; } }

.copy {
  font-family: var(--mono); font-size: 11px; letter-spacing: .06em; text-transform: uppercase;
  padding: 5px 9px; border: 1px solid var(--line); border-radius: 3px; color: var(--ink-2);
  transition: border-color .2s, background-color .2s, color .2s;
}
.copy:hover { border-color: var(--ink); color: var(--ink); }
.copy.is-done { background: var(--olive); border-color: var(--olive); color: var(--bg); }
.copy--lg { padding: 8px 12px; font-size: 12px; }

/* ---------- contact ---------- */
.contact__grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(32px, 6vw, 96px); align-items: end; }
.contact__headline { font-weight: 800; font-stretch: 112%; font-size: clamp(2.5rem, 6vw, 5.4rem); line-height: .98; letter-spacing: -.025em; text-wrap: balance; }
.contact__headline em { font-style: normal; color: var(--accent-ink); }
.contact__side > p { color: var(--ink-2); max-width: 40ch; }
.contact__email { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-top: 22px; padding: 18px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.email-link {
  font-family: var(--mono); font-size: clamp(1rem, 1.8vw, 1.25rem); font-weight: 500;
  background: linear-gradient(var(--accent), var(--accent)) 0 100% / 0 2px no-repeat;
  transition: background-size .4s var(--ease); padding-bottom: 2px; word-break: break-all;
}
.email-link:hover { background-size: 100% 2px; }
.contact__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
@media (max-width: 900px) { .contact__grid { grid-template-columns: 1fr; } }

/* ---------- footer ---------- */
.footer { border-top: 1px solid var(--line); padding: 28px 0 36px; font-family: var(--mono); font-size: 12px; color: var(--muted); letter-spacing: .03em; }
.footer__inner { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.footer__top:hover { color: var(--ink); }
kbd { font-family: var(--mono); font-size: 11px; padding: 1px 6px; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 3px; color: var(--ink-2); }
@media (pointer: coarse) { .footer__hint { display: none; } }

/* ---------- toast ---------- */
.toast {
  position: fixed; left: 50%; bottom: 24px; z-index: 80; transform: translate(-50%, 16px);
  background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: var(--radius);
  font-family: var(--mono); font-size: 12.5px; opacity: 0; pointer-events: none;
  transition: opacity .25s, transform .35s var(--ease);
}
.toast.is-on { opacity: 1; transform: translate(-50%, 0); }

/* ---------- reveal ---------- */
html.js [data-reveal] { opacity: 0; transform: translateY(22px); transition: opacity .8s var(--ease), transform .8s var(--ease); transition-delay: var(--d, 0s); }
html.js [data-reveal].is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; transition-delay: 0s !important; }
  html.js [data-reveal] { opacity: 1; transform: none; }
  html.js .timeline:not(.is-in) .seg { transform: none; }
}

/* ---------- print ---------- */
@media print {
  :root { --bg: #fff; --bg-alt: #fff; --ink: #000; --ink-2: #222; --muted: #555; --line: #ccc; }
  .nav, .progress, .hero__term, .hero__cta, .filters, .timeline, .skill-search, .contact__actions, .footer__hint, .copy, .toast, .hero__grid-bg, .name__cursor { display: none !important; }
  html.js [data-reveal] { opacity: 1 !important; transform: none !important; }
  .role__body { grid-template-rows: 1fr !important; }
  .role__toggle { display: none; }
  .section { padding-block: 28px; break-inside: avoid-page; }
  .name { font-size: 64px; }
  .hero__row { grid-template-columns: 1fr; padding-bottom: 20px; }
  body { font-size: 12pt; }
}
