/* Huseyin Kaplan — site styles. Monochrome frame, colourful content. */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; color-scheme: light; }
img, svg { max-width: 100%; }
[hidden] { display: none !important; }
:root { padding-top: env(safe-area-inset-top, 0px); padding-bottom: env(safe-area-inset-bottom, 0px); }
body { margin: 0; }
/* Layout: inset gray panels open and close the page; plain ground in between holds a dense bento of live demos. */
:root {
  --page: #fafafa;
  --panel: #f4f4f5;
  --card: #ffffff;
  --line: #e4e4e7;
  --line-strong: #d4d4d8;
  --ink: #09090b;
  --body: #52525b;
  --muted: #a1a1aa;
  --ok: #22c55e;
  --ok-tint: #dcfce7;
  --ok-ink: #15803d;
  --cta-bg: #09090b;
  --cta-ink: #fafafa;
  --shadow: 0 1px 2px rgb(9 9 11 / 0.04), 0 8px 24px rgb(9 9 11 / 0.06);

  --blue: #2563eb;
  --blue-tint: #dbeafe;
  --violet: #7c3aed;
  --violet-tint: #ede9fe;
  --amber: #d97706;
  --amber-tint: #fef3c7;
  --red: #dc2626;
  --red-tint: #fee2e2;
  --pink: #db2777;
  --teal: #0d9488;

  --screen: #0c0c0e;
  --screen-2: #17171a;
  --screen-line: #27272a;
  --screen-ink: #e4e4e7;
  --screen-muted: #71717a;

  --font-display: 'Geist', 'Helvetica Neue', Arial, sans-serif;
  --font-body: 'Geist', 'Helvetica Neue', Arial, sans-serif;
  --font-mono: 'Geist Mono', ui-monospace, 'SFMono-Regular', Consolas, monospace;

  --radius-panel: 28px;
  --radius-card: 16px;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --page: #09090b;
    --panel: #131316;
    --card: #0f0f12;
    --line: #26262b;
    --line-strong: #3f3f46;
    --ink: #fafafa;
    --body: #a1a1aa;
    --muted: #71717a;
    --ok-tint: rgb(34 197 94 / 0.16);
    --ok-ink: #4ade80;
    --cta-bg: #fafafa;
    --cta-ink: #09090b;
    --shadow: 0 1px 2px rgb(0 0 0 / 0.4), 0 8px 24px rgb(0 0 0 / 0.35);
    --blue: #60a5fa;
    --blue-tint: rgb(96 165 250 / 0.16);
    --violet: #a78bfa;
    --violet-tint: rgb(167 139 250 / 0.16);
    --amber: #fbbf24;
    --amber-tint: rgb(251 191 36 / 0.15);
    --red: #f87171;
    --red-tint: rgb(248 113 113 / 0.15);
    --pink: #f472b6;
    --teal: #2dd4bf;
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --page: #09090b;
  --panel: #131316;
  --card: #0f0f12;
  --line: #26262b;
  --line-strong: #3f3f46;
  --ink: #fafafa;
  --body: #a1a1aa;
  --muted: #71717a;
  --ok-tint: rgb(34 197 94 / 0.16);
  --ok-ink: #4ade80;
  --cta-bg: #fafafa;
  --cta-ink: #09090b;
  --shadow: 0 1px 2px rgb(0 0 0 / 0.4), 0 8px 24px rgb(0 0 0 / 0.35);
  --blue: #60a5fa;
  --blue-tint: rgb(96 165 250 / 0.16);
  --violet: #a78bfa;
  --violet-tint: rgb(167 139 250 / 0.16);
  --amber: #fbbf24;
  --amber-tint: rgb(251 191 36 / 0.15);
  --red: #f87171;
  --red-tint: rgb(248 113 113 / 0.15);
  --pink: #f472b6;
  --teal: #2dd4bf;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  background: var(--page);
  color: var(--body);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.6;
  padding-inline: 12px;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; border-radius: 8px; }
h1, h2, h3 { color: var(--ink); font-family: var(--font-display); margin: 0; text-wrap: balance; }
p { margin: 0; }
.mono { font-family: var(--font-mono); }
.wrap { max-width: 1160px; margin-inline: auto; padding-inline: 8px; }

