:root {
  --bg: #ffffff;
  --bg-surface: #f9f9f9;
  --bg-code: #f3f3f6;
  --border: #e4e4e7;
  --border-subtle: rgba(0,0,0,0.07);
  --text: #09090b;
  --text-muted: #52525b;
  --text-dim: #a1a1aa;
  --accent: #9378ff;
  --accent-dim: rgba(147,120,255,0.08);
  --accent-border: rgba(147,120,255,0.3);
  --serif: 'Playfair Display', Georgia, serif;
  --mono: 'JetBrains Mono', 'Courier New', monospace;
  --sans: 'DM Sans', system-ui, sans-serif;
  /* code syntax — light mode */
  --c-method: #6d28d9;
  --c-path: #09090b;
  --c-header-key: #1d4ed8;
  --c-header-val: #b45309;
  --c-status: #dc2626;
  --c-json-key: #1d4ed8;
  --c-json-str: #b45309;
  --c-json-num: #c2410c;
  --c-keyword: #6d28d9;
  --c-string: #b45309;
  --c-func: #16803c;
  --c-comment: #9ca3af;
}

[data-theme="dark"] {
  --bg: #09090b;
  --bg-surface: #111113;
  --bg-code: #0d0d0f;
  --border: #27272a;
  --border-subtle: rgba(255,255,255,0.06);
  --text: #f4f4f5;
  --text-muted: #71717a;
  --text-dim: #52525b;
  --accent: #9378ff;
  --accent-dim: rgba(147,120,255,0.1);
  --accent-border: rgba(147,120,255,0.3);
  /* code syntax — dark mode */
  --c-method: #4ade80;
  --c-path: #f4f4f5;
  --c-header-key: #93c5fd;
  --c-header-val: #fcd34d;
  --c-status: #f87171;
  --c-json-key: #93c5fd;
  --c-json-str: #fcd34d;
  --c-json-num: #fb923c;
  --c-keyword: #c084fc;
  --c-string: #fcd34d;
  --c-func: #4ade80;
  --c-comment: #52525b;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
a:hover { color: var(--accent); }

/* ── NAV ─────────────────────────────────────────── */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
  height: 56px;
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-subtle);
}

[data-theme="dark"] nav {
  background: rgba(9,9,11,0.85);
}

/* ── THEME TOGGLE ────────────────────────────────── */
.theme-toggle {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: none;
  cursor: pointer;
  color: var(--text-muted);
  transition: border-color 0.15s, background 0.15s, color 0.15s;
  flex-shrink: 0;
}
.theme-toggle:hover {
  border-color: var(--accent-border);
  background: var(--accent-dim);
  color: var(--text);
}
.icon-sun, .icon-moon { width: 15px; height: 15px; }
[data-theme="dark"] .icon-sun { display: none; }
.icon-moon { display: none; }
[data-theme="dark"] .icon-moon { display: block; }

.nav-logo {
  font-family: var(--mono);
  font-weight: 600;
  font-size: 1rem;
  letter-spacing: -0.02em;
  color: var(--text);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  list-style: none;
}

.nav-links a {
  font-size: 0.875rem;
  color: var(--text-muted);
  transition: color 0.15s;
}
.nav-links a:hover { color: var(--text); }

.nav-cta {
  font-size: 0.8125rem;
  font-weight: 500;
  padding: 0.4rem 0.875rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text) !important;
  transition: border-color 0.15s, background 0.15s;
}
.nav-cta:hover {
  border-color: var(--accent-border);
  background: var(--accent-dim);
  color: var(--text) !important;
}

/* ── LAYOUT ──────────────────────────────────────── */
.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 2rem;
}

section {
  padding: 5rem 0;
}

/* ── HERO ────────────────────────────────────────── */
#hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 56px;
  border-bottom: 1px solid var(--border-subtle);
}

.hero-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: center;
  width: 100%;
  min-width: 0;
}

.hero-text, .hero-code { min-width: 0; }

