/* ============================================================
   Cleitinho é candidato? — estilos
   ============================================================ */

:root {
  --bg-0: #0a0c10;
  --bg-1: #0f1219;
  --bg-2: #151924;
  --surface: #171b26;
  --surface-2: #1d2230;
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.14);
  --text-0: #f4f5f7;
  --text-1: #c7cad3;
  --text-2: #8b909d;
  --text-3: #5c6272;

  --gold: #e3b04b;
  --gold-soft: #f2cd7e;

  --red: #ef4444;
  --red-strong: #dc2626;
  --red-glow: rgba(239, 68, 68, 0.35);
  --red-bg: #2a1013;

  --green: #22c55e;
  --green-strong: #16a34a;
  --green-glow: rgba(34, 197, 94, 0.32);
  --green-bg: #0f2417;

  --amber: #eab308;
  --amber-glow: rgba(234, 179, 8, 0.28);

  --radius-lg: 22px;
  --radius-md: 14px;
  --radius-sm: 9px;

  --font-display: "Sora", "Inter", system-ui, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  --shadow-lg: 0 24px 60px -20px rgba(0, 0, 0, 0.6);
  --shadow-md: 0 12px 30px -12px rgba(0, 0, 0, 0.55);
  color-scheme: dark;
}

/* Tema fixo e proposital em modo escuro — o card de status (vermelho/verde)
   é o protagonista visual da página, e um tema claro automático prejudicaria
   o contraste e o "drama" da narrativa política. Não há alternância de tema. */

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg-0);
  color: var(--text-0);
  font-family: var(--font-body);
  line-height: 1.5;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img, svg { display: block; max-width: 100%; }

a { color: inherit; }

/* ---------- Ambient background ---------- */
.bg-decor {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  background:
    radial-gradient(ellipse 80% 60% at 50% -10%, rgba(227, 176, 75, 0.10), transparent),
    linear-gradient(180deg, var(--bg-0), var(--bg-1) 40%, var(--bg-0));
}
.bg-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--border) 1px, transparent 1px),
    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 70% 50% at 50% 0%, black, transparent 75%);
  opacity: 0.5;
}
.bg-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.35;
  animation: float 22s ease-in-out infinite;
}
.bg-orb-1 {
  width: 520px; height: 520px;
  top: -160px; left: -120px;
  background: radial-gradient(circle, rgba(227, 176, 75, 0.55), transparent 70%);
}
.bg-orb-2 {
  width: 480px; height: 480px;
  bottom: -180px; right: -140px;
  background: radial-gradient(circle, rgba(90, 70, 200, 0.35), transparent 70%);
  animation-delay: -9s;
}
@keyframes float {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(30px, -24px) scale(1.06); }
}

/* ---------- Fold zone (primeira dobra: pintada com a cor do status) ---------- */
.fold-zone {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: linear-gradient(180deg, var(--bg-1), var(--bg-0));
  transition: background 0.8s ease;
}
.fold-zone[data-state="candidato"] {
  background:
    radial-gradient(ellipse 120% 60% at 50% -8%, rgba(255, 255, 255, 0.14), transparent 62%),
    linear-gradient(165deg, #d3453c 0%, #8c231f 78%, #6e1a17 100%);
}
.fold-zone[data-state="nao-candidato"] {
  background:
    radial-gradient(ellipse 120% 60% at 50% -8%, rgba(255, 255, 255, 0.15), transparent 62%),
    linear-gradient(165deg, #319457 0%, #1a6338 78%, #0f4526 100%);
}
.fold-decor {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 75% 55% at 50% 0%, black, transparent 78%);
  opacity: 0.6;
}
.fold-zone[data-state="loading"] .fold-decor { opacity: 0.25; }

/* ---------- Relógio (sem cabeçalho — fica no topo da própria dobra) ---------- */
.clock {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin: 0 0 22px;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.24);
  color: rgba(255, 255, 255, 0.85);
  max-width: 100%;
}
.clock-icon {
  flex-shrink: 0;
  opacity: 0.8;
}
.clock-date {
  font-size: 12px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.clock-sep { opacity: 0.5; flex-shrink: 0; }
.clock-time {
  font-family: var(--font-mono);
  font-size: 12.5px;
  font-weight: 500;
  color: #fff;
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
}

/* ---------- Layout ---------- */
main { max-width: 1080px; margin: 0 auto; padding: 0 24px; }

/* ---------- Hero (dentro da fold-zone, sem cartão — o fundo já é a cor) ---------- */
.fold {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 28px 24px 44px;
}
.eyebrow {
  margin: 0 0 10px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.75);
}
.hero-question {
  position: relative;
  font-family: var(--font-display);
  font-size: clamp(24px, 4vw, 38px);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.18;
  margin: 0 0 22px;
  max-width: 680px;
  color: #fff;
}
.br-desktop { display: inline; }
@media (max-width: 640px) { .br-desktop { display: none; } }