/* Nav */
.nav {
  position: fixed;
  top: calc(env(safe-area-inset-top, 0px) + 14px);
  left: 50%;
  transform: translateX(-50%);
  z-index: 20;
  width: min(1080px, calc(100% - 32px));
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 8px 8px 8px 20px;
  background: color-mix(in srgb, var(--card) 88%, transparent);
  backdrop-filter: blur(12px);
  border: 1px solid var(--line);
  border-radius: 999px;
  box-shadow: var(--shadow);
}
.brand { display: flex; align-items: center; color: var(--ink); }
.brand svg { height: 24px; width: auto; display: block; }
.nav-links { display: flex; gap: 2px; margin-inline: auto; }
.nav { transition: transform 220ms var(--ease), opacity 220ms var(--ease); }
.nav.is-hidden { transform: translate(-50%, calc(-100% - 24px)); opacity: 0; }
.nav-links a[aria-current="page"] { background: var(--panel); color: var(--ink); }
.dd { position: relative; }
.dd-panel {
  position: absolute; top: calc(100% + 10px); left: 50%; transform: translate(-50%, 4px);
  width: 300px; padding: 6px; display: grid; gap: 2px;
  background: var(--card); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow);
  opacity: 0; visibility: hidden; transition: opacity 160ms var(--ease), transform 160ms var(--ease), visibility 160ms;
}
.dd-panel::before { content: ''; position: absolute; inset: -12px 0 auto; height: 12px; }
.dd:hover .dd-panel, .dd:focus-within .dd-panel { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
.nav-links .dd-panel a { display: grid; gap: 1px; padding: 9px 12px; border-radius: 10px; }
.dd-panel b { color: var(--ink); font-weight: 500; font-size: 13.5px; }
.dd-panel span { color: var(--muted); font-size: 12.5px; }
.nav-links .dd-panel a.dd-all { color: var(--ink); font-size: 13px; font-weight: 500; }
.icon-btn .si { width: 16px; height: 16px; }
.icon-btn.menu-btn { display: none; cursor: pointer; }
.menu {
  position: fixed; z-index: 19; left: 50%; transform: translateX(-50%);
  top: calc(env(safe-area-inset-top, 0px) + 74px); width: min(420px, calc(100% - 32px));
  padding: 8px; display: grid; gap: 2px;
  background: var(--card); border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow);
}
.menu > a { padding: 11px 14px; border-radius: 12px; color: var(--ink); font-size: 15px; font-weight: 500; }
.menu > a:hover, .menu > a[aria-current="page"] { background: var(--panel); }
.menu-foot { display: flex; gap: 8px; padding: 8px 6px 4px; border-top: 1px solid var(--line); margin-top: 6px; }
.menu-foot .btn { flex: 1; justify-content: center; }
.nav-links a {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 6px 12px; border-radius: 999px; font-size: 14px; color: var(--body);
  transition: background 150ms var(--ease), color 150ms var(--ease);
}
.nav-links a:hover { background: var(--panel); color: var(--ink); }
.caret { width: 10px; height: 10px; opacity: 0.6; }
.nav-right { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.nav-links + .nav-right { margin-left: 0; }
.kbd {
  font-family: var(--font-mono); font-size: 11px; color: var(--muted);
  border: 1px solid var(--line); background: var(--card);
  border-radius: 999px; padding: 1px 8px;
}
.icon-btn {
  width: 36px; height: 36px; display: grid; place-items: center;
  border-radius: 999px; color: var(--ink); border: 1px solid var(--line); background: var(--card);
  transition: border-color 150ms var(--ease);
}
.icon-btn:hover { border-color: var(--line-strong); }
.icon-btn svg { width: 16px; height: 16px; }
.count-pill {
  display: inline-flex; align-items: center; gap: 8px;
  height: 36px; padding: 0 6px 0 14px; border-radius: 999px;
  background: var(--panel); border: 1px solid var(--line);
  font-size: 13px; font-weight: 500; color: var(--ink);
}
.count-pill b {
  font-family: var(--font-mono); font-weight: 500; font-size: 11px;
  min-width: 24px; height: 24px; display: grid; place-items: center;
  border-radius: 999px; background: var(--ink); color: var(--page);
}

/* Hero */
.panel { background: var(--panel); border-radius: var(--radius-panel); }
.hero {
  margin-top: 12px;
  padding: 140px 20px 0;
  text-align: center;
  overflow: hidden;
}
.badge {
  display: inline-flex; align-items: center; gap: 10px; flex-wrap: wrap; justify-content: center;
  padding: 5px 14px 5px 6px; border-radius: 999px;
  background: var(--card); border: 1px solid var(--line);
  font-size: 13px; color: var(--ink);
}
.badge .status {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 2px 10px; border-radius: 999px; background: var(--ok-tint); color: var(--ok-ink);
  font-family: var(--font-mono); font-size: 11px; text-transform: uppercase; letter-spacing: 0.08em;
}
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 3px rgb(34 197 94 / 0.2); }
.badge .note { color: var(--muted); }
.display {
  margin-top: 28px;
  font-size: clamp(44px, 8vw, 96px);
  line-height: 1.02;
  font-weight: 700;
  letter-spacing: -0.035em;
}
.display .line { display: block; }
.chip {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.12em;
  height: 0.6em; padding: 0 0.18em; margin: 0 0.1em;
  border-radius: 0.24em; vertical-align: 0.32em;
  font-family: var(--font-mono); font-size: 0.44em; font-weight: 500; letter-spacing: 0;
  transform: rotate(-4deg);
}
.chip-cite { background: var(--blue-tint); color: var(--blue); }
.chip-pass { background: var(--ok-tint); color: var(--ok-ink); transform: rotate(5deg); }
.chip-pass svg { width: 0.62em; height: 0.62em; }
.lede {
  margin: 22px auto 0; max-width: 60ch;
  font-size: 17px; line-height: 1.6; color: var(--body); text-wrap: balance;
}
.creds {
  list-style: none; margin: 18px 0 0; padding: 0;
  display: flex; justify-content: center; flex-wrap: wrap; gap: 6px 18px;
  font-family: var(--font-mono); font-size: 12px; color: var(--muted);
}
.creds li { display: inline-flex; align-items: center; gap: 8px; }
.creds li::before { content: ''; width: 4px; height: 4px; border-radius: 50%; background: var(--ok); }
.hero-btns { margin-top: 24px; display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; }
.btn {
  height: 38px; padding: 0 18px; display: inline-flex; align-items: center; border-radius: 999px;
  border: 1px solid var(--line); background: var(--card); color: var(--ink); font-size: 14px; font-weight: 500;
  transition: border-color 150ms var(--ease), opacity 150ms var(--ease);
}
.btn:hover { border-color: var(--line-strong); }
.btn-dark { background: var(--ink); color: var(--page); border-color: var(--ink); }
.btn-dark:hover { opacity: 0.88; }
.cmd {
  margin: 28px auto 0; width: min(620px, 100%);
  display: flex; align-items: center; gap: 8px;
  padding: 6px; background: var(--card); border: 1px solid var(--line); border-radius: 999px;
  box-shadow: var(--shadow); text-align: left;
}
.cmd select {
  appearance: none; flex: none;
  height: 34px; padding: 0 28px 0 14px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--panel) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 10 10'%3E%3Cpath d='M2 4l3 3 3-3' fill='none' stroke='%23a1a1aa' stroke-width='1.5'/%3E%3C/svg%3E") no-repeat right 11px center;
  font-family: var(--font-mono); font-size: 12px; color: var(--ink); cursor: pointer;
}
.cmd code {
  flex: 1; min-width: 0; overflow-x: auto; white-space: nowrap;
  font-family: var(--font-mono); font-size: 13px; color: var(--ink);
  scrollbar-width: none;
}
.cmd code::-webkit-scrollbar { display: none; }
.cmd code .prompt { color: var(--muted); margin-right: 8px; }
.copy {
  flex: none; height: 34px; padding: 0 14px; border-radius: 999px; cursor: pointer;
  border: 0; background: var(--ink); color: var(--page);
  font: 500 12px var(--font-mono);
  transition: opacity 150ms var(--ease);
}
.copy:hover { opacity: 0.85; }
.cmd-note { margin-top: 10px; font-family: var(--font-mono); font-size: 12px; color: var(--muted); }