h1 {
  font-family: var(--serif);
  font-size: clamp(2.25rem, 4vw, 3.5rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin-bottom: 1.5rem;
}

.hero-sub {
  font-family: var(--mono);
  font-size: 0.9rem;
  line-height: 1.75;
  color: var(--text-muted);
  margin-bottom: 2rem;
  max-width: 480px;
}

.cta-group {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.625rem 1.25rem;
  background: var(--accent);
  color: #09090b;
  font-weight: 600;
  font-size: 0.875rem;
  border-radius: 6px;
  transition: opacity 0.15s;
}
.btn-primary:hover { opacity: 0.88; color: #09090b; }

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.625rem 1.25rem;
  border: 1px solid var(--border);
  color: var(--text);
  font-weight: 500;
  font-size: 0.875rem;
  border-radius: 6px;
  transition: border-color 0.15s, background 0.15s;
}
.btn-secondary:hover {
  border-color: var(--accent-border);
  background: var(--accent-dim);
  color: var(--text);
}

/* ── CODE WINDOW ─────────────────────────────────── */
.code-window {
  background: var(--bg-code);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  font-family: var(--mono);
  font-size: 0.8rem;
  line-height: 1.65;
}

.code-window-bar {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.625rem 1rem;
  background: var(--border);
  border-bottom: 1px solid var(--border);
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.dot-red { background: #ff5f57; }
.dot-yellow { background: #ffbd2e; }
.dot-green { background: #28c940; }

.code-window-label {
  font-size: 0.7rem;
  color: var(--text-dim);
  margin-left: 0.25rem;
}

.code-window pre {
  padding: 1.25rem 1.5rem;
  overflow-x: auto;
  white-space: pre;
}

.code-window code {
  font-family: var(--mono);
}

/* HTTP syntax highlighting */
.http-method { color: var(--c-method); font-weight: 600; }
.http-path { color: var(--c-path); }
.http-version { color: var(--text-dim); }
.http-header-key { color: var(--c-header-key); }
.http-header-val { color: var(--c-header-val); }
.http-status { color: var(--c-status); font-weight: 600; }
.http-status-ok { color: var(--c-method); font-weight: 600; }
.json-key { color: var(--c-json-key); }
.json-str { color: var(--c-json-str); }
.json-num { color: var(--c-json-num); }
.comment { color: var(--c-comment); font-style: italic; }

/* TS syntax */
.ts-keyword { color: var(--c-keyword); }
.ts-string { color: var(--c-string); }
.ts-func { color: var(--c-func); }
.ts-var { color: var(--c-path); }
.ts-comment { color: var(--c-comment); font-style: italic; }
.ts-template { color: var(--c-string); }
.ts-interp { color: var(--c-path); }

.code-caption {
  padding: 0.5rem 1.25rem 0.875rem;
  font-size: 0.75rem;
  color: var(--text-dim);
  font-family: var(--mono);
  border-top: 1px solid var(--border-subtle);
}

/* ── PROBLEM ─────────────────────────────────────── */
#problem {
  border-bottom: 1px solid var(--border-subtle);
}

.problem-editorial {
  font-family: var(--serif);
  font-size: clamp(1.5rem, 2.5vw, 2.25rem);
  line-height: 1.3;
  max-width: 720px;
  margin-bottom: 1.5rem;
}

.problem-editorial .ceiling {
  font-style: italic;
  color: var(--accent);
}

.problem-transition {
  font-size: 1rem;
  color: var(--text-muted);
  max-width: 620px;
  margin-bottom: 3rem;
}

.problem-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 2.5rem;
}

.problem-card {
  background: var(--bg);
  padding: 1.75rem;
}

.problem-card p {
  font-size: 0.9375rem;
  line-height: 1.7;
  color: var(--text-muted);
}

.problem-card strong {
  display: block;
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.625rem;
}

.problem-card p span.stuck {
  color: var(--text);
  font-weight: 500;
}

.problem-close {
  font-family: var(--serif);
  font-size: 1.125rem;
  line-height: 1.5;
  color: var(--text-muted);
  max-width: 600px;
}

.problem-close strong {
  color: var(--text);
  font-family: var(--serif);
}

/* ── HOW IT WORKS ────────────────────────────────── */
#how-it-works {
  border-bottom: 1px solid var(--border-subtle);
}

.section-header {
  margin-bottom: 3rem;
}

h2 {
  font-family: var(--serif);
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 0.75rem;
  letter-spacing: -0.02em;
}

.section-sub {
  font-size: 1rem;
  color: var(--text-muted);
  max-width: 560px;
  line-height: 1.65;
}

.layers-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
}

.layer-card {
  background: var(--bg);
  padding: 2rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
}

.layer-num {
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--text-dim);
  letter-spacing: 0.1em;
}

