@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;600;700;800&family=JetBrains+Mono:wght@500;700&display=swap');

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

html, body {
    width: 100%;
    height: 100%;
    overflow: hidden;
    background-color: #070d1e;
    font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
    color: #f1f5f9;
}

#canvas3d {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    display: block;
    outline: none;
    z-index: 1;
}

/* Glassmorphism Classes */
.glass-ui {
    background: rgba(7, 13, 30, 0.7);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.5), 0 0 15px rgba(6, 182, 212, 0.1);
}

/* Loading Overlay */
#loadingScreen {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: radial-gradient(circle at center, #0f1c3f 0%, #060b18 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1), visibility 0.8s;
}

#loadingScreen.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.loader-brand {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    margin-bottom: 28px;
}

.loader-logo {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, #0284c7 0%, #06b6d4 100%);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 35px rgba(6, 182, 212, 0.5);
    animation: floatLogo 2.5s ease-in-out infinite alternate;
}

.loader-logo svg {
    width: 36px;
    height: 36px;
    fill: none;
    stroke: #ffffff;
    stroke-width: 2.2;
}

.loader-title {
    font-size: 24px;
    font-weight: 800;
    letter-spacing: -0.5px;
    color: #ffffff;
}

.loader-title span {
    color: #06b6d4;
}

.loader-subtitle {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: #94a3b8;
    font-weight: 600;
}

.loader-progress-box {
    width: 280px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 999px;
    padding: 3px;
    position: relative;
    overflow: hidden;
}