.shot-wrap { position: relative; margin: 56px auto 0; max-width: 980px; }
.shot {
  height: 300px; border-radius: 18px 18px 0 0; overflow: hidden;
  background: var(--screen); border: 1px solid var(--screen-line); border-bottom: 0;
  display: block; text-align: left;
  filter: blur(2.4px) saturate(1.05);
  -webkit-mask-image: linear-gradient(to bottom, #000 55%, transparent);
  mask-image: linear-gradient(to bottom, #000 55%, transparent);
  font-size: 12px; color: var(--screen-ink);
}
.shot img { width: 100%; height: auto; display: block; }
.toolbar {
  position: absolute; left: 50%; top: 110px; transform: translateX(-50%);
  display: flex; align-items: center; gap: 4px;
  padding: 6px 6px 6px 8px; border-radius: 999px;
  background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow);
  white-space: nowrap;
}
.toolbar span.t-ico {
  width: 30px; height: 30px; display: grid; place-items: center; border-radius: 999px; color: var(--body);
}
.toolbar span.t-ico svg { width: 15px; height: 15px; }
.toolbar .t-label {
  margin-left: 4px; height: 30px; display: inline-flex; align-items: center; gap: 6px;
  padding: 0 14px; border-radius: 999px; background: var(--ink); color: var(--page);
  font-size: 13px; font-weight: 500;
}

/* Section intro */
.intro { padding: 112px 0 48px; text-align: center; }
.pill-label {
  display: inline-block; padding: 4px 12px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--card);
  font-family: var(--font-mono); font-size: 11px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--body);
}
.intro h2 { margin-top: 18px; font-size: clamp(30px, 4.4vw, 44px); font-weight: 700; letter-spacing: -0.03em; line-height: 1.1; }
.intro p { margin: 14px auto 0; max-width: 58ch; font-size: 16px; text-wrap: balance; }

.evidence { list-style: none; margin: 22px 0 0; padding: 0; display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; }
.evidence li {
  display: inline-flex; align-items: center; gap: 8px; padding: 4px 12px 4px 4px; border-radius: 999px;
  background: var(--card); border: 1px solid var(--line); font-size: 13px; color: var(--body);
}
.evidence b { padding: 2px 9px; border-radius: 999px; background: var(--panel); color: var(--ink); font: 500 11px var(--font-mono); text-transform: uppercase; letter-spacing: 0.06em; }

/* Bento */
.bento { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.stack { grid-column: span 2; display: grid; gap: 16px; }
.card {
  display: flex; flex-direction: column;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-card);
  overflow: hidden;
  transition: transform 180ms var(--ease), border-color 180ms var(--ease), opacity 180ms var(--ease);
}
.card:hover { transform: translateY(-2px); border-color: var(--line-strong); }
.card.dim { opacity: 0.28; }
.demo { flex: 1; min-height: 250px; padding: 20px; position: relative; display: flex; flex-direction: column; justify-content: center; }
.tall .demo { min-height: 560px; }
.card-foot {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 12px 16px; border-top: 1px solid var(--line);
}
.card-foot .name { color: var(--ink); font-weight: 500; font-size: 14px; }
.card-foot .proj { color: var(--muted); font-family: var(--font-mono); font-size: 11px; margin-left: 8px; }
.card-foot .arrow {
  width: 28px; height: 28px; display: grid; place-items: center; border-radius: 999px;
  border: 1px solid var(--line); color: var(--ink); font-size: 14px;
  transition: background 150ms var(--ease), color 150ms var(--ease);
}
.card:hover .arrow { background: var(--ink); color: var(--page); }
.cap { font-family: var(--font-mono); font-size: 11px; color: var(--muted); }

/* Demo: cited stream */
.chat-q { align-self: flex-end; max-width: 85%; background: var(--panel); color: var(--ink); border-radius: 14px 14px 4px 14px; padding: 8px 12px; font-size: 13px; }
.chat-a { margin-top: 10px; min-height: 78px; font-size: 13.5px; color: var(--ink); line-height: 1.6; }
.chat-a .c { display: inline-block; font: 500 10.5px var(--font-mono); padding: 0 5px; margin: 0 2px; border-radius: 4px; background: var(--blue-tint); color: var(--blue); vertical-align: 1px; }
.chat-a .cursor { display: inline-block; width: 7px; height: 14px; background: var(--ink); vertical-align: -2px; animation: blink 0.9s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.sources { margin-top: 12px; display: grid; gap: 6px; }
.src { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border: 1px solid var(--line); border-radius: 8px; font: 12px var(--font-mono); color: var(--body); transition: border-color 200ms, background 200ms; }
.src.on { border-color: var(--blue); background: var(--blue-tint); color: var(--ink); }
.src b { font-weight: 500; color: var(--blue); }

/* Demo: abstention */
.q-line { font-size: 14px; color: var(--ink); min-height: 44px; }
.meter { position: relative; height: 10px; border-radius: 999px; background: var(--panel); margin: 18px 0 6px; overflow: visible; }
.meter .fill { height: 100%; border-radius: 999px; width: 0; background: var(--muted); transition: width 700ms var(--ease), background 300ms; }
.meter .thr { position: absolute; top: -6px; bottom: -6px; width: 2px; background: var(--ink); left: 55%; }
.meter-scale { display: flex; justify-content: space-between; }
.verdict { margin-top: 18px; display: inline-flex; align-self: flex-start; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 999px; font: 500 12px var(--font-mono); transition: background 200ms, color 200ms; background: var(--panel); color: var(--muted); }
.verdict.yes { background: var(--ok-tint); color: var(--ok-ink); }
.verdict.no { background: var(--amber-tint); color: var(--amber); }

/* Demo: RRF */
.rrf { display: grid; grid-template-columns: 1fr 1fr 1.25fr; gap: 10px; font-family: var(--font-mono); font-size: 12px; }
.rrf h4 { margin: 0 0 6px; font-weight: 500; font-size: 10.5px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); }
.rrf ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.rrf li { display: flex; justify-content: space-between; gap: 6px; padding: 5px 7px; border-radius: 6px; border: 1px solid var(--line); color: var(--body); transition: all 200ms var(--ease); font-variant-numeric: tabular-nums; }
.rrf li .r { color: var(--muted); }
.rrf .lex li.on { border-color: var(--violet); background: var(--violet-tint); color: var(--ink); }
.rrf .vec li.on { border-color: var(--teal); background: color-mix(in srgb, var(--teal) 14%, transparent); color: var(--ink); }
.rrf .fused li.on { border-color: var(--ink); color: var(--ink); background: var(--panel); }
.formula { margin-top: 14px; }

