/* ══════════════════════════════════════════════════════
   MIAWW AREA — Immersive Dark Premium Theme v2.0
   Living backgrounds, fluid micro-animations, premium glass
   ══════════════════════════════════════════════════════ */

/* ── Design Tokens ── */
:root {
    --bg-base: #060a14;
    --bg-card: rgba(12, 15, 28, 0.75);
    --bg-card-hover: rgba(18, 22, 40, 0.88);
    --bg-elevated: rgba(20, 24, 44, 0.92);

    --accent: #818cf8;
    --accent-dim: #6366f1;
    --accent-bright: #a5b4fc;
    --accent-soft: rgba(129, 140, 248, 0.1);
    --accent-border: rgba(129, 140, 248, 0.2);
    --accent-glow: rgba(129, 140, 248, 0.08);
    --accent-2: #a78bfa;
    --accent-3: #22d3ee;

    --text-primary: #eaecf2;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;

    --border-idle: rgba(255, 255, 255, 0.06);
    --border-hover: rgba(129, 140, 248, 0.3);

    --green: #34d399;
    --yellow: #fbbf24;
    --red: #f87171;

    --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
    --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
    --ease-smooth: cubic-bezier(0.22, 1, 0.36, 1);
}

html {
    scroll-behavior: smooth;
}

/* ── Base ── */
body {
    background-color: var(--bg-base) !important;
    color: var(--text-primary) !important;
    background-image: none !important;
    -webkit-user-select: none;
    -ms-user-select: none;
    user-select: none;
    overflow-x: hidden;
}

/* Kill legacy elements */
body::before, body::after, #interactive-bg, .floating-orb {
    display: none !important;
}

/* ══════════════════════════════════════════════════════
   ANIMATED BACKGROUND
   ══════════════════════════════════════════════════════ */

.animated-bg {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

/* ── Floating Gradient Orbs ── */
.bg-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    will-change: transform;
}

.bg-orb-1 {
    width: clamp(280px, 45vw, 550px);
    height: clamp(280px, 45vw, 550px);
    background: radial-gradient(circle, var(--accent) 0%, transparent 70%);
    top: -12%;
    left: -8%;
    opacity: 0.12;
    animation: orbDrift1 28s ease-in-out infinite;
}

.bg-orb-2 {
    width: clamp(240px, 38vw, 480px);
    height: clamp(240px, 38vw, 480px);
    background: radial-gradient(circle, var(--accent-2) 0%, transparent 70%);
    bottom: -8%;
    right: -6%;
    opacity: 0.1;
    animation: orbDrift2 34s ease-in-out infinite;
}

.bg-orb-3 {
    width: clamp(200px, 30vw, 380px);
    height: clamp(200px, 30vw, 380px);
    background: radial-gradient(circle, var(--accent-3) 0%, transparent 70%);
    top: 40%;
    left: 55%;
    opacity: 0.07;
    animation: orbDrift3 26s ease-in-out infinite;
}

@keyframes orbDrift1 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    25% { transform: translate(10vw, 6vh) scale(1.1); }
    50% { transform: translate(4vw, 14vh) scale(0.93); }
    75% { transform: translate(-6vw, 4vh) scale(1.05); }
}

@keyframes orbDrift2 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    25% { transform: translate(-10vw, -8vh) scale(1.12); }
    50% { transform: translate(-5vw, -16vh) scale(0.88); }
    75% { transform: translate(8vw, -4vh) scale(1.06); }
}

@keyframes orbDrift3 {
    0%, 100% { transform: translate(-50%, 0) scale(1); opacity: 0.06; }
    50% { transform: translate(-35%, -10vh) scale(1.25); opacity: 0.14; }
}

/* ── Grid Overlay ── */
.bg-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(129, 140, 248, 0.018) 1px, transparent 1px),
        linear-gradient(90deg, rgba(129, 140, 248, 0.018) 1px, transparent 1px);
    background-size: 80px 80px;
    mask-image: radial-gradient(ellipse 60% 50% at 50% 35%, rgba(0,0,0,0.5) 0%, transparent 100%);
    -webkit-mask-image: radial-gradient(ellipse 60% 50% at 50% 35%, rgba(0,0,0,0.5) 0%, transparent 100%);
}

/* ── Floating Particles ── */
.bg-particles {
    position: absolute;
    inset: 0;
}