h3 {
  font-family: var(--sans);
  font-size: 1.0625rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.layer-body {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.65;
  flex: 1;
}

.layer-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem;
  margin-top: 0.5rem;
}

.tag {
  font-family: var(--mono);
  font-size: 0.675rem;
  padding: 0.2rem 0.5rem;
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-dim);
  background: var(--bg-surface);
}

/* ── INTEGRATION ─────────────────────────────────── */
#integration {
  border-bottom: 1px solid var(--border-subtle);
}

.integration-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
}

.integration-meta {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

.proof-points {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.proof-points li {
  font-family: var(--mono);
  font-size: 0.8125rem;
  color: var(--text-muted);
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
}

.proof-points li::before {
  content: '→';
  color: var(--accent);
  flex-shrink: 0;
}

.integration-note {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--text-dim);
  padding: 0.875rem 1rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--bg-surface);
  line-height: 1.6;
}

/* ── USE CASES ───────────────────────────────────── */
#use-cases {
  border-bottom: 1px solid var(--border-subtle);
}

.use-cases-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 2rem;
}

.use-case-card {
  background: var(--bg);
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
}

.use-case-label {
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--accent);
  letter-spacing: 0.06em;
}

.use-case-card h3 {
  font-size: 0.9375rem;
  font-weight: 600;
}

.use-case-card p {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.65;
}

.use-cases-close {
  font-family: var(--serif);
  font-size: 1.125rem;
  color: var(--text-muted);
  text-align: center;
  padding: 1rem 0;
}

.use-cases-close strong {
  color: var(--text);
  font-family: var(--serif);
}

/* ── TIER LIST ───────────────────────────────────── */
.tier-list {
  display: flex;
  flex-direction: column;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 2rem;
}

.tier-block {
  background: var(--bg);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
}

.tier-header {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  flex-wrap: wrap;
}

.tier-label {
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.tier-tam {
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--text-dim);
  padding: 0.15rem 0.5rem;
  border: 1px solid var(--border);
  border-radius: 4px;
  background: var(--bg-surface);
}

.tier-block h3 {
  font-size: 1rem;
  font-weight: 600;
}

.tier-block p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.75;
}

.tier-link {
  font-family: var(--mono);
  font-size: 0.8rem;
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  margin-top: 0.25rem;
  transition: opacity 0.15s;
}
.tier-link:hover { opacity: 0.75; color: var(--accent); }

/* ── OPEN STANDARDS ──────────────────────────────── */
#open-standards {
  border-bottom: 1px solid var(--border-subtle);
}

.standards-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
}

.standard-card {
  background: var(--bg);
  padding: 1.75rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
}

.standard-card strong {
  font-size: 0.9375rem;
  font-weight: 600;
  display: block;
}

.standard-card p {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.65;
}

.standard-card a {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--accent);
  display: inline-block;
  margin-top: 0.25rem;
}

/* ── OPEN SOURCE CTA ─────────────────────────────── */
#open-source {
  border-bottom: 1px solid var(--border-subtle);
  text-align: center;
}

.open-source-inner {
  max-width: 640px;
  margin: 0 auto;
}

.open-source-body {
  font-size: 1rem;
  color: var(--text-muted);
  line-height: 1.75;
  margin-bottom: 2rem;
}

.open-source-body p + p {
  margin-top: 1rem;
}

.github-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-weight: 500;
  font-size: 0.9375rem;
  transition: border-color 0.15s, background 0.15s;
  margin-bottom: 1.75rem;
}

.github-cta:hover {
  border-color: var(--accent-border);
  background: var(--accent-dim);
  color: var(--text);
}