/* Demo: CI gate */
.ci { display: grid; gap: 8px; font-family: var(--font-mono); font-size: 12.5px; }
.ci-head { display: flex; justify-content: space-between; color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: 0.08em; }
.suite { display: grid; grid-template-columns: 22px 1fr auto; align-items: center; gap: 8px; padding: 10px; border: 1px solid var(--line); border-radius: 10px; color: var(--body); transition: border-color 200ms; }
.suite .st { width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; border: 1.5px solid var(--line-strong); }
.suite.run .st { border-color: var(--blue); border-top-color: transparent; animation: spin 0.7s linear infinite; }
.suite.pass .st { border: 0; background: var(--ok); color: #fff; }
.suite.pass .st::after { content: ''; width: 7px; height: 4px; border: 2px solid #fff; border-top: 0; border-right: 0; transform: rotate(-45deg) translate(1px, -1px); }
.suite.pass { color: var(--ink); }
.suite .n { color: var(--muted); font-variant-numeric: tabular-nums; }
@keyframes spin { to { transform: rotate(360deg); } }
.progress { height: 6px; border-radius: 999px; background: var(--panel); overflow: hidden; margin-top: 8px; }
.progress span { display: block; height: 100%; width: 0; background: var(--ok); transition: width 300ms var(--ease); }
.ci-out { margin-top: 10px; padding: 12px; border-radius: 10px; background: var(--panel); font-size: 12px; color: var(--body); min-height: 64px; line-height: 1.7; }
.ci-out .ok { color: var(--ok-ink); }

/* Demo: latency chart */
.chart-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.chart-head .big { font: 600 28px var(--font-display); color: var(--ink); letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.chart-head .big small { font-size: 13px; color: var(--muted); font-weight: 500; margin-left: 4px; }
.legend { display: flex; gap: 14px; flex-wrap: wrap; }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 14px; height: 2px; background: var(--blue); display: inline-block; }
.legend i { background: var(--ink); height: 6px; border-radius: 3px; }
.legend i.edu { background: none; border: 1.5px dashed var(--violet); }
.legend i.now { width: 2px; height: 12px; background: var(--ok); border-radius: 0; }
.chart svg { width: 100%; height: auto; display: block; overflow: visible; }
.chart text { font: 10.5px var(--font-mono); fill: var(--muted); }
.now-dot { animation: pulse 1.6s ease-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes pulse { 50% { transform: scale(1.8); opacity: 0.5; } }

/* Demo: taxonomy */
.tax { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px 10px; }
@media (max-width: 640px) { .tax { grid-template-columns: repeat(2, 1fr); } }
.tax figure { margin: 0; display: grid; justify-items: center; gap: 6px; text-align: center; }
.tax .tile { width: 48px; height: 48px; border-radius: 12px; background: var(--panel); display: grid; place-items: center; color: var(--ink); transition: transform 250ms var(--ease), box-shadow 250ms; }
.tax .tile .si { width: 24px; height: 24px; }
.tax figure.hit .tile { transform: scale(1.12); box-shadow: 0 0 0 2px var(--ink); }
.tax figcaption { font: 10.5px var(--font-mono); color: var(--body); line-height: 1.3; word-break: break-word; }
.tax figcaption b { display: block; color: var(--muted); font-weight: 400; font-variant-numeric: tabular-nums; }

/* Demo: approval */
.action { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.action-top { display: flex; justify-content: space-between; align-items: center; padding: 10px 12px; border-bottom: 1px solid var(--line); font-size: 13px; color: var(--ink); font-weight: 500; }
.state { font: 500 10.5px var(--font-mono); padding: 2px 8px; border-radius: 999px; text-transform: uppercase; letter-spacing: 0.06em; }
.state.proposed { background: var(--amber-tint); color: var(--amber); }
.state.approved { background: var(--blue-tint); color: var(--blue); }
.state.executed { background: var(--ok-tint); color: var(--ok-ink); }
.state.rejected { background: var(--red-tint); color: var(--red); }
.action pre { margin: 0; padding: 10px 12px; font: 11.5px/1.6 var(--font-mono); color: var(--body); background: var(--panel); overflow-x: auto; }
.action pre .k { color: var(--violet); }
.action pre .s { color: var(--ok-ink); }
.action-btns { display: flex; gap: 8px; padding: 10px 12px; }
.action-btns button {
  flex: 1; height: 32px; border-radius: 999px; cursor: pointer; font: 500 12px var(--font-body);
  border: 1px solid var(--line); background: var(--card); color: var(--ink);
  transition: background 150ms, opacity 150ms;
}
.action-btns button.primary { background: var(--ink); color: var(--page); border-color: var(--ink); }
.action-btns button:disabled { opacity: 0.4; cursor: default; }

/* Demo: bench */
.bars { display: grid; gap: 12px; }
.bar-row { display: grid; gap: 4px; }
.bar-row .lbl { display: flex; justify-content: space-between; font-size: 12.5px; color: var(--ink); }
.bar-row .lbl span:last-child { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
.bar { height: 10px; border-radius: 999px; background: var(--panel); overflow: hidden; }
.bar span { display: block; height: 100%; width: 0; border-radius: 999px; transition: width 1100ms var(--ease); }
.scen { margin-top: 16px; display: grid; gap: 4px; font: 11.5px var(--font-mono); }
.scen div { display: grid; grid-template-columns: 1fr auto; padding: 5px 0; border-top: 1px solid var(--line); color: var(--body); }
.scen em { font-style: normal; color: var(--ok-ink); }

/* Demo: orbit */
.orbit { position: relative; width: 210px; height: 210px; margin: 0 auto; }
.ring { position: absolute; inset: 0; border: 1px dashed var(--line-strong); border-radius: 50%; animation: rot 26s linear infinite; }
.ring.inner { inset: 48px; animation-duration: 16s; animation-direction: reverse; }
.orb { position: absolute; width: 0; height: 0; }
.orb span {
  position: absolute; translate: -50% -50%;
  display: grid; place-items: center; width: 38px; height: 38px;
  border-radius: 999px; color: var(--ink); background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow);
  animation: rot 26s linear infinite reverse;
}
.orb .si { width: 18px; height: 18px; }
.ring.inner .orb span { animation-duration: 16s; animation-direction: normal; }
.core { position: absolute; inset: 72px; overflow: hidden; border: 2px solid var(--card); box-shadow: var(--shadow); border-radius: 50%; background: var(--ink); color: var(--page); display: grid; place-items: center; }
.core img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }
@keyframes rot { to { transform: rotate(360deg); } }
.orbit-cap { text-align: center; margin-top: 16px; }

/* Stats */
.stats { margin-top: 96px; display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; }
.stat { background: var(--panel); border-radius: var(--radius-card); padding: 24px 20px; }
.stat b { display: block; font: 700 48px/1 var(--font-display); color: var(--ink); letter-spacing: -0.04em; font-variant-numeric: tabular-nums; }
.stat span { display: block; margin-top: 10px; font-size: 13px; color: var(--body); }

/* CTA */
.cta-row { display: flex; flex-direction: column; align-items: center; gap: 16px; text-align: center; padding-block: 88px 96px; }
.cta-h { font-size: clamp(28px, 4vw, 40px); font-weight: 700; letter-spacing: -0.03em; line-height: 1.1; }
.cta-p { max-width: 52ch; font-size: 16px; margin-bottom: 8px; text-wrap: balance; }
.cta {
  display: inline-flex; align-items: center; gap: 10px; height: 52px; padding: 0 26px;
  border-radius: 999px; background: var(--cta-bg); color: var(--cta-ink);
  font-size: 16px; font-weight: 500;
  transition: transform 180ms var(--ease);
}
.cta:hover { transform: translateY(-2px); }

/* Footer */
.footer { padding: 56px 40px 28px; margin-bottom: 12px; }
.f-cols { display: grid; grid-template-columns: 1.4fr repeat(4, 1fr); gap: 32px; }
.f-brand { color: var(--ink); display: grid; gap: 14px; align-content: start; }
.f-brand svg { height: 26px; width: auto; }
.f-brand p { color: var(--body); font-size: 14px; max-width: 30ch; }
.f-col h5 { margin: 0 0 14px; font: 500 11px var(--font-mono); text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); }
.f-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
.f-col a { font-size: 14px; color: var(--body); transition: color 150ms; }
.f-col a:hover { color: var(--ink); }
.f-bottom { margin-top: 48px; padding-top: 20px; border-top: 1px solid var(--line); display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: 13px; color: var(--muted); }

@media (min-width: 961px) {
  .menu { display: none !important; }
}
/* Logo strip */
.logo-strip { list-style: none; margin: 28px auto 0; padding: 0; max-width: 900px; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.logo-strip li {
  display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 12px 0 10px; border-radius: 999px;
  background: var(--card); border: 1px solid var(--line); font-size: 13px; color: var(--ink);
}
.logo-strip .si { width: 16px; height: 16px; }

/* Shared tags */
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.tag {
  display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border-radius: 999px;
  background: var(--panel); border: 1px solid var(--line); font-size: 12px; color: var(--ink);
}
.tag .si { width: 13px; height: 13px; }
.cap-card .tags { gap: 10px; }
.cap-card .tags > .si { width: 22px; height: 22px; }
.btn .si { width: 15px; height: 15px; margin-right: 8px; }
.link { color: var(--ink); font-size: 13px; font-weight: 500; text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: 3px; }
.link:hover { text-decoration-color: var(--ink); }

/* Page shells */
.page-hero { margin-top: 12px; padding: 136px 20px 64px; }
.page-hero .wrap { max-width: 980px; }
.page-title { margin-top: 18px; font-size: clamp(36px, 5.6vw, 64px); font-weight: 700; letter-spacing: -0.035em; line-height: 1.04; }
.page-sub { margin-top: 16px; max-width: 62ch; font-size: 17px; color: var(--body); text-wrap: pretty; }
.hero-btns.left { justify-content: flex-start; }
.page { display: grid; gap: 88px; padding-block: 72px 120px; }
.page section { display: grid; gap: 24px; }
.sec-head { display: grid; gap: 14px; justify-items: start; }
.sec-head h2 { font-size: clamp(26px, 3.4vw, 36px); font-weight: 700; letter-spacing: -0.03em; line-height: 1.1; }
.two-col { grid-template-columns: 1fr 1fr; gap: 40px !important; }

/* About */
.about-hero { display: grid; grid-template-columns: 260px 1fr; gap: 48px; align-items: center; }
.portrait { width: 100%; max-width: 260px; height: auto; aspect-ratio: 1; object-fit: cover; border-radius: 24px; border: 1px solid var(--line); background: var(--card); }
.about-intro .page-title { margin-top: 16px; }
.meta-list { list-style: none; margin: 18px 0 0; padding: 0; display: grid; gap: 6px; font-family: var(--font-mono); font-size: 12.5px; color: var(--muted); }
.split { grid-template-columns: 200px 1fr; gap: 32px !important; }
.prose { display: grid; gap: 16px; max-width: 66ch; font-size: 16px; }
.prose .lead { font-size: 20px; line-height: 1.5; color: var(--ink); letter-spacing: -0.01em; text-wrap: pretty; }
.xp { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; }
.xp-item { display: grid; grid-template-columns: 104px 1fr; gap: 20px; padding: 24px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-card); }
.org {
  width: 64px; height: 64px; border-radius: 14px; background: #ffffff; border: 1px solid #e4e4e7;
  display: grid; place-items: center; padding: 9px; overflow: hidden;
}
.org img { width: 100%; height: 100%; object-fit: contain; }
.org-si .si { width: 60%; height: 60%; }
.xp-item .org { width: 104px; height: 60px; padding: 8px 10px; }
.org-sm { width: 48px; height: 48px; border-radius: 12px; padding: 7px; }
.xp-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; }
.xp-top h3 { font-size: 18px; font-weight: 600; letter-spacing: -0.01em; }
.xp-co { color: var(--body); font-size: 14px; }
.xp-date { font-family: var(--font-mono); font-size: 12px; color: var(--ink); padding: 3px 10px; border-radius: 999px; background: var(--panel); white-space: nowrap; }
.xp-body > .cap { display: block; margin-top: 4px; }
.xp-points { margin: 14px 0 0; padding-left: 18px; display: grid; gap: 8px; font-size: 14.5px; max-width: 78ch; }
.xp-points b { color: var(--ink); font-weight: 600; }
.cred-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.cred-list li { display: grid; grid-template-columns: 48px 1fr; gap: 14px; align-items: center; padding: 14px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-card); }
.cred-list h3 { font-size: 15px; font-weight: 600; }
.cred-list p { font-size: 13.5px; }
.cap-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.cap-card { padding: 24px; background: var(--panel); border-radius: var(--radius-card); display: grid; gap: 10px; align-content: start; }
.cap-card h3 { font-size: 18px; font-weight: 600; }
.cap-card p { font-size: 14.5px; }

