:root {
  /* grafite com ~30% de branco */
  --ink: #707376;
  --ink-dim: #5c5f62;
  --bg: #050505;
  --font: "Special Elite", "Courier New", monospace;
  --font-grunge: "Rubik Distressed", Impact, "Arial Narrow", sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body { height: 100%; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}

/* ---------- Fundo animado ---------- */
.bg { position: fixed; inset: 0; z-index: 0; overflow: hidden; background: #050505; }
.bg canvas, .bg > div { position: absolute; inset: 0; width: 100%; height: 100%; }

#scene { opacity: .95; }

/* ruído de TV fora do ar */
#static {
  image-rendering: pixelated;
  opacity: .08;
  mix-blend-mode: screen;
}

.scanlines {
  background: repeating-linear-gradient(to bottom,
    rgba(0,0,0,0) 0, rgba(0,0,0,0) 2px,
    rgba(0,0,0,.35) 3px, rgba(0,0,0,0) 4px);
  mix-blend-mode: multiply;
  animation: flicker 5s infinite steps(1);
}

/* barra de interferência rolando */
.roll {
  background: linear-gradient(to bottom,
    rgba(255,255,255,0) 0%, rgba(255,255,255,.045) 50%, rgba(255,255,255,0) 100%);
  inset: auto;
  top: -20%; left: 0; width: 100%;
  height: 18%;
  animation: roll 7s linear infinite;
}

.vignette {
  background: radial-gradient(ellipse at 50% 45%, rgba(0,0,0,0) 30%, rgba(0,0,0,.85) 100%);
}

/* fumaça de gás lacrimogêneo */
.smoke {
  filter: blur(46px);
  opacity: .5;
  will-change: transform;
}
.s1 { background: radial-gradient(ellipse 40% 30% at 25% 78%, rgba(120,120,120,.30), transparent 70%); animation: drift1 26s ease-in-out infinite alternate; }
.s2 { background: radial-gradient(ellipse 45% 28% at 60% 70%, rgba(100,100,100,.26), transparent 70%); animation: drift2 32s ease-in-out infinite alternate; }
.s3 { background: radial-gradient(ellipse 35% 25% at 85% 82%, rgba(130,130,130,.22), transparent 70%); animation: drift1 38s ease-in-out infinite alternate-reverse; }

/* brilho do fogo (bem discreto) */
.fire-glow {
  background:
    radial-gradient(ellipse 22% 26% at 30% 82%, rgba(190,70,20,.22), transparent 70%),
    radial-gradient(ellipse 16% 20% at 38% 70%, rgba(190,90,20,.12), transparent 70%);
  mix-blend-mode: screen;
  animation: fire 1.6s infinite steps(1);
}

@keyframes drift1 { from { transform: translateX(-6%) scale(1); } to { transform: translateX(8%) scale(1.15); } }
@keyframes drift2 { from { transform: translateX(7%) translateY(-2%) scale(1.1); } to { transform: translateX(-9%) translateY(3%) scale(1); } }
@keyframes roll   { from { transform: translateY(0); } to { transform: translateY(700%); } }
@keyframes flicker {
  0%, 100% { opacity: 1; } 47% { opacity: 1; } 48% { opacity: .6; } 49% { opacity: 1; } 83% { opacity: .75; } 84% { opacity: 1; }
}
@keyframes fire {
  0% { opacity: .9; } 18% { opacity: .55; } 34% { opacity: 1; } 51% { opacity: .65; } 70% { opacity: .95; } 86% { opacity: .5; }
}

/* ---------- Idioma ---------- */
.top {
  position: fixed; top: 0; right: 0; z-index: 10;
  padding: clamp(14px, 3vw, 28px);
}
.lang { display: flex; align-items: center; gap: 8px; font-size: 14px; letter-spacing: .25em; color: var(--ink-dim); }
.lang button {
  background: none; border: 0; cursor: pointer;
  font: inherit; letter-spacing: inherit;
  color: var(--ink-dim);
  padding: 8px 6px; border-bottom: 1px solid transparent;
  transition: color .2s, border-color .2s;
}
.lang button:hover { color: var(--ink); }
.lang button[aria-pressed="true"] { color: var(--ink); border-bottom-color: var(--ink); }
.lang button:focus-visible { outline: 1px dashed var(--ink); outline-offset: 3px; }

/* ---------- Conteúdo ---------- */
.stage {
  position: relative; z-index: 5;
  height: 100%;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center;
  padding: 24px;
  gap: clamp(8px, 1.6vh, 16px);
}

.logo { width: min(78vw, 640px, 62vh * 1.97); margin-bottom: clamp(10px, 3vh, 34px); }
.logo-img {
  display: block; width: 100%; height: auto;
  filter: drop-shadow(0 0 18px rgba(0,0,0,.9));
  animation: glitch 9s infinite steps(1);
}

.soon {
  font-family: var(--font-grunge);
  font-size: clamp(32px, 5.4vw, 60px);
  font-weight: 400;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink);
  text-shadow: 0 0 12px rgba(0,0,0,.95);
}
.announce {
  font-size: clamp(14px, 2vw, 20px);
  font-weight: 400;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--ink);
  text-shadow: 0 0 10px rgba(0,0,0,.95);
}

.countdown {
  margin-top: clamp(10px, 3vh, 28px);
  display: flex; align-items: flex-start; justify-content: center;
  gap: clamp(6px, 2vw, 22px);
}
.unit { display: flex; flex-direction: column; align-items: center; min-width: clamp(54px, 11vw, 104px); }
.unit b {
  font-family: var(--font-grunge);
  font-size: clamp(38px, 8vw, 84px);
  font-weight: 400; line-height: 1;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
  text-shadow: 0 0 14px rgba(0,0,0,.95);
}
.unit small {
  margin-top: 6px;
  font-size: clamp(10px, 1.4vw, 13px);
  font-weight: 400; letter-spacing: .3em; text-transform: uppercase;
  color: var(--ink-dim);
}
.sep { font-size: clamp(30px, 6vw, 62px); line-height: 1.05; color: var(--ink-dim); animation: blink 1s infinite steps(1); }
.live { font-family: var(--font-grunge); font-weight: 400; font-size: clamp(22px, 4vw, 40px); letter-spacing: .25em; text-transform: uppercase; }

@keyframes blink { 50% { opacity: .25; } }

/* glitch ocasional do logo */
@keyframes glitch {
  0%, 92%, 100% { transform: none; }
  93% { transform: translate(-4px, 1px) skewX(-2deg); }
  94% { transform: translate(5px, -1px); }
  95% { transform: translate(-2px, 0) skewX(3deg); }
  96% { transform: none; }
}

@media (max-width: 520px) {
  .logo { width: 92vw; }
  .sep { display: none; }
  .countdown { gap: 4px; }
}

@media (prefers-reduced-motion: reduce) {
  .smoke, .fire-glow, .roll, .scanlines, .logo-img, .sep { animation: none; }
}
