:root {
    --neon-cyan: #00d4ff;
    --neon-purple: #a855f7;
    --neon-green: #10b981;
    --neon-pink: #fe2c55;
    --neon-gold: #f59e0b;
    --sidebar-width: 270px;
    --transition-speed: 0.3s;
    --header-height: 70px;

    /* Dashboard Theme variables - Dark (Default) */
    --dash-bg: #050810;
    --dash-card-bg: rgba(12, 18, 38, 0.75);
    --dash-card-border: rgba(0, 212, 255, 0.18);
    --dash-card-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), 0 0 40px rgba(0, 212, 255, 0.06), 0 0 80px rgba(168, 85, 247, 0.04);
    --dash-text: #f1f5f9;
    --dash-text-primary: #f1f5f9;
    --dash-text-muted: #94a3b8;
    --dash-border: rgba(255, 255, 255, 0.07);
    --dash-card-inner-bg: rgba(255, 255, 255, 0.02);
    --dash-card-inner-border: rgba(255, 255, 255, 0.07);
    --dash-input-bg: rgba(255, 255, 255, 0.04);
    --dash-input-border: rgba(255, 255, 255, 0.1);
    --dash-input-text: #ffffff;
    --dash-scroll-track: #050810;
    --dash-sidebar-bg: rgba(8, 12, 24, 0.85);
    --dash-sidebar-border: rgba(0, 212, 255, 0.15);
    --dash-sidebar-btn-bg: rgba(255, 255, 255, 0.02);
    --dash-sidebar-btn-border: rgba(255, 255, 255, 0.05);
}

[data-theme="light"] {
    --dash-bg: #eef2f9;
    --dash-card-bg: rgba(255, 255, 255, 0.88);
    --dash-card-border: rgba(99, 179, 237, 0.35);
    --dash-card-shadow: 0 8px 32px rgba(0, 0, 0, 0.06), 0 2px 8px rgba(99, 179, 237, 0.12);
    --dash-text: #1e293b;
    --dash-text-primary: #1e293b;
    --dash-text-muted: #64748b;
    --dash-border: rgba(0, 0, 0, 0.06);
    --dash-card-inner-bg: rgba(0, 0, 0, 0.015);
    --dash-card-inner-border: rgba(0, 0, 0, 0.05);
    --dash-input-bg: rgba(0, 0, 0, 0.02);
    --dash-input-border: rgba(0, 0, 0, 0.08);
    --dash-input-text: #1e293b;
    --dash-scroll-track: #eef2f9;
    --dash-sidebar-bg: rgba(255, 255, 255, 0.85);
    --dash-sidebar-border: rgba(99, 179, 237, 0.2);
    --dash-sidebar-btn-bg: rgba(0, 0, 0, 0.015);
    --dash-sidebar-btn-border: rgba(0, 0, 0, 0.03);
}

/* =========================================================
   BODY — Animated Living Background
   ========================================================= */
body.dashboard-body {
    background-color: var(--dash-bg) !important;
    background-image:
        /* Aurora Layer 1 — top-right cyan bloom (toned down) */
        radial-gradient(ellipse 80% 60% at 80% -10%, rgba(0, 212, 255, 0.08) 0%, transparent 60%),
        /* Aurora Layer 2 — bottom-left purple (toned down) */
        radial-gradient(ellipse 70% 55% at -10% 100%, rgba(168, 85, 247, 0.07) 0%, transparent 55%),
        /* Aurora Layer 3 — center (very subtle) */
        radial-gradient(ellipse 50% 40% at 50% 50%, rgba(0, 180, 255, 0.025) 0%, transparent 70%),
        /* Fine mesh grid */
        linear-gradient(rgba(255, 255, 255, 0.015) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.015) 1px, transparent 1px) !important;
    background-size: 100% 100%, 100% 100%, 100% 100%, 40px 40px, 40px 40px !important;
    background-attachment: fixed !important;
    overflow-x: hidden;
    color: var(--dash-text) !important;
    margin: 0;
    font-family: 'Tajawal', sans-serif;
    transition: background-color var(--transition-speed), color var(--transition-speed);
    position: relative;
}

/* Floating orbs — very subtle depth, not flashy */
body.dashboard-body::before,
body.dashboard-body::after {
    content: '';
    position: fixed;
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
    filter: blur(120px);
    animation: floatOrb 16s ease-in-out infinite alternate;
}

body.dashboard-body::before {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(0, 212, 255, 0.04) 0%, transparent 70%);
    top: -150px;
    right: -150px;
    animation-duration: 18s;
}

body.dashboard-body::after {
    width: 700px;
    height: 700px;
    background: radial-gradient(circle, rgba(168, 85, 247, 0.035) 0%, transparent 70%);
    bottom: -150px;
    left: -150px;
    animation-duration: 22s;
    animation-delay: -8s;
}

@keyframes floatOrb {
    0% {
        transform: translate(0, 0);
    }

    50% {
        transform: translate(30px, 20px);
    }

    100% {
        transform: translate(-15px, -20px);
    }
}

/* Light mode bg */
[data-theme="light"] body.dashboard-body {
    background-color: #eef2f9 !important;
    background-image:
        radial-gradient(ellipse 80% 50% at 90% 0%, rgba(99, 179, 237, 0.1) 0%, transparent 55%),
        radial-gradient(ellipse 60% 50% at 0% 100%, rgba(139, 92, 246, 0.06) 0%, transparent 55%),
        linear-gradient(rgba(0, 0, 0, 0.008) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 0, 0, 0.008) 1px, transparent 1px) !important;
    background-size: 100% 100%, 100% 100%, 40px 40px, 40px 40px !important;
}

[data-theme="light"] body.dashboard-body::before {
    background: radial-gradient(circle, rgba(99, 179, 237, 0.05) 0%, transparent 70%);
}

[data-theme="light"] body.dashboard-body::after {
    background: radial-gradient(circle, rgba(139, 92, 246, 0.04) 0%, transparent 70%);
}


/* Force Navbar to be full-width and not a capsule */
.dashboard-body .header-nav {
    max-width: 100% !important;
    width: 100% !important;
    margin-top: 0 !important;
    border-radius: 0 !important;
    height: var(--header-height) !important;
    border-left: none !important;
    border-right: none !important;
    border-top: none !important;
    border-bottom: 1px solid var(--dash-card-border) !important;
    background: var(--dash-sidebar-bg) !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1) !important;
}

/* Hide Default Scrollbar */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: var(--dash-scroll-track);
}

::-webkit-scrollbar-thumb {
    background: rgba(0, 198, 255, 0.3);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--neon-cyan);
}

/* 2. Top Navbar Custom Additions */
.main-header-wrapper {
    position: sticky;
    top: 0;
    width: 100%;
    z-index: 1000;
    background: var(--dash-sidebar-bg);
    border-bottom: 1px solid var(--dash-card-border);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    height: var(--header-height);
}

/* User Dropdown inside Navbar */
.user-dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-trigger {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-weight: 800 !important;
}

.dropdown-arrow {
    transition: transform 0.3s ease;
}

.user-dropdown.active .dropdown-arrow {
    transform: rotate(180deg);
}

.user-dropdown-menu {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    background: var(--dash-card-bg);
    border: 1px solid var(--dash-card-border);
    border-radius: 12px;
    box-shadow: var(--dash-card-shadow);
    list-style: none;
    padding: 8px;
    margin: 0;
    min-width: 170px;
    display: none;
    z-index: 1100;
    animation: dropdownFade 0.25s ease forwards;
    transform-origin: top left;
}

.user-dropdown.active .user-dropdown-menu {
    display: block;
}

@keyframes dropdownFade {
    from {
        opacity: 0;
        transform: translateY(-8px) scale(0.95);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.user-dropdown-menu li {
    margin: 4px 0;
}

.user-dropdown-menu .dropdown-item {
    width: 100%;
    background: none;
    border: none;
    padding: 10px 14px;
    color: var(--dash-text-muted);
    text-align: right;
    font-size: 0.95rem;
    font-weight: 700;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.2s ease;
    text-decoration: none;
}

.user-dropdown-menu .dropdown-item:hover {
    background: rgba(0, 198, 255, 0.08);
    color: var(--neon-cyan);
}

.user-dropdown-menu #globalNavLogoutBtn:hover {
    background: rgba(239, 68, 68, 0.15);
    color: #ef4444;
}

/* 3. Base Wrapper Grid (placed under the top navbar) */
.dashboard-grid-container {
    display: grid;
    grid-template-columns: var(--sidebar-width) 1fr;
    min-height: calc(100vh - var(--header-height));
    position: relative;
}

/* 4. Sidebar Styling — Glassy with iridescent accent border */
.dashboard-sidebar {
    background: var(--dash-sidebar-bg) !important;
    border-left: 1px solid var(--dash-sidebar-border) !important;
    border-right: none !important;
    display: flex;
    flex-direction: column;
    height: calc(100vh - var(--header-height));
    position: sticky;
    /* MUST stay sticky — do NOT add position:relative after this */
    top: var(--header-height);
    right: 0;
    z-index: 100;
    padding: 24px 14px;
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    box-shadow: -8px 0 40px rgba(0, 0, 0, 0.2), inset -1px 0 0 rgba(0, 212, 255, 0.1);
    transition: transform var(--transition-speed) ease;
    overflow: hidden;
    /* allows ::before stripe — no position:relative needed */
}

/* Iridescent vertical stripe on sidebar right edge */
.dashboard-sidebar::before {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    width: 3px;
    height: 100%;
    background: linear-gradient(180deg,
            rgba(0, 212, 255, 0) 0%,
            rgba(0, 212, 255, 0.8) 30%,
            rgba(168, 85, 247, 0.8) 60%,
            rgba(254, 44, 85, 0.4) 80%,
            rgba(0, 212, 255, 0) 100%);
    opacity: 0.6;
    pointer-events: none;
    animation: sidebarStripe 6s ease-in-out infinite alternate;
}

@keyframes sidebarStripe {
    0% {
        opacity: 0.15;
    }

    50% {
        opacity: 0.35;
    }

    100% {
        opacity: 0.2;
    }
}

.sidebar-menu {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
    position: relative;
    z-index: 1;
}

.sidebar-tab-btn {
    width: 100%;
    background: transparent !important;
    border: 1px solid transparent !important;
    border-radius: 14px;
    color: var(--dash-text-muted) !important;
    padding: 13px 16px;
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 14px;
    transition: all 0.25s cubic-bezier(0.25, 0.8, 0.25, 1);
    text-align: right;
    position: relative;
    overflow: hidden;
}

.sidebar-tab-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.08), rgba(168, 85, 247, 0.05));
    opacity: 0;
    transition: opacity 0.25s ease;
}

