/* tld.werd.sh — design tokens, layout, components. Light by default, dark via system or toggle. */

@font-face {
  font-family: "IBM Plex Sans";
  src: url("/static/fonts/ibm-plex-sans-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Sans";
  src: url("/static/fonts/ibm-plex-sans-500.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Sans";
  src: url("/static/fonts/ibm-plex-sans-600.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Sans";
  src: url("/static/fonts/ibm-plex-sans-700.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "JetBrains Mono";
  src: url("/static/fonts/jetbrains-mono-var.woff2") format("woff2");
  font-weight: 100 800;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: light;
  --bg: #ffffff;
  --bg-subtle: #f8fafc;
  --surface: #ffffff;
  --surface-2: #f1f5f9;
  --fg: #0f172a;
  --fg-muted: #475569;
  --fg-faint: #64748b;
  --border: #e2e8f0;
  --border-strong: #cbd5e1;
  --accent: #15803d;
  --accent-hover: #166534;
  --accent-fg: #ffffff;
  --accent-soft: #dcfce7;
  --accent-soft-fg: #14532d;
  --warn: #b45309;
  --warn-soft: #fef3c7;
  --danger: #b91c1c;
  --danger-soft: #fee2e2;
  --code-bg: #0f172a;
  --code-fg: #e2e8f0;
  --code-dim: #94a3b8;
  --code-green: #4ade80;
  --ring: #15803d;
  --shadow: 0 1px 2px rgb(15 23 42 / 0.06), 0 4px 16px rgb(15 23 42 / 0.06);
  --glow: none;

  --font-sans: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --radius: 10px;
  --radius-lg: 16px;
  --container: 72rem;
  --gutter: 1rem;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #0b1120;
    --bg-subtle: #0f172a;
    --surface: #111a2e;
    --surface-2: #1b2336;
    --fg: #f8fafc;
    --fg-muted: #cbd5e1;
    --fg-faint: #94a3b8;
    --border: #233047;
    --border-strong: #3b4a63;
    --accent: #22c55e;
    --accent-hover: #4ade80;
    --accent-fg: #0f172a;
    --accent-soft: rgb(34 197 94 / 0.14);
    --accent-soft-fg: #86efac;
    --warn: #fbbf24;
    --warn-soft: rgb(251 191 36 / 0.14);
    --danger: #f87171;
    --danger-soft: rgb(248 113 113 / 0.14);
    --code-bg: #060b16;
    --ring: #4ade80;
    --shadow: 0 1px 2px rgb(0 0 0 / 0.4), 0 8px 24px rgb(0 0 0 / 0.35);
    --glow: 0 0 24px rgb(34 197 94 / 0.18);
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0b1120;
  --bg-subtle: #0f172a;
  --surface: #111a2e;
  --surface-2: #1b2336;
  --fg: #f8fafc;
  --fg-muted: #cbd5e1;
  --fg-faint: #94a3b8;
  --border: #233047;
  --border-strong: #3b4a63;
  --accent: #22c55e;
  --accent-hover: #4ade80;
  --accent-fg: #0f172a;
  --accent-soft: rgb(34 197 94 / 0.14);
  --accent-soft-fg: #86efac;
  --warn: #fbbf24;
  --warn-soft: rgb(251 191 36 / 0.14);
  --danger: #f87171;
  --danger-soft: rgb(248 113 113 / 0.14);
  --code-bg: #060b16;
  --ring: #4ade80;
  --shadow: 0 1px 2px rgb(0 0 0 / 0.4), 0 8px 24px rgb(0 0 0 / 0.35);
  --glow: 0 0 24px rgb(34 197 94 / 0.18);
}

/* ---------- Base ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 5rem; /* anchors land below the sticky header */
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 400 1rem/1.6 var(--font-sans);
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  transition: background-color 200ms var(--ease), color 200ms var(--ease);
}
main {
  flex: 1;
}
img,
svg {
  display: block;
  max-width: 100%;
}
a {
  color: var(--accent);
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
}
a:hover {
  color: var(--accent-hover);
}
:focus-visible {
  outline: 2px solid var(--ring);
  outline-offset: 2px;
  border-radius: 4px;
}
h1,
h2,
h3 {
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin: 0 0 0.5em;
  text-wrap: balance;
}
h1 {
  font-size: clamp(2.25rem, 5.5vw, 3.5rem);
  font-weight: 700;
}
h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 600;
}
h3 {
  font-size: 1.125rem;
  font-weight: 600;
}
p {
  margin: 0 0 1em;
}
code,
kbd,
pre {
  font-family: var(--font-mono);
  font-size: 0.9em;
}
:not(pre) > code {
  background: var(--surface-2);
  border: 1px solid var(--border);
  padding: 0.1em 0.35em;
  border-radius: 6px;
  word-break: break-word;
}
pre {
  background: var(--code-bg);
  color: var(--code-fg);
  padding: 1rem 1.25rem;
  border-radius: var(--radius);
  overflow-x: auto;
  line-height: 1.55;
  margin: 0 0 1.25em;
}
hr {
  border: 0;
  border-top: 1px solid var(--border);
  margin: 2.5rem 0;
}
.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.skip-link {
  position: absolute;
  left: 1rem;
  top: -3rem;
  background: var(--accent);
  color: var(--accent-fg);
  padding: 0.5rem 0.75rem;
  border-radius: 8px;
  z-index: 100;
  text-decoration: none;
}
.skip-link:focus {
  top: 0.75rem;
}
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
}
@media (min-width: 768px) {
  :root {
    --gutter: 2rem;
  }
}
.icon-fill {
  width: 1.125rem;
  height: 1.125rem;
  fill: currentColor;
}
.icon {
  width: 1.125rem;
  height: 1.125rem;
  flex: none;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.muted {
  color: var(--fg-muted);
}
.mono {
  font-family: var(--font-mono);
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: saturate(180%) blur(10px);
  -webkit-backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 1rem;
  height: 4rem;
}
.brand {
  display: inline-flex;
  align-items: baseline;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--fg);
  text-decoration: none;
  letter-spacing: -0.02em;
}
.brand:hover {
  color: var(--fg);
}
.brand-dot {
  color: var(--accent);
}
.brand-logo {
  height: 30px;
  width: auto;
}
.brand-tile {
  fill: #0f172a;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .brand-tile {
    fill: #1e293b;
  }
}
:root[data-theme="dark"] .brand-tile {
  fill: #1e293b;
}
.nav {
  display: none;
  gap: 0.25rem;
  margin-left: 1rem;
}
.nav a,
.mobile-nav a {
  color: var(--fg-muted);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  padding: 0.5rem 0.75rem;
  border-radius: 8px;
  transition: color 150ms var(--ease), background-color 150ms var(--ease);
}
.nav a:hover,
.mobile-nav a:hover {
  color: var(--fg);
  background: var(--surface-2);
}
.nav a[aria-current="page"],
.mobile-nav a[aria-current="page"] {
  color: var(--fg);
  background: var(--surface-2);
}
.header-actions {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  margin-left: auto;
}
.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  min-width: 44px;
  min-height: 44px;
  padding: 0 0.6rem;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 10px;
  color: var(--fg-muted);
  font: 500 0.875rem var(--font-sans);
  cursor: pointer;
  text-decoration: none;
  transition: color 150ms var(--ease), background-color 150ms var(--ease),
    border-color 150ms var(--ease);
}
.icon-btn:hover {
  color: var(--fg);
  background: var(--surface-2);
}
.theme-toggle .theme-label {
  display: none;
}
.theme-toggle [data-icon] {
  display: none;
}
.theme-toggle[data-mode="system"] [data-icon="system"],
.theme-toggle[data-mode="light"] [data-icon="light"],
.theme-toggle[data-mode="dark"] [data-icon="dark"] {
  display: block;
}
.mobile-nav {
  position: relative;
}
.mobile-nav summary {
  list-style: none;
}
.mobile-nav summary::-webkit-details-marker {
  display: none;
}
.mobile-nav-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 0.5rem);
  min-width: 13rem;
  padding: 0.5rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
}
.mobile-nav-panel a {
  padding: 0.7rem 0.75rem;
}
@media (min-width: 860px) {
  .nav {
    display: flex;
  }
  .mobile-nav {
    display: none;
  }
  .theme-toggle .theme-label {
    display: inline;
  }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 44px;
  padding: 0 1.1rem;
  border-radius: 10px;
  border: 1px solid transparent;
  font: 600 0.95rem var(--font-sans);
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  transition: background-color 150ms var(--ease), color 150ms var(--ease),
    border-color 150ms var(--ease), transform 100ms var(--ease);
}
.btn:active {
  transform: translateY(1px);
}
.btn-primary {
  background: var(--accent);
  color: var(--accent-fg);
}
.btn-primary:hover {
  background: var(--accent-hover);
  color: var(--accent-fg);
}
.btn-secondary {
  background: var(--surface);
  color: var(--fg);
  border-color: var(--border-strong);
}
.btn-secondary:hover {
  background: var(--surface-2);
  color: var(--fg);
}
.btn-sm {
  min-height: 36px;
  padding: 0 0.8rem;
  font-size: 0.875rem;
}
.btn[disabled] {
  opacity: 0.65;
  cursor: progress;
}

