/* ==========================================================================
   Tokens
   ========================================================================== */
:root {
  --bg: #f7f7f4;
  --bg-alt: #efefe9;
  --surface: #ffffff;
  --surface-2: #f4f4f0;
  --text: #15171b;
  --text-2: #434954;
  --muted: #5d6470;
  --border: #e1e1d9;
  --border-strong: #cdcdc3;
  --accent: #0b7a5b;
  --accent-hover: #086248;
  --accent-soft: #e0f1e9;
  --accent-ink: #ffffff;
  --accent-text: #0a6f53;
  /* Chart marks: one highlight, everything else de-emphasized (validated for contrast and CVD). */
  --viz-hl: #0b7a5b;
  --viz-base: #8d95a1;
  --shadow: 0 1px 2px rgb(20 20 10 / 0.04), 0 12px 32px -16px rgb(20 20 10 / 0.18);
  --grid-dot: rgb(20 20 10 / 0.07);

  --radius: 16px;
  --radius-sm: 10px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", "Segoe UI Mono", Menlo, Consolas, monospace;
  --gutter: 24px;

  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0d0f12;
    --bg-alt: #111418;
    --surface: #15181d;
    --surface-2: #1b1f25;
    --text: #eceef1;
    --text-2: #b8bec7;
    --muted: #8f97a3;
    --border: #252a31;
    --border-strong: #343b45;
    --accent: #3ddc97;
    --accent-hover: #67e7ae;
    --accent-soft: rgb(61 220 151 / 0.12);
    --accent-ink: #05261a;
    --accent-text: #4fe2a2;
    --viz-hl: #23a871;
    --viz-base: #606a78;
    --shadow: 0 1px 2px rgb(0 0 0 / 0.3), 0 16px 40px -20px rgb(0 0 0 / 0.7);
    --grid-dot: rgb(255 255 255 / 0.06);
    color-scheme: dark;
  }
  :root:not([data-theme="light"]) .i-moon { display: none; }
  :root:not([data-theme="light"]) .i-sun { display: block; }
}

:root[data-theme="dark"] {
  --bg: #0d0f12;
  --bg-alt: #111418;
  --surface: #15181d;
  --surface-2: #1b1f25;
  --text: #eceef1;
  --text-2: #b8bec7;
  --muted: #8f97a3;
  --border: #252a31;
  --border-strong: #343b45;
  --accent: #3ddc97;
  --accent-hover: #67e7ae;
  --accent-soft: rgb(61 220 151 / 0.12);
  --accent-ink: #05261a;
  --accent-text: #4fe2a2;
  --viz-hl: #23a871;
  --viz-base: #606a78;
  --shadow: 0 1px 2px rgb(0 0 0 / 0.3), 0 16px 40px -20px rgb(0 0 0 / 0.7);
  --grid-dot: rgb(255 255 255 / 0.06);
  color-scheme: dark;
}
:root[data-theme="dark"] .i-moon { display: none; }
:root[data-theme="dark"] .i-sun { display: block; }

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

h1, h2, h3, h4 { margin: 0; line-height: 1.15; text-wrap: balance; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
strong { font-weight: 650; }

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

.wrap {
  width: 100%;
  max-width: 1160px;
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.sr-only {
  position: absolute !important;
  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: 16px; top: -48px;
  z-index: 100;
  padding: 8px 14px;
  background: var(--accent);
  color: var(--accent-ink);
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
}
.skip:focus { top: 12px; }

svg { width: 18px; height: 18px; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
svg.fill, svg .fill { fill: currentColor; stroke: none; }

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 16px;
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s, border-color 0.15s, color 0.15s, transform 0.15s;
}
.btn:hover { border-color: var(--text-2); }
.btn:active { transform: translateY(1px); }
.btn-primary {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
}
.btn-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.btn-ghost { background: transparent; }
.btn-small { padding: 7px 12px; font-size: 0.875rem; border-radius: 9px; }
.btn-small svg { width: 16px; height: 16px; }
.btn-large { padding: 14px 22px; font-size: 1.05rem; border-radius: 12px; }

.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 38px; height: 38px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: transparent;
  color: var(--text-2);
  cursor: pointer;
}
.icon-btn:hover { color: var(--text); border-color: var(--border-strong); }
.i-sun { display: none; }

/* ==========================================================================
   Nav
   ========================================================================== */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s;
}
.nav.is-scrolled { border-bottom-color: var(--border); }