.sidebar-tab-btn i {
    font-size: 1.1rem;
    transition: transform 0.3s ease, color 0.25s ease;
    position: relative;
    z-index: 1;
}

.sidebar-tab-btn span {
    position: relative;
    z-index: 1;
}

.sidebar-tab-btn:hover {
    border-color: rgba(0, 212, 255, 0.2) !important;
    color: #e2e8f0 !important;
    transform: translateX(-3px);
}

.sidebar-tab-btn:hover::before {
    opacity: 1;
}

.sidebar-tab-btn:hover i {
    transform: scale(1.12) rotate(-3deg);
}

/* ======================================================
   Per-Tab Icon Colors — Dark Mode
   ====================================================== */

/* Base: icons start muted, overridden per tab below */
.sidebar-tab-btn i {
    font-size: 1.1rem;
    transition: transform 0.3s ease, color 0.25s ease, filter 0.25s ease;
    position: relative;
    z-index: 1;
    color: var(--dash-text-muted);
}

/* الملف الشخصي — Cyan */
[data-target="tab-profile"] i {
    color: #38bdf8 !important;
}

[data-target="tab-profile"]:hover i,
[data-target="tab-profile"].active i {
    color: #00d4ff !important;
    filter: none !important;
}

/* اشتراكاتي — Gold */
[data-target="tab-subscriptions"] i {
    color: #fbbf24 !important;
}

[data-target="tab-subscriptions"]:hover i,
[data-target="tab-subscriptions"].active i {
    color: #f59e0b !important;
    filter: none !important;
}

/* حقيبتي — Purple */
[data-target="tab-inventory"] i {
    color: #c084fc !important;
}

[data-target="tab-inventory"]:hover i,
[data-target="tab-inventory"].active i {
    color: #a855f7 !important;
    filter: none !important;
}

/* الإعدادات — Green */
[data-target="tab-settings"] i {
    color: #34d399 !important;
}

[data-target="tab-settings"]:hover i,
[data-target="tab-settings"].active i {
    color: #10b981 !important;
    filter: none !important;
}

/* Light Mode — softer, darker */
[data-theme="light"] [data-target="tab-profile"] i {
    color: #0284c7 !important;
}

[data-theme="light"] [data-target="tab-profile"]:hover i,
[data-theme="light"] [data-target="tab-profile"].active i {
    color: #0369a1 !important;
    filter: none !important;
}

[data-theme="light"] [data-target="tab-subscriptions"] i {
    color: #d97706 !important;
}

[data-theme="light"] [data-target="tab-subscriptions"]:hover i,
[data-theme="light"] [data-target="tab-subscriptions"].active i {
    color: #b45309 !important;
    filter: none !important;
}

[data-theme="light"] [data-target="tab-inventory"] i {
    color: #7c3aed !important;
}

[data-theme="light"] [data-target="tab-inventory"]:hover i,
[data-theme="light"] [data-target="tab-inventory"].active i {
    color: #6d28d9 !important;
    filter: none !important;
}

[data-theme="light"] [data-target="tab-settings"] i {
    color: #059669 !important;
}

[data-theme="light"] [data-target="tab-settings"]:hover i,
[data-theme="light"] [data-target="tab-settings"].active i {
    color: #047857 !important;
    filter: none !important;
}

[data-target="tab-profile"].active {
    background: rgba(0, 212, 255, 0.08) !important;
    border: 1px solid rgba(0, 212, 255, 0.2) !important;
    box-shadow: none !important;
    color: #e2e8f0 !important;
}

[data-target="tab-subscriptions"].active {
    background: rgba(245, 158, 11, 0.09) !important;
    border: 1px solid rgba(251, 191, 36, 0.2) !important;
    box-shadow: none !important;
    color: #fde68a !important;
}

[data-target="tab-inventory"].active {
    background: rgba(168, 85, 247, 0.09) !important;
    border: 1px solid rgba(168, 85, 247, 0.2) !important;
    box-shadow: none !important;
    color: #e9d5ff !important;
}

[data-target="tab-settings"].active {
    background: rgba(16, 185, 129, 0.09) !important;
    border: 1px solid rgba(52, 211, 153, 0.2) !important;
    box-shadow: none !important;
    color: #a7f3d0 !important;
}

/* Light mode active tabs — clean, no glow */
[data-theme="light"] [data-target="tab-profile"]:hover i,
[data-theme="light"] [data-target="tab-profile"].active i {
    color: #0369a1 !important;
    filter: none !important;
}

[data-theme="light"] [data-target="tab-profile"].active {
    background: rgba(2, 132, 199, 0.08) !important;
    border: 1px solid rgba(2, 132, 199, 0.2) !important;
    box-shadow: none !important;
    color: #0369a1 !important;
}

[data-theme="light"] [data-target="tab-subscriptions"]:hover i,
[data-theme="light"] [data-target="tab-subscriptions"].active i {
    color: #b45309 !important;
    filter: none !important;
}

[data-theme="light"] [data-target="tab-subscriptions"].active {
    background: rgba(217, 119, 6, 0.08) !important;
    border: 1px solid rgba(217, 119, 6, 0.2) !important;
    box-shadow: none !important;
    color: #92400e !important;
}

[data-theme="light"] [data-target="tab-inventory"]:hover i,
[data-theme="light"] [data-target="tab-inventory"].active i {
    color: #6d28d9 !important;
    filter: none !important;
}

[data-theme="light"] [data-target="tab-inventory"].active {
    background: rgba(124, 58, 237, 0.08) !important;
    border: 1px solid rgba(124, 58, 237, 0.2) !important;
    box-shadow: none !important;
    color: #4c1d95 !important;
}

[data-theme="light"] [data-target="tab-settings"]:hover i,
[data-theme="light"] [data-target="tab-settings"].active i {
    color: #047857 !important;
    filter: none !important;
}

[data-theme="light"] [data-target="tab-settings"].active {
    background: rgba(5, 150, 105, 0.08) !important;
    border: 1px solid rgba(5, 150, 105, 0.2) !important;
    box-shadow: none !important;
    color: #065f46 !important;
}

/* Mobile Header overrides (not shown on bottom-bar mode) */
.dashboard-mobile-header {
    display: none;
}

/* 5. Main Content Area Styling */
.dashboard-main-content {
    padding: 40px;
    z-index: 1;
    overflow-y: auto;
    max-height: calc(100vh - var(--header-height));
}

/* Tab Content Visibility */
.tab-content-panel {
    display: none;
    animation: fadeIn 0.4s ease-out forwards;
}

.tab-content-panel.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Section Header titles — gradient text */
.tab-section-title {
    font-size: 1.7rem;
    font-weight: 900;
    margin-bottom: 28px;
    color: var(--dash-text) !important;
    display: flex;
    align-items: center;
    gap: 12px;
    position: relative;
    padding-bottom: 14px;
}

/* Neon underline accent */
.tab-section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 60px;
    height: 2px;
    background: linear-gradient(90deg, rgba(0, 212, 255, 0), rgba(0, 212, 255, 0.9), rgba(168, 85, 247, 0.7));
    border-radius: 2px;
    transition: width 0.4s ease;
}

.tab-section-title:hover::after {
    width: 120px;
}

.tab-section-title i {
    color: var(--neon-cyan);
}


/* 6. Card Styling — Premium glassmorphism with gradient top border */
.premium-player-card,
.inventory-section,
.settings-form-wrapper {
    background: var(--dash-card-bg) !important;
    border: 1px solid var(--dash-card-border) !important;
    border-radius: 20px;
    backdrop-filter: blur(28px);
    -webkit-backdrop-filter: blur(28px);
    box-shadow: var(--dash-card-shadow) !important;
    color: var(--dash-text) !important;
    position: relative;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

/* Gradient shimmer line at top of each card */
.premium-player-card::before,
.inventory-section::before,
.settings-form-wrapper::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg,
            transparent 0%,
            rgba(0, 212, 255, 0.6) 25%,
            rgba(168, 85, 247, 0.8) 50%,
            rgba(0, 212, 255, 0.6) 75%,
            transparent 100%);
    opacity: 0.8;
    pointer-events: none;
    border-radius: 20px 20px 0 0;
}

.premium-player-card:hover,
.inventory-section:hover {
    transform: translateY(-2px);
    box-shadow:
        0 16px 48px rgba(0, 0, 0, 0.45),
        0 0 60px rgba(0, 212, 255, 0.1),
        0 0 100px rgba(168, 85, 247, 0.07) !important;
    border-color: rgba(0, 212, 255, 0.3) !important;
}

/* Subscription cards inherit from dynamic CSS section */
.subscription-card {
    transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

/* Gamer Card Styling — clean glassmorphism */
.gamer-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    padding: 35px 30px !important;
    position: relative;
    margin-bottom: 30px;
    border-radius: 20px !important;
    background: rgba(6, 10, 22, 0.85) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4) !important;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    overflow: hidden;
    transition: border-color 0.3s ease, transform 0.3s ease;
}

.gamer-card:hover {
    border-color: rgba(0, 212, 255, 0.15) !important;
    transform: translateY(-2px);
}

/* Light Mode Overrides for Gamer Card */
[data-theme="light"] .gamer-card {
    background: rgba(255, 255, 255, 0.65) !important;
    border: 1px solid #0097b5 !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08) !important;
    backdrop-filter: blur(10px) !important;
    -webkit-backdrop-filter: blur(10px) !important;
}

/* Light mode: gradient-clip text is invisible on white — use solid dark color instead */
[data-theme="light"] .gamer-title {
    background: none !important;
    -webkit-background-clip: unset !important;
    -webkit-text-fill-color: unset !important;
    background-clip: unset !important;
    color: #0f172a !important;
    text-shadow: none !important;
}

[data-theme="light"] .email-label {
    color: #4b5563 !important;
}

[data-theme="light"] .gamer-badge-title {
    color: #4b5563 !important;
}

[data-theme="light"] .progress-details span {
    color: #4b5563 !important;
}

[data-theme="light"] .xp-badge-value,
[data-theme="light"] .level-badge-value,
[data-theme="light"] .qid-box-small {
    color: #0097b5 !important;
    border-color: rgba(0, 151, 181, 0.3) !important;
    background: rgba(0, 151, 181, 0.03) !important;
}

