:root {
    --bg: #030303;
    --red: #ff2218;
    --red-dim: #8f100c;
    --amber: #ffb000;
    --cyan: #3de8ff;
    --text: #f4efe8;
    --muted: #8a8078;
    --panel: rgba(10, 6, 8, 0.72);
    --border: rgba(255, 34, 24, 0.45);
    --mono: "Share Tech Mono", monospace;
    --display: "Oswald", sans-serif;
}

* { box-sizing: border-box; }

html, body {
    margin: 0;
    min-height: 100%;
    background: var(--bg);
    color: var(--text);
    font-family: var(--mono);
}

body { overflow-x: hidden; }

/* ── Background layers ── */
.fx-canvas {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    opacity: 0.55;
}

.grid-floor {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background:
        linear-gradient(rgba(255,34,24,.07) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,34,24,.07) 1px, transparent 1px);
    background-size: 48px 48px;
    mask-image: radial-gradient(ellipse 80% 60% at 50% 75%, #000 20%, transparent 75%);
    transform: perspective(500px) rotateX(62deg) scale(2.2);
    transform-origin: 50% 100%;
    opacity: 0.35;
    animation: gridDrift 20s linear infinite;
}

.laser-scan {
    position: fixed;
    left: 0;
    right: 0;
    height: 2px;
    z-index: 5;
    pointer-events: none;
    background: linear-gradient(90deg, transparent, var(--red), var(--cyan), var(--red), transparent);
    box-shadow: 0 0 20px var(--red), 0 0 40px rgba(255,34,24,.4);
    animation: laserMove 6s ease-in-out infinite;
    opacity: 0.7;
}

.noise {
    position: fixed;
    inset: 0;
    z-index: 6;
    pointer-events: none;
    opacity: 0.04;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.scanlines {
    pointer-events: none;
    position: fixed;
    inset: 0;
    z-index: 7;
    background: repeating-linear-gradient(to bottom, rgba(255,255,255,.025) 0, rgba(255,255,255,.025) 1px, transparent 1px, transparent 3px);
    opacity: 0.4;
}

.vignette {
    pointer-events: none;
    position: fixed;
    inset: 0;
    z-index: 8;
    background: radial-gradient(ellipse at center, transparent 30%, rgba(0,0,0,.88) 100%);
}

.spotlight {
    pointer-events: none;
    position: fixed;
    inset: 0;
    z-index: 1;
    background:
        radial-gradient(circle at 50% 12%, rgba(255,176,0,.14) 0%, transparent 26%),
        radial-gradient(circle at 50% 38%, rgba(255,34,24,.1) 0%, transparent 42%),
        linear-gradient(180deg, #141010 0%, #050505 50%, #000 100%);
}

.hud-top {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 20;
    display: flex;
    justify-content: center;
    gap: 1rem;
    padding: 0.65rem 1rem;
    flex-wrap: wrap;
    pointer-events: none;
}

.hud-chip {
    font-size: 0.62rem;
    letter-spacing: 0.28em;
    color: rgba(61,232,255,.75);
    border: 1px solid rgba(61,232,255,.25);
    padding: 0.25rem 0.55rem;
    background: rgba(0,0,0,.4);
}

.hud-time { color: rgba(255,176,0,.9); border-color: rgba(255,176,0,.3); }

/* ── Scene ── */
.interrogation {
    position: relative;
    z-index: 10;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3.5rem 1rem 2.5rem;
    transition: transform 0.15s ease-out;
}

.arnold-shadow {
    position: fixed;
    inset: 0;
    z-index: 2;
    pointer-events: none;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    overflow: hidden;
}

.arnold-glow {
    position: absolute;
    bottom: 5%;
    width: 280px;
    height: 280px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255,34,24,.35) 0%, transparent 70%);
    filter: blur(30px);
    animation: arnoldBreath 5s ease-in-out infinite;
}

.arnold-figure {
    width: min(360px, 58vw);
    height: auto;
    opacity: 0.32;
    transform: translateY(6%);
    filter: drop-shadow(0 0 50px rgba(255,34,24,.35));
    animation: arnoldBreath 5s ease-in-out infinite;
}

.arnold-figure .lens {
    fill: rgba(255,40,30,.9);
    animation: lensPulse 2.5s ease-in-out infinite;
}

/* ── Panel ── */
.room {
    width: min(740px, 100%);
    border: 1px solid var(--border);
    background: var(--panel);
    backdrop-filter: blur(16px) saturate(1.2);
    -webkit-backdrop-filter: blur(16px) saturate(1.2);
    box-shadow:
        0 0 0 1px rgba(255,255,255,.04) inset,
        0 0 80px rgba(255,34,24,.12),
        0 30px 100px rgba(0,0,0,.75);
    padding: 2.25rem 1.85rem 1.65rem;
    position: relative;
    animation: roomIn 1s cubic-bezier(.2,.8,.2,1);
}

