/* ========================================
   EasyPSN Mini App — Design System
   Premium PlayStation Gaming Aesthetic
   ======================================== */

/* CSS Variables */
:root {
    /* Colors - Deep PlayStation Palette */
    --bg-primary: #0f172a;
    --bg-secondary: #1e293b;
    --bg-tertiary: #334155;
    
    /* Deep Blue & Midnight */
    --deep-slate: #0f172a;
    --midnight-blue: #1e293b;
    --deep-blue: #1e3a8a;

    --surface-glass: rgba(255, 255, 255, 0.05);
    --surface-glass-hover: rgba(255, 255, 255, 0.08);
    --surface-glass-active: rgba(255, 255, 255, 0.12);

    --border-glass: rgba(255, 255, 255, 0.1);
    --border-glass-hover: rgba(255, 255, 255, 0.2);

    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.7);
    --text-tertiary: rgba(255, 255, 255, 0.5);
    --text-muted: rgba(255, 255, 255, 0.3);

    /* PlayStation Brand Colors */
    --ps-blue: #0070d1;
    --ps-blue-light: #00a0e9;
    --ps-purple: #9b59b6;

    /* Tier Colors - Premium PlayStation Branding */
    --tier-essential: #e5e7eb;
    --tier-essential-glow: rgba(229, 231, 235, 0.3);
    --tier-extra: #06b6d4;
    --tier-extra-glow: rgba(6, 182, 212, 0.4);
    --tier-premium: #fbbf24;
    --tier-premium-glow: rgba(251, 191, 36, 0.5);
    
    /* Tier Gradients */
    --tier-essential-gradient: linear-gradient(135deg, rgba(229, 231, 235, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);
    --tier-extra-gradient: linear-gradient(135deg, rgba(6, 182, 212, 0.2) 0%, rgba(8, 145, 178, 0.1) 100%);
    --tier-premium-gradient: linear-gradient(135deg, rgba(251, 191, 36, 0.25) 0%, rgba(217, 119, 6, 0.15) 50%, rgba(0, 0, 0, 0.3) 100%);

    /* Status Colors */
    --success: #22c55e;
    --warning: #f59e0b;
    --error: #ef4444;

    /* Gradients */
    --gradient-primary: linear-gradient(135deg, var(--ps-blue), var(--ps-purple));
    --gradient-essential: linear-gradient(135deg, #00b4d8, #00d4ff);
    --gradient-extra: linear-gradient(135deg, #f59e0b, #fbbf24);
    --gradient-premium: linear-gradient(135deg, #7c3aed, #a855f7);

    /* Spacing */
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 32px;
    --spacing-2xl: 48px;

    /* Border Radius */
    --radius-sm: 12px;
    --radius-md: 16px;
    --radius-lg: 20px;
    --radius-xl: 28px;
    --radius-full: 9999px;

    /* Shadows */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
    --shadow-glow-blue: 0 0 20px rgba(0, 112, 209, 0.4);
    --shadow-glow-purple: 0 0 20px rgba(168, 85, 247, 0.4);

    /* Typography */
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-family-accent: 'Rajdhani', sans-serif;
    --font-size-xs: 11px;
    --font-size-sm: 13px;
    --font-size-md: 15px;
    --font-size-lg: 17px;
    --font-size-xl: 20px;
    --font-size-2xl: 24px;
    --font-size-3xl: 32px;

    /* Transitions */
    --transition-fast: 150ms ease;
    --transition-normal: 250ms ease;
    --transition-slow: 400ms ease;

    /* Layout */
    --header-height: 48px;
    --nav-height: 72px;
    --safe-area-bottom: max(env(safe-area-inset-bottom, 0px), var(--tg-safe-bottom, 0px));
    --tg-safe-bottom: 0px;
    
    /* Telegram Theme Colors (will be set by JS) */
    --tg-bg-color: #0a0a0f;
    --tg-text-color: #ffffff;
    --tg-hint-color: rgba(255, 255, 255, 0.7);
    --tg-link-color: #0070d1;
    --tg-button-color: #0070d1;
    --tg-button-text-color: #ffffff;
}

/* Animations */
@keyframes logo-glow {

    0%,
    100% {
        box-shadow:
            0 6px 12px rgba(0, 0, 0, 0.5),
            0 2px 4px rgba(0, 0, 0, 0.3),
            inset 0 2px 4px rgba(255, 255, 255, 0.1),
            inset 0 -2px 4px rgba(0, 0, 0, 0.3),
            0 0 15px rgba(0, 112, 209, 0.3);
    }

    50% {
        box-shadow:
            0 6px 12px rgba(0, 0, 0, 0.5),
            0 2px 4px rgba(0, 0, 0, 0.3),
            inset 0 2px 4px rgba(255, 255, 255, 0.1),
            inset 0 -2px 4px rgba(0, 0, 0, 0.3),
            0 0 25px rgba(0, 112, 209, 0.5);
    }
}

/* Reset & Base */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
    -webkit-tap-highlight-color: transparent;
    overflow-y: scroll;
}

body {
    font-family: 'Inter', sans-serif;
    font-size: var(--font-size-md);
    line-height: 1.5;
    color: var(--text-primary);
    background: var(--deep-slate);
    min-height: 100vh;
    min-height: 100dvh; /* Dynamic viewport height for mobile browsers */
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    /* Support for safe area insets on all devices */
    padding-top: env(safe-area-inset-top, 0px);
    padding-bottom: env(safe-area-inset-bottom, 0px);
    padding-left: env(safe-area-inset-left, 0px);
    padding-right: env(safe-area-inset-right, 0px);
    -moz-osx-font-smoothing: grayscale;
    position: relative;
}

/* Premium Deep Background - Very Dark, Minimal Effects */
.aurora-bg {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: -1;
    background:
        /* Very subtle noise texture for texture (almost invisible) */
        url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.03'/%3E%3C/svg%3E"),
        /* Very subtle radial gradient - almost flat dark */
        radial-gradient(ellipse 120% 100% at 50% 50%, rgba(15, 23, 42, 1) 0%, rgba(15, 23, 42, 0.98) 60%, rgba(15, 23, 42, 0.95) 100%),
        /* Base deep slate - solid dark */
        var(--deep-slate);
    background-size: 
        200px 200px,
        100% 100%,
        100% 100%;
    /* Убрана анимация для статичного темного фона */
}

/* Aurora animation removed for darker static background */

/* App Container */
#app {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    max-width: 100%;
}

/* Header - Premium Glassmorphism */
.header {
    position: fixed;
    top: var(--tg-safe-top, 120px);
    left: 0;
    right: 0;
    width: 100%;
    height: 48px;
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    padding: 0 var(--spacing-md);
    padding-right: calc(var(--spacing-md) + 10px);
    background: transparent;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    z-index: 100;
    transition: all 0.3s ease;
    overflow: visible;
}

/* Фон только сверху до конца header */
.header::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    height: calc(var(--tg-safe-top, 120px) + 48px);
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    z-index: -1;
    pointer-events: none;
}

/* Hide header on game detail page */
body.viewing-game-detail .header {
    display: none !important;
}





.header-back {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--surface-glass);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-full);
    color: var(--text-primary);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.header-back:active {
    transform: scale(0.95);
    background: var(--surface-glass-active);
}

.header-logo {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    margin-left: var(--spacing-md);
}

.header-logo-img {
    height: 30px;
    width: auto;
    object-fit: contain;
    /* Bright cyan color to match theme */
    filter:
        brightness(0) saturate(100%) invert(70%) sepia(100%) saturate(2500%) hue-rotate(175deg) brightness(1.4) drop-shadow(0 0 6px rgba(0, 200, 255, 0.6));
}

/* Header Actions - Right Side */
.header-actions {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    overflow: visible;
    position: relative;
    padding-right: 15px;
    margin-right: -5px;
}

.header-btn {
    position: relative;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-lg);
    color: var(--text-secondary);
    cursor: pointer;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    transition: all var(--transition-fast);
    overflow: visible;
}

.header-btn:hover {
    background: rgba(15, 23, 42, 0.8);
    color: var(--text-primary);
    border-color: rgba(0, 160, 233, 0.4);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 112, 209, 0.2);
}

.header-btn:active {
    transform: scale(0.95);
    transition: transform 0.1s ease;
}

/* Micro-interactions for buttons */
.btn,
.header-btn {
    position: relative;
    overflow: hidden;
}

.nav-item {
    position: relative;
    overflow: visible;
}

.btn::before,
.header-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn:active::before,
.header-btn:active::before {
    width: 300px;
    height: 300px;
}

.header-btn.header-profile {
    background: rgba(0, 160, 233, 0.15);
    border: 1px solid rgba(0, 160, 233, 0.3);
    color: var(--ps-blue-light);
}

.header-btn.header-profile:hover {
    background: rgba(0, 160, 233, 0.25);
    border-color: var(--ps-blue-light);
    box-shadow: 0 4px 16px rgba(0, 160, 233, 0.3);
}

/* Notification Badge */
.header-btn {
    position: relative;
}

.notification-badge {
    position: absolute;
    top: 6px;
    right: 8px;
    background: none;
    color: #00a0e9;
    font-size: 14px;
    font-weight: 700;
    padding: 0;
    border-radius: 0;
    min-width: auto;
    height: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: none;
    z-index: 10000;
    line-height: 1;
    font-family: var(--font-family-accent);
    white-space: nowrap;
    pointer-events: none;
    text-shadow: 
        0 0 10px rgba(0, 160, 233, 1),
        0 0 20px rgba(0, 160, 233, 0.6),
        0 2px 4px rgba(0, 0, 0, 0.8);
    transform: translate(20%, -20%);
}

@keyframes pulse-badge {
    0%, 100% {
        transform: scale(1);
        background: #ef4444;
        box-shadow: 
            0 0 0 3px var(--deep-slate),
            0 2px 10px rgba(239, 68, 68, 0.9),
            0 0 20px rgba(239, 68, 68, 0.7);
    }
    50% {
        transform: scale(1.15);
        background: #ff3333;
        box-shadow: 
            0 0 0 3px var(--deep-slate),
            0 4px 16px rgba(239, 68, 68, 1),
            0 0 32px rgba(255, 51, 51, 0.9),
            0 0 48px rgba(255, 51, 51, 0.6);
    }
}


/* Inline Header Search */
.header-search-wrapper {
    width: 0;
    overflow: hidden;
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
}

.header-search-wrapper.active {
    width: 160px;
    margin-right: var(--spacing-sm);
}

.header-search-input {
    width: 160px;
    min-width: 160px;
    height: 36px;
    padding: 0 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 50px;
    color: var(--text-primary);
    font-size: 13px;
    font-family: inherit;
    outline: none;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    transition: all var(--transition-fast);
    opacity: 0;
    pointer-events: none;
}

