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

html, body {
    width: 100%;
    height: 100%;
    background: #000;
    overflow: hidden;
    font-family: 'Courier New', monospace;
}

#container {
    position: relative;
    width: 100vw;
    height: 100vh;
    cursor: none;
}

#scene {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
    filter: saturate(0.92) contrast(1.06) brightness(1.0);
}

/* ---------- VHS overlay ---------- */
#vhs {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 10;
}

#noise {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0.055;
    mix-blend-mode: screen;
}

#scanlines {
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(
        to bottom,
        rgba(0,0,0,0) 0px,
        rgba(0,0,0,0) 2px,
        rgba(0,0,0,0.13) 3px,
        rgba(0,0,0,0) 4px
    );
}

#vignette {
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at center,
        rgba(0,0,0,0) 55%,
        rgba(0,0,0,0.42) 100%);
}

#vhs-ui {
    position: absolute;
    inset: 0;
    color: #e8e8e8;
    text-shadow: 0 0 6px rgba(255,255,255,0.55), 1px 0 0 rgba(255,0,80,0.35), -1px 0 0 rgba(0,180,255,0.35);
    font-size: clamp(14px, 2vw, 22px);
    letter-spacing: 2px;
    opacity: 0.85;
}

#rec {
    position: absolute;
    top: 4%;
    left: 5%;
    display: flex;
    align-items: center;
    gap: 10px;
}

#rec-dot {
    width: 0.7em;
    height: 0.7em;
    border-radius: 50%;
    background: #ff2b2b;
    box-shadow: 0 0 8px #ff2b2b;
    animation: blink 1.1s steps(1) infinite;
}

@keyframes blink { 50% { opacity: 0; } }

#play-mode {
    position: absolute;
    top: 4%;
    right: 5%;
}

#timestamp {
    position: absolute;
    bottom: 5%;
    left: 5%;
    white-space: pre;
}

#battery {
    position: absolute;
    bottom: 5%;
    right: 5%;
    letter-spacing: 1px;
}

#tracking-bar {
    position: absolute;
    left: 0;
    width: 100%;
    height: 0;
    background: rgba(255,255,255,0.10);
    box-shadow: 0 0 18px 6px rgba(255,255,255,0.10);
    top: 110%;
}

/* ---------- static cut ---------- */
#static-cut {
    position: absolute;
    inset: 0;
    z-index: 30;
    display: none;
    background: #000;
}

#static-cut.active { display: block; }

#static-canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

#static-text {
    position: absolute;
    bottom: 8%;
    width: 100%;
    text-align: center;
    color: #fff;
    font-size: clamp(16px, 2.4vw, 26px);
    letter-spacing: 6px;
    text-shadow: 0 0 8px #fff;
    animation: blink 0.6s steps(1) infinite;
}

/* ---------- caption ---------- */
#caption {
    position: absolute;
    bottom: 14%;
    width: 100%;
    text-align: center;
    z-index: 20;
    color: #ddd;
    font-size: clamp(13px, 1.6vw, 18px);
    letter-spacing: 3px;
    text-shadow: 0 0 6px rgba(255,255,255,0.4);
    opacity: 0;
    transition: opacity 1.2s;
    pointer-events: none;
}

#caption.show { opacity: 0.75; }

/* ---------- start screen ---------- */
#start-screen {
    position: absolute;
    inset: 0;
    z-index: 50;
    background:
        radial-gradient(ellipse at center, rgba(38,34,10,0.94), rgba(0,0,0,0.98)),
        #000;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: default;
    text-align: center;
}

#start-inner h1 {
    color: #e8d872;
    font-size: clamp(34px, 6vw, 72px);
    letter-spacing: 14px;
    text-shadow: 0 0 24px rgba(232,216,114,0.5);
    margin-bottom: 8px;
}

#start-inner .sub {
    color: #a49751;
    letter-spacing: 6px;
    font-size: clamp(12px, 1.5vw, 16px);
    margin-bottom: 34px;
}

#start-inner .desc {
    color: #8f8a76;
    line-height: 1.75;
    font-size: clamp(12px, 1.4vw, 15px);
    margin-bottom: 30px;
}

#start-inner .controls {
    display: flex;
    justify-content: center;
    gap: 26px;
    color: #6f6a58;
    font-size: clamp(11px, 1.2vw, 14px);
    margin-bottom: 36px;
    flex-wrap: wrap;
}

#start-inner .controls b { color: #cfc389; }

#enter-btn {
    background: none;
    border: 1px solid #e8d872;
    color: #e8d872;
    font-family: inherit;
    font-size: clamp(15px, 1.8vw, 20px);
    letter-spacing: 6px;
    padding: 14px 46px;
    cursor: pointer;
    transition: background 0.25s, color 0.25s, box-shadow 0.25s;
}

#enter-btn:hover {
    background: #e8d872;
    color: #1a1608;
    box-shadow: 0 0 30px rgba(232,216,114,0.45);
}

#start-inner .hint {
    margin-top: 22px;
    color: #55503f;
    font-size: 12px;
    letter-spacing: 3px;
}

/* ---------- paused ---------- */
#paused-hint {
    position: absolute;
    inset: 0;
    z-index: 40;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,0.72);
    color: #ccc;
    letter-spacing: 5px;
    font-size: clamp(14px, 1.8vw, 20px);
    text-shadow: 0 0 8px rgba(255,255,255,0.5);
    cursor: pointer;
}

#paused-hint.active { display: flex; }