.hud-corner {
    position: absolute;
    width: 28px;
    height: 28px;
    border: 2px solid rgba(61,232,255,.5);
    pointer-events: none;
}

.hud-tl { top: 8px; left: 8px; border-right: none; border-bottom: none; }
.hud-tr { top: 8px; right: 8px; border-left: none; border-bottom: none; }
.hud-bl { bottom: 8px; left: 8px; border-right: none; border-top: none; }
.hud-br { bottom: 8px; right: 8px; border-left: none; border-top: none; }

.reticle {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 120px;
    height: 120px;
    margin: -60px 0 0 -60px;
    border: 1px solid rgba(255,34,24,.15);
    border-radius: 50%;
    pointer-events: none;
    animation: reticleSpin 12s linear infinite;
}

.reticle::before,
.reticle::after {
    content: "";
    position: absolute;
    background: rgba(255,34,24,.4);
}

.reticle::before {
    top: 50%; left: -8px; right: -8px; height: 1px;
    transform: translateY(-50%);
}

.reticle::after {
    left: 50%; top: -8px; bottom: -8px; width: 1px;
    transform: translateX(-50%);
}

.rec-badge {
    position: absolute;
    top: 1rem;
    right: 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.72rem;
    letter-spacing: 0.2em;
    color: var(--red);
    animation: flicker 2.4s infinite;
    z-index: 2;
}

.rec-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--red);
    box-shadow: 0 0 12px var(--red);
}

.lang-switch {
    display: flex;
    justify-content: center;
    gap: 0.4rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.lang-btn {
    border: 1px solid rgba(255,255,255,.1);
    color: var(--muted);
    font-size: 0.68rem;
    letter-spacing: 0.14em;
    text-decoration: none;
    padding: 0.4rem 0.75rem;
    text-transform: uppercase;
    transition: all 0.25s;
    background: rgba(0,0,0,.3);
}

.lang-btn:hover,
.lang-btn.is-active {
    color: var(--text);
    border-color: var(--red);
    background: rgba(255,34,24,.15);
    box-shadow: 0 0 20px rgba(255,34,24,.2);
}

.header {
    margin-bottom: 1.75rem;
    padding-top: 0.5rem;
    text-align: center;
    position: relative;
    z-index: 2;
}

.dept {
    margin: 0 0 1rem;
    font-size: 0.7rem;
    letter-spacing: 0.32em;
    color: var(--muted);
}

.question {
    margin: 0 auto;
    font-family: var(--display);
    font-size: clamp(2.5rem, 9vw, 4.5rem);
    line-height: 0.92;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 700;
    position: relative;
}

.q-line { display: block; }

.q-accent {
    color: var(--red);
    text-shadow: 0 0 30px rgba(255,34,24,.55), 0 0 60px rgba(255,34,24,.2);
    animation: pulse 3s ease-in-out infinite, textGlitch 5s infinite;
}

.sub {
    margin: 1.25rem auto 0;
    max-width: 34rem;
    color: var(--muted);
    font-size: 0.9rem;
    line-height: 1.65;
}

/* ── Arnold quote ── */
.arnold-voice {
    margin: 0 0 1.75rem;
    padding: 1.1rem 1.2rem;
    border: 1px solid rgba(255,34,24,.35);
    background: linear-gradient(135deg, rgba(255,34,24,.08), rgba(0,0,0,.4));
    text-align: center;
    position: relative;
    z-index: 2;
    overflow: hidden;
}

.arnold-voice::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,.04), transparent);
    animation: sweep 4s infinite;
}

.voice-wave {
    display: flex;
    justify-content: center;
    gap: 4px;
    margin-bottom: 0.75rem;
    height: 18px;
    align-items: flex-end;
}

.voice-wave span {
    width: 3px;
    background: var(--red);
    border-radius: 2px;
    animation: waveBar 1.2s ease-in-out infinite;
    box-shadow: 0 0 8px var(--red);
}

.voice-wave span:nth-child(1) { animation-delay: 0s; }
.voice-wave span:nth-child(2) { animation-delay: .1s; }
.voice-wave span:nth-child(3) { animation-delay: .2s; }
.voice-wave span:nth-child(4) { animation-delay: .3s; }
.voice-wave span:nth-child(5) { animation-delay: .4s; }

.arnold-quote {
    margin: 0;
    font-family: var(--display);
    font-size: clamp(1.05rem, 3.5vw, 1.4rem);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    line-height: 1.35;
}

/* ── Form ── */
.form {
    display: grid;
    gap: 1rem;
    position: relative;
    z-index: 2;
}

.field { display: flex; flex-direction: column; gap: 0.45rem; }

.label {
    font-size: 0.7rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--amber);
    text-align: center;
}

.input-wrap {
    position: relative;
}