.copy-qid-button {
    background: none !important;
    border: none !important;
    color: var(--neon-cyan) !important;
    cursor: pointer !important;
    padding: 0 !important;
    margin: 0 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 0.95rem !important;
    transition: transform 0.2s ease, color 0.2s ease !important;
    box-shadow: none !important;
}

.copy-qid-button:hover {
    transform: scale(1.15) !important;
    color: var(--dash-text) !important;
}

[data-theme="light"] .copy-qid-button {
    color: #0097b5 !important;
}

.gamer-title {
    font-size: 2.4rem;
    font-weight: 900;
    background: linear-gradient(135deg, #ffffff 0%, #7dd3fc 60%, #c4b5fd 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: none;
    text-align: center;
    width: 100%;
    margin: 0;
}

.profile-meta-text {
    display: flex;
    flex-direction: column;
    gap: 6px;
    align-items: center;
    text-align: center;
}

.profile-meta-text .email-label {
    font-size: 0.95rem;
    color: var(--dash-text-muted);
}

.gamer-info-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 25px;
    width: 100%;
    margin-top: 10px;
}

.gamer-badge-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
}

.gamer-badge-title {
    font-size: 0.8rem;
    font-weight: 800;
    color: var(--dash-text-muted);
    text-transform: uppercase;
}

.qid-box-small {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(0, 212, 255, 0.05);
    border: 1px solid rgba(0, 212, 255, 0.18);
    padding: 6px 14px;
    border-radius: 10px;
    font-family: 'Outfit', monospace;
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--neon-cyan);
}

.level-badge-value {
    font-size: 1.25rem;
    font-weight: 800;
    color: #c084fc;
    background: rgba(168, 85, 247, 0.07);
    border: 1px solid rgba(168, 85, 247, 0.2);
    padding: 4px 14px;
    border-radius: 10px;
}

.xp-badge-value {
    font-size: 1.15rem;
    font-weight: 800;
    color: #34d399;
    background: rgba(16, 185, 129, 0.07);
    border: 1px solid rgba(16, 185, 129, 0.2);
    padding: 5px 14px;
    border-radius: 10px;
}

[data-theme="light"] .level-badge-value,
[data-theme="light"] .xp-badge-value {
    text-shadow: none !important;
}

.gamer-separator {
    width: 1px;
    height: 35px;
    background: var(--dash-card-inner-border);
}

.player-xp-progress {
    width: 100%;
    max-width: 600px;
    margin: 8px 0 !important;
}

.neon-progress-container {
    height: 8px;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 2px !important;
    border: 1px solid rgba(0, 198, 255, 0.3);
    overflow: hidden;
    position: relative;
    box-shadow: 0 0 10px rgba(0, 198, 255, 0.1);
}

[data-theme="light"] .neon-progress-container {
    background: rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(0, 151, 181, 0.3);
    box-shadow: none !important;
}

.neon-progress-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg,
            #0ea5e9 0%,
            #8b5cf6 50%,
            #0ea5e9 100%) !important;
    background-size: 200% 100% !important;
    animation: energyBarFlow 3s linear infinite !important;
    border-radius: 0px !important;
    box-shadow: none !important;
    transition: width 1.2s cubic-bezier(0.1, 1, 0.1, 1);
    position: relative;
}

[data-theme="light"] .neon-progress-fill {
    background: linear-gradient(90deg, #0097b5, #7c3aed, #0097b5) !important;
    box-shadow: none !important;
}

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

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

/* Condensed Stats Row Styling */
.gamer-stats-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    width: 100%;
    margin-top: 25px;
}

.gamer-stat-box {
    flex: 1;
    max-width: 180px;
    background: rgba(5, 8, 18, 0.8) !important;
    border: 1px solid rgba(0, 212, 255, 0.12) !important;
    border-radius: 14px;
    padding: 20px 10px !important;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px !important;
    box-shadow: inset 0 0 14px rgba(0, 212, 255, 0.04) !important;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    position: relative;
    overflow: hidden;
}

.gamer-stat-box::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(0, 212, 255, 0.4), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.gamer-stat-box:hover {
    border-color: rgba(0, 212, 255, 0.35) !important;
    box-shadow:
        0 0 24px rgba(0, 212, 255, 0.15),
        inset 0 0 20px rgba(0, 212, 255, 0.05) !important;
    transform: translateY(-4px);
}

.gamer-stat-box:hover::before {
    opacity: 1;
}

.gamer-stat-box i {
    margin-bottom: 0 !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: filter 0.3s ease;
}

.gamer-stat-box:hover i {
    filter: brightness(1.3) drop-shadow(0 0 6px currentColor);
}

.gamer-stat-box i.fa-regular.fa-clock {
    font-size: 1.6rem !important;
    color: var(--neon-cyan) !important;
}

[data-theme="light"] .gamer-stat-box i.fa-regular.fa-clock {
    color: #0097b5 !important;
}

.gamer-stat-box i.fa-solid.fa-tower-broadcast {
    font-size: 1.6rem !important;
    color: #c084fc !important;
}

.gamer-stat-box i.fa-solid.fa-trophy {
    font-size: 1.6rem !important;
    color: #fbbf24 !important;
}

[data-theme="light"] .gamer-stat-box {
    background: rgba(255, 255, 255, 0.75) !important;
    border: 1px solid rgba(0, 151, 181, 0.3) !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03) !important;
}

[data-theme="light"] .gamer-stat-box:hover {
    border-color: #0097b5 !important;
    box-shadow: 0 6px 18px rgba(0, 151, 181, 0.15) !important;
    background: rgba(0, 151, 181, 0.03) !important;
    transform: translateY(-3px);
}

.gamer-stat-val {
    font-size: 2rem !important;
    font-weight: 800 !important;
    color: var(--neon-cyan) !important;
    font-family: 'Outfit', sans-serif !important;
    margin: 0 !important;
    line-height: 1 !important;
}

[data-theme="light"] .gamer-stat-val {
    color: #11141a !important;
}

.gamer-stat-lbl {
    font-size: 0.8rem;
    font-weight: 800;
    color: var(--dash-text-muted);
    text-align: center;
    margin: 0 !important;
    line-height: 1.2 !important;
}

[data-theme="light"] .gamer-stat-lbl {
    color: #4b5563 !important;
}

/* 7. Subscriptions Tab Styling */
.subscriptions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
}

.subscription-card {
    padding: 30px;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.subscription-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--neon-cyan), var(--neon-purple));
}

.subscription-card:hover {
    transform: translateY(-5px);
    border-color: rgba(0, 114, 255, 0.45) !important;
    box-shadow: var(--dash-card-shadow) !important;
}

.sub-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.sub-plan-name {
    font-size: 1.4rem;
    font-weight: 900;
    color: var(--dash-text);
}

.sub-status-badge {
    background: rgba(16, 185, 129, 0.1);
    color: var(--neon-green);
    border: 1px solid rgba(16, 185, 129, 0.3);
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.sub-status-badge.inactive {
    background: rgba(239, 68, 68, 0.15);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.sub-details-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.sub-detail-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--dash-card-inner-border);
    padding-bottom: 10px;
}

.sub-detail-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.sub-detail-label {
    color: var(--dash-text-muted);
    font-size: 0.9rem;
}

.sub-detail-value {
    color: var(--dash-text);
    font-weight: 700;
}

/* 8. Inventory Sub-tabs & Grid slots */
.inventory-section {
    padding: 35px;
}

.inventory-subtabs {
    display: flex;
    gap: 15px;
    margin-bottom: 25px;
    border-bottom: 1px solid var(--dash-card-inner-border);
    padding-bottom: 15px;
}

.inv-subtab-btn {
    background: none;
    border: none;
    color: var(--dash-text-muted);
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
    padding: 8px 18px;
    border-radius: 8px;
    transition: all 0.2s ease;
    border-bottom: 3px solid transparent;
}

.inv-subtab-btn:hover {
    color: var(--dash-text);
    background: var(--dash-card-inner-bg);
}

.inv-subtab-btn.active {
    background: rgba(0, 198, 255, 0.12) !important;
    color: var(--neon-cyan) !important;
    border: 1px solid var(--neon-cyan) !important;
    border-bottom: 3px solid var(--neon-cyan) !important;
    box-shadow: 0 0 10px rgba(0, 198, 255, 0.2) !important;
}

.inv-tab-content {
    display: none;
    animation: fadeIn 0.3s ease-in-out forwards;
}

.inv-tab-content.active {
    display: block;
}

.loot-slots-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 20px;
    min-height: unset;
}

.loot-slot-item {
    aspect-ratio: 1;
    background: var(--dash-card-inner-bg);
    border: 1px solid var(--dash-card-inner-border);
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 15px;
    position: relative;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: inset 0 0 10px var(--dash-card-inner-border);
}

.loot-slot-item::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: radial-gradient(circle at center, rgba(0, 114, 255, 0.12) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.loot-slot-item:hover {
    border-color: var(--neon-cyan);
    box-shadow: 0 8px 20px rgba(0, 114, 255, 0.25);
    transform: translateY(-4px) scale(1.03);
}

.loot-slot-item:hover::before {
    opacity: 1;
}

.loot-slot-item img {
    width: 65%;
    height: 65%;
    object-fit: contain;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
    transition: transform 0.3s ease;
    z-index: 1;
}

.loot-slot-item:hover img {
    transform: scale(1.1);
}

.loot-slot-name {
    margin-top: 10px;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--dash-text);
    text-align: center;
    white-space: normal;
    word-break: break-word;
    width: 100%;
    z-index: 1;
}

.loot-empty-state {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 15px;
    color: var(--dash-text-muted);
    text-align: center;
    padding: 60px 0;
}

.loot-empty-state i {
    font-size: 3.5rem;
    color: rgba(0, 114, 255, 0.15);
}

/* 9. Settings: Livestream Account Linking Grid */
.settings-form-wrapper {
    padding: 35px;
    max-width: 100%;
}

.stream-connect-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    margin-top: 10px;
}

.stream-connect-card {
    background: var(--dash-card-inner-bg) !important;
    border: 1px solid var(--dash-card-inner-border) !important;
    border-radius: 12px;
    padding: 12px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: all 0.3s ease;
}

.stream-card-left {
    display: flex;
    align-items: center;
    gap: 15px;
}

.stream-icon {
    font-size: 1.6rem;
    width: 32px;
    text-align: center;
}

.stream-icon-svg-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
}

.stream-card-info h4 {
    font-size: 1rem;
    font-weight: 800;
    color: var(--dash-text);
    margin-bottom: 2px;
}

.stream-card-info p {
    font-size: 0.8rem;
    color: var(--dash-text-muted);
    margin: 0;
}

