/* Alan Whitehead — a field guide to enterprise work and real systems. */
@font-face {
  font-family: Inter;
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("fonts/inter-latin.woff2") format("woff2");
}
@font-face {
  font-family: Fraunces;
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url("fonts/fraunces-latin.woff2") format("woff2");
}
:root {
  --ink: #17201f;
  --muted: #586461;
  --paper: #f5f7f4;
  --white: #fff;
  --line: #d4dbd5;
  --night: #101c1c;
  --night-raised: #192929;
  --light-muted: #adbfba;
  --night-line: #3b504b;
  --accent: #d2f879;
  --green: #315722;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --width: 1280px;
}
* {
  box-sizing: border-box;
}
body,
h1,
h2,
h3,
p,
figure,
ul,
ol,
dl,
dd {
  margin: 0;
}
html {
  scroll-behavior: smooth;
  scroll-padding-top: 100px;
}
body {
  font-family:
    Inter,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  color: var(--ink);
  background: var(--paper);
  font-size: 1rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
a {
  color: inherit;
  text-underline-offset: 0.25em;
  text-decoration-thickness: 1px;
}
button,
input,
textarea {
  font: inherit;
}
button,
a {
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
}
img {
  display: block;
  max-width: 100%;
  height: auto;
}
svg {
  max-width: 100%;
}
button {
  color: inherit;
}
h1,
h2,
h3 {
  font-weight: 500;
  line-height: 1.08;
  letter-spacing: -0.045em;
  text-wrap: balance;
}
h1 {
  font-size: clamp(2.75rem, 5.6vw, 5rem);
}
h2 {
  font-size: clamp(2rem, 3.4vw, 3.25rem);
}
h3 {
  font-size: clamp(1.3rem, 2vw, 1.8rem);
  letter-spacing: -0.035em;
}
p {
  color: var(--muted);
  text-wrap: pretty;
}
p + p {
  margin-top: 1rem;
}
abbr {
  text-decoration: none;
}
::selection {
  color: var(--night);
  background: var(--accent);
}
:focus-visible {
  outline: 3px solid #557d24;
  outline-offset: 5px;
}
.dark :focus-visible,
.site-header :focus-visible,
.site-footer :focus-visible {
  outline-color: var(--accent);
}
[hidden] {
  display: none !important;
}
.wrap {
  width: min(calc(100% - 96px), var(--width));
  margin-inline: auto;
}
.section {
  padding-block: 88px;
}
.dark {
  background: var(--night);
  color: #f5f8f3;
}
.dark p {
  color: var(--light-muted);
}
.dark .eyebrow {
  color: var(--accent);
}
.eyebrow,
.mono {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 0.75rem;
  font-weight: 400;
  line-height: 1.6;
  letter-spacing: 0.065em;
}
.eyebrow {
  text-transform: uppercase;
  color: var(--green);
  margin-bottom: 20px;
}
.eyebrow .status-dot {
  margin-right: 9px;
}
.status-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  background: var(--accent);
  border-radius: 50%;
  vertical-align: middle;
}
.text-link {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  font-size: 0.9375rem;
  font-weight: 600;
  text-decoration: none;
  padding-block: 10px;
  border-bottom: 1px solid currentColor;
}
.text-link span,
.button span {
  transition: transform 0.25s var(--ease);
}
.text-link:hover span,
.button:hover span {
  transform: translate(3px, -3px);
}
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  min-height: 48px;
  padding: 13px 22px;
  border: 1px solid var(--line);
  background: transparent;
  font-size: 0.9375rem;
  font-weight: 600;
  text-decoration: none;
  border-radius: 2px;
  transition:
    background 0.2s,
    color 0.2s,
    border-color 0.2s;
}
.button-dark {
  background: var(--night);
  border-color: var(--night);
  color: var(--white);
}
.button-dark:hover {
  background: #29403a;
}
.button-accent {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--night);
}
.button:hover {
  border-color: var(--green);
}
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}
.skip-link {
  position: fixed;
  top: 12px;
  left: 24px;
  transform: translateY(-180%);
  z-index: 100;
  background: var(--accent);
  color: var(--night);
  padding: 12px 20px;
}
.skip-link:focus {
  transform: none;
}
/* Shared navigation. Visible without JavaScript; compact menu is progressive. */
.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: var(--night);
  color: #f6f8f2;
  border-bottom: 1px solid var(--night-line);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 25px;
  min-height: 84px;
}
.brand {
  display: inline-flex;
  gap: 16px;
  align-items: center;
  text-decoration: none;
  font-size: 0.9375rem;
  font-weight: 600;
  letter-spacing: -0.025em;
  flex-shrink: 0;
}
.brand-mark {
  font-family: Inter, sans-serif;
  font-size: 1.75rem;
  font-weight: 600;
  letter-spacing: -0.13em;
  border: 1px solid var(--night-line);
  padding: 1px 10px 6px 7px;
  line-height: 1.2;
}
.brand-mark span {
  color: var(--accent);
}
#navigation {
  display: flex;
  align-items: center;
  gap: 30px;
}
#navigation a {
  position: relative;
  padding: 28px 0;
  font-size: 0.875rem;
  text-decoration: none;
  color: #b9c6c0;
  transition: color 0.2s;
}
#navigation a:hover,
#navigation a[aria-current] {
  color: #fff;
}
#navigation a::after {
  content: "";
  position: absolute;
  bottom: 17px;
  height: 2px;
  background: var(--accent);
  left: 0;
  right: 0;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s var(--ease);
}
#navigation a[aria-current]::after,
#navigation a:hover::after {
  transform: scaleX(1);
}
.menu-button {
  display: none;
  background: none;
  border: 1px solid var(--night-line);
  padding: 8px 13px;
  font-size: 0.875rem;
  min-height: 44px;
}
.menu-button span {
  margin-left: 18px;
}
/* Opening experience: interactive content map, no live telemetry implied. */
.hero {
  padding-top: 64px;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.02fr 1fr;
  gap: 60px;
  align-items: center;
}
.hero-copy .eyebrow {
  margin-bottom: 27px;
}
.hero h1 {
  font-size: clamp(3rem, 5.35vw, 4.8rem);
  line-height: 1.07;
  letter-spacing: -0.055em;
}
.hero h1 > span {
  color: var(--accent);
}
.hero-lede {
  font-size: 1.125rem;
  max-width: 44ch;
  line-height: 1.7;
  margin-top: 28px;
}
.identity {
  display: flex;
  gap: 15px;
  align-items: center;
  margin-top: 32px;
}
.identity img {
  width: 50px;
  height: 50px;
  object-fit: cover;
  border-radius: 50%;
  filter: grayscale(0.5);
}
.identity p {
  font-size: 0.875rem;
  color: #eff5eb;
  line-height: 1.5;
}
.identity p span {
  color: var(--light-muted);
}
.experience-map {
  border: 1px solid var(--night-line);
  background: var(--night);
  position: relative;
}
.figure-top {
  padding: 16px 20px;
  border-bottom: 1px solid var(--night-line);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  color: var(--light-muted);
}
.figure-top .mono {
  font-size: 0.75rem;
  letter-spacing: 0.01em;
}
.map-canvas {
  position: relative;
  height: 330px;
  background-image: radial-gradient(#394840 0.65px, transparent 0.65px);
  background-size: 20px 20px;
}
.map-lines {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  fill: none;
  stroke: var(--night-line);
  stroke-width: 1;
}
.map-trace {
  stroke: var(--accent);
  stroke-opacity: 0.6;
  stroke-dasharray: 1100;
  stroke-dashoffset: 0;
}
.map-selected {
  stroke: var(--accent);
  stroke-width: 2;
  opacity: 0;
  transition: opacity 0.25s;
}
.experience-map[data-active="revenue"] .path-revenue,
.experience-map[data-active="trust"] .path-trust,
.experience-map[data-active="systems"] .path-systems {
  opacity: 1;
}
.map-orbit {
  stroke-dasharray: 2 7;
}
.map-center {
  position: absolute;
  left: 50%;
  top: 47%;
  transform: translate(-50%, -50%);
  font-size: 2.7rem;
  line-height: 1;
  letter-spacing: -0.13em;
  font-weight: 600;
}
.map-center > span {
  color: var(--accent);
}
.map-node {
  position: absolute;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 12px 16px;
  border: 1px solid #52635d;
  background: var(--night);
  min-width: 180px;
  text-decoration: none;
  transition:
    background 0.25s,
    border-color 0.25s,
    transform 0.3s var(--ease);
}
.map-node strong {
  font-size: 0.875rem;
  font-weight: 500;
}
.map-node small {
  color: var(--light-muted);
  font-size: 0.75rem;
}
.node-index {
  font-family: monospace;
  font-size: 0.75rem;
  color: var(--accent);
  position: absolute;
  right: 9px;
  top: 4px;
}
.node-revenue {
  top: 23px;
  left: 50%;
  transform: translateX(-50%);
}
.node-trust {
  bottom: 18px;
  left: 20px;
}
.node-systems {
  bottom: 18px;
  right: 20px;
}
.map-node:hover,
.map-node[aria-pressed="true"] {
  border-color: var(--accent);
  background: #253525;
}
.map-node[aria-pressed="true"] strong {
  color: var(--accent);
}
.map-panels {
  border-top: 1px solid var(--night-line);
  padding: 24px;
  min-height: 190px;
}
.map-panel .eyebrow {
  margin-bottom: 8px;
  font-size: 0.75rem;
}
.map-panel > p:not(.eyebrow) {
  font-size: 0.9375rem;
  line-height: 1.6;
  max-width: 49ch;
}
.map-panel .text-link {
  font-size: 0.8125rem;
  margin-top: 10px;
  border-bottom: 0;
  color: #f5f8ef;
  padding-bottom: 0;
}
.map-panel + .map-panel {
  margin-top: 25px;
}
.enhanced .map-panel + .map-panel {
  margin-top: 0;
}
.hero-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  border-top: 1px solid var(--night-line);
  padding-block: 22px;
  margin-top: 53px;
}
.hero-foot p {
  font-size: 0.8125rem;
}
.hero-foot p span {
  margin-inline: 12px;
}
.hero-foot > a {
  font-size: 0.875rem;
  white-space: nowrap;
  text-decoration: none;
  color: var(--accent);
}
.hero-foot > a span {
  margin-left: 24px;
}
.proof-strip {
  border-bottom: 1px solid var(--line);
  background: #e9eee6;
}
.proof-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}
.proof-grid > a,
.proof-grid > div {
  padding: 29px 28px 29px 0;
  margin-right: 28px;
  border-right: 1px solid #cbd4c7;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  gap: 7px;
}
.proof-grid > :last-child {
  border: 0;
  margin: 0;
  padding-right: 0;
}
.proof-grid strong {
  font-size: 2.25rem;
  line-height: 1.25;
  font-weight: 500;
  letter-spacing: -0.05em;
}
.proof-grid > :last-child strong {
  font-size: 1.375rem;
  line-height: 2.045;
}
.proof-grid span {
  font-size: 0.75rem;
  color: #4e5c50;
  line-height: 1.7;
}
.proof-grid i {
  font-style: normal;
  margin-left: 12px;
  color: var(--green);
}
.proof-grid > a:hover strong {
  color: var(--green);
}
.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 64px;
  margin-bottom: 42px;
}
.section-head > p {
  max-width: 40ch;
  font-size: 1rem;
}
.selected-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}
.feature-work {
  display: block;
  text-decoration: none;
}
.work-graphic {
  height: 285px;
  position: relative;
  overflow: hidden;
  display: grid;
  place-items: center;
  transition: background 0.3s;
}
.deal-graphic {
  background: #dfe8d6;
}
.deal-graphic > div {
  display: flex;
  align-items: center;
  flex-direction: column;
  text-align: center;
  gap: 9px;
}
.deal-graphic > div > span {
  font-family: monospace;
  font-size: 0.75rem;
}
.deal-graphic .strike-line {
  width: 1px;
  height: 16px;
  background: #7f9275;
}
.deal-graphic strong {
  font-size: 3.5rem;
  letter-spacing: -0.06em;
  font-weight: 500;
  line-height: 1.1;
}
.deal-graphic small {
  font-family: monospace;
  font-size: 0.75rem;
  letter-spacing: 0;
}
.graphic-index {
  position: absolute;
  left: 20px;
  top: 17px;
  font-family: monospace;
  font-size: 0.75rem;
  color: #4e5e45;
}
.graphic-foot {
  font-family: monospace;
  font-size: 0.75rem;
  color: var(--light-muted);
  position: absolute;
  bottom: 23px;
}
.workflow-graphic {
  background: #1f3230;
  align-content: center;
  gap: 20px;
}
.workflow-graphic .graphic-index {
  color: #b8c9c0;
}
.mini-flow {
  display: flex;
  gap: 14px;
  align-items: center;
  width: 80%;
  justify-content: space-between;
}
.mini-flow span {
  color: #d8e9cc;
  font-family: monospace;
  border: 1px solid #647363;
  padding: 13px;
  min-width: 85px;
  text-align: center;
  font-size: 0.8125rem;
}
.mini-flow b {
  color: var(--accent);
  font-weight: 400;
}
.feature-work:hover .work-graphic {
  background-color: #d0dfc1;
}
.feature-work:hover .workflow-graphic {
  background-color: #2a403a;
}
.work-caption {
  padding: 24px 0 0;
}
.work-caption .eyebrow {
  font-size: 0.75rem;
  margin-bottom: 13px;
}
.work-caption h3 {
  position: relative;
  padding-right: 24px;
  max-width: 27ch;
  font-size: 1.625rem;
  line-height: 1.2;
}
.work-caption h3 > span {
  position: absolute;
  right: 0;
  top: 4px;
  transition: transform 0.25s var(--ease);
}
.feature-work:hover h3 > span {
  transform: translate(3px, -3px);
}
.work-caption > p:last-child {
  font-size: 0.9375rem;
  max-width: 51ch;
  margin-top: 15px;
}
.section-link {
  margin-top: 35px;
}
.technical-teaser {
  padding-block: 76px;
}
.teaser-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}
.teaser-grid > div > p:not(.eyebrow) {
  max-width: 43ch;
  margin-top: 23px;
}
.teaser-grid .text-link {
  margin-top: 24px;
  color: var(--accent);
}
.stack-preview {
  border-top: 1px solid var(--night-line);
}
.stack-preview > a {
  display: grid;
  grid-template-columns: 30px 1fr 20px;
  gap: 4px 18px;
  padding: 25px 4px;
  border-bottom: 1px solid var(--night-line);
  text-decoration: none;
  transition:
    padding 0.25s var(--ease),
    background 0.25s;
}
.stack-preview > a > span {
  grid-row: span 2;
  font-family: monospace;
  font-size: 0.75rem;
  color: var(--accent);
  padding-top: 4px;
}
.stack-preview strong {
  font-weight: 500;
  font-size: 1.2rem;
  line-height: 1.4;
}
.stack-preview small {
  grid-column: 2;
  color: var(--light-muted);
  font-size: 0.75rem;
}
.stack-preview b {
  grid-column: 3;
  grid-row: 1;
  font-weight: 400;
  color: var(--accent);
}
.stack-preview > a:hover {
  padding-left: 16px;
  background: #1d2c26;
}
.career-intro {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 100px;
}
.career-intro > div > p:not(.eyebrow) {
  margin-top: 24px;
  max-width: 40ch;
}
.career-intro .text-link {
  margin-top: 25px;
}
.career-path {
  list-style: none;
  padding: 0 0 0 25px;
  border-left: 1px solid var(--line);
}
.career-path li {
  position: relative;
  padding: 0 0 27px 9px;
}
.career-path li:last-child {
  padding-bottom: 0;
}
.career-path li::before {
  content: "";
  position: absolute;
  left: -30px;
  top: 9px;
  width: 9px;
  height: 9px;
  border: 1px solid #677d5d;
  background: var(--paper);
  border-radius: 50%;
}
.career-path li:last-child::before {
  background: var(--green);
}
.career-path span {
  font-family: monospace;
  font-size: 0.75rem;
  color: var(--green);
  display: block;
  margin-bottom: 6px;
}
.career-path strong {
  font-weight: 500;
}
.career-path p {
  font-size: 0.875rem;
  margin-top: 5px;
  max-width: 45ch;
}
.contact-band {
  background: #e3ebd9;
  padding-block: 48px;
  border-top: 1px solid #cbd6c3;
}
.contact-band > .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
}
.contact-band h2 {
  font-size: clamp(1.625rem, 2.6vw, 2.5rem);
}
.contact-band .eyebrow {
  margin-bottom: 14px;
}
.site-footer {
  color: #e0e8dd;
  background: var(--night);
}
.site-footer p {
  color: #a9b9ad;
  font-size: 0.8125rem;
}
.footer-main {
  display: flex;
  justify-content: space-between;
  gap: 25px;
  align-items: center;
  padding-block: 38px;
}
.footer-main > a:last-child {
  font-size: 0.875rem;
  text-decoration: none;
}
.footer-dot {
  color: var(--accent);
  font-size: 1.5rem;
  font-weight: 400;
}
.footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  border-top: 1px solid var(--night-line);
  padding-block: 23px;
}
.footer-bottom > div {
  display: flex;
  gap: 24px;
  font-size: 0.75rem;
}
.footer-bottom a {
  text-decoration: none;
}
.site-footer a:hover {
  text-decoration: underline;
}
/* Interior pages. */
.page-intro {
  padding-block: 60px 49px;
  border-bottom: 1px solid var(--line);
}
.page-intro .intro-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 75px;
  align-items: end;
}
.page-intro h1 {
  max-width: 17ch;
}
.page-intro .lede {
  font-size: 1.0625rem;
  line-height: 1.75;
  max-width: 48ch;
}
.page-intro .subnote {
  font-size: 0.8125rem;
  margin-top: 16px;
}
.section-heading {
  margin-bottom: 35px;
}
.section-heading > p:not(.eyebrow) {
  margin-top: 20px;
  max-width: 62ch;
}
.section-heading.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 70px;
  align-items: end;
}
.section-heading.split > p {
  margin: 0;
}
.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 0;
  list-style: none;
}
.tag-list li {
  font-family: monospace;
  font-size: 0.75rem;
  border: 1px solid var(--line);
  padding: 4px 10px;
  color: var(--muted);
}
.dark .tag-list li {
  border-color: var(--night-line);
  color: var(--light-muted);
}
.page-links {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  margin-top: 24px;
  font-size: 0.8125rem;
}
.page-links a {
  text-decoration: none;
  border-bottom: 1px solid var(--night-line);
  padding-block: 6px;
}
.page-links a:hover {
  color: var(--accent);
}
/* Technical architecture explorer. */
.architecture {
  padding-block: 65px 72px;
}
.architecture-layout {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 36px;
  align-items: stretch;
}
.architecture-board {
  border: 1px solid var(--night-line);
  padding: 28px;
  position: relative;
  background-image: radial-gradient(#3b4b42 0.65px, transparent 0.65px);
  background-size: 22px 22px;
}
.architecture-board > .mono {
  color: var(--light-muted);
  display: block;
  margin-bottom: 23px;
}
.architecture-layers {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 27px;
}
.architecture-layers > li {
  position: relative;
}
.architecture-layers > li:not(:last-child)::after {
  content: "↕";
  position: absolute;
  bottom: -27px;
  left: 50%;
  color: var(--accent);
  font-size: 1.25rem;
  height: 27px;
  line-height: 27px;
}
.layer-link {
  display: grid;
  grid-template-columns: 30px 1fr 18px;
  gap: 4px 14px;
  align-items: center;
  text-decoration: none;
  border: 1px solid #52645a;
  background: var(--night);
  padding: 18px 20px;
  transition:
    background 0.2s,
    border-color 0.2s;
}
.layer-link > .mono {
  grid-row: span 2;
  color: var(--accent);
  font-size: 0.75rem;
}
.layer-link strong {
  font-size: 1.0625rem;
  font-weight: 500;
}
.layer-link small {
  grid-column: 2;
  font-size: 0.75rem;
  color: var(--light-muted);
}
.layer-link b {
  grid-column: 3;
  grid-row: 1;
  color: var(--accent);
  font-weight: 400;
}
.layer-link:hover,
.layer-link[aria-pressed="true"] {
  border-color: var(--accent);
  background: #253525;
}
.architecture-caption {
  font-size: 0.75rem;
  margin-top: 20px;
  max-width: 60ch;
}
.architecture-notes {
  background: #1a2b28;
  border: 1px solid var(--night-line);
  padding: 30px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.architecture-notes .map-panel h3 {
  font-size: 1.7rem;
  margin-bottom: 20px;
}
.architecture-notes .map-panel > p:not(.eyebrow) {
  font-size: 0.9375rem;
}
.architecture-notes .tag-list {
  margin-top: 23px;
}
.architecture-notes .map-panel .text-link {
  margin-top: 18px;
}
.tech-project {
  padding-block: 75px;
  border-bottom: 1px solid var(--line);
}
.project-layout {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 75px;
}
.project-narrative > p:not(.eyebrow) {
  margin-top: 23px;
}
.project-narrative .tag-list {
  margin-top: 24px;
}
.project-narrative h2 {
  font-size: 2.5rem;
}
.project-narrative .scope-label {
  font-size: 0.75rem;
  color: var(--green);
  font-family: monospace;
  display: block;
  margin-top: 26px;
}
.system-figure {
  background: #e8eee3;
  padding: 28px;
  border: 1px solid #cad5c3;
}
.system-figure > figcaption {
  font-size: 0.75rem;
  color: #526349;
  line-height: 1.6;
  margin-top: 22px;
}
.system-figure > .eyebrow {
  font-size: 0.75rem;
  margin-bottom: 22px;
}
.topology-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
  position: relative;
}
.topology-node {
  border: 1px solid #8fa185;
  padding: 16px;
  background: #f7f9f2;
  position: relative;
}
.topology-node strong {
  display: block;
  font-size: 0.9375rem;
  font-weight: 500;
}
.topology-node small {
  font-size: 0.75rem;
  display: block;
  color: #55694b;
  margin-top: 6px;
}
.topology-node.wide {
  grid-column: 1/-1;
  background: #20352a;
  color: #edf5e5;
}
.topology-node.wide small {
  color: #becdb3;
}
.topology-link {
  grid-column: 1/-1;
  text-align: center;
  font-size: 0.75rem;
  font-family: monospace;
  color: #39522c;
  line-height: 1;
}
.technical-details {
  border-top: 1px solid #c7d2bf;
  margin-top: 26px;
  padding-top: 6px;
}
.technical-details summary {
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-weight: 500;
  font-size: 0.875rem;
  cursor: pointer;
  list-style: none;
}
.technical-details summary::after {
  content: "+";
  font-size: 1.2rem;
}
.technical-details[open] summary::after {
  content: "−";
}
.technical-details > div {
  padding: 8px 0 12px;
}
.technical-details p {
  font-size: 0.875rem;
}
.detail-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
  margin-top: 18px;
}
.detail-columns h3 {
  font-size: 1rem;
  line-height: 1.4;
  letter-spacing: -0.01em;
  margin-bottom: 8px;
}
.detail-columns p {
  font-size: 0.875rem;
}
.ai-diagram {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.ai-diagram .topology-node {
  padding: 18px;
}
.ai-diagram .wide {
  text-align: center;
}
.branch-labels {
  grid-column: 1/-1;
  display: flex;
  justify-content: space-around;
  font-family: monospace;
  font-size: 0.75rem;
  color: #3d5631;
}
.voice-flow {
  border-top: 1px solid #b6c7a9;
  margin-top: 20px;
  padding-top: 18px;
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
  font-size: 0.8125rem;
}
.voice-flow span:nth-child(even) {
  color: var(--green);
}
.workflow-steps {
  list-style: none;
  padding: 0;
  counter-reset: workflow;
  display: grid;
  gap: 0;
}
.workflow-steps li {
  counter-increment: workflow;
  padding: 18px 0 18px 49px;
  border-bottom: 1px solid #bacbad;
  position: relative;
}
.workflow-steps li::before {
  content: "0" counter(workflow);
  position: absolute;
  left: 0;
  top: 20px;
  font-family: monospace;
  font-size: 0.75rem;
  color: var(--green);
}
.workflow-steps li strong {
  display: block;
  font-weight: 500;
  font-size: 1rem;
}
.workflow-steps li p {
  font-size: 0.8125rem;
  margin-top: 4px;
}
.workflow-steps li:last-child {
  border: 0;
}
.engineering-note {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 75px;
  padding-block: 60px;
}
.engineering-note h2 {
  font-size: 2rem;
}
.engineering-note p {
  max-width: 62ch;
}
.engineering-note .text-link {
  margin-top: 15px;
}
/* Deal history and progressive case studies. */
.history-strip {
  padding: 29px 0;
  background: #e8eee2;
  border-bottom: 1px solid var(--line);
}
.history-track {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  list-style: none;
  padding: 0;
}
.history-track li {
  padding: 0 18px 0 20px;
  border-left: 1px solid #a6b99b;
  position: relative;
}
.history-track li::before {
  content: "";
  position: absolute;
  left: -3px;
  top: 4px;
  width: 5px;
  height: 5px;
  background: #416331;
}
.history-track time {
  display: block;
  font-family: monospace;
  font-size: 0.75rem;
  color: var(--green);
  margin-bottom: 8px;
}
.history-track strong {
  font-weight: 500;
  font-size: 0.875rem;
  display: block;
}
.history-track p {
  font-size: 0.75rem;
  margin-top: 5px;
}
.deal-library {
  padding-top: 48px;
}
.filter-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 30px;
}
.filter-group {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.filter-group button {
  background: transparent;
  padding: 10px 16px;
  border: 1px solid #acbaa7;
  font-size: 0.8125rem;
  min-height: 44px;
  transition:
    background 0.2s,
    color 0.2s;
}
.filter-group button[aria-pressed="true"] {
  background: var(--night);
  color: var(--white);
  border-color: var(--night);
}
.filter-group button:hover {
  border-color: var(--green);
}
.filter-count {
  font-family: monospace;
  font-size: 0.75rem;
  color: var(--muted);
}
.deal-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  align-items: start;
}
.deal-card {
  border: 1px solid var(--line);
  background: #fff;
  scroll-margin-top: 110px;
}
.deal-card > summary {
  list-style: none;
  cursor: pointer;
  padding: 26px 28px;
  position: relative;
  transition: background 0.25s;
}
.deal-card > summary:hover {
  background: #f0f4e9;
}
.deal-card > summary::-webkit-details-marker,
.technical-details summary::-webkit-details-marker {
  display: none;
}
.deal-card .eyebrow {
  font-size: 0.75rem;
  margin-bottom: 18px;
  max-width: 90%;
}
.deal-number {
  position: absolute;
  right: 25px;
  top: 25px;
  font-family: monospace;
  font-size: 0.75rem;
  color: #667261;
}
.deal-card h3 {
  font-size: 1.625rem;
  max-width: 24ch;
  line-height: 1.18;
  margin-bottom: 23px;
}
.deal-value {
  font-size: 2.7rem;
  line-height: 1;
  letter-spacing: -0.055em;
  font-weight: 500;
  color: var(--ink);
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 11px;
}
.deal-value small {
  font-family: monospace;
  font-size: 0.75rem;
  letter-spacing: 0;
  color: #53654b;
}
.deal-value.words {
  font-size: 1.8rem;
  line-height: 1.5;
}
.deal-card .deal-summary {
  margin-top: 17px;
  font-size: 0.9375rem;
  line-height: 1.65;
}
.deal-meta {
  margin-top: 25px;
  padding-top: 15px;
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-family: monospace;
  font-size: 0.75rem;
  color: #52614b;
}
.deal-meta > span:last-child {
  color: var(--green);
  display: inline-flex;
  gap: 10px;
}
.deal-meta > span:last-child::after {
  content: "+";
  font-size: 1rem;
  line-height: 1;
}
.deal-card[open] .deal-meta > span:last-child::after {
  content: "−";
}
.case-body {
  padding: 0 28px 26px;
}
.case-body > div {
  border-top: 1px solid var(--line);
  padding-top: 20px;
  margin-top: 8px;
}
.case-body h4 {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
  color: var(--green);
  margin: 0 0 8px;
}
.case-body p {
  font-size: 0.875rem;
}
.case-flow {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-top: 22px;
  font-family: monospace;
  font-size: 0.75rem;
  color: var(--green);
}
.case-flow span {
  border: 1px solid #c5d5b7;
  padding: 6px 9px;
  background: #eef4e6;
}
.deal-card[open] {
  border-color: #879c75;
}
.deal-card:target {
  outline: 2px solid var(--green);
  outline-offset: 4px;
}
.library-note {
  font-size: 0.8125rem;
  margin-top: 28px;
  max-width: 80ch;
}
.commercial-method {
  padding-block: 68px;
}
.method-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 45px;
  margin-top: 40px;
}
.method-grid > div {
  border-top: 1px solid var(--night-line);
  padding-top: 20px;
}
.method-grid .mono {
  color: var(--accent);
}
.method-grid h3 {
  font-size: 1.4rem;
  margin-top: 15px;
}
.method-grid p {
  font-size: 0.9375rem;
  margin-top: 16px;
}
/* Resume — direct, complete and printable. */
.resume-header h1 {
  font-size: clamp(2.75rem, 5vw, 4.5rem);
}
.resume-role {
  font-size: 1.125rem;
  margin-top: 20px;
  max-width: 42ch;
}
.header-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}
.resume-header .intro {
  max-width: 62ch;
  margin-top: 18px;
}
.resume-topline {
  display: flex;
  gap: 18px;
  align-items: center;
  font-size: 0.8125rem;
  margin-top: 24px;
}
.resume-progress {
  border-bottom: 1px solid var(--line);
  background: #e8eee2;
  padding-block: 22px;
}
.resume-progress ol {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  padding: 0;
}
.resume-progress a {
  font-size: 0.75rem;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  border-top: 1px solid #a8b99c;
  padding-top: 10px;
  min-width: 100px;
}
.resume-progress a > span {
  font-family: monospace;
  color: var(--green);
  margin-bottom: 4px;
}
.resume-progress a:hover {
  border-color: var(--green);
}
.resume-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 250px;
  gap: 90px;
  align-items: start;
  padding-block: 55px 80px;
}
.resume-content {
  min-width: 0;
}
.resume-contact {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 23px;
  list-style: none;
  padding: 0;
  font-size: 0.8125rem;
}
.resume-section {
  margin-top: 42px;
}
.resume-section:first-of-type {
  margin-top: 35px;
}
.resume-section h2 {
  font-size: 1.8rem;
  border-bottom: 1px solid #8e9c87;
  padding-bottom: 15px;
  margin-bottom: 23px;
  letter-spacing: -0.035em;
}
.resume-section > p {
  font-size: 0.9375rem;
  margin-top: 14px;
}
.job {
  margin-top: 32px;
  padding: 0 0 0 25px;
  border-left: 1px solid #b9c6b1;
  position: relative;
  scroll-margin-top: 110px;
}
.job::before {
  content: "";
  position: absolute;
  left: -4px;
  top: 6px;
  width: 7px;
  height: 7px;
  background: #577748;
  border-radius: 50%;
}
.job h3 {
  font-size: 1.35rem;
  line-height: 1.25;
  letter-spacing: -0.03em;
}
.job-meta {
  font-family: monospace;
  font-size: 0.75rem;
  color: var(--green);
  margin-bottom: 9px;
}
.job > p.job-meta {
  margin-top: 12px;
  margin-bottom: 0;
}
.job-summary {
  font-size: 0.9375rem;
  margin-top: 14px;
  max-width: 73ch;
}
.role-details {
  margin-top: 10px;
}
.role-details summary {
  font-size: 0.8125rem;
  color: var(--green);
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  cursor: pointer;
  list-style: none;
}
.role-details summary::after {
  content: "+";
  font-size: 1.1rem;
}
.role-details[open] summary::after {
  content: "−";
}
.role-details summary::-webkit-details-marker {
  display: none;
}
.role-details ul,
.skills-list {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 13px;
}
.role-details ul {
  margin-top: 8px;
}
.role-details li,
.skills-list li {
  font-size: 0.875rem;
  color: var(--muted);
  line-height: 1.75;
}
.role-details li strong,
.skills-list strong {
  font-weight: 600;
  color: var(--ink);
}
.job > p:not([class]) {
  font-size: 0.9375rem;
  margin-top: 14px;
}
.career-note {
  padding: 20px 24px;
  border: 1px dashed #a8b99c;
  background: #ebf0e7;
  margin-block: 30px;
}
.career-note p {
  font-size: 0.875rem;
}
.resume-aside {
  position: sticky;
  top: 118px;
}
.resume-aside h2 {
  font-size: 1rem;
  letter-spacing: -0.02em;
  margin-bottom: 18px;
}
.resume-aside nav {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.resume-aside nav a {
  padding-block: 11px;
  font-size: 0.8125rem;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
  color: var(--muted);
}
.resume-aside nav a:hover {
  color: var(--green);
}
.resume-aside .button {
  width: 100%;
  margin-top: 20px;
}
.resume-aside .text-link {
  font-size: 0.8125rem;
}
.resume-aside > p {
  font-size: 0.75rem;
  margin-top: 16px;
}
.resume-toggle {
  margin-top: 24px;
  padding: 9px 0;
  border: 0;
  border-bottom: 1px solid var(--green);
  background: none;
  font-size: 0.8125rem;
  color: var(--green);
  min-height: 44px;
}
/* Contact: a useful brief, direct email, no pseudo-submission form. */
.contact-hero {
  padding-block: 60px 80px;
}
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 90px;
  align-items: start;
}
.contact-copy h1 {
  max-width: 14ch;
}
.contact-copy > .lede {
  font-size: 1.0625rem;
  max-width: 43ch;
  margin-top: 25px;
}
.email-link {
  display: inline-block;
  font-size: clamp(1.25rem, 2.15vw, 1.8rem);
  font-weight: 500;
  letter-spacing: -0.025em;
  color: var(--accent);
  margin-top: 32px;
  text-decoration: none;
  border-bottom: 1px solid var(--night-line);
  padding-bottom: 10px;
}
.contact-tools {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-top: 20px;
  flex-wrap: wrap;
}
.copy-email {
  color: var(--light-muted);
  border: 1px solid var(--night-line);
  background: transparent;
  padding: 8px 13px;
  min-height: 44px;
  font-size: 0.8125rem;
}
.contact-tools > a {
  font-size: 0.8125rem;
}
.copy-status {
  font-size: 0.75rem;
  min-height: 24px;
  margin-top: 10px !important;
}
.contact-context {
  margin-top: 28px;
  display: grid;
  gap: 12px;
}
.contact-context > div {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  border-bottom: 1px solid var(--night-line);
  padding-bottom: 12px;
}
.contact-context dt {
  font-size: 0.75rem;
  color: var(--light-muted);
}
.contact-context dd {
  font-size: 0.8125rem;
  text-align: right;
}
.brief-builder {
  border: 1px solid var(--night-line);
  padding: 30px;
  background: #1b2c28;
}
.brief-builder h2 {
  font-size: 1.6rem;
  margin-bottom: 16px;
}
.brief-builder > p {
  font-size: 0.875rem;
  margin-bottom: 22px;
}
.brief-options {
  display: grid;
  gap: 10px;
}
.brief-option {
  display: flex;
  gap: 13px;
  align-items: flex-start;
  padding: 15px;
  border: 1px solid var(--night-line);
  font-size: 0.875rem;
  cursor: pointer;
  transition:
    border-color 0.2s,
    background 0.2s;
}
.brief-option:has(input:checked) {
  border-color: var(--accent);
  background: #293c27;
}
.brief-option input {
  accent-color: var(--accent);
  margin: 5px 0 0;
  width: 15px;
  height: 15px;
}
.brief-option strong {
  font-weight: 500;
  display: block;
}
.brief-option small {
  display: block;
  font-size: 0.75rem;
  color: var(--light-muted);
  margin-top: 4px;
}
.brief-preview {
  border-top: 1px solid var(--night-line);
  margin-top: 23px;
  padding-top: 20px;
}
.brief-preview .eyebrow {
  font-size: 0.75rem;
  margin-bottom: 10px;
}
.brief-preview p {
  font-size: 0.875rem;
}
.brief-preview .button {
  margin-top: 20px;
  display: flex;
}
.brief-note {
  font-size: 0.75rem !important;
  margin-top: 12px !important;
  margin-bottom: 0 !important;
}
.contact-bottom {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 90px;
  padding-block: 65px;
}
.contact-bottom h2 {
  font-size: 2rem;
}
.conversation-topics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
}
.conversation-topics h3 {
  font-size: 1.1rem;
  letter-spacing: -0.02em;
  line-height: 1.4;
  margin-bottom: 10px;
}
.conversation-topics p {
  font-size: 0.875rem;
}
/* Coherent motion: short, once, and always optional. Content starts visible. */
@keyframes enter {
  from {
    opacity: 0.55;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
@keyframes trace {
  from {
    stroke-dashoffset: 1100;
  }
  to {
    stroke-dashoffset: 0;
  }
}
@keyframes panel-in {
  from {
    opacity: 0.6;
    transform: translateY(5px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
@media (prefers-reduced-motion: no-preference) {
  .hero-copy {
    animation: enter 0.75s var(--ease) both;
  }
  .map-trace {
    animation: trace 1.4s var(--ease) both;
  }
  .is-revealed {
    animation: enter 0.7s var(--ease) both;
  }
  .panel-enter {
    animation: panel-in 0.3s var(--ease);
  }
  .deal-card[open] .case-body {
    animation: panel-in 0.3s var(--ease);
  }
  @view-transition {
    navigation: auto;
  }
  ::view-transition-old(root) {
    animation-duration: 0.12s;
  }
  ::view-transition-new(root) {
    animation-duration: 0.2s;
  }
}
@media (min-width: 1500px) {
  .hero {
    padding-top: 76px;
  }
  .hero-foot {
    margin-top: 64px;
  }
}
@media (max-width: 1150px) {
  .wrap {
    width: calc(100% - 64px);
  }
  .hero-grid {
    gap: 35px;
    grid-template-columns: 1fr 1fr;
  }
  .hero h1 {
    font-size: 3.65rem;
  }
  .map-node {
    min-width: 157px;
    padding: 12px;
  }
  .map-node small {
    font-size: 0.75rem;
  }
  .node-trust {
    left: 12px;
  }
  .node-systems {
    right: 12px;
  }
  .proof-grid strong {
    font-size: 2rem;
  }
  .proof-grid > :last-child strong {
    font-size: 1.125rem;
    line-height: 2.2;
  }
  .proof-grid > a,
  .proof-grid > div {
    margin-right: 18px;
    padding-right: 18px;
  }
  .project-layout,
  .architecture-layout,
  .contact-grid,
  .engineering-note {
    gap: 35px;
  }
  .resume-grid {
    gap: 45px;
  }
  .mini-flow {
    width: 90%;
    gap: 10px;
  }
  .mini-flow span {
    min-width: 75px;
    padding: 11px;
  }
  .career-intro {
    gap: 55px;
  }
  #navigation {
    gap: 22px;
  }
  .section-head {
    gap: 40px;
  }
  .figure-top .mono {
    font-size: 0.75rem;
  }
  .teaser-grid {
    gap: 45px;
  }
}
@media (max-width: 900px) {
  .header-inner {
    min-height: 76px;
    flex-wrap: wrap;
  }
  .site-header .brand {
    font-size: 0.875rem;
  }
  #navigation {
    gap: 18px;
  }
  #navigation a {
    font-size: 0.75rem;
  }
  .hero-grid {
    grid-template-columns: 1fr;
  }
  .hero {
    padding-top: 42px;
  }
  .hero-copy {
    max-width: 650px;
  }
  .hero h1 {
    font-size: 4.5rem;
  }
  .hero-lede {
    max-width: 54ch;
  }
  .experience-map {
    max-width: 650px;
    width: 100%;
    margin-top: 5px;
  }
  .map-canvas {
    height: 330px;
  }
  .map-node {
    min-width: 185px;
    padding: 12px 17px;
  }
  .map-node small {
    font-size: 0.75rem;
  }
  .node-trust {
    left: 24px;
  }
  .node-systems {
    right: 24px;
  }
  .figure-top .mono {
    font-size: 0.75rem;
  }
  .hero-foot {
    margin-top: 38px;
  }
  .proof-grid {
    grid-template-columns: 1fr 1fr;
  }
  .proof-grid > a,
  .proof-grid > div {
    margin-right: 25px;
    padding: 25px 20px 25px 0;
  }
  .proof-grid > :nth-child(2) {
    border: 0;
  }
  .proof-grid > :nth-child(-n + 2) {
    border-bottom: 1px solid #cbd4c7;
  }
  .proof-grid > :last-child strong {
    font-size: 1.375rem;
    line-height: 1.82;
  }
  .section {
    padding-block: 65px;
  }
  .section-head {
    align-items: start;
  }
  .section-head > p {
    max-width: 32ch;
  }
  .teaser-grid,
  .career-intro {
    grid-template-columns: 1fr;
    gap: 38px;
  }
  .career-path {
    max-width: 600px;
  }
  .teaser-grid > div > p:not(.eyebrow) {
    max-width: 58ch;
  }
  .stack-preview {
    max-width: 650px;
  }
  .page-intro .intro-grid {
    grid-template-columns: 1fr;
    gap: 25px;
  }
  .page-intro h1 {
    max-width: 22ch;
  }
  .page-intro .lede {
    max-width: 65ch;
  }
  .architecture-layout {
    grid-template-columns: 1fr 1fr;
    gap: 20px;
  }
  .architecture-board {
    padding: 20px;
  }
  .architecture-notes {
    padding: 22px;
  }
  .layer-link {
    padding: 14px 12px;
    gap: 4px 8px;
    grid-template-columns: 23px 1fr 15px;
  }
  .layer-link strong {
    font-size: 0.875rem;
  }
  .layer-link small {
    font-size: 0.75rem;
  }
  .project-layout {
    grid-template-columns: 1fr;
    gap: 30px;
  }
  .project-narrative > p:not(.eyebrow) {
    max-width: 65ch;
  }
  .project-narrative h2 {
    max-width: 20ch;
  }
  .system-figure {
    max-width: 760px;
  }
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 38px;
  }
  .contact-copy {
    max-width: 620px;
  }
  .contact-copy h1 {
    max-width: 20ch;
  }
  .contact-copy > .lede {
    max-width: 55ch;
  }
  .brief-builder {
    max-width: 620px;
  }
  .contact-bottom {
    gap: 35px;
    grid-template-columns: 1fr;
  }
  .resume-grid {
    grid-template-columns: 1fr;
  }
  .resume-aside {
    position: static;
    grid-row: 1;
  }
  .resume-aside nav {
    flex-direction: row;
    gap: 18px;
    flex-wrap: wrap;
  }
  .resume-aside > .button,
  .resume-aside > .text-link,
  .resume-aside > p,
  .resume-aside > h2 {
    display: none;
  }
  .resume-aside nav a {
    padding-block: 5px;
  }
  .resume-toggle {
    margin-top: 8px;
  }
  .resume-progress a {
    min-width: 0;
  }
  .resume-progress ol {
    align-items: start;
  }
  .footer-main > p {
    display: none;
  }
  .mini-flow {
    gap: 5px;
  }
  .mini-flow span {
    min-width: 65px;
    padding: 10px 8px;
    font-size: 0.75rem;
  }
  .deal-card > summary {
    padding: 23px;
  }
  .case-body {
    padding-inline: 23px;
  }
  .history-track {
    grid-template-columns: 1fr 1fr;
    gap: 24px;
  }
  .history-track li {
    padding-right: 20px;
  }
  .section-heading.split {
    gap: 30px;
  }
  .deal-card h3 {
    font-size: 1.4rem;
  }
  .engineering-note {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .method-grid {
    gap: 25px;
  }
}
@media (max-width: 640px) {
  .wrap {
    width: calc(100% - 40px);
  }
  .header-inner {
    min-height: 70px;
    gap: 0;
  }
  .brand-mark {
    font-size: 1.5rem;
  }
  .site-header .brand {
    gap: 12px;
  }
  .enhanced .menu-button {
    display: block;
  }
  .enhanced #navigation {
    display: none;
  }
  .enhanced #navigation.is-open {
    display: flex;
  }
  #navigation {
    width: 100%;
    align-items: stretch;
    flex-direction: column;
    padding: 8px 0 15px;
    gap: 0;
  }
  #navigation a {
    font-size: 0.9375rem;
    padding: 11px 3px;
  }
  #navigation a::after {
    bottom: 5px;
    right: auto;
    width: 22px;
  }
  .hero {
    padding-top: 32px;
  }
  .hero h1 {
    font-size: clamp(2.65rem, 10.4vw, 4rem);
  }
  .hero-copy .eyebrow {
    font-size: 0.75rem;
    margin-bottom: 21px;
  }
  .hero-lede {
    font-size: 1rem;
    line-height: 1.7;
    margin-top: 23px;
  }
  .identity {
    margin-top: 24px;
  }
  .identity p {
    font-size: 0.8125rem;
  }
  .identity img {
    width: 44px;
    height: 44px;
  }
  .hero-grid {
    gap: 29px;
  }
  .map-canvas {
    height: 290px;
  }
  .map-lines {
    height: 290px;
  }
  .map-node {
    min-width: 0;
    width: 43%;
    padding: 11px 10px;
  }
  .map-node strong {
    font-size: 0.75rem;
  }
  .map-node small {
    font-size: 0.75rem;
    letter-spacing: -0.01em;
  }
  .node-index {
    font-size: 0.75rem;
    top: 2px;
    right: 5px;
  }
  .node-revenue {
    width: 49%;
    top: 18px;
  }
  .node-trust {
    bottom: 18px;
    left: 12px;
  }
  .node-systems {
    bottom: 18px;
    right: 12px;
  }
  .map-center {
    font-size: 2.2rem;
  }
  .figure-top {
    padding: 13px 14px;
    gap: 8px;
  }
  .figure-top .mono {
    font-size: 0.75rem;
  }
  .map-panels {
    padding: 20px;
    min-height: 190px;
  }
  .map-panel > p:not(.eyebrow) {
    font-size: 0.875rem;
  }
  .map-panel .eyebrow {
    font-size: 0.75rem;
  }
  .map-panel .text-link {
    font-size: 0.75rem;
  }
  .hero-foot {
    flex-wrap: wrap;
    padding-block: 21px;
    gap: 12px;
    margin-top: 28px;
  }
  .hero-foot p {
    font-size: 0.75rem;
    max-width: 39ch;
  }
  .hero-foot p span {
    margin-inline: 5px;
  }
  .hero-foot > a {
    font-size: 0.8125rem;
  }
  .proof-grid > a,
  .proof-grid > div {
    margin-right: 15px;
    padding: 22px 10px 22px 0;
  }
  .proof-grid > :nth-child(even) {
    margin-right: 0;
    padding-right: 0;
  }
  .proof-grid strong {
    font-size: 1.875rem;
  }
  .proof-grid > :last-child strong {
    font-size: 1.1rem;
    line-height: 1.6;
    min-height: 37px;
    display: flex;
    align-items: center;
  }
  .proof-grid span {
    font-size: 0.75rem;
  }
  .proof-grid i {
    margin-left: 3px;
  }
  .section {
    padding-block: 50px;
  }
  .section-head {
    display: block;
    margin-bottom: 28px;
  }
  .section-head > p {
    max-width: 48ch;
    margin-top: 21px;
    font-size: 0.9375rem;
  }
  .eyebrow {
    font-size: 0.75rem;
    margin-bottom: 16px;
  }
  .selected-grid {
    grid-template-columns: 1fr;
    gap: 38px;
  }
  .work-graphic {
    height: 255px;
  }
  .work-caption {
    padding-top: 19px;
  }
  .work-caption h3 {
    font-size: 1.5rem;
    max-width: 26ch;
  }
  .work-caption > p:last-child {
    font-size: 0.875rem;
  }
  .mini-flow {
    width: 82%;
    gap: 12px;
  }
  .mini-flow span {
    font-size: 0.75rem;
    min-width: 68px;
  }
  .teaser-grid {
    gap: 30px;
  }
  .technical-teaser {
    padding-block: 48px;
  }
  .stack-preview strong {
    font-size: 1.1rem;
  }
  .stack-preview > a {
    padding-block: 22px;
    gap: 4px 12px;
  }
  .stack-preview small {
    font-size: 0.75rem;
  }
  .career-intro {
    gap: 33px;
  }
  .contact-band {
    padding-block: 36px;
  }
  .contact-band > .wrap {
    align-items: start;
    flex-direction: column;
    gap: 25px;
  }
  .contact-band h2 {
    font-size: 1.75rem;
  }
  .footer-main {
    flex-direction: column;
    align-items: start;
    gap: 19px;
    padding-block: 30px;
  }
  .footer-bottom {
    flex-direction: column;
    gap: 17px;
  }
  .footer-bottom > div {
    flex-wrap: wrap;
    gap: 20px;
  }
  .footer-bottom p {
    font-size: 0.75rem;
  }
  .page-intro {
    padding-block: 35px;
  }
  .page-intro h1 {
    font-size: 2.75rem;
  }
  .page-intro .lede {
    font-size: 0.9375rem;
  }
  .page-intro .subnote {
    font-size: 0.75rem;
  }
  .architecture {
    padding-block: 40px;
  }
  .architecture-layout {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .architecture-board {
    padding: 20px;
  }
  .layer-link {
    padding: 16px;
    grid-template-columns: 25px 1fr 15px;
    gap: 4px 10px;
  }
  .layer-link strong {
    font-size: 0.9375rem;
  }
  .layer-link small {
    font-size: 0.75rem;
  }
  .architecture-notes {
    padding: 23px;
  }
  .architecture-notes .map-panel h3 {
    font-size: 1.5rem;
    margin-bottom: 16px;
  }
  .architecture-caption {
    font-size: 0.75rem;
  }
  .architecture-notes .map-panel > p:not(.eyebrow) {
    font-size: 0.875rem;
  }
  .section-heading.split {
    grid-template-columns: 1fr;
    gap: 22px;
  }
  .section-heading.split > p {
    font-size: 0.9375rem;
  }
  .tech-project {
    padding-block: 46px;
  }
  .project-narrative h2 {
    font-size: 2rem;
  }
  .project-narrative > p:not(.eyebrow) {
    font-size: 0.9375rem;
  }
  .system-figure {
    padding: 20px;
  }
  .topology-node {
    padding: 13px;
  }
  .topology-node strong {
    font-size: 0.8125rem;
  }
  .topology-node small {
    font-size: 0.75rem;
  }
  .topology-grid {
    gap: 12px;
  }
  .detail-columns {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .ai-diagram {
    gap: 12px;
  }
  .ai-diagram .topology-node {
    padding: 13px;
  }
  .branch-labels {
    font-size: 0.75rem;
  }
  .system-figure > figcaption {
    font-size: 0.75rem;
  }
  .history-strip {
    padding-block: 24px;
  }
  .history-track {
    gap: 22px;
  }
  .history-track li {
    padding-left: 14px;
    padding-right: 8px;
  }
  .history-track strong {
    font-size: 0.8125rem;
  }
  .history-track p {
    font-size: 0.75rem;
  }
  .history-track time {
    font-size: 0.75rem;
  }
  .filter-row {
    gap: 17px;
  }
  .filter-group {
    gap: 7px;
  }
  .filter-group button {
    font-size: 0.75rem;
    padding: 10px 11px;
  }
  .deal-list {
    grid-template-columns: 1fr;
    gap: 19px;
  }
  .deal-card h3 {
    font-size: 1.6rem;
  }
  .deal-card .deal-summary {
    font-size: 0.875rem;
  }
  .deal-value {
    font-size: 2.6rem;
  }
  .deal-meta {
    font-size: 0.75rem;
  }
  .commercial-method {
    padding-block: 45px;
  }
  .method-grid {
    grid-template-columns: 1fr;
    gap: 25px;
    margin-top: 28px;
  }
  .method-grid p {
    font-size: 0.875rem;
  }
  .resume-role {
    font-size: 1rem;
  }
  .header-actions .button {
    font-size: 0.8125rem;
    padding: 12px 16px;
  }
  .resume-progress ol {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
  }
  .resume-progress a {
    font-size: 0.75rem;
  }
  .resume-grid {
    padding-block: 28px 50px;
    gap: 25px;
  }
  .resume-contact {
    gap: 8px;
    font-size: 0.75rem;
    flex-direction: column;
  }
  .resume-aside nav {
    gap: 8px 17px;
  }
  .resume-aside nav a {
    font-size: 0.75rem;
  }
  .resume-section h2 {
    font-size: 1.6rem;
  }
  .job {
    padding-left: 18px;
  }
  .job h3 {
    font-size: 1.2rem;
  }
  .job-meta {
    font-size: 0.75rem;
  }
  .role-details li,
  .skills-list li {
    font-size: 0.875rem;
  }
  .resume-section > p {
    font-size: 0.875rem;
  }
  .career-note {
    padding: 18px;
  }
  .contact-hero {
    padding-block: 36px 48px;
  }
  .contact-copy h1 {
    font-size: 2.75rem;
  }
  .contact-copy > .lede {
    font-size: 0.9375rem;
  }
  .email-link {
    font-size: 1.35rem;
  }
  .brief-builder {
    padding: 23px;
  }
  .brief-builder h2 {
    font-size: 1.5rem;
  }
  .brief-option {
    padding: 13px;
  }
  .contact-context > div {
    gap: 20px;
  }
  .contact-context dd {
    font-size: 0.75rem;
  }
  .contact-bottom {
    padding-block: 42px;
  }
  .conversation-topics {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .contact-bottom h2 {
    font-size: 1.8rem;
  }
}
@media (max-width: 360px) {
  .wrap {
    width: calc(100% - 32px);
  }
  .map-node {
    padding: 12px 8px;
  }
  .map-node strong {
    font-size: 0.75rem;
  }
  .map-node small {
    font-size: 0.75rem;
  }
  .map-panels {
    padding: 18px;
  }
  .figure-top .mono {
    font-size: 0.75rem;
  }
  .proof-grid > :last-child strong {
    font-size: 1rem;
  }
  .mini-flow {
    width: 90%;
    gap: 7px;
  }
  .mini-flow span {
    min-width: 60px;
  }
  .brand {
    font-size: 0.8125rem;
  }
  .email-link {
    font-size: 1.25rem;
  }
  .topology-node {
    padding: 11px;
  }
  .layer-link {
    padding: 13px;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
  ::view-transition-group(*),
  ::view-transition-old(*),
  ::view-transition-new(*) {
    animation: none !important;
  }
}
@media print {
  @page {
    size: letter;
    margin: 0.5in 0.58in;
    @bottom-left {
      content: "Alan Whitehead · Professional resume";
      font: 8pt Arial;
      color: #666;
    }
    @bottom-right {
      content: counter(page) " / " counter(pages);
      font: 8pt Arial;
      color: #666;
    }
  }
  :root {
    --ink: #000;
    --muted: #333;
    --paper: #fff;
    --line: #aaa;
    --green: #333;
  }
  body {
    font-size: 9pt;
    line-height: 1.35;
    background: #fff;
    color: #000;
  }
  .wrap {
    width: 100%;
    max-width: none;
  }
  .site-header,
  .site-footer,
  .skip-link,
  .resume-aside,
  .resume-progress,
  .header-actions,
  .resume-topline,
  .page-intro .eyebrow,
  .page-intro .intro,
  .page-intro .subnote {
    display: none !important;
  }
  .page-intro {
    padding: 0;
    border: 0;
  }
  .resume-header .intro-grid {
    display: block;
  }
  .resume-header .lede {
    font-size: 9pt;
    line-height: 1.4;
    margin-top: 8pt;
  }
  .resume-header h1 {
    font-size: 23pt;
  }
  .resume-role {
    font-size: 10pt;
    margin-top: 6pt;
    max-width: none;
  }
  .resume-grid {
    display: block;
    padding: 0;
  }
  .resume-content {
    max-width: none;
  }
  .resume-contact {
    margin-top: 10pt;
    display: flex;
    flex-direction: row;
    gap: 12pt;
    font-size: 8pt;
  }
  .resume-section {
    margin-top: 12pt !important;
  }
  .resume-section h2 {
    font-size: 11pt;
    padding-bottom: 3pt;
    margin-bottom: 7pt;
    break-after: avoid;
  }
  .resume-section > p {
    font-size: 9pt;
    margin-top: 7pt;
  }
  .job {
    margin-top: 12pt;
    padding: 0;
    border: 0;
  }
  .job::before {
    display: none;
  }
  .job header {
    break-after: avoid;
    break-inside: avoid;
  }
  #assessment,
  #capabilities {
    break-before: page;
  }
  .job-meta {
    break-after: avoid;
  }
  .job h3 {
    font-size: 10pt;
  }
  .job-meta {
    font-family: Inter, sans-serif;
    font-size: 8pt;
    margin-bottom: 4pt;
  }
  .job-summary,
  .role-details summary {
    display: none !important;
  }
  .role-details {
    margin-top: 4pt;
  }
  .role-details ul,
  .skills-list {
    gap: 5pt;
    margin-top: 5pt;
  }
  .role-details li,
  .skills-list li {
    font-size: 8.5pt;
    line-height: 1.38;
    break-inside: avoid;
  }
  .role-details li strong,
  .skills-list strong {
    color: #000;
  }
  .job > p:not([class]) {
    font-size: 9pt;
    margin-top: 5pt;
  }
  .career-note {
    margin-block: 10pt;
    padding: 7pt 9pt;
    border: 1px solid #aaa;
    background: none;
  }
  .career-note p {
    font-size: 8.5pt;
  }
  .skills-list {
    margin: 0;
  }
  .resume-role,
  .resume-section p,
  .job-meta,
  .role-details li,
  .skills-list li {
    color: #222;
  }
  a {
    text-decoration: none !important;
    color: inherit !important;
  }
  details {
    content-visibility: visible;
  }
  details::details-content {
    content-visibility: visible !important;
  }
  h2,
  h3,
  h4 {
    break-after: avoid;
  }
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}
/* AI systems explorer — task flow and explicit inference boundaries. */
.ai-intro {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 70px;
  margin-bottom: 36px;
  align-items: start;
}
.ai-intro h2 {
  font-size: clamp(2rem, 3.4vw, 3.25rem);
  max-width: 23ch;
}
.ai-intro > div > p:not(.eyebrow) {
  font-size: 0.9375rem;
}
.ai-intro .ai-scope {
  font-family: monospace;
  font-size: 0.75rem !important;
  color: var(--green);
  margin-top: 24px;
  max-width: 43ch;
}
.ai-studio {
  border: 1px solid #abbba2;
  background: #edf2e8;
}
.ai-studio-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 24px 28px;
  background: #e3ebda;
  border-bottom: 1px solid #b8c8af;
}
.ai-studio-head .eyebrow {
  display: block;
  margin-bottom: 8px;
}
.ai-studio-head h3 {
  font-size: 1.4rem;
  letter-spacing: -0.035em;
}
.ai-studio-head > .mono {
  font-size: 0.75rem;
  color: #52644a;
  text-align: right;
}
.ai-controls {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  padding: 22px 28px 0;
}
.ai-controls button {
  border: 1px solid #a6b999;
  background: #f8faf4;
  padding: 10px 17px;
  min-height: 44px;
  font-size: 0.8125rem;
  transition:
    background 0.2s,
    border-color 0.2s,
    color 0.2s;
}
.ai-controls button[aria-pressed="true"] {
  background: var(--night);
  color: #f4f8f0;
  border-color: var(--night);
}
.ai-controls button:hover {
  border-color: #3b6328;
}
.ai-layout {
  display: grid;
  grid-template-columns: 1.55fr 1fr;
  gap: 35px;
  padding: 28px;
}
.ai-blueprint {
  min-width: 0;
}
.ai-label {
  font-family: monospace;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: var(--green);
}
.ai-audio {
  padding: 18px 20px;
  background: #f8faf4;
  border: 1px solid #b6c5ae;
}
.ai-audio > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 9px;
  margin-top: 9px;
}
.ai-audio strong {
  font-size: 0.875rem;
  font-weight: 500;
}
.ai-audio p {
  font-size: 0.75rem;
  margin-top: 8px;
}
.ai-audio > div > span {
  color: var(--green);
}
.ai-connector {
  text-align: center;
  height: 29px;
  line-height: 29px;
  font-size: 1.25rem;
  color: #537147;
}
.ai-flow {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 29px;
}
.ai-flow > li {
  position: relative;
}
.ai-flow > li:not(:last-child)::after {
  content: "↓";
  position: absolute;
  bottom: -29px;
  left: 50%;
  font-size: 1.25rem;
  height: 29px;
  line-height: 29px;
  color: #4c6b3e;
}
.ai-step {
  display: grid;
  grid-template-columns: 25px 1fr;
  gap: 12px;
  padding: 18px 20px;
  background: #fafcf7;
  border: 1px solid #a8bb9f;
  transition:
    border-color 0.25s,
    background 0.25s,
    box-shadow 0.25s;
}
.ai-step-no {
  font-family: monospace;
  font-size: 0.75rem;
  color: #536c47;
  padding-top: 2px;
}
.ai-step strong {
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.4;
}
.ai-step p {
  font-size: 0.8125rem;
  margin-top: 5px;
}
.ai-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 12px;
}
.ai-chip-row > span {
  font-family: monospace;
  font-size: 0.75rem;
  border: 1px solid #c5d1bc;
  padding: 3px 8px;
  background: #edf3e5;
}
.ai-tool-edge {
  border-left: 2px solid #91a781;
  padding-left: 11px;
  margin-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.ai-tool-edge > span:last-child {
  font-size: 0.8125rem;
  color: #46563e;
}
.ai-tool-edge .ai-label {
  font-size: 0.75rem;
}
.ai-inference {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.ai-inference > div {
  padding: 19px 17px;
  border: 1px solid #a5b99b;
  background: #e4edda;
  transition:
    background 0.25s,
    border-color 0.25s,
    box-shadow 0.25s;
}
.ai-inference .ai-hosted {
  background: #e5ecf0;
  border: 1px dashed #7d96a2;
}
.ai-hosted .ai-label {
  color: #31566a;
}
.ai-inference strong {
  display: block;
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.5;
  margin-top: 10px;
}
.ai-inference p {
  font-size: 0.75rem;
  line-height: 1.65;
  margin-top: 4px;
}
.boundary-label {
  display: block;
  font-family: monospace;
  font-size: 0.75rem;
  line-height: 1.65;
  border-top: 1px solid #adbf9f;
  margin-top: 14px;
  padding-top: 10px;
  color: #455b37;
}
.ai-hosted .boundary-label {
  border-top: 1px dashed #879eab;
  color: #355465;
}
.ai-output {
  font-family: monospace;
  font-size: 0.75rem;
  color: var(--green);
  display: block;
  margin-top: 13px;
}
.ai-blueprint > figcaption {
  font-size: 0.75rem;
  color: #5a6951;
  margin-top: 22px;
}
.ai-notes {
  padding: 25px;
  background: #fff;
  border: 1px solid #bdcbb4;
  align-self: start;
  position: sticky;
  top: 108px;
}
.ai-notes h3 {
  font-size: 1.6rem;
  margin-bottom: 20px;
  letter-spacing: -0.04em;
}
.ai-notes p:not(.eyebrow) {
  font-size: 0.875rem;
}
.ai-notes .eyebrow {
  font-size: 0.75rem;
  margin-bottom: 16px;
}
.ai-notes [data-ai-panel] + [data-ai-panel] {
  margin-top: 30px;
}
.enhanced .ai-notes [data-ai-panel] + [data-ai-panel] {
  margin-top: 0;
}
.boundary-facts {
  margin-top: 22px;
  display: grid;
  gap: 16px;
}
.boundary-facts > div {
  border-top: 1px solid var(--line);
  padding-top: 12px;
}
.boundary-facts dt {
  font-size: 0.75rem;
  font-family: monospace;
  color: #3e5b30;
  margin-bottom: 6px;
}
.boundary-facts dd {
  font-size: 0.8125rem;
  line-height: 1.7;
  color: #596653;
}
.ai-trace-tools {
  border-top: 1px solid var(--line);
  margin-top: 25px;
  padding-top: 20px;
}
.ai-trace-tools .button {
  width: 100%;
  font-size: 0.8125rem;
  justify-content: space-between;
}
.ai-trace-status {
  font-size: 0.75rem !important;
  line-height: 1.7;
  min-height: 4em;
  margin-top: 13px !important;
}
.ai-practice-note {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 40px;
  align-items: start;
  margin-top: 26px;
}
.ai-practice-note p {
  font-size: 0.875rem;
}
.ai-practice-note strong {
  font-weight: 600;
  color: var(--ink);
}
.ai-practice-note .tag-list li {
  font-size: 0.75rem;
}
.ai-studio[data-mode="local"] .ai-local {
  background: #dcedc8;
  border-color: #527439;
  box-shadow: inset 0 3px #527439;
}
.ai-studio[data-mode="hosted"] .ai-hosted {
  background: #d9e7ef;
  border-color: #3d667b;
  box-shadow: inset 0 3px #3d667b;
}
.ai-studio[data-mode="audio"] .ai-audio {
  background: #e0edcf;
  border-color: #527439;
  box-shadow: inset 0 3px #527439;
}
.ai-studio[data-trace="task"] [data-ai-stage="task"],
.ai-studio[data-trace="agents"] [data-ai-stage="agents"],
.ai-studio[data-trace="routing"] [data-ai-stage="routing"],
.ai-studio[data-trace="validation"] [data-ai-stage="validation"],
.ai-studio[data-trace="audio"] [data-ai-stage="audio"] {
  border-color: #42612e;
  background: #e1edcf;
  box-shadow: inset 3px 0 #42612e;
}
.ai-studio[data-trace="inference"] .ai-inference {
  outline: 2px solid #527439;
  outline-offset: 5px;
}
.ai-controls button:focus-visible,
.ai-trace-tools button:focus-visible {
  outline-color: #42612e;
}
@keyframes flow-cue {
  from {
    transform: translateY(-4px);
    opacity: 0.4;
  }
  to {
    transform: translateY(3px);
    opacity: 1;
  }
}
@media (prefers-reduced-motion: no-preference) {
  .ai-studio[data-trace="task"] [data-ai-stage="task"]::after,
  .ai-studio[data-trace="agents"] [data-ai-stage="agents"]::after,
  .ai-studio[data-trace="routing"] [data-ai-stage="routing"]::after,
  .ai-studio[data-trace="inference"] [data-ai-stage="inference"]::after {
    animation: flow-cue 0.4s var(--ease);
  }
  .ai-notes .ai-panel-enter {
    animation: panel-in 0.25s var(--ease);
  }
}
@media (max-width: 1100px) {
  .ai-intro {
    gap: 35px;
  }
  .ai-layout {
    grid-template-columns: 1.4fr 1fr;
    gap: 24px;
  }
  .ai-inference > div {
    padding: 15px 12px;
  }
  .ai-notes {
    padding: 22px;
  }
  .ai-notes h3 {
    font-size: 1.4rem;
  }
  .ai-controls,
  .ai-layout,
  .ai-studio-head {
    padding-inline: 22px;
  }
}
@media (max-width: 900px) {
  .ai-intro {
    grid-template-columns: 1fr;
    gap: 25px;
  }
  .ai-intro > div:last-child {
    max-width: 65ch;
  }
  .ai-layout {
    grid-template-columns: 1fr;
    gap: 26px;
  }
  .ai-notes {
    position: static;
  }
  .boundary-facts {
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
  }
  .ai-trace-tools {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 22px;
    align-items: start;
  }
  .ai-trace-status {
    margin-top: 0 !important;
    min-height: 0;
  }
  .ai-studio-head {
    align-items: start;
  }
  .ai-studio-head > .mono {
    max-width: 15ch;
  }
  .ai-practice-note {
    grid-template-columns: 1fr;
    gap: 22px;
  }
}
@media (max-width: 640px) {
  .ai-intro h2 {
    font-size: 2rem;
  }
  .ai-intro .ai-scope {
    font-size: 0.75rem !important;
    margin-top: 20px;
  }
  .ai-studio-head {
    flex-direction: column;
    gap: 14px;
    padding: 21px 17px;
  }
  .ai-studio-head h3 {
    font-size: 1.3rem;
    line-height: 1.3;
  }
  .ai-studio-head > .mono {
    max-width: none;
    text-align: left;
    font-size: 0.75rem;
  }
  .ai-layout {
    padding: 20px 16px;
    gap: 23px;
  }
  .ai-controls {
    padding: 18px 16px 0;
    gap: 7px;
  }
  .ai-controls button {
    padding: 9px 10px;
    font-size: 0.75rem;
  }
  .ai-audio {
    padding: 15px 13px;
  }
  .ai-audio strong {
    font-size: 0.75rem;
  }
  .ai-audio > div {
    gap: 7px;
  }
  .ai-step {
    padding: 16px 13px;
    grid-template-columns: 20px 1fr;
    gap: 8px;
  }
  .ai-step strong {
    font-size: 0.875rem;
  }
  .ai-step p {
    font-size: 0.75rem;
  }
  .ai-chip-row > span {
    font-size: 0.75rem;
    padding: 3px 6px;
  }
  .ai-tool-edge > span:last-child {
    font-size: 0.75rem;
  }
  .ai-inference {
    gap: 10px;
  }
  .ai-inference > div {
    padding: 15px 12px;
  }
  .ai-inference strong {
    font-size: 0.8125rem;
  }
  .ai-inference .ai-label {
    font-size: 0.75rem;
    line-height: 1.7;
    display: block;
  }
  .boundary-label {
    font-size: 0.75rem;
    margin-top: 10px;
    padding-top: 9px;
  }
  .ai-notes {
    padding: 21px 17px;
  }
  .ai-notes h3 {
    font-size: 1.5rem;
  }
  .boundary-facts {
    grid-template-columns: 1fr;
    gap: 15px;
  }
  .ai-trace-tools {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .ai-trace-tools .button {
    width: auto;
  }
  .ai-practice-note {
    gap: 20px;
  }
  .ai-audio p {
    font-size: 0.75rem;
  }
  .ai-step-no {
    font-size: 0.75rem;
  }
}
@media (max-width: 360px) {
  .ai-inference {
    grid-template-columns: 1fr;
  }
  .ai-inference > div {
    padding: 16px;
  }
  .ai-audio > div {
    flex-wrap: wrap;
    justify-content: start;
    gap: 6px 9px;
  }
  .ai-controls button {
    flex: 1 1 auto;
  }
}
@media print {
  .ai-controls,
  .ai-trace-tools {
    display: none !important;
  }
  .ai-notes {
    position: static;
  }
}
.ai-trace-progress {
  list-style: none;
  padding: 0;
  display: flex;
  gap: 4px;
  margin-top: 17px;
}
.ai-trace-progress li {
  flex: 1;
  min-width: 0;
  border-top: 3px solid #d1dbc8;
  padding-top: 7px;
  font-size: 0.75rem;
  text-align: center;
  color: #53604b;
  transition:
    border-color 0.2s,
    color 0.2s;
}
.ai-studio:not([data-mode="audio"]) [data-ai-signal="audio"] {
  display: none;
}
.ai-studio[data-trace="audio"] [data-ai-signal="audio"],
.ai-studio[data-trace="task"] [data-ai-signal="task"],
.ai-studio[data-trace="agents"] [data-ai-signal="agents"],
.ai-studio[data-trace="routing"] [data-ai-signal="routing"],
.ai-studio[data-trace="inference"] [data-ai-signal="inference"],
.ai-studio[data-trace="validation"] [data-ai-signal="validation"] {
  border-color: #42612e;
  color: #213615;
  font-weight: 600;
}
@media (min-width: 641px) and (max-width: 900px) {
  .ai-trace-progress {
    grid-column: 2;
    margin-top: 0;
  }
  .ai-trace-status {
    grid-column: 1/-1;
  }
}
/* Reserve the enhanced first-paint layout while the deferred controller loads. */
.enhanced [data-explorer]:not([data-ready]) [data-panel]:not(:first-child),
.enhanced [data-ai-studio]:not([data-ready]) [data-ai-panel]:not(:first-child) {
  display: none;
}
.enhanced [data-ai-controls][hidden],
.enhanced [data-filters][hidden] {
  display: flex !important;
}
.enhanced [data-ai-trace-tools][hidden] {
  display: block !important;
}