.bg-particles span {
    position: absolute;
    display: block;
    width: 2px;
    height: 2px;
    background: var(--accent);
    border-radius: 50%;
    box-shadow: 0 0 6px 1px rgba(129, 140, 248, 0.4);
    opacity: 0;
    animation: particleRise linear infinite;
}

.bg-particles span:nth-child(1) { left: 10%; animation-duration: 22s; animation-delay: 0s; }
.bg-particles span:nth-child(2) { left: 28%; animation-duration: 28s; animation-delay: 5s; width: 3px; height: 3px; }
.bg-particles span:nth-child(3) { left: 48%; animation-duration: 20s; animation-delay: 2s; }
.bg-particles span:nth-child(4) { left: 68%; animation-duration: 25s; animation-delay: 7s; width: 3px; height: 3px; }
.bg-particles span:nth-child(5) { left: 88%; animation-duration: 30s; animation-delay: 1s; }
.bg-particles span:nth-child(6) { left: 38%; animation-duration: 24s; animation-delay: 9s; }
.bg-particles span:nth-child(7) { left: 62%; animation-duration: 21s; animation-delay: 4s; width: 1.5px; height: 1.5px; }
.bg-particles span:nth-child(8) { left: 18%; animation-duration: 26s; animation-delay: 8s; }

@keyframes particleRise {
    0% {
        bottom: -2%;
        opacity: 0;
        transform: translateX(0) scale(0);
    }
    6% {
        opacity: 0.6;
        transform: translateX(0) scale(1);
    }
    50% {
        opacity: 0.35;
        transform: translateX(25px) scale(0.8);
    }
    94% {
        opacity: 0.08;
    }
    100% {
        bottom: 102%;
        opacity: 0;
        transform: translateX(-15px) scale(0.3);
    }
}

/* ── Cursor Glow (Desktop Only) ── */
.cursor-glow {
    position: fixed;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(129, 140, 248, 0.045) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
    z-index: 1;
    transform: translate(-50%, -50%);
    transition: left 0.12s ease-out, top 0.12s ease-out, opacity 0.5s ease;
    opacity: 0;
}

.cursor-glow.active {
    opacity: 1;
}

@media (max-width: 768px) {
    .cursor-glow { display: none !important; }
    
    /* Mobile Performance Optimizations */
    .bg-orb, .bg-particles, .animated-bg { 
        display: none !important; 
        animation: none !important; 
    }
    
    .glass-card, nav .glass-card, .promo-popup-box, .purchase-modal-card,
    #detail-modal, #discord-modal, #purchase-modal, #lightbox-modal,
    .discord-welcome-overlay.active {
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
        background-color: var(--bg-elevated) !important;
    }
}

/* ══════════════════════════════════════════════════════
   GLASS CARDS
   ══════════════════════════════════════════════════════ */

.glass-card, nav .glass-card, .promo-popup-box, .purchase-modal-card {
    background: var(--bg-card) !important;
    backdrop-filter: blur(16px) saturate(140%) !important;
    -webkit-backdrop-filter: blur(16px) saturate(140%) !important;
    border: 1px solid var(--border-idle) !important;
    border-radius: 16px !important;
    box-shadow:
        0 4px 24px rgba(0, 0, 0, 0.25),
        inset 0 1px 0 rgba(255, 255, 255, 0.03) !important;
    transition: border-color 0.4s ease, box-shadow 0.4s ease, transform 0.4s var(--ease-smooth), background 0.4s ease !important;
}

.glass-card:hover, .testi-card:hover {
    border-color: var(--border-hover) !important;
    background: var(--bg-card-hover) !important;
    box-shadow:
        0 12px 40px rgba(99, 102, 241, 0.08),
        0 0 0 1px rgba(129, 140, 248, 0.06),
        inset 0 1px 0 rgba(255, 255, 255, 0.04) !important;
    transform: translateY(-5px) !important;
}

/* ══════════════════════════════════════════════════════
   TITLE GRADIENT — Enhanced Shimmer
   ══════════════════════════════════════════════════════ */

.text-gradient-animated {
    background: linear-gradient(
        120deg,
        #c7d2fe 0%,
        #818cf8 20%,
        #a78bfa 40%,
        #22d3ee 60%,
        #818cf8 80%,
        #c7d2fe 100%
    ) !important;
    background-size: 300% auto !important;
    color: transparent !important;
    -webkit-background-clip: text !important;
    background-clip: text !important;
    animation: titleShimmer 8s linear infinite !important;
    filter: none !important;
    text-shadow: none !important;
}

