/* CLUB RANDOMS - Futuristic Cyberpunk & Neon Disco Stylesheet */
@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@500;700;900&family=Rajdhani:wght@500;600;700&display=swap');

:root {
    --primary: #00ffff;
    --primary-glow: rgba(0, 255, 255, 0.45);
    --secondary: #ff007f;
    --secondary-glow: rgba(255, 0, 127, 0.45);
    --accent: #ffd700;
    --dark-bg: rgba(8, 8, 16, 0.88);
    --glass-border: rgba(255, 255, 255, 0.12);
    --font-heading: 'Orbitron', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-body: 'Rajdhani', -apple-system, BlinkMacSystemFont, sans-serif;
}

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

html, body {
    width: 100%;
    height: 100%;
    overflow: hidden;
    background-color: #030308;
    color: #e0e5ff;
    font-family: var(--font-body);
    font-size: 16px;
}

#canvas-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

/* ==========================================
   SCREEN SHADERS & DRINK EFFECTS
   ========================================== */
#screen-effects-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 5;
    transition: all 0.6s ease;
}

.effect-margarita {
    backdrop-filter: contrast(130%) hue-rotate(45deg) saturate(160%);
    box-shadow: inset 0 0 100px rgba(0, 255, 255, 0.5);
}

.effect-cyberpunk {
    backdrop-filter: contrast(160%) brightness(110%);
    box-shadow: inset 0 0 120px rgba(255, 0, 128, 0.6);
}

.effect-synthwave {
    backdrop-filter: sepia(35%) saturate(180%) hue-rotate(-20deg);
    box-shadow: inset 0 0 120px rgba(255, 120, 0, 0.4);
}

.effect-subzero {
    backdrop-filter: brightness(125%) hue-rotate(170deg) blur(0.5px);
    box-shadow: inset 0 0 140px rgba(100, 220, 255, 0.7);
}

/* ==========================================
   ENTRANCE BOUNCER MODAL
   ========================================== */
#entrance-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(5, 8, 18, 0.65); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.entrance-card {
    width: 90%;
    max-width: 520px;
    background: var(--dark-bg);
    border: 1px solid var(--primary);
    box-shadow: 0 0 40px var(--primary-glow);
    border-radius: 16px;
    padding: 32px;
    text-align: center;
    position: relative;
    backdrop-filter: blur(14px);
}

.entrance-header h1 {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    color: #ffffff;
    text-shadow: 0 0 15px var(--primary);
    letter-spacing: 2px;
}

.neon-subtitle {
    color: var(--secondary);
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: 3px;
    margin-top: 4px;
    text-shadow: 0 0 10px var(--secondary-glow);
}

.bouncer-dialogue {
    margin: 20px 0;
    background: rgba(0, 0, 0, 0.5);
    border-left: 3px solid var(--accent);
    padding: 12px 16px;
    font-size: 1.05rem;
    border-radius: 6px;
    color: #c9d5ea;
    text-align: left;
}

.entrance-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
    text-align: left;
}

.entrance-form label {
    font-family: var(--font-heading);
    font-size: 0.85rem;
    color: #8da4c4;
    letter-spacing: 1px;
}

.entrance-form input[type="text"] {
    width: 100%;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    color: #fff;
    font-family: var(--font-body);
    font-size: 1.2rem;
    outline: none;
    transition: all 0.3s ease;
}

.entrance-form input[type="text"]:focus {
    border-color: var(--primary);
    box-shadow: 0 0 15px var(--primary-glow);
}

.wristband-selection {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.wristband-btn {
    padding: 10px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--glass-border);
    color: #fff;
    font-family: var(--font-heading);
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.wristband-btn.active {
    border-color: var(--accent);
    background: rgba(255, 215, 0, 0.15);
    box-shadow: 0 0 15px rgba(255, 215, 0, 0.4);
    color: var(--accent);
}

.btn-enter-club {
    margin-top: 10px;
    padding: 16px;
    background: linear-gradient(135deg, var(--secondary) 0%, #7b00ff 100%);
    border: none;
    border-radius: 10px;
    color: #fff;
    font-family: var(--font-heading);
    font-size: 1.2rem;
    font-weight: 700;
    cursor: pointer;
    letter-spacing: 2px;
    box-shadow: 0 0 25px var(--secondary-glow);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-enter-club:hover {
    transform: scale(1.03);
    box-shadow: 0 0 35px var(--secondary-glow);
}

/* ==========================================
   MAIN HUD INTERFACE
   ========================================== */
#hud {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 10;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 16px;
}

#hud * {
    pointer-events: auto;
}

/* Top Bar */
.hud-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    gap: 16px;
}

.club-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--dark-bg);
    border: 1px solid var(--glass-border);
    padding: 8px 18px;
    border-radius: 30px;
    backdrop-filter: blur(10px);
}

.live-badge {
    background: #ff0044;
    color: #fff;
    font-family: var(--font-heading);
    font-size: 0.75rem;
    font-weight: 900;
    padding: 2px 8px;
    border-radius: 12px;
    box-shadow: 0 0 10px #ff0044;
    animation: livePulse 1.4s infinite;
}

