/* ===================================================================
   Temas do Painel de Alinhamento — só tokens. O layout (painel.css) usa
   apenas var(--…), então um tema novo é um bloco [data-tema="x"] aqui.

   Contrato de tokens (todos obrigatórios em cada tema):
     superfícies  --bg --bg-a --bg-b --surface --surface-2 --border --border-forte
     texto        --text --text-body --muted
     marca        --primary --primary-ink --grad --accent
     estados      --apto --apto-bg --inapto --inapto-bg --theta
                  --incerto --incerto-bg --contra --contra-bg
     forma        --radius --radius-sm --shadow --font-display --font-body
   =================================================================== */

/* 1. Claro (OAI) — a identidade original do Antigravity: slate + sky + teal */
:root, [data-tema="oai"] {
  --bg: #f8fafc; --bg-a: rgba(2,132,199,.07); --bg-b: rgba(13,148,136,.07);
  --surface: #ffffff; --surface-2: #f1f5f9; --border: #e2e8f0; --border-forte: #cbd5e1;
  --text: #0f172a; --text-body: #334155; --muted: #64748b;
  --primary: #0369a1; --primary-ink: #ffffff; --grad: linear-gradient(135deg, #0369a1 0%, #0f766e 100%); --accent: #0f766e;
  --apto: #047857; --apto-bg: #ecfdf5; --inapto: #b91c1c; --inapto-bg: #fef2f2; --theta: #94a3b8;
  --incerto: #b45309; --incerto-bg: #fffbeb; --contra: #6d28d9; --contra-bg: #f5f3ff;
  --radius: 18px; --radius-sm: 10px; --shadow: 0 10px 30px -8px rgba(15,23,42,.08), 0 2px 6px rgba(15,23,42,.04);
  --font-display: "Plus Jakarta Sans", Inter, system-ui, sans-serif; --font-body: Inter, system-ui, sans-serif;
  color-scheme: light;
}

/* 2. Noite — escuro neutro, para uso prolongado */
[data-tema="noite"] {
  --bg: #0b1120; --bg-a: rgba(56,189,248,.08); --bg-b: rgba(45,212,191,.06);
  --surface: #111a2e; --surface-2: #17223a; --border: #22304d; --border-forte: #334569;
  --text: #f1f5f9; --text-body: #cbd5e1; --muted: #8fa0bb;
  --primary: #38bdf8; --primary-ink: #04121f; --grad: linear-gradient(135deg, #38bdf8 0%, #2dd4bf 100%); --accent: #2dd4bf;
  --apto: #4ade80; --apto-bg: rgba(74,222,128,.10); --inapto: #f87171; --inapto-bg: rgba(248,113,113,.10); --theta: #52607a;
  --incerto: #fbbf24; --incerto-bg: rgba(251,191,36,.10); --contra: #c4b5fd; --contra-bg: rgba(196,181,253,.10);
  --shadow: 0 12px 30px -10px rgba(0,0,0,.55);
  color-scheme: dark;
}

/* 3. Boletim — âmbar/creme do boletim de editais e do widget "Compatível com você" */
[data-tema="boletim"] {
  --bg: #fef7e6; --bg-a: rgba(186,117,23,.08); --bg-b: rgba(140,85,16,.05);
  --surface: #fffdf7; --surface-2: #fdf1d8; --border: #f1dfb4; --border-forte: #e2c27e;
  --text: #2e1a01; --text-body: #4a3510; --muted: #7a6440;
  --primary: #9a4b05; --primary-ink: #ffffff; --grad: linear-gradient(135deg, #b45309 0%, #7c2d12 100%); --accent: #b45309;
  --apto: #15803d; --apto-bg: #effaf1; --inapto: #b91c1c; --inapto-bg: #fdf0ee; --theta: #c9b996;
  --incerto: #a16207; --incerto-bg: #fef6dc; --contra: #6d28d9; --contra-bg: #f6f1ff;
  --font-display: "Plus Jakarta Sans", Inter, system-ui, sans-serif;
  color-scheme: light;
}

