﻿/* =============================================
   PRO AUDIO EMPIRE - CYBERPUNK MIXING CONSOLE
   ============================================= */

/* Google Fonts removed - using system-ui */
:root {
    --bg-dark: #050510;
    --bg-panel: #0a0a1a;
    --bg-surface: #111128;
    --neon-cyan: #00f3ff;
    --neon-pink: #ff00ff;
    --neon-purple: #8b5cf6;
    --neon-green: #00ff41;
    --neon-gold: #ffd700;
    --neon-red: #ff2244;
    --glow-cyan: 0 0 10px rgba(0, 243, 255, 0.5), 0 0 30px rgba(0, 243, 255, 0.2);
    --glow-pink: 0 0 10px rgba(255, 0, 255, 0.5), 0 0 30px rgba(255, 0, 255, 0.2);
    --glow-gold: 0 0 10px rgba(255, 215, 0, 0.5), 0 0 30px rgba(255, 215, 0, 0.2);
    --font-display: 'Orbitron', sans-serif;
    --font-mono: 'Courier New', monospace;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

body {
    background: var(--bg-dark);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    min-height: 100dvh;
    overflow: hidden;
    font-family: var(--font-display);
    color: #eee;
}

/* =============================================
   GAME CONTAINER (9:16 Enforced)
   ============================================= */
.game-container {
    width: 100vw;
    max-width: 56.25vh;
    height: 100vh;
    height: 100dvh;
    display: flex;
    flex-direction: column;
    position: relative;
    background: var(--bg-dark);
    overflow: hidden;
}

/* =============================================
   ZONE 1: LOGO (15%)
   ============================================= */
.zone-logo {
    flex: 0 0 15%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: linear-gradient(180deg, #0a0a2a 0%, var(--bg-dark) 100%);
    position: relative;
    padding: 5px 10px;
    gap: 2px;
}

.neon-border {
    position: absolute;
    left: 10%;
    right: 10%;
    height: 2px;
    background: var(--neon-cyan);
    box-shadow: var(--glow-cyan);
    animation: neonPulse 2s ease-in-out infinite;
}

.neon-border.top {
    top: 0;
}

.logo-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

.logo-icon {
    display: flex;
    gap: 3px;
    align-items: flex-end;
    height: 20px;
    margin-bottom: 2px;
}

.logo-eq-bar {
    width: 4px;
    height: var(--h, 50%);
    background: linear-gradient(180deg, var(--neon-pink), var(--neon-cyan));
    border-radius: 2px;
    animation: eqBounce 1.5s ease-in-out infinite;
    box-shadow: 0 0 5px var(--neon-cyan);
}

.logo-eq-bar:nth-child(1) {
    animation-delay: 0s;
}

.logo-eq-bar:nth-child(2) {
    animation-delay: 0.2s;
}

.logo-eq-bar:nth-child(3) {
    animation-delay: 0.1s;
}

.logo-eq-bar:nth-child(4) {
    animation-delay: 0.3s;
}

.logo-eq-bar:nth-child(5) {
    animation-delay: 0.15s;
}

.game-title {
    font-family: var(--font-display);
    font-size: clamp(1rem, 4.5vw, 1.6rem);
    font-weight: 900;
    letter-spacing: 3px;
    background: linear-gradient(90deg, var(--neon-cyan), var(--neon-pink), var(--neon-cyan));
    background-size: 200% 100%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientShift 3s linear infinite;
    text-shadow: none;
    filter: drop-shadow(0 0 8px rgba(0, 243, 255, 0.3));
}

.subtitle {
    font-size: 0.5rem;
    letter-spacing: 6px;
    color: #666;
    font-weight: 400;
}

.jackpot-display {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 215, 0, 0.05);
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: 4px;
    padding: 2px 12px;
    margin-top: 3px;
}

.jackpot-label {
    font-size: 0.5rem;
    color: var(--neon-gold);
    letter-spacing: 2px;
}

.jackpot-amount {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    color: var(--neon-gold);
    text-shadow: 0 0 8px rgba(255, 215, 0, 0.5);
}

/* =============================================
   ZONE 2: REELS (50%)
   ============================================= */
.zone-reels {
    flex: 0 0 50%;
    display: flex;
    flex-direction: column;
    position: relative;
    background: #000;
    border-top: 1px solid rgba(0, 243, 255, 0.2);
    border-bottom: 1px solid rgba(0, 243, 255, 0.2);
    overflow: hidden;
}

.reel-viewport {
    flex: 1;
    position: relative;
    overflow: hidden;
    width: 100%;
    height: 100%;
}

.reel-mask {
    width: 100%;
    height: 100%;
    overflow: hidden;
    position: absolute;
    inset: 0;
    /* Fade edges */
    mask-image: linear-gradient(180deg,
            transparent 0%,
            black 12%,
            black 88%,
            transparent 100%);
    -webkit-mask-image: linear-gradient(180deg,
            transparent 0%,
            black 12%,
            black 88%,
            transparent 100%);
}

.reels-container {
    display: flex;
    height: 100%;
    gap: 0;
    position: relative;
}

.reel-col {
    flex: 1;
    height: 100%;
    position: relative;
    overflow: hidden !important;
}

.reel-divider {
    width: 1px;
    background: linear-gradient(180deg, transparent, rgba(0, 243, 255, 0.3), transparent);
    flex-shrink: 0;
}

.reel-strip {
    display: flex;
    flex-direction: column;
    will-change: transform;
}

/* --- Symbols --- */
.symbol {
    width: 100%;
    height: 80px;
    min-height: 80px;
    max-height: 80px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 4px;
    position: relative;
    flex-shrink: 0;
}

.symbol img {
    max-width: 75%;
    max-height: 75%;
    object-fit: contain;
    filter: drop-shadow(0 0 3px var(--neon-cyan));
}

.symbol .symbol-emoji {
    font-size: 2.5rem;
    line-height: 1;
    filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.5));
}