.header-search-wrapper.active .header-search-input {
    opacity: 1;
    pointer-events: auto;
}

.header-search-input::placeholder {
    color: var(--text-tertiary);
    font-size: 13px;
}

.header-search-input:focus {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--ps-blue);
}

/* Main Content */
.main-content {
    flex: 1;
    padding-top: calc(var(--header-height) + var(--tg-safe-top, 120px) + var(--spacing-md));
    padding-left: var(--spacing-md);
    padding-right: var(--spacing-md);
    padding-bottom: calc(var(--nav-height) + var(--safe-area-bottom) + 12px + var(--spacing-md));
    overflow-y: auto;
    overflow-x: hidden;
}

/* Screen Containers */
.screen {
    display: none;
    animation: fadeIn var(--transition-normal) ease;
}

.screen.active {
    display: block;
}

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

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

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-md) var(--spacing-xl);
    border: none;
    border-radius: var(--radius-lg);
    font-size: var(--font-size-md);
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-fast);
    text-decoration: none;
    white-space: nowrap;
}

.btn-lg {
    padding: var(--spacing-lg) var(--spacing-2xl);
    font-size: var(--font-size-lg);
    width: 100%;
}

.btn-primary {
    background: linear-gradient(135deg, var(--ps-blue), #0070d1);
    color: white;
    box-shadow: 0 4px 16px rgba(0, 112, 209, 0.3);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #0070d1, var(--ps-blue));
    box-shadow: 0 6px 24px rgba(0, 112, 209, 0.5);
    transform: translateY(-2px);
}

.btn-primary:active {
    transform: translateY(0);
}

/* Copy Button - Clean icon button without background */
.copy-btn {
    padding: var(--spacing-sm) !important;
    min-width: 36px !important;
    width: 36px !important;
    height: 36px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: transparent !important;
    border: none !important;
    border-radius: 0 !important;
    color: #4A90E2 !important;
    flex-shrink: 0;
    cursor: pointer !important;
    transition: transform 0.15s ease !important;
    outline: none !important;
}

.copy-btn:hover {
    background: transparent !important;
    border: none !important;
    transform: scale(1.1);
}

.copy-btn:active {
    transform: scale(0.9);
}

.copy-btn svg {
    display: block !important;
    flex-shrink: 0 !important;
    pointer-events: none !important;
    width: 18px !important;
    height: 18px !important;
    stroke: #4A90E2 !important;
    color: #4A90E2 !important;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(20px);
    }

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

/* Bottom Navigation - Premium Glassmorphism */
.bottom-nav {
    position: fixed;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 24px);
    max-width: calc(100vw - 24px);
    height: 64px;
    padding: 0 var(--spacing-md);
    margin-bottom: 0;
    display: flex;
    align-items: center;
    justify-content: space-around;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-xl);
    box-shadow: 
        0 -2px 8px rgba(0, 0, 0, 0.3),
        0 0 1px rgba(255, 255, 255, 0.05) inset;
    z-index: 100;
    transition: all 0.3s ease;
}

.nav-item {
    flex: 1 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: var(--spacing-sm) var(--spacing-md);
    background: transparent !important;
    background-color: transparent !important;
    border: none !important;
    border-radius: 0 !important;
    color: var(--text-tertiary);
    font-size: 10px;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition-normal);
    position: relative;
    box-shadow: none !important;
    outline: none !important;
    -webkit-tap-highlight-color: transparent !important;
}

.nav-item .nav-icon {
    width: 22px;
    height: 22px;
    transition: all var(--transition-normal);
}

.nav-item.active {
    color: var(--text-primary);
    text-shadow: 0 0 8px rgba(0, 112, 209, 0.5);
    background: transparent !important;
    background-color: transparent !important;
    box-shadow: none !important;
    border: none !important;
    border-radius: 0 !important;
}

.nav-item.active .nav-icon {
    transform: scale(1.15);
    filter: drop-shadow(0 0 6px rgba(0, 160, 233, 0.6));
}

.nav-item.active .nav-icon path,
.nav-item.active .nav-icon rect,
.nav-item.active .nav-icon circle {
    stroke: var(--ps-blue-light);
}

/* Active indicator dot - removed */
.nav-item.active::after {
    display: none;
}

.nav-item::before {
    display: none !important;
    content: none !important;
}

.nav-item:hover {
    background: transparent !important;
    background-color: transparent !important;
    box-shadow: none !important;
    border: none !important;
    border-radius: 0 !important;
}

.nav-item:focus {
    background: transparent !important;
    background-color: transparent !important;
    box-shadow: none !important;
    border: none !important;
    border-radius: 0 !important;
    outline: none !important;
}

@keyframes pulse-dot {

    0%,
    100% {
        transform: translateX(-50%) scale(1);
        opacity: 1;
    }

    50% {
        transform: translateX(-50%) scale(1.2);
        opacity: 0.8;
    }
}

.nav-item:active {
    transform: scale(0.9);
    background: transparent !important;
    background-color: transparent !important;
    box-shadow: none !important;
    border: none !important;
    border-radius: 0 !important;
}

/* Center Logo Button - Premium PlayStation Style */
.nav-logo-btn {
    position: relative;
    flex-shrink: 0;
    width: 56px;
    min-width: 56px;
    max-width: 56px;
    height: 56px;
    margin-top: 0;
    background: linear-gradient(135deg, rgba(45, 45, 60, 0.98) 0%, rgba(25, 25, 35, 1) 50%, rgba(15, 15, 25, 1) 100%);
    border: 1px solid rgba(0, 112, 209, 0.3);
    border-radius: 50%;
    cursor: default;
    pointer-events: none;
    transition: box-shadow 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow:
        0 6px 12px rgba(0, 0, 0, 0.5),
        0 2px 4px rgba(0, 0, 0, 0.3),
        inset 0 2px 4px rgba(255, 255, 255, 0.1),
        inset 0 -2px 4px rgba(0, 0, 0, 0.3);
    animation: logo-glow 3s ease-in-out infinite;
    z-index: 10;
}

.nav-logo-btn::before {
    content: '';
    position: absolute;
    inset: -2px;
    background: transparent;
    border-radius: 50%;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.nav-logo-btn:hover {
    box-shadow:
        0 8px 16px rgba(0, 0, 0, 0.6),
        0 3px 6px rgba(0, 0, 0, 0.4),
        inset 0 2px 4px rgba(255, 255, 255, 0.12),
        inset 0 -2px 4px rgba(0, 0, 0, 0.35);
}

.nav-logo-btn:hover::before {
    opacity: 0;
}

.nav-logo-btn:active {
    transform: scale(0.98);
    box-shadow:
        0 2px 6px rgba(0, 0, 0, 0.4),
        inset 0 2px 6px rgba(0, 0, 0, 0.4),
        inset 0 -1px 2px rgba(255, 255, 255, 0.05);
}

.nav-logo-inner {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    overflow: hidden;
}

.nav-logo-img {
    width: 32px;
    height: 32px;
    object-fit: contain;
    filter:
        brightness(0) saturate(100%) invert(70%) sepia(100%) saturate(2500%) hue-rotate(175deg) brightness(1.4) drop-shadow(0 0 8px rgba(0, 200, 255, 0.6));
}

.nav-logo-fallback {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--ps-blue-light);
}

.nav-logo-fallback svg {
    width: 32px;
    height: 32px;
    filter: drop-shadow(0 0 8px rgba(0, 200, 255, 0.6));
}

/* Toast position adjustment for floating nav */
.toast-container {
    position: fixed;
    bottom: calc(100px + var(--safe-area-bottom));
    left: var(--spacing-md);
    right: var(--spacing-md);
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
    z-index: 1001;
    pointer-events: none;
}

/* Glass Card - Enhanced Glassmorphism */
.glass-card {
    background: rgba(15, 23, 42, 0.5);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-lg);
    padding: var(--spacing-md);
    transition: all var(--transition-normal);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.glass-card:hover {
    background: rgba(15, 23, 42, 0.7);
    border-color: rgba(0, 112, 209, 0.4);
    box-shadow: 
        0 4px 16px rgba(0, 0, 0, 0.3),
        0 0 20px rgba(0, 112, 209, 0.3),
        0 0 1px rgba(255, 255, 255, 0.1) inset;
    transform: translateY(-4px) scale(1.02);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-md) var(--spacing-lg);
    font-family: inherit;
    font-size: var(--font-size-md);
    font-weight: 600;
    color: var(--text-primary);
    background: var(--surface-glass);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: all var(--transition-fast);
    -webkit-tap-highlight-color: transparent;
}

.btn:active {
    transform: scale(0.98);
}

.btn-primary {
    font-family: var(--font-family-accent);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    background: var(--gradient-primary);
    border: none;
    box-shadow: var(--shadow-glow-blue);
}

.btn-primary:active {
    box-shadow: none;
}

.btn-lg {
    width: 100%;
    padding: var(--spacing-lg);
    font-size: var(--font-size-lg);
    border-radius: var(--radius-xl);
}

/* Tier Cards */
/* Subscriptions Carousel */
.subs-carousel {
    position: relative;
    width: 100%;
    overflow: hidden;
    padding: var(--spacing-sm) var(--spacing-md);
    margin: 0 calc(-1 * var(--spacing-md));
}

.subs-carousel-track {
    display: flex;
    transition: transform 0.5s ease;
    gap: var(--spacing-md);
    padding: var(--spacing-sm) 0;
}

.tier-card {
    min-width: calc(100% - var(--spacing-md));
    width: calc(100% - var(--spacing-md));
    flex-shrink: 0;
    box-sizing: border-box;
    position: relative;
    padding: var(--spacing-lg);
    border-radius: var(--radius-xl);
    overflow: hidden;
    transition: all var(--transition-normal);
    margin: 0 var(--spacing-sm);
    will-change: transform;
    /* Ensure rounded corners are visible */
    clip-path: none;
}

.tier-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: inherit;
    opacity: 0.1;
    z-index: -1;
}

/* Tier Cards - Premium Color Coding */
.tier-card.essential {
    background: var(--tier-essential-gradient);
    border: 1px solid rgba(229, 231, 235, 0.2);
    position: relative;
}

.tier-card.essential::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: var(--radius-xl);
    padding: 1px;
    background: linear-gradient(135deg, rgba(229, 231, 235, 0.4), transparent);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.tier-card.essential:hover {
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.4),
        0 0 40px var(--tier-essential-glow);
    border-color: rgba(229, 231, 235, 0.5);
    transform: translateY(-4px) scale(1.02);
}