h1 .text-gradient-animated::before,
h1 .text-gradient-animated::after {
    display: none !important;
}

@keyframes titleShimmer {
    0% { background-position: 0% center; }
    100% { background-position: 300% center; }
}

/* ── Hero Entrance ── */
.hero-title {
    animation: heroEntrance 1.2s var(--ease-out-expo) both;
}

@keyframes heroEntrance {
    from {
        opacity: 0;
        transform: translateY(40px) scale(0.92);
        filter: blur(12px);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

/* ══════════════════════════════════════════════════════
   BUTTONS
   ══════════════════════════════════════════════════════ */

.btn-shine {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.18), rgba(99, 102, 241, 0.08)) !important;
    border: 1px solid var(--accent-border) !important;
    color: var(--accent-bright) !important;
    position: relative !important;
    overflow: hidden !important;
    transition: all 0.3s var(--ease-smooth) !important;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.2) !important;
}

.btn-shine::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -75%;
    width: 50%;
    height: 200%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(129, 140, 248, 0.1),
        transparent
    ) !important;
    transform: rotate(25deg);
    animation: btnSweep 4s ease-in-out infinite;
}

@keyframes btnSweep {
    0% { left: -75%; }
    35% { left: 125%; }
    100% { left: 125%; }
}

.btn-shine:hover {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.3), rgba(129, 140, 248, 0.15)) !important;
    border-color: var(--accent) !important;
    box-shadow:
        0 6px 24px rgba(99, 102, 241, 0.2),
        0 0 50px rgba(129, 140, 248, 0.06) !important;
    color: #e0e7ff !important;
    transform: translateY(-2px) !important;
}

.btn-shine:active {
    transform: scale(0.96) translateY(0) !important;
    transition-duration: 0.1s !important;
}

/* ══════════════════════════════════════════════════════
   COLOR MAPPINGS (Tailwind overrides → Indigo theme)
   ══════════════════════════════════════════════════════ */

.text-premium-cyan, .text-blue-400, .text-blue-500, .text-purple-400, .text-\[\#5865F2\] {
    color: var(--accent) !important;
}
.text-white {
    color: var(--text-primary) !important;
}
.group-hover\/card\:text-premium-cyan:hover,
.group-hover\/gcard\:text-premium-cyan:hover,
.hover\:text-premium-cyan:hover {
    color: var(--accent-bright) !important;
}

.bg-premium-cyan, .bg-blue-400, .bg-blue-500, .bg-purple-400,
.bg-blue-600\/20, .bg-blue-500\/10, .bg-blue-500\/20, .bg-purple-500\/20,
.bg-\[\#5865F2\], .bg-\[\#0f111a\]\/80, .bg-\[\#0f111a\] {
    background-color: rgba(12, 15, 28, 0.5) !important;
}

.border-premium-cyan, .border-blue-400, .border-blue-500, .border-purple-400,
.border-premium-cyan\/30, .border-premium-cyan\/40, .border-premium-cyan\/50,
.border-blue-500\/20, .border-blue-500\/30, .border-purple-500\/30,
.border-premium-border {
    border-color: var(--border-idle) !important;
}