.nav-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  height: 64px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-weight: 650;
  letter-spacing: -0.01em;
  white-space: nowrap;
}
.brand-mark {
  display: inline-grid;
  place-items: center;
  width: 32px; height: 32px;
  border-radius: 9px;
  background: var(--text);
  color: var(--bg);
  font-family: var(--mono);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.nav nav { margin-left: auto; }
.nav-links { display: flex; gap: 4px; }
.nav-links a {
  display: block;
  padding: 6px 12px;
  border-radius: 8px;
  color: var(--text-2);
  font-size: 0.925rem;
  font-weight: 500;
  text-decoration: none;
}
.nav-links a:hover { color: var(--text); background: var(--surface-2); }
.nav-links a.is-active { color: var(--text); background: var(--surface-2); }

.nav-actions { display: flex; align-items: center; gap: 10px; }

/* ==========================================================================
   Hero
   ========================================================================== */
.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 56px;
  align-items: center;
  padding-top: 72px;
  padding-bottom: 96px;
}
.hero::before {
  /* faint dot grid, like engineering paper */
  content: "";
  position: absolute;
  inset: 0 calc(var(--gutter) * -1);
  z-index: -1;
  background-image: radial-gradient(var(--grid-dot) 1px, transparent 1px);
  background-size: 22px 22px;
  -webkit-mask-image: radial-gradient(ellipse 70% 70% at 70% 40%, #000 30%, transparent 75%);
  mask-image: radial-gradient(ellipse 70% 70% at 70% 40%, #000 30%, transparent 75%);
  pointer-events: none;
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 14px 6px 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text-2);
  font-size: 0.875rem;
  font-weight: 500;
}
.pulse {
  position: relative;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--accent);
}
.pulse::after {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  opacity: 0;
  animation: pulse 2.4s ease-out infinite;
}
@keyframes pulse {
  0% { transform: scale(0.5); opacity: 0.7; }
  100% { transform: scale(1.4); opacity: 0; }
}

.kicker {
  margin-top: 28px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.9rem;
  letter-spacing: 0.02em;
}

.hero h1 {
  margin-top: 12px;
  font-size: clamp(2.5rem, 1.3rem + 4.2vw, 4.1rem);
  font-weight: 750;
  line-height: 1.04;
  letter-spacing: -0.035em;
}
.hero h1 .hl { color: var(--accent-text); }

.lede {
  margin-top: 22px;
  max-width: 40rem;
  color: var(--text-2);
  font-size: 1.15rem;
  line-height: 1.6;
}

.cta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 32px;
}

.facts {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
  margin-top: 44px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}
.facts li { display: flex; flex-direction: column; gap: 2px; }
.facts strong { font-size: 1.15rem; font-weight: 700; letter-spacing: -0.01em; }
.facts span { color: var(--muted); font-size: 0.85rem; line-height: 1.35; }