.input-wrap::before,
.input-wrap::after {
    content: "";
    position: absolute;
    width: 10px;
    height: 10px;
    border: 1px solid rgba(61,232,255,.4);
    pointer-events: none;
    transition: border-color 0.2s;
}

.input-wrap::before { top: -1px; left: -1px; border-right: none; border-bottom: none; }
.input-wrap::after { bottom: -1px; right: -1px; border-left: none; border-top: none; }

.input-wrap:focus-within::before,
.input-wrap:focus-within::after {
    border-color: var(--red);
}

.field input,
.field textarea {
    width: 100%;
    border: 1px solid rgba(255,255,255,.08);
    background: rgba(0,0,0,.55);
    color: var(--text);
    font: inherit;
    padding: 0.9rem 1rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.field input:focus,
.field textarea:focus {
    outline: none;
    border-color: rgba(255,34,24,.6);
    box-shadow: 0 0 0 1px rgba(255,34,24,.2), 0 0 30px rgba(255,34,24,.15);
}

.field textarea { resize: vertical; min-height: 140px; }

.btn-submit {
    position: relative;
    width: 100%;
    border: 1px solid var(--red);
    background: linear-gradient(180deg, rgba(255,34,24,.35), rgba(60,8,6,.9));
    color: var(--text);
    font-family: var(--display);
    font-size: 1.25rem;
    letter-spacing: 0.38em;
    padding: 1.05rem 1.5rem;
    cursor: pointer;
    text-transform: uppercase;
    overflow: hidden;
    transition: transform 0.15s, box-shadow 0.25s;
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 40px rgba(255,34,24,.35), 0 0 60px rgba(255,34,24,.15);
}

.btn-submit:active { transform: translateY(0); }
.btn-submit:disabled { opacity: 0.55; cursor: wait; }

.btn-glow {
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, transparent 30%, rgba(255,255,255,.15) 50%, transparent 70%);
    animation: sweep 3s infinite;
}

.btn-text { position: relative; z-index: 1; }

.status {
    min-height: 1.4rem;
    margin: 0.75rem 0 0;
    font-size: 0.85rem;
    text-align: center;
}

.status.ok { color: #7dffb2; text-shadow: 0 0 12px rgba(125,255,178,.4); }
.status.err { color: #ff7b72; }

.footer {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255,255,255,.06);
    text-align: center;
    position: relative;
    z-index: 2;
}

.arnold-easter {
    margin: 0;
    font-family: var(--display);
    font-size: 0.85rem;
    letter-spacing: 0.28em;
    text-transform: uppercase;
    color: var(--red);
    text-shadow: 0 0 20px rgba(255,34,24,.5);
    animation: pulse 3.5s ease-in-out infinite;
}

/* ── Keyframes ── */
@keyframes roomIn {
    from { opacity: 0; transform: translateY(24px) scale(0.96); filter: blur(4px); }
    to { opacity: 1; transform: none; filter: none; }
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

@keyframes arnoldBreath {
    0%, 100% { transform: translateY(6%) scale(1); opacity: 0.32; }
    50% { transform: translateY(4%) scale(1.03); opacity: 0.4; }
}

@keyframes lensPulse {
    0%, 100% { fill: rgba(255,40,30,.85); }
    50% { fill: rgba(255,80,40,1); }
}

@keyframes flicker {
    0%, 100% { opacity: 1; }
    49% { opacity: 1; }
    50% { opacity: 0.3; }
    51% { opacity: 1; }
}

@keyframes sweep {
    0% { transform: translateX(-120%); }
    100% { transform: translateX(120%); }
}

@keyframes laserMove {
    0%, 100% { top: 8%; opacity: 0.3; }
    50% { top: 92%; opacity: 0.85; }
}

@keyframes gridDrift {
    0% { background-position: 0 0; }
    100% { background-position: 0 48px; }
}

@keyframes reticleSpin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes waveBar {
    0%, 100% { height: 4px; }
    50% { height: 18px; }
}

@keyframes textGlitch {
    0%, 92%, 100% { transform: translate(0); filter: none; }
    93% { transform: translate(-2px, 0); text-shadow: -2px 0 var(--cyan), 2px 0 var(--red), 0 0 30px rgba(255,34,24,.5); }
    95% { transform: translate(2px, 0); text-shadow: 2px 0 var(--cyan), -2px 0 var(--red), 0 0 30px rgba(255,34,24,.5); }
}

@media (max-width: 600px) {
    .room { padding: 1.75rem 1rem 1.35rem; }
    .header { padding-top: 1.5rem; }
    .rec-badge { top: 0.7rem; right: 0.7rem; font-size: 0.65rem; }
    .reticle { display: none; }
    .hud-top { gap: 0.4rem; }
    .hud-chip { font-size: 0.55rem; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    .interrogation { transition: none; }
}