.tier-card.essential:hover::after {
    opacity: 1;
    border: 1px solid rgba(229, 231, 235, 0.6);
}

.tier-card.extra {
    background: var(--tier-extra-gradient);
    border: 1px solid rgba(6, 182, 212, 0.3);
    position: relative;
}

.tier-card.extra::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: var(--radius-xl);
    padding: 1px;
    background: linear-gradient(135deg, rgba(6, 182, 212, 0.6), rgba(8, 145, 178, 0.4));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.tier-card.extra:hover {
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.4),
        0 0 50px var(--tier-extra-glow);
    border-color: rgba(6, 182, 212, 0.6);
    transform: translateY(-4px) scale(1.02);
}

.tier-card.extra:hover::after {
    opacity: 1;
    border: 1px solid rgba(6, 182, 212, 0.7);
}

.tier-card.premium {
    background: var(--tier-premium-gradient);
    border: 1px solid rgba(251, 191, 36, 0.3);
    position: relative;
}

.tier-card.premium::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: var(--radius-xl);
    padding: 1px;
    background: linear-gradient(135deg, rgba(251, 191, 36, 0.8), rgba(217, 119, 6, 0.6), rgba(0, 0, 0, 0.4));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.tier-card.premium:hover {
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.5),
        0 0 60px var(--tier-premium-glow),
        inset 0 0 20px rgba(251, 191, 36, 0.1);
    border-color: rgba(251, 191, 36, 0.7);
    transform: translateY(-4px) scale(1.02);
}

.tier-card.premium:hover::after {
    opacity: 1;
    border: 1px solid rgba(251, 191, 36, 0.8);
}

.tier-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    font-size: var(--font-size-xs);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: var(--radius-full);
}

.tier-badge.popular {
    background: linear-gradient(135deg, var(--tier-extra), #f59e0b);
    color: #000;
}

/* Custom Banner */
.custom-banner {
    position: relative;
    height: 200px;
    border-radius: var(--radius-xl);
    overflow: hidden;
    cursor: pointer;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    transition: transform 0.3s;
}

.custom-banner:hover {
    transform: scale(1.02);
}

.custom-banner-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.5) 50%, rgba(0, 0, 0, 0.3) 100%);
    display: flex;
    align-items: center;
    padding: var(--spacing-lg);
    z-index: 2;
}

.custom-banner-content {
    max-width: 60%;
}

.custom-banner-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: var(--spacing-xs);
    color: white;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.custom-banner-subtitle {
    font-size: 16px;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: var(--spacing-md);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.custom-banner-btn {
    padding: 12px 24px;
    background: var(--ps-blue);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 4px 12px rgba(13, 138, 188, 0.4);
}

.custom-banner-btn:hover {
    background: var(--ps-blue-light);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(13, 138, 188, 0.6);
}

/* Image Banners */
.image-banner {
    min-width: 280px;
    height: 160px;
    border-radius: var(--radius-xl);
    overflow: hidden;
    cursor: pointer;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid transparent;
}

.image-banner:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
    border-color: var(--ps-blue);
}

.image-banner-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.4) 50%, rgba(0, 0, 0, 0.7) 100%);
    transition: opacity 0.3s;
    z-index: 1;
    pointer-events: none;
}

.image-banner:hover .image-banner-overlay {
    opacity: 0.8;
    background: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.5) 50%, rgba(0, 0, 0, 0.85) 100%);
}

/* Banner Carousel */
.banner-carousel {
    position: relative;
    width: 100%;
    overflow: hidden;
    border-radius: var(--radius-xl);
}

.banner-carousel-track {
    display: flex;
    transition: transform 0.5s ease-in-out;
}

.carousel-banner {
    min-width: 100%;
    height: 200px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    cursor: pointer;
    flex-shrink: 0;
    position: relative;
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: 
        0 12px 40px rgba(0, 0, 0, 0.5),
        0 4px 16px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        inset 0 -1px 0 rgba(0, 0, 0, 0.2);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    transform: perspective(1000px) rotateX(2deg) translateZ(0);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.carousel-banner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg,
            rgba(13, 138, 188, 0.2) 0%,
            rgba(124, 58, 237, 0.15) 50%,
            rgba(236, 72, 153, 0.2) 100%);
    opacity: 0.7;
    pointer-events: none;
    z-index: 1;
    box-shadow: inset 0 0 60px rgba(0, 112, 209, 0.3);
}

.carousel-banner::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg,
            rgba(255, 255, 255, 0.1) 0%,
            transparent 30%,
            transparent 70%,
            rgba(0, 0, 0, 0.2) 100%);
    pointer-events: none;
    z-index: 2;
    border-radius: var(--radius-xl);
}

.carousel-banner:hover {
    transform: perspective(1000px) rotateX(0deg) translateZ(20px);
    box-shadow: 
        0 20px 60px rgba(0, 0, 0, 0.6),
        0 8px 24px rgba(0, 112, 209, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.2),
        inset 0 -1px 0 rgba(0, 0, 0, 0.3),
        0 0 40px rgba(0, 112, 209, 0.3);
    border-color: rgba(255, 255, 255, 0.2);
}

.carousel-banner:hover::before {
    opacity: 0.9;
    box-shadow: inset 0 0 80px rgba(0, 112, 209, 0.5);
}

.carousel-dots {
    position: absolute;
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 10;
}

.carousel-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(0, 112, 209, 0.4);
    cursor: pointer;
    transition: all 0.3s;
}

.carousel-dot.active {
    background: var(--ps-blue, #0070d1);
    width: 24px;
    border-radius: 4px;
    box-shadow: 0 0 8px rgba(0, 112, 209, 0.5);
}

/* Subscription Banners */
.subscription-banner {
    min-width: 320px;
    padding: var(--spacing-lg);
    border-radius: var(--radius-xl);
    background: var(--surface-glass);
    border: 1px solid var(--border-glass);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.subscription-banner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
}

.subscription-banner.essential::before {
    background: linear-gradient(135deg, rgba(13, 138, 188, 0.2), rgba(13, 138, 188, 0.05));
}

.subscription-banner.extra::before {
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.2), rgba(124, 58, 237, 0.05));
}

.subscription-banner.premium::before {
    background: linear-gradient(135deg, rgba(236, 72, 153, 0.2), rgba(236, 72, 153, 0.05));
}

.subscription-banner:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.subscription-banner:hover::before {
    opacity: 1;
}

.subscription-banner.essential:hover {
    border-color: var(--tier-essential);
}

.subscription-banner.extra:hover {
    border-color: var(--tier-extra);
}

.subscription-banner.premium:hover {
    border-color: var(--tier-premium);
}

.banner-content {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    flex: 1;
    position: relative;
    z-index: 1;
}

.banner-icon {
    font-size: 40px;
    flex-shrink: 0;
}

.banner-info {
    flex: 1;
}

.banner-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 4px;
}

.subscription-banner.essential .banner-title {
    color: var(--tier-essential);
    text-shadow: 0 0 10px var(--tier-essential-glow);
}

.subscription-banner.extra .banner-title {
    color: var(--tier-extra);
    text-shadow: 0 0 10px var(--tier-extra-glow);
}

.subscription-banner.premium .banner-title {
    color: var(--tier-premium);
    text-shadow: 0 0 15px var(--tier-premium-glow);
}

.banner-subtitle {
    font-size: 13px;
    color: var(--text-secondary);
}

.banner-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    padding: 4px 12px;
    background: var(--tier-premium);
    color: white;
    font-size: 11px;
    font-weight: 700;
    border-radius: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.banner-cta {
    color: var(--text-secondary);
    transition: all 0.3s;
    position: relative;
    z-index: 1;
}

.subscription-banner:hover .banner-cta {
    color: var(--ps-blue-light);
    transform: translateX(4px);
}

/* Game Cards / Product Cards - Premium with Tier Support */
.game-card,
.product-card {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: var(--surface-glass);
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all var(--transition-normal);
    cursor: pointer;
    animation: cardFadeIn 0.6s ease-out backwards;
    opacity: 0;
    animation-fill-mode: forwards;
}

/* Staggered Animation Delays */
.game-card:nth-child(1),
.product-card:nth-child(1) { animation-delay: 0.05s; }
.game-card:nth-child(2),
.product-card:nth-child(2) { animation-delay: 0.1s; }
.game-card:nth-child(3),
.product-card:nth-child(3) { animation-delay: 0.15s; }
.game-card:nth-child(4),
.product-card:nth-child(4) { animation-delay: 0.2s; }
.game-card:nth-child(5),
.product-card:nth-child(5) { animation-delay: 0.25s; }
.game-card:nth-child(6),
.product-card:nth-child(6) { animation-delay: 0.3s; }
.game-card:nth-child(7),
.product-card:nth-child(7) { animation-delay: 0.35s; }
.game-card:nth-child(8),
.product-card:nth-child(8) { animation-delay: 0.4s; }
.game-card:nth-child(9),
.product-card:nth-child(9) { animation-delay: 0.45s; }
.game-card:nth-child(10),
.product-card:nth-child(10) { animation-delay: 0.5s; }

/* Tier Modifiers for Product Cards */
.product-card[data-tier="essential"],
.game-card[data-tier="essential"] {
    border-color: rgba(229, 231, 235, 0.15);
}

/* Default hover effect for cards without tier */
.game-card:hover:not([data-tier]),
.product-card:hover:not([data-tier]) {
    transform: translateY(-4px) scale(1.02);
    border-color: rgba(0, 112, 209, 0.4);
    box-shadow: 
        var(--shadow-lg),
        0 0 25px rgba(0, 112, 209, 0.4);
}

/* Essential tier cards */
.product-card[data-tier="essential"]:hover,
.game-card[data-tier="essential"]:hover {
    transform: translateY(-4px) scale(1.02);
    border-color: rgba(229, 231, 235, 0.4);
    box-shadow: 
        var(--shadow-lg),
        0 0 20px var(--tier-essential-glow);
}

.product-card[data-tier="extra"],
.game-card[data-tier="extra"] {
    border-color: rgba(6, 182, 212, 0.2);
}

.product-card[data-tier="extra"]:hover,
.game-card[data-tier="extra"]:hover {
    transform: translateY(-4px) scale(1.02);
    border-color: rgba(6, 182, 212, 0.5);
    box-shadow: 
        var(--shadow-lg),
        0 0 25px var(--tier-extra-glow);
}

.product-card[data-tier="premium"],
.game-card[data-tier="premium"] {
    border-color: rgba(251, 191, 36, 0.25);
    position: relative;
}