.loader-bar {
    width: 0%;
    height: 6px;
    background: linear-gradient(90deg, #0284c7, #06b6d4, #10b981);
    border-radius: 999px;
    transition: width 0.3s ease;
    box-shadow: 0 0 12px rgba(6, 182, 212, 0.8);
}

.loader-status {
    margin-top: 14px;
    font-size: 12px;
    color: #94a3b8;
    font-family: 'JetBrains Mono', monospace;
}

/* Top Navigation Bar */
.top-nav {
    position: fixed;
    top: 16px;
    left: 20px;
    right: 20px;
    z-index: 100;
    display: flex;
    justify-content: space-between;
    align-items: center;
    pointer-events: none;
}

.brand-badge {
    pointer-events: auto;
    padding: 10px 18px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.brand-badge .badge-icon {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    background: linear-gradient(135deg, #0284c7, #06b6d4);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.brand-badge .badge-text h1 {
    font-size: 15px;
    font-weight: 800;
    color: #fff;
    line-height: 1.1;
}

.brand-badge .badge-text h1 span {
    color: #06b6d4;
}

.brand-badge .badge-text p {
    font-size: 10px;
    color: #94a3b8;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.nav-actions {
    pointer-events: auto;
    display: flex;
    align-items: center;
    gap: 10px;
}

.nav-btn {
    padding: 9px 16px;
    border-radius: 12px;
    background: rgba(15, 23, 42, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #e2e8f0;
    font-size: 12px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.nav-btn:hover {
    background: rgba(30, 41, 59, 0.9);
    border-color: rgba(6, 182, 212, 0.4);
    color: #06b6d4;
    transform: translateY(-1px);
}

.nav-btn.primary {
    background: linear-gradient(135deg, #0284c7, #06b6d4);
    border-color: rgba(6, 182, 212, 0.5);
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(6, 182, 212, 0.35);
}

.nav-btn.primary:hover {
    background: linear-gradient(135deg, #0369a1, #0891b2);
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(6, 182, 212, 0.5);
}

/* Controls Hint / HUD Overlay */
.bottom-hud {
    position: fixed;
    bottom: 20px;
    left: 20px;
    right: 20px;
    z-index: 100;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    pointer-events: none;
}

.controls-hint {
    pointer-events: auto;
    padding: 10px 18px;
    border-radius: 16px;
    font-size: 11px;
    color: #cbd5e1;
    display: flex;
    align-items: center;
    gap: 16px;
}

.hint-item {
    display: flex;
    align-items: center;
    gap: 7px;
}

.kbd-badge {
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 6px;
    padding: 3px 8px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    font-weight: 700;
    color: #06b6d4;
}

/* Mobile & Tablet Virtual Touch Controls (360° Dynamic Joystick) */
.touch-controls-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 200;
    pointer-events: none;
}

/* Left Touch Area for Dynamic 360° Joystick */
.joystick-zone {
    position: absolute;
    top: 0;
    left: 0;
    width: 50vw;
    height: 100vh;
    pointer-events: auto;
    touch-action: none;
}

/* Joystick Base */
.joystick-base {
    position: absolute;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(6, 182, 212, 0.2) 0%, rgba(9, 17, 39, 0.8) 100%);
    border: 2px solid rgba(6, 182, 212, 0.55);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 0 30px rgba(6, 182, 212, 0.35), inset 0 0 15px rgba(6, 182, 212, 0.2);
    transform: translate(-50%, -50%);
    display: none;
    pointer-events: none;
}

/* Joystick Knob */
.joystick-knob {
    position: absolute;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0284c7 0%, #06b6d4 100%);
    box-shadow: 0 0 20px rgba(6, 182, 212, 0.8), 0 4px 10px rgba(0, 0, 0, 0.5);
    border: 2px solid rgba(255, 255, 255, 0.4);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
}

/* Idle Joystick Hint Ring */
.joystick-hint {
    position: absolute;
    bottom: 36px;
    left: 36px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    pointer-events: none;
    opacity: 0.7;
    animation: joystickPulse 2.5s infinite alternate ease-in-out;
}

.joystick-hint-ring {
    width: 76px;
    height: 76px;
    border-radius: 50%;
    border: 2px dashed rgba(6, 182, 212, 0.65);
    background: rgba(6, 182, 212, 0.1);
}

.joystick-hint span {
    font-size: 11px;
    font-weight: 700;
    color: #38bdf8;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.8);
    letter-spacing: -0.2px;
}

@keyframes joystickPulse {
    0% { transform: scale(0.96); opacity: 0.55; }
    100% { transform: scale(1.04); opacity: 0.9; }
}

/* Action Buttons (Right Touch Zone) */
.action-buttons {
    position: absolute;
    bottom: 30px;
    right: 24px;
    pointer-events: auto;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.action-btn {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: rgba(9, 17, 39, 0.85);
    border: 2px solid rgba(6, 182, 212, 0.45);
    color: #ffffff;
    font-size: 11px;
    font-weight: 800;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    cursor: pointer;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.5), 0 0 15px rgba(6, 182, 212, 0.2);
    transition: all 0.15s;
    user-select: none;
    touch-action: manipulation;
}

.action-btn:active {
    background: rgba(6, 182, 212, 0.7);
    border-color: #06b6d4;
    transform: scale(0.92);
}

.action-btn svg {
    width: 22px;
    height: 22px;
}

/* Animations */
@keyframes floatLogo {
    0% { transform: translateY(0px) rotate(0deg); }
    100% { transform: translateY(-8px) rotate(3deg); }
}

@media (max-width: 1024px), (hover: none) and (pointer: coarse) {
    .controls-hint {
        display: none !important;
    }
    .touch-controls-overlay {
        display: block !important;
    }
    .top-nav {
        left: 10px;
        right: 10px;
        top: 10px;
        gap: 6px;
    }
    .brand-badge {
        padding: 6px 10px;
    }
    .brand-badge .badge-text p {
        display: none;
    }
    .nav-btn {
        padding: 6px 10px;
        font-size: 11px;
    }
}

/* ==========================================================================
   NPC Interaction Prompt & Dialogue Modal (Tahap 03)
   ========================================================================== */

/* 1. Floating NPC Prompt */
.interaction-prompt {
    position: fixed;
    bottom: 90px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 100;
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 10px 18px;
    border-radius: 40px;
    border: 1px solid rgba(6, 182, 212, 0.45);
    background: rgba(7, 13, 30, 0.88);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6), 0 0 20px rgba(6, 182, 212, 0.35);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    animation: promptPulse 2s ease-in-out infinite alternate;
}

.interaction-prompt.hidden {
    opacity: 0;
    visibility: hidden;
    transform: translateX(-50%) translateY(20px) scale(0.95);
    pointer-events: none;
}

.prompt-icon {
    font-size: 24px;
    filter: drop-shadow(0 0 8px rgba(6, 182, 212, 0.6));
}

.prompt-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.prompt-name {
    font-size: 13px;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: -0.2px;
}

.prompt-desc {
    font-size: 11px;
    color: #94a3b8;
}

.prompt-desc kbd {
    background: rgba(255, 255, 255, 0.15);
    color: #38bdf8;
    padding: 1px 6px;
    border-radius: 4px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    font-weight: 700;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.prompt-action-btn {
    padding: 8px 18px;
    background: linear-gradient(135deg, #0284c7 0%, #06b6d4 100%);
    border: none;
    border-radius: 20px;
    color: #ffffff;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.3px;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(6, 182, 212, 0.4);
    transition: all 0.2s;
}

.prompt-action-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(6, 182, 212, 0.6);
}

.prompt-action-btn:active {
    transform: scale(0.95);
}

/* 2. Dialogue Modal Card */
.dialogue-modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 1000;
    background: rgba(4, 9, 20, 0.65);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.dialogue-modal-backdrop.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.dialogue-card {
    position: relative;
    max-width: 520px;
    width: 100%;
    border-radius: 24px;
    padding: 28px 24px 22px 24px;
    background: rgba(9, 17, 39, 0.92);
    border: 1px solid rgba(6, 182, 212, 0.35);
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.8), 0 0 30px rgba(6, 182, 212, 0.2);
    transform: scale(1);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.dialogue-modal-backdrop.hidden .dialogue-card {
    transform: scale(0.92) translateY(20px);
}

.dialogue-close {
    position: absolute;
    top: 16px;
    right: 18px;
    background: transparent;
    border: none;
    color: #94a3b8;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    transition: color 0.2s, transform 0.2s;
}

.dialogue-close:hover {
    color: #ffffff;
    transform: scale(1.15);
}

.dialogue-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
    padding-bottom: 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.dialogue-avatar {
    width: 54px;
    height: 54px;
    background: linear-gradient(135deg, rgba(2, 132, 199, 0.3) 0%, rgba(6, 182, 212, 0.3) 100%);
    border: 1px solid rgba(6, 182, 212, 0.4);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    flex-shrink: 0;
}

.dialogue-meta h3 {
    font-size: 18px;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 4px;
}

.dialogue-badge {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    color: #38bdf8;
    background: rgba(56, 189, 248, 0.12);
    padding: 3px 10px;
    border-radius: 12px;
    border: 1px solid rgba(56, 189, 248, 0.25);
}

.dialogue-body {
    margin-bottom: 22px;
}

.dialogue-body p {
    font-size: 14px;
    line-height: 1.65;
    color: #cbd5e1;
}

.dialogue-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

.dialogue-btn {
    padding: 10px 20px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    border: none;
    font-family: inherit;
}

.dialogue-btn.primary {
    background: linear-gradient(135deg, #0284c7 0%, #06b6d4 100%);
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(6, 182, 212, 0.35);
}

.dialogue-btn.primary:hover {
    box-shadow: 0 6px 22px rgba(6, 182, 212, 0.55);
    transform: translateY(-1px);
}

.dialogue-btn.secondary {
    background: rgba(255, 255, 255, 0.08);
    color: #94a3b8;
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.dialogue-btn.secondary:hover {
    background: rgba(255, 255, 255, 0.14);
    color: #ffffff;
}

@keyframes promptPulse {
    0% { box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6), 0 0 15px rgba(6, 182, 212, 0.25); }
    100% { box-shadow: 0 12px 35px rgba(0, 0, 0, 0.7), 0 0 28px rgba(6, 182, 212, 0.55); }
}

@media (max-width: 1024px), (hover: none) and (pointer: coarse) {
    .interaction-prompt {
        bottom: 125px;
        width: calc(100% - 32px);
        max-width: 380px;
        justify-content: space-between;
    }
    .dialogue-card {
        padding: 22px 18px 18px 18px;
        max-height: 88vh;
        overflow-y: auto;
    }
    .dialogue-actions {
        flex-direction: column-reverse;
    }
    .dialogue-btn {
        width: 100%;
        text-align: center;
    }
}

/* ==========================================================================
   Tahap 05: Business Modals, Quest Gamification & WhatsApp Conversion
   ========================================================================== */

/* 1. Quest HUD Badge */
.quest-hud-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    border-radius: 20px;
    border: 1px solid rgba(245, 158, 11, 0.4);
    background: rgba(15, 23, 42, 0.85);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4), 0 0 12px rgba(245, 158, 11, 0.25);
    transition: transform 0.3s;
}

.quest-hud-badge.pop-anim {
    animation: questPop 0.5s ease-out;
}

@keyframes questPop {
    0% { transform: scale(1); }
    50% { transform: scale(1.2) rotate(4deg); }
    100% { transform: scale(1); }
}

.quest-hud-icon {
    font-size: 18px;
    filter: drop-shadow(0 0 6px #f59e0b);
}

.quest-hud-text {
    display: flex;
    flex-direction: column;
}

.quest-hud-title {
    font-size: 9px;
    font-weight: 700;
    color: #f59e0b;
    letter-spacing: 0.5px;
}

.quest-hud-count {
    font-size: 13px;
    font-weight: 800;
    color: #ffffff;
    font-family: 'JetBrains Mono', monospace;
}

/* 2. Floating Toast Notification */
.toast-notice {
    position: fixed;
    top: 80px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9999;
    padding: 10px 20px;
    border-radius: 30px;
    border: 1px solid rgba(245, 158, 11, 0.6);
    background: rgba(15, 23, 42, 0.95);
    color: #fef08a;
    font-size: 13px;
    font-weight: 700;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6), 0 0 20px rgba(245, 158, 11, 0.4);
    animation: toastSlideDown 0.35s ease-out;
    pointer-events: none;
    transition: opacity 0.3s, transform 0.3s;
}

.toast-notice.hidden {
    opacity: 0;
    transform: translateX(-50%) translateY(-15px);
}

@keyframes toastSlideDown {
    from { opacity: 0; transform: translateX(-50%) translateY(-20px); }
    to { opacity: 1; transform: translateX(-50%) translateY(0); }
}

/* 3. Universal Business Modals */
.business-modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    transition: opacity 0.3s, visibility 0.3s;
}

.business-modal-backdrop.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.modal-backdrop-bg {
    position: absolute;
    inset: 0;
    background: rgba(4, 8, 20, 0.75);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.business-modal-card {
    position: relative;
    max-width: 580px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    border-radius: 24px;
    padding: 28px 24px;
    background: rgba(9, 17, 39, 0.95);
    border: 1px solid rgba(6, 182, 212, 0.35);
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.8), 0 0 35px rgba(6, 182, 212, 0.2);
    z-index: 1;
    transform: scale(1);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.business-modal-backdrop.hidden .business-modal-card {
    transform: scale(0.92) translateY(20px);
}

.modal-close-btn {
    position: absolute;
    top: 16px;
    right: 18px;
    background: transparent;
    border: none;
    color: #94a3b8;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    transition: color 0.2s, transform 0.2s;
    z-index: 2;
}

.modal-close-btn:hover {
    color: #ffffff;
    transform: scale(1.15);
}

/* Header */
.modal-header {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.modal-icon {
    font-size: 36px;
    line-height: 1;
}

.modal-title-group h2 {
    font-size: 20px;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 4px;
}

.modal-badge {
    font-size: 11px;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 12px;
}

.modal-badge.gold {
    background: rgba(245, 158, 11, 0.15);
    color: #fbbf24;
    border: 1px solid rgba(245, 158, 11, 0.3);
}

.modal-badge.titan {
    background: rgba(139, 92, 246, 0.15);
    color: #c084fc;
    border: 1px solid rgba(139, 92, 246, 0.3);
}

.modal-badge.green {
    background: rgba(16, 185, 129, 0.15);
    color: #34d399;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

/* Tab Navigation */
.modal-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 18px;
    background: rgba(255, 255, 255, 0.04);
    padding: 4px;
    border-radius: 12px;
}

.tab-btn {
    flex: 1;
    padding: 8px 12px;
    background: transparent;
    border: none;
    border-radius: 8px;
    color: #94a3b8;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
}

.tab-btn.active {
    background: rgba(6, 182, 212, 0.25);
    color: #ffffff;
    border: 1px solid rgba(6, 182, 212, 0.45);
}

/* Plan Card */
.plan-card {
    background: rgba(15, 23, 42, 0.7);
    border-radius: 16px;
    padding: 18px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    margin-bottom: 18px;
}

.plan-price-box {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 12px;
}

.plan-price {
    font-size: 26px;
    font-weight: 800;
    color: #ffffff;
}

.plan-period {
    font-size: 12px;
    color: #94a3b8;
}

.plan-features {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
    font-size: 13px;
    color: #cbd5e1;
}

.plan-features li {
    display: flex;
    align-items: center;
    gap: 8px;
}

.plan-features li span {
    color: #10b981;
    font-weight: 800;
}

/* Metric Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-bottom: 18px;
}

.stat-item {
    background: rgba(15, 23, 42, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 14px;
    text-align: center;
}

.stat-val {
    font-size: 24px;
    font-weight: 800;
    color: #ffffff;
    font-family: 'JetBrains Mono', monospace;
}

.stat-val.green { color: #10b981; }
.stat-val.cyan { color: #06b6d4; }
.stat-val.purple { color: #a855f7; }

.stat-label {
    font-size: 11px;
    color: #94a3b8;
    margin-top: 4px;
}

/* Client Showcase Grid */
.clients-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-bottom: 18px;
}

.client-item {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    padding: 10px 12px;
}

.client-avatar {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 800;
    color: #ffffff;
    flex-shrink: 0;
}

.client-name {
    font-size: 13px;
    font-weight: 700;
    color: #ffffff;
}

.client-type {
    font-size: 11px;
    color: #94a3b8;
}

/* Voucher Reward Card */
.reward-card {
    text-align: center;
    border-color: rgba(245, 158, 11, 0.5);
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.8), 0 0 40px rgba(245, 158, 11, 0.35);
}

.reward-icon {
    font-size: 54px;
    margin-bottom: 10px;
}

.reward-header h2 {
    font-size: 22px;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 8px;
}

.reward-header p {
    font-size: 13px;
    color: #cbd5e1;
    line-height: 1.5;
    margin-bottom: 20px;
}

.voucher-box {
    background: rgba(245, 158, 11, 0.12);
    border: 2px dashed rgba(245, 158, 11, 0.5);
    border-radius: 16px;
    padding: 18px;
    margin-bottom: 22px;
}

.voucher-label {
    display: block;
    font-size: 10px;
    font-weight: 800;
    color: #f59e0b;
    letter-spacing: 1px;
    margin-bottom: 6px;
}

.voucher-code {
    display: block;
    font-size: 26px;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: 2px;
    font-family: 'JetBrains Mono', monospace;
    margin-bottom: 6px;
}

.voucher-desc {
    font-size: 11px;
    color: #94a3b8;
}

/* Modal Actions */
.modal-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

.modal-btn {
    padding: 12px 22px;
    border-radius: 14px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    border: none;
    font-family: inherit;
    transition: all 0.2s;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.modal-btn.primary {
    background: linear-gradient(135deg, #0284c7 0%, #06b6d4 100%);
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(6, 182, 212, 0.4);
    flex: 1;
}

.modal-btn.primary:hover {
    box-shadow: 0 6px 22px rgba(6, 182, 212, 0.6);
    transform: translateY(-1px);
}

.modal-btn.wa {
    background: linear-gradient(135deg, #059669 0%, #10b981 100%);
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4);
    flex: 1;
}

.modal-btn.wa:hover {
    box-shadow: 0 6px 22px rgba(16, 185, 129, 0.6);
    transform: translateY(-1px);
}

.modal-btn.secondary {
    background: rgba(255, 255, 255, 0.08);
    color: #94a3b8;
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.modal-btn.secondary:hover {
    background: rgba(255, 255, 255, 0.15);
    color: #ffffff;
}

@media (max-width: 600px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
    .clients-grid {
        grid-template-columns: 1fr;
    }
    .modal-actions {
        flex-direction: column-reverse;
    }
    .modal-btn {
        width: 100%;
    }
}

/* ==========================================================================
   Tahap 06: Fast Travel & Performance Optimizations
   ========================================================================== */

/* Active Audio Button */
.nav-btn.active {
    background: rgba(6, 182, 212, 0.25);
    border-color: #06b6d4;
    color: #38bdf8;
    box-shadow: 0 0 15px rgba(6, 182, 212, 0.4);
}

/* Fast Mode Active Badge */
.nav-btn.fast-mode {
    border-color: #10b981;
    color: #34d399;
}

/* Audio Settings Drawer */
.audio-settings-drawer {
    position: fixed;
    top: 75px;
    right: 20px;
    z-index: 95;
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 16px 20px;
    width: 290px;
    border-radius: 18px;
    background: rgba(9, 17, 39, 0.94);
    border: 1px solid rgba(6, 182, 212, 0.4);
    box-shadow: 0 14px 35px rgba(0, 0, 0, 0.75), 0 0 25px rgba(6, 182, 212, 0.25);
    transition: opacity 0.28s ease, transform 0.28s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.28s;
}

.audio-settings-drawer.hidden {
    opacity: 0;
    visibility: hidden;
    transform: translateY(-12px) scale(0.97);
    pointer-events: none;
}

.audio-settings-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.audio-settings-title {
    font-size: 13px;
    font-weight: 700;
    color: #e2e8f0;
    letter-spacing: -0.2px;
}

.audio-settings-close {
    background: transparent;
    border: none;
    color: #94a3b8;
    font-size: 20px;
    cursor: pointer;
    line-height: 1;
    transition: color 0.2s;
}

.audio-settings-close:hover {
    color: #ffffff;
}

.volume-slider-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.volume-label-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.volume-item-title {
    font-size: 11px;
    font-weight: 600;
    color: #cbd5e1;
}

.volume-val-badge {
    font-size: 11px;
    font-weight: 700;
    color: #38bdf8;
    background: rgba(6, 182, 212, 0.15);
    padding: 2px 7px;
    border-radius: 8px;
    border: 1px solid rgba(6, 182, 212, 0.3);
}

.volume-input-row {
    width: 100%;
}

.audio-slider {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 6px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.15);
    outline: none;
    transition: background 0.2s;
    cursor: pointer;
}

.audio-slider:hover {
    background: rgba(255, 255, 255, 0.25);
}

.audio-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0284c7, #06b6d4);
    box-shadow: 0 0 10px rgba(6, 182, 212, 0.6);
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.15s;
}

.audio-slider::-webkit-slider-thumb:hover {
    transform: scale(1.18);
    box-shadow: 0 0 14px rgba(6, 182, 212, 0.9);
}

.audio-slider::-moz-range-thumb {
    width: 16px;
    height: 16px;
    border: none;
    border-radius: 50%;
    background: linear-gradient(135deg, #0284c7, #06b6d4);
    box-shadow: 0 0 10px rgba(6, 182, 212, 0.6);
    cursor: pointer;
}

/* Fast Travel Drawer */
.fast-travel-drawer {
    position: fixed;
    top: 75px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 90;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border-radius: 40px;
    background: rgba(9, 17, 39, 0.92);
    border: 1px solid rgba(6, 182, 212, 0.35);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7), 0 0 20px rgba(6, 182, 212, 0.25);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
    overflow-x: auto;
    max-width: calc(100vw - 32px);
}

.fast-travel-drawer.hidden {
    opacity: 0;
    visibility: hidden;
    transform: translateX(-50%) translateY(-15px);
    pointer-events: none;
}

.fast-travel-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #e2e8f0;
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s;
    font-family: inherit;
}

.fast-travel-pill:hover {
    background: rgba(6, 182, 212, 0.25);
    border-color: #06b6d4;
    color: #ffffff;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(6, 182, 212, 0.3);
}

.fast-travel-pill:active {
    transform: scale(0.95);
}

@media (max-width: 1024px), (hover: none) and (pointer: coarse) {
    .fast-travel-drawer {
        top: 60px;
        padding: 6px 10px;
    }
    .fast-travel-pill {
        padding: 5px 10px;
        font-size: 10px;
    }
}

@media (max-width: 480px) {
    .action-btn {
        width: 52px;
        height: 52px;
        font-size: 10px;
    }
    .joystick-hint {
        bottom: 24px;
        left: 24px;
    }
    .joystick-base {
        width: 100px;
        height: 100px;
    }
    .joystick-knob {
        width: 44px;
        height: 44px;
    }
    .top-nav {
        top: 8px;
        left: 8px;
        right: 8px;
    }
    .nav-actions {
        gap: 4px;
    }
    .nav-btn {
        padding: 5px 8px;
    }
    .nav-btn span {
        font-size: 10px;
    }
}

/* Language Toggle Button Pill */
#btnLangToggle {
    border: 1px solid rgba(56, 189, 248, 0.4);
    background: rgba(14, 165, 233, 0.12);
}

#btnLangToggle:hover {
    border-color: #38bdf8;
    background: rgba(14, 165, 233, 0.25);
    box-shadow: 0 0 14px rgba(56, 189, 248, 0.35);
}

#langFlag {
    font-size: 14px;
    line-height: 1;
}