.symbol .symbol-name {
    font-size: 0.5rem;
    color: #888;
    margin-top: 2px;
    font-family: var(--font-display);
    letter-spacing: 1px;
}

/* Special symbol glow */
.symbol.special-wild {
    background: radial-gradient(circle, rgba(0, 243, 255, 0.1) 0%, transparent 70%);
}

.symbol.special-scatter {
    background: radial-gradient(circle, rgba(255, 215, 0, 0.1) 0%, transparent 70%);
}

.symbol.special-freespin {
    background: radial-gradient(circle, rgba(255, 0, 255, 0.1) 0%, transparent 70%);
}

.symbol.special-bonus {
    background: radial-gradient(circle, rgba(139, 92, 246, 0.1) 0%, transparent 70%);
}

/* Payline indicators */
.payline-indicator {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 0;
    height: 0;
    border: 8px solid transparent;
    z-index: 10;
}

.payline-indicator.left {
    left: 0;
    border-left: 10px solid var(--neon-cyan);
}

.payline-indicator.right {
    right: 0;
    border-right: 10px solid var(--neon-cyan);
}

/* Notification bar */
.notification-bar {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 24px;
    background: rgba(0, 0, 0, 0.85);
    border-top: 1px solid rgba(0, 243, 255, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.6rem;
    color: var(--neon-cyan);
    letter-spacing: 2px;
    transform: translateY(100%);
    transition: transform 0.3s ease;
    z-index: 15;
}

.notification-bar.show {
    transform: translateY(0);
}

/* Win line overlay */
.win-lines-overlay {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 20;
}

.win-line {
    position: absolute;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--neon-gold);
    box-shadow: 0 0 10px var(--neon-gold), 0 0 20px var(--neon-gold), 0 0 40px var(--neon-gold);
    opacity: 0;
    transition: opacity 0.2s;
    z-index: 20;
}

.win-line.active {
    opacity: 1;
    animation: winLinePulse 0.5s ease-in-out infinite;
}

.win-dot {
    position: absolute;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--neon-gold);
    box-shadow: 0 0 8px var(--neon-gold), 0 0 16px var(--neon-gold), 0 0 30px rgba(255, 215, 0, 0.5);
    z-index: 21;
    animation: winDotPulse 0.4s ease-in-out infinite alternate;
}

@keyframes winDotPulse {
    from {
        transform: scale(1);
        box-shadow: 0 0 8px var(--neon-gold), 0 0 16px var(--neon-gold);
    }

    to {
        transform: scale(1.5);
        box-shadow: 0 0 12px var(--neon-gold), 0 0 24px var(--neon-gold), 0 0 40px rgba(255, 215, 0, 0.6);
    }
}

/* =============================================
   ZONE 3: FADERS (20%) - MIXING CONSOLE STYLE
   ============================================= */
