:root {
  color-scheme: light;
  font-family: "Avenir Next", "Segoe UI", system-ui, sans-serif;
  --bg-top: #f8fbff;
  --bg-bottom: #e8f0fa;
  --text: #1a2a3d;
  --muted: #5a7088;
  --accent: #2b8cff;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  height: 100%;
  overflow: hidden;
  background: linear-gradient(165deg, var(--bg-top) 0%, var(--bg-bottom) 55%, #dfeaf7 100%);
  color: var(--text);
}

#live-root {
  position: relative;
  width: 100vw;
  height: 100vh;
}

#canvas {
  display: block;
  width: 100%;
  height: 100%;
}

#overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: clamp(16px, 4vw, 32px);
}

#brand {
  font-size: clamp(1.6rem, 4.5vw, 2.6rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1;
  color: var(--text);
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.6);
}

#live-status {
  align-self: flex-start;
  margin-top: 10px;
  font-size: clamp(0.85rem, 2vw, 1rem);
  color: var(--muted);
  letter-spacing: 0.02em;
}

#live-status.status--live {
  color: #1a5fbf;
}

#live-status.status--idle {
  color: var(--muted);
}

#idle-tagline {
  margin: 14px 0 0;
  max-width: 28rem;
  font-size: clamp(0.9rem, 2.2vw, 1.05rem);
  line-height: 1.45;
  color: var(--muted);
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

#idle-tagline.visible {
  opacity: 1;
  transform: translateY(0);
}

#live-status.status--idle::before {
  background: #9eb4cc;
  box-shadow: 0 0 0 4px rgba(158, 180, 204, 0.22);
  animation: pulse 3s ease-in-out infinite;
}

#live-status.status--live::before {
  background: var(--accent);
  box-shadow: 0 0 0 4px rgba(43, 140, 255, 0.18);
  animation: pulse 2.4s ease-in-out infinite;
}

#live-status::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 8px;
  border-radius: 50%;
  vertical-align: middle;
}

@keyframes pulse {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.55;
    transform: scale(0.92);
  }
}

#footer {
  display: flex;
  gap: 16px;
  font-size: 0.8rem;
  color: var(--muted);
}

#footer a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid rgba(90, 112, 136, 0.35);
}

#footer a:hover {
  color: var(--text);
}

@media (max-width: 600px) {
  #footer {
    flex-direction: column;
    gap: 6px;
  }
}