/* ---------- Veredito (linha "Até às HH:MM..., SIM/NÃO.") ---------- */
.verdict-line {
  position: relative;
  margin: 0 0 20px;
  font-family: var(--font-display);
  font-size: clamp(20px, 3vw, 28px);
  font-weight: 600;
  color: rgba(255, 255, 255, 0.92);
  max-width: 620px;
}
.verdict-word {
  display: inline-block;
  margin-left: 10px;
  padding: 6px 20px;
  border-radius: 10px;
  background: #fff;
  color: var(--text-0);
  font-weight: 800;
  letter-spacing: 0.01em;
  box-shadow: 0 8px 20px -8px rgba(0, 0, 0, 0.4);
}
/* Vermelho quando a resposta é SIM, verde quando é NÃO — mesma lógica de cor do resto da página */
.fold-zone[data-state="candidato"] .verdict-word { color: var(--red-strong); }
.fold-zone[data-state="nao-candidato"] .verdict-word { color: var(--green-strong); }

.emoji-big {
  position: relative;
  font-size: clamp(88px, 13vw, 140px);
  line-height: 1;
  margin-bottom: 20px;
  filter: drop-shadow(0 10px 28px rgba(0, 0, 0, 0.35));
  animation: pop 0.5s cubic-bezier(.2, 1.4, .4, 1);
}
@keyframes pop {
  0% { transform: scale(0.6); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}
.status-summary {
  position: relative;
  margin: 0 0 14px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 15px;
  line-height: 1.55;
  max-width: 560px;
}
.status-meta {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.62);
  font-family: var(--font-mono);
  flex-wrap: wrap;
}

/* ---------- Votos (primeira dobra) ---------- */
.vote-row {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  justify-content: center;
  gap: 12px;
  margin-top: 28px;
  width: 100%;
  max-width: 520px;
}
.vote-btn {
  flex: 1 1 200px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 14px 18px 12px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  cursor: pointer;
  font-family: var(--font-display);
  backdrop-filter: blur(8px);
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}
.vote-btn:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.22);
  border-color: rgba(255, 255, 255, 0.45);
  transform: translateY(-2px);
}
.vote-btn:active:not(:disabled) {
  transform: translateY(0) scale(0.98);
}
.vote-btn:disabled {
  opacity: 0.72;
  cursor: default;
}
.vote-btn.vote-error {
  border-color: rgba(255, 200, 200, 0.8);
  animation: voteShake 0.4s ease;
}
@keyframes voteShake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  75% { transform: translateX(5px); }
}
.vote-label {
  font-size: 14px;
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.25;
}
.vote-count {
  font-family: var(--font-mono);
  font-size: 18px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.9);
  font-variant-numeric: tabular-nums;
}
.vote-btn.bump .vote-count {
  animation: voteBump 0.35s ease;
}
@keyframes voteBump {
  0% { transform: scale(1); }
  40% { transform: scale(1.22); }
  100% { transform: scale(1); }
}

