/* ==========================================
   404 KM - CYBERPUNK / HACKER TERMINAL EDITION (STYLESHEET)
   Matrix, Mr. Robot & Black Mirror Estetiği
   ========================================== */

/* Root Değişkenleri & Hacker Renk Paleti */
:root {
    --bg-color: #020202;
    --card-bg: rgba(0, 20, 5, 0.65);
    --card-border: rgba(0, 255, 65, 0.2);
    --card-border-hover: rgba(0, 255, 65, 0.7);
    --text-main: #00ff41;
    --text-dimmed: #008f11;
    --text-muted: #4e9a06;
    --neon-green: #00ff41;
    --neon-red: #ff0055;
    --neon-cyan: #00f3ff;
    --glow-green: rgba(0, 255, 65, 0.25);
    --glow-red: rgba(255, 0, 85, 0.3);
    --font-primary: "Courier New", Courier, monospace, -apple-system;
    --transition-smooth: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-quick: all 0.2s ease;
}

/* Sıfırlama & Temel Ayarlar */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

html, body {
    width: 100%;
    height: 100vh;
    height: 100dvh;
    overflow: hidden;
    background-color: var(--bg-color);
    color: var(--text-main);
    font-family: var(--font-primary);
    text-shadow: 0 0 8px rgba(0, 255, 65, 0.4);
}

/* Matrix Tarzı Dijital Yağmur / Arka Plan Katmanı */
.space-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
    overflow: hidden;
    background: radial-gradient(circle at center, #050d05 0%, #020202 100%);
}

.stars-layer {
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background-image: 
        linear-gradient(rgba(0, 255, 65, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 255, 65, 0.05) 1px, transparent 1px);
    background-size: 30px 30px;
    animation: scanlineGrid 20s linear infinite;
    opacity: 0.3;
}

@keyframes scanlineGrid {
    0% { transform: translateY(0); }
    100% { transform: translateY(30px); }
}

/* CRT Tarama Çizgisi Efekti (Retro Hacker Monitörü) */
body::after {
    content: " ";
    display: block;
    position: fixed;
    top: 0; left: 0; bottom: 0; right: 0;
    background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.25) 50%), linear-gradient(90deg, rgba(255, 0, 0, 0.03), rgba(0, 255, 0, 0.01), rgba(0, 0, 255, 0.03));
    z-index: 998;
    background-size: 100% 3px, 6px 100%;
    pointer-events: none;
}

/* Tehlike / Uyarı Sızıntıları (Glitch Glow) */
.nebula-glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    z-index: 2;
    opacity: 0.4;
    pointer-events: none;
    transition: var(--transition-smooth);
}

.glow-1 {
    width: 400px;
    height: 400px;
    background: var(--glow-green);
    top: 5%;
    left: 10%;
    animation: floatGlow1 10s ease-in-out infinite alternate;
}

.glow-2 {
    width: 450px;
    height: 450px;
    background: var(--glow-red);
    bottom: 5%;
    right: 10%;
    animation: floatGlow2 12s ease-in-out infinite alternate;
}

@keyframes floatGlow1 {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(30px, 40px) scale(1.1); }
}

@keyframes floatGlow2 {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(-40px, -30px) scale(1.15); }
}

/* Parallax Taşıyıcı */
.parallax-container {
    position: relative;
    width: 100%;
    height: 100%;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Sahne */
.cinematic-stage {
    width: 100%;
    max-width: 650px;
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Hacker Terminal Konsolu (Glassmorphism + Terminal Border) */
.glass-card {
    position: relative;
    width: 100%;
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--card-border);
    border-radius: 6px;
    padding: 40px 30px;
    box-shadow: 0 0 40px rgba(0, 255, 65, 0.15), inset 0 0 15px rgba(0, 255, 65, 0.05);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: left;
    transition: var(--transition-smooth);
}

.glass-card::before {
    content: "ROOT@194KM-SECURE-TERMINAL:~#";
    position: absolute;
    top: 12px;
    left: 18px;
    font-size: 0.75rem;
    color: var(--text-muted);
    letter-spacing: 0.1em;
}

/* İçerik Alanı */
.content-wrapper {
    width: 100%;
    min-height: 140px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    margin-top: 15px;
    margin-bottom: 25px;
}

.typewriter-container {
    width: 100%;
}

.cinematic-text {
    font-size: 1.25rem;
    font-weight: 500;
    letter-spacing: 0.05em;
    line-height: 1.6;
    color: var(--text-main);
    opacity: 0;
    transform: translateY(8px);
    animation: fadeInText 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.cinematic-text.highlight {
    font-weight: 700;
    color: var(--neon-cyan);
    text-shadow: 0 0 12px rgba(0, 243, 255, 0.6);
    font-size: 1.6rem;
}

.cinematic-text.danger {
    color: var(--neon-red);
    text-shadow: 0 0 12px rgba(255, 0, 85, 0.6);
}

.cinematic-text.subtext {
    font-size: 1rem;
    color: var(--text-dimmed);
    margin-top: 8px;
}

@keyframes fadeInText {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Buton Alanı */
.action-wrapper {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: center;
}

/* Terminal Komut Butonları */
.cinematic-btn {
    position: relative;
    width: 100%;
    max-width: 400px;
    padding: 14px 20px;
    background: rgba(0, 255, 65, 0.03);
    border: 1px solid rgba(0, 255, 65, 0.3);
    border-radius: 4px;
    color: var(--text-main);
    font-family: var(--font-primary);
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    cursor: pointer;
    text-align: left;
    transition: var(--transition-quick);
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 0 10px rgba(0, 255, 65, 0.05);
}

.cinematic-btn::before {
    content: ">";
    color: var(--neon-cyan);
    font-weight: bold;
}

.cinematic-btn:hover {
    background: rgba(0, 255, 65, 0.12);
    border-color: var(--neon-green);
    box-shadow: 0 0 20px rgba(0, 255, 65, 0.3);
    color: #ffffff;
    transform: translateX(4px);
}

.cinematic-btn:active {
    transform: translateX(0);
}

.cinematic-btn .icon {
    font-size: 1.1rem;
}

/* Seçenek Izgarası */
.options-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
    width: 100%;
    max-width: 450px;
}

/* Sistem Kararma / Kernel Panic Perdesi */
.cinematic-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #000000;
    z-index: 999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s ease;
}

.cinematic-overlay.active {
    opacity: 1;
    pointer-events: all;
}

/* Terminal Loader */
.loader-container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
    width: 100%;
}

.spinner {
    width: 24px;
    height: 24px;
    border: 2px solid rgba(0, 255, 65, 0.2);
    border-top-color: var(--neon-green);
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Mobil Optimizasyon */
@media (max-width: 480px) {
    .glass-card {
        padding: 30px 15px;
    }

    .cinematic-text {
        font-size: 1.05rem;
    }

    .cinematic-text.highlight {
        font-size: 1.35rem;
    }
}