/* Projects */
.proj-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.proj { display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-card); overflow: hidden; transition: border-color 180ms var(--ease), transform 180ms var(--ease); }
.proj:hover { border-color: var(--line-strong); transform: translateY(-2px); }
.proj-shot { display: block; aspect-ratio: 16 / 10; background: var(--panel); border-bottom: 1px solid var(--line); overflow: hidden; }
.proj-shot img { width: 100%; height: 100%; object-fit: cover; object-position: top; display: block; transition: transform 400ms var(--ease); }
.proj:hover .proj-shot img { transform: scale(1.02); }
.proj-shot--text { display: grid; place-content: center; text-align: center; gap: 6px; background: var(--ink); color: var(--page); }
.proj-shot--text span { font: 700 clamp(32px, 4vw, 48px)/1 var(--font-display); letter-spacing: -0.03em; }
.proj-shot--text small { font: 12px var(--font-mono); opacity: 0.7; }
.proj-body { padding: 22px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.proj-body h3 { font-size: 21px; font-weight: 600; letter-spacing: -0.02em; }
.proj-body p { font-size: 14.5px; }
.proj-body .tags { margin-top: 4px; }
.proj-meta { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.status-pill { display: inline-flex; align-items: center; gap: 6px; padding: 2px 10px; border-radius: 999px; background: var(--ok-tint); color: var(--ok-ink); font: 500 11px var(--font-mono); text-transform: uppercase; letter-spacing: 0.06em; }
.status-pill::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--ok); }
.status-pill.founder { background: var(--violet-tint); color: var(--violet); }
.status-pill.founder::before { background: var(--violet); }
.proj-links { display: flex; flex-wrap: wrap; gap: 8px; margin-top: auto; padding-top: 10px; }
.proj-wide { grid-column: span 2; display: grid; grid-template-columns: 1.2fr 1fr; }
.proj-wide .proj-shot { border-bottom: 0; border-right: 1px solid var(--line); aspect-ratio: auto; min-height: 280px; }
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.steps li { padding: 22px; background: var(--panel); border-radius: var(--radius-card); display: grid; gap: 10px; align-content: start; }
.step-n { width: 30px; height: 30px; border-radius: 999px; display: grid; place-items: center; background: var(--ink); color: var(--page); font: 600 13px var(--font-mono); }
.steps h3 { font-size: 17px; font-weight: 600; }
.steps p { font-size: 14px; }