.fa-discord { color: #7c8ae6 !important; }

/* ══════════════════════════════════════════════════════
   CARD & ELEMENT ENTRANCE ANIMATIONS
   ══════════════════════════════════════════════════════ */

.animate-card {
    opacity: 0;
    animation-name: cardReveal;
    animation-duration: 0.65s;
    animation-timing-function: var(--ease-out-expo);
    animation-fill-mode: forwards;
}

@keyframes cardReveal {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.96);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Stagger delays for grid items */
.animate-card:nth-child(1)  { animation-delay: 0.04s; }
.animate-card:nth-child(2)  { animation-delay: 0.08s; }
.animate-card:nth-child(3)  { animation-delay: 0.12s; }
.animate-card:nth-child(4)  { animation-delay: 0.16s; }
.animate-card:nth-child(5)  { animation-delay: 0.20s; }
.animate-card:nth-child(6)  { animation-delay: 0.24s; }
.animate-card:nth-child(7)  { animation-delay: 0.28s; }
.animate-card:nth-child(8)  { animation-delay: 0.32s; }
.animate-card:nth-child(9)  { animation-delay: 0.36s; }
.animate-card:nth-child(10) { animation-delay: 0.40s; }
.animate-card:nth-child(11) { animation-delay: 0.44s; }
.animate-card:nth-child(12) { animation-delay: 0.48s; }
.animate-card:nth-child(13) { animation-delay: 0.52s; }
.animate-card:nth-child(14) { animation-delay: 0.56s; }

/* ══════════════════════════════════════════════════════
   SCROLLBAR
   ══════════════════════════════════════════════════════ */

::-webkit-scrollbar { width: 6px !important; }
::-webkit-scrollbar-track { background: var(--bg-base) !important; }
::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, rgba(129, 140, 248, 0.3), rgba(167, 139, 250, 0.3)) !important;
    border-radius: 10px !important;
}
::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, rgba(129, 140, 248, 0.5), rgba(167, 139, 250, 0.5)) !important;
}

.custom-scrollbar::-webkit-scrollbar { width: 4px; }
.custom-scrollbar::-webkit-scrollbar-track { background: transparent; }
.custom-scrollbar::-webkit-scrollbar-thumb {
    background: rgba(129, 140, 248, 0.2);
    border-radius: 10px;
}
.custom-scrollbar::-webkit-scrollbar-thumb:hover {
    background: rgba(129, 140, 248, 0.4);
}

/* ── Status Dots ── */
.blink-dot {
    animation: softPulse 2.5s ease-in-out infinite !important;
}

@keyframes softPulse {
    0%, 100% { opacity: 1; box-shadow: 0 0 8px currentColor; }
    50% { opacity: 0.3; box-shadow: 0 0 2px currentColor; }
}

/* ══════════════════════════════════════════════════════
   MODAL OVERLAYS — Enhanced Spring Animations
   ══════════════════════════════════════════════════════ */

#detail-modal, #discord-modal, #purchase-modal, #lightbox-modal {
    backdrop-filter: blur(10px) saturate(120%) !important;
    -webkit-backdrop-filter: blur(10px) saturate(120%) !important;
    transition: opacity 0.4s ease !important;
}

/* Detail modal — slide up with spring */
#detail-modal-content {
    transition: transform 0.55s var(--ease-spring), opacity 0.4s ease !important;
}

#detail-modal-content.scale-95 {
    transform: scale(0.88) translateY(60px) !important;
}

#detail-modal-content.scale-100 {
    transform: scale(1) translateY(0) !important;
}

/* Discord & purchase checkout modal — slide up with spring */
#discord-modal #modal-content,
#purchase-modal #modal-content {
    transition: transform 0.55s var(--ease-spring), opacity 0.4s ease !important;
}

#discord-modal #modal-content.scale-95,
#purchase-modal #modal-content.scale-95,
#purchase-modal .glass-card.scale-95 {
    transform: scale(0.85) translateY(80px) !important;
}

#discord-modal #modal-content.scale-100,
#purchase-modal #modal-content.scale-100,
#purchase-modal .glass-card.scale-100 {
    transform: scale(1) translateY(0) !important;
}

/* ══════════════════════════════════════════════════════
   PROMO POPUP — Elastic Entrance
   ══════════════════════════════════════════════════════ */

.promo-popup {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(calc(100% + 50px));
    z-index: 9999;
    transition: transform 0.7s var(--ease-spring);
    pointer-events: none;
}

.promo-popup.show {
    transform: translateX(-50%) translateY(0);
    pointer-events: auto;
}

.promo-popup-box {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 18px 24px;
    border-radius: 16px !important;
    position: relative;
    overflow: hidden;
}

.promo-popup-content { flex: 1; }

.promo-popup-kicker {
    font-size: 11px;
    font-weight: 800;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.12em;
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.promo-popup-kicker i {
    animation: boltFlash 2s ease-in-out infinite;
}

@keyframes boltFlash {
    0%, 70%, 100% { opacity: 1; }
    80% { opacity: 0.3; }
    90% { opacity: 1; }
}

.promo-popup-text {
    font-size: 12px;
    color: var(--text-secondary);
    line-height: 1.5;
}

.promo-popup-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.promo-popup-join {
    padding: 8px 20px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--accent);
    border: 1px solid var(--accent-border);
    background: var(--accent-soft);
    transition: all 0.25s var(--ease-smooth);
    text-decoration: none;
    white-space: nowrap;
}

