/* base.css — design tokens and primitives shared by the landing page and the app.
   System fonts only: no font host learns who visits (GU Analyser's ASVS finding). */

:root {
  --bg: #f4f6f9;
  --surface: #ffffff;
  --surface-2: #f8fafc;
  --ink: #0f1b2d;
  --ink-2: #334155;
  --muted: #64748b;
  --line: #e2e8f0;
  --line-strong: #cbd5e1;
  --brand: #0f766e;
  --brand-strong: #0b5f58;
  --brand-soft: #e6f4f2;
  --on-brand: #ffffff;
  --ok: #15803d;
  --ok-soft: #e8f6ed;
  --bad: #b91c1c;
  --bad-soft: #fdecec;
  --warn: #b45309;
  --warn-soft: #fef3e2;
  --shadow-1: 0 1px 2px rgba(15, 27, 45, .06), 0 1px 3px rgba(15, 27, 45, .05);
  --shadow-2: 0 4px 12px rgba(15, 27, 45, .08), 0 2px 4px rgba(15, 27, 45, .04);
  --radius: 12px;
  --radius-sm: 8px;
  --font: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", Consolas, monospace;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0a111e;
    --surface: #111a2b;
    --surface-2: #162136;
    --ink: #e8eef6;
    --ink-2: #c3cedc;
    --muted: #8b9bb1;
    --line: #22304a;
    --line-strong: #31425f;
    --brand: #2dd4bf;
    --brand-strong: #5eead4;
    --brand-soft: #0f2f33;
    --on-brand: #04201d;
    --ok: #4ade80;
    --ok-soft: #10301e;
    --bad: #f87171;
    --bad-soft: #3a1618;
    --warn: #fbbf24;
    --warn-soft: #36270a;
    --shadow-1: 0 1px 2px rgba(0, 0, 0, .4);
    --shadow-2: 0 6px 18px rgba(0, 0, 0, .45);
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.55 var(--font);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4 { margin: 0; line-height: 1.2; letter-spacing: -.015em; font-weight: 650; }
p { margin: 0; }
a { color: var(--brand); text-underline-offset: 3px; }
a:hover { color: var(--brand-strong); }
button, input, select { font: inherit; color: inherit; }
img, canvas { display: block; max-width: 100%; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; border-radius: 4px; }
.num { font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.container { width: 100%; max-width: 1160px; margin: 0 auto; padding: 0 20px; }

/* Buttons: 44px tall, so they pass the tap-target rule on a phone. */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 0 18px;
  border: 1px solid var(--line-strong); border-radius: var(--radius-sm);
  background: var(--surface); color: var(--ink);
  font-weight: 600; font-size: 15px; text-decoration: none; cursor: pointer;
  transition: background .15s, border-color .15s, transform .05s;
}
.btn:hover { background: var(--surface-2); color: var(--ink); }
.btn:active { transform: translateY(1px); }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.btn-primary { background: var(--brand); border-color: var(--brand); color: var(--on-brand); }
.btn-primary:hover { background: var(--brand-strong); border-color: var(--brand-strong); color: var(--on-brand); }
.btn-ghost { border-color: transparent; background: transparent; }
.btn-lg { min-height: 52px; padding: 0 24px; font-size: 16px; }
.btn-sm { min-height: 36px; padding: 0 12px; font-size: 14px; }

.card {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow-1);
}

.tag {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 2px 9px; border-radius: 999px;
  background: var(--surface-2); border: 1px solid var(--line);
  color: var(--ink-2); font-size: 12.5px; font-weight: 600; white-space: nowrap;
}
.tag-brand { background: var(--brand-soft); border-color: transparent; color: var(--brand-strong); }
.tag-warn { background: var(--warn-soft); border-color: transparent; color: var(--warn); }

.brand-mark { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; font-size: 17px; color: var(--ink); text-decoration: none; letter-spacing: -.01em; }
.brand-mark svg { width: 28px; height: 28px; flex: none; }

.field { display: grid; gap: 6px; }
.field label { font-size: 14px; font-weight: 600; color: var(--ink-2); }
.input {
  min-height: 44px; padding: 0 12px; width: 100%;
  border: 1px solid var(--line-strong); border-radius: var(--radius-sm);
  background: var(--surface); color: var(--ink);
}
.input:focus { outline: 2px solid var(--brand); outline-offset: 0; border-color: var(--brand); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
