/* =====================================================================
   CADASTECH · Central de Cadastro — tokens, reset e tipografia
   Identidade: teal #35969B + azul #1A63A3 (cruz do logo) e o "traço de
   circuito" do logo como elemento gráfico (indicador ativo, divisores).
   ===================================================================== */

:root {
  /* marca */
  --teal: #35969b;
  --teal-600: #2b7d82;
  --teal-50: #e6f3f3;
  --blue: #1a63a3;
  --blue-600: #154f83;
  --blue-50: #e7f0f8;

  /* superfícies (claro) */
  --bg: #f2f5f7;
  --surface: #ffffff;
  --surface-2: #f7f9fb;
  --surface-3: #eef2f5;
  --line: #dbe2e8;
  --line-strong: #c4cfd8;
  --ink: #12212e;
  --ink-2: #33475a;
  --muted: #5d6e7e;
  --faint: #8a99a7;

  /* estados */
  --ok: #23845a;
  --ok-50: #e5f4ec;
  --warn: #b77a10;
  --warn-50: #fbf1dc;
  --err: #c0392b;
  --err-50: #fbe9e7;
  --info: var(--blue);
  --info-50: var(--blue-50);

  --focus: 0 0 0 3px rgba(53, 150, 155, .35);
  --shadow-1: 0 1px 2px rgba(18, 33, 46, .06);
  --shadow-2: 0 8px 28px rgba(18, 33, 46, .12);
  --shadow-3: 0 18px 60px rgba(18, 33, 46, .22);

  --r-s: 6px;
  --r-m: 10px;
  --r-l: 16px;

  --font: "IBM Plex Sans", "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
  --font-cond: "IBM Plex Sans Condensed", "IBM Plex Sans", "Arial Narrow", system-ui, sans-serif;

  --sidebar: 264px;
  --sidebar-rail: 68px;
  --topbar: 60px;

  color-scheme: light;
}

/* tema escuro — automático pelo sistema (data-theme ausente/auto) */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="claro"]) {
    --teal: #4fb3b8;
    --teal-600: #6cc4c8;
    --teal-50: #12343a;
    --blue: #5b9be0;
    --blue-600: #7fb2ea;
    --blue-50: #13283f;
    --bg: #0d1822;
    --surface: #132230;
    --surface-2: #172a39;
    --surface-3: #1c3244;
    --line: #233a4d;
    --line-strong: #2f4a60;
    --ink: #e5eef5;
    --ink-2: #c3d2de;
    --muted: #93a7b8;
    --faint: #6d8396;
    --ok: #4cc28d;  --ok-50: #10332a;
    --warn: #e2a93b; --warn-50: #3a2d10;
    --err: #ef6b5d; --err-50: #3d1a17;
    --shadow-1: 0 1px 2px rgba(0, 0, 0, .3);
    --shadow-2: 0 10px 30px rgba(0, 0, 0, .35);
    --shadow-3: 0 18px 60px rgba(0, 0, 0, .55);
    color-scheme: dark;
  }
}
:root[data-theme="escuro"] {
  --teal: #4fb3b8;
  --teal-600: #6cc4c8;
  --teal-50: #12343a;
  --blue: #5b9be0;
  --blue-600: #7fb2ea;
  --blue-50: #13283f;
  --bg: #0d1822;
  --surface: #132230;
  --surface-2: #172a39;
  --surface-3: #1c3244;
  --line: #233a4d;
  --line-strong: #2f4a60;
  --ink: #e5eef5;
  --ink-2: #c3d2de;
  --muted: #93a7b8;
  --faint: #6d8396;
  --ok: #4cc28d;  --ok-50: #10332a;
  --warn: #e2a93b; --warn-50: #3a2d10;
  --err: #ef6b5d; --err-50: #3d1a17;
  --shadow-1: 0 1px 2px rgba(0, 0, 0, .3);
  --shadow-2: 0 10px 30px rgba(0, 0, 0, .35);
  --shadow-3: 0 18px 60px rgba(0, 0, 0, .55);
  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-family: var(--font);
  font-size: 14px;
  line-height: 1.5;
  font-feature-settings: "tnum" 1, "lnum" 1;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 { margin: 0; color: var(--ink); line-height: 1.2; font-weight: 600; letter-spacing: -.01em; }
h1 { font-size: 1.5rem; }
h2 { font-size: 1.15rem; }
h3 { font-size: 1rem; }
p { margin: 0 0 .75em; }

a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }

button, input, select, textarea { font: inherit; color: inherit; }

:focus-visible { outline: none; box-shadow: var(--focus); border-radius: var(--r-s); }

svg.i { width: 18px; height: 18px; flex: 0 0 auto; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
svg.i.sm { width: 15px; height: 15px; }
svg.i.lg { width: 22px; height: 22px; }

.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.num { font-variant-numeric: tabular-nums; text-align: right; white-space: nowrap; }
.nowrap { white-space: nowrap; }
.hidden { display: none !important; }
.pos { color: var(--ok); }
.neg { color: var(--err); }

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