.promo-popup-join:hover {
    background: rgba(99, 102, 241, 0.22);
    border-color: var(--accent);
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(99, 102, 241, 0.15);
}

.promo-popup-close {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    border: 1px solid var(--border-idle);
    background: transparent;
    color: var(--text-secondary);
    transition: all 0.2s ease;
}

.promo-popup-close:hover {
    color: var(--text-primary);
    border-color: var(--accent-border);
    background: rgba(129, 140, 248, 0.06);
}

/* ══════════════════════════════════════════════════════
   TESTI CARDS / NFA ROWS / LIGHTBOX
   ══════════════════════════════════════════════════════ */

.testi-card {
    break-inside: avoid;
    margin-bottom: 1.5rem;
    padding: 0 !important;
    overflow: hidden;
}

#lightbox-image {
    max-width: 90vw;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 16px;
    border: 1px solid var(--border-idle);
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.6);
}

/* Lightbox zoom entrance */
#lightbox-modal.opacity-100 #lightbox-image {
    animation: lbZoomIn 0.45s var(--ease-spring) both;
}

@keyframes lbZoomIn {
    from {
        transform: scale(0.8);
        opacity: 0;
        filter: blur(8px);
    }
    to {
        transform: scale(1);
        opacity: 1;
        filter: blur(0);
    }
}

/* NFA row hover pulse */
.nfa-row {
    position: relative;
    overflow: hidden;
}

.nfa-row::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(129, 140, 248, 0.04), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.nfa-row:hover::before {
    opacity: 1;
}

/* ── Performance ── */
.product-card, .testi-card, .glass-card {
    will-change: transform;
    contain: layout style;
}

/* ══════════════════════════════════════════════════════
   DISCORD WELCOME POPUP — Dramatic Entrance
   ══════════════════════════════════════════════════════ */

.discord-welcome-overlay {
    position: fixed;
    inset: 0;
    z-index: 100000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(4, 6, 12, 0);
    transition: background 0.5s ease;
}

.discord-welcome-overlay.active {
    background: rgba(4, 6, 12, 0.92);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.discord-welcome-card {
    position: relative;
    max-width: 420px;
    width: 100%;
    padding: 44px 32px 32px;
    background: linear-gradient(165deg, rgba(22, 25, 48, 0.97), rgba(10, 13, 26, 0.98));
    border: 1px solid rgba(129, 140, 248, 0.15);
    border-radius: 24px;
    box-shadow:
        0 0 100px rgba(88, 101, 242, 0.12),
        0 30px 80px rgba(0, 0, 0, 0.6);
    text-align: center;
    transform: scale(0.75) translateY(60px);
    opacity: 0;
    transition: transform 0.65s var(--ease-spring),
                opacity 0.45s ease;
}

.discord-welcome-overlay.active .discord-welcome-card {
    transform: scale(1) translateY(0);
    opacity: 1;
}

.discord-welcome-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    border: 1px solid var(--border-idle);
    background: transparent;
    color: var(--text-secondary);
    font-size: 14px;
    cursor: pointer;
    transition: all 0.25s ease;
    min-height: auto !important;
}

.discord-welcome-close:hover {
    color: var(--text-primary);
    border-color: var(--accent-border);
    background: rgba(129, 140, 248, 0.08);
    transform: rotate(90deg);
}

.discord-welcome-icon {
    width: 72px;
    height: 72px;
    margin: 0 auto 20px;
    background: linear-gradient(135deg, rgba(88, 101, 242, 0.2), rgba(129, 140, 248, 0.1));
    border: 1px solid rgba(88, 101, 242, 0.3);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: #7c8ae6;
    animation: discordFloat 3s ease-in-out infinite;
}

@keyframes discordFloat {
    0%, 100% {
        transform: translateY(0);
        box-shadow: 0 0 0 0 rgba(88, 101, 242, 0.25);
    }
    50% {
        transform: translateY(-8px);
        box-shadow: 0 12px 30px rgba(88, 101, 242, 0.15);
    }
}