.support-links {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.support-links a {
  font-size: 0.875rem;
  color: var(--text-dim);
  transition: color 0.15s;
}

.support-links a:hover { color: var(--text); }

/* ── FAQ ─────────────────────────────────────────── */
#faq {
  border-bottom: 1px solid var(--border-subtle);
}

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
}

details {
  background: var(--bg);
}

summary {
  padding: 1.25rem 1.5rem;
  font-weight: 500;
  font-size: 0.9375rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  list-style: none;
  transition: background 0.15s;
  user-select: none;
}

summary::-webkit-details-marker { display: none; }

summary::after {
  content: '+';
  font-family: var(--mono);
  color: var(--text-dim);
  font-size: 1.1rem;
  line-height: 1;
  flex-shrink: 0;
}

details[open] summary::after { content: '−'; }
details[open] summary { background: var(--bg-surface); }
summary:hover { background: var(--bg-surface); }

.faq-answer {
  padding: 0 1.5rem 1.5rem;
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.75;
  background: var(--bg-surface);
}

/* ── FOOTER ──────────────────────────────────────── */
footer {
  border-top: 1px solid var(--border-subtle);
  padding: 4rem 0 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem;
  padding-bottom: 3rem;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.footer-logo {
  font-family: var(--mono);
  font-weight: 600;
  font-size: 1rem;
}

.footer-tagline {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.footer-byline {
  font-size: 0.8125rem;
  color: var(--text-dim);
}

.footer-col h4 {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 1rem;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
}

.footer-links a {
  font-size: 0.875rem;
  color: var(--text-muted);
  transition: color 0.15s;
}
.footer-links a:hover { color: var(--text); }

.footer-bottom {
  border-top: 1px solid var(--border-subtle);
  padding: 1.25rem 0;
  font-size: 0.8125rem;
  color: var(--text-dim);
  line-height: 1.5;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.footer-legal { display: flex; gap: 1.25rem; }
.footer-legal a { color: var(--text-dim); text-decoration: none; }
.footer-legal a:hover { color: var(--text); }

/* ── DIVIDER ─────────────────────────────────────── */
.section-divider {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 0 0 3rem;
}
.section-divider span {
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--text-dim);
  letter-spacing: 0.1em;
  white-space: nowrap;
}
.section-divider::before,
.section-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

/* ── RESPONSIVE ──────────────────────────────────── */
@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr; gap: 3rem; }
  .layers-grid { grid-template-columns: 1fr 1fr; }
  .integration-inner { grid-template-columns: 1fr; }
  .use-cases-grid { grid-template-columns: 1fr 1fr; }
  .standards-grid { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr 1fr; }
}

@media (max-width: 600px) {
  html, body { overflow-x: hidden; max-width: 100%; }
  nav { padding: 0 1rem; gap: 0.5rem; }
  .nav-links { gap: 0.625rem; }
  .nav-links li:not(:last-child):not(:nth-last-child(2)) { display: none; }
  .nav-cta { font-size: 0.75rem; padding: 0.35rem 0.625rem; }
  .container { padding: 0 1rem; }
  section { padding: 3rem 0; }
  #hero { padding-top: 56px; min-height: auto; padding-bottom: 3rem; }
  h1 { font-size: 1.875rem; }
  .hero-sub { font-size: 0.875rem; }
  /* code window comes after text on mobile — no order flip */
  .hero-code { order: 1; width: 100%; min-width: 0; }
  .code-window { width: 100%; max-width: 100%; overflow: hidden; }
  .code-window pre { font-size: 0.7rem; padding: 1rem; overflow-x: auto; max-width: 100%; }
  .code-window pre code { display: block; min-width: 0; }
  .layers-grid { grid-template-columns: 1fr; }
  .problem-grid { grid-template-columns: 1fr; }
  .use-cases-grid { grid-template-columns: 1fr; }
  .standards-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 2rem; }
  .cta-group { flex-direction: column; }
  .btn-primary, .btn-secondary { width: 100%; justify-content: center; }
  .problem-editorial { font-size: 1.25rem; }
  h2 { font-size: 1.5rem; }
  .support-links { gap: 1rem; flex-direction: column; align-items: center; }
  .tier-block { padding: 1.5rem 1rem; }
  .tier-header { flex-direction: column; gap: 0.5rem; }
  .integration-inner { gap: 2rem; }
}