.stream-card-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.stream-status {
    font-size: 0.85rem;
    font-weight: 800;
    color: var(--dash-text-muted);
    background: var(--dash-card-inner-bg);
    border: 1px solid var(--dash-card-inner-border);
    padding: 5px 12px;
    border-radius: 20px;
    letter-spacing: 0.5px;
}

.connect-btn {
    font-weight: 800 !important;
}

/* TikTok Card Specific Vibe */
.tiktok-card {
    border-color: rgba(254, 44, 85, 0.25) !important;
}

.tiktok-card .stream-icon {
    color: var(--neon-pink);
}

.tiktok-card:hover {
    border-color: var(--neon-pink) !important;
    box-shadow: 0 8px 25px rgba(254, 44, 85, 0.15);
}

.tiktok-card .connect-btn:hover {
    background: var(--neon-pink) !important;
    border-color: var(--neon-pink) !important;
    color: #ffffff !important;
    box-shadow: 0 4px 15px rgba(254, 44, 85, 0.4) !important;
}

/* Twitch Card Specific Vibe */
.twitch-card {
    border-color: rgba(145, 70, 255, 0.3) !important;
}

.twitch-card .stream-icon {
    color: var(--neon-purple);
}

.twitch-card:hover {
    border-color: var(--neon-purple) !important;
    box-shadow: 0 8px 25px rgba(145, 70, 255, 0.15);
}

.twitch-card .connect-btn:hover {
    background: var(--neon-purple) !important;
    border-color: var(--neon-purple) !important;
    color: #ffffff !important;
    box-shadow: 0 4px 15px rgba(145, 70, 255, 0.4) !important;
}

/* Kick Card Specific Vibe */
.kick-card {
    border-color: rgba(16, 185, 129, 0.3) !important;
}

.kick-card:hover {
    border-color: #10b981 !important;
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.15);
}

.kick-card .connect-btn:hover {
    background: #10b981 !important;
    border-color: #10b981 !important;
    color: #ffffff !important;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4) !important;
}

/* Form Styles */
.settings-form-group label {
    display: block;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--dash-text);
    margin-bottom: 8px;
}

.settings-input {
    width: 100%;
    background: var(--dash-input-bg);
    border: 1px solid var(--dash-input-border);
    border-radius: 10px;
    padding: 12px 16px;
    color: var(--dash-input-text);
    font-size: 1rem;
    transition: all 0.3s ease;
    text-align: right;
}

.settings-input:focus {
    outline: none;
    border-color: var(--neon-cyan);
    box-shadow: 0 0 10px rgba(0, 114, 255, 0.25);
}

.settings-submit-btn {
    width: 100%;
    background: linear-gradient(135deg, var(--neon-cyan), var(--neon-purple));
    border: none;
    border-radius: 10px;
    color: #ffffff;
    padding: 14px 20px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0, 114, 255, 0.3);
    transition: all 0.3s ease;
}

.settings-submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 114, 255, 0.45);
}

.settings-submit-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* 10. Responsive Layout (Desktop Grid & Mobile Bottom Navbar) */
@media (max-width: 991px) {
    .dashboard-grid-container {
        grid-template-columns: 240px 1fr;
    }
}

@media (max-width: 768px) {
    .dashboard-grid-container {
        grid-template-columns: 1fr;
        min-height: calc(100vh - var(--header-height));
    }

    /* Transform Sidebar into Bottom App Navigation Bar */
    .dashboard-sidebar {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        top: auto;
        height: 72px !important;
        width: 100vw;
        border-top: 1px solid var(--dash-sidebar-border) !important;
        border-left: none !important;
        padding: 0 !important;
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: space-around;
        z-index: 1000;
        background: var(--dash-sidebar-bg) !important;
        backdrop-filter: blur(15px);
        box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.5) !important;
    }

    .sidebar-menu {
        display: grid !important;
        grid-template-columns: repeat(4, 1fr) !important;
        width: 100% !important;
        height: 100% !important;
        gap: 0 !important;
        padding: 0 !important;
        margin: 0 !important;
        align-items: center !important;
    }

    .sidebar-tab-btn {
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 2px !important;
        padding: 5px 2px !important;
        font-size: 0.72rem !important;
        border: none !important;
        background: none !important;
        text-align: center !important;
        color: var(--dash-text-muted) !important;
        box-shadow: none !important;
        border-radius: 0 !important;
        height: 100% !important;
    }

    .sidebar-tab-btn i {
        margin: 0 !important;
        font-size: 1.15rem !important;
    }

    .sidebar-tab-btn:hover {
        transform: none !important;
        background: none !important;
        color: var(--neon-cyan) !important;
    }

    .sidebar-tab-btn.active {
        background: none !important;
        border: none !important;
        box-shadow: none !important;
        color: var(--neon-cyan) !important;
    }

    .sidebar-tab-btn.active i {
        color: var(--neon-cyan) !important;
    }

    /* Extra padding inside main area to clear bottom bar */
    .dashboard-main-content {
        padding: 25px 20px 105px 20px !important;
        max-height: calc(100vh - var(--header-height));
    }

    /* Gamer card mobile layout */
    .gamer-info-row {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        gap: 15px !important;
    }

    .gamer-separator {
        display: none !important;
    }

    .gamer-badge-box {
        width: 100% !important;
        background: var(--dash-card-inner-bg);
        border: 1px solid var(--dash-card-inner-border);
        padding: 10px;
        border-radius: 12px;
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
        text-align: center !important;
    }

    .qid-box-small,
    .level-badge-value,
    .xp-badge-value {
        width: 100% !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        text-align: center !important;
        background: none !important;
        border: none !important;
        padding: 0 !important;
        box-shadow: none !important;
        margin: 0 auto !important;
    }

    .gamer-badge-box:first-child {
        grid-column: span 2;
    }

    /* Tooltip styles */
    .xp-tooltip-box {
        visibility: hidden;
        opacity: 0;
        position: absolute;
        bottom: 135%;
        right: 50%;
        transform: translateX(50%);
        background: rgba(10, 15, 30, 0.95);
        border: 1px solid var(--dash-card-border);
        color: #fff;
        padding: 12px;
        border-radius: 10px;
        width: 220px;
        font-size: 0.78rem;
        line-height: 1.5;
        font-weight: 700;
        box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
        z-index: 100;
        transition: opacity 0.3s ease, visibility 0.3s ease;
        text-align: right;
        pointer-events: none;
    }

    [data-theme="light"] .xp-tooltip-box {
        background: #ffffff;
        border-color: rgba(0, 0, 0, 0.1);
        color: #1a1d24;
        box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
    }

    /* Stats Row mobile grid layout */
    .gamer-stats-row {
        display: grid !important;
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 10px !important;
        width: 100% !important;
        margin-top: 15px !important;
    }

    .gamer-stat-box {
        padding: 8px 4px !important;
        max-width: 100% !important;
    }

    .gamer-stat-val {
        font-size: 1.4rem !important;
    }

    .gamer-stat-lbl {
        font-size: 0.72rem !important;
    }

    /* Settings Form: Mobile stack and margins */
    .settings-form-wrapper {
        padding-bottom: 120px !important;
        margin-bottom: 80px !important;
    }

    .stream-connect-card {
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
        gap: 15px !important;
        padding: 20px 15px !important;
    }

    .stream-card-left {
        flex-direction: column !important;
        gap: 10px !important;
        align-items: center !important;
    }

    .stream-card-right {
        width: 100% !important;
        flex-direction: column !important;
        gap: 10px !important;
        align-items: center !important;
    }

    .stream-card-right .connect-btn {
        width: 100% !important;
    }

    #changePasswordForm {
        flex-direction: column !important;
        align-items: stretch !important;
        width: 100% !important;
    }

    #changePasswordForm .settings-form-group {
        width: 100% !important;
    }

    #changePasswordForm button {
        width: 100% !important;
        margin-top: 10px !important;
    }
}

/* XP Help Popup Modal Styles */
.xp-help-modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(6, 8, 12, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: modalFadeIn 0.25s ease-out forwards;
}

.xp-help-modal-content {
    background: var(--dash-card-bg);
    border: 1px solid var(--dash-card-border);
    border-radius: 16px;
    width: 90%;
    max-width: 480px;
    padding: 25px;
    box-shadow: var(--dash-card-shadow);
    text-align: right;
    position: relative;
    animation: modalSlideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

[data-theme="light"] .xp-help-modal-backdrop {
    background: rgba(255, 255, 255, 0.7);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--dash-card-inner-border);
    padding-bottom: 12px;
    margin-bottom: 20px;
}

.modal-header h3 {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--dash-text);
    margin: 0;
}

.close-modal-btn {
    background: none;
    border: none;
    color: var(--dash-text-muted);
    font-size: 1.6rem;
    cursor: pointer;
    padding: 0;
    line-height: 1;
    transition: color 0.2s;
}

.close-modal-btn:hover {
    color: var(--dash-text);
}