.discord-welcome-badge {
    display: inline-block;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--accent);
    background: var(--accent-soft);
    border: 1px solid var(--accent-border);
    padding: 4px 14px;
    border-radius: 20px;
    margin-bottom: 16px;
}

.discord-welcome-title {
    font-family: 'Sora', sans-serif;
    font-size: 22px;
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1.35;
    margin-bottom: 12px;
    letter-spacing: -0.01em;
}

.discord-welcome-desc {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 28px;
    max-width: 340px;
    margin-left: auto;
    margin-right: auto;
}

.discord-welcome-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 16px 24px;
    border-radius: 14px;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #fff;
    background: linear-gradient(135deg, #5865F2, #7c8ae6);
    border: none;
    text-decoration: none;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: all 0.35s var(--ease-smooth);
    box-shadow:
        0 4px 24px rgba(88, 101, 242, 0.35),
        0 0 0 0 rgba(88, 101, 242, 0);
}

.discord-welcome-btn::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -75%;
    width: 50%;
    height: 200%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.15),
        transparent
    );
    transform: rotate(25deg);
    animation: btnShimmer 3s ease-in-out infinite;
}

@keyframes btnShimmer {
    0%   { left: -75%; }
    40%  { left: 125%; }
    100% { left: 125%; }
}

.discord-welcome-btn:hover {
    background: linear-gradient(135deg, #6974f5, #8f9bf0);
    box-shadow:
        0 8px 36px rgba(88, 101, 242, 0.5),
        0 0 0 5px rgba(88, 101, 242, 0.12);
    transform: translateY(-3px);
}

.discord-welcome-btn:active {
    transform: translateY(0) scale(0.97);
}

.discord-welcome-btn .fab.fa-discord {
    font-size: 20px;
    color: #fff !important;
}

.discord-welcome-skip {
    display: inline-block;
    margin-top: 14px;
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    padding: 6px 12px;
    transition: color 0.2s ease;
    min-height: auto !important;
}

.discord-welcome-skip:hover {
    color: var(--text-primary);
}

/* ══════════════════════════════════════════════════════
   NAV LINK HOVER UNDERLINE
   ══════════════════════════════════════════════════════ */

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    width: 0;
    height: 1.5px;
    background: var(--accent);
    transition: width 0.3s var(--ease-smooth), left 0.3s var(--ease-smooth);
    border-radius: 2px;
}

.nav-link:hover::after {
    width: 80%;
    left: 10%;
}

/* ══════════════════════════════════════════════════════
   UTILITY ANIMATIONS
   ══════════════════════════════════════════════════════ */

/* Accent dot pulsing */
@keyframes accentPulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(129, 140, 248, 0.4); }
    50% { box-shadow: 0 0 0 6px rgba(129, 140, 248, 0); }
}

.animate-pulse-accent {
    animation: accentPulse 2s ease-in-out infinite;
}

/* Subtle floating animation for badges */
@keyframes gentleFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-3px); }
}

/* ══════════════════════════════════════════════════════
   SAFE AREA & RESPONSIVE
   ══════════════════════════════════════════════════════ */

body {
    padding-left: env(safe-area-inset-left) !important;
    padding-right: env(safe-area-inset-right) !important;
}

/* ── Navbar: compact on mobile ── */
@media (max-width: 640px) {
    .nav-bar {
        top: 8px !important;
        right: 8px !important;
        left: 8px !important;
    }
    .nav-bar > div {
        padding: 8px 12px !important;
        gap: 10px !important;
        width: 100% !important;
        justify-content: center !important;
    }
    .nav-bar a, .nav-bar .nav-link {
        font-size: 10px !important;
        letter-spacing: 0.08em !important;
    }
    .nav-bar .fab.fa-discord {
        font-size: 12px !important;
    }
}

/* ── Header Title: smaller on mobile ── */
@media (max-width: 640px) {
    .hero-title {
        font-size: 2.5rem !important;
        line-height: 1.1 !important;
    }
}

/* ── Promo Popup: stack on mobile ── */
@media (max-width: 640px) {
    .promo-popup {
        left: 8px !important;
        right: 8px !important;
        bottom: calc(12px + env(safe-area-inset-bottom)) !important;
        transform: translateX(0) translateY(calc(100% + 50px)) !important;
        width: auto !important;
    }
    .promo-popup.show {
        transform: translateX(0) translateY(0) !important;
    }
    .promo-popup-box {
        flex-direction: column !important;
        gap: 12px !important;
        padding: 14px 16px !important;
    }
    .promo-popup-actions {
        width: 100% !important;
        justify-content: stretch !important;
    }
    .promo-popup-join {
        flex: 1 !important;
        text-align: center !important;
        padding: 10px 16px !important;
    }
    .promo-popup-text {
        font-size: 11px !important;
    }
}