.product-card[data-tier="premium"]::before,
.game-card[data-tier="premium"]::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: var(--radius-lg);
    padding: 1px;
    background: linear-gradient(135deg, rgba(251, 191, 36, 0.5), rgba(217, 119, 6, 0.3));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    z-index: 1;
}

.product-card[data-tier="premium"]:hover,
.game-card[data-tier="premium"]:hover {
    transform: translateY(-4px) scale(1.02);
    border-color: rgba(251, 191, 36, 0.6);
    box-shadow: 
        var(--shadow-lg),
        0 0 30px var(--tier-premium-glow),
        inset 0 0 15px rgba(251, 191, 36, 0.1);
}

.product-card[data-tier="premium"]:hover::before,
.game-card[data-tier="premium"]:hover::before {
    opacity: 1;
}

.game-card:active,
.product-card:active {
    transform: translateY(-2px) scale(0.98);
}

/* Staggered Fade In Animation */
@keyframes cardFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.game-card {
    aspect-ratio: 2/3;
    display: flex;
    flex-direction: column;
}

.game-card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    background: var(--bg-tertiary);
    border-radius: var(--radius-lg);
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1;
}

/* Dark gradient overlay for text readability */
.game-card-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 45%;
    background: linear-gradient(to top, 
        rgba(0, 0, 0, 0.95) 0%, 
        rgba(0, 0, 0, 0.85) 30%,
        rgba(0, 0, 0, 0.7) 60%,
        rgba(0, 0, 0, 0.4) 80%,
        transparent 100%);
    pointer-events: none;
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
    z-index: 2;
}

.game-card-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: var(--spacing-md);
    z-index: 3;
    color: white;
}

.game-card-title {
    font-family: var(--font-family-accent);
    font-size: var(--font-size-sm);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    margin-bottom: var(--spacing-xs);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: white;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.8);
}

.game-card-price {
    font-family: var(--font-family-accent);
    font-size: var(--font-size-md);
    color: var(--ps-blue-light);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.8);
}

.game-card-badge {
    position: absolute;
    top: var(--spacing-sm);
    left: var(--spacing-sm);
    padding: 4px 8px;
    font-size: var(--font-size-xs);
    font-weight: 600;
    background: rgba(0, 0, 0, 0.8);
    border-radius: var(--radius-sm);
    backdrop-filter: blur(10px);
    z-index: 4;
}

/* Status Indicators */
.status-dot {
    width: 8px;
    height: 8px;
    border-radius: var(--radius-full);
}

.status-dot.available {
    background: #10b981;
    box-shadow: 0 0 8px rgba(16, 185, 129, 0.6);
}

/* Reviews Carousel */
.reviews-carousel {
    position: relative;
    width: 100%;
    overflow: hidden;
}

.reviews-carousel-track {
    display: flex;
    transition: transform 0.5s ease;
    gap: 0;
}

.review-card {
    min-width: 100%;
    width: 100%;
    flex-shrink: 0;
    box-sizing: border-box;
    background: var(--surface-glass);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    padding: var(--spacing-lg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    transition: all var(--transition-normal);
    cursor: pointer;
}

.review-card:hover {
    border-color: rgba(0, 112, 209, 0.4);
    box-shadow: 
        var(--shadow-lg),
        0 0 20px rgba(0, 112, 209, 0.3);
}

/* Popular Games Carousel */
/* Top Sales Carousel (Games + Subscriptions) */
.top-sales-carousel {
    position: relative;
    width: 100%;
    max-width: 100%;
    overflow: hidden;
    padding: var(--spacing-sm) var(--spacing-md);
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.top-sales-carousel .top-sales-carousel-track {
    display: flex;
    transition: transform 0.5s ease;
    gap: 0;
    width: 100%;
    justify-content: center;
}

.top-sales-carousel .top-sales-slide {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 auto;
}

.top-sales-carousel-track {
    display: flex;
    transition: transform 0.5s ease;
    gap: 0;
    width: 100%;
    justify-content: center;
}

.top-sales-slide {
    min-width: 100%;
    width: 100%;
    flex-shrink: 0;
    box-sizing: border-box;
    padding: 0 var(--spacing-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

.popular-carousel {
    position: relative;
    width: 100%;
    overflow: hidden;
}

.popular-carousel-track {
    display: flex;
    transition: transform 0.5s ease;
    gap: 0;
}

.popular-slide {
    min-width: 100%;
    width: 100%;
    flex-shrink: 0;
    box-sizing: border-box;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-md);
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: var(--spacing-md);
}

.review-author {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.review-avatar {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-full);
    background: linear-gradient(135deg, var(--ps-blue), var(--ps-purple));
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 18px;
    color: var(--text-primary);
}

.review-author-name {
    font-weight: 600;
    font-size: 15px;
    color: var(--text-primary);
}

.review-rating {
    font-size: 12px;
    margin-top: 2px;
}

.review-game {
    font-size: 12px;
    color: var(--ps-blue-light);
    background: rgba(0, 160, 233, 0.1);
    padding: 4px 8px;
    border-radius: var(--radius-sm);
}

.review-text {
    color: var(--text-secondary);
    font-size: 14px;
    line-height: 1.6;
    margin: 0;
}

.status-dot.unavailable {
    background: var(--error);
}

/* Chips / Tags - Enhanced PlayStation Style */
.chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 20px;
    font-size: var(--font-size-sm);
    font-weight: 600;
    background: var(--surface-glass);
    border: 1.5px solid var(--border-glass);
    border-radius: var(--radius-full);
    cursor: pointer;
    transition: all var(--transition-fast);
    white-space: nowrap;
}

.chip:hover {
    border-color: rgba(0, 160, 233, 0.5);
    transform: translateY(-1px);
}

.chip.active {
    background: linear-gradient(135deg, rgba(0, 112, 209, 0.3), rgba(0, 160, 233, 0.2));
    border-color: var(--ps-blue);
    color: var(--ps-blue-light);
    box-shadow: 0 0 16px rgba(0, 112, 209, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.chip:active {
    transform: scale(0.95);
}

/* Sort Chips - Compact & Multimedia */
.sort-chip {
    padding: 6px 14px;
    font-size: 12px;
    gap: 5px;
    border-radius: var(--radius-lg);
    backdrop-filter: blur(12px);
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.sort-chip svg {
    flex-shrink: 0;
    opacity: 0.8;
    transition: all 0.3s;
}

.sort-chip span {
    font-weight: 600;
    letter-spacing: 0.3px;
}

.sort-chip:hover {
    border-color: rgba(0, 160, 233, 0.4);
    background: rgba(15, 23, 42, 0.8);
    box-shadow: 0 4px 12px rgba(0, 112, 209, 0.2);
    transform: translateY(-2px);
}

.sort-chip:hover svg {
    opacity: 1;
    transform: scale(1.1);
}

.sort-chip.active {
    background: linear-gradient(135deg, 
        rgba(0, 112, 209, 0.25) 0%, 
        rgba(0, 160, 233, 0.2) 50%,
        rgba(124, 58, 237, 0.15) 100%);
    border-color: var(--ps-blue);
    color: var(--ps-blue-light);
    box-shadow: 
        0 0 20px rgba(0, 112, 209, 0.4),
        0 4px 12px rgba(0, 112, 209, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
    transform: translateY(-1px);
}

.sort-chip.active svg {
    opacity: 1;
    filter: drop-shadow(0 0 4px rgba(0, 160, 233, 0.6));
}

.sort-chip:active {
    transform: scale(0.96) translateY(0);
}

/* Catalog Search Input */
.catalog-controls {
    display: flex;
    align-items: center;
    gap: 8px;
    position: relative;
    z-index: 10;
}

.catalog-search {
    position: relative;
    flex-shrink: 0;
}

.search-input-compact {
    width: 140px;
    padding: 6px 12px 6px 36px;
    font-size: 12px;
    line-height: 1.2;
    height: 28px;
    box-sizing: border-box;
    background: var(--surface-glass);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    color: var(--text-primary);
    outline: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(12px);
    font-weight: 500;
    position: relative;
    z-index: 11;
}

.search-input-compact::placeholder {
    color: var(--text-secondary);
    opacity: 0.6;
}

.search-input-compact:focus {
    border-color: var(--ps-blue);
    background: rgba(15, 23, 42, 0.8);
    box-shadow: 0 0 16px rgba(0, 112, 209, 0.3);
    width: 160px;
}

/* Search Toggle Button */
.search-toggle-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 28px;
    padding: 0;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-lg);
    cursor: pointer;
    color: var(--text-primary);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(12px);
    flex-shrink: 0;
}

.search-toggle-btn:hover {
    border-color: rgba(0, 160, 233, 0.4);
    background: rgba(15, 23, 42, 0.8);
    box-shadow: 0 4px 12px rgba(0, 112, 209, 0.2);
    transform: translateY(-2px);
}

.search-toggle-btn:active {
    transform: scale(0.95);
}

.search-toggle-btn svg {
    opacity: 0.8;
    transition: opacity 0.3s;
}

.search-toggle-btn:hover svg {
    opacity: 1;
    color: var(--ps-blue-light);
}

.catalog-search {
    position: relative;
    display: flex;
    align-items: center;
    animation: slideIn 0.3s ease-out;
    z-index: 10;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-10px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.catalog-search .search-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    opacity: 0.6;
    transition: opacity 0.3s;
    z-index: 1;
}

.search-input-compact:focus ~ .search-icon,
.catalog-search:focus-within .search-icon {
    opacity: 1;
    color: var(--ps-blue-light);
}

/* Search Bar - Premium Glassmorphism */
.search-bar {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-md);
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-lg);
    transition: all var(--transition-fast);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.search-bar:focus-within {
    border-color: var(--ps-blue);
    box-shadow: 
        0 0 0 3px rgba(0, 112, 209, 0.2),
        0 4px 12px rgba(0, 112, 209, 0.15);
    background: rgba(15, 23, 42, 0.75);
}

.search-bar input {
    flex: 1;
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: var(--font-size-md);
    outline: none;
}

.search-bar input::placeholder {
    color: var(--text-tertiary);
}

.search-bar svg {
    width: 20px;
    height: 20px;
    color: var(--text-tertiary);
}

/* Detail Page Buttons */
.detail-share-btn,
.detail-fav-btn {
    background: none !important;
    border: none !important;
}

.detail-share-btn:hover,
.detail-fav-btn:hover {
    opacity: 0.7;
}

/* Section Headers */
.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--spacing-md);
}

.section-title {
    font-family: var(--font-family-accent);
    font-size: var(--font-size-lg);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.section-link {
    font-size: var(--font-size-sm);
    color: var(--ps-blue);
    font-weight: 500;
    text-decoration: none;
}

/* Horizontal Scroll */
.horizontal-scroll {
    display: flex;
    gap: var(--spacing-md);
    overflow-x: auto;
    padding-top: var(--spacing-lg);
    padding-bottom: var(--spacing-lg);
    margin: 0 calc(-1 * var(--spacing-md));
    padding-left: var(--spacing-md);
    padding-right: var(--spacing-md);
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.horizontal-scroll::-webkit-scrollbar {
    display: none;
}

.horizontal-scroll>* {
    scroll-snap-align: start;
    flex-shrink: 0;
}

/* Grid Layouts with Staggered Animation */
.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-md);
}

.bento-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-md);
}