.xp-rules-list {
    list-style: none;
    padding: 0;
    margin: 0 0 25px 0;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.xp-rules-list li {
    display: flex;
    gap: 15px;
    align-items: flex-start;
}

.xp-rules-list li i {
    font-size: 1.3rem;
    color: var(--neon-cyan);
    margin-top: 3px;
    width: 24px;
    text-align: center;
}

.xp-rules-list li div {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.xp-rules-list li div strong {
    font-size: 0.95rem;
    color: var(--dash-text);
}

.xp-rules-list li div span {
    font-size: 0.82rem;
    color: var(--dash-text-muted);
    line-height: 1.4;
}

.xp-note-box {
    background: var(--dash-card-inner-bg);
    border: 1px solid var(--dash-card-inner-border);
    padding: 12px 15px;
    border-radius: 10px;
    font-size: 0.8rem;
    color: var(--dash-text-muted);
    display: flex;
    gap: 10px;
    align-items: center;
    line-height: 1.4;
}

.xp-note-box i {
    color: var(--neon-cyan);
    font-size: 1rem;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes modalSlideUp {
    from {
        transform: translateY(20px);
    }

    to {
        transform: translateY(0);
    }
}

/* Gumroad recipient picker */
.gumroad-recipient-modal {
    text-align: right;
    direction: rtl;
}

.gumroad-recipient-intro {
    margin: 0 0 18px;
    color: var(--dash-text-muted);
    line-height: 1.7;
    font-size: 0.9rem;
}

.gumroad-recipient-options {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 11px;
}

.gumroad-recipient-option {
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 11px;
    min-height: 116px;
    padding: 15px 13px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    background: rgba(255, 255, 255, 0.035);
    color: var(--dash-text);
    text-align: right;
    cursor: pointer;
    transition: border-color 0.18s ease, background 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.gumroad-recipient-option:hover {
    transform: translateY(-2px);
    border-color: rgba(0, 212, 255, 0.42);
    background: rgba(0, 212, 255, 0.07);
}

.gumroad-recipient-option.is-selected {
    border-color: var(--neon-cyan, #00d4ff);
    background: linear-gradient(140deg, rgba(0, 212, 255, 0.14), rgba(129, 40, 202, 0.12));
    box-shadow: 0 0 0 1px rgba(0, 212, 255, 0.1), 0 10px 24px rgba(0, 0, 0, 0.18);
}

.gumroad-recipient-icon {
    display: grid;
    place-items: center;
    flex: 0 0 36px;
    width: 36px;
    height: 36px;
    border-radius: 11px;
    color: #d7f8ff;
    background: rgba(0, 212, 255, 0.15);
    font-size: 0.95rem;
}

.gumroad-recipient-icon.gift {
    color: #f6dcff;
    background: rgba(217, 70, 239, 0.15);
}

.gumroad-recipient-copy {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
}

.gumroad-recipient-copy strong {
    color: var(--dash-text);
    font-size: 0.93rem;
    font-weight: 850;
}

.gumroad-recipient-copy small {
    color: var(--dash-text-muted);
    font-size: 0.72rem;
    line-height: 1.45;
}

.gumroad-recipient-copy b {
    margin-top: 4px;
    color: var(--neon-cyan, #00d4ff);
    direction: ltr;
    text-align: right;
    font-family: 'Outfit', sans-serif;
    font-size: 0.76rem;
}

.gumroad-recipient-check {
    position: absolute;
    top: 10px;
    left: 10px;
    color: var(--neon-cyan, #00d4ff);
    opacity: 0;
    transform: scale(0.75);
    transition: opacity 0.18s ease, transform 0.18s ease;
}

.gumroad-recipient-option.is-selected .gumroad-recipient-check {
    opacity: 1;
    transform: scale(1);
}

.gumroad-gift-qid-wrap {
    margin-top: 14px;
    padding: 13px;
    border: 1px solid rgba(217, 70, 239, 0.26);
    border-radius: 13px;
    background: rgba(217, 70, 239, 0.07);
}

.gumroad-gift-qid-wrap[hidden] {
    display: none;
}

.gumroad-gift-qid-wrap label {
    display: block;
    margin-bottom: 8px;
    color: var(--dash-text);
    font-size: 0.78rem;
    font-weight: 800;
}

.gumroad-gift-qid-wrap input {
    width: 100%;
    box-sizing: border-box;
    padding: 11px 12px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 10px;
    outline: none;
    background: rgba(0, 0, 0, 0.2);
    color: var(--dash-text);
    direction: ltr;
    text-align: center;
    font-family: 'Outfit', sans-serif;
    transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.gumroad-gift-qid-wrap input:focus {
    border-color: #d946ef;
    box-shadow: 0 0 0 3px rgba(217, 70, 239, 0.12);
}

.gumroad-recipient-note {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    margin-top: 15px;
    color: var(--dash-text-muted);
    font-size: 0.75rem;
}

.gumroad-recipient-note i {
    color: #34d399;
}

[data-theme="light"] .gumroad-recipient-option {
    border-color: rgba(15, 23, 42, 0.1);
    background: rgba(255, 255, 255, 0.72);
}

[data-theme="light"] .gumroad-recipient-option.is-selected {
    background: linear-gradient(140deg, rgba(0, 212, 255, 0.13), rgba(168, 85, 247, 0.1));
}

[data-theme="light"] .gumroad-gift-qid-wrap input {
    border-color: rgba(15, 23, 42, 0.14);
    background: rgba(255, 255, 255, 0.88);
}

@media (max-width: 560px) {
    .gumroad-recipient-options {
        grid-template-columns: 1fr;
    }

    .gumroad-recipient-option {
        min-height: 92px;
    }
}

/* =========================================================
   Subscription Cards — Dynamic Styles
   ========================================================= */

/* Loading state */
.sub-loading-state {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 60px 20px;
    color: var(--dash-text-muted);
    font-size: 1rem;
}

.sub-loading-state i {
    font-size: 1.5rem;
    color: var(--neon-cyan);
}

/* Empty state */
.sub-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 60px 20px;
    text-align: center;
    color: var(--dash-text-muted);
}

.sub-empty-state i {
    font-size: 3rem;
    color: rgba(148, 163, 184, 0.5);
    /* dark mode: subtle gray */
    margin-bottom: 8px;
}

.sub-empty-state h4 {
    font-size: 1.1rem;
    color: var(--dash-text-primary);
    margin: 0;
}

.sub-empty-state p {
    font-size: 0.9rem;
    margin: 0;
    opacity: 0.7;
}

/* Light mode — make icon + text clearly visible */
[data-theme="light"] .sub-empty-state i {
    color: #94a3b8 !important;
    /* slate-400 — readable on white */
}

[data-theme="light"] .sub-empty-state h4 {
    color: #1e293b !important;
}

[data-theme="light"] .sub-empty-state p {
    color: #64748b !important;
    opacity: 1;
}

/* Light mode: make the CTA button text visible
   (btn-primary already has a blue bg so the icon/text need to be white) */
[data-theme="light"] .sub-empty-state .btn-primary {
    color: #ffffff !important;
}

[data-theme="light"] .sub-empty-state .btn-primary i {
    color: #ffffff !important;
}

/* Grid layout */
.subscriptions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 18px;
    padding-top: 6px;
}

/* Card */
.subscription-card {
    background: var(--dash-card-bg);
    border: 1px solid var(--dash-border);
    border-radius: 14px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.subscription-card:hover {
    border-color: var(--neon-cyan);
    box-shadow: 0 0 16px rgba(0, 240, 255, 0.08);
}

/* Card header */
.sub-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
}

.sub-plan-name {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--dash-text-primary);
    margin: 0;
}

/* Status badge */
.sub-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 700;
    background: rgba(0, 255, 135, 0.12);
    color: #00ff87;
    border: 1px solid rgba(0, 255, 135, 0.25);
    white-space: nowrap;
}

.sub-status-badge.inactive {
    background: rgba(255, 75, 75, 0.1);
    color: #ff6b6b;
    border-color: rgba(255, 75, 75, 0.2);
}

/* Detail list */
.sub-details-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.sub-detail-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--dash-border);
}

.sub-detail-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.sub-detail-label {
    color: var(--dash-text-muted);
}

.sub-detail-value {
    color: var(--dash-text-primary);
    font-weight: 600;
    font-family: 'Outfit', sans-serif;
}

/* Games / Platforms tags row */
.sub-detail-games {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
}

.sub-games-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 2px;
}

.sub-game-tag {
    font-size: 0.75rem;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 20px;
    background: rgba(0, 212, 255, 0.1);
    border: 1px solid rgba(0, 212, 255, 0.25);
    color: #7dd3fc;
    white-space: nowrap;
}

[data-theme="light"] .sub-game-tag {
    background: rgba(2, 132, 199, 0.08);
    border-color: rgba(2, 132, 199, 0.25);
    color: #0369a1;
}

/* Expired renewal banner */
.sub-renew-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-top: 12px;
    padding: 10px 14px;
    border-radius: 10px;
    background: rgba(240, 165, 0, 0.1);
    border: 1px solid rgba(240, 165, 0, 0.25);
    font-size: 0.85rem;
    color: #fbbf24;
    font-weight: 600;
}

[data-theme="light"] .sub-renew-banner {
    background: rgba(217, 119, 6, 0.07);
    border-color: rgba(217, 119, 6, 0.25);
    color: #92400e;
}

/* Inactive card dimming */
.subscription-card.inactive {
    opacity: 0.75;
}

/* =========================================================
   Player Dashboard Refresh - Account UX Upgrade
   ========================================================= */
body.dashboard-body {
    background-color: #060914 !important;
    background-image:
        linear-gradient(135deg, rgba(0, 212, 255, 0.11) 0%, transparent 26%),
        linear-gradient(315deg, rgba(16, 185, 129, 0.08) 0%, transparent 24%),
        linear-gradient(45deg, rgba(245, 158, 11, 0.07) 0%, transparent 22%),
        repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.018) 0 1px, transparent 1px 38px),
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.014) 0 1px, transparent 1px 38px) !important;
}

body.dashboard-body::before,
body.dashboard-body::after,
.bg-glow-1,
.bg-glow-2 {
    display: none !important;
}

[data-theme="light"] body.dashboard-body {
    background-color: #f3f7fb !important;
    background-image:
        linear-gradient(135deg, rgba(2, 132, 199, 0.12) 0%, transparent 28%),
        linear-gradient(315deg, rgba(5, 150, 105, 0.09) 0%, transparent 24%),
        linear-gradient(45deg, rgba(217, 119, 6, 0.08) 0%, transparent 22%),
        repeating-linear-gradient(0deg, rgba(15, 23, 42, 0.035) 0 1px, transparent 1px 40px),
        repeating-linear-gradient(90deg, rgba(15, 23, 42, 0.025) 0 1px, transparent 1px 40px) !important;
}

.dashboard-grid-container {
    isolation: isolate;
}

.dashboard-grid-container::before {
    content: '';
    position: fixed;
    inset: var(--header-height) 0 0 0;
    pointer-events: none;
    z-index: -1;
    background:
        linear-gradient(90deg, rgba(0, 212, 255, 0.05), transparent 22%, rgba(16, 185, 129, 0.035) 64%, transparent),
        linear-gradient(180deg, rgba(255, 255, 255, 0.035), transparent 34%);
}

.dashboard-main-content {
    position: relative;
    padding: 34px clamp(22px, 4vw, 48px) 48px !important;
}

.dashboard-hero-panel {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(320px, 0.85fr);
    gap: 22px;
    align-items: stretch;
    margin-bottom: 30px;
    padding: clamp(22px, 3vw, 34px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 22px;
    background:
        linear-gradient(135deg, rgba(13, 20, 38, 0.94), rgba(8, 13, 28, 0.78)),
        linear-gradient(90deg, rgba(0, 212, 255, 0.12), rgba(245, 158, 11, 0.08));
    box-shadow: 0 22px 70px rgba(0, 0, 0, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.08);
    overflow: hidden;
    position: relative;
}

.dashboard-hero-panel::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(0, 212, 255, 0.16), transparent 1px),
        linear-gradient(0deg, rgba(255, 255, 255, 0.04), transparent 1px);
    background-size: 58px 58px;
    mask-image: linear-gradient(90deg, rgba(0, 0, 0, 0.5), transparent 75%);
    pointer-events: none;
}