/* Eval report card */
.report {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
  font-family: var(--mono);
  font-size: 0.85rem;
  overflow: hidden;
}
.report-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  background: var(--surface-2);
}
.report-dots, .shot-bar { display: inline-flex; gap: 6px; }
.report-dots i, .shot-bar i {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--border-strong);
}
.report-file { color: var(--text); font-weight: 600; white-space: nowrap; }
.report-tag {
  margin-left: auto;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-text);
  font-size: 0.72rem;
  white-space: nowrap;
}
.report-table {
  width: 100%;
  border-collapse: collapse;
}
.report-table thead th {
  padding: 12px 16px 6px;
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-align: left;
  text-transform: uppercase;
}
.report-table thead th:last-child { text-align: right; }
.report-table tbody th,
.report-table tbody td {
  padding: 11px 16px;
  border-top: 1px solid var(--border);
  text-align: left;
  vertical-align: baseline;
}
.report-table tbody th { font-weight: 600; white-space: nowrap; }
.report-table tbody th a { text-decoration: none; }
.report-table tbody th a:hover { color: var(--accent-text); text-decoration: underline; }
.report-table tbody td { color: var(--text-2); }
.report-table .num {
  color: var(--text);
  font-size: 0.95rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  text-align: right;
  white-space: nowrap;
}
.from { color: var(--muted); font-weight: 500; }
.report-foot {
  padding: 12px 16px;
  border-top: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--text-2);
  font-size: 0.78rem;
}
.ok { color: var(--accent-text); font-weight: 700; margin-right: 4px; }

/* ==========================================================================
   Sections
   ========================================================================== */
.section { padding: 104px 0; }
.section-alt { background: var(--bg-alt); }

.section-head { max-width: 46rem; margin-bottom: 48px; }
.eyebrow {
  color: var(--accent-text);
  font-family: var(--mono);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.section-head h2, .contact h2 {
  margin-top: 12px;
  font-size: clamp(1.85rem, 1.2rem + 2.2vw, 2.6rem);
  font-weight: 720;
  letter-spacing: -0.028em;
}
.section-lede {
  margin-top: 16px;
  color: var(--text-2);
  font-size: 1.1rem;
}

/* ==========================================================================
   Projects
   ========================================================================== */
.project {
  padding: 32px;
  border: 1px solid var(--border);
  border-radius: calc(var(--radius) + 4px);
  background: var(--surface);
  box-shadow: var(--shadow);
}
.project + .project { margin-top: 40px; }

.project-top {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr);
  gap: 40px;
  align-items: start;
}

.shot {
  display: block;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  background: var(--surface-2);
  text-decoration: none;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s;
}
.shot:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--border-strong); }
.shot-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
}
.shot-url {
  flex: 1;
  min-width: 0;
  margin-left: 10px;
  padding: 3px 10px;
  border-radius: 6px;
  background: var(--surface);
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.74rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.shot img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  object-position: top left;
  background: #fff;
}

.tag {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.tag span {
  padding: 2px 7px;
  border-radius: 6px;
  background: var(--accent-soft);
  color: var(--accent-text);
  font-weight: 700;
}
.project h3 {
  margin-top: 12px;
  font-size: clamp(1.7rem, 1.3rem + 1.2vw, 2.1rem);
  font-weight: 740;
  letter-spacing: -0.025em;
}
.pitch {
  margin-top: 12px;
  color: var(--text-2);
  font-size: 1.05rem;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 24px 0 0;
}
.metrics > div {
  padding: 14px 14px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-2);
}
.metrics dt {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.metrics dd {
  margin: 4px 0 2px;
  font-size: 1.55rem;
  font-weight: 730;
  letter-spacing: -0.02em;
  line-height: 1.2;
  white-space: nowrap;
}
.metrics dd .from { font-size: 1.05rem; margin-right: 2px; }
.metrics p { color: var(--muted); font-size: 0.8rem; line-height: 1.35; }

.links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 22px;
}

