:root {
  --rood: #d62839;
  --donker: #0b0f1e;
  --tekst: #f4f1e8;
  --geel: #ffd34d;
  --pixel: "Press Start 2P", monospace;
  --leesbaar: "VT323", monospace;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  height: 100%;
  background: #000;
  color: var(--tekst);
  overflow: hidden;
}

body {
  display: grid;
  place-items: center;
}

/* Het beeld is altijd 16:9 en zo groot mogelijk. */
.scherm {
  position: relative;
  width: min(100vw, calc(100vh * 16 / 9));
  aspect-ratio: 16 / 9;
  container-type: inline-size;
  background: var(--donker);
  overflow: hidden;
}

canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  image-rendering: pixelated;
}

.live {
  position: absolute;
  top: 2.5cqw;
  left: 2.5cqw;
  display: flex;
  align-items: center;
  gap: 0.8cqw;
  padding: 0.6cqw 1cqw;
  background: var(--rood);
  font: 1.2cqw var(--pixel);
}
.live-stip {
  width: 1cqw;
  height: 1cqw;
  background: #fff;
  animation: knipper 1s steps(1) infinite;
}
#klok { opacity: 0.85; }

.logo {
  position: absolute;
  top: 2.5cqw;
  right: 2.5cqw;
  padding: 0.6cqw 1cqw;
  background: rgba(11, 15, 30, 0.8);
  border-bottom: 0.4cqw solid var(--rood);
  font: 1.2cqw var(--pixel);
  letter-spacing: 0.1cqw;
}

/* Naam van wie er spreekt, links boven de ondertitel. */
.naambalk {
  position: absolute;
  left: 4cqw;
  bottom: 15.5cqw;
  transform: translateX(calc(-100% - 5cqw));
  transition: transform 0.4s steps(6);
}
.naambalk.zichtbaar { transform: translateX(0); }
.naam {
  padding: 0.8cqw 1.2cqw;
  background: var(--rood);
  font: 1.3cqw var(--pixel);
}
.functie {
  display: inline-block;
  padding: 0.4cqw 1.2cqw;
  background: var(--tekst);
  color: var(--donker);
  font: 1.9cqw var(--leesbaar);
}

.ondertitel {
  position: absolute;
  left: 50%;
  bottom: 6.5cqw;
  width: 86%;
  transform: translateX(-50%);
  padding: 0.6cqw 1.4cqw;
  background: rgba(0, 0, 0, 0.72);
  font: 2.6cqw/1.15 var(--leesbaar);
  text-align: center;
  visibility: hidden;
}
.ondertitel.zichtbaar { visibility: visible; }
.ondertitel b { color: var(--geel); font-weight: normal; }

.ticker {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 4.6cqw;
  display: flex;
  background: var(--tekst);
  color: var(--donker);
}
.ticker-label {
  display: grid;
  place-items: center;
  padding: 0 1.4cqw;
  background: var(--rood);
  color: #fff;
  font: 1.3cqw var(--pixel);
}
.ticker-baan {
  flex: 1;
  overflow: hidden;
  display: flex;
  align-items: center;
}
.ticker-tekst {
  white-space: nowrap;
  font: 2.6cqw var(--leesbaar);
  padding-left: 100%;
  animation: rol 60s linear infinite;
}

/* Tussen twee onderwerpen: een korte titelkaart. */
.titelkaart {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  gap: 2cqw;
  text-align: center;
  background:
    repeating-linear-gradient(0deg, rgba(0,0,0,0.25) 0 2px, transparent 2px 4px),
    linear-gradient(135deg, #1a2350, #6b1424);
  visibility: hidden;
  pointer-events: none;
}
.titelkaart.zichtbaar { visibility: visible; }
.titelkaart-logo {
  font: 4cqw var(--pixel);
  color: #fff;
  text-shadow: 0.4cqw 0.4cqw 0 var(--rood);
}
.titelkaart-titel {
  max-width: 80cqw;
  margin: 0 auto;
  font: 3.4cqw var(--leesbaar);
  color: var(--geel);
}

.melding {
  position: absolute;
  inset: 30% 15% auto;
  padding: 2cqw;
  background: rgba(0, 0, 0, 0.85);
  border: 0.3cqw solid var(--geel);
  font: 2.4cqw/1.3 var(--leesbaar);
  text-align: center;
  display: none;
}
.melding.zichtbaar { display: block; }

.start {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  gap: 1.5cqw;
  width: 100%;
  border: 0;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  font: 2cqw var(--pixel);
  cursor: pointer;
}
.start-icoon {
  font-size: 6cqw;
  color: var(--rood);
}
.start:hover .start-icoon { color: var(--geel); }

.volledig {
  position: absolute;
  top: 6.5cqw;
  right: 2.5cqw;
  width: 3.2cqw;
  height: 3.2cqw;
  border: 0;
  background: rgba(0, 0, 0, 0.5);
  color: #fff;
  font-size: 2cqw;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.2s;
}
.scherm:hover .volledig { opacity: 1; }

@keyframes knipper { 50% { opacity: 0; } }
@keyframes rol { to { transform: translateX(-100%); } }