#langLabel {
    font-weight: 800;
    color: #38bdf8;
    letter-spacing: 0.5px;
}

/* ==========================================================================
   Live Background Auto-Update Banner
   ========================================================================== */
.live-update-banner {
    position: fixed;
    top: 75px;
    right: 20px;
    z-index: 9999;
    display: none;
    align-items: center;
    gap: 14px;
    padding: 12px 18px;
    border-radius: 16px;
    background: rgba(15, 23, 42, 0.94);
    border: 1px solid rgba(56, 189, 248, 0.5);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.6), 0 0 20px rgba(56, 189, 248, 0.35);
    animation: slideInDown 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.update-content {
    display: flex;
    align-items: center;
    gap: 10px;
}

.update-badge {
    background: linear-gradient(135deg, #0284c7 0%, #06b6d4 100%);
    color: #ffffff;
    font-size: 11px;
    font-weight: 800;
    padding: 3px 8px;
    border-radius: 8px;
    letter-spacing: 0.5px;
    font-family: 'JetBrains Mono', monospace;
}

.update-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.update-text strong {
    font-size: 13px;
    color: #ffffff;
    font-weight: 700;
}

.update-notes {
    font-size: 11px;
    color: #94a3b8;
}

.update-btn-action {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: #ffffff;
    border: none;
    padding: 8px 16px;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.35);
    transition: transform 0.2s, box-shadow 0.2s;
    font-family: inherit;
    white-space: nowrap;
}

.update-btn-action:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(16, 185, 129, 0.55);
}

.update-btn-close {
    background: transparent;
    border: none;
    color: #94a3b8;
    font-size: 16px;
    cursor: pointer;
    padding: 6px 8px;
    line-height: 1;
    border-radius: 8px;
    transition: color 0.2s, background 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.update-btn-close:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.12);
}

@media (max-width: 768px) {
    .live-update-banner {
        top: 65px;
        left: 12px;
        right: 12px;
        justify-content: space-between;
    }
}