.project-body {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr);
  gap: 40px;
  margin-top: 32px;
  padding-top: 32px;
  border-top: 1px solid var(--border);
}
.project-body h4 {
  margin-bottom: 14px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.checks li {
  position: relative;
  padding-left: 28px;
  color: var(--text-2);
  font-size: 0.98rem;
}
.checks li + li { margin-top: 12px; }
.checks li strong { color: var(--text); }
.checks li::before {
  content: "";
  position: absolute;
  left: 3px; top: 0.5em;
  width: 11px; height: 6px;
  border-left: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  transform: rotate(-45deg);
}

.stack {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.built .stack { margin-top: 22px; }
.stack li {
  padding: 4px 10px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--text-2);
  font-family: var(--mono);
  font-size: 0.78rem;
  line-height: 1.5;
}

/* Bar charts: semantic tables, so the table view is the chart. */
.chart {
  margin: 0;
  padding: 20px 20px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-2);
}
.chart figcaption { margin-bottom: 10px; }
.chart figcaption strong { display: block; font-size: 1rem; }
.chart figcaption span { display: block; margin-top: 2px; color: var(--muted); font-size: 0.85rem; }
.chart table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0 5px;
  table-layout: fixed;
}
.chart tbody th {
  width: 46%;
  padding-right: 12px;
  color: var(--text-2);
  font-size: 0.86rem;
  font-weight: 500;
  line-height: 1.3;
  text-align: left;
  vertical-align: middle;
}
.chart tbody td {
  white-space: nowrap;
  vertical-align: middle;
}
.chart tbody tr.group th {
  width: auto;
  padding-top: 10px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.chart tbody tr.group:first-child th { padding-top: 2px; }
.chart .bar {
  display: inline-block;
  vertical-align: middle;
  width: calc((100% - 3.9rem) * var(--v) / 100);
  height: 12px;
  border-radius: 0 4px 4px 0;
  background: var(--viz-base);
  transform-origin: left center;
  transition: transform 0.9s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.chart .val {
  display: inline-block;
  vertical-align: middle;
  margin-left: 8px;
  color: var(--text-2);
  font-family: var(--mono);
  font-size: 0.82rem;
  font-variant-numeric: tabular-nums;
}
.chart tr.is-hl th { color: var(--text); font-weight: 650; }
.chart tr.is-hl .bar { background: var(--viz-hl); }
.chart tr.is-hl .val { color: var(--text); font-weight: 700; }
.chart th em {
  display: inline-block;
  margin-left: 6px;
  padding: 0 6px;
  border-radius: 5px;
  background: var(--accent-soft);
  color: var(--accent-text);
  font-family: var(--mono);
  font-size: 0.66rem;
  font-style: normal;
  font-weight: 600;
  letter-spacing: 0.05em;
  line-height: 1.6;
  text-transform: uppercase;
  vertical-align: 1px;
}
html.js .chart:not(.is-in) .bar { transform: scaleX(0); }

.lesson {
  margin-top: 16px;
  padding: 14px 16px;
  border-left: 3px solid var(--border-strong);
  border-radius: 0 8px 8px 0;
  background: var(--surface-2);
  color: var(--text-2);
  font-size: 0.92rem;
}
.lesson strong { color: var(--text); }

/* ==========================================================================
   Approach
   ========================================================================== */
.principles {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  counter-reset: p;
}
.principles li {
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  counter-increment: p;
}
.principles li::before {
  content: counter(p, decimal-leading-zero);
  display: block;
  margin-bottom: 14px;
  color: var(--accent-text);
  font-family: var(--mono);
  font-size: 0.8rem;
  font-weight: 700;
}
.principles h3 { font-size: 1.1rem; font-weight: 680; letter-spacing: -0.01em; }
.principles p { margin-top: 8px; color: var(--text-2); font-size: 0.95rem; }

/* ==========================================================================
   Experience
   ========================================================================== */
.exp {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
  gap: 20px;
}
.job, .carry, .card, .skill-group {
  padding: 28px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.job-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px 20px;
  margin-bottom: 20px;
}
.job h3 { font-size: 1.35rem; font-weight: 720; letter-spacing: -0.015em; }
.org { margin-top: 4px; color: var(--text-2); }
.when {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.85rem;
  white-space: nowrap;
}
.carry {
  background: var(--accent-soft);
  border-color: transparent;
}
.carry h3 { font-size: 1.05rem; font-weight: 680; }
.carry p { margin-top: 10px; color: var(--text-2); font-size: 0.95rem; }

.cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  margin-top: 20px;
}
.card-label {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.card h3 { margin-top: 10px; font-size: 1.1rem; font-weight: 680; }
.card p:last-child { margin-top: 6px; color: var(--text-2); font-size: 0.95rem; }

/* ==========================================================================
   Skills
   ========================================================================== */
.skills {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr 1.4fr;
  gap: 20px;
}
.skill-group h3 { margin-bottom: 16px; font-size: 1.05rem; font-weight: 680; }

/* ==========================================================================
   Contact
   ========================================================================== */
.contact { text-align: center; }
.contact-inner { max-width: 760px; }
.contact .section-lede { margin-inline: auto; max-width: 36rem; }
.email-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 32px;
}
.copy-status {
  min-height: 1.5em;
  margin-top: 10px;
  color: var(--accent-text);
  font-size: 0.9rem;
  font-weight: 600;
}
.social {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 24px;
  margin-top: 16px;
}
.social a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text-2);
  font-weight: 500;
  text-decoration: none;
}
.social a:hover { color: var(--text); text-decoration: underline; text-underline-offset: 3px; }