/* Insights */
.post-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.post { display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-card); overflow: hidden; transition: border-color 180ms var(--ease), transform 180ms var(--ease); }
.post:hover { border-color: var(--line-strong); transform: translateY(-2px); }
.post img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; display: block; border-bottom: 1px solid var(--line); background: var(--panel); }
.post-body { padding: 16px; display: grid; gap: 8px; align-content: start; }
.post-body h3 { font-size: 16px; font-weight: 600; line-height: 1.3; letter-spacing: -0.01em; }
.post-body p { font-size: 14px; }
.post-feature { grid-column: span 4; display: grid; grid-template-columns: 1.3fr 1fr; }
.post-feature img { aspect-ratio: auto; height: 100%; border-bottom: 0; border-right: 1px solid var(--line); }
.post-feature .post-body { padding: 28px; align-content: center; }
.post-feature h3 { font-size: clamp(22px, 2.6vw, 30px); letter-spacing: -0.02em; }
.post-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.post-tags span { font: 11px var(--font-mono); color: var(--muted); padding: 2px 8px; border-radius: 999px; border: 1px solid var(--line); }
.notes { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.notes li { padding: 18px; background: var(--panel); border-radius: var(--radius-card); display: grid; gap: 10px; align-content: start; }
.notes p { color: var(--ink); font-size: 15px; line-height: 1.5; }
.notes-more { justify-self: start; }

/* Uses */
.uses-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.use { padding: 24px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-card); display: grid; gap: 10px !important; align-content: start; }
.use h3 { font-size: 18px; font-weight: 600; }
.use p { font-size: 14.5px; }
.use-list { list-style: none; margin: 6px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.use-list li { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 12px 0 10px; border-radius: 10px; background: var(--panel); font-size: 13.5px; color: var(--ink); }
.use-list .si { width: 17px; height: 17px; }
.si-text { width: 17px; height: 17px; border-radius: 4px; display: grid; place-items: center; background: var(--ink); color: var(--page); font: 700 8px var(--font-mono); }

/* Contact */
.contact-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 16px; }
.contact-card { padding: 22px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-card); display: grid; gap: 8px; align-content: start; transition: border-color 180ms var(--ease); }
a.contact-card:hover { border-color: var(--line-strong); }
.contact-card h3 { font-size: 17px; font-weight: 600; word-break: break-word; }
.contact-card .mono-h { font-family: var(--font-mono); font-size: 14px; font-weight: 500; }
.contact-main { background: var(--panel); border-color: transparent; }
.contact-main h3 { font-size: 26px; letter-spacing: -0.02em; }
.contact-main .btn { justify-self: start; margin-top: 8px; }
.tile-lg { width: 40px; height: 40px; border-radius: 12px; background: var(--panel); display: grid; place-items: center; margin-bottom: 6px; }
.tile-lg .si { width: 20px; height: 20px; }
.check-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.check-list li { display: grid; grid-template-columns: 20px 1fr; gap: 10px; font-size: 15px; color: var(--ink); }
.check-list li::before { content: ''; width: 18px; height: 18px; margin-top: 3px; border-radius: 50%; background: var(--ok-tint) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M3 6.2l2 2 4-4.4' fill='none' stroke='%2322c55e' stroke-width='1.8'/%3E%3C/svg%3E") center / 12px no-repeat; }

@media (max-width: 960px) {
  .about-hero { grid-template-columns: 180px 1fr; gap: 28px; }
  .split, .two-col { grid-template-columns: 1fr; }
  .cap-grid, .steps, .notes { grid-template-columns: 1fr 1fr; }
  .post-grid { grid-template-columns: 1fr 1fr; }
  .post-feature { grid-column: span 2; }
  .contact-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .page-hero { padding: 108px 4px 44px; }
  .about-hero { grid-template-columns: 1fr; }
  .portrait { max-width: 180px; }
  .xp-item { grid-template-columns: 1fr; padding: 18px; }
  .proj-grid, .uses-grid, .cap-grid, .steps, .notes, .post-grid, .contact-grid { grid-template-columns: 1fr; }
  .proj-wide, .post-feature { grid-column: auto; grid-template-columns: 1fr; }
  .proj-wide .proj-shot { border-right: 0; border-bottom: 1px solid var(--line); min-height: 0; aspect-ratio: 16 / 10; }
  .post-feature img { border-right: 0; border-bottom: 1px solid var(--line); aspect-ratio: 16 / 9; height: auto; }
  .page { gap: 64px; padding-block: 48px 88px; }
}

@media (max-width: 960px) {
  .nav-links { display: none; }
  .icon-btn.menu-btn { display: grid; }
  .nav-right { margin-left: auto; }
  .bento { grid-template-columns: 1fr 1fr; }
  .stack { grid-column: span 2; }
  .tall { grid-column: span 2; }
  .tall .demo { min-height: 0; }
  .stats { grid-template-columns: repeat(3, 1fr); }
  .f-cols { grid-template-columns: repeat(2, 1fr); }
  .f-brand { grid-column: span 2; }
}
@media (max-width: 640px) {
  .search, .count-pill span.lbl { display: none; }
  .nav { gap: 8px; padding-left: 16px; }
  .hero { padding-top: 112px; }
  .bento { grid-template-columns: 1fr; }
  .stack, .tall { grid-column: auto; }
  .stats { grid-template-columns: 1fr 1fr; }
  .stats .stat:last-child { grid-column: span 2; }
  .footer { padding: 40px 20px 24px; }
  .f-cols { grid-template-columns: 1fr 1fr; }
  .shot { height: 220px; }
  .rrf { grid-template-columns: 1fr 1fr; }
  .rrf .fused { grid-column: span 2; }
  .cmd select { padding: 0 24px 0 10px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ---------- Site additions ---------- */
.skip-link {
  position: fixed; left: 16px; top: -60px; z-index: 50; padding: 10px 16px; border-radius: 999px;
  background: var(--ink); color: var(--page); font-weight: 500; transition: top 150ms var(--ease);
}
.skip-link:focus { top: calc(env(safe-area-inset-top, 0px) + 12px); }
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
main { display: block; }
.f-col h2 { margin: 0 0 14px; font: 500 11px var(--font-mono); text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); }
.f-brand svg { height: 26px; width: auto; color: var(--ink); }

/* Search */
.search { position: relative; }
.search-field {
  display: flex; align-items: center; gap: 8px;
  height: 36px; padding: 0 6px 0 12px;
  background: var(--panel); border: 1px solid var(--line); border-radius: 999px;
}
.search-field svg { width: 14px; height: 14px; color: var(--muted); flex: none; }
.search-field input {
  width: 128px; border: 0; background: transparent; outline: none;
  font: inherit; font-size: 13px; color: var(--ink);
}
.search-field input::placeholder { color: var(--muted); }
.search-field:focus-within { border-color: var(--line-strong); }
.search-results {
  position: absolute; right: 0; top: calc(100% + 10px); width: 320px; max-height: 60vh; overflow-y: auto;
  list-style: none; margin: 0; padding: 6px;
  background: var(--card); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow);
}
.search-results a { display: grid; gap: 1px; padding: 9px 12px; border-radius: 10px; }
.search-results a b { color: var(--ink); font-weight: 500; font-size: 13.5px; }
.search-results a span { color: var(--muted); font-size: 12.5px; }
.search-results [aria-selected="true"] a, .search-results a:hover { background: var(--panel); }
.search-results .empty { padding: 10px 12px; color: var(--muted); font-size: 13px; }
.lang-btn { font: 600 11px var(--font-mono); letter-spacing: 0.04em; }

/* Contact */
.contact-layout { display: grid; grid-template-columns: 1fr 1.25fr; gap: 20px; align-items: start; }
.contact-stack { display: grid; gap: 16px; }
.contact-tabs { display: inline-flex; gap: 4px; padding: 4px; border-radius: 999px; background: var(--panel); border: 1px solid var(--line); justify-self: start; }
.contact-tab {
  height: 36px; padding: 0 16px; border-radius: 999px; border: 0; cursor: pointer;
  background: transparent; color: var(--body); font: 500 14px var(--font-body);
  transition: background 150ms var(--ease), color 150ms var(--ease);
}
.contact-tab.is-active { background: var(--card); color: var(--ink); box-shadow: var(--shadow); }
.contact-pane { display: grid; }
.form-card, .calendar-shell { padding: 22px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-card); }
.calendar-shell { padding: 8px; min-height: 120px; }
.calendar-frame { min-height: 0; }
#cal-inline-embed { min-height: 620px; border-radius: 12px; overflow: hidden; }
.calendar-mobile-toggle { display: none; width: 100%; justify-content: center; }
.calendar-shell.is-collapsed .calendar-mobile-toggle { display: inline-flex; }
@media (max-width: 767.98px) {
  .calendar-shell.is-collapsed .calendar-frame { display: none; }
}
.hidden { display: none !important; }
.field-group { display: grid; gap: 16px; }
.field { display: grid; gap: 6px; }
.field label { font-size: 13px; font-weight: 500; color: var(--ink); }
.field input, .field select, .field textarea {
  width: 100%; padding: 10px 14px; border-radius: 12px; border: 1px solid var(--line);
  background: var(--page); color: var(--ink); font: inherit; font-size: 15px;
  transition: border-color 150ms var(--ease);
}
.field textarea { min-height: 140px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--ink); }
.field [aria-invalid="true"] { border-color: var(--red); }
.field-error { display: none; color: var(--red); font-size: 12.5px; }
.field-error.active { display: block; }
.field-meta { display: flex; justify-content: space-between; gap: 12px; font-size: 12.5px; color: var(--muted); }
.status-box { padding: 12px 14px; border-radius: 12px; font-size: 14px; background: var(--panel); color: var(--body); }
.status-box.is-error { background: var(--red-tint); color: var(--red); }
.status-box.is-success { background: var(--ok-tint); color: var(--ok-ink); }
.btn-block { width: 100%; justify-content: center; }
button.btn { cursor: pointer; font-family: inherit; }
.btn[disabled] { opacity: 0.5; cursor: progress; }
#recaptcha-container:empty { display: none; }