.games-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-md);
}

/* Staggered animation for all grid children */
.grid-2 > *,
.bento-grid > *,
.games-grid > * {
    animation: cardFadeIn 0.6s ease-out backwards;
    opacity: 0;
    animation-fill-mode: forwards;
}

.grid-2 > *:nth-child(1),
.bento-grid > *:nth-child(1),
.games-grid > *:nth-child(1) { animation-delay: 0.05s; }
.grid-2 > *:nth-child(2),
.bento-grid > *:nth-child(2),
.games-grid > *:nth-child(2) { animation-delay: 0.1s; }
.grid-2 > *:nth-child(3),
.bento-grid > *:nth-child(3),
.games-grid > *:nth-child(3) { animation-delay: 0.15s; }
.grid-2 > *:nth-child(4),
.bento-grid > *:nth-child(4),
.games-grid > *:nth-child(4) { animation-delay: 0.2s; }
.grid-2 > *:nth-child(5),
.bento-grid > *:nth-child(5),
.games-grid > *:nth-child(5) { animation-delay: 0.25s; }
.grid-2 > *:nth-child(6),
.bento-grid > *:nth-child(6),
.games-grid > *:nth-child(6) { animation-delay: 0.3s; }
.grid-2 > *:nth-child(7),
.bento-grid > *:nth-child(7),
.games-grid > *:nth-child(7) { animation-delay: 0.35s; }
.grid-2 > *:nth-child(8),
.bento-grid > *:nth-child(8),
.games-grid > *:nth-child(8) { animation-delay: 0.4s; }
.grid-2 > *:nth-child(9),
.bento-grid > *:nth-child(9),
.games-grid > *:nth-child(9) { animation-delay: 0.45s; }
.grid-2 > *:nth-child(10),
.bento-grid > *:nth-child(10),
.games-grid > *:nth-child(10) { animation-delay: 0.5s; }

.bento-item {
    background: var(--surface-glass);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    padding: var(--spacing-lg);
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
    cursor: pointer;
    transition: all var(--transition-normal);
}

.bento-item:hover {
    transform: translateY(-4px) scale(1.02);
    background: var(--surface-glass-hover);
    border-color: rgba(0, 112, 209, 0.4);
    box-shadow: 
        var(--shadow-lg),
        0 0 20px rgba(0, 112, 209, 0.3);
}

.bento-item:active {
    transform: translateY(0);
}

.bento-item.featured {
    grid-column: span 2;
}

.bento-icon {
    width: 32px;
    height: 32px;
    color: var(--ps-blue-light);
}

.bento-icon svg {
    width: 100%;
    height: 100%;
}

.bento-title {
    font-size: var(--font-size-md);
    font-weight: 600;
}

.bento-subtitle {
    font-size: var(--font-size-sm);
    color: var(--text-secondary);
}

/* AdsGram Ad Banner (320x100 format) */
.adsgram-banner {
    margin-bottom: var(--spacing-lg);
    cursor: pointer;
    width: 100%;
}

.adsgram-banner-content {
    transition: all 0.2s ease;
}

.adsgram-banner-content:active {
    transform: scale(0.98);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.2) !important;
}

.adsgram-banner:hover .adsgram-banner-content {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3) !important;
    border-color: rgba(0, 112, 209, 0.3) !important;
}

/* Hero Banner */
.hero-banner {
    position: relative;
    border-radius: var(--radius-xl);
    overflow: hidden;
    margin-bottom: var(--spacing-lg);
}

.hero-banner img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    position: relative;
}

.hero-banner img::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 70%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.6) 50%, rgba(0, 0, 0, 0.3) 80%, transparent 100%);
    pointer-events: none;
}

.hero-banner-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0.5) 50%, transparent 100%);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: var(--spacing-lg);
    z-index: 2;
}

.hero-banner-title {
    font-size: var(--font-size-xl);
    font-weight: 700;
    margin-bottom: var(--spacing-xs);
}

.hero-banner-subtitle {
    font-size: var(--font-size-sm);
    color: var(--text-secondary);
}

/* Subscription Detail Banner */
.subscription-detail-banner {
    height: 200px;
    border-radius: var(--radius-xl);
    overflow: hidden;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
}

.subscription-detail-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.4) 0%, rgba(0, 0, 0, 0.6) 50%, rgba(0, 0, 0, 0.85) 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-lg);
    z-index: 2;
}

.subscription-detail-icon {
    font-size: 56px;
    margin-bottom: var(--spacing-sm);
}

.subscription-detail-title {
    font-size: 32px;
    font-weight: 700;
    color: white;
    text-align: center;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

/* Period Buttons */
.period-buttons {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.period-btn {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--spacing-md) var(--spacing-lg);
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-xl);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.period-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.05), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

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

.period-btn:hover {
    background: rgba(255, 255, 255, 0.06);
    transform: translateY(-2px);
}

.period-btn:active {
    transform: translateY(0) scale(0.98);
}

/* Blue glow for 7 days */
.period-btn[data-days="7"].selected {
    background: linear-gradient(135deg, rgba(0, 112, 209, 0.2), rgba(0, 160, 233, 0.1));
    border-color: var(--ps-blue);
    box-shadow: 0 0 30px rgba(0, 112, 209, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

/* Gold glow for 14 days */
.period-btn[data-days="14"].selected {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.2), rgba(245, 158, 11, 0.1));
    border-color: #FFD700;
    box-shadow: 0 0 30px rgba(255, 215, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

/* Purple glow for 30 days */
.period-btn[data-days="30"].selected {
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.2), rgba(124, 58, 237, 0.1));
    border-color: #A855F7;
    box-shadow: 0 0 30px rgba(168, 85, 247, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

/* Extra glow for 90 days */
.period-btn[data-days="90"].selected {
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.2), rgba(124, 58, 237, 0.1));
    border-color: var(--tier-extra);
    box-shadow: 0 0 30px rgba(124, 58, 237, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

/* Premium glow for 365 days */
.period-btn[data-days="365"].selected {
    background: linear-gradient(135deg, rgba(236, 72, 153, 0.2), rgba(236, 72, 153, 0.1));
    border-color: var(--tier-premium);
    box-shadow: 0 0 30px rgba(236, 72, 153, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.period-prices {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 2px;
}

.period-price-stars {
    font-size: 12px;
    color: var(--tier-extra);
    font-weight: 600;
}

.period-label {
    font-weight: 600;
}

.period-price {
    font-family: var(--font-family-accent);
    font-size: var(--font-size-xl);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    color: var(--ps-blue-light);
}

/* Availability Badge - Glowing Pill Style */
.availability-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 50px;
    font-weight: 600;
    font-size: var(--font-size-sm);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    transition: all 0.3s ease;
}

.availability-badge.in-stock {
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.2), rgba(22, 163, 74, 0.1));
    border: 2px solid rgba(34, 197, 94, 0.5);
    color: #4ade80;
    box-shadow: 0 0 25px rgba(34, 197, 94, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.availability-badge.out-of-stock {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.2), rgba(220, 38, 38, 0.1));
    border: 2px solid rgba(239, 68, 68, 0.5);
    color: #f87171;
    box-shadow: 0 0 25px rgba(239, 68, 68, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.availability-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    font-size: 14px;
    font-weight: 700;
}

.availability-text {
    font-weight: 600;
    letter-spacing: 0.3px;
}


/* Game Detail Banner */
.game-detail-banner {
    margin: 0 calc(-1 * var(--spacing-md));
    margin-top: var(--spacing-md);
    margin-bottom: var(--spacing-md);
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-lg);
}

.game-detail-banner::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 150px;
    background: linear-gradient(to top,
            var(--bg-primary) 0%,
            rgba(15, 23, 42, 0.80) 15%,
            rgba(15, 23, 42, 0.50) 30%,
            rgba(15, 23, 42, 0.25) 45%,
            rgba(15, 23, 42, 0.10) 60%,
            rgba(15, 23, 42, 0.03) 75%,
            transparent 90%);
    pointer-events: none;
    z-index: 1;
}

.game-detail-image {
    width: 100%;
    height: 300px;
    object-fit: cover;
    display: block;
    position: relative;
    border: none;
    outline: none;
    box-shadow: none;
    border-radius: var(--radius-lg);
}

/* Dark gradient overlay for game detail banner */
.game-detail-image::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.7) 0%, rgba(0, 0, 0, 0.4) 30%, rgba(0, 0, 0, 0.2) 50%, rgba(0, 0, 0, 0.05) 70%, transparent 100%);
    pointer-events: none;
}

/* Empty State */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: var(--spacing-2xl);
    gap: var(--spacing-md);
}

.empty-state-icon {
    width: 64px;
    height: 64px;
    color: var(--text-tertiary);
    margin: 0 auto;
}

.empty-state-icon svg {
    width: 100%;
    height: 100%;
}

.empty-state-title {
    font-size: var(--font-size-lg);
    font-weight: 600;
}

.empty-state-text {
    color: var(--text-secondary);
    max-width: 280px;
}

/* Rental Card */
.rental-card {
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-lg);
    overflow: hidden;
    backdrop-filter: blur(12px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
}

.rental-card:hover {
    border-color: rgba(0, 160, 233, 0.4);
    background: rgba(15, 23, 42, 0.8);
    box-shadow: 0 4px 12px rgba(0, 112, 209, 0.2);
    transform: translateY(-2px);
}

.rental-card:active {
    transform: scale(0.96) translateY(0);
}

.rental-card-pending {
    opacity: 0.85;
    border-style: dashed;
    border-color: rgba(245, 158, 11, 0.4);
}

.rental-card-pending .rental-card-status.pending {
    color: var(--warning);
    font-weight: 600;
}

.rental-card-pending .rental-card-status.pending .status-dot {
    animation: pulse-warning 2s ease-in-out infinite;
    box-shadow: 0 0 12px var(--warning), 0 0 4px var(--warning);
}

.rental-card-header {
    display: flex;
    gap: var(--spacing-md);
    padding: var(--spacing-md);
}

.rental-card-image {
    width: 80px;
    height: 80px;
    border-radius: var(--radius-md);
    object-fit: cover;
    background: var(--bg-tertiary);
    position: relative;
}

