:root {
    --bg-color: #0f172a;
    --fg-color: #6366f1;
    --surface: rgba(30, 41, 59, 1);
    --card: rgba(30, 41, 59, 0.55);
    --text: #f8fafc;
    --text-light: #cbd5e1;
    --border: rgba(148, 163, 184, 0.2);
    --border-accent: rgba(99, 102, 241, 0.25);
    --error: #ef4444;
    --success: #22c55e;
    --font-family: 'Inter', system-ui, sans-serif;
    color-scheme: dark;
    accent-color: var(--fg-color);
}

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

html {
    height: 100%;
}

body {
    font-family: var(--font-family);
    line-height: 1.6;
    color: var(--text);
    background: var(--bg-color);
    width: 100%;
    overflow-x: hidden;
}

/* ── scene */
.scene {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.scene .overlay {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at top right,
            var(--fg-color) 0%,
            var(--bg-color) 100%);
    opacity: 0.9;
}

/* sits low so the player dock reads as the horizon it sets behind */
.scene .sun {
    position: absolute;
    left: 50%;
    bottom: -140px;
    transform: translateX(-50%);
    width: min(48vw, 520px);
    aspect-ratio: 1;
    border-radius: 50%;
    background: radial-gradient(circle at 50% 30%,
        rgba(165, 180, 252, 0.85) 0%,
        rgba(99, 102, 241, 0.55) 45%,
        rgba(99, 102, 241, 0) 72%);
    -webkit-mask-image: repeating-linear-gradient(to bottom,
        black 0 13px,
        transparent 13px 18px);
    mask-image: repeating-linear-gradient(to bottom,
        black 0 13px,
        transparent 13px 18px);
    opacity: 0.25;
}

.scene .grid-overlay {
    position: absolute;
    inset: 0;
    background-image:
        repeating-linear-gradient(0deg,
            rgba(255,255,255,0.03) 0px,
            rgba(255,255,255,0.03) 1px,
            transparent 1px,
            transparent 20px),
        repeating-linear-gradient(90deg,
            rgba(255,255,255,0.03) 0px,
            rgba(255,255,255,0.03) 1px,
            transparent 1px,
            transparent 20px);
}

.scene .scanline {
    position: absolute;
    left: 0;
    right: 0;
    top: -120px;
    height: 120px;
    background: linear-gradient(to bottom,
        transparent,
        rgba(148, 163, 184, 0.045),
        transparent);
    animation: scan 14s linear infinite;
}

@keyframes scan {
    to {
        transform: translateY(calc(100vh + 120px));
    }
}

/* ── shared bits */
:focus-visible {
    outline: 2px solid var(--fg-color);
    outline-offset: 2px;
}

.card-title {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--text-light);
    margin-bottom: 0.5rem;
}

/* takes no space until App.js applies a state class */
.status {
    display: none;
    width: 100%;
    padding: 0.45rem 0.75rem;
    border-radius: 0.35rem;
    font-weight: 500;
    font-size: 0.8125rem;
    text-align: center;
}

.status.info,
.status.error,
.status.success {
    display: block;
}

.status.info {
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.2);
}

.status.error {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
}

.status.success {
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.2);
}

.streaming-notice {
    padding-left: 0.5rem;
    border-left: 2px solid rgba(234, 179, 8, 0.45);
    color: var(--text-light);
    font-size: 0.75rem;
    line-height: 1.35;
    opacity: 0.85;
}

.streaming-notice[hidden] {
    display: none;
}

@media (prefers-reduced-motion: reduce) {
    .scene .scanline {
        animation: none;
        display: none;
    }
}