.zone-faders {
    flex: 0 0 20%;
    display: flex;
    justify-content: space-around;
    align-items: stretch;
    padding: 8px 15px;
    background: var(--bg-panel);
    border-top: 1px solid rgba(0, 243, 255, 0.15);
    gap: 10px;
}

.fader-module {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.fader-label {
    font-family: var(--font-display);
    font-size: 0.55rem;
    color: var(--neon-cyan);
    letter-spacing: 2px;
    text-shadow: 0 0 5px rgba(0, 243, 255, 0.3);
}

/* --- Mixing Console Fader Track --- */
.fader-track {
    flex: 1;
    width: 36px;
    background: linear-gradient(90deg, #0a0a0a 0%, #1a1a2a 45%, #0a0a0a 50%, #1a1a2a 55%, #0a0a0a 100%);
    border: 1px solid #444;
    border-radius: 3px;
    position: relative;
    display: flex;
    justify-content: center;
    min-height: 60px;
    /* Console groove inset */
    box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.9),
        inset 1px 0 0 rgba(80, 80, 80, 0.2),
        inset -1px 0 0 rgba(80, 80, 80, 0.2);
}

.fader-glow {
    position: absolute;
    inset: -1px;
    border-radius: 3px;
    background: transparent;
    box-shadow: inset 0 0 8px rgba(0, 243, 255, 0.08);
    pointer-events: none;
}

/* Center rail line */
.fader-rail {
    width: 2px;
    height: 100%;
    background: linear-gradient(180deg, var(--neon-cyan), var(--neon-purple), var(--neon-pink));
    opacity: 0.25;
    border-radius: 1px;
}

/* --- Mixing Console Fader Cap (THICK METALLIC) --- */
.fader-cap {
    width: 60px;
    height: 30px;
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    cursor: grab;
    z-index: 50;
    touch-action: none;
    /* Metallic surface */
    background: linear-gradient(180deg,
            #666 0%,
            #8a8a8a 8%,
            #555 15%,
            #3a3a3a 40%,
            #1a1a1a 50%,
            #3a3a3a 60%,
            #555 85%,
            #8a8a8a 92%,
            #666 100%);
    border-radius: 3px;
    border: 1px solid #777;
    box-shadow:
        0 2px 8px rgba(0, 0, 0, 0.9),
        0 0 4px rgba(0, 243, 255, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.15),
        inset 0 -1px 0 rgba(0, 0, 0, 0.3);
    display: flex;
    justify-content: center;
    align-items: center;
}

.fader-cap:active {
    cursor: grabbing;
    border-color: var(--neon-cyan);
    box-shadow:
        0 0 12px rgba(0, 243, 255, 0.5),
        0 2px 8px rgba(0, 0, 0, 0.9),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

/* Cap center notch line (classic mixing console indicator) */
.fader-line {
    width: 75%;
    height: 3px;
    background: linear-gradient(90deg, transparent 10%, var(--neon-cyan) 30%, var(--neon-cyan) 70%, transparent 90%);
    border-radius: 1px;
    box-shadow: 0 0 6px var(--neon-cyan), 0 0 2px var(--neon-cyan);
    opacity: 0.8;
}

.fader-ticks {
    position: absolute;
    right: -32px;
    top: 0;
    bottom: 0;
    width: 30px;
    pointer-events: none;
}

.tick {
    position: absolute;
    top: var(--pos, 0%);
    right: 0;
    font-size: 0.5rem;
    color: #555;
    font-family: var(--font-mono);
    transform: translateY(-50%);
}

.fader-value {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    color: var(--neon-cyan);
    text-shadow: 0 0 5px rgba(0, 243, 255, 0.3);
    min-width: 40px;
    text-align: center;
}

/* =============================================
   ZONE 4: CONTROLS (15%)
   ============================================= */
.zone-controls {
    flex: 0 0 15%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 5px 10px;
    padding-bottom: max(5px, env(safe-area-inset-bottom));
    background: linear-gradient(180deg, var(--bg-panel) 0%, #050515 100%);
    border-top: 1px solid rgba(0, 243, 255, 0.2);
    gap: 5px;
}

.info-panel {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
}

.info-cell {
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid #222;
    border-radius: 4px;
    padding: 2px 6px;
    text-align: center;
}

.info-label {
    font-size: 0.4rem;
    color: #555;
    letter-spacing: 1px;
}

.info-value {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    font-weight: 700;
}

.neon-cyan {
    color: var(--neon-cyan);
    text-shadow: 0 0 5px rgba(0, 243, 255, 0.4);
}

.neon-pink {
    color: var(--neon-pink);
    text-shadow: 0 0 5px rgba(255, 0, 255, 0.4);
}

.neon-green {
    color: var(--neon-green);
    text-shadow: 0 0 5px rgba(0, 255, 65, 0.4);
}

.neon-gold {
    color: var(--neon-gold);
    text-shadow: var(--glow-gold);
}

/* Spin Button */
.spin-button {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 35%, #ff4444, #aa0000 60%, #660000);
    border: 3px solid #ff6666;
    box-shadow:
        0 0 20px rgba(255, 0, 0, 0.5),
        0 0 40px rgba(255, 0, 0, 0.2),
        inset 0 2px 4px rgba(255, 255, 255, 0.3),
        0 4px 0 #330000;
    cursor: pointer;
    outline: none;
    position: relative;
    flex-shrink: 0;
    transition: all 0.15s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.spin-text {
    font-family: var(--font-display);
    font-size: 0.85rem;
    font-weight: 900;
    color: #fff;
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.5);
    letter-spacing: 2px;
    position: relative;
    z-index: 2;
}

.spin-ring {
    position: absolute;
    inset: -5px;
    border: 2px solid rgba(255, 0, 0, 0.4);
    border-radius: 50%;
    animation: spinRingPulse 2s ease-in-out infinite;
}

.spin-button:active {
    transform: translateY(3px) scale(0.95);
    box-shadow:
        0 0 30px rgba(255, 0, 0, 0.8),
        inset 0 2px 4px rgba(255, 255, 255, 0.3);
    background: radial-gradient(circle at 35% 35%, #cc0000, #770000);
}

.spin-button.disabled {
    opacity: 0.4;
    pointer-events: none;
}

/* =============================================
   BIG WIN OVERLAY
   ============================================= */
.big-win-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
}

.big-win-overlay.show {
    opacity: 1;
    pointer-events: auto;
}

.big-win-text {
    font-family: var(--font-display);
    font-size: 2.5rem;
    font-weight: 900;
    background: linear-gradient(90deg, var(--neon-gold), #fff, var(--neon-gold));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: bigWinPulse 0.5s ease-in-out infinite;
    filter: drop-shadow(0 0 20px rgba(255, 215, 0, 0.8));
}

.big-win-amount {
    font-family: var(--font-mono);
    font-size: 2rem;
    color: var(--neon-gold);
    text-shadow: 0 0 20px rgba(255, 215, 0, 0.8);
    margin-top: 10px;
}

/* =============================================
   ANIMATIONS
   ============================================= */
@keyframes neonPulse {

    0%,
    100% {
        opacity: 0.6;
    }

    50% {
        opacity: 1;
    }
}

@keyframes eqBounce {

    0%,
    100% {
        transform: scaleY(1);
    }

    50% {
        transform: scaleY(0.5);
    }
}

@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }

    100% {
        background-position: 200% 50%;
    }
}

@keyframes spinRingPulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 0.4;
    }

    50% {
        transform: scale(1.15);
        opacity: 0.8;
    }
}

@keyframes bigWinPulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.1);
    }
}

@keyframes winLinePulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.4;
    }
}

@keyframes winSymbolGlow {

    0%,
    100% {
        filter: brightness(1) drop-shadow(0 0 5px var(--neon-gold));
    }

    50% {
        filter: brightness(1.5) drop-shadow(0 0 15px var(--neon-gold));
    }
}

.symbol.winning {
    animation: winSymbolGlow 0.6s ease-in-out infinite;
}

/* Reel spinning blur */
.reel-strip.spinning {
    filter: blur(2px);
}

/* =============================================
   DESKTOP SCALING
   ============================================= */
@media (min-width: 1025px) {
    .game-container {
        max-width: 400px;
        border-left: 2px solid rgba(0, 243, 255, 0.2);
        border-right: 2px solid rgba(0, 243, 255, 0.2);
        border-radius: 12px;
        overflow: hidden;
        box-shadow:
            0 0 40px rgba(0, 243, 255, 0.15),
            0 0 80px rgba(139, 92, 246, 0.1);
    }
}