:root {
  --bg: #141310;
  --panel: rgba(255, 154, 47, 0.035);
  --amber: rgba(255, 174, 79, 0.90);
  --amber-bright: rgba(255, 183, 92, 0.98);
  --amber-dim: rgba(255, 174, 79, 0.57);
  --line: rgba(255, 174, 79, 0.24);
}
* { box-sizing: border-box; }
html { background: var(--bg); }
body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 50% 30%, rgba(255, 140, 30, .035), transparent 48%),
    var(--bg);
  color: var(--amber);
  font-family: "Courier New", Courier, monospace;
  letter-spacing: .035em;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(ellipse at center, transparent 48%, rgba(0,0,0,.28) 100%);
  z-index: 5;
}
.scanlines {
  position: fixed;
  inset: -10px 0;
  pointer-events: none;
  z-index: 6;
  opacity: .24;

  background: repeating-linear-gradient(
    to bottom,
    rgba(255,255,255,.018) 0,
    rgba(255,255,255,.018) 1px,
    transparent 1px,
    transparent 4px
  );

  animation: scanline-drift 9s linear infinite;
}

@keyframes scanline-drift {
  from {
    transform: translateY(0);
  }

  to {
    transform: translateY(8px);
  }
}
.terminal {
  width: min(1050px, calc(100% - 34px));
  margin: 0 auto;
  padding: 54px 0 70px;

  text-shadow:
    0 0 4px rgba(255,150,40,.48),
    0 0 11px rgba(255,120,20,.16);

  animation:
    phosphor-flicker 5.7s infinite,
    crt-jitter 11s infinite;
}

/* Uneven old-monitor brightness */
@keyframes phosphor-flicker {
  0%, 18%, 22%, 62%, 64%, 100% {
    opacity: .97;
    filter: brightness(1);
  }

  19% {
    opacity: .94;
    filter: brightness(.96);
  }

  20% {
    opacity: .985;
    filter: brightness(1.035);
  }

  21% {
    opacity: .955;
    filter: brightness(.99);
  }

  63% {
    opacity: .93;
    filter: brightness(.965);
  }
}

/* Almost imperceptible vibration + occasional stutter */
@keyframes crt-jitter {
  0%, 94%, 96%, 100% {
    transform: translate(0, 0);
  }

  94.5% {
    transform: translateX(.4px);
  }

  95% {
    transform: translateX(-.7px);
  }

  95.3% {
    transform: translateX(1px);
  }

  95.6% {
    transform: translateX(-.3px);
  }
}
header { text-align: center; padding-bottom: 28px; border-bottom: 1px solid var(--line); }
.eyebrow, .label, small, footer, .audio-note { color: var(--amber-dim); }
h1 { margin: 14px 0 4px; font-size: clamp(3.5rem, 11vw, 8rem); letter-spacing: .17em; padding-left: .17em; line-height: .9; color: var(--amber-bright); }
.tagline { margin: 22px auto 0; font-size: clamp(.92rem, 2.4vw, 1.16rem); }
.status-panel { margin: 30px 0; padding: 20px 22px; border: 1px solid var(--line); background: var(--panel); line-height: 1.9; }
#status { color: var(--amber-bright); }
.countdown { display: grid; grid-template-columns: 1fr auto 1fr auto 1fr auto 1fr; align-items: start; gap: 12px; padding: 38px 0 28px; text-align: center; }
.count-unit span { display: block; font-size: clamp(2.2rem, 7.4vw, 5.7rem); line-height: .95; color: var(--amber-bright); }
.count-unit small { display: block; margin-top: 12px; font-size: clamp(.58rem, 1.6vw, .84rem); }
.separator { font-size: clamp(2rem, 6vw, 4.8rem); line-height: .9; color: var(--amber-dim); }
.awake { text-align: center; margin: 4px 0 45px; color: var(--amber-bright); font-size: 1.35rem;
  font-weight: 700; text-transform: uppercase;  letter-spacing: 0.08em;}
h2 { margin: 0 0 20px; font-size: 1rem; letter-spacing: .13em; color: var(--amber-bright); }
.history, .participation { border-top: 1px solid var(--line); padding: 34px 4px; line-height: 1.75; }
.history p { max-width: 850px; }
.objective { font-size: 1.25rem; color: var(--amber-bright); text-transform: uppercase; }
.controls { border-top: 1px solid var(--line); padding: 34px 4px; display: flex; flex-wrap: wrap; gap: 13px; }
button, a {
  appearance: none;
  border: 1px solid var(--line);
  background: rgba(255, 150, 40, .025);
  color: var(--amber);
  font: inherit;
  padding: 12px 14px;
  text-decoration: none;
  cursor: pointer;
  text-shadow: inherit;
}
button:hover, a:hover, button:focus-visible, a:focus-visible { background: rgba(255, 160, 50, .09); color: var(--amber-bright); outline: 1px solid var(--amber-dim); }
.quiet { opacity: .58; }
.audio-note { width: 100%; font-size: .72rem; margin: 3px 0 0; }
.calendar-links { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 20px; }
footer { border-top: 1px solid var(--line); padding-top: 28px; font-size: .78rem; line-height: 1.7; }
.tiny { margin-top: 28px; opacity: .7; }
.timeline-notice { position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%); z-index: 20; width: min(620px, calc(100% - 32px)); padding: 17px 20px; border: 1px solid var(--amber); background: #17130e; text-align: center; box-shadow: 0 0 25px rgba(255,130,20,.14); }
.alert-overlay { position: fixed; inset: 0; z-index: 30; background: rgba(15,12,8,.96); display: grid; place-items: center; padding: 25px; text-align: center; color: var(--amber-bright); text-shadow: 0 0 7px rgba(255,150,40,.7); }
.alert-overlay[hidden], .timeline-notice[hidden] { display: none; }
.alert-overlay h2 { font-size: clamp(1.5rem, 5vw, 3rem); margin: 20px 0; }
@media (max-width: 620px) {
  .terminal { width: min(100% - 24px, 1050px); padding-top: 35px; }
  h1 { letter-spacing: .10em; padding-left: .10em; }
  .countdown { gap: 4px; }
  .count-unit span { font-size: clamp(1.65rem, 10vw, 3rem); }
  .separator { font-size: clamp(1.5rem, 8vw, 2.5rem); }
  .count-unit small { font-size: .52rem; letter-spacing: 0; }
  button, a { width: 100%; text-align: center; }
}
@media (prefers-reduced-motion: reduce) { .terminal { animation: none; } }