.emoji-burst {
  position: fixed;
  inset: 0;
  z-index: 40;
  pointer-events: none;
  overflow: hidden;
}
.emoji-burst-piece {
  position: absolute;
  left: 0;
  top: 0;
  font-size: var(--burst-size, 28px);
  line-height: 1;
  will-change: transform, opacity;
  animation: emojiBurst var(--burst-dur, 900ms) cubic-bezier(0.15, 0.75, 0.25, 1) forwards;
  transform: translate(var(--burst-x), var(--burst-y)) rotate(0deg) scale(0.4);
  opacity: 0;
}
@keyframes emojiBurst {
  0% {
    opacity: 0;
    transform: translate(var(--burst-x), var(--burst-y)) rotate(0deg) scale(0.35);
  }
  12% {
    opacity: 1;
    transform: translate(var(--burst-x), var(--burst-y)) rotate(calc(var(--burst-rot) * 0.2)) scale(1.15);
  }
  100% {
    opacity: 0;
    transform: translate(
        calc(var(--burst-x) + var(--burst-dx)),
        calc(var(--burst-y) + var(--burst-dy))
      )
      rotate(var(--burst-rot))
      scale(0.7);
  }
}

/* ---------- Dica de rolagem ---------- */
.scroll-hint {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  margin-top: 40px;
  color: rgba(255, 255, 255, 0.65);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  animation: bob 2.2s ease-in-out infinite;
}
.scroll-hint:hover { color: #fff; }
@keyframes bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(6px); }
}

.ai-strip {
  position: relative;
  margin-top: 26px;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.85);
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.26);
  padding: 8px 14px;
  border-radius: 999px;
  flex-wrap: wrap;
  justify-content: center;
}
.ai-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--text-3);
  flex-shrink: 0;
}
.ai-dot.on { background: var(--green); box-shadow: 0 0 0 3px var(--green-glow); animation: pulse-dot 2s infinite; }
.ai-dot.checking { background: var(--amber); box-shadow: 0 0 0 3px var(--amber-glow); animation: pulse-dot 1s infinite; }
.ai-dot.err { background: var(--red); box-shadow: 0 0 0 3px var(--red-glow); }
@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 3px transparent; }
  50% { box-shadow: 0 0 0 5px currentColor; }
}

/* ---------- Timeline section ---------- */
.timeline-section { padding: 60px 0 20px; }
.section-head { text-align: center; margin-bottom: 44px; }
.section-head h2 {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 700;
  margin: 0 0 8px;
  letter-spacing: -0.01em;
}
.section-head p { margin: 0; color: var(--text-2); font-size: 14.5px; }

.timeline {
  list-style: none;
  margin: 0 auto;
  padding: 0;
  max-width: 760px;
  position: relative;
}
.timeline::before {
  content: "";
  position: absolute;
  left: 27px;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: linear-gradient(180deg, transparent, var(--border-strong) 6%, var(--border-strong) 94%, transparent);
}
@media (max-width: 640px) {
  .timeline::before { left: 17px; }
}

.tl-item {
  position: relative;
  padding-left: 66px;
  margin-bottom: 6px;
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}
.tl-item.in-view { opacity: 1; transform: translateY(0); }
@media (max-width: 640px) { .tl-item { padding-left: 44px; } }

.tl-dot {
  position: absolute;
  left: 20px;
  top: 22px;
  width: 14px; height: 14px;
  border-radius: 50%;
  background: var(--surface-2);
  border: 2px solid var(--text-3);
  z-index: 1;
}
@media (max-width: 640px) { .tl-dot { left: 10px; } }