/* 4. Açoriano — azulejo e cal: azul-açoriano sobre branco-linho, detalhe terracota */
[data-tema="acoriano"] {
  --bg: #f7f5ef; --bg-a: rgba(29,78,137,.07); --bg-b: rgba(178,74,43,.05);
  --surface: #fffefb; --surface-2: #eef2f8; --border: #dfe3ea; --border-forte: #b9c4d6;
  --text: #0f2240; --text-body: #2b3b55; --muted: #5d6b82;
  --primary: #1d4e89; --primary-ink: #ffffff; --grad: linear-gradient(135deg, #1d4e89 0%, #2f6db3 100%); --accent: #b24a2b;
  --apto: #1f7a4d; --apto-bg: #edf7f1; --inapto: #a83224; --inapto-bg: #fbeeec; --theta: #aeb8c8;
  --incerto: #9a5b0c; --incerto-bg: #fbf3e4; --contra: #5b3fa0; --contra-bg: #f3f0fa;
  --radius: 6px; --radius-sm: 4px; --shadow: 0 1px 0 #dfe3ea, 0 8px 20px -12px rgba(15,34,64,.18);
  --font-display: Georgia, "Times New Roman", serif;
  color-scheme: light;
}

/* 5. Oceano — Floripa à noite: azul-marinho profundo e turquesa */
[data-tema="oceano"] {
  --bg: #061a2b; --bg-a: rgba(20,184,166,.10); --bg-b: rgba(14,116,144,.14);
  --surface: #0a2539; --surface-2: #0e2f47; --border: #16405e; --border-forte: #22597f;
  --text: #e6f4f1; --text-body: #bcd9d6; --muted: #7fa6b0;
  --primary: #2dd4bf; --primary-ink: #042022; --grad: linear-gradient(135deg, #14b8a6 0%, #0ea5e9 100%); --accent: #fcd34d;
  --apto: #5eead4; --apto-bg: rgba(94,234,212,.10); --inapto: #fb7185; --inapto-bg: rgba(251,113,133,.10); --theta: #3d6278;
  --incerto: #fcd34d; --incerto-bg: rgba(252,211,77,.10); --contra: #c4b5fd; --contra-bg: rgba(196,181,253,.10);
  --shadow: 0 14px 34px -12px rgba(0,0,0,.6);
  color-scheme: dark;
}

/* 6. Alto contraste — acessibilidade (WCAG AAA no texto, bordas visíveis, sem gradiente) */
[data-tema="contraste"] {
  --bg: #ffffff; --bg-a: transparent; --bg-b: transparent;
  --surface: #ffffff; --surface-2: #f2f2f2; --border: #000000; --border-forte: #000000;
  --text: #000000; --text-body: #000000; --muted: #333333;
  --primary: #0000c8; --primary-ink: #ffffff; --grad: #0000c8; --accent: #000000;
  --apto: #005a00; --apto-bg: #ffffff; --inapto: #a00000; --inapto-bg: #ffffff; --theta: #7a7a7a;
  --incerto: #6b3d00; --incerto-bg: #ffffff; --contra: #4b0082; --contra-bg: #ffffff;
  --radius: 4px; --radius-sm: 2px; --shadow: none;
  color-scheme: light;
}

/* "auto": segue o sistema operacional (Claro OAI ↔ Noite) */
@media (prefers-color-scheme: dark) {
  [data-tema="auto"] {
    --bg: #0b1120; --bg-a: rgba(56,189,248,.08); --bg-b: rgba(45,212,191,.06);
    --surface: #111a2e; --surface-2: #17223a; --border: #22304d; --border-forte: #334569;
    --text: #f1f5f9; --text-body: #cbd5e1; --muted: #8fa0bb;
    --primary: #38bdf8; --primary-ink: #04121f; --grad: linear-gradient(135deg, #38bdf8 0%, #2dd4bf 100%); --accent: #2dd4bf;
    --apto: #4ade80; --apto-bg: rgba(74,222,128,.10); --inapto: #f87171; --inapto-bg: rgba(248,113,113,.10); --theta: #52607a;
    --incerto: #fbbf24; --incerto-bg: rgba(251,191,36,.10); --contra: #c4b5fd; --contra-bg: rgba(196,181,253,.10);
    --shadow: 0 12px 30px -10px rgba(0,0,0,.55);
    color-scheme: dark;
  }
}