/* ── Cards: touch-friendly on mobile ── */
@media (max-width: 640px) {
    .glass-card:hover {
        transform: none !important;
    }
    .glass-card:active {
        transform: scale(0.97) !important;
        transition-duration: 0.15s !important;
    }

    /* Lighter background effects on mobile for performance */
    .bg-orb {
        filter: blur(80px);
        opacity: 0.08 !important;
    }
    .bg-particles span {
        box-shadow: none;
    }
    .bg-grid {
        opacity: 0.5;
    }
}

/* ── Modals: full width on mobile with slide-up ── */
@media (max-width: 640px) {
    #detail-modal > div,
    #discord-modal > div,
    #purchase-modal > div {
        max-width: 100% !important;
        margin: 8px !important;
        border-radius: 20px !important;
        max-height: 92vh !important;
    }
    #detail-modal .btn-shine,
    #discord-modal .btn-shine,
    #purchase-modal .btn-shine {
        min-height: 48px !important;
        font-size: 12px !important;
    }
    /* Deeper slide on mobile */
    #detail-modal-content.scale-95,
    #discord-modal #modal-content.scale-95,
    #purchase-modal #modal-content.scale-95 {
        transform: scale(0.95) translateY(100px) !important;
    }
}

/* ── Touch-friendly buttons ── */
@media (max-width: 640px) {
    button, .btn-shine, [onclick] {
        min-height: 44px;
    }
    .promo-popup-close,
    button[class*="absolute top"],
    .discord-welcome-close,
    .discord-welcome-skip {
        min-height: auto;
    }
}

/* ── NFA rows mobile ── */
@media (max-width: 640px) {
    .nfa-row {
        padding: 16px !important;
        gap: 12px !important;
    }
    .nfa-row .price-container span:first-child {
        font-size: 1.1rem !important;
    }
}

/* ── Vouch lightbox mobile ── */
@media (max-width: 640px) {
    #lightbox-image {
        max-width: 95vw !important;
        max-height: 75vh !important;
        border-radius: 12px;
    }
    #lightbox-modal button {
        width: 48px !important;
        height: 48px !important;
        top: 12px !important;
        right: 12px !important;
    }
}

/* ── Tablet tweaks ── */
@media (min-width: 641px) and (max-width: 1024px) {
    .nav-bar > div {
        padding: 10px 20px !important;
        gap: 16px !important;
    }
}

/* ── Discord Welcome: Mobile slide-up ── */
@media (max-width: 640px) {
    .discord-welcome-overlay {
        padding: 16px;
        align-items: flex-end;
    }
    .discord-welcome-card {
        padding: 32px 24px 24px;
        border-radius: 20px;
        margin-bottom: env(safe-area-inset-bottom);
        transform: scale(0.9) translateY(100%);
    }
    .discord-welcome-overlay.active .discord-welcome-card {
        transform: scale(1) translateY(0);
    }
    .discord-welcome-icon {
        width: 60px;
        height: 60px;
        font-size: 26px;
        border-radius: 16px;
        margin-bottom: 16px;
    }
    .discord-welcome-title {
        font-size: 19px;
    }
    .discord-welcome-desc {
        font-size: 12px;
        margin-bottom: 22px;
    }
    .discord-welcome-btn {
        padding: 14px 20px;
        font-size: 13px;
        border-radius: 12px;
    }
}

/* ══════════════════════════════════════════════════════
   SCROLL REVEAL SYSTEM
   ══════════════════════════════════════════════════════ */

.reveal-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s var(--ease-out-expo), transform 0.7s var(--ease-out-expo);
}

.reveal-up.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* ── Scroll Indicator ── */
@keyframes scrollDotBounce {
    0%, 100% { transform: translateY(0); opacity: 0.4; }
    50% { transform: translateY(6px); opacity: 1; }
}

.animate-scroll-dot {
    animation: scrollDotBounce 2s ease-in-out infinite;
}