/* Not found */
.nf { display: grid; justify-items: center; gap: 16px; text-align: center; }
.nf .code { font: 600 13px var(--font-mono); color: var(--muted); }

@media (max-width: 960px) {
  .contact-layout { grid-template-columns: 1fr; }
}

/* Headings reused at a lower level for document outline */
.rrf h3 { margin: 0 0 6px; font-weight: 500; font-size: 10.5px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); font-family: var(--font-mono); }
.contact-card h2 { font-size: 17px; font-weight: 600; word-break: break-word; }
.contact-card .mono-h { font-family: var(--font-mono); font-size: 14px; font-weight: 500; }

/* FAQ */
.faq { display: grid; gap: 10px; max-width: 820px; }
.faq details { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-card); padding: 0 20px; }
.faq summary { cursor: pointer; list-style: none; padding: 16px 0; font-weight: 600; color: var(--ink); display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; font-family: var(--font-mono); color: var(--muted); }
.faq details[open] summary::after { content: '–'; }
.faq details p { margin: 0 0 16px; font-size: 15px; max-width: 70ch; }

/* Insights index */
.notes-grid { grid-template-columns: repeat(3, 1fr); }
.notes-grid .post-body p { font-size: 13.5px; }

/* Post page */
.post-hero .wrap { max-width: 820px; }
.crumbs { display: flex; gap: 8px; align-items: center; font-size: 13px; color: var(--muted); margin-bottom: 18px; }
.crumbs a { color: var(--body); }
.crumbs a:hover { color: var(--ink); }
.post-title { font-size: clamp(30px, 4.6vw, 52px); }
.byline { display: flex; align-items: center; gap: 12px; margin-top: 24px; }
.byline img { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; }
.byline b { display: block; color: var(--ink); font-weight: 600; font-size: 14px; }
.post-wrap { max-width: 820px; padding-block: 48px 24px; display: grid; gap: 28px; }
.post-cover { margin: 0; border-radius: var(--radius-card); overflow: hidden; border: 1px solid var(--line); background: var(--panel); }
.post-cover img { width: 100%; height: auto; display: block; }
.post-prose { max-width: 70ch; font-size: 17px; line-height: 1.75; color: var(--ink); gap: 0; display: block; }
.post-prose > * + * { margin-top: 1.1em; }
.post-prose p, .post-prose li { color: var(--ink); }
.post-prose h2, .post-prose h3, .post-prose h4 { margin-top: 1.8em; font-size: 1.35em; letter-spacing: -0.02em; line-height: 1.25; }
.post-prose h4 { font-size: 1.15em; }
.post-prose ul, .post-prose ol { padding-left: 1.3em; }
.post-prose li + li { margin-top: 0.4em; }
.post-prose a { color: var(--ink); text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: 3px; }
.post-prose blockquote { margin-left: 0; padding: 4px 0 4px 18px; border-left: 3px solid var(--line-strong); color: var(--body); font-style: italic; }
.post-prose figure { margin-inline: 0; }
.post-prose img { height: auto; border-radius: 12px; border: 1px solid var(--line); }
.post-prose figcaption { margin-top: 8px; font-size: 13px; color: var(--muted); text-align: center; }
.post-prose pre { overflow-x: auto; padding: 16px; border-radius: 12px; background: var(--panel); font-size: 14px; line-height: 1.6; }
.post-prose code { font-family: var(--font-mono); font-size: 0.9em; }
.post-prose :not(pre) > code { padding: 1px 6px; border-radius: 6px; background: var(--panel); }
.post-prose hr { border: 0; border-top: 1px solid var(--line); }
.post-note { font-style: italic; }
.post-foot { display: flex; gap: 16px; flex-wrap: wrap; }
.post-sources { padding: 20px; border-radius: var(--radius-card); background: var(--panel); }
.post-sources h2 { margin: 0 0 10px; font: 500 11px var(--font-mono); text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); }
.post-sources ul { margin: 0; padding-left: 18px; display: grid; gap: 6px; font-size: 14px; }
.post-sources a { color: var(--ink); word-break: break-all; }
.author-box { display: grid; grid-template-columns: 64px 1fr auto; gap: 16px; align-items: center; padding: 20px; border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--card); }
.author-box img { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; }
.author-box b { color: var(--ink); }
.author-box p { font-size: 14px; }
.related { padding-top: 24px; }
.related .link { justify-self: start; }