/* Dark gradient overlay for rental card images */
.rental-card-image::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.7) 0%, rgba(0, 0, 0, 0.3) 50%, transparent 100%);
    pointer-events: none;
    border-radius: 0 0 var(--radius-md) var(--radius-md);
}

.rental-card-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: var(--spacing-xs);
}

.rental-card-title {
    font-family: var(--font-family-accent);
    font-size: var(--font-size-sm);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.rental-card-status {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    font-size: var(--font-size-sm);
}

.rental-card-status.active {
    color: var(--success);
}

.rental-card-status.expiring {
    color: var(--warning);
    animation: pulse-warning 2s ease-in-out infinite;
    font-weight: 600;
}

.rental-card-status.expiring .status-dot {
    animation: pulse-dot 1.5s ease-in-out infinite;
    box-shadow: 0 0 12px rgba(245, 158, 11, 0.8), 0 0 24px rgba(245, 158, 11, 0.4);
}

@keyframes pulse-warning {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.8;
        transform: scale(1.02);
    }
}

@keyframes pulse-dot {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
        box-shadow: 0 0 12px rgba(245, 158, 11, 0.8), 0 0 24px rgba(245, 158, 11, 0.4);
    }
    50% {
        transform: scale(1.2);
        opacity: 0.9;
        box-shadow: 0 0 20px rgba(245, 158, 11, 1), 0 0 40px rgba(245, 158, 11, 0.6);
    }
}

.rental-card-time {
    font-size: var(--font-size-sm);
    color: var(--text-secondary);
}

/* Rentals Statistics */
.rentals-statistics {
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-lg);
    padding: 0;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    overflow: hidden;
}

.statistics-toggle {
    width: 100%;
    padding: 6px 18px;
    background: transparent;
    border: none;
    font-family: var(--font-family-accent);
    font-size: var(--font-size-sm);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    color: var(--text-primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-xs);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.statistics-toggle:hover {
    color: var(--ps-blue-light);
}

.statistics-toggle:active {
    transform: scale(0.98);
}

.statistics-arrow {
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.statistics-content {
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transition: max-height 0.3s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.rentals-statistics.expanded .statistics-content {
    max-height: 1000px;
    opacity: 1;
}

.statistics-list {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
    padding: var(--spacing-md);
}

.stat-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-sm);
}

.stat-row-highlight {
    margin-top: var(--spacing-xs);
}

.stat-item-compact {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-sm) var(--spacing-md);
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-md);
    cursor: default;
    position: relative;
    overflow: hidden;
    transform: none !important;
    transition: none !important;
}

.stat-icon-wrapper {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 112, 209, 0.1);
    border-radius: var(--radius-sm);
    color: var(--ps-blue-light);
    flex-shrink: 0;
}

.stat-item-money {
    grid-column: 1 / -1;
}

.stat-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.stat-label-compact {
    font-family: 'Inter', sans-serif;
    font-size: 10px;
    color: var(--text-secondary);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.stat-value-compact {
    font-family: 'Inter', sans-serif;
    font-size: var(--font-size-md);
    font-weight: 600;
    color: var(--ps-blue-light);
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transform: none !important;
    transition: none !important;
}

.stat-value-date {
    font-size: var(--font-size-sm);
}

.stat-value-money {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    font-size: var(--font-size-lg);
}

.stat-stars {
    opacity: 0.8;
    font-size: var(--font-size-md);
}


.stat-value-price-compact {
    font-size: var(--font-size-lg);
    text-shadow: 0 0 12px rgba(0, 160, 233, 0.4);
}

.stat-label-compact {
    font-size: 10px;
    color: var(--text-secondary);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.stat-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: var(--spacing-sm);
    background: rgba(255, 255, 255, 0.03);
    border-radius: var(--radius-md);
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.stat-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(0, 112, 209, 0.1), transparent);
    transition: left 0.5s;
}

.stat-item:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(0, 112, 209, 0.3);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 112, 209, 0.2);
}

.stat-item:hover::before {
    left: 100%;
}

.stat-item:hover .stat-value {
    color: var(--ps-blue-light);
    transform: scale(1.05);
    text-shadow: 0 0 12px rgba(0, 160, 233, 0.5);
}

.stat-item-full {
    grid-column: 1 / -1;
    background: linear-gradient(135deg, rgba(0, 112, 209, 0.1), rgba(0, 160, 233, 0.05));
    border-color: rgba(0, 112, 209, 0.2);
}

.stat-item-full:hover {
    background: linear-gradient(135deg, rgba(0, 112, 209, 0.15), rgba(0, 160, 233, 0.1));
    border-color: rgba(0, 112, 209, 0.4);
}

.stat-label {
    font-family: 'Inter', sans-serif;
    font-size: 10px;
    color: var(--text-secondary);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-value {
    font-family: 'Inter', sans-serif;
    font-size: var(--font-size-md);
    font-weight: 600;
    color: var(--ps-blue-light);
    line-height: 1.2;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-block;
}

.stat-value-small {
    font-size: var(--font-size-sm);
}

.stat-value-price {
    font-size: var(--font-size-lg);
    color: var(--ps-blue-light);
    text-shadow: 0 0 12px rgba(0, 160, 233, 0.4);
    font-weight: 600;
}

.rental-progress {
    height: 4px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    overflow: hidden;
}

.rental-progress-bar {
    height: 100%;
    background: var(--gradient-primary);
    border-radius: var(--radius-full);
    transition: width var(--transition-slow);
}

/* Tabs */
.tabs {
    display: flex;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-lg);
}

.tab-btn {
    flex: 1;
    padding: 6px 18px;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
    gap: 5px;
    border-radius: var(--radius-lg);
    backdrop-filter: blur(12px);
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    letter-spacing: 0.3px;
    min-width: 0;
}

.tab-btn:hover {
    border-color: rgba(0, 160, 233, 0.4);
    background: rgba(15, 23, 42, 0.8);
    box-shadow: 0 4px 12px rgba(0, 112, 209, 0.2);
    transform: translateY(-2px);
}

.tab-btn.active {
    background: linear-gradient(135deg, 
        rgba(0, 112, 209, 0.25) 0%, 
        rgba(0, 160, 233, 0.2) 50%,
        rgba(124, 58, 237, 0.15) 100%);
    border-color: var(--ps-blue);
    color: var(--ps-blue-light);
    box-shadow: 
        0 0 20px rgba(0, 112, 209, 0.4),
        0 4px 12px rgba(0, 112, 209, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
    transform: translateY(-1px);
}

.tab-btn:active {
    transform: scale(0.96) translateY(0);
}

/* Loading States */
.loading-overlay {
    position: fixed;
    inset: 0;
    display: none !important;
    align-items: center;
    justify-content: center;
    background: rgba(10, 10, 15, 0.8);
    backdrop-filter: blur(10px);
    z-index: 1000;
    pointer-events: none;
}

.loading-overlay.active {
    display: flex !important;
    pointer-events: auto;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--border-glass);
    border-top-color: var(--ps-blue);
    border-radius: var(--radius-full);
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Skeleton Loader */
.skeleton {
    background: linear-gradient(90deg, var(--surface-glass) 25%, var(--surface-glass-hover) 50%, var(--surface-glass) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: var(--radius-md);
}

@keyframes shimmer {
    0% {
        background-position: 200% 0;
    }

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

/* Toast Notifications */
.toast-container {
    position: fixed;
    bottom: calc(var(--nav-height) + var(--safe-area-bottom) + 12px + var(--spacing-md));
    left: var(--spacing-md);
    right: var(--spacing-md);
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
    z-index: 1001;
    pointer-events: none;
}

.toast {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-md);
    background: var(--bg-secondary);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    animation: toastIn var(--transition-normal) ease;
    pointer-events: auto;
}

.toast.success {
    border-color: var(--success);
}

.toast.error {
    border-color: var(--error);
}

@keyframes toastIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

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

/* Favorite Button */
.favorite-btn {
    position: absolute;
    top: var(--spacing-sm);
    right: var(--spacing-sm);
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.7);
    border: none;
    border-radius: var(--radius-full);
    backdrop-filter: blur(10px);
    cursor: pointer;
    transition: all var(--transition-fast);
    z-index: 4;
}

.favorite-btn svg {
    width: 20px;
    height: 20px;
    color: var(--text-primary);
    transition: all var(--transition-fast);
}

.favorite-btn.active svg {
    fill: var(--error);
    color: var(--error);
}

.favorite-btn:active {
    transform: scale(0.9);
}

/* Input / Form */
.input-group {
    margin-bottom: var(--spacing-md);
}

.input-label {
    display: block;
    font-size: var(--font-size-sm);
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: var(--spacing-xs);
}

.input {
    width: 100%;
    padding: var(--spacing-md);
    font-family: inherit;
    font-size: var(--font-size-md);
    color: var(--text-primary);
    background: var(--surface-glass);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    outline: none;
    transition: all var(--transition-fast);
}

.input:focus {
    border-color: var(--ps-blue);
    box-shadow: 0 0 0 3px rgba(0, 112, 209, 0.2);
}

/* Payment Methods */
.payment-method {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-md);
    background: var(--surface-glass);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.payment-method:hover {
    background: var(--surface-glass-hover);
}

.payment-method.selected {
    border-color: var(--ps-blue);
    background: rgba(0, 112, 209, 0.1);
}

.payment-method-icon {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    font-size: 20px;
}

.payment-method-info {
    flex: 1;
}

.payment-method-name {
    font-weight: 600;
}

.payment-method-desc {
    font-size: var(--font-size-sm);
    color: var(--text-secondary);
}

.payment-method-radio {
    width: 20px;
    height: 20px;
    border: 2px solid var(--border-glass);
    border-radius: var(--radius-full);
    position: relative;
}

.payment-method.selected .payment-method-radio {
    border-color: var(--ps-blue);
}

.payment-method.selected .payment-method-radio::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 10px;
    height: 10px;
    background: var(--ps-blue);
    border-radius: var(--radius-full);
}

/* Utility Classes */
.mt-sm {
    margin-top: var(--spacing-sm);
}

.mt-md {
    margin-top: var(--spacing-md);
}

.mt-lg {
    margin-top: var(--spacing-lg);
}

.mt-xl {
    margin-top: var(--spacing-xl);
}

.mb-sm {
    margin-bottom: var(--spacing-sm);
}

.mb-md {
    margin-bottom: var(--spacing-md);
}

.mb-lg {
    margin-bottom: var(--spacing-lg);
}

.mb-xl {
    margin-bottom: var(--spacing-xl);
}

.text-center {
    text-align: center;
}