/* ==========================================================================
   Footer
   ========================================================================== */
.footer {
  padding: 28px 0 40px;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.875rem;
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
}
.footer a { color: var(--text-2); }

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1020px) {
  .hero { grid-template-columns: 1fr; gap: 48px; padding-top: 48px; }
  .report { max-width: 560px; }
  .project-top, .project-body { grid-template-columns: 1fr; gap: 28px; }
  .principles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .exp { grid-template-columns: 1fr; }
  .skills { grid-template-columns: 1fr 1fr; }
  .skills .skill-group:first-child { grid-column: 1 / -1; }
}

@media (max-width: 860px) {
  .nav nav { display: none; }
  .nav-actions { margin-left: auto; }
}

@media (max-width: 720px) {
  :root { --gutter: 16px; }
  body { font-size: 1rem; }
  .section { padding: 72px 0; }
  .hero { padding-top: 36px; padding-bottom: 72px; }
  .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .project { padding: 18px; border-radius: var(--radius); }
  .metrics { grid-template-columns: 1fr; gap: 0; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface-2); }
  .metrics > div { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 12px; align-items: center; padding: 10px 14px; border: 0; border-radius: 0; background: none; }
  .metrics > div + div { border-top: 1px solid var(--border); }
  .metrics dd { grid-column: 2; grid-row: 1 / span 2; margin: 0; font-size: 1.3rem; }
  .metrics dt, .metrics p { grid-column: 1; }
  .report-dots { display: none; }
  .report-head { padding: 10px 14px; }
  .principles, .cards, .skills { grid-template-columns: 1fr; }
  .job, .carry, .card, .skill-group, .principles li { padding: 20px; }
  .chart { padding: 16px 14px 10px; }
  .chart tbody th { width: 50%; }
  .report-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .report-table tbody tr {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    column-gap: 12px;
    padding: 10px 14px;
    border-top: 1px solid var(--border);
  }
  .report-table tbody tr:first-child { border-top: 0; }
  .report-table tbody th, .report-table tbody td { padding: 0; border-top: 0; }
  .report-table tbody th { grid-column: 1; font-size: 0.75rem; }
  .report-table tbody td:not(.num) { grid-column: 1; }
  .report-table .num { grid-column: 2; grid-row: 1 / span 2; align-self: center; }
  .brand-name { display: none; }
}

@media (max-width: 400px) {
  .cta .btn { flex: 1 1 100%; }
  .email-row .btn { flex: 1 1 100%; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html.js .chart:not(.is-in) .bar { transform: none; }
}

@media print {
  .nav, .skip, .cta, .links, .email-row, .copy-status, .icon-btn { display: none !important; }
  body { background: #fff; color: #000; }
  .section { padding: 32px 0; }
  .project, .principles li, .job, .carry, .card, .skill-group { box-shadow: none; break-inside: avoid; }
  html.js .chart:not(.is-in) .bar { transform: none; }
}