@media (max-width: 960px) {
  .notes-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .notes-grid { grid-template-columns: 1fr; }
  .author-box { grid-template-columns: 48px 1fr; }
  .author-box img { width: 48px; height: 48px; }
  .author-box .btn { grid-column: 1 / -1; justify-content: center; }
  .post-prose { font-size: 16px; }
}
.post img, .proj-shot img { height: auto; }
.post img { height: auto; aspect-ratio: 16 / 9; }
.post-cover { display: grid; place-items: center; }
.post-cover img { width: auto; max-width: 100%; max-height: 560px; }

/* ---------- Mobile fixes ---------- */
/* Long code blocks and URLs in articles must not widen the page. */
.post-wrap { grid-template-columns: minmax(0, 1fr); }
.post-wrap > * { min-width: 0; }
.post-prose { overflow-wrap: anywhere; }
.post-prose pre { max-width: 100%; overflow-wrap: normal; }
.post-prose figure, .post-prose img { max-width: 100%; }

/* Comfortable tap targets for standalone links. */
.proj-links .btn, .steps .link, .contact-card .link, .post-foot .link, .related > section > .link,
.cred-list .link, .notes-more {
  display: inline-flex; align-items: center; min-height: 44px;
}

.xp-item { grid-template-columns: 120px 1fr; }
.xp-item .org { width: 120px; height: 60px; padding: 8px 10px; }

@media (max-width: 960px) {
  .contact-layout > .contact-stack:last-child { order: -1; }
}

@media (max-width: 640px) {
  .display .chip { display: none; }
  .badge .note { display: none; }
  .badge .status { white-space: nowrap; }
  .toolbar .t-ico { display: none; }
  .chart { overflow-x: auto; -webkit-overflow-scrolling: touch; margin-inline: -4px; padding-bottom: 4px; }
  .chart svg { min-width: 540px; }
  .menu-foot { flex-wrap: wrap; }
  .menu-foot .btn-dark { flex-basis: 100%; }
  .calendar-shell { min-height: 0; }
  .xp-item { grid-template-columns: 1fr; }
  .xp-item .org { width: 150px; height: 64px; }
  .contact-tabs { justify-self: stretch; }
  .contact-tab { flex: 1; }
  .tax { grid-template-columns: repeat(3, 1fr); }
  .tax figure:last-child { grid-column: 2; }
}