.text-secondary {
    color: var(--text-secondary);
}

.text-success {
    color: var(--success);
}

.text-warning {
    color: var(--warning);
}

.text-error {
    color: var(--error);
}

.fw-500 {
    font-weight: 500;
}

.fw-600 {
    font-weight: 600;
}

.fw-700 {
    font-weight: 700;
}

.flex {
    display: flex;
}

.flex-col {
    flex-direction: column;
}

.items-center {
    align-items: center;
}

.justify-between {
    justify-content: space-between;
}

.gap-sm {
    gap: var(--spacing-sm);
}

.gap-md {
    gap: var(--spacing-md);
}

/* Profile Screen */
.profile-header {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-sm) 0;
    background: transparent;
    border: none;
    margin-bottom: var(--spacing-md);
}

.profile-avatar {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--ps-blue), var(--ps-purple));
    border-radius: var(--radius-full);
    color: white;
    position: relative;
    z-index: 1;
    box-shadow: 0 4px 8px rgba(0, 112, 243, 0.3);
    flex-shrink: 0;
}

.profile-info {
    flex: 1;
    position: relative;
    z-index: 1;
}

.profile-actions {
    display: flex;
    gap: var(--spacing-xs);
    position: relative;
    z-index: 1;
}

.profile-action-btn {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--surface-glass);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
    color: var(--text-secondary);
}

.profile-action-btn:hover {
    background: var(--surface-glass-hover);
    border-color: var(--ps-blue);
    color: var(--ps-blue);
    transform: translateY(-2px);
}

.profile-action-btn svg {
    stroke: currentColor;
}

.profile-action-btn.active {
    background: linear-gradient(135deg, rgba(0, 112, 243, 0.2), rgba(156, 39, 176, 0.2));
    border-color: var(--ps-blue);
    color: var(--ps-blue);
}

.profile-action-btn.active:hover {
    background: linear-gradient(135deg, rgba(0, 112, 243, 0.3), rgba(156, 39, 176, 0.3));
}


.profile-name {
    font-size: var(--font-size-xl);
    font-weight: 700;
    margin-bottom: var(--spacing-xs);
}

.profile-username {
    font-size: var(--font-size-sm);
    color: var(--text-secondary);
}

.profile-stats {
    display: flex;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-lg);
}

.profile-stat {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--spacing-xs);
    padding: var(--spacing-lg);
    background: var(--surface-glass);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
}

.profile-stat-value {
    font-size: var(--font-size-xl);
    font-weight: 700;
    color: var(--ps-blue-light);
}

.profile-stat-label {
    font-size: var(--font-size-xs);
    color: var(--text-tertiary);
}

.profile-menu {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.profile-menu-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-lg);
    background: var(--surface-glass);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: all var(--transition-fast);
    position: relative;
    overflow: hidden;
}

.profile-menu-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(180deg, var(--ps-blue), var(--ps-purple));
    transform: scaleY(0);
    transition: transform var(--transition-fast);
}

.profile-menu-item:hover {
    background: var(--surface-glass-hover);
    transform: translateX(4px);
    border-color: rgba(0, 112, 243, 0.3);
}

.profile-menu-item:hover::before {
    transform: scaleY(1);
}

.profile-menu-item:active {
    transform: scale(0.98);
}

.profile-menu-icon {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    stroke: currentColor;
    color: var(--text-secondary);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
    transition: all var(--transition-fast);
}

.profile-menu-item:hover .profile-menu-icon {
    transform: scale(1.1);
    color: var(--ps-blue);
}

.profile-menu-text {
    flex: 1;
    font-size: var(--font-size-md);
    font-weight: 600;
    color: var(--text-primary);
}

.profile-menu-arrow {
    color: var(--text-tertiary);
}

/* Toggle Switch */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 28px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(255, 255, 255, 0.1);
    transition: 0.3s;
    border-radius: 28px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}

input:checked+.toggle-slider {
    background-color: var(--ps-blue);
}

input:checked+.toggle-slider:before {
    transform: translateX(20px);
}

.toggle-slider:hover {
    background-color: rgba(255, 255, 255, 0.15);
}

input:checked+.toggle-slider:hover {
    background-color: #0070d1;
}

/* FAQ Styles */
.faq-item {
    cursor: pointer;
    transition: all var(--transition-fast);
}

.faq-item:hover {
    background: var(--surface-glass-hover);
}

.faq-question {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-weight: 600;
    font-size: 15px;
    padding: var(--spacing-md);
    letter-spacing: 0.3px;
}

.faq-arrow {
    transition: transform var(--transition-fast);
    color: var(--text-tertiary);
}

.faq-item.expanded .faq-arrow {
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
    padding: 0 var(--spacing-md);
    color: var(--text-secondary);
    line-height: 1.8;
    white-space: pre-line;
    font-size: 14px;
}

.faq-item.expanded .faq-answer {
    max-height: 1000px;
    padding: 0 var(--spacing-md) var(--spacing-md);
}

.faq-answer b {
    color: var(--text-primary);
    font-weight: 600;
}

.faq-answer i {
    color: var(--text-tertiary);
    font-style: italic;
}

.faq-answer code {
    background: rgba(255, 255, 255, 0.05);
    padding: 2px 6px;
    border-radius: 4px;
    font-family: monospace;
    font-size: 0.9em;
}

/* Statistics Dashboard */
.stats-dashboard {
    animation: fadeIn 0.5s ease;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-md);
}

.stat-card {
    background: var(--surface-glass);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    padding: var(--spacing-md);
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    position: relative;
    overflow: hidden;
    transition: all var(--transition-fast);
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--stat-color, var(--ps-blue));
    opacity: 0;
    transition: opacity var(--transition-fast);
}

.stat-card:hover {
    background: var(--surface-glass-hover);
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
}

.stat-card:hover::before {
    opacity: 1;
}

.stat-icon {
    width: 32px;
    height: 32px;
    flex-shrink: 0;
    stroke: var(--stat-color, var(--ps-blue));
    color: var(--stat-color, var(--ps-blue));
    filter: drop-shadow(0 2px 8px rgba(0, 112, 243, 0.3));
    transition: all var(--transition-fast);
}

.stat-card:hover .stat-icon {
    transform: scale(1.1) rotate(5deg);
    filter: drop-shadow(0 4px 12px rgba(0, 112, 243, 0.5));
}

.stat-content {
    flex: 1;
}

.stat-value {
    font-size: 28px;
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1;
    letter-spacing: -0.5px;
}

.stat-label {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-secondary);
    margin-top: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-trend {
    font-size: var(--font-size-sm);
    font-weight: 600;
    color: #10b981;
    background: rgba(16, 185, 129, 0.1);
    padding: 2px 6px;
    border-radius: 4px;
}

/* Progress Stats */
.progress-stats {
    background: var(--surface-glass);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    padding: var(--spacing-md);
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.progress-bar-container {
    height: 8px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
    overflow: hidden;
}

.progress-bar-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 1s ease;
    animation: progressFill 1s ease;
}

@keyframes progressFill {
    from {
        width: 0;
    }
}

/* Top Games */
.top-games {
    background: var(--surface-glass);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    padding: var(--spacing-md);
}

.top-game-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-sm);
    background: rgba(255, 255, 255, 0.02);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.top-game-item:hover {
    background: rgba(255, 255, 255, 0.05);
    transform: translateX(4px);
}

.top-game-rank {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--ps-blue), var(--ps-purple));
    border-radius: 50%;
    font-weight: 700;
    font-size: var(--font-size-sm);
    flex-shrink: 0;
}

.top-game-info {
    flex: 1;
    min-width: 0;
}

.top-game-title {
    font-weight: 600;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.top-game-meta {
    font-size: var(--font-size-sm);
    color: var(--text-tertiary);
    margin-top: 2px;
}

/* ========================================
   Greeting
   ======================================== */
.greeting {
    padding: var(--spacing-md) 0;
    animation: fadeIn 0.5s ease;
}

.greeting-text {
    font-family: var(--font-family-accent);
    font-size: var(--font-size-2xl);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    color: var(--text-primary);
    margin: 0;
}

/* ========================================
   Compare Button
   ======================================== */
.compare-btn {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-sm) var(--spacing-md);
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-lg);
    color: var(--text-secondary);
    font-size: var(--font-size-sm);
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition-fast);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.compare-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--ps-blue);
    color: var(--text-primary);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 112, 209, 0.2);
}

.compare-btn:active {
    transform: translateY(0) scale(0.98);
}

.compare-btn svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

.compare-btn-compact {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-lg);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.compare-btn-compact:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--ps-blue);
    color: var(--text-primary);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 112, 209, 0.2);
}

.compare-btn-compact:active {
    transform: translateY(0) scale(0.95);
}

/* ========================================
   Tariff Comparison Modal
   ======================================== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 10000;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity var(--transition-normal), visibility var(--transition-normal);
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.comparison-modal {
    width: 100%;
    max-width: 100%;
    max-height: 85vh;
    background: var(--deep-slate);
    border-top-left-radius: var(--radius-xl);
    border-top-right-radius: var(--radius-xl);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    transform: translateY(100%);
    transition: transform var(--transition-normal);
    overflow: hidden;
}

.modal-overlay.active .comparison-modal {
    transform: translateY(0);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--spacing-lg);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.02);
}

.modal-title {
    font-family: var(--font-family-accent);
    font-size: var(--font-size-xl);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    color: var(--text-primary);
    margin: 0;
}

.modal-close {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-lg);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
    transform: rotate(90deg);
}

.modal-body {
    padding: var(--spacing-lg);
    overflow-y: auto;
    flex: 1;
}

.comparison-table {
    display: grid;
    grid-template-columns: 1.5fr repeat(3, 1fr);
    gap: var(--spacing-sm);
    font-size: var(--font-size-sm);
}

.comparison-header {
    display: contents;
}

.comparison-header > div {
    padding: var(--spacing-md);
    font-weight: 700;
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-md);
    text-align: center;
}

.comparison-feature {
    padding: var(--spacing-md);
    color: var(--text-secondary);
    font-weight: 500;
    display: flex;
    align-items: center;
}

.comparison-tier {
    padding: var(--spacing-md);
    font-weight: 700;
    text-align: center;
    border-radius: var(--radius-md);
}

.comparison-tier.essential {
    background: var(--tier-essential-gradient);
    color: var(--tier-essential);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.comparison-tier.extra {
    background: var(--tier-extra-gradient);
    color: var(--tier-extra);
    border: 1px solid var(--tier-extra);
}

.comparison-tier.premium {
    background: var(--tier-premium-gradient);
    color: var(--tier-premium);
    border: 1px solid var(--tier-premium);
}

.comparison-row {
    display: contents;
}

.comparison-cell {
    padding: var(--spacing-md);
    text-align: center;
    background: rgba(255, 255, 255, 0.02);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
}

.comparison-cell.essential {
    color: var(--tier-essential);
}

.comparison-cell.extra {
    color: var(--tier-extra);
}

.comparison-cell.premium {
    color: var(--tier-premium);
}

/* Style comparison cells */
.comparison-cell {
    font-size: var(--font-size-sm);
}