/* ---------- Hero + search ---------- */
.hero {
  position: relative;
  padding: 4rem 0 3rem;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: -45% 0 auto;
  height: 32rem;
  background: radial-gradient(closest-side, var(--accent-soft), transparent);
  opacity: 0.9;
  pointer-events: none;
  z-index: -1;
}
@media (min-width: 768px) {
  .hero {
    padding: 6rem 0 4rem;
  }
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font: 500 0.8rem var(--font-mono);
  color: var(--accent-soft-fg);
  background: var(--accent-soft);
  padding: 0.3rem 0.7rem;
  border-radius: 999px;
  margin-bottom: 1.25rem;
}
.eyebrow::before {
  content: "";
  width: 0.45rem;
  height: 0.45rem;
  border-radius: 50%;
  background: var(--accent);
}
.hero .container {
  text-align: center;
}
.hero h1 {
  max-width: 18ch;
  margin-inline: auto;
}
.hero h1 .hl {
  color: var(--accent);
}
.lead {
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  color: var(--fg-muted);
  max-width: 40rem;
  margin: 0 auto 2rem;
}
.search-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow), var(--glow);
  padding: 1rem;
  max-width: 52rem;
  margin-inline: auto;
  text-align: left;
}
@media (min-width: 768px) {
  .search-card {
    padding: 1.25rem;
  }
}
.field-label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 0.4rem;
}
.search-row {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
@media (min-width: 640px) {
  .search-row {
    flex-direction: row;
  }
}
.input-wrap {
  position: relative;
  flex: 1;
}
.input-wrap .icon {
  position: absolute;
  left: 0.9rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--fg-faint);
  pointer-events: none;
}
.input {
  width: 100%;
  min-height: 48px;
  padding: 0.65rem 0.9rem;
  background: var(--bg);
  color: var(--fg);
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  font: 400 1rem var(--font-sans);
  transition: border-color 150ms var(--ease), box-shadow 150ms var(--ease);
}
.input-wrap .input {
  padding-left: 2.6rem;
  font-family: var(--font-mono);
}
.input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.input[aria-invalid="true"] {
  border-color: var(--danger);
}
.search-row .btn {
  min-height: 48px;
  padding: 0 1.4rem;
}
.helper {
  font-size: 0.85rem;
  color: var(--fg-faint);
  margin: 0.5rem 0 0;
}
.field-error {
  font-size: 0.875rem;
  color: var(--danger);
  margin: 0.5rem 0 0;
}
.search-options {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1.25rem;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px dashed var(--border);
}
.search-options fieldset {
  border: 0;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
}
.search-options legend {
  float: left;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--fg-muted);
  margin-right: 0.35rem;
}
.chip input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.chip span {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 0.75rem;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  font: 500 0.8rem var(--font-mono);
  color: var(--fg-muted);
  cursor: pointer;
  user-select: none;
  transition: all 150ms var(--ease);
}
.chip span:hover {
  color: var(--fg);
  border-color: var(--fg-faint);
}
.chip input:checked + span {
  background: var(--accent-soft);
  border-color: var(--accent);
  color: var(--accent-soft-fg);
}
.chip input:focus-visible + span {
  outline: 2px solid var(--ring);
  outline-offset: 2px;
}
.keywords {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex: 1;
  min-width: 14rem;
}
.keywords label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--fg-muted);
  white-space: nowrap;
}
.keywords .input {
  min-height: 40px;
  font-size: 0.9rem;
}