/* ── CONTACT FORM ────────────────────────────────── */
.contact-page-header {
  padding-top: 7rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid var(--border-subtle);
}

.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: start;
  padding: 4rem 0 6rem;
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.contact-info p {
  font-size: 0.9375rem;
  color: var(--text-muted);
  line-height: 1.75;
}

.contact-detail {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.contact-detail-label {
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--text-dim);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.contact-detail a {
  font-size: 0.9rem;
  color: var(--accent);
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
}

.form-label {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-muted);
}

.form-label span {
  color: var(--text-dim);
  font-weight: 400;
}

.form-input,
.form-textarea {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0.625rem 0.875rem;
  font-size: 0.9rem;
  font-family: var(--sans);
  color: var(--text);
  transition: border-color 0.15s;
  width: 100%;
}

.form-input:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--accent-border);
}

.form-textarea {
  min-height: 140px;
  resize: vertical;
  line-height: 1.6;
}

.form-honeypot {
  display: none !important;
}

.form-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.5rem;
  background: var(--accent);
  color: #09090b;
  font-weight: 600;
  font-size: 0.9rem;
  border-radius: 6px;
  border: none;
  cursor: pointer;
  transition: opacity 0.15s;
  font-family: var(--sans);
  align-self: flex-start;
}

.form-submit:hover { opacity: 0.88; }
.form-submit:disabled { opacity: 0.5; cursor: not-allowed; }

.form-success {
  padding: 2rem;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  font-family: var(--mono);
  font-size: 0.875rem;
  color: var(--text-muted);
}

@media (max-width: 900px) {
  .contact-layout { grid-template-columns: 1fr; gap: 3rem; }
}

/* ── BLOG ────────────────────────────────────────── */
.blog-header {
  padding-top: 7rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid var(--border-subtle);
}

.blog-grid {
  display: flex;
  flex-direction: column;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  margin: 3rem 0;
}

.blog-card {
  background: var(--bg);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
  transition: background 0.15s;
}
.blog-card:hover { background: var(--bg-surface); }

.blog-card-category {
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--accent);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.blog-card h2 {
  font-family: var(--serif);
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 0;
}

.blog-card p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.65;
}

.blog-card-meta {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--text-dim);
  margin-top: 0.25rem;
}

.blog-empty {
  text-align: center;
  padding: 4rem 2rem;
  color: var(--text-muted);
}

/* ── BLOG POST ───────────────────────────────────── */
.post-header {
  padding-top: 7rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid var(--border-subtle);
  max-width: 720px;
}

.post-category {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--accent);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.post-header h1 {
  font-size: clamp(1.75rem, 3.5vw, 2.75rem);
  margin-bottom: 1rem;
}

.post-description {
  font-size: 1.0625rem;
  color: var(--text-muted);
  line-height: 1.65;
  margin-bottom: 1.5rem;
}

.post-author {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.post-author a { color: var(--accent); }

.post-body {
  max-width: 720px;
  padding: 3rem 0 5rem;
  line-height: 1.8;
}

.post-body h2 { font-size: 1.5rem; margin: 2rem 0 0.75rem; }
.post-body h3 { font-size: 1.125rem; margin: 1.5rem 0 0.5rem; }
.post-body p { margin-bottom: 1.25rem; color: var(--text-muted); }
.post-body a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.post-body ul, .post-body ol { padding-left: 1.5rem; margin-bottom: 1.25rem; color: var(--text-muted); }
.post-body li { margin-bottom: 0.375rem; }
.post-body pre { background: var(--bg-code); border: 1px solid var(--border); border-radius: 8px; padding: 1.25rem; overflow-x: auto; margin-bottom: 1.25rem; }
.post-body code { font-family: var(--mono); font-size: 0.85em; }
.post-body pre code { font-size: 0.8rem; }
.post-body blockquote { border-left: 3px solid var(--accent-border); padding-left: 1.25rem; margin: 1.5rem 0; color: var(--text-muted); font-style: italic; }