.tl-item[data-tendency="sim"] .tl-dot { border-color: var(--red); background: color-mix(in srgb, var(--red) 30%, var(--surface-2)); box-shadow: 0 0 0 4px var(--red-glow); }
.tl-item[data-tendency="nao"] .tl-dot { border-color: var(--green); background: color-mix(in srgb, var(--green) 30%, var(--surface-2)); box-shadow: 0 0 0 4px var(--green-glow); }
.tl-item[data-tendency="indefinido"] .tl-dot { border-color: var(--amber); background: color-mix(in srgb, var(--amber) 25%, var(--surface-2)); box-shadow: 0 0 0 4px var(--amber-glow); }
.tl-item[data-tendency="evento"] .tl-dot { border-color: var(--text-3); }

.tl-card {
  display: block;
  text-decoration: none;
  color: inherit;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 16px 18px;
  transition: 0.18s ease;
  cursor: pointer;
}
.tl-card:hover {
  border-color: var(--border-strong);
  transform: translateX(4px);
  box-shadow: var(--shadow-md);
}
.tl-card:hover .tl-title { color: var(--gold-soft); }

.tl-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}
.tl-date {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  color: var(--text-2);
  letter-spacing: 0.02em;
}
.tl-badge {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 3px 9px;
  border-radius: 999px;
  white-space: nowrap;
}
.tl-item[data-tendency="sim"] .tl-badge { color: var(--red); background: color-mix(in srgb, var(--red) 16%, transparent); }
.tl-item[data-tendency="nao"] .tl-badge { color: var(--green); background: color-mix(in srgb, var(--green) 16%, transparent); }
.tl-item[data-tendency="indefinido"] .tl-badge { color: var(--amber); background: color-mix(in srgb, var(--amber) 18%, transparent); }
.tl-item[data-tendency="evento"] .tl-badge { color: var(--text-2); background: var(--surface-2); }

.tl-title {
  font-family: var(--font-display);
  font-size: 15.5px;
  font-weight: 600;
  margin: 0 0 5px;
  transition: color 0.15s ease;
}
.tl-desc {
  margin: 0;
  font-size: 13.5px;
  color: var(--text-2);
  line-height: 1.5;
}
.tl-link-hint {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 10px;
  font-size: 11.5px;
  color: var(--text-3);
}
.tl-item.today .tl-card { border-color: color-mix(in srgb, var(--gold) 55%, var(--border-strong)); box-shadow: 0 0 0 1px color-mix(in srgb, var(--gold) 30%, transparent); }
.tl-today-flag {
  font-size: 10.5px;
  font-weight: 700;
  color: var(--bg-0);
  background: var(--gold-soft);
  padding: 3px 8px;
  border-radius: 999px;
  margin-left: 6px;
}

/* ---------- Disclaimer ---------- */
.disclaimer {
  max-width: 760px;
  margin: 56px auto 0;
  padding: 22px 24px;
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius-md);
  background: var(--surface);
}
.disclaimer h3 { margin: 0 0 8px; font-size: 14px; font-family: var(--font-display); }
.disclaimer p { margin: 0; font-size: 13px; color: var(--text-2); line-height: 1.6; }

/* ---------- Footer ---------- */
.site-footer {
  max-width: 1080px;
  margin: 48px auto 0;
  padding: 24px;
  text-align: center;
  font-size: 12.5px;
  color: var(--text-3);
  border-top: 1px solid var(--border);
}
.site-footer p { margin: 0 0 6px; }
.site-footer p:last-child { margin-bottom: 0; }
.site-footer a { color: var(--text-2); text-decoration: underline; text-underline-offset: 2px; }
.site-footer a:hover { color: var(--gold-soft); }

/* ---------- Scrollbar (webkit) ---------- */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 999px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-3); }

/* ---------- Responsive ---------- */
@media (max-width: 560px) {
  .clock-date { max-width: 52vw; }
  main { padding: 0 16px; }
  .fold { padding: 28px 18px 36px; }
  .verdict-line { font-size: 19px; }
  .emoji-big { font-size: 84px; }
  .scroll-hint { margin-top: 30px; }
}