.dashboard-hero-copy,
.dashboard-hero-stats {
    position: relative;
    z-index: 1;
}

.dashboard-kicker {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    padding: 5px 11px;
    border: 1px solid rgba(0, 212, 255, 0.28);
    border-radius: 999px;
    color: #7dd3fc;
    background: rgba(0, 212, 255, 0.09);
    font-size: 0.78rem;
    font-weight: 900;
}

.dashboard-hero-copy h1 {
    margin: 14px 0 10px;
    color: var(--dash-text);
    font-size: clamp(1.85rem, 4vw, 3.15rem);
    line-height: 1.12;
    letter-spacing: 0;
    font-weight: 950;
}

.dashboard-hero-copy p {
    margin: 0;
    max-width: 620px;
    color: var(--dash-text-muted);
    font-size: 1rem;
    line-height: 1.8;
}

.dashboard-quick-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 22px;
}

.dashboard-jump-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 40px;
    padding: 9px 14px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.055);
    color: var(--dash-text);
    font-weight: 850;
    cursor: pointer;
    transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.dashboard-jump-btn:hover {
    transform: translateY(-2px);
    border-color: rgba(0, 212, 255, 0.45);
    background: rgba(0, 212, 255, 0.11);
}

.dashboard-hero-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.hero-stat-card {
    min-height: 118px;
    padding: 16px;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.055);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.hero-stat-identity {
    grid-column: 1 / -1;
    min-height: 104px;
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.11), rgba(16, 185, 129, 0.08));
}

.hero-stat-label {
    color: var(--dash-text-muted);
    font-size: 0.78rem;
    font-weight: 900;
}

.hero-stat-card strong {
    color: var(--dash-text);
    font-family: 'Outfit', 'Tajawal', sans-serif;
    font-size: 1.35rem;
    line-height: 1.25;
    overflow-wrap: anywhere;
}

.hero-stat-card small {
    color: var(--dash-text-muted);
    font-size: 0.78rem;
}

#heroSubStatus:not(.is-empty) {
    color: #34d399;
}

#heroSubStatus.is-empty {
    color: #fbbf24;
}

.player-avatar-shell {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    margin-top: -6px;
}

.player-avatar-ring {
    width: 112px;
    aspect-ratio: 1;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background:
        linear-gradient(#0a1020, #0a1020) padding-box,
        conic-gradient(from 145deg, #00d4ff, #10b981, #f59e0b, #a855f7, #00d4ff) border-box;
    border: 4px solid transparent;
    box-shadow: 0 18px 42px rgba(0, 0, 0, 0.35), 0 0 0 8px rgba(255, 255, 255, 0.035);
}

.player-avatar-ring span {
    font-family: 'Outfit', 'Tajawal', sans-serif;
    font-size: 2.6rem;
    font-weight: 950;
    color: #ffffff;
}

.player-live-pill {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 12px;
    border-radius: 999px;
    border: 1px solid rgba(16, 185, 129, 0.28);
    background: rgba(16, 185, 129, 0.1);
    color: #a7f3d0;
    font-size: 0.78rem;
    font-weight: 900;
}

.gamer-card {
    align-items: stretch !important;
    padding: clamp(24px, 3vw, 38px) !important;
    background:
        linear-gradient(180deg, rgba(12, 19, 39, 0.94), rgba(7, 11, 23, 0.9)) !important;
}

.profile-meta-text,
.player-xp-progress {
    align-self: center;
    width: min(100%, 760px);
}

.gamer-info-row,
.gamer-stats-row,
.inventory-summary-strip {
    width: 100%;
}

.gamer-stat-box,
.gamer-badge-box,
.loot-slot-item,
.subscription-card,
.stream-connect-card {
    background: rgba(255, 255, 255, 0.052) !important;
    border-color: rgba(255, 255, 255, 0.095) !important;
}

.gamer-stat-box:hover,
.loot-slot-item:hover,
.subscription-card:hover,
.stream-connect-card:hover {
    border-color: rgba(0, 212, 255, 0.36) !important;
}

.section-helper-card,
.inventory-summary-strip,
.settings-top-card {
    margin-bottom: 18px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.045);
    border-radius: 16px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.055);
}

.section-helper-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 18px;
    color: var(--dash-text);
}

.section-helper-card>i {
    width: 42px;
    aspect-ratio: 1;
    border-radius: 12px;
    display: grid;
    place-items: center;
    background: rgba(245, 158, 11, 0.12);
    color: #fbbf24;
    font-size: 1.15rem;
}

.section-helper-card strong,
.settings-top-card h4 {
    display: block;
    color: var(--dash-text);
    margin: 0 0 4px;
    font-weight: 900;
}

.section-helper-card span,
.settings-top-card p {
    color: var(--dash-text-muted);
    font-size: 0.88rem;
    line-height: 1.6;
}

.inventory-summary-strip {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1px;
    overflow: hidden;
}

.inventory-summary-strip div {
    padding: 18px;
    background: rgba(255, 255, 255, 0.025);
}

.inventory-summary-strip span {
    display: block;
    color: var(--dash-text-muted);
    font-size: 0.82rem;
    font-weight: 850;
    margin-bottom: 6px;
}

.inventory-summary-strip strong {
    color: var(--dash-text);
    font-family: 'Outfit', 'Tajawal', sans-serif;
    font-size: 1.55rem;
}

.inventory-subtabs {
    background: rgba(0, 0, 0, 0.14);
    padding: 7px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
}

.inv-subtab-btn {
    border-radius: 10px !important;
}

.loot-slots-grid {
    gap: 16px !important;
}

.loot-empty-state,
.sub-empty-state,
.sub-loading-state {
    min-height: 260px;
    border: 1px dashed rgba(255, 255, 255, 0.13);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.03);
}

.subscriptions-grid {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)) !important;
}

.subscription-card {
    border-radius: 18px !important;
    padding: 22px !important;
}

.sub-header {
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.075);
}

.sub-status-badge {
    min-height: 28px;
}

.settings-form-wrapper {
    padding: clamp(20px, 3vw, 34px) !important;
}

.settings-top-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 24px 28px !important;
}

.settings-top-card .dashboard-kicker {
    margin-bottom: 12px;
}

.settings-top-card h4 {
    font-size: 1.25rem !important;
    margin: 8px 0 6px !important;
}

.settings-top-card p {
    margin-top: 4px !important;
    line-height: 1.6;
}

.settings-top-card>i {
    color: #34d399;
    font-size: 1.9rem;
}

.stream-connect-grid {
    gap: 14px !important;
}

.stream-connect-card {
    padding: 18px 20px !important;
    border-radius: 16px !important;
}

.stream-card-info h4 {
    margin: 0 0 5px !important;
}

.password-change-box {
    border-radius: 16px !important;
}

[data-theme="light"] .dashboard-hero-panel {
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(246, 249, 253, 0.92)),
        linear-gradient(90deg, rgba(2, 132, 199, 0.11), rgba(217, 119, 6, 0.08));
    border-color: rgba(15, 23, 42, 0.08);
    box-shadow: 0 20px 55px rgba(15, 23, 42, 0.08);
}

[data-theme="light"] .hero-stat-card,
[data-theme="light"] .section-helper-card,
[data-theme="light"] .inventory-summary-strip,
[data-theme="light"] .settings-top-card,
[data-theme="light"] .gamer-stat-box,
[data-theme="light"] .gamer-badge-box,
[data-theme="light"] .loot-slot-item,
[data-theme="light"] .subscription-card,
[data-theme="light"] .stream-connect-card {
    background: rgba(255, 255, 255, 0.72) !important;
    border-color: rgba(15, 23, 42, 0.08) !important;
}

[data-theme="light"] .player-avatar-ring {
    background:
        linear-gradient(#ffffff, #ffffff) padding-box,
        conic-gradient(from 145deg, #0284c7, #059669, #d97706, #7c3aed, #0284c7) border-box;
}

[data-theme="light"] .player-avatar-ring span {
    color: #0f172a;
}

@media (max-width: 1100px) {
    .dashboard-hero-panel {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .dashboard-main-content {
        padding: 20px 14px 106px !important;
    }

    .dashboard-hero-panel {
        border-radius: 18px;
        padding: 20px;
        margin-bottom: 22px;
    }

    .dashboard-hero-copy h1 {
        font-size: 2rem;
    }

    .dashboard-hero-stats {
        grid-template-columns: 1fr;
    }

    .inventory-summary-strip {
        grid-template-columns: repeat(3, 1fr) !important;
    }

    .inventory-summary-strip div {
        padding: 12px 6px !important;
        text-align: center;
    }

    .inventory-summary-strip strong {
        font-size: 1.25rem !important;
    }

    .hero-stat-identity {
        grid-column: auto;
    }

    .dashboard-jump-btn {
        flex: 1 1 calc(50% - 8px);
        min-width: 130px;
        padding-inline: 10px;
    }

    .player-avatar-ring {
        width: 92px;
    }

    .player-avatar-ring span {
        font-size: 2.15rem;
    }

    .section-helper-card,
    .settings-top-card {
        align-items: flex-start;
    }

    .settings-top-card>i {
        display: none;
    }

    .subscriptions-grid {
        grid-template-columns: 1fr !important;
    }
}

/* =========================================================
   Player Dashboard Polish Pass - compact profile, cleaner shell
   ========================================================= */
body.dashboard-body {
    background-color: #070b16 !important;
    background-image:
        linear-gradient(180deg, rgba(8, 13, 28, 0.92), rgba(6, 10, 20, 0.98)),
        radial-gradient(900px 420px at 82% 6%, rgba(0, 212, 255, 0.13), transparent 62%),
        radial-gradient(760px 380px at 12% 88%, rgba(16, 185, 129, 0.09), transparent 60%),
        linear-gradient(rgba(255, 255, 255, 0.018) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.014) 1px, transparent 1px) !important;
    background-size: auto, auto, auto, 44px 44px, 44px 44px !important;
}

.dashboard-grid-container::before {
    background:
        linear-gradient(90deg, rgba(0, 212, 255, 0.08), transparent 18%, rgba(245, 158, 11, 0.035) 58%, transparent),
        linear-gradient(180deg, rgba(255, 255, 255, 0.035), transparent 28%) !important;
}

.dashboard-main-content {
    padding-top: 30px !important;
}

.dashboard-hero-panel,
.player-avatar-shell,
.player-avatar-ring,
.player-live-pill {
    display: none !important;
}

.profile-card-heading {
    width: 100%;
    margin-bottom: 2px;
    padding: 4px 2px 8px;
    text-align: right;
}

.profile-card-heading h2 {
    margin: 10px 0 6px;
    color: var(--dash-text);
    font-size: clamp(1.35rem, 2.6vw, 2.1rem);
    line-height: 1.25;
    letter-spacing: 0;
    font-weight: 950;
}

.profile-card-heading p {
    max-width: 680px;
    margin: 0;
    color: var(--dash-text-muted);
    font-size: 0.95rem;
    line-height: 1.75;
}

.gamer-card {
    display: flex !important;
    flex-direction: column !important;
    gap: 24px !important;
    align-items: stretch !important;
    padding: 32px !important;
    border-radius: 20px !important;
    background:
        linear-gradient(135deg, rgba(13, 20, 38, 0.94), rgba(8, 13, 27, 0.86)),
        linear-gradient(90deg, rgba(0, 212, 255, 0.1), rgba(16, 185, 129, 0.055)) !important;
    border: 1px solid rgba(255, 255, 255, 0.105) !important;
    box-shadow: 0 18px 58px rgba(0, 0, 0, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.07) !important;
    max-width: 800px !important;
    margin: 0 auto 30px !important;
}

.profile-card-heading {
    width: 100% !important;
    margin-bottom: 4px !important;
    text-align: right !important;
}

.profile-meta-text {
    width: 100% !important;
    padding: 24px !important;
    border: 1px solid rgba(0, 212, 255, 0.16);
    border-radius: 16px;
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.09), rgba(255, 255, 255, 0.035));
    text-align: center !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
}