/* ---------- Results ---------- */
.results {
  max-width: 52rem;
  margin: 1.5rem auto 0;
  text-align: left;
}
.results[hidden] {
  display: none;
}
.results-summary {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
  font-size: 0.95rem;
  color: var(--fg-muted);
}
.results-summary strong {
  color: var(--fg);
}
.result-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.6rem;
}
.result {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 0.5rem 1rem;
  align-items: center;
  padding: 0.9rem 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  animation: rise 240ms var(--ease) both;
}
.result:hover {
  border-color: var(--border-strong);
}
@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
}
.result-main {
  min-width: 0;
}
.result-thumb {
  width: 44px;
  height: 44px;
  border-radius: 10px;
}
@media (max-width: 639px) {
  .result {
    grid-template-columns: auto 1fr;
  }
  .result-side {
    grid-column: 1 / -1;
    justify-content: flex-end;
  }
}
.logos-panel {
  grid-column: 1 / -1;
  border-top: 1px dashed var(--border);
  padding-top: 0.9rem;
  margin-top: 0.25rem;
}
.logos-panel[hidden] {
  display: none;
}
.logos-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.75rem;
}
.logos-head p {
  margin: 0;
  font-size: 0.85rem;
  color: var(--fg-muted);
}
.logo-grid {
  display: grid;
  gap: 0.75rem;
}
@media (min-width: 640px) {
  .logo-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
.logo-card {
  margin: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface);
}
.logo-art {
  /* logos are drawn for light backgrounds: show them on a white artboard in both themes */
  background: #ffffff;
  height: 110px;
  display: grid;
  place-items: center;
  padding: 0.75rem;
}
.logo-art img {
  max-height: 86px;
  max-width: 100%;
  width: auto;
  height: auto;
}
.logo-card figcaption {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  font-size: 0.85rem;
  color: var(--fg-muted);
}
.logo-actions {
  display: flex;
  gap: 0.4rem;
}
.result-domain {
  font: 600 1.05rem var(--font-mono);
  overflow-wrap: anywhere;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}