.scroll-indicator {
    opacity: 0;
    animation: fadeInOnly 0.8s ease forwards;
    animation-delay: 1.5s;
}

@keyframes fadeInOnly {
    to { opacity: 0.6; }
}

/* ══════════════════════════════════════════════════════
   FOOTER
   ══════════════════════════════════════════════════════ */

.site-footer {
    background: rgba(6, 8, 16, 0.95);
    border-top: 1px solid var(--border-idle);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.footer-link {
    color: var(--text-secondary);
    transition: color 0.25s ease, transform 0.25s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.05em;
}

.footer-link:hover {
    color: var(--accent);
    transform: translateY(-1px);
}

/* ══════════════════════════════════════════════════════
   SCROLL-TO-TOP BUTTON
   ══════════════════════════════════════════════════════ */

.scroll-top-btn {
    position: fixed;
    bottom: 90px;
    right: 20px;
    z-index: 9990;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: var(--bg-card);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border-idle);
    color: var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.35s var(--ease-smooth);
    pointer-events: none;
    font-size: 16px;
    min-height: auto !important;
}

.scroll-top-btn.visible {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.scroll-top-btn:hover {
    background: var(--bg-card-hover);
    border-color: var(--accent-border);
    transform: translateY(-3px) !important;
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.12);
}

/* ══════════════════════════════════════════════════════
   ENHANCED GROUP CARDS (game-store style)
   ══════════════════════════════════════════════════════ */

.group-card {
    padding: 0 !important;
    overflow: hidden;
    border-radius: 20px !important;
}

.group-card .group-card-img {
    transition: transform 0.7s var(--ease-smooth), filter 0.7s ease;
}

.group-card:hover .group-card-img {
    transform: scale(1.1);
    filter: brightness(1.1);
}

.group-card .group-card-overlay {
    background: linear-gradient(
        to top,
        rgba(6, 8, 20, 0.95) 0%,
        rgba(6, 8, 20, 0.6) 40%,
        rgba(6, 8, 20, 0.15) 70%,
        transparent 100%
    );
}

.group-card .group-card-cta {
    opacity: 0;
    transform: translateX(-8px);
    transition: all 0.35s var(--ease-smooth);
}

.group-card:hover .group-card-cta {
    opacity: 1;
    transform: translateX(0);
}

/* ══════════════════════════════════════════════════════
   ENHANCED PRODUCT CARDS
   ══════════════════════════════════════════════════════ */

.product-card {
    padding: 0 !important;
    overflow: hidden;
    border-radius: 20px !important;
}

.product-card .product-card-img {
    transition: transform 0.7s var(--ease-smooth);
}

.product-card:hover .product-card-img {
    transform: scale(1.08);
}

.product-card .product-card-btn {
    transition: all 0.3s var(--ease-smooth);
}

.product-card:hover .product-card-btn {
    background: var(--accent) !important;
    color: #060a14 !important;
    border-color: var(--accent) !important;
}

/* ══════════════════════════════════════════════════════
   STATS COUNTER
   ══════════════════════════════════════════════════════ */

.stat-badge {
    position: relative;
    overflow: hidden;
}

.stat-badge::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(129, 140, 248, 0.06), transparent);
    animation: statShine 4s ease-in-out infinite;
}

@keyframes statShine {
    0% { left: -100%; }
    50% { left: 100%; }
    100% { left: 100%; }
}

/* ══════════════════════════════════════════════════════
   BACK BUTTON ENHANCED
   ══════════════════════════════════════════════════════ */

.back-btn {
    position: relative;
    overflow: hidden;
}

.back-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(129, 140, 248, 0.08), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.back-btn:hover::before {
    opacity: 1;
}

/* ══════════════════════════════════════════════════════
   VOUCH PAGE — Counter Badge
   ══════════════════════════════════════════════════════ */

.vouch-counter {
    font-variant-numeric: tabular-nums;
}

@keyframes countPop {
    0% { transform: scale(0.5); opacity: 0; }
    60% { transform: scale(1.15); }
    100% { transform: scale(1); opacity: 1; }
}

.count-animate {
    animation: countPop 0.6s var(--ease-spring) both;
}

/* ── Reduced motion preference ── */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    .animated-bg { display: none; }
    .cursor-glow { display: none; }
    .reveal-up { opacity: 1; transform: none; }
}