@keyframes livePulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

.brand-text {
    font-family: var(--font-heading);
    font-weight: 900;
    font-size: 1.15rem;
    color: #fff;
    letter-spacing: 1.5px;
}

.now-playing-pill {
    background: var(--dark-bg);
    border: 1px solid var(--primary);
    box-shadow: 0 0 15px var(--primary-glow);
    padding: 8px 20px;
    border-radius: 30px;
    display: flex;
    align-items: center;
    gap: 14px;
    backdrop-filter: blur(10px);
}

.track-name {
    font-family: var(--font-heading);
    font-size: 0.9rem;
    color: #fff;
}

.track-bpm {
    color: var(--primary);
    font-weight: 700;
    font-size: 0.85rem;
}

.hud-user-info {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--dark-bg);
    border: 1px solid var(--glass-border);
    padding: 8px 16px;
    border-radius: 30px;
    backdrop-filter: blur(10px);
}

.user-coins {
    color: var(--accent);
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.95rem;
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

/* Navigation Drawer Buttons */
.hud-nav-bar {
    display: flex;
    gap: 8px;
    background: var(--dark-bg);
    border: 1px solid var(--glass-border);
    padding: 6px;
    border-radius: 30px;
    backdrop-filter: blur(10px);
}

.nav-pill-btn {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid transparent;
    color: #e2e8f0;
    padding: 8px 14px;
    border-radius: 20px;
    font-family: var(--font-heading);
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.nav-pill-btn:hover, .nav-pill-btn.active {
    background: var(--primary-glow);
    border-color: var(--primary);
    color: #fff;
    box-shadow: 0 0 12px var(--primary-glow);
}

/* Bottom Bar */
.hud-bottom {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    width: 100%;
    gap: 16px;
}

/* Dance Moves Bar */
.dance-moves-bar {
    display: flex;
    gap: 8px;
    background: var(--dark-bg);
    border: 1px solid var(--glass-border);
    padding: 8px 12px;
    border-radius: 16px;
    backdrop-filter: blur(12px);
}

.dance-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    color: #cbd5e1;
    padding: 10px 14px;
    border-radius: 10px;
    font-family: var(--font-heading);
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.dance-btn span.key {
    font-size: 0.65rem;
    color: var(--primary);
}

.dance-btn.active, .dance-btn:hover {
    background: rgba(255, 0, 127, 0.25);
    border-color: var(--secondary);
    color: #fff;
    box-shadow: 0 0 14px var(--secondary-glow);
    transform: translateY(-2px);
}

/* Camera Bar */
.camera-modes-bar {
    display: flex;
    gap: 6px;
    background: var(--dark-bg);
    border: 1px solid var(--glass-border);
    padding: 8px 12px;
    border-radius: 16px;
    backdrop-filter: blur(12px);
}

.cam-btn {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--glass-border);
    color: #cbd5e1;
    padding: 8px 12px;
    border-radius: 8px;
    font-family: var(--font-heading);
    font-size: 0.78rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.cam-btn.active, .cam-btn:hover {
    background: var(--primary);
    color: #000;
    font-weight: 700;
    box-shadow: 0 0 15px var(--primary-glow);
}

/* ==========================================
   SLIDING DRAWERS & PANELS
   ========================================== */
.drawer-panel {
    position: absolute;
    background: var(--dark-bg);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 20px;
    backdrop-filter: blur(18px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7);
    z-index: 50;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    display: none;
}

.drawer-panel.open {
    display: flex;
    flex-direction: column;
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 12px;
    margin-bottom: 16px;
}

.panel-header h2 {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    color: #fff;
    letter-spacing: 1px;
}

.btn-close-panel {
    background: none;
    border: none;
    color: #94a3b8;
    font-size: 1.4rem;
    cursor: pointer;
    line-height: 1;
}

.btn-close-panel:hover {
    color: #fff;
}

/* 1. DJ Soundboard Drawer */
#panel-soundboard {
    top: 75px;
    right: 20px;
    width: 320px;
}

.soundboard-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.sfx-btn {
    padding: 16px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    color: #fff;
    font-family: var(--font-heading);
    font-size: 0.85rem;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    transition: all 0.15s ease;
}

.sfx-btn span.icon {
    font-size: 1.8rem;
}

.sfx-btn:hover {
    background: rgba(0, 255, 255, 0.2);
    border-color: var(--primary);
    box-shadow: 0 0 18px var(--primary-glow);
    transform: scale(1.04);
}

.sfx-btn:active {
    transform: scale(0.96);
}

.co2-button {
    grid-column: span 2;
    background: linear-gradient(135deg, #00d2ff 0%, #00f0ff 100%);
    color: #030a10;
    font-weight: 900;
    box-shadow: 0 0 20px rgba(0, 240, 255, 0.5);
}

/* 2. Cyber-Bar Drinks Drawer */
#panel-bar {
    top: 75px;
    right: 20px;
    width: 360px;
    max-height: 80vh;
    overflow-y: auto;
}

.drinks-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.drink-card {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: all 0.2s ease;
}

.drink-card:hover {
    border-color: var(--accent);
    background: rgba(255, 215, 0, 0.08);
}

.drink-info h3 {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    color: #fff;
}

.drink-info p {
    font-size: 0.85rem;
    color: #94a3b8;
    margin-top: 2px;
}

.btn-order-drink {
    background: var(--accent);
    color: #000;
    border: none;
    border-radius: 8px;
    padding: 8px 12px;
    font-family: var(--font-heading);
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.4);
    transition: transform 0.15s ease;
}