.playerName-container {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    width: auto !important;
    margin: 0 auto !important;
}

#playerName.gamer-title {
    font-size: clamp(1.7rem, 3.2vw, 2.5rem) !important;
    line-height: 1.2 !important;
    text-align: center !important;
    letter-spacing: 0.5px !important;
    width: auto !important;
    display: inline-block !important;
}

.email-label {
    display: block;
    margin-top: 6px;
    text-align: center !important;
    overflow-wrap: anywhere;
}

.gamer-info-row {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 20px !important;
    width: 100% !important;
}

.gamer-separator {
    display: none !important;
}

.gamer-badge-box,
.gamer-stat-box,
.subscription-card,
.stream-connect-card,
.loot-slot-item,
.section-helper-card,
.inventory-summary-strip,
.settings-top-card {
    border-radius: 14px !important;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.052) !important;
    border: 1px solid rgba(255, 255, 255, 0.105) !important;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.055) !important;
}

.gamer-badge-box {
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    align-items: center !important;
    width: 100% !important;
    padding: 16px !important;
    min-height: 100px !important;
    height: auto !important;
    text-align: center !important;
}

.gamer-badge-title {
    color: var(--dash-text-muted) !important;
    font-size: 0.8rem !important;
    margin-bottom: 8px !important;
    font-weight: 800 !important;
    text-transform: uppercase;
}

.qid-box-small,
.level-badge-value,
.xp-badge-value {
    justify-content: center !important;
    align-items: center !important;
    width: fit-content !important;
    margin: 0 auto !important;
    padding: 6px 14px !important;
    font-size: 1rem !important;
}

.player-xp-progress {
    width: 100% !important;
    padding: 24px !important;
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.105);
    background: rgba(255, 255, 255, 0.048);
}

.gamer-stats-row {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 20px !important;
    width: 100% !important;
}

.gamer-stat-box {
    min-height: 120px !important;
    height: auto !important;
    max-width: none !important;
    /* Reset old max-width to let items fill the width and align perfectly in the center */
    padding: 18px 10px !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
}

.gamer-stat-val {
    font-family: 'Outfit', 'Tajawal', sans-serif;
    letter-spacing: 0 !important;
}

.tab-section-title {
    margin-bottom: 20px !important;
}

.inventory-summary-strip {
    border-radius: 14px !important;
    margin-bottom: 16px !important;
}

.inventory-summary-strip div {
    background: transparent !important;
}

.inventory-subtabs {
    border-radius: 14px !important;
    background: rgba(255, 255, 255, 0.045) !important;
}

.loot-empty-state,
.sub-empty-state,
.sub-loading-state {
    border-radius: 16px !important;
}

[data-theme="light"] body.dashboard-body {
    background-color: #f5f8fc !important;
    background-image:
        linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(243, 247, 252, 0.96)),
        radial-gradient(900px 420px at 82% 6%, rgba(2, 132, 199, 0.13), transparent 62%),
        radial-gradient(760px 380px at 12% 88%, rgba(5, 150, 105, 0.1), transparent 60%),
        linear-gradient(rgba(15, 23, 42, 0.035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(15, 23, 42, 0.025) 1px, transparent 1px) !important;
}

[data-theme="light"] .gamer-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(248, 251, 255, 0.9)) !important;
    border-color: rgba(15, 23, 42, 0.09) !important;
    box-shadow: 0 18px 48px rgba(15, 23, 42, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.7) !important;
}

[data-theme="light"] .profile-meta-text,
[data-theme="light"] .player-xp-progress,
[data-theme="light"] .gamer-badge-box,
[data-theme="light"] .gamer-stat-box,
[data-theme="light"] .subscription-card,
[data-theme="light"] .stream-connect-card,
[data-theme="light"] .loot-slot-item,
[data-theme="light"] .section-helper-card,
[data-theme="light"] .inventory-summary-strip,
[data-theme="light"] .settings-top-card {
    background: rgba(255, 255, 255, 0.78) !important;
    border-color: rgba(15, 23, 42, 0.08) !important;
}

@media (max-width: 1100px) {
    /* No flex layout override needed as it is already vertical */
}

@media (max-width: 768px) {

    .profile-card-heading,
    .profile-meta-text {
        text-align: center;
    }

    .profile-meta-text {
        padding: 16px !important;
    }

    .playerName-container {
        justify-content: center !important;
    }

    #playerName.gamer-title,
    .email-label {
        text-align: center !important;
    }

    .gamer-info-row {
        grid-template-columns: 1fr 1fr !important;
        gap: 12px !important;
    }

    .gamer-badge-box:first-child {
        grid-column: span 2 !important;
    }

    .gamer-badge-box {
        padding: 12px 14px !important;
        min-height: auto !important;
        align-items: center !important;
        text-align: center !important;
    }

    .gamer-badge-title {
        margin-bottom: 4px !important;
    }

    .qid-box-small,
    .level-badge-value,
    .xp-badge-value {
        justify-content: center !important;
        font-size: 0.95rem !important;
    }

    .gamer-stats-row {
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 8px !important;
    }

    .gamer-stat-box {
        min-height: 82px !important;
        padding: 12px 6px !important;
    }

    .gamer-stat-val {
        font-size: 1.25rem !important;
    }

    .gamer-stat-lbl {
        font-size: 0.7rem !important;
    }
}

/* =========================================================
   SWEETALERT2 CUSTOM STYLE Overrides (Premium Dark/Light)
   ========================================================= */
.swal2-container {
    z-index: 999999 !important;
    /* ضمان الظهور فوق جميع النوافذ المنبثقة */
    backdrop-filter: blur(8px) !important;
    -webkit-backdrop-filter: blur(8px) !important;
}

/* تخصيص مظهر نافذة التنبيه الفاخرة */
.swal-premium-popup {
    border-radius: 20px !important;
    border: 1px solid var(--dash-card-border) !important;
    box-shadow: var(--dash-card-shadow) !important;
    padding: 2.5rem 1.5rem !important;
    font-family: 'Tajawal', sans-serif !important;
}

.swal-premium-popup .swal2-input {
    font-family: 'Tajawal', sans-serif !important;
    text-align: center !important;
    direction: ltr !important;
    letter-spacing: 1.5px !important;
    font-size: 1.25rem !important;
    font-weight: 800 !important;
}

.swal-premium-popup .swal2-input::placeholder {
    color: rgba(255, 255, 255, 0.22) !important;
}

.swal-premium-popup .swal2-input::-webkit-input-placeholder {
    color: rgba(255, 255, 255, 0.22) !important;
}

.swal-premium-popup .swal2-input::-moz-placeholder {
    color: rgba(255, 255, 255, 0.22) !important;
}

.swal-premium-popup .swal2-input:-ms-input-placeholder {
    color: rgba(255, 255, 255, 0.22) !important;
}

.swal-premium-popup .swal2-validation-message {
    background: rgba(239, 68, 68, 0.08) !important;
    border: 1px solid rgba(239, 68, 68, 0.2) !important;
    color: #ef4444 !important;
    border-radius: 12px !important;
    padding: 10px 15px !important;
    font-family: 'Tajawal', sans-serif !important;
    font-size: 0.85rem !important;
    font-weight: 700 !important;
    margin-top: 15px !important;
}

/* في وضع الدارك ثيم */
[data-theme="dark"] .swal-premium-popup {
    background: rgba(12, 18, 38, 0.95) !important;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
}

/* في وضع اللايت ثيم */
[data-theme="light"] .swal-premium-popup {
    background: rgba(255, 255, 255, 0.98) !important;
    border: 1px solid rgba(0, 151, 181, 0.25) !important;
}

/* تخصيص عنوان التنبيه */
.swal-premium-title {
    font-size: 1.45rem !important;
    font-weight: 800 !important;
    color: var(--dash-text-primary) !important;
    margin-bottom: 0.8rem !important;
}

/* تخصيص نص التنبيه */
.swal-premium-text {
    font-size: 0.95rem !important;
    line-height: 1.6 !important;
    color: var(--dash-text-muted) !important;
    font-weight: 700 !important;
}

/* تخصيص الأزرار */
.swal2-actions {
    gap: 12px !important;
    margin-top: 1.8rem !important;
}

.swal2-styled.swal2-confirm {
    border-radius: 10px !important;
    font-weight: 800 !important;
    font-size: 0.95rem !important;
    padding: 10px 24px !important;
    box-shadow: 0 4px 15px rgba(255, 0, 85, 0.3) !important;
    transition: all 0.2s ease !important;
}

.swal2-styled.swal2-confirm:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 20px rgba(255, 0, 85, 0.45) !important;
}

.swal2-styled.swal2-cancel {
    border-radius: 10px !important;
    font-weight: 800 !important;
    font-size: 0.95rem !important;
    padding: 10px 24px !important;
    transition: all 0.2s ease !important;
}

.swal2-styled.swal2-cancel:hover {
    transform: translateY(-2px) !important;
}