.result-meta {
  font-size: 0.875rem;
  color: var(--fg-muted);
  margin-top: 0.2rem;
}
.result-notes {
  font-size: 0.8rem;
  color: var(--fg-faint);
  margin-top: 0.25rem;
}
.result-side {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.score {
  display: none;
  flex-direction: column;
  align-items: center;
  font: 600 1rem var(--font-mono);
  min-width: 3rem;
}
.score small {
  font: 500 0.65rem var(--font-sans);
  color: var(--fg-faint);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
@media (min-width: 640px) {
  .score {
    display: flex;
  }
}
.pill {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font: 600 0.7rem var(--font-sans);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.2rem 0.5rem;
  border-radius: 999px;
}
.pill-available {
  background: var(--accent-soft);
  color: var(--accent-soft-fg);
}
.pill-premium {
  background: var(--warn-soft);
  color: var(--warn);
}
.pill-taken {
  background: var(--surface-2);
  color: var(--fg-faint);
}
.pill-error {
  background: var(--danger-soft);
  color: var(--danger);
}
.taken-group {
  margin-top: 1rem;
}
.taken-group summary {
  cursor: pointer;
  font-size: 0.9rem;
  color: var(--fg-muted);
  padding: 0.4rem 0;
  min-height: 44px;
  display: flex;
  align-items: center;
}
.taken-list {
  list-style: none;
  padding: 0;
  margin: 0.25rem 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.taken-list li {
  font: 500 0.85rem var(--font-mono);
  color: var(--fg-faint);
  background: var(--surface-2);
  border-radius: 8px;
  padding: 0.3rem 0.6rem;
  text-decoration: line-through;
  text-decoration-color: var(--border-strong);
}
.disclosure-note {
  font-size: 0.8rem;
  color: var(--fg-faint);
  margin-top: 1rem;
}
.skeleton {
  height: 4.4rem;
  border-radius: var(--radius);
  background: linear-gradient(90deg, var(--surface-2), var(--surface), var(--surface-2));
  background-size: 200% 100%;
  animation: shimmer 1.2s linear infinite;
}
@keyframes shimmer {
  to {
    background-position: -200% 0;
  }
}
.alert {
  border: 1px solid var(--danger);
  background: var(--danger-soft);
  color: var(--fg);
  border-radius: var(--radius);
  padding: 0.9rem 1rem;
  font-size: 0.95rem;
}
.empty {
  padding: 1.25rem;
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius);
  color: var(--fg-muted);
}

/* ---------- Sections ---------- */
.section {
  padding: 4rem 0;
}
.section-alt {
  background: var(--bg-subtle);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.section-head {
  max-width: 40rem;
  margin-bottom: 2.5rem;
}
.section-head p {
  color: var(--fg-muted);
  font-size: 1.05rem;
}
.grid {
  display: grid;
  gap: 1rem;
}
@media (min-width: 640px) {
  .grid-2 {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 960px) {
  .grid-3 {
    grid-template-columns: repeat(3, 1fr);
  }
  .grid-4 {
    grid-template-columns: repeat(4, 1fr);
  }
}
@media (min-width: 640px) and (max-width: 959px) {
  .grid-3,
  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
}
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  transition: border-color 150ms var(--ease), transform 150ms var(--ease);
}
.card p {
  color: var(--fg-muted);
  margin: 0;
  font-size: 0.95rem;
}
.card-icon {
  width: 2.5rem;
  height: 2.5rem;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: var(--accent-soft);
  color: var(--accent-soft-fg);
  margin-bottom: 1rem;
}
.step-num {
  font: 600 0.8rem var(--font-mono);
  color: var(--accent);
  margin-bottom: 0.5rem;
  display: block;
}
.split {
  display: grid;
  gap: 2rem;
  align-items: center;
}
@media (min-width: 960px) {
  .split {
    grid-template-columns: 1fr 1.1fr;
    gap: 3rem;
  }
}
.terminal {
  background: var(--code-bg);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.terminal-bar {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.6rem 0.8rem;
  border-bottom: 1px solid rgb(148 163 184 / 0.15);
}
.terminal-bar i {
  width: 0.65rem;
  height: 0.65rem;
  border-radius: 50%;
  background: #334155;
}
.terminal-bar .copy {
  margin-left: auto;
  color: var(--code-dim);
  min-height: 32px;
  min-width: 32px;
}
.terminal-bar .copy:hover {
  color: var(--code-fg);
  background: rgb(148 163 184 / 0.12);
}
.terminal pre {
  margin: 0;
  border-radius: 0;
  background: transparent;
  font-size: 0.85rem;
}
.t-dim {
  color: var(--code-dim);
}
.t-ok {
  color: var(--code-green);
}
.t-prompt {
  color: var(--code-green);
  user-select: none;
}
.checks {
  list-style: none;
  padding: 0;
  margin: 1.25rem 0 1.75rem;
  display: grid;
  gap: 0.6rem;
}
.checks li {
  display: flex;
  gap: 0.6rem;
  color: var(--fg-muted);
}
.checks .icon {
  color: var(--accent);
  margin-top: 0.25rem;
}
.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* FAQ */
.faq {
  max-width: 48rem;
  display: grid;
  gap: 0.6rem;
}
.faq details {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0 1.1rem;
}
.faq summary {
  cursor: pointer;
  font-weight: 600;
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  list-style: none;
}
.faq summary::-webkit-details-marker {
  display: none;
}
.faq summary::after {
  content: "+";
  font: 500 1.25rem var(--font-mono);
  color: var(--fg-faint);
  transition: transform 200ms var(--ease);
}
.faq details[open] summary::after {
  transform: rotate(45deg);
}
.faq details p {
  color: var(--fg-muted);
  margin: 0 0 1rem;
}

/* ---------- Prose pages (about, privacy, blog) ---------- */
.page-head {
  padding: 3.5rem 0 1.5rem;
}
.page-head p {
  color: var(--fg-muted);
  font-size: 1.1rem;
  max-width: 42rem;
}
.prose {
  max-width: 44rem;
  padding-bottom: 4rem;
}
.prose h2 {
  margin-top: 2.25rem;
  font-size: 1.5rem;
}
.prose h3 {
  margin-top: 1.75rem;
}
.prose ul,
.prose ol {
  padding-left: 1.25rem;
  margin: 0 0 1.25em;
}
.prose li {
  margin-bottom: 0.4em;
}
.prose table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 1.5em;
  font-size: 0.95rem;
  display: block;
  overflow-x: auto;
}
.prose th,
.prose td {
  text-align: left;
  padding: 0.55rem 0.75rem;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}
.prose th {
  font-weight: 600;
  background: var(--surface-2);
}
.prose blockquote {
  margin: 0 0 1.25em;
  padding: 0.9rem 1.1rem;
  border-left: 3px solid var(--accent);
  background: var(--surface-2);
  border-radius: 0 var(--radius) var(--radius) 0;
  color: var(--fg-muted);
}
.prose blockquote p:last-child {
  margin: 0;
}
.post-meta {
  font: 500 0.85rem var(--font-mono);
  color: var(--fg-faint);
  margin-bottom: 0.75rem;
}
.post-list {
  list-style: none;
  padding: 0;
  margin: 0 0 4rem;
  display: grid;
  gap: 1rem;
  max-width: 48rem;
}
.post-card {
  display: block;
  padding: 1.5rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  text-decoration: none;
  color: var(--fg);
  transition: border-color 150ms var(--ease), transform 150ms var(--ease);
}
.post-card:hover {
  color: var(--fg);
  border-color: var(--accent);
  transform: translateY(-2px);
}
.post-card h2 {
  font-size: 1.25rem;
  margin-bottom: 0.35rem;
}
.post-card p {
  color: var(--fg-muted);
  margin: 0;
}
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.9rem;
  margin-bottom: 1rem;
  text-decoration: none;
}

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--border);
  background: var(--bg-subtle);
  padding: 3rem 0 2rem;
  font-size: 0.9rem;
}
.footer-grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: repeat(2, 1fr);
}
@media (min-width: 768px) {
  .footer-grid {
    grid-template-columns: 2fr 1fr 1fr 1fr;
  }
}
.footer-brand {
  grid-column: 1 / -1;
}
@media (min-width: 768px) {
  .footer-brand {
    grid-column: auto;
  }
}
.footer-brand p {
  color: var(--fg-muted);
  max-width: 22rem;
  margin-top: 0.75rem;
}
.site-footer h2 {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--fg-faint);
  margin-bottom: 0.75rem;
}
.site-footer ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.15rem;
}
.site-footer ul a {
  color: var(--fg-muted);
  text-decoration: none;
  display: inline-block;
  padding: 0.3rem 0;
}
.site-footer ul a:hover {
  color: var(--fg);
}
.footer-legal {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  color: var(--fg-faint);
  font-size: 0.8rem;
  display: grid;
  gap: 0.4rem;
}
.footer-legal p {
  margin: 0;
}

/* ---------- Motion preferences ---------- */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