.btn-order-drink:hover {
    transform: scale(1.05);
}

/* 3. Live Chat & Guestbook Drawer */
#panel-chat {
    bottom: 90px;
    left: 20px;
    width: 340px;
    height: 380px;
}

.chat-messages {
    flex: 1;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-right: 4px;
    margin-bottom: 12px;
}

.chat-bubble {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    padding: 8px 12px;
    font-size: 0.95rem;
    word-break: break-word;
}

.chat-bubble .meta {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    margin-bottom: 4px;
}

.chat-bubble .author {
    font-family: var(--font-heading);
    font-weight: 700;
}

.chat-input-row {
    display: flex;
    gap: 8px;
}

.chat-input-row input {
    flex: 1;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    padding: 10px;
    color: #fff;
    outline: none;
    font-family: var(--font-body);
}

.chat-input-row input:focus {
    border-color: var(--primary);
}

.btn-send-chat {
    background: var(--primary);
    color: #000;
    border: none;
    border-radius: 8px;
    padding: 0 16px;
    font-family: var(--font-heading);
    font-weight: 700;
    cursor: pointer;
}

/* 4. VJ Lighting Desk Drawer */
#panel-lighting {
    top: 75px;
    right: 20px;
    width: 320px;
}

.theme-selector-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-bottom: 16px;
}

.theme-btn {
    padding: 10px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    color: #fff;
    font-family: var(--font-heading);
    font-size: 0.8rem;
    cursor: pointer;
    text-align: center;
    transition: all 0.2s ease;
}

.theme-btn.active {
    border-color: var(--primary);
    box-shadow: 0 0 12px var(--primary-glow);
    background: rgba(0, 255, 255, 0.15);
}

/* 5. Photobooth Modal */
#photobooth-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(10px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1005;
}

.polaroid-frame {
    background: #ffffff;
    padding: 18px 18px 45px 18px;
    border-radius: 4px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.8);
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 90vw;
}

.polaroid-frame canvas {
    max-width: 100%;
    max-height: 60vh;
    border-radius: 2px;
}

.polaroid-caption {
    margin-top: 15px;
    font-family: var(--font-heading);
    color: #111;
    font-size: 1.1rem;
    letter-spacing: 1px;
    text-align: center;
}

.photobooth-actions {
    display: flex;
    gap: 12px;
    margin-top: 16px;
}

.btn-action-primary {
    background: var(--primary);
    color: #000;
    padding: 10px 20px;
    border-radius: 8px;
    font-family: var(--font-heading);
    font-weight: 700;
    cursor: pointer;
    border: none;
}

.btn-action-secondary {
    background: #333;
    color: #fff;
    padding: 10px 20px;
    border-radius: 8px;
    font-family: var(--font-heading);
    cursor: pointer;
    border: none;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .hud-top {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    .hud-bottom {
        flex-direction: column;
        align-items: stretch;
    }
    .dance-moves-bar {
        overflow-x: auto;
        justify-content: flex-start;
    }
    .drawer-panel {
        width: calc(100% - 40px) !important;
        left: 20px !important;
        right: 20px !important;
    }
}

/* ==========================================
   MOBILE TOUCH D-PAD
   ========================================== */
#mobile-dpad {
    position: absolute;
    bottom: 90px;
    right: 20px;
    width: 130px;
    height: 130px;
    z-index: 15;
    display: none;
}

@media (max-width: 900px), (pointer: coarse) {
    #mobile-dpad {
        display: block;
    }
}

.dpad-container {
    position: relative;
    width: 100%;
    height: 100%;
    background: rgba(10, 10, 20, 0.65);
    border: 1px solid var(--primary-glow);
    border-radius: 50%;
    box-shadow: 0 0 15px rgba(0, 255, 255, 0.25);
    backdrop-filter: blur(8px);
}

.dpad-btn {
    position: absolute;
    width: 38px;
    height: 38px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--glass-border);
    color: #fff;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.1rem;
    cursor: pointer;
    touch-action: none;
    transition: background 0.1s ease;
}

.dpad-btn:active {
    background: var(--primary);
    color: #000;
    box-shadow: 0 0 10px var(--primary);
}

.dpad-up    { top: 6px; left: 46px; }
.dpad-down  { bottom: 6px; left: 46px; }
.dpad-left  { top: 46px; left: 6px; }
.dpad-right { top: 46px; right: 6px; }

/* Dynamic Viewport height for iOS */
html, body {
    height: 100dvh;
    min-height: 100dvh;
}