/* Unified inventory-modal actions: primary, gift, and dismiss buttons share
   one visual system instead of SweetAlert's default mixed colors. */
.swal2-actions {
    width: min(100%, 430px) !important;
    justify-content: center !important;
    gap: 10px !important;
}

.swal2-styled.swal2-confirm,
.swal2-styled.swal2-deny,
.swal2-styled.swal2-cancel {
    min-width: 126px !important;
    min-height: 44px !important;
    margin: 0 !important;
    border-radius: 12px !important;
    border: 1px solid transparent !important;
    font-family: 'Tajawal', sans-serif !important;
    font-size: 0.88rem !important;
    font-weight: 800 !important;
    letter-spacing: 0 !important;
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease !important;
}

.swal2-styled.swal2-confirm {
    background: linear-gradient(135deg, #00c8ed 0%, #0578df 100%) !important;
    color: #f8fdff !important;
    box-shadow: 0 7px 18px rgba(0, 171, 229, 0.26) !important;
}

.swal2-styled.swal2-deny {
    background: linear-gradient(135deg, #a855f7 0%, #6d28d9 100%) !important;
    color: #fcfaff !important;
    box-shadow: 0 7px 18px rgba(126, 62, 215, 0.24) !important;
}

.swal2-styled.swal2-cancel {
    background: rgba(100, 116, 139, 0.18) !important;
    border-color: rgba(148, 163, 184, 0.38) !important;
    color: #dbeafe !important;
    box-shadow: none !important;
}

.swal2-styled.swal2-confirm:hover,
.swal2-styled.swal2-deny:hover,
.swal2-styled.swal2-cancel:hover {
    transform: translateY(-2px) !important;
}

.swal2-styled.swal2-confirm:hover {
    box-shadow: 0 10px 24px rgba(0, 171, 229, 0.38) !important;
}

.swal2-styled.swal2-deny:hover {
    box-shadow: 0 10px 24px rgba(126, 62, 215, 0.36) !important;
}

.swal2-styled.swal2-cancel:hover {
    border-color: rgba(191, 219, 254, 0.7) !important;
    background: rgba(100, 116, 139, 0.3) !important;
}

.swal2-styled.swal2-confirm:focus-visible,
.swal2-styled.swal2-deny:focus-visible,
.swal2-styled.swal2-cancel:focus-visible {
    outline: 3px solid rgba(0, 212, 255, 0.42) !important;
    outline-offset: 3px !important;
}

[data-theme="light"] .swal2-styled.swal2-cancel {
    background: rgba(226, 232, 240, 0.75) !important;
    border-color: rgba(100, 116, 139, 0.35) !important;
    color: #334155 !important;
}

@media (max-width: 520px) {
    .swal2-actions {
        width: 100% !important;
        gap: 8px !important;
    }

    .swal2-styled.swal2-confirm,
    .swal2-styled.swal2-deny,
    .swal2-styled.swal2-cancel {
        min-width: 0 !important;
        flex: 1 1 0 !important;
        padding: 10px 8px !important;
        font-size: 0.8rem !important;
    }
}

/* =========================================================
   INVENTORY UPGRADES & STYLES
   ========================================================= */
.inventory-section-title {
    font-size: 1rem;
    font-weight: 800;
    color: var(--dash-text-primary);
    margin-top: 25px;
    margin-bottom: 15px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    gap: 8px;
}

.verification-banner-card {
    position: relative;
    width: 400px;
    height: 100px;
    /* مقاس أكبر 25% مع الحفاظ على نسبة الأبعاد 4:1 تماماً لمنع الطعج */
    border-radius: 12px;
    overflow: hidden;
    background-size: 100% 100% !important;
    background-repeat: no-repeat !important;
    background-position: center;
    border: 1px solid rgba(0, 212, 255, 0.4);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    margin: 10px auto;
}

.verification-banner-avatar-container {
    position: absolute;
    left: 58.5px;
    /* التموضع النهائي المضبوط X */
    top: 12.5px;
    /* التموضع النهائي المضبوط Y */
    width: 71.9px;
    /* القطر النهائي المضبوط W */
    height: 71.9px;
    /* القطر النهائي المضبوط H */
    border-radius: 50%;
    overflow: hidden;
    z-index: 1;
    /* جعل الصورة بالخلفية خلف إطار اللافتة */
}

.verification-banner-avatar {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.verification-banner-frame {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: fill;
    z-index: 2;
    /* إطار اللافتة المفرغ يجلس فوق الصورة الشخصية */
    pointer-events: none;
}

.verification-banner-name {
    position: absolute;
    left: 120px;
    /* تموضع البداية لمنطقة النص */
    width: 215px;
    /* عرض منطقة النص المخصصة للاسم للتوسيط */
    top: 50%;
    transform: translateY(-50%);
    color: #fff;
    font-size: 1.55rem;
    /* تم تكبير الخط ليكون أوضح وأكبر */
    font-weight: 800;
    direction: ltr;
    text-align: center;
    /* توسيط الاسم في منتصف المستطيل الداكن */
    z-index: 3;
    /* الاسم يجلس فوق إطار اللافتة تماماً */
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8);
}

.banner-equipped-badge {
    font-size: 0.8rem;
    font-weight: 800;
    color: var(--neon-green);
    margin-top: 6px;
    display: block;
    text-align: center;
}

/* تنسيق خاص للافتات من الخارج في شبكة الحقيبة لتظهر عريضة وواضحة جداً وغير مضغوطة */
.loot-slot-banner-wide {
    grid-column: span 2 !important;
    /* تمديدها لتأخذ عمودين بالشبكة */
    width: 240px !important;
    /* عرض مخصص وعريض للافتة لتظهر بوضوح */
    min-height: unset !important;
    height: auto !important;
    align-self: start !important; /* تمنع تمدد الارتفاع ليطابق العناصر المجاورة بالشبكة */
    padding: 10px !important;
    background: rgba(255, 255, 255, 0.02) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    border-radius: 12px;
    display: flex !important;
    flex-direction: column !important;
    justify-content: flex-start !important;
    align-items: center !important;
    gap: 6px !important;
    cursor: pointer;
    transition: all 0.3s ease;
}

.loot-slot-banner-wide:hover {
    border-color: var(--neon-cyan) !important;
    box-shadow: 0 0 15px rgba(0, 212, 255, 0.15) !important;
    transform: translateY(-2px);
}

/* متجاوب تماماً للهواتف المحمولة */
@media (max-width: 480px) {
    .verification-banner-card {
        width: 300px;
        height: 75px;
        /* الحفاظ على نسبة العرض للارتفاع 400:100 */
    }

    .verification-banner-avatar-container {
        left: 43.9px;
        top: 9.4px;
        width: 53.9px;
        height: 53.9px;
    }

    .verification-banner-name {
        left: 90px;
        width: 160px;
        font-size: 0.95rem;
    }

    .loot-slot-banner-wide {
        grid-column: span 1 !important;
        width: 100% !important;
        max-width: 100% !important;
        min-height: 85px !important;
        height: auto !important;
        padding: 5px !important;
    }
    .loot-slot-banner-wide > div:first-child {
        height: 42px !important;
        flex-shrink: 0 !important;
    }
}

.locked-item-placeholder {
    background: rgba(255, 255, 255, 0.02) !important;
    border: 1px dashed rgba(255, 255, 255, 0.08) !important;
    border-radius: 12px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    backdrop-filter: blur(5px);
    opacity: 0.6;
    height: 110px;
}

.locked-item-placeholder i {
    font-size: 1.5rem;
    color: rgba(255, 255, 255, 0.3);
}

.locked-item-placeholder span {
    font-size: 0.85rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.4);
}

/* ========================================== */
/*   تصميم كروت الإقصاء المخصصة باللوحة       */
/* ========================================== */
.loot-slot-banner-wide {
    grid-column: span 2;
    aspect-ratio: unset !important;
}

/* كارت الإقصاء — عمودين عرضاً وأطول ارتفاعاً لإظهار شكل الكارت */
.loot-slot-elim-card {
    grid-column: span 2 !important;
    width: 100% !important;
    height: 170px !important;
    aspect-ratio: unset !important;
    padding: 10px !important;
    background: var(--dash-card-inner-bg) !important;
    border: 1px solid var(--dash-card-inner-border) !important;
    border-radius: 14px;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    align-items: center !important;
    cursor: pointer;
    transition: all 0.3s ease;
    box-sizing: border-box !important;
}

.loot-slot-elim-card:hover {
    border-color: #ffd700 !important;
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.2) !important;
    transform: translateY(-2px);
}

.golden-elim-preview-wrapper {
    position: relative;
    width: 100%;
    max-width: 480px;
    aspect-ratio: 1024 / 598;
    margin: 15px auto;
    background-image: none;
    border-radius: 16px;
    overflow: visible;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
    transform: scale(0.85);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.golden-elim-card-frame {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../../images/Elimination/full.png');
    background-size: 100% 100% !important;
    background-repeat: no-repeat;
    background-position: center;
    z-index: 3;
    pointer-events: none;
}

.golden-elim-preview-wrapper.show {
    transform: scale(1);
    opacity: 1;
}

.golden-elim-avatar-container {
    position: absolute;
    width: 66px;
    height: 66px;
    border-radius: 50%;
    overflow: hidden;
    z-index: 2;
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.5);
    border: 3px solid #ffd700;
}

.golden-elim-avatar-container.shooter {
    left: 94px;
    top: 57px;
    width: 80px;
    height: 80px;
}

.golden-elim-avatar-container.victim {
    right: 94px;
    top: 57px;
    width: 80px;
    height: 80px;
}

.golden-elim-avatar-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.golden-elim-avatar-container.victim.die {
    animation: blowUp 1s ease-out forwards;
}

.golden-elim-skull {
    position: absolute;
    left: 178px;
    top: 67px;
    width: 60px;
    height: 60px;
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: goldSkullPulse 0.6s infinite alternate;
}

.golden-elim-skull i {
    font-size: 3rem;
    color: #ffd700;
    filter: drop-shadow(0 0 12px rgba(212, 175, 55, 0.8));
}

@keyframes goldSkullPulse {
    0% {
        transform: scale(1) rotate(0deg);
    }

    100% {
        transform: scale(1.15) rotate(15deg);
    }
}

.golden-elim-text-desc {
    position: absolute;
    bottom: 60px;
    left: 0;
    width: 100%;
    text-align: center;
    color: #ffffff;
    font-size: 0.78rem;
    font-weight: 800;
    z-index: 4;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.9);
    pointer-events: none;
}