/* Responsive adjustments for comparison table */
@media (max-width: 480px) {
    .comparison-table {
        font-size: var(--font-size-xs);
        gap: var(--spacing-xs);
    }
    
    .comparison-header > div,
    .comparison-feature,
    .comparison-cell {
        padding: var(--spacing-sm);
        min-height: 40px;
    }
}

/* Mobile Optimizations */
@media (max-width: 480px) {
    /* Reduce spacing on mobile */
    :root {
        --spacing-xs: 4px;
        --spacing-sm: 6px;
        --spacing-md: 12px;
        --spacing-lg: 16px;
        --spacing-xl: 20px;
        --spacing-2xl: 32px;
    }

    /* Main content padding */
    .main-content {
        padding-left: var(--spacing-sm);
        padding-right: var(--spacing-sm);
        padding-top: calc(var(--header-height) + var(--tg-safe-top, 120px) + var(--spacing-sm));
        padding-bottom: calc(var(--nav-height) + var(--safe-area-bottom) + 12px + var(--spacing-sm));
    }

    /* Smaller game cards gap */
    .games-grid {
        gap: var(--spacing-sm);
    }

    .grid-2 {
        gap: var(--spacing-sm);
    }

    .bento-grid {
        gap: var(--spacing-sm);
    }

    /* Optimize game card aspect ratio for mobile */
    .game-card {
        aspect-ratio: 3/4;
    }

    /* Smaller font sizes */
    .game-card-title {
        font-size: 12px;
    }

    .game-card-price {
        font-size: 13px;
    }

    /* Reduce banner heights */
    .hero-banner img {
        height: 140px;
    }

    .carousel-banner {
        height: 160px;
    }

    .custom-banner {
        height: 160px;
    }

    /* AdsGram banner mobile optimization */
    .adsgram-banner-content {
        height: 90px !important;
    }

    .adsgram-banner-content > div:first-child {
        width: 90px !important;
        height: 90px !important;
    }

    .adsgram-banner-content > div:last-child {
        padding: 10px !important;
    }

    .adsgram-banner-content > div:last-child > div:first-child {
        font-size: 14px !important;
        margin-bottom: 3px !important;
    }

    .adsgram-banner-content > div:last-child > div:nth-child(2) {
        font-size: 11px !important;
        margin-bottom: 6px !important;
    }

    .adsgram-banner-content > div:last-child > div:last-child {
        font-size: 11px !important;
    }

    /* Smaller tier cards padding */
    .tier-card {
        padding: var(--spacing-md);
    }

    /* Optimize section headers */
    .section-title {
        font-size: var(--font-size-md);
    }

    /* Smaller buttons */
    .btn {
        padding: var(--spacing-sm) var(--spacing-md);
        font-size: var(--font-size-sm);
    }

    /* Reduce rental card padding */
    .rental-card-header {
        padding: var(--spacing-sm);
        gap: var(--spacing-sm);
    }

    .rental-card-image {
        width: 60px;
        height: 60px;
    }

    /* Smaller period buttons */
    .period-btn {
        padding: var(--spacing-sm) var(--spacing-md);
    }

    .period-price {
        font-size: var(--font-size-lg);
    }

    /* Optimize profile stats */
    .profile-stat {
        padding: var(--spacing-md);
    }

    .profile-stat-value {
        font-size: var(--font-size-lg);
    }

    /* Smaller chips */
    .chip {
        padding: 6px 14px;
        font-size: 12px;
    }

    /* Header optimizations */
    .header {
        padding: 0 var(--spacing-sm);
        padding-right: calc(var(--spacing-sm) + 8px);
    }

    .header-btn {
        width: 28px;
        height: 28px;
    }

    /* Bottom nav optimizations */
    .bottom-nav {
        padding: 0 var(--spacing-sm);
        height: 60px;
    }

    .nav-item {
        padding: var(--spacing-xs) var(--spacing-sm);
        font-size: 9px;
        background: transparent !important;
        background-color: transparent !important;
        border: none !important;
        border-radius: 0 !important;
        box-shadow: none !important;
    }

    .nav-icon {
        width: 20px;
        height: 20px;
    }

    /* Toast position */
    .toast-container {
        left: var(--spacing-sm);
        right: var(--spacing-sm);
        bottom: calc(92px + var(--safe-area-bottom));
    }

    /* Smaller subscription banners */
    .subscription-banner {
        min-width: 100%;
        padding: var(--spacing-md);
    }

    /* Optimize image banners */
    .image-banner {
        min-width: 100%;
        height: 140px;
    }

    /* Smaller review cards */
    .review-card {
        padding: var(--spacing-md);
    }
}

/* Tablet optimizations */
@media (min-width: 481px) and (max-width: 768px) {
    .main-content {
        padding-left: var(--spacing-md);
        padding-right: var(--spacing-md);
    }

    .games-grid {
        gap: var(--spacing-md);
    }

    .game-card {
        aspect-ratio: 2/3;
    }
}

/* Ensure content doesn't overflow on small screens */
@media (max-width: 360px) {
    :root {
        --spacing-xs: 3px;
        --spacing-sm: 5px;
        --spacing-md: 10px;
        --spacing-lg: 14px;
    }

    .game-card-title {
        font-size: 11px;
    }

    .section-title {
        font-size: 15px;
    }

    .header-btn {
        width: 26px;
        height: 26px;
    }
}

/* Accent typography with Rajdhani */
.payment-price-rub,
.payment-price-stars,
.total-price,
.price-tag {
    font-family: var(--font-family-accent);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.payment-price-rub,
.payment-price-stars {
    font-size: var(--font-size-xl);
}

/* Tier card titles */
.tier-card .fw-700,
.tier-card h1,
.tier-card h2,
.tier-card h3 {
    font-family: var(--font-family-accent);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

/* Category buttons and tags */
.chip,
.category-btn,
.product-tag {
    font-family: var(--font-family-accent);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

/* Copy button styles - ensure icon is visible and properly centered */
button.btn[onclick*="clipboard"] {
    position: relative;
    padding: var(--spacing-sm) !important;
    min-width: 36px !important;
    height: 36px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

button.btn[onclick*="clipboard"] svg {
    display: block !important;
    width: 18px !important;
    height: 18px !important;
    margin: 0 !important;
    padding: 0 !important;
    flex-shrink: 0 !important;
    color: inherit !important;
    pointer-events: none;
    box-sizing: border-box;
}

button.btn[onclick*="clipboard"] svg rect,
button.btn[onclick*="clipboard"] svg path {
    fill: none !important;
    stroke: currentColor !important;
    stroke-width: 2 !important;
    stroke-linecap: round !important;
    stroke-linejoin: round !important;
}

/* ========================================
   Telegram Mini App - Cross-Device Compatibility
   ======================================== */

/* Orientation support */
@media (orientation: landscape) {
    /* Adjust for landscape mode on mobile devices */
    @media (max-height: 500px) {
        .main-content {
            padding-top: calc(var(--header-height) + var(--tg-safe-top, 60px) + var(--spacing-sm));
        }
        
        .hero-banner img,
        .carousel-banner,
        .custom-banner {
            height: 120px;
        }
        
        .adsgram-banner-content {
            height: 70px !important;
        }
    }
}

/* iOS specific adjustments */
@supports (-webkit-touch-callout: none) {
    body {
        /* iOS Safari specific fixes */
        -webkit-overflow-scrolling: touch;
    }
    
    /* Fix for iOS safe area */
    .bottom-nav {
        padding-bottom: max(env(safe-area-inset-bottom, 0px), var(--tg-safe-bottom, 0px));
    }
}

/* Android specific adjustments */
[data-platform="android"] .main-content {
    /* Android specific styles if needed */
    /* Currently using default styles */
}

/* Very small screens (iPhone SE, etc.) */
@media (max-width: 375px) and (max-height: 667px) {
    :root {
        --spacing-xs: 3px;
        --spacing-sm: 5px;
        --spacing-md: 10px;
        --spacing-lg: 14px;
        --spacing-xl: 18px;
    }
    
    .game-card-title {
        font-size: 11px;
        line-height: 1.3;
    }
    
    .section-title {
        font-size: 14px;
    }
    
    .header {
        height: 44px;
    }
    
    .bottom-nav {
        height: 56px;
    }
}

/* Large screens (tablets, desktop) */
@media (min-width: 769px) {
    .main-content {
        max-width: 1200px;
        margin: 0 auto;
        padding-left: var(--spacing-lg);
        padding-right: var(--spacing-lg);
    }
    
    .games-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: var(--spacing-lg);
    }
    
    .grid-2 {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-lg);
    }
}

/* High DPI displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    /* Ensure crisp rendering on retina displays */
    .game-card-image,
    .tier-card-icon,
    .nav-icon {
        image-rendering: -webkit-optimize-contrast;
        image-rendering: crisp-edges;
    }
}

/* Touch device optimizations */
@media (hover: none) and (pointer: coarse) {
    /* Increase touch target sizes */
    .btn,
    .nav-item,
    .header-btn {
        min-height: 44px;
        min-width: 44px;
    }
    
    /* Remove hover effects on touch devices */
    .game-card:hover,
    .tier-card:hover {
        transform: none;
    }
}

/* Prevent text selection on interactive elements */
.btn,
.nav-item,
.header-btn,
.game-card,
.tier-card {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

/* Smooth scrolling for all devices */
* {
    -webkit-overflow-scrolling: touch;
}

/* Fix for Telegram viewport changes */
#mainContent {
    /* Ensure proper scrolling in Telegram */
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
}

/* Support for Telegram theme colors */
@media (prefers-color-scheme: light) {
    /* Light theme support if Telegram provides it */
    :root {
        --bg-primary: var(--tg-bg-color, #ffffff);
        --text-primary: var(--tg-text-color, #000000);
    }
}

/* Ensure content is always accessible */
.main-content {
    /* Prevent content from being hidden behind Telegram UI */
    min-height: calc(100vh - var(--header-height) - var(--nav-height) - var(--tg-safe-top, 120px) - var(--safe-area-bottom));
    min-height: calc(100dvh - var(--header-height) - var(--nav-height) - var(--tg-safe-top, 120px) - var(--safe-area-bottom));
}