/* Анімації для кнопок та індикаторів */
@keyframes promoBtnPulse {

    0%,
    100% {
        transform: scale(1);
        box-shadow: 0 4px 15px rgba(69, 189, 100, 0.4);
    }

    50% {
        transform: scale(1.02);
        box-shadow: 0 6px 25px rgba(69, 189, 100, 0.6);
    }
}

@keyframes pulse {

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

    50% {
        opacity: 0.6;
        transform: scale(1.2);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(0.95);
    }

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

.fade-in {
    animation: fadeIn 0.3s ease-out forwards;
}

/* Стилі для модалки рівнів */
#levelRewardsModal .gift-modal-content {
    animation: modalSlideUp 0.3s ease-out;
}

#levelRewardsList {
    scrollbar-width: thin;
    scrollbar-color: rgba(102, 126, 234, 0.3) transparent;
}

#levelRewardsList::-webkit-scrollbar {
    width: 4px;
}

#levelRewardsList::-webkit-scrollbar-track {
    background: transparent;
}

#levelRewardsList::-webkit-scrollbar-thumb {
    background: rgba(102, 126, 234, 0.3);
    border-radius: 4px;
}

#levelRewardsList::-webkit-scrollbar-thumb:hover {
    background: rgba(102, 126, 234, 0.5);
}

/* Ховер ефект для level-progress-container */
.level-progress-container:hover {
    border-color: rgba(102, 126, 234, 0.4) !important;
    background: rgba(0, 0, 0, 0.25) !important;
}

.level-progress-container:active {
    transform: scale(0.98);
}

/* Ефекти при купівлі */
@keyframes buyStarsFloat {
    0% {
        transform: translateY(0) scale(1) rotate(0deg);
        opacity: 0;
    }

    20% {
        opacity: 1;
    }

    100% {
        transform: translateY(-100px) scale(1.5) rotate(360deg);
        opacity: 0;
    }
}

.buy-star-particle {
    position: fixed;
    pointer-events: none;
    z-index: 10000;
    font-size: 2rem;
    animation: buyStarsFloat 1.5s ease-out forwards;
}

.success-glow {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 0;
    height: 0;
    background: radial-gradient(circle, rgba(242, 201, 76, 0.6) 0%, transparent 70%);
    border-radius: 50%;
    z-index: 9999;
    pointer-events: none;
    animation: successGlowExpand 1s ease-out forwards;
}

@keyframes successGlowExpand {
    0% {
        width: 0;
        height: 0;
        opacity: 1;
    }

    100% {
        width: 1000px;
        height: 1000px;
        opacity: 0;
    }
}

@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;500;700;900&display=swap');

:root {
    --bg-color: #17212b;
    --card-bg: #242f3d;
    --text-primary: #ffffff;
    --text-secondary: #8b96a1;
    --accent: #5288c1;
    --green: #45bd64;
    --gold: #f2c94c;
    --red: #e55c5c;
    --r-common: #b0b0b0;
    --r-uncommon: #45bd64;
    --r-rare: #007aff;
    --r-legendary: #f2c94c;
    --r-mythic: #ff00ff;

    /* === iOS 26 Liquid Glass System === */
    /* Layer 1: Illumination - blur + saturation boost */
    --glass-blur: 20px;
    --glass-saturate: 200%;
    /* Буст кольорів! */
    --glass-brightness: 1.1;
    /* Трохи світліше */
    --glass-bg-opacity: 0.15;

    /* Layer 2: Highlight (dynamic) - тонкий блік */
    --glass-highlight-opacity: 0.08;
    --glass-highlight-x: 50%;
    --glass-highlight-y: -30%;

    /* Layer 3: Shadow/Depth - м'які тіні */
    --glass-shadow-opacity: 0.12;
    --glass-inner-shadow: 0.06;
}

/* CSS @property for animatable custom properties */
@property --glass-highlight-x {
    syntax: '<percentage>';
    inherits: true;
    initial-value: 50%;
}

@property --glass-highlight-y {
    syntax: '<percentage>';
    inherits: true;
    initial-value: -25%;
}

/* Сезонні ефекти */
#seasonEffects {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 9998;
    overflow: hidden;
}

.snowflake {
    position: absolute;
    top: -20px;
    color: #fff;
    font-size: 1rem;
    animation: snowfall linear infinite;
    opacity: 0.8;
    text-shadow: 0 0 5px rgba(255, 255, 255, 0.5);
}

@keyframes snowfall {
    0% {
        transform: translateY(0) rotate(0deg);
    }

    100% {
        transform: translateY(100vh) rotate(360deg);
    }
}

.sun-ray {
    position: absolute;
    width: 3px;
    height: 100px;
    background: linear-gradient(to bottom, rgba(255, 200, 50, 0.6), transparent);
    animation: sunray 3s ease-in-out infinite;
    opacity: 0.4;
}

@keyframes sunray {

    0%,
    100% {
        opacity: 0.2;
        transform: scaleY(0.8);
    }

    50% {
        opacity: 0.5;
        transform: scaleY(1.2);
    }
}

.summer-particle {
    position: absolute;
    font-size: 1.2rem;
    animation: floatUp 8s linear infinite;
    opacity: 0.6;
}

@keyframes floatUp {
    0% {
        transform: translateY(100vh) rotate(0deg);
        opacity: 0;
    }

    10% {
        opacity: 0.6;
    }

    90% {
        opacity: 0.6;
    }

    100% {
        transform: translateY(-20px) rotate(180deg);
        opacity: 0;
    }
}

/* Зимова тема */
body.season-winter {
    --bg-color: #0d1b2a;
    --card-bg: #1b2838;
}

body.season-winter .header {
    background: rgba(20, 20, 30, 0.5);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

body.season-winter .bottom-nav {
    background: rgba(15, 20, 30, 0.35);
    backdrop-filter: blur(30px) saturate(200%);
    -webkit-backdrop-filter: blur(30px) saturate(200%);
    border-radius: 20px 20px 0 0;
}

/* Літня тема */
body.season-summer {
    --bg-color: #1a1a2e;
    --card-bg: #2d2d44;
}

body.season-summer .header {
    background: rgba(20, 20, 30, 0.5);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

body.season-summer .bottom-nav {
    background: rgba(15, 20, 30, 0.35);
    backdrop-filter: blur(30px) saturate(200%);
    -webkit-backdrop-filter: blur(30px) saturate(200%);
    border-radius: 20px 20px 0 0;
}

* {
    box-sizing: border-box;
}

/* Вимкнення анімацій (крім кейсів та профілю) */
body.no-animations *:not(.reel):not(.reel *):not(.card):not(.profile-effect):not(.profile-effect *):not(.profile-head *):not([class*="name-anim"]):not([class*="avatar-frame"]):not(.contract-card):not(.contract-card *) {
    animation: none !important;
    transition: transform 0.1s, opacity 0.1s !important;
}

body.no-animations .topup-icon,
body.no-animations .gift-modal-icon,
body.no-animations .logo,
body.no-animations .custom-case-card,
body.no-animations .custom-icon,
body.no-animations .snowflake,
body.no-animations .sun-ray,
body.no-animations .summer-particle {
    animation: none !important;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: 'Roboto', sans-serif;
    margin: 0;
    padding: 0;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
    overflow: hidden;
    height: 100vh;
}

.app-container {
    display: flex;
    flex-direction: column;
    height: 100vh;
    overflow: hidden;
}

.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 15px 15px 10px 15px;
    background: rgba(20, 20, 30, 0.5);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 100;
    transition: all 0.3s ease;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

/* === iOS 26 LIQUID GLASS - HEADER === */
.header.glass-effect {
    isolation: isolate;
    overflow: hidden;

    /* Майже прозора основа - фон видно чітко */
    background: transparent !important;

    /* LENS EFFECT: blur + saturation + brightness + contrast */
    backdrop-filter:
        blur(var(--glass-blur)) saturate(var(--glass-saturate)) brightness(1.08) contrast(1.05);
    -webkit-backdrop-filter:
        blur(var(--glass-blur)) saturate(var(--glass-saturate)) brightness(1.08) contrast(1.05);

    /* Рамка - тільки знизу */
    border: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);

    /* Inner shadows для об'єму */
    box-shadow:
        /* Зовнішня м'яка тінь */
        0 4px 20px rgba(0, 0, 0, 0.2),
        /* Білий inner glow зверху */
        inset 0 1px 0 rgba(255, 255, 255, 0.25),
        /* Темний inner shadow знизу */
        inset 0 -1px 0 rgba(0, 0, 0, 0.15);
}

/* RIM LIGHT - градієнтна біла смужка зверху */
.header.glass-effect::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    pointer-events: none;
    z-index: 10;

    /* Яскравий по центру, згасає до країв */
    background: linear-gradient(90deg,
            rgba(255, 255, 255, 0) 0%,
            rgba(255, 255, 255, 0.2) 20%,
            rgba(255, 255, 255, 0.5) 50%,
            rgba(255, 255, 255, 0.2) 80%,
            rgba(255, 255, 255, 0) 100%);
}

/* LENS DISTORTION імітація - радіальне освітлення по центру */
.header.glass-effect::after {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 1;

    /* Радіальний градієнт - світліше по центру (ефект лупи) */
    background: radial-gradient(ellipse 80% 100% at 50% 100%,
            rgba(255, 255, 255, 0.08) 0%,
            rgba(255, 255, 255, 0.03) 40%,
            transparent 70%);
}

.header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: 900;
    background: linear-gradient(90deg, #00f2fe, #4facfe, #00f260, #0575e6, #00f2fe);
    background-size: 300% 100%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: logoShift 5s ease infinite;
    letter-spacing: 2px;
}

@keyframes logoShift {

    0%,
    100% {
        background-position: 0% 50%;
    }

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

@keyframes logoShine {
    to {
        background-position: 200% center;
    }
}

.header-right {
    display: flex;
    gap: 8px;
    align-items: center;
}

.balance-badge {
    background: rgba(0, 0, 0, 0.2);
    padding: 5px 12px;
    border-radius: 12px;
    font-weight: bold;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: all 0.3s ease;
}

/* Glass ефект для балансів */
.header.glass-effect .balance-badge {
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.18);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

/* Glass ефект для логотипу */
.header.glass-effect .logo {
    text-shadow: 0 2px 15px rgba(0, 0, 0, 0.4);
    filter: drop-shadow(0 0 8px rgba(79, 172, 254, 0.3));
}

.admin-btn {
    display: none;
}

.admin-fab {
    position: fixed;
    bottom: 80px;
    right: 15px;
    width: 50px;
    height: 50px;
    background: rgba(102, 126, 234, 0.5);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: white;
    font-size: 1.3rem;
    cursor: pointer;
    z-index: 999;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
    display: none;
    align-items: center;
    justify-content: center;
}

.admin-fab:active {
    transform: scale(0.9);
}

/* ========== FLOATING SOUND BUTTON ========== */
.sound-fab {
    position: fixed;
    bottom: 80px;
    left: 15px;
    width: 44px;
    height: 44px;
    background: linear-gradient(145deg,
            rgba(25, 22, 20, 0.92) 0%,
            rgba(35, 30, 25, 0.88) 100%);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 50%;
    border: 1px solid rgba(212, 175, 85, 0.3);
    color: #f5e6c8;
    font-size: 1.1rem;
    cursor: pointer;
    z-index: 998;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4), 0 0 8px rgba(212, 175, 85, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.55;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.sound-fab:hover,
.sound-fab.panel-open {
    opacity: 1;
}

.sound-fab:active {
    transform: scale(0.9);
}

.sound-fab.muted {
    border-color: rgba(231, 76, 60, 0.4);
    color: rgba(231, 76, 60, 0.7);
}

.sound-panel {
    position: fixed;
    bottom: 130px;
    left: 15px;
    width: 240px;
    background: linear-gradient(145deg,
            rgba(25, 22, 20, 0.96) 0%,
            rgba(35, 30, 25, 0.94) 50%,
            rgba(20, 18, 15, 0.98) 100%);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border-radius: 18px;
    border: 1px solid rgba(212, 175, 85, 0.25);
    box-shadow:
        0 12px 40px rgba(0, 0, 0, 0.6),
        0 0 20px rgba(212, 175, 85, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.04);
    z-index: 999;
    padding: 16px;
    opacity: 0;
    transform: translateY(12px) scale(0.92);
    pointer-events: none;
    visibility: hidden;
    transition: opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.35s cubic-bezier(0.4, 0, 0.2, 1),
                visibility 0.35s;
}

.sound-panel.active {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
    visibility: visible;
}

.sound-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
    color: #f5e6c8;
    font-weight: 700;
    font-size: 0.95rem;
}

.sound-panel-close {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(212, 175, 85, 0.1);
    color: rgba(212, 175, 85, 0.6);
    cursor: pointer;
    font-size: 0.8rem;
    transition: all 0.2s;
}

.sound-panel-close:active {
    background: rgba(212, 175, 85, 0.2);
}

.sound-panel-row {
    margin-bottom: 12px;
}

.sound-panel-row:last-child {
    margin-bottom: 0;
}

.sound-panel-label {
    font-size: 0.8rem;
    color: rgba(245, 230, 200, 0.7);
    margin-bottom: 6px;
}

.sound-panel-slider-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
}

.sound-panel-slider {
    flex: 1;
    height: 4px;
    -webkit-appearance: none;
    appearance: none;
    background: rgba(212, 175, 85, 0.15);
    border-radius: 4px;
    outline: none;
}

.sound-panel-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: linear-gradient(135deg, #d4af55, #f2c94c);
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(212, 175, 85, 0.4);
}

.sound-panel-value {
    font-size: 0.75rem;
    color: #d4af55;
    font-weight: 600;
    min-width: 32px;
    text-align: right;
}

.views-wrapper {
    flex: 1;
    position: relative;
    overflow: hidden;
    min-height: 0;
}

.views-container {
    display: flex;
    width: 500%;
    height: 100%;
    transition: transform 0.25s cubic-bezier(0.22, 0.61, 0.36, 1);
    will-change: transform;
    transform: translateX(0%);
}

.views-container.transitioning {
    transition: transform 0.18s cubic-bezier(0.4, 0.0, 0.2, 1);
}

.view-section {
    width: 20%;
    height: 100%;
    flex-shrink: 0;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 60px 15px 15px 15px;
    transition: filter 0.12s ease, opacity 0.12s ease;
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
    touch-action: pan-y;
}

/* Відступ знизу для контенту - щоб не ховався під плаваючою навігацією */
.view-section::after {
    content: '';
    display: block;
    height: 90px;
    flex-shrink: 0;
}

.view-section.blur {
    filter: blur(8px);
    opacity: 0.7;
}

.admin-progress-container {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.15), rgba(118, 75, 162, 0.15));
    border: 2px solid rgba(102, 126, 234, 0.3);
    border-radius: 12px;
    padding: 12px;
    position: relative;
    overflow: hidden;
}

.admin-progress-title {
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.admin-progress-bar-bg {
    background: rgba(0, 0, 0, 0.3);
    height: 8px;
    border-radius: 4px;
    overflow: hidden;
}

.admin-progress-bar-fill {
    background: linear-gradient(90deg, #667eea, #764ba2);
    height: 100%;
    border-radius: 4px;
    transition: width 0.5s ease;
}

.admin-progress-text {
    font-size: 0.8rem;
    color: var(--gold);
    font-weight: bold;
    margin-top: 5px;
    text-align: center;
}

.admin-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 9999;
    overflow-y: auto;
}

.admin-modal.active {
    display: block;
}

.admin-content {
    background: var(--bg-color);
    margin: 20px auto;
    max-width: 500px;
    border-radius: 12px;
    padding: 20px;
    position: relative;
}

.admin-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text-secondary);
    cursor: pointer;
}

.admin-title {
    font-size: 1.3rem;
    font-weight: bold;
    margin-bottom: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.admin-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 20px;
}

.admin-stat-box {
    background: var(--card-bg);
    padding: 15px;
    border-radius: 10px;
    text-align: center;
}

.admin-stat-val {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--accent);
}

.admin-stat-lbl {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-top: 5px;
}

.admin-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
}

.admin-tab {
    flex: 1;
    background: var(--card-bg);
    border: 2px solid rgba(255, 255, 255, 0.1);
    padding: 12px;
    border-radius: 10px;
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    text-align: center;
}

.admin-tab.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-color: #667eea;
}

.stats-dashboard {
    display: none;
}

.stats-dashboard.active {
    display: block;
}

.stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 20px;
}

.stat-card {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 16px;
    border-left: 4px solid var(--accent);
}

.stat-card.green {
    border-left-color: var(--green);
}

.stat-card.gold {
    border-left-color: var(--gold);
}

.stat-card.red {
    border-left-color: var(--red);
}

.stat-card-icon {
    font-size: 2rem;
    margin-bottom: 8px;
}

.stat-card-value {
    font-size: 1.8rem;
    font-weight: bold;
    margin-bottom: 4px;
}

.stat-card-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.top-users-list {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 16px;
}

.top-user-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    margin-bottom: 8px;
}

.top-user-rank {
    width: 32px;
    height: 32px;
    background: var(--accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

.top-user-rank.gold {
    background: var(--gold);
    color: #000;
}

.top-user-rank.silver {
    background: #c0c0c0;
    color: #000;
}

.top-user-rank.bronze {
    background: #cd7f32;
    color: #000;
}

.top-user-info {
    flex: 1;
}

.top-user-name {
    font-weight: 600;
}

.top-user-value {
    color: var(--gold);
    font-weight: bold;
}

.admin-search {
    margin-bottom: 15px;
    display: flex;
    gap: 8px;
}

.admin-search input {
    flex: 1;
    background: var(--card-bg);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 10px;
    border-radius: 8px;
    color: white;
    font-size: 0.9rem;
}

.admin-search button {
    background: var(--accent);
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    color: white;
    font-weight: bold;
    cursor: pointer;
}

.users-list {
    margin-bottom: 15px;
}

.user-item {
    background: var(--card-bg);
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.user-info {
    flex: 1;
}

.user-id-display {
    font-weight: bold;
    color: var(--accent);
}

.user-username {
    color: var(--text-secondary);
    font-size: 0.85rem;
}

.user-stats {
    text-align: right;
    font-size: 0.85rem;
}

.admin-pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 15px;
}

.admin-pagination button {
    background: var(--card-bg);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 8px 16px;
    border-radius: 8px;
    color: white;
    cursor: pointer;
}

.admin-pagination button:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.bottom-nav {
    position: fixed;
    bottom: 10px;
    left: 12px;
    right: 12px;
    height: 60px;
    background: rgba(15, 15, 25, 0.45);
    backdrop-filter: blur(30px) saturate(200%);
    -webkit-backdrop-filter: blur(30px) saturate(200%);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 28px;
    display: flex;
    justify-content: space-around;
    align-items: center;
    z-index: 100;
    flex-shrink: 0;
    transition: all 0.15s ease;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(255, 255, 255, 0.05) inset;
}

/* === iOS 26 LIQUID GLASS - BOTTOM NAV === */
.bottom-nav.glass-effect {
    /* НЕ змінюємо position! fixed залишається від .bottom-nav */
    isolation: isolate;
    overflow: hidden;

    /* Майже прозора основа */
    background: transparent !important;

    /* LENS EFFECT: blur + saturation + brightness + contrast */
    backdrop-filter:
        blur(var(--glass-blur)) saturate(var(--glass-saturate)) brightness(1.08) contrast(1.05);
    -webkit-backdrop-filter:
        blur(var(--glass-blur)) saturate(var(--glass-saturate)) brightness(1.08) contrast(1.05);

    /* Тонка рамка */
    border: 1px solid rgba(255, 255, 255, 0.08) !important;

    /* Inner shadows */
    box-shadow:
        0 4px 20px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.25),
        inset 0 -1px 0 rgba(0, 0, 0, 0.15);
}

/* RIM LIGHT - яскрава смужка зверху */
.bottom-nav.glass-effect::before {
    content: '';
    position: absolute;
    top: 0;
    left: 5%;
    right: 5%;
    height: 1px;
    pointer-events: none;
    z-index: 10;

    /* Яскравий по центру */
    background: linear-gradient(90deg,
            rgba(255, 255, 255, 0) 0%,
            rgba(255, 255, 255, 0.25) 25%,
            rgba(255, 255, 255, 0.5) 50%,
            rgba(255, 255, 255, 0.25) 75%,
            rgba(255, 255, 255, 0) 100%);
}

/* LENS DISTORTION імітація - радіальне освітлення */
.bottom-nav.glass-effect::after {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 1;
    border-radius: inherit;

    /* Радіальний градієнт по центру зверху */
    background: radial-gradient(ellipse 70% 80% at 50% 0%,
            rgba(255, 255, 255, 0.1) 0%,
            rgba(255, 255, 255, 0.04) 40%,
            transparent 70%);
}


/* Toggle switch */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    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: rgba(255, 255, 255, 0.15);
    border-radius: 28px;
    transition: 0.3s;
}

.toggle-slider::before {
    position: absolute;
    content: '';
    height: 22px;
    width: 22px;
    left: 3px;
    bottom: 3px;
    background: white;
    border-radius: 50%;
    transition: 0.3s;
}

.toggle-switch input:checked+.toggle-slider {
    background: linear-gradient(135deg, #667eea, #764ba2);
}

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

.nav-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: 0.7rem;
    width: 20%;
    gap: 3px;
    transition: all 0.3s ease;
    position: relative;
    padding: 8px 0;
}

.nav-btn.active {
    color: var(--accent);
}

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

/* Підкреслення активної кнопки */
.nav-btn.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 24px;
    height: 3px;
    background: var(--accent);
    border-radius: 3px 3px 0 0;
}

/* Glass ефект для активної кнопки */
.bottom-nav.glass-effect .nav-btn.active {
    color: #fff;
}

.bottom-nav.glass-effect .nav-btn.active::after {
    background: linear-gradient(90deg, #667eea, #764ba2);
    box-shadow: 0 0 12px rgba(102, 126, 234, 0.8), 0 0 20px rgba(118, 75, 162, 0.5);
}

.nav-btn .nav-icon {
    transition: transform 0.2s ease;
}

.nav-btn.active .nav-icon {
    transform: scale(1.1);
}

.nav-icon {
    font-size: 1.4rem;
    position: relative;
}

.news-card {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 15px;
    margin-bottom: 15px;
}

.news-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.news-icon {
    width: 32px;
    height: 32px;
    background: var(--accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

.news-title {
    font-weight: bold;
}

.news-date {
    margin-left: auto;
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.news-body {
    font-size: 0.9rem;
    line-height: 1.5;
    color: #ddd;
}

.cases-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    padding-top: 12px;
    padding-bottom: 10px;
}

.case-card {
    /* Premium Dark Gold Glassmorphism */
    background: linear-gradient(145deg,
            rgba(25, 22, 20, 0.92) 0%,
            rgba(35, 30, 25, 0.88) 50%,
            rgba(20, 18, 15, 0.95) 100%);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);

    border-radius: 18px;
    border: 1px solid rgba(212, 175, 85, 0.2);

    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.45),
        0 2px 8px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.04);

    padding: 6px;
    text-align: center;
    position: relative;
    overflow: visible;
    transition: all 0.25s ease;
    display: flex;
    flex-direction: column;
}

.case-card:active {
    transform: scale(0.96);
    border-color: rgba(212, 175, 85, 0.4);
}

.case-card-image {
    width: 100%;
    aspect-ratio: 1;
    border-radius: 14px;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 1;
    background-repeat: no-repeat;
    filter: drop-shadow(0 6px 16px rgba(212, 175, 85, 0.15));
}

/* Якщо використовується img замість background */
.case-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    border-radius: 16px;
}

/* === INFO SECTION - Simple text container now === */
.case-card-info {
    position: relative;
    margin-top: 4px;
    width: 100%;
    padding: 4px 0;
    z-index: 2;
}

/* Rim light removed from info, handled by card border/shadow */
.case-card-info::before {
    display: none;
}

.case-icon {
    font-size: 3rem;
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.2));
}

.case-name {
    font-weight: 600;
    font-size: 0.75rem;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.2;
    color: #f5e6c8;
}

.case-price {
    color: #d4af55;
    font-weight: bold;
    font-size: 0.7rem;
    line-height: 1.2;
}

.case-discount-badge {
    position: absolute;
    top: -8px;
    left: -8px;
    background: linear-gradient(135deg, rgba(212, 175, 85, 0.3), rgba(212, 175, 85, 0.15));
    border: 1px solid rgba(212, 175, 85, 0.5);
    padding: 4px 10px;
    border-radius: 10px;
    font-size: 0.75rem;
    font-weight: bold;
    color: #f5e6c8;
    z-index: 10;
    box-shadow: 0 2px 10px rgba(212, 175, 85, 0.2);
}

.customization-case-card {
    position: relative;
    overflow: visible !important;
    border: none !important;
}

.customization-case-card .case-card-image {
    border: 2px solid rgba(155, 89, 182, 0.5);
}

/* RULE REMOVED: .customization-case-card:not([style*="background-image"]) .case-card-image */

/* Особливий glass для кастомізації */
.customization-case-card .case-card-info {
    border-color: rgba(155, 89, 182, 0.2);
}

.customization-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(90deg, #9b59b6, #667eea, #e91e63, #9b59b6);
    background-size: 300% 100%;
    padding: 5px 12px;
    border-radius: 8px;
    font-size: 0.65rem;
    font-weight: bold;
    color: #fff;
    white-space: nowrap;
    letter-spacing: 0.5px;
    animation: shimmerBadge 3s linear infinite;
    box-shadow: 0 2px 8px rgba(155, 89, 182, 0.5);
    z-index: 20;
}

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

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

/* Анімація кастомізації */
.custom-spin-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.95);
    z-index: 99999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.custom-spin-portal {
    width: 200px;
    height: 200px;
    position: relative;
}

.custom-spin-ring {
    position: absolute;
    border-radius: 50%;
    border: 3px solid transparent;
}

.custom-spin-ring:nth-child(1) {
    width: 100%;
    height: 100%;
    border-top-color: #ff00ff;
    border-bottom-color: #667eea;
    animation: portalSpin 1.5s linear infinite;
}

.custom-spin-ring:nth-child(2) {
    width: 80%;
    height: 80%;
    top: 10%;
    left: 10%;
    border-left-color: #e91e63;
    border-right-color: #9b59b6;
    animation: portalSpin 1.2s linear infinite reverse;
}

.custom-spin-ring:nth-child(3) {
    width: 60%;
    height: 60%;
    top: 20%;
    left: 20%;
    border-top-color: #667eea;
    border-bottom-color: #ff00ff;
    animation: portalSpin 0.9s linear infinite;
}

.custom-spin-center {
    position: absolute;
    width: 40%;
    height: 40%;
    top: 30%;
    left: 30%;
    background: radial-gradient(circle, #ff00ff55, #667eea33, transparent);
    border-radius: 50%;
    animation: portalPulse 0.8s ease-in-out infinite;
}

.custom-spin-icon {
    position: absolute;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    animation: iconFloat 1s ease-in-out infinite;
}

@keyframes portalSpin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

@keyframes portalPulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 0.5;
    }

    50% {
        transform: scale(1.3);
        opacity: 1;
    }
}

@keyframes iconFloat {

    0%,
    100% {
        transform: translateY(0) scale(1);
    }

    50% {
        transform: translateY(-10px) scale(1.1);
    }
}

/* Мульти-відкриття кастомізації */
.custom-spin-multi-container {
    position: relative;
    width: 300px;
    height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.custom-spin-multi-ring {
    position: absolute;
    border-radius: 50%;
    border: 4px solid transparent;
    border-top-color: inherit;
    animation: portalSpin 2s linear infinite;
}

.custom-spin-multi-center {
    width: 120px;
    height: 120px;
    background: radial-gradient(circle, #ff00ff44, #667eea22, transparent);
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    animation: portalPulse 1s ease-in-out infinite;
    position: relative;
    z-index: 5;
}

.custom-spin-multi-icon {
    font-size: 3.5rem;
    filter: drop-shadow(0 0 15px #ff00ff);
}

.custom-spin-count-badge {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: #ff00ff;
    color: white;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 0.9rem;
    font-weight: 900;
    box-shadow: 0 0 10px rgba(255, 0, 255, 0.5);
}

.custom-spin-text {
    margin-top: 30px;
    font-size: 1.2rem;
    font-weight: bold;
    background: linear-gradient(90deg, #ff00ff, #667eea, #e91e63);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: textPulse 1s ease-in-out infinite;
}

@keyframes textPulse {

    0%,
    100% {
        opacity: 0.7;
    }

    50% {
        opacity: 1;
    }
}

.custom-reveal {
    animation: customReveal 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes customReveal {
    0% {
        transform: scale(0) rotate(-180deg);
        opacity: 0;
    }

    100% {
        transform: scale(1) rotate(0deg);
        opacity: 1;
    }
}

@keyframes fadeOut {
    0% {
        opacity: 1;
    }

    100% {
        opacity: 0;
    }
}

/* === ЗАВДАННЯ === */
/* === ЗАВДАННЯ - Premium Dark Gold Style (як Режими) === */
.tasks-grid {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.task-card {
    /* Glassmorphism base - як mode-tile */
    background: linear-gradient(145deg,
            rgba(25, 22, 20, 0.92) 0%,
            rgba(35, 30, 25, 0.88) 50%,
            rgba(20, 18, 15, 0.95) 100%);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);

    /* Layout */
    border-radius: 18px;
    padding: 18px 20px;
    margin-bottom: 0;
    display: flex;
    flex-direction: column;
    position: relative;
    cursor: pointer;
    overflow: hidden;

    /* Gold border */
    border: 1px solid rgba(212, 175, 85, 0.25);

    /* Premium shadow */
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.45),
        0 2px 8px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.05),
        inset 0 -1px 0 rgba(0, 0, 0, 0.2);

    /* Smooth transition */
    transition: all 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Top-left gold light reflection */
.task-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 60%;
    height: 50%;
    background: linear-gradient(135deg,
            rgba(212, 175, 85, 0.08) 0%,
            rgba(212, 175, 85, 0.03) 40%,
            transparent 70%);
    border-radius: 18px 0 0 0;
    pointer-events: none;
}

/* Glass shine effect */
.task-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 60%;
    height: 100%;
    background: linear-gradient(90deg,
            transparent 0%,
            rgba(255, 255, 255, 0.03) 50%,
            transparent 100%);
    transform: skewX(-20deg);
    pointer-events: none;
    transition: left 0.6s ease;
}

.task-card:hover::after {
    left: 150%;
}

.task-card:hover {
    transform: translateY(-3px);
    border-color: rgba(212, 175, 85, 0.45);
    box-shadow:
        0 12px 40px rgba(0, 0, 0, 0.5),
        0 4px 12px rgba(0, 0, 0, 0.35),
        0 0 30px rgba(212, 175, 85, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.task-card:active {
    transform: translateY(-1px) scale(0.985);
    transition: transform 0.1s;
}

/* Difficulty colors via accent glow */
.task-card.difficulty-green {
    --task-accent: #45bd64;
    --task-accent-rgb: 69, 189, 100;
}

.task-card.difficulty-yellow {
    --task-accent: #f2c94c;
    --task-accent-rgb: 242, 201, 76;
}

.task-card.difficulty-red {
    --task-accent: #e74c3c;
    --task-accent-rgb: 231, 76, 60;
}

/* Difficulty indicator - left border glow */
.task-card .task-difficulty-bar {
    position: absolute;
    top: 10%;
    left: 0;
    width: 4px;
    height: 80%;
    border-radius: 0 4px 4px 0;
    background: var(--task-accent, #d4af55);
    box-shadow: 0 0 12px var(--task-accent, #d4af55);
}

/* Ready state - pulsing green glow */
.task-card.ready {
    border-color: rgba(69, 189, 100, 0.5);
    animation: taskReadyPulse 2s ease-in-out infinite;
}

@keyframes taskReadyPulse {
    0%, 100% {
        box-shadow:
            0 8px 32px rgba(0, 0, 0, 0.45),
            0 0 20px rgba(69, 189, 100, 0.2);
    }
    50% {
        box-shadow:
            0 8px 32px rgba(0, 0, 0, 0.45),
            0 0 35px rgba(69, 189, 100, 0.4);
    }
}

/* Ready notification dot */
.task-card.ready .task-ready-dot {
    position: absolute;
    top: -4px;
    right: -4px;
    width: 14px;
    height: 14px;
    background: linear-gradient(135deg, #45bd64, #3aa856);
    border-radius: 50%;
    border: 2px solid rgba(25, 22, 20, 0.95);
    animation: readyDotPulse 1.5s ease-in-out infinite;
    z-index: 10;
    box-shadow: 0 0 10px rgba(69, 189, 100, 0.6);
}

@keyframes readyDotPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.2); }
}

/* Completed state */
.task-card.completed {
    opacity: 0.6;
    background: linear-gradient(145deg,
            rgba(20, 18, 15, 0.85) 0%,
            rgba(25, 22, 20, 0.8) 100%);
}

.task-card.completed .task-completed-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    padding: 5px 12px;
    background: linear-gradient(135deg, #45bd64, #3aa856);
    border-radius: 20px;
    color: white;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(69, 189, 100, 0.4);
}

/* Task header - horizontal layout */
.task-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 0;
    padding-left: 0;
}

/* Icon - large premium style */
.task-icon {
    font-size: 2.8rem;
    line-height: 1;
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.5));
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    position: relative;
    z-index: 2;
    flex-shrink: 0;
}

.task-card:hover .task-icon {
    transform: scale(1.08);
    filter: drop-shadow(0 6px 16px rgba(212, 175, 85, 0.25));
}

.task-info {
    flex: 1;
    z-index: 2;
    min-width: 0;
}

.task-name {
    font-size: 1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 4px;
    color: #f5e6c8;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.task-desc {
    font-size: 0.8rem;
    color: rgba(200, 190, 170, 0.8);
    line-height: 1.3;
}

/* Reward badge - gold style */
.task-reward {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.85rem;
    font-weight: 700;
    padding: 6px 12px;
    background: linear-gradient(135deg, rgba(212, 175, 85, 0.15), rgba(212, 175, 85, 0.05));
    border: 1px solid rgba(212, 175, 85, 0.3);
    border-radius: 20px;
    color: #d4af55;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    flex-shrink: 0;
}

/* Progress bar - gold style */
.task-progress-bar {
    height: 6px;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 10px;
    overflow: hidden;
    margin: 12px 0 4px 0;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.3);
}

.task-progress-fill {
    height: 100%;
    border-radius: 10px;
    transition: width 0.5s ease;
    box-shadow: 0 0 8px currentColor;
}

.task-progress-fill.green {
    background: linear-gradient(90deg, #45bd64, #3aa856);
    color: #45bd64;
}

.task-progress-fill.yellow {
    background: linear-gradient(90deg, #f2c94c, #d4af55);
    color: #f2c94c;
}

.task-progress-fill.red {
    background: linear-gradient(90deg, #e74c3c, #c0392b);
    color: #e74c3c;
}

.task-progress-text {
    font-size: 0.7rem;
    color: rgba(200, 190, 170, 0.6);
    text-align: right;
    font-weight: 600;
    margin-top: 4px;
}

/* Task buttons - premium gold style */
.task-claim-btn {
    padding: 12px 16px;
    border: none;
    border-radius: 10px;
    font-weight: 700;
    font-size: 0.85rem;
    cursor: pointer;
    margin-top: 12px;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    text-transform: uppercase;
    letter-spacing: 0.8px;
    position: relative;
    z-index: 2;
}

.task-card>.task-claim-btn,
.task-card>div[style*="display:flex"] {
    margin-left: 0;
    width: 100%;
}

.task-claim-btn.ready {
    background: linear-gradient(135deg, #45bd64, #3aa856);
    color: white;
    box-shadow:
        0 4px 15px rgba(69, 189, 100, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.task-claim-btn.ready:hover {
    box-shadow: 0 6px 25px rgba(69, 189, 100, 0.5);
    transform: translateY(-2px);
}

.task-claim-btn.ready:active {
    transform: translateY(0) scale(0.98);
}

.task-claim-btn.disabled {
    background: linear-gradient(135deg, rgba(212, 175, 85, 0.08), rgba(212, 175, 85, 0.03));
    color: rgba(200, 190, 170, 0.6);
    cursor: pointer;
    border: 1px solid rgba(212, 175, 85, 0.2);
}

.task-claim-btn.disabled:hover {
    background: linear-gradient(135deg, rgba(212, 175, 85, 0.15), rgba(212, 175, 85, 0.08));
    border-color: rgba(212, 175, 85, 0.35);
}

/* Task buttons row */
.task-buttons-row {
    display: flex;
    gap: 10px;
    margin-top: 12px;
}

.task-buttons-row .task-claim-btn {
    flex: 1;
    margin-top: 0;
}

/* Deprecated - legacy support */
.task-new-dot {
    display: none;
}

@keyframes taskPulse {

    0%,
    100% {
        box-shadow: 0 4px 20px rgba(69, 189, 100, 0.3), 0 0 0 0 rgba(69, 189, 100, 0.4);
    }

    50% {
        box-shadow: 0 4px 20px rgba(69, 189, 100, 0.4), 0 0 0 8px rgba(69, 189, 100, 0);
    }
}

@keyframes claimPulse {

    0%,
    100% {
        transform: scale(1);
        box-shadow: 0 4px 15px rgba(69, 189, 100, 0.4);
    }

    50% {
        transform: scale(1.02);
        box-shadow: 0 6px 20px rgba(69, 189, 100, 0.5);
    }
}

@keyframes newItemPulse {

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

    50% {
        transform: scale(1.3);
        opacity: 0.8;
    }
}

/* ========== РЕЖИМИ - PREMIUM DARK GLASSMORPHISM ========== */

.modes-grid {
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 8px;
}

.mode-tile {
    /* Glassmorphism base */
    background: linear-gradient(145deg,
            rgba(25, 22, 20, 0.92) 0%,
            rgba(35, 30, 25, 0.88) 50%,
            rgba(20, 18, 15, 0.95) 100%);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);

    /* Layout */
    border-radius: 18px;
    padding: 22px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    cursor: pointer;
    min-height: 95px;
    overflow: hidden;

    /* Gold border */
    border: 1px solid rgba(212, 175, 85, 0.25);

    /* Premium shadow */
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.45),
        0 2px 8px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.05),
        inset 0 -1px 0 rgba(0, 0, 0, 0.2);

    /* Smooth transition */
    transition: all 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Top-left gold light reflection */
.mode-tile::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 60%;
    height: 50%;
    background: linear-gradient(135deg,
            rgba(212, 175, 85, 0.08) 0%,
            rgba(212, 175, 85, 0.03) 40%,
            transparent 70%);
    border-radius: 18px 0 0 0;
    pointer-events: none;
}

/* Glass shine effect */
.mode-tile::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 60%;
    height: 100%;
    background: linear-gradient(90deg,
            transparent 0%,
            rgba(255, 255, 255, 0.03) 50%,
            transparent 100%);
    transform: skewX(-20deg);
    pointer-events: none;
    transition: left 0.6s ease;
}

.mode-tile:hover::after {
    left: 150%;
}

/* Hover state */
.mode-tile:hover {
    transform: translateY(-3px);
    border-color: rgba(212, 175, 85, 0.45);
    box-shadow:
        0 12px 40px rgba(0, 0, 0, 0.5),
        0 4px 12px rgba(0, 0, 0, 0.35),
        0 0 30px rgba(212, 175, 85, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.mode-tile:active {
    transform: translateY(-1px) scale(0.985);
    transition: transform 0.1s;
}

/* Subtle gold glow on hover */
.mode-glow {
    position: absolute;
    inset: -1px;
    border-radius: 18px;
    background: radial-gradient(ellipse at 30% 20%,
            rgba(212, 175, 85, 0.15) 0%,
            transparent 60%);
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.mode-tile:hover .mode-glow {
    opacity: 1;
}

/* Mode-specific accent colors */
.mode-contracts {
    --accent-color: #d4af55;
    --accent-rgb: 212, 175, 85;
}

.mode-2048 {
    --accent-color: #e8c547;
    --accent-rgb: 232, 197, 71;
}

.mode-battles {
    --accent-color: #c9a84d;
    --accent-rgb: 201, 168, 77;
}

.mode-wheel {
    --accent-color: #f2c94c;
    --accent-rgb: 242, 201, 76;
}

/* Icon wrapper - premium style */
.mode-icon-wrap {
    font-size: 3.8rem;
    line-height: 1;
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.5));
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    position: relative;
    z-index: 2;
}

/* Subtle gold tint on icon */
.mode-icon-wrap::after {
    content: '';
    position: absolute;
    inset: -10px;
    background: radial-gradient(circle,
            rgba(212, 175, 85, 0.1) 0%,
            transparent 70%);
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
}

.mode-tile:hover .mode-icon-wrap {
    transform: scale(1.08) translateX(-4px);
    filter: drop-shadow(0 6px 16px rgba(212, 175, 85, 0.25));
}

.mode-tile:hover .mode-icon-wrap::after {
    opacity: 1;
}

/* Info section */
.mode-info {
    flex: 1;
    z-index: 2;
    padding-right: 12px;
}

/* Title - warm gold/white */
.mode-title {
    font-size: 1.15rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 6px;
    color: #f5e6c8;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* Individual mode title accents */
.mode-contracts .mode-title {
    background: linear-gradient(135deg, #f5e6c8 0%, #d4af55 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.mode-2048 .mode-title {
    background: linear-gradient(135deg, #f5e6c8 0%, #e8c547 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.mode-battles .mode-title {
    background: linear-gradient(135deg, #f5e6c8 0%, #c9a84d 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.mode-wheel .mode-title {
    background: linear-gradient(135deg, #fff8e7 0%, #f2c94c 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Description - soft warm white */
.mode-desc {
    font-size: 0.82rem;
    color: rgba(245, 235, 220, 0.6);
    margin-bottom: 10px;
    letter-spacing: 0.3px;
}

/* Badge - glass pill */
.mode-badge {
    display: inline-flex;
    align-items: center;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    background: rgba(212, 175, 85, 0.12);
    color: rgba(212, 175, 85, 0.9);
    border: 1px solid rgba(212, 175, 85, 0.2);
    backdrop-filter: blur(8px);
    text-transform: uppercase;
}

/* Coming soon badge */
.mode-badge-coming {
    background: rgba(100, 100, 100, 0.15);
    color: rgba(180, 180, 180, 0.6);
    border-color: rgba(120, 120, 120, 0.15);
}

/* Contract highlight animation */
.mode-tile.contract-highlight {
    border-color: rgba(212, 175, 85, 0.6);
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.45),
        0 0 40px rgba(212, 175, 85, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

/* Wheel of Fortune - special premium treatment */
.mode-wheel {
    background: linear-gradient(145deg,
            rgba(30, 25, 20, 0.94) 0%,
            rgba(25, 22, 18, 0.92) 50%,
            rgba(20, 18, 15, 0.96) 100%);
    border-color: rgba(242, 201, 76, 0.35);
}

.mode-wheel:hover {
    border-color: rgba(242, 201, 76, 0.55);
    box-shadow:
        0 12px 40px rgba(0, 0, 0, 0.5),
        0 0 50px rgba(242, 201, 76, 0.1);
}

.mode-wheel .mode-glow {
    background: radial-gradient(ellipse at 30% 30%,
            rgba(242, 201, 76, 0.12) 0%,
            transparent 60%);
}

@keyframes wheelGlowPulse {

    0%,
    100% {
        opacity: 0.6;
        transform: scale(1);
    }

    50% {
        opacity: 1;
        transform: scale(1.1);
    }
}

.wheel-mini-mode {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: conic-gradient(#e74c3c 0deg 45deg,
            #f2c94c 45deg 90deg,
            #27ae60 90deg 135deg,
            #3498db 135deg 180deg,
            #9b59b6 180deg 225deg,
            #e67e22 225deg 270deg,
            #1abc9c 270deg 315deg,
            #e91e63 315deg 360deg);
    animation: wheelRotateSlow 8s linear infinite;
    position: relative;
    border: 3px solid #fff;
    box-shadow: 0 0 15px rgba(242, 201, 76, 0.5);
}

.wheel-mini-inner-mode {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 16px;
    height: 16px;
    background: linear-gradient(145deg, #f2c94c, #d4a834);
    border-radius: 50%;
    border: 2px solid #fff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

@keyframes wheelRotateSlow {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

.wheel-icon-animated {
    position: relative;
}

.wheel-icon-animated::after {
    content: '▼';
    position: absolute;
    top: -8px;
    left: 50%;
    transform: translateX(-50%);
    color: #f2c94c;
    font-size: 14px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    animation: pointerBounce 1s ease-in-out infinite;
}

@keyframes pointerBounce {

    0%,
    100% {
        transform: translateX(-50%) translateY(0);
    }

    50% {
        transform: translateX(-50%) translateY(3px);
    }
}

/* Hot badge - premium gold */
.mode-badge-hot {
    background: linear-gradient(135deg, rgba(242, 201, 76, 0.25) 0%, rgba(212, 165, 55, 0.2) 100%);
    color: #f2c94c;
    font-weight: 700;
    border: 1px solid rgba(242, 201, 76, 0.4);
    box-shadow: 0 2px 12px rgba(242, 201, 76, 0.15);
    animation: premiumBadgePulse 3s ease-in-out infinite;
}

@keyframes premiumBadgePulse {

    0%,
    100% {
        box-shadow: 0 2px 12px rgba(242, 201, 76, 0.15);
        border-color: rgba(242, 201, 76, 0.4);
    }

    50% {
        box-shadow: 0 2px 20px rgba(242, 201, 76, 0.25);
        border-color: rgba(242, 201, 76, 0.55);
    }
}

@keyframes contractHighlight {

    0%,
    100% {
        box-shadow: 0 0 25px rgba(231, 76, 60, 0.6);
        transform: scale(1.03);
    }

    50% {
        box-shadow: 0 0 40px rgba(231, 76, 60, 0.9), 0 0 20px rgba(242, 201, 76, 0.4);
        transform: scale(1.05);
    }
}

/* === ПРОФІЛЬ - Premium Dark Gold Style === */
.profile-head {
    text-align: center;
    margin-bottom: 20px;
    overflow: visible;
    padding-top: 35px;
}

.profile-head.profile-premium {
    /* Glassmorphism base - як mode-tile */
    background: linear-gradient(145deg,
            rgba(25, 22, 20, 0.95) 0%,
            rgba(35, 30, 25, 0.92) 50%,
            rgba(20, 18, 15, 0.98) 100%);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);

    /* Layout */
    border-radius: 20px;
    padding: 24px;
    margin: 0 8px 20px 8px;
    position: relative;
    overflow: hidden;

    /* Gold border */
    border: 1px solid rgba(212, 175, 85, 0.25);

    /* Premium shadow */
    box-shadow:
        0 8px 40px rgba(0, 0, 0, 0.5),
        0 2px 8px rgba(0, 0, 0, 0.35),
        inset 0 1px 0 rgba(255, 255, 255, 0.05),
        inset 0 -1px 0 rgba(0, 0, 0, 0.2);

    transition: all 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Gold glow effect */
.profile-gold-glow {
    position: absolute;
    inset: -1px;
    border-radius: 20px;
    background: radial-gradient(ellipse at 50% 0%,
            rgba(212, 175, 85, 0.12) 0%,
            transparent 60%);
    pointer-events: none;
    z-index: 0;
}

/* Top-left gold reflection */
.profile-gold-reflection {
    position: absolute;
    top: 0;
    left: 0;
    right: 50%;
    height: 40%;
    background: linear-gradient(135deg,
            rgba(212, 175, 85, 0.08) 0%,
            rgba(212, 175, 85, 0.03) 40%,
            transparent 70%);
    border-radius: 20px 0 0 0;
    pointer-events: none;
    z-index: 0;
}

/* Кнопки керування */
.profile-actions-top {
    position: absolute;
    top: 14px;
    right: 14px;
    display: flex;
    gap: 8px;
    z-index: 5;
}

.profile-action-btn {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    backdrop-filter: blur(10px);
    border: 1px solid;
}

.profile-action-edit {
    background: linear-gradient(135deg, rgba(212, 175, 85, 0.15), rgba(212, 175, 85, 0.05));
    border-color: rgba(212, 175, 85, 0.3);
    color: #d4af55;
}

.profile-action-settings {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03));
    border-color: rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.8);
}

.profile-action-btn:hover {
    transform: scale(1.08);
}

.profile-action-edit:hover {
    border-color: rgba(212, 175, 85, 0.5);
    box-shadow: 0 0 15px rgba(212, 175, 85, 0.2);
}

.profile-action-settings:hover {
    border-color: rgba(255, 255, 255, 0.3);
}

/* Аватар секція */
.profile-avatar-section {
    text-align: center;
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
}

.profile-premium .avatar {
    width: 95px;
    height: 95px;
    border-radius: 50%;
    margin: 0 auto 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.8rem;
    background-size: cover;
    background-position: center;
    border: 3px solid rgba(212, 175, 85, 0.4);
    box-shadow:
        0 6px 25px rgba(0, 0, 0, 0.4),
        0 0 20px rgba(212, 175, 85, 0.15);
    transition: all 0.3s;
}

.profile-username {
    margin: 0;
    text-align: center;
    font-size: 1.5rem;
    font-weight: 700;
    color: #f5e6c8;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
    letter-spacing: 0.5px;
}

.profile-id-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 8px;
}

.profile-id-badge {
    color: rgba(200, 190, 170, 0.7);
    font-size: 0.75rem;
    display: flex;
    align-items: center;
    gap: 6px;
    background: rgba(0, 0, 0, 0.3);
    padding: 5px 12px;
    border-radius: 14px;
    border: 1px solid rgba(212, 175, 85, 0.15);
}

.profile-id-toggle {
    background: none;
    border: none;
    color: rgba(200, 190, 170, 0.5);
    font-size: 0.8rem;
    cursor: pointer;
    padding: 0 2px;
    transition: color 0.2s;
}

.profile-id-toggle:hover {
    color: #d4af55;
}

/* Рівень картка */
.profile-level-card {
    margin-top: 16px;
    position: relative;
    z-index: 1;
    background: linear-gradient(145deg, rgba(0, 0, 0, 0.35), rgba(0, 0, 0, 0.25));
    backdrop-filter: blur(10px);
    padding: 14px 16px;
    border-radius: 14px;
    border: 1px solid rgba(212, 175, 85, 0.2);
    cursor: pointer;
    transition: all 0.3s;
}

.profile-level-card:hover {
    border-color: rgba(212, 175, 85, 0.4);
    transform: translateY(-2px);
}

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

.profile-level-num {
    font-size: 1.2rem;
    font-weight: 800;
    min-width: 28px;
    text-align: center;
}

.profile-level-current {
    color: #d4af55;
    text-shadow: 0 2px 8px rgba(212, 175, 85, 0.4);
}

.profile-level-next {
    color: rgba(200, 190, 170, 0.5);
}

.profile-level-progress {
    flex: 1;
}

.profile-level-bar {
    height: 8px;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 6px;
    overflow: hidden;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.3);
}

.profile-level-fill {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, #d4af55, #f2c94c);
    border-radius: 6px;
    transition: width 0.4s ease;
    box-shadow: 0 0 10px rgba(212, 175, 85, 0.4);
}

.profile-level-info {
    display: flex;
    justify-content: space-between;
    margin-top: 5px;
}

.profile-xp-text {
    font-size: 0.7rem;
    color: rgba(200, 190, 170, 0.5);
}

.profile-xp-current {
    color: rgba(200, 190, 170, 0.8);
}

.profile-level-hint {
    font-size: 0.65rem;
    color: rgba(200, 190, 170, 0.4);
}

/* Статистика */
.profile-stats-row {
    margin-top: 16px;
    position: relative;
    z-index: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 24px;
    background: linear-gradient(145deg, rgba(0, 0, 0, 0.3), rgba(0, 0, 0, 0.2));
    padding: 14px 20px;
    border-radius: 14px;
    border: 1px solid rgba(212, 175, 85, 0.15);
}

.profile-stat-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.profile-stat-icon {
    font-size: 1rem;
}

.profile-stat-value {
    font-weight: 700;
    font-size: 1rem;
}

.profile-stat-spins {
    color: #d4af55;
}

.profile-stat-best {
    color: #f2c94c;
}

.profile-stat-label {
    font-size: 0.7rem;
    color: rgba(200, 190, 170, 0.5);
}

.profile-stat-divider {
    width: 1px;
    height: 24px;
    background: rgba(212, 175, 85, 0.2);
}

/* Друзі та Реферали */
.profile-social-row {
    margin-top: 14px;
    position: relative;
    z-index: 1;
    display: flex;
    gap: 12px;
}

.profile-social-btn {
    flex: 1;
    background: linear-gradient(145deg, rgba(0, 0, 0, 0.3), rgba(0, 0, 0, 0.2));
    backdrop-filter: blur(10px);
    border: 1px solid rgba(212, 175, 85, 0.2);
    padding: 14px;
    border-radius: 14px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.profile-social-btn:hover {
    transform: translateY(-2px);
    border-color: rgba(212, 175, 85, 0.4);
}

.profile-social-icon {
    font-size: 1.2rem;
}

.profile-social-text {
    color: #f5e6c8;
    font-weight: 600;
    font-size: 0.9rem;
}

.profile-social-count {
    padding: 3px 10px;
    border-radius: 10px;
    font-size: 0.75rem;
    font-weight: 700;
}

.profile-social-count-friends {
    background: rgba(212, 175, 85, 0.2);
    color: #d4af55;
}

.profile-social-count-refs {
    background: rgba(242, 201, 76, 0.2);
    color: #f2c94c;
}

/* Рекорд 2048 */
.profile-record-2048 {
    display: none;
    margin-top: 14px;
    position: relative;
    z-index: 1;
    background: linear-gradient(145deg, rgba(0, 0, 0, 0.3), rgba(0, 0, 0, 0.2));
    backdrop-filter: blur(10px);
    padding: 14px 18px;
    border-radius: 14px;
    border: 1px solid rgba(237, 194, 46, 0.25);
    align-items: center;
    justify-content: space-between;
}

.profile-record-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.profile-record-icon {
    font-size: 1.2rem;
}

.profile-record-label {
    font-weight: 600;
    color: #f5e6c8;
    font-size: 0.9rem;
}

.profile-record-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.profile-record-value {
    font-weight: 800;
    color: #edc22e;
    font-size: 1.15rem;
    text-shadow: 0 2px 8px rgba(237, 194, 46, 0.3);
}

.profile-record-rank {
    background: linear-gradient(135deg, #edc22e, #d4a520);
    color: #000;
    padding: 3px 10px;
    border-radius: 10px;
    font-size: 0.75rem;
    font-weight: 800;
    box-shadow: 0 2px 10px rgba(237, 194, 46, 0.3);
}

/* Інвентар секція */
.profile-inventory-section {
    margin: 0 8px;
}

.profile-inventory-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
}

.profile-inventory-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.15rem;
    font-weight: 700;
    color: #f5e6c8;
    letter-spacing: 0.5px;
}

.profile-inventory-icon {
    font-size: 1.3rem;
    filter: drop-shadow(0 2px 6px rgba(212, 175, 85, 0.3));
}

.profile-inventory-count {
    color: #d4af55;
    font-size: 0.85rem;
    font-weight: 600;
    background: linear-gradient(135deg, rgba(212, 175, 85, 0.15), rgba(212, 175, 85, 0.05));
    border: 1px solid rgba(212, 175, 85, 0.25);
    padding: 5px 14px;
    border-radius: 14px;
}

.profile-contract-btn {
    background: linear-gradient(135deg, rgba(212, 175, 85, 0.2), rgba(212, 175, 85, 0.1));
    color: #d4af55;
    padding: 10px 18px;
    border: 1px solid rgba(212, 175, 85, 0.3);
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.3s;
}

.profile-contract-btn:hover {
    background: linear-gradient(135deg, rgba(212, 175, 85, 0.3), rgba(212, 175, 85, 0.15));
    border-color: rgba(212, 175, 85, 0.5);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(212, 175, 85, 0.2);
}

.profile-sell-all-btn {
    display: none;
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #45bd64, #3aa856);
    border: none;
    border-radius: 14px;
    color: white;
    font-weight: bold;
    font-size: 1rem;
    margin-bottom: 14px;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(69, 189, 100, 0.3);
    transition: all 0.3s;
}

.profile-sell-all-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(69, 189, 100, 0.4);
}

.profile-inventory-grid {
    background: transparent !important;
    border-radius: 0 !important;
    padding: 0 !important;
    min-height: 200px;
}

.profile-inventory-empty {
    grid-column: 1 / -1;
    text-align: center;
    color: rgba(200, 190, 170, 0.5);
    padding: 50px 20px;
    font-size: 0.9rem;
    background: linear-gradient(145deg, rgba(25, 22, 20, 0.9), rgba(35, 30, 25, 0.85));
    border-radius: 16px;
    border: 1px solid rgba(212, 175, 85, 0.15);
}

.avatar {
    width: 70px;
    height: 70px;
    background: #333;
    border-radius: 50%;
    margin: 0 auto 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
}

/* Особливі ефекти для бейджів Дракон та Єдиноріг */
.profile-badge-icon.badge-dragon-effect {
    animation: dragonPulse 2s ease-in-out infinite;
    filter: drop-shadow(0 0 8px rgba(255, 87, 34, 0.8)) drop-shadow(0 0 12px rgba(255, 152, 0, 0.6));
}

@keyframes dragonPulse {

    0%,
    100% {
        transform: scale(1);
        filter: drop-shadow(0 0 8px rgba(255, 87, 34, 0.8)) drop-shadow(0 0 12px rgba(255, 152, 0, 0.6));
    }

    50% {
        transform: scale(1.15);
        filter: drop-shadow(0 0 12px rgba(255, 87, 34, 1)) drop-shadow(0 0 18px rgba(255, 152, 0, 0.8));
    }
}

.profile-dragon-effect {
    position: absolute;
    inset: -10px;
    border-radius: 20px;
    background: linear-gradient(45deg, rgba(255, 87, 34, 0.2), rgba(255, 152, 0, 0.2), rgba(255, 87, 34, 0.2));
    background-size: 200% 200%;
    animation: dragonFlame 3s ease-in-out infinite;
    pointer-events: none;
    z-index: 0;
    filter: blur(8px);
}

@keyframes dragonFlame {

    0%,
    100% {
        background-position: 0% 50%;
        opacity: 0.6;
    }

    50% {
        background-position: 100% 50%;
        opacity: 0.8;
    }
}

.profile-badge-icon.badge-unicorn-effect {
    animation: unicornSparkle 2.5s ease-in-out infinite;
    filter: drop-shadow(0 0 8px rgba(255, 20, 147, 0.8)) drop-shadow(0 0 12px rgba(138, 43, 226, 0.6)) drop-shadow(0 0 16px rgba(30, 144, 255, 0.5));
}

@keyframes unicornSparkle {

    0%,
    100% {
        transform: scale(1) rotate(0deg);
        filter: drop-shadow(0 0 8px rgba(255, 20, 147, 0.8)) drop-shadow(0 0 12px rgba(138, 43, 226, 0.6)) drop-shadow(0 0 16px rgba(30, 144, 255, 0.5));
    }

    25% {
        transform: scale(1.1) rotate(-5deg);
        filter: drop-shadow(0 0 10px rgba(255, 20, 147, 1)) drop-shadow(0 0 14px rgba(138, 43, 226, 0.8)) drop-shadow(0 0 18px rgba(30, 144, 255, 0.7));
    }

    50% {
        transform: scale(1.15) rotate(0deg);
        filter: drop-shadow(0 0 12px rgba(255, 20, 147, 1)) drop-shadow(0 0 16px rgba(138, 43, 226, 0.9)) drop-shadow(0 0 20px rgba(30, 144, 255, 0.8));
    }

    75% {
        transform: scale(1.1) rotate(5deg);
        filter: drop-shadow(0 0 10px rgba(255, 20, 147, 1)) drop-shadow(0 0 14px rgba(138, 43, 226, 0.8)) drop-shadow(0 0 18px rgba(30, 144, 255, 0.7));
    }
}

@keyframes goldPulse {
    from {
        box-shadow: 0 0 10px rgba(237, 194, 46, 0.5);
    }

    to {
        box-shadow: 0 0 20px rgba(237, 194, 46, 0.9);
    }
}

.profile-unicorn-effect {
    position: absolute;
    inset: -10px;
    border-radius: 20px;
    background: linear-gradient(135deg, rgba(255, 20, 147, 0.15), rgba(138, 43, 226, 0.15), rgba(30, 144, 255, 0.15), rgba(255, 20, 147, 0.15));
    background-size: 300% 300%;
    animation: unicornRainbow 4s ease-in-out infinite;
    pointer-events: none;
    z-index: 0;
    filter: blur(10px);
}

@keyframes unicornRainbow {
    0% {
        background-position: 0% 50%;
        opacity: 0.5;
    }

    50% {
        background-position: 100% 50%;
        opacity: 0.8;
    }

    100% {
        background-position: 0% 50%;
        opacity: 0.5;
    }
}

.stats-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.stat-box {
    background: var(--card-bg);
    padding: 15px;
    border-radius: 10px;
    text-align: center;
}

.profile-head .stat-box {
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.profile-head .stats-row {
    position: relative;
    z-index: 2;
}

.profile-head>div:first-child {
    position: relative;
    z-index: 2;
}

.profile-head .avatar {
    position: relative;
    z-index: 2;
}

.profile-head .avatar-container {
    position: relative;
    z-index: 2;
    display: inline-block;
    overflow: visible;
}

.profile-head h2 {
    position: relative;
    z-index: 2;
}

.profile-head .level-progress-container {
    position: relative;
    z-index: 2;
}

.stat-val {
    font-size: 1.2rem;
    font-weight: bold;
}

.stat-lbl {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

/* Лідерборд */
.leaderboard-section {
    margin-top: 20px;
}

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

.leaderboard-title {
    color: var(--text-secondary);
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 6px;
}

.leaderboard-refresh {
    background: var(--card-bg);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--accent);
    padding: 5px 10px;
    border-radius: 8px;
    font-size: 0.75rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 4px;
}

.leaderboard-refresh:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.leaderboard-tabs {
    display: flex;
    gap: 6px;
    margin-bottom: 12px;
    overflow-x: auto;
    padding-bottom: 5px;
}

.leaderboard-tab {
    background: var(--card-bg);
    border: none;
    padding: 8px 12px;
    border-radius: 20px;
    color: var(--text-secondary);
    font-size: 0.75rem;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s;
}

.leaderboard-tab.active {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
}

.leaderboard-list {
    background: var(--card-bg);
    border-radius: 12px;
    overflow: hidden;
}

.leaderboard-item {
    display: flex;
    align-items: center;
    padding: 10px 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.leaderboard-item:last-child {
    border-bottom: none;
}

.leaderboard-rank {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.85rem;
    margin-right: 10px;
}

.leaderboard-rank.rank-1 {
    background: linear-gradient(135deg, #f2c94c, #d4a520);
    color: #000;
}

.leaderboard-rank.rank-2 {
    background: linear-gradient(135deg, #c0c0c0, #a8a8a8);
    color: #000;
}

.leaderboard-rank.rank-3 {
    background: linear-gradient(135deg, #cd7f32, #a66628);
    color: #fff;
}

.leaderboard-rank.rank-other {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-secondary);
}

.leaderboard-name {
    flex: 1;
    font-size: 0.9rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.leaderboard-value {
    font-weight: bold;
    color: var(--gold);
    font-size: 0.9rem;
}

.leaderboard-empty {
    text-align: center;
    padding: 20px;
    color: var(--text-secondary);
    font-size: 0.85rem;
}

.leaderboard-month {
    font-size: 0.7rem;
    color: var(--text-secondary);
    text-align: center;
    margin-top: 8px;
}

/* === ІНВЕНТАР - Premium Dark Gold Style === */
.inventory-section-premium {
    margin: 0 8px;
    padding: 0;
}

.inventory-header-premium {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding: 0;
}

.inventory-title-premium {
    display: flex;
    align-items: center;
    gap: 12px;
}

.inventory-icon-wrap {
    width: 44px;
    height: 44px;
    background: linear-gradient(145deg, rgba(25, 22, 20, 0.95), rgba(35, 30, 25, 0.9));
    border: 1px solid rgba(212, 175, 85, 0.3);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    filter: drop-shadow(0 2px 8px rgba(212, 175, 85, 0.2));
}

.inventory-title-text {
    font-size: 1.2rem;
    font-weight: 700;
    color: #f5e6c8;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.inventory-subtitle {
    font-size: 0.7rem;
    color: rgba(200, 190, 170, 0.5);
    margin-top: 2px;
}

.inventory-count-badge {
    color: #d4af55;
    font-size: 0.85rem;
    font-weight: 700;
    background: linear-gradient(135deg, rgba(212, 175, 85, 0.15), rgba(212, 175, 85, 0.05));
    border: 1px solid rgba(212, 175, 85, 0.3);
    padding: 6px 14px;
    border-radius: 14px;
}

.inventory-contract-btn {
    background: linear-gradient(145deg, rgba(212, 175, 85, 0.15), rgba(212, 175, 85, 0.08));
    color: #d4af55;
    padding: 10px 18px;
    border: 1px solid rgba(212, 175, 85, 0.3);
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    display: flex;
    align-items: center;
    gap: 6px;
}

.inventory-contract-btn:hover {
    background: linear-gradient(145deg, rgba(212, 175, 85, 0.25), rgba(212, 175, 85, 0.15));
    border-color: rgba(212, 175, 85, 0.5);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(212, 175, 85, 0.2);
}

.inventory-sell-btn {
    display: none;
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #45bd64, #3aa856);
    border: none;
    border-radius: 14px;
    color: white;
    font-weight: bold;
    font-size: 1rem;
    margin-bottom: 14px;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(69, 189, 100, 0.3);
    transition: all 0.3s;
}

.inventory-sell-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(69, 189, 100, 0.4);
}

.inventory-grid-premium {
    background: transparent !important;
    border-radius: 0 !important;
    padding: 0 !important;
    min-height: 200px;
}

.inventory-empty-premium {
    grid-column: 1 / -1;
    text-align: center;
    color: rgba(200, 190, 170, 0.5);
    padding: 50px 20px;
    font-size: 0.9rem;
    background: linear-gradient(145deg, rgba(25, 22, 20, 0.9), rgba(35, 30, 25, 0.85));
    border-radius: 18px;
    border: 1px solid rgba(212, 175, 85, 0.15);
}

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

/* Inventory item - Premium Dark Gold Style */
.inventory-item {
    background: linear-gradient(145deg,
            rgba(25, 22, 20, 0.95) 0%,
            rgba(35, 30, 25, 0.9) 50%,
            rgba(20, 18, 15, 0.95) 100%);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 16px;
    padding: 14px 10px;
    text-align: center;
    border: 1px solid rgba(212, 175, 85, 0.2);
    transition: all 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    box-shadow:
        0 6px 24px rgba(0, 0, 0, 0.4),
        0 2px 6px rgba(0, 0, 0, 0.25),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
    position: relative;
    overflow: hidden;
}

/* Top-left gold reflection */
.inventory-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 60%;
    height: 50%;
    background: linear-gradient(135deg,
            rgba(212, 175, 85, 0.1) 0%,
            rgba(212, 175, 85, 0.03) 40%,
            transparent 70%);
    border-radius: 16px 0 0 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

/* Glass shine effect on hover */
.inventory-item::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 60%;
    height: 100%;
    background: linear-gradient(90deg,
            transparent 0%,
            rgba(255, 255, 255, 0.04) 50%,
            transparent 100%);
    transform: skewX(-20deg);
    pointer-events: none;
    transition: left 0.5s ease;
}

.inventory-item:hover {
    transform: translateY(-4px) scale(1.02);
    border-color: rgba(212, 175, 85, 0.45);
    box-shadow:
        0 10px 35px rgba(0, 0, 0, 0.5),
        0 4px 10px rgba(0, 0, 0, 0.3),
        0 0 25px rgba(212, 175, 85, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.inventory-item:hover::before {
    opacity: 1;
}

.inventory-item:hover::after {
    left: 150%;
}

.inventory-item:active {
    transform: scale(0.98) translateY(-2px);
}

.inventory-item.selected {
    border-color: var(--gold);
    box-shadow: 0 0 24px rgba(242, 201, 76, 0.7), 0 6px 20px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.2);
    background: linear-gradient(135deg, rgba(242, 201, 76, 0.2), rgba(242, 201, 76, 0.1));
}

.inventory-item.selected::before {
    opacity: 1;
    background: linear-gradient(135deg, rgba(242, 201, 76, 0.25), rgba(242, 201, 76, 0.15));
}

.inventory-item.selected::after {
    opacity: 1;
    background: linear-gradient(135deg, rgba(242, 201, 76, 0.4), rgba(242, 201, 76, 0.3));
}

.inventory-icon {
    font-size: 2.8rem;
    margin-bottom: 10px;
    filter: drop-shadow(0 3px 10px rgba(0, 0, 0, 0.4));
    position: relative;
    z-index: 1;
    transition: transform 0.3s ease;
}

.inventory-item:hover .inventory-icon {
    transform: scale(1.1);
}

.inventory-name {
    font-size: 0.8rem;
    font-weight: 700;
    margin-bottom: 6px;
    line-height: 1.3;
    color: #fff;
    position: relative;
    z-index: 1;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}

.inventory-value {
    color: var(--gold);
    font-size: 0.8rem;
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    position: relative;
    z-index: 1;
}

.settings-modal,
.gift-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    z-index: 10001;
    overflow-y: auto;
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    /* Плавне відкриття без мигання */
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
    /* Для gift-modal - flex за замовчуванням */
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}

.settings-modal {
    display: block;
}

.settings-modal.active,
.gift-modal.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.settings-content {
    background: var(--bg-color);
    margin: 40px auto;
    max-width: 400px;
    border-radius: 12px;
    padding: 20px;
    position: relative;
}

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

.settings-title {
    font-size: 1.3rem;
    font-weight: bold;
}

.settings-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text-secondary);
    cursor: pointer;
}

.settings-item {
    background: var(--card-bg);
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.settings-label {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 500;
}

.settings-toggle {
    width: 50px;
    height: 28px;
    background: #333;
    border-radius: 14px;
    position: relative;
    cursor: pointer;
    transition: 0.3s;
}

.settings-toggle.active {
    background: var(--accent);
}

.settings-toggle-circle {
    width: 22px;
    height: 22px;
    background: white;
    border-radius: 50%;
    position: absolute;
    top: 3px;
    left: 3px;
    transition: 0.3s;
}

.settings-toggle.active .settings-toggle-circle {
    left: 25px;
}

.topup-banner {
    background: linear-gradient(135deg, rgba(82, 136, 193, 0.2), rgba(69, 189, 100, 0.2));
    border: 2px solid var(--accent);
    border-radius: 12px;
    padding: 15px;
    text-align: center;
    margin-bottom: 20px;
}

.topup-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 20px;
    touch-action: pan-y;
    overflow: visible;
    padding: 12px 8px;
}

.topup-card {
    background: var(--card-bg);
    border: 2px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 15px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
}

.topup-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: 0.6s;
}

.topup-card:hover::before {
    left: 100%;
}

.topup-card:active {
    transform: scale(0.96);
}

.topup-card .topup-icon {
    font-size: 2rem;
    margin-bottom: 5px;
    animation: topupFloat 3s ease-in-out infinite;
    will-change: transform;
}

@keyframes topupFloat {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-4px);
    }
}

.topup-card.topup-bonus {
    border-color: var(--green);
    background: linear-gradient(135deg, rgba(69, 189, 100, 0.1), rgba(69, 189, 100, 0.05));
}

.topup-card.topup-mega {
    border-color: var(--gold);
    background: linear-gradient(135deg, rgba(242, 201, 76, 0.15), rgba(242, 201, 76, 0.05));
    grid-column: 1 / -1;
    box-shadow: 0 0 20px rgba(242, 201, 76, 0.35);
}

.topup-card.topup-disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.topup-badge {
    position: absolute;
    top: -8px;
    right: 5px;
    background: var(--green);
    padding: 3px 8px;
    border-radius: 8px;
    font-size: 0.7rem;
    font-weight: bold;
    z-index: 2;
    white-space: nowrap;
}

.topup-mega .topup-badge {
    background: var(--gold);
    color: #000;
}

.topup-stars {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 5px;
}

.topup-equals {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 5px;
}

.topup-balance {
    font-size: 1.3rem;
    font-weight: bold;
    color: var(--gold);
}

.topup-info {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 15px;
    font-size: 0.85rem;
    line-height: 1.6;
}

.gift-modal-content {
    background: var(--bg-color);
    border-radius: 16px;
    padding: 0;
    max-width: 90%;
    width: 340px;
    position: relative;
    animation: slideUp 0.3s ease;
    overflow: visible;
    touch-action: pan-y;
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }

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

.gift-modal-header {
    text-align: center;
    padding: 25px 20px 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.gift-modal-icon {
    font-size: 4rem;
    margin-bottom: 10px;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-10px);
    }
}

.gift-modal-name {
    font-size: 1.2rem;
    font-weight: bold;
    margin-bottom: 5px;
}

.gift-modal-value {
    color: var(--gold);
    font-size: 1.1rem;
    font-weight: bold;
}

.gift-modal-actions {
    padding: 15px;
}

.gift-action-btn {
    background: var(--card-bg);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 15px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    transition: all 0.2s;
}

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

.gift-action-btn.sell {
    border-color: var(--green);
    background: linear-gradient(135deg, rgba(69, 189, 100, 0.1), rgba(69, 189, 100, 0.05));
}

.gift-action-btn.exchange {
    border-color: var(--accent);
}

.gift-action-btn.withdraw {
    border-color: var(--gold);
}

.gift-action-icon {
    font-size: 1.5rem;
    margin-right: 12px;
}

.gift-action-text {
    flex: 1;
}

.gift-action-title {
    font-weight: 600;
    margin-bottom: 3px;
}

.gift-action-desc {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.gift-action-arrow {
    color: var(--text-secondary);
    font-size: 1.2rem;
}

.gift-modal-close {
    background: var(--card-bg);
    border: none;
    border-radius: 12px;
    padding: 12px;
    width: 100%;
    color: var(--text-secondary);
    font-weight: 600;
    cursor: pointer;
}

/* Список друзів для подарунків */
.gift-friend-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 12px;
    margin-bottom: 8px;
    cursor: pointer;
    transition: all 0.2s;
}
.gift-friend-item:hover, .gift-friend-item:active {
    background: rgba(212,175,85,0.12);
    border-color: rgba(212,175,85,0.3);
}
.gift-friend-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea, #764ba2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    font-weight: bold;
    color: white;
    flex-shrink: 0;
}
.gift-friend-info {
    flex: 1;
    min-width: 0;
}
.gift-friend-name {
    font-weight: 600;
    font-size: 0.95rem;
    color: white;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.gift-friend-username {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-top: 2px;
}
.gift-friend-arrow {
    font-size: 1.2rem;
    color: var(--text-secondary);
    flex-shrink: 0;
}

/* Лог фільтри */
.log-filter-btn {
    padding: 6px 12px;
    background: var(--card-bg);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 20px;
    color: var(--text-secondary);
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s;
}
.log-filter-btn.active {
    background: rgba(102,126,234,0.2);
    border-color: var(--accent);
    color: white;
}

/* Тролінг - завантажені звуки */
.troll-uploaded-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    background: var(--card-bg);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 8px;
    margin-bottom: 6px;
    cursor: pointer;
    transition: all 0.2s;
}
.troll-uploaded-item:hover, .troll-uploaded-item.active {
    background: rgba(255,107,107,0.15);
    border-color: rgba(255,107,107,0.4);
}

#game-screen {
    display: none;
}

#game-title {
    color: #f5e6c8;
    font-weight: 700;
    letter-spacing: 1px;
}

#wheel-game-screen {
    display: none;
}

.back-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #d4af55;
    font-weight: 600;
    margin-bottom: 15px;
    cursor: pointer;
    transition: opacity 0.2s;
}

.back-btn:active {
    opacity: 0.7;
}

#roulette-container {
    margin-bottom: 20px;
    position: relative;
}

.roulette-wrapper {
    position: relative;
    overflow: hidden;
    /* ФАЗА 5: CSS mask замість ::before/::after градієнтів (GPU оптимізація) */
    -webkit-mask-image: linear-gradient(to right, transparent 0%, black 12%, black 88%, transparent 100%);
    mask-image: linear-gradient(to right, transparent 0%, black 12%, black 88%, transparent 100%);
}

/* ФАЗА 5: Видалено ::before/::after для кращого FPS - використовуємо mask вище */
/*
.roulette-wrapper::before,
.roulette-wrapper::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    width: 60px;
    z-index: 10;
    pointer-events: none;
}

.roulette-wrapper::before {
    left: 0;
    background: linear-gradient(to right, var(--bg-color) 0%, transparent 100%);
}

.roulette-wrapper::after {
    right: 0;
    background: linear-gradient(to left, var(--bg-color) 0%, transparent 100%);
}
*/

.win-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: fadeIn 0.3s;
}

.win-modal {
    background: linear-gradient(145deg,
            rgba(25, 22, 20, 0.96) 0%,
            rgba(35, 30, 25, 0.94) 50%,
            rgba(20, 18, 15, 0.98) 100%);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 20px;
    padding: 30px;
    text-align: center;
    max-width: 300px;
    width: 90%;
    animation: scaleIn 0.3s;
    border: 1px solid rgba(212, 175, 85, 0.4);
    box-shadow:
        0 12px 40px rgba(0, 0, 0, 0.6),
        0 0 30px rgba(212, 175, 85, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.win-modal-icon {
    font-size: 4rem;
    margin-bottom: 15px;
    animation: bounceIn 0.5s;
}

.win-modal-title {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 10px;
    color: var(--gold);
}

.win-modal-content {
    font-size: 1.1rem;
    margin-bottom: 20px;
    line-height: 1.6;
}

.win-modal-stars {
    color: var(--gold);
    font-weight: bold;
    font-size: 1.3rem;
}

.win-modal-fragments {
    color: #82ccdd;
    font-weight: bold;
}

.win-modal-btn {
    background: linear-gradient(135deg, rgba(212, 175, 85, 0.25), rgba(212, 175, 85, 0.1));
    border: 1px solid rgba(212, 175, 85, 0.5);
    padding: 12px 24px;
    border-radius: 14px;
    color: #f5e6c8;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    min-width: 100px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3), 0 0 10px rgba(212, 175, 85, 0.1);
    transition: all 0.2s;
}

.win-modal-btn:active {
    transform: scale(0.97);
}

/* Піраміда подарунків */
.win-gifts-pyramid {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.win-gifts-row {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.win-gift-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.win-gift-name {
    font-weight: bold;
    font-size: 0.85rem;
    margin-top: 2px;
    color: var(--gold);
}

@keyframes bounceIn {
    0% {
        transform: scale(0);
    }

    50% {
        transform: scale(1.2);
    }

    100% {
        transform: scale(1);
    }
}

@keyframes scaleIn {
    from {
        transform: scale(0.8);
        opacity: 0;
    }

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

.layout-single .roulette-box {
    width: 100%;
    height: 130px;
}

.layout-vertical {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.layout-vertical .roulette-box {
    width: 100%;
    height: 80px;
}

.roulette-box {
    opacity: 0;
    transform: translateY(20px) scale(0.95);
    animation: reelAppear 0.4s ease forwards;
}

.roulette-box:nth-child(1) {
    animation-delay: 0s;
}

.roulette-box:nth-child(2) {
    animation-delay: 0.1s;
}

.roulette-box:nth-child(3) {
    animation-delay: 0.2s;
}

.roulette-box:nth-child(4) {
    animation-delay: 0.25s;
}

.roulette-box:nth-child(5) {
    animation-delay: 0.3s;
}

.roulette-box:nth-child(6) {
    animation-delay: 0.35s;
}

.roulette-box:nth-child(7) {
    animation-delay: 0.4s;
}

.roulette-box:nth-child(8) {
    animation-delay: 0.45s;
}

.roulette-box:nth-child(9) {
    animation-delay: 0.5s;
}

.roulette-box:nth-child(10) {
    animation-delay: 0.55s;
}

@keyframes reelAppear {
    0% {
        opacity: 0;
        transform: translateY(20px) scale(0.95);
    }

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

.layout-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.layout-grid .roulette-box {
    height: 70px;
}

/* ========== ROULETTE - PREMIUM DARK GOLD ========== */
.roulette-box {
    background: linear-gradient(145deg,
            rgba(25, 22, 20, 0.92) 0%,
            rgba(35, 30, 25, 0.88) 50%,
            rgba(20, 18, 15, 0.95) 100%);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 16px;
    border: 1px solid rgba(212, 175, 85, 0.25);
    box-shadow:
        0 6px 24px rgba(0, 0, 0, 0.45),
        inset 0 1px 0 rgba(255, 255, 255, 0.04),
        inset 0 -1px 0 rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
}

.center-marker {
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(180deg, rgba(212, 175, 85, 0.3), #d4af55, rgba(212, 175, 85, 0.3));
    transform: translateX(-50%);
    z-index: 10;
    box-shadow: 0 0 12px rgba(212, 175, 85, 0.5), 0 0 25px rgba(212, 175, 85, 0.2);
}

.reel {
    display: flex;
    will-change: transform;
}

.reel.idle-scroll {
    animation: reelIdleScroll 12s linear infinite;
}

@keyframes reelIdleScroll {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

.layout-single .card {
    min-width: 90px;
    height: 90px;
    font-size: 3rem;
    margin: 0 5px;
}

.layout-vertical .card {
    min-width: 60px;
    height: 60px;
    font-size: 2rem;
    margin: 0 3px;
}

.layout-grid .card {
    min-width: 50px;
    height: 50px;
    font-size: 1.5rem;
    margin: 0 2px;
}

.card {
    background: linear-gradient(145deg, rgba(35, 30, 25, 0.8), rgba(25, 22, 20, 0.9));
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(212, 175, 85, 0.12);
    flex-shrink: 0;
}

/* Оптимізація розміру Lottie для різних layout */
.layout-vertical .card lottie-player {
    width: 35px !important;
    height: 35px !important;
}

.layout-grid .card lottie-player {
    width: 30px !important;
    height: 30px !important;
}

/* Ефект виграшу для звичайного кейсу - GPU оптимізація */
.win-glow-effect {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 16px;
    pointer-events: none;
    z-index: 100;
    box-shadow: inset 0 0 30px rgba(212, 175, 85, 0.4), 0 0 40px rgba(212, 175, 85, 0.5);
    background: rgba(212, 175, 85, 0.08);
    animation: winGlow 1.5s ease-out forwards;
    will-change: opacity;
}

@keyframes winGlow {
    0% {
        opacity: 0;
    }

    20% {
        opacity: 1;
    }

    50% {
        opacity: 0.8;
    }

    100% {
        opacity: 0;
    }
}

#roulette-container {
    position: relative;
}

.bulk-bar {
    display: flex;
    gap: 8px;
    justify-content: center;
    margin-bottom: 15px;
}

.bulk-btn {
    background: linear-gradient(145deg,
            rgba(25, 22, 20, 0.92) 0%,
            rgba(35, 30, 25, 0.88) 100%);
    color: #f5e6c8;
    border: 1px solid rgba(212, 175, 85, 0.2);
    padding: 10px 18px;
    border-radius: 14px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.25s ease;
    position: relative;
    overflow: hidden;
    box-shadow:
        0 4px 12px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.bulk-btn::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 60%;
    height: 50%;
    background: linear-gradient(135deg, rgba(212, 175, 85, 0.06) 0%, transparent 70%);
    border-radius: 14px 0 0 0;
    pointer-events: none;
}

.bulk-btn:active::after {
    background: rgba(212, 175, 85, 0.1);
    right: 0;
    height: 100%;
    border-radius: 14px;
}

.bulk-btn.active {
    background: linear-gradient(135deg,
            rgba(212, 175, 85, 0.25) 0%,
            rgba(212, 175, 85, 0.1) 100%);
    color: #f5e6c8;
    border-color: rgba(212, 175, 85, 0.6);
    transform: scale(1.05);
    box-shadow:
        0 0 15px rgba(212, 175, 85, 0.15),
        0 4px 12px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(212, 175, 85, 0.1);
}

.bulk-btn:not(.active):hover {
    border-color: rgba(212, 175, 85, 0.4);
    background: linear-gradient(135deg, rgba(212, 175, 85, 0.1), rgba(212, 175, 85, 0.04));
}

.bulk-btn:disabled {
    opacity: 0.3;
    display: none;
}

.spin-btn {
    width: 100%;
    padding: 15px;
    border: 1px solid rgba(212, 175, 85, 0.4);
    border-radius: 14px;
    background: linear-gradient(135deg,
            rgba(212, 175, 85, 0.2) 0%,
            rgba(212, 175, 85, 0.08) 100%);
    color: #f5e6c8;
    font-weight: 700;
    font-size: 1.1rem;
    margin-bottom: 20px;
    transition: all 0.25s ease;
    letter-spacing: 0.5px;
    box-shadow:
        0 4px 16px rgba(0, 0, 0, 0.3),
        0 0 12px rgba(212, 175, 85, 0.08);
    cursor: pointer;
}

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

.spin-btn:disabled {
    background: rgba(25, 22, 20, 0.8);
    border-color: rgba(212, 175, 85, 0.1);
    color: rgba(245, 230, 200, 0.3);
}

.chances-box {
    background: linear-gradient(145deg,
            rgba(25, 22, 20, 0.92) 0%,
            rgba(35, 30, 25, 0.88) 100%);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 16px;
    padding: 16px;
    border: 1px solid rgba(212, 175, 85, 0.15);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
}

.chance-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid rgba(212, 175, 85, 0.08);
}

.chance-row:last-child {
    border: none;
}

.item-name {
    font-weight: 500;
}

.c-common {
    color: var(--r-common);
}

.c-uncommon {
    color: var(--r-uncommon);
}

.c-rare {
    color: var(--r-rare);
}

.c-legendary {
    color: var(--r-legendary);
}

.c-mythic {
    color: var(--r-mythic);
}

.c-empty {
    color: var(--text-secondary);
    opacity: 0.6;
}

.c-nft {
    color: #ff00ff;
    font-weight: bold;
}

.c-fragments {
    color: #9b59b6;
    font-weight: bold;
}

.user-detail-screen {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-color);
    z-index: 10000;
    overflow-y: auto;
    padding-bottom: 20px;
}

.user-detail-screen.active {
    display: block;
}

.user-detail-header {
    position: sticky;
    top: 0;
    background: var(--bg-color);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding: 15px;
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 10;
}

.user-detail-back {
    background: var(--card-bg);
    border: none;
    color: var(--accent);
    width: 40px;
    height: 40px;
    border-radius: 10px;
    font-size: 1.3rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.user-detail-title {
    flex: 1;
    font-size: 1.2rem;
    font-weight: bold;
}

.user-detail-content {
    padding: 15px;
}

.user-info-card {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 12px;
}

.user-info-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.user-info-row:last-child {
    border: none;
}

.user-info-label {
    color: var(--text-secondary);
    font-size: 0.85rem;
}

.user-info-value {
    font-weight: bold;
}

.user-action-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-bottom: 10px;
}

.user-action-btn {
    background: var(--card-bg);
    border: 2px solid var(--accent);
    color: white;
    padding: 14px;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
}

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

.user-action-btn.success {
    border-color: var(--green);
    background: linear-gradient(135deg, rgba(69, 189, 100, 0.15), rgba(69, 189, 100, 0.05));
}

.user-action-btn.danger {
    border-color: var(--red);
    background: linear-gradient(135deg, rgba(229, 92, 92, 0.15), rgba(229, 92, 92, 0.05));
}

.user-action-btn.full-width {
    grid-column: 1 / -1;
}

.log-container {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 16px;
    max-height: 350px;
    overflow-y: auto;
}

.log-entry {
    padding: 12px;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 8px;
    margin-bottom: 8px;
    font-size: 0.85rem;
    border-left: 3px solid var(--accent);
}

.log-time {
    color: var(--text-secondary);
    font-size: 0.7rem;
    margin-bottom: 4px;
}

.log-action {
    font-weight: 600;
    color: var(--accent);
    margin-bottom: 3px;
}

.nft-winners-btn {
    background: linear-gradient(135deg, #ff00ff, #8800ff);
    border: none;
    padding: 12px;
    border-radius: 10px;
    color: white;
    font-weight: bold;
    width: 100%;
    margin-bottom: 15px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

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

.nft-winner-item {
    background: var(--card-bg);
    padding: 12px;
    border-radius: 10px;
    margin-bottom: 8px;
    border-left: 3px solid #ff00ff;
}

.nft-winner-name {
    font-weight: bold;
    color: #ff00ff;
}

.nft-winner-date {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

/* ========== 9 SLOTS - PREMIUM DARK GOLD ========== */

.slots-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-bottom: 20px;
    padding: 4px;
}

.slot-card {
    aspect-ratio: 1;
    background: linear-gradient(145deg,
            rgba(25, 22, 20, 0.92) 0%,
            rgba(35, 30, 25, 0.88) 50%,
            rgba(20, 18, 15, 0.95) 100%);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    border: 1px solid rgba(212, 175, 85, 0.2);
    box-shadow:
        0 4px 16px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.04);
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.slot-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 60%;
    height: 50%;
    background: linear-gradient(135deg,
            rgba(212, 175, 85, 0.06) 0%,
            transparent 70%);
    border-radius: 16px 0 0 0;
    pointer-events: none;
}

.slot-card.inactive {
    background: linear-gradient(145deg,
            rgba(20, 18, 15, 0.9) 0%,
            rgba(25, 22, 20, 0.85) 100%);
    color: rgba(212, 175, 85, 0.3);
    border-color: rgba(212, 175, 85, 0.1);
    cursor: default;
}

.slot-card.active {
    background: linear-gradient(145deg,
            rgba(212, 175, 85, 0.15) 0%,
            rgba(35, 30, 25, 0.92) 50%,
            rgba(212, 175, 85, 0.08) 100%);
    border-color: rgba(212, 175, 85, 0.4);
    animation: slotPulseGold 2s ease-in-out infinite;
    box-shadow:
        0 4px 20px rgba(0, 0, 0, 0.4),
        0 0 20px rgba(212, 175, 85, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.slot-card.selected {
    border-color: rgba(212, 175, 85, 0.7);
    box-shadow:
        0 0 20px rgba(212, 175, 85, 0.25),
        0 4px 20px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(212, 175, 85, 0.1);
    transform: scale(1.05);
    background: linear-gradient(145deg,
            rgba(212, 175, 85, 0.2) 0%,
            rgba(35, 30, 25, 0.92) 50%,
            rgba(212, 175, 85, 0.12) 100%);
}

.slot-card.revealed {
    animation: slotReveal 0.5s ease;
}

.slot-card.revealed.win {
    border-color: #45bd64;
    background: linear-gradient(145deg,
            rgba(69, 189, 100, 0.2) 0%,
            rgba(25, 22, 20, 0.9) 50%,
            rgba(69, 189, 100, 0.1) 100%);
    box-shadow:
        0 0 20px rgba(69, 189, 100, 0.15),
        0 4px 16px rgba(0, 0, 0, 0.4);
}

.slot-card.revealed.lose {
    border-color: rgba(231, 76, 60, 0.4);
    opacity: 0.5;
    background: linear-gradient(145deg,
            rgba(231, 76, 60, 0.08) 0%,
            rgba(20, 18, 15, 0.9) 100%);
}

@keyframes slotPulseGold {
    0%, 100% {
        border-color: rgba(212, 175, 85, 0.25);
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4), 0 0 10px rgba(212, 175, 85, 0.05);
    }
    50% {
        border-color: rgba(212, 175, 85, 0.5);
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4), 0 0 25px rgba(212, 175, 85, 0.12);
    }
}

@keyframes slotReveal {
    0% {
        transform: scaleX(0);
        opacity: 0.5;
    }
    100% {
        transform: scaleX(1);
        opacity: 1;
    }
}

.slots-count-bar {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-bottom: 18px;
}

.slots-count-btn {
    background: linear-gradient(145deg,
            rgba(25, 22, 20, 0.92) 0%,
            rgba(35, 30, 25, 0.88) 100%);
    color: #f5e6c8;
    border: 1px solid rgba(212, 175, 85, 0.2);
    padding: 10px 20px;
    border-radius: 14px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.25s ease;
    box-shadow:
        0 4px 12px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.04);
    white-space: nowrap;
    position: relative;
    overflow: hidden;
}

.slots-count-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 60%;
    height: 50%;
    background: linear-gradient(135deg, rgba(212, 175, 85, 0.06) 0%, transparent 70%);
    border-radius: 14px 0 0 0;
    pointer-events: none;
}

.slots-count-btn.active {
    background: linear-gradient(135deg,
            rgba(212, 175, 85, 0.25) 0%,
            rgba(212, 175, 85, 0.1) 100%);
    color: #f5e6c8;
    border-color: rgba(212, 175, 85, 0.6);
    box-shadow:
        0 0 15px rgba(212, 175, 85, 0.15),
        0 4px 12px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(212, 175, 85, 0.1);
}

.slots-count-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.slots-info {
    text-align: center;
    color: #f5e6c8;
    font-size: 0.95rem;
    margin-bottom: 16px;
    font-weight: 500;
    letter-spacing: 0.3px;
}

.slots-play-btn {
    display: block;
    width: 100%;
    padding: 14px;
    border: 1px solid rgba(212, 175, 85, 0.4);
    border-radius: 14px;
    background: linear-gradient(135deg,
            rgba(212, 175, 85, 0.2) 0%,
            rgba(212, 175, 85, 0.08) 100%);
    color: #f5e6c8;
    font-size: 1.05rem;
    font-weight: 700;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all 0.25s ease;
    box-shadow:
        0 4px 16px rgba(0, 0, 0, 0.3),
        0 0 12px rgba(212, 175, 85, 0.08);
    text-transform: uppercase;
}

.slots-play-btn:hover,
.slots-play-btn:active {
    border-color: rgba(212, 175, 85, 0.6);
    box-shadow:
        0 0 20px rgba(212, 175, 85, 0.15),
        0 4px 16px rgba(0, 0, 0, 0.35);
}

.slots-play-btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
}

.case-toggle-item {
    background: var(--card-bg);
    padding: 12px;
    border-radius: 10px;
    margin-bottom: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

@keyframes nftWin {
    0% {
        transform: scale(0.5);
        opacity: 0;
    }

    50% {
        transform: scale(1.1);
    }

    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.nft-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(255, 0, 255, 0.9), rgba(102, 126, 234, 0.9));
    z-index: 99999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    animation: nftWin 0.5s ease;
}

.nft-overlay-icon {
    font-size: 6rem;
    margin-bottom: 20px;
    animation: float 2s ease-in-out infinite;
}

.nft-overlay-title {
    font-size: 2rem;
    font-weight: bold;
    margin-bottom: 10px;
}

.nft-overlay-text {
    font-size: 1rem;
    text-align: center;
    padding: 0 30px;
    line-height: 1.6;
}

.nft-overlay-close {
    margin-top: 30px;
    background: white;
    color: #000;
    border: none;
    padding: 15px 40px;
    border-radius: 12px;
    font-weight: bold;
    font-size: 1rem;
    cursor: pointer;
}

.inventory-item.selected {
    border-color: var(--gold);
    box-shadow: 0 0 10px rgba(242, 201, 76, 0.5);
    transform: scale(0.95);
}

.inv-actions {
    display: none;
    gap: 8px;
    margin-bottom: 10px;
}

.inv-actions.active {
    display: flex;
}

.inv-action-btn {
    flex: 1;
    padding: 12px;
    border-radius: 10px;
    border: none;
    font-weight: bold;
    cursor: pointer;
    font-size: 0.85rem;
}

.contract-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 10002;
}

.contract-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}

.contract-card {
    width: 200px;
    height: 280px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 5rem;
    cursor: pointer;
    transition: transform 0.6s;
    transform-style: preserve-3d;
    position: relative;
}

.contract-card.flipped {
    transform: rotateY(180deg);
}

.contract-card-front,
.contract-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.contract-card-back {
    background: var(--card-bg);
    transform: rotateY(180deg);
}

.contract-info {
    color: var(--gold);
    font-size: 1.2rem;
    font-weight: bold;
    margin-bottom: 20px;
}

.contract-result-icon {
    font-size: 4rem;
    margin-bottom: 10px;
}

.contract-result-name {
    font-size: 1.2rem;
    font-weight: bold;
}

/* GPU оптимізація - 360deg замість 720deg, 2s замість 3s */
@keyframes confetti {
    0% {
        transform: translateY(0) rotate(0);
        opacity: 1;
    }

    100% {
        transform: translateY(100vh) rotate(360deg);
        opacity: 0;
    }
}

.confetti {
    position: fixed;
    width: 10px;
    height: 10px;
    top: -10px;
    animation: confetti 2s ease-out forwards;
    z-index: 10003;
    will-change: transform, opacity;
}

@keyframes customCaseGlow {

    0%,
    100% {
        box-shadow: 0 0 15px rgba(255, 0, 255, 0.3);
    }

    50% {
        box-shadow: 0 0 30px rgba(255, 0, 255, 0.5), 0 0 60px rgba(102, 126, 234, 0.3);
    }
}

@keyframes customCaseRainbow {
    0% {
        border-color: #ff00ff;
    }

    25% {
        border-color: #00ffff;
    }

    50% {
        border-color: #ffff00;
    }

    75% {
        border-color: #ff6b6b;
    }

    100% {
        border-color: #ff00ff;
    }
}

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

    25% {
        transform: rotate(5deg) scale(1.1);
    }

    50% {
        transform: rotate(0deg) scale(1);
    }

    75% {
        transform: rotate(-5deg) scale(1.1);
    }

    100% {
        transform: rotate(0deg) scale(1);
    }
}

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

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

.custom-case-card {
    animation: customCaseGlow 3s ease-in-out infinite, customCaseRainbow 4s linear infinite;
}

.custom-case-card .custom-icon {
    animation: customCaseSpin 2s ease-in-out infinite;
}

.custom-case-badge {
    background: linear-gradient(90deg, #ff00ff, #00ffff, #ffff00, #ff00ff);
    background-size: 200% auto;
    animation: customCaseShine 2s linear infinite;
}

.profile-bg-item {
    width: 50px;
    height: 50px;
    border-radius: 10px;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.home-leaderboard {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 12px;
    margin-bottom: 15px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.home-leaderboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.home-leaderboard-title {
    font-size: 0.9rem;
    font-weight: bold;
    color: var(--gold);
}

.home-leaderboard-view-all {
    background: none;
    border: none;
    color: var(--accent);
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
}

.home-leader-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 8px;
    margin-bottom: 6px;
}

.home-leader-rank {
    width: 24px;
    height: 24px;
    background: var(--accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.75rem;
    flex-shrink: 0;
}

.home-leader-rank.rank-1 {
    background: var(--gold);
    color: #000;
}

.home-leader-rank.rank-2 {
    background: #c0c0c0;
    color: #000;
}

.home-leader-rank.rank-3 {
    background: #cd7f32;
    color: #000;
}

.home-leader-info {
    flex: 1;
    min-width: 0;
}

.home-leader-name {
    font-weight: 600;
    font-size: 0.85rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.home-leader-value {
    color: var(--gold);
    font-weight: bold;
    font-size: 0.75rem;
}

.case-card[style*="background-image"] .case-card-image {
    min-height: 100px;
}

.case-card-overlay {
    display: none;
}

.custom-case-badge {
    position: absolute;
    top: -6px;
    right: -6px;
    background: linear-gradient(135deg, #FFD700, #FFA500);
    padding: 3px 8px;
    border-radius: 6px;
    font-size: 0.65rem;
    font-weight: bold;
    color: #000;
    z-index: 10;
    box-shadow: 0 2px 6px rgba(255, 215, 0, 0.4);
}

.profile-bg-item.active {
    border-color: var(--gold);
    box-shadow: 0 0 15px rgba(242, 201, 76, 0.5);
}

.profile-bg-item.locked {
    opacity: 0.4;
    cursor: not-allowed;
}

.profile-bg-item.locked::after {
    content: '🔒';
    position: absolute;
    font-size: 1.2rem;
}

.profile-bg-item:not(.locked):hover {
    transform: scale(1.1);
}

/* Рамки аватара */
.avatar-frame-silver {
    box-shadow: 0 0 0 3px #c0c0c0, 0 0 10px rgba(192, 192, 192, 0.5);
}

.avatar-frame-blue {
    box-shadow: 0 0 0 3px #007aff, 0 0 10px rgba(0, 122, 255, 0.5);
}

.avatar-frame-gold {
    box-shadow: 0 0 0 3px #f2c94c, 0 0 15px rgba(242, 201, 76, 0.6);
}

.avatar-frame-fire {
    box-shadow: 0 0 0 3px #f12711, 0 0 15px rgba(241, 39, 17, 0.6);
    animation: frameFirePulse 1.5s infinite;
}

.avatar-frame-nature {
    box-shadow: 0 0 0 3px #45bd64, 0 0 15px rgba(69, 189, 100, 0.6);
}

.avatar-frame-diamond {
    box-shadow: 0 0 0 3px #b465da, 0 0 20px rgba(180, 101, 218, 0.7);
    animation: frameDiamondShine 2s infinite;
}

.avatar-frame-neon {
    box-shadow: 0 0 0 3px #ff00ff, 0 0 20px rgba(255, 0, 255, 0.6);
    animation: frameNeonPulse 1s infinite;
}

.avatar-frame-rainbow {
    animation: frameRainbow 3s linear infinite;
}

.avatar-frame-legendary {
    box-shadow: 0 0 0 4px #f2c94c, 0 0 25px rgba(242, 201, 76, 0.8), inset 0 0 15px rgba(255, 255, 255, 0.2);
    animation: frameLegendary 2s infinite;
}

@keyframes frameFirePulse {

    0%,
    100% {
        box-shadow: 0 0 0 3px #f12711, 0 0 15px rgba(241, 39, 17, 0.6);
    }

    50% {
        box-shadow: 0 0 0 3px #f5af19, 0 0 25px rgba(245, 175, 25, 0.8);
    }
}

@keyframes frameDiamondShine {

    0%,
    100% {
        box-shadow: 0 0 0 3px #b465da, 0 0 20px rgba(180, 101, 218, 0.5);
    }

    50% {
        box-shadow: 0 0 0 3px #ee609c, 0 0 30px rgba(238, 96, 156, 0.7);
    }
}

@keyframes frameNeonPulse {

    0%,
    100% {
        box-shadow: 0 0 0 3px #ff00ff, 0 0 15px rgba(255, 0, 255, 0.5);
    }

    50% {
        box-shadow: 0 0 0 3px #00ffff, 0 0 25px rgba(0, 255, 255, 0.7);
    }
}

@keyframes frameRainbow {
    0% {
        box-shadow: 0 0 0 3px #ff0000, 0 0 15px rgba(255, 0, 0, 0.5);
    }

    16% {
        box-shadow: 0 0 0 3px #ff7f00, 0 0 15px rgba(255, 127, 0, 0.5);
    }

    33% {
        box-shadow: 0 0 0 3px #ffff00, 0 0 15px rgba(255, 255, 0, 0.5);
    }

    50% {
        box-shadow: 0 0 0 3px #00ff00, 0 0 15px rgba(0, 255, 0, 0.5);
    }

    66% {
        box-shadow: 0 0 0 3px #0000ff, 0 0 15px rgba(0, 0, 255, 0.5);
    }

    83% {
        box-shadow: 0 0 0 3px #9400d3, 0 0 15px rgba(148, 0, 211, 0.5);
    }

    100% {
        box-shadow: 0 0 0 3px #ff0000, 0 0 15px rgba(255, 0, 0, 0.5);
    }
}

@keyframes frameLegendary {

    0%,
    100% {
        box-shadow: 0 0 0 4px #f2c94c, 0 0 20px rgba(242, 201, 76, 0.6);
    }

    50% {
        box-shadow: 0 0 0 4px #ff00ff, 0 0 30px rgba(255, 0, 255, 0.8);
    }
}

/* New frames */
.avatar-frame-ice {
    box-shadow: 0 0 0 3px #00d4ff, 0 0 15px rgba(0, 212, 255, 0.5);
    animation: frameIcePulse 2s infinite;
}

.avatar-frame-plasma {
    box-shadow: 0 0 0 3px #9d00ff, 0 0 20px rgba(157, 0, 255, 0.6);
    animation: framePlasma 1.5s infinite;
}

.avatar-frame-cosmic {
    box-shadow: 0 0 0 4px #000, 0 0 25px rgba(255, 255, 255, 0.5);
    animation: frameCosmic 3s infinite;
    background: radial-gradient(circle, transparent 60%, rgba(100, 100, 255, 0.3) 100%);
}

@keyframes frameIcePulse {

    0%,
    100% {
        box-shadow: 0 0 0 3px #00d4ff, 0 0 15px rgba(0, 212, 255, 0.4);
    }

    50% {
        box-shadow: 0 0 0 3px #87ceeb, 0 0 25px rgba(135, 206, 235, 0.7);
    }
}

@keyframes framePlasma {

    0%,
    100% {
        box-shadow: 0 0 0 3px #9d00ff, 0 0 15px rgba(157, 0, 255, 0.5);
    }

    50% {
        box-shadow: 0 0 0 3px #ff00ff, 0 0 25px rgba(255, 0, 255, 0.7);
    }
}

@keyframes frameCosmic {

    0%,
    100% {
        box-shadow: 0 0 0 4px #1a1a2e, 0 0 20px rgba(100, 100, 255, 0.5);
    }

    33% {
        box-shadow: 0 0 0 4px #302b63, 0 0 25px rgba(255, 0, 255, 0.4);
    }

    66% {
        box-shadow: 0 0 0 4px #24243e, 0 0 30px rgba(0, 255, 255, 0.4);
    }
}

/* Корона */
.accessory-crown {
    position: absolute;
    top: -25px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 40px;
    z-index: 5;
    filter: drop-shadow(0 0 10px rgba(242, 201, 76, 0.8));
    animation: crownFloat 2s ease-in-out infinite;
    pointer-events: none;
}

.accessory-crown::before {
    content: '👑';
    font-size: 3.5rem;
    display: block;
    text-align: center;
}

@keyframes crownFloat {

    0%,
    100% {
        transform: translateX(-50%) translateY(0) rotate(-2deg);
    }

    50% {
        transform: translateX(-50%) translateY(-8px) rotate(2deg);
    }
}

/* === Анімації імені (Оновлені) === */
.name-anim-glow {
    animation: nameGlowImproved 3s ease-in-out infinite;
    text-shadow: 0 0 10px var(--accent), 0 0 20px var(--accent);
    display: block;
    width: 100%;
}

@keyframes nameGlowImproved {

    0%,
    100% {
        text-shadow: 0 0 10px var(--accent), 0 0 20px var(--accent);
        opacity: 1;
    }

    50% {
        text-shadow: 0 0 25px var(--accent), 0 0 40px var(--accent), 0 0 60px var(--accent);
        opacity: 0.9;
    }
}

.name-anim-pulse {
    animation: namePulseImproved 2s cubic-bezier(0.4, 0, 0.2, 1) infinite;
    display: block;
    width: 100%;
}

@keyframes namePulseImproved {

    0%,
    100% {
        transform: scale(1);
        filter: brightness(1);
    }

    50% {
        transform: scale(1.05);
        filter: brightness(1.2);
        text-shadow: 0 0 15px rgba(255, 255, 255, 0.4);
    }
}

.name-anim-rainbow {
    background: linear-gradient(90deg, #ff0000, #ff7f00, #ffff00, #00ff00, #00ffea, #007aff, #9400d3, #ff0000);
    background-size: 300% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: nameRainbowFlow 4s linear infinite;
    filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.1));
    display: block;
    width: 100%;
}

@keyframes nameRainbowFlow {
    0% {
        background-position: 0% center;
    }

    100% {
        background-position: 300% center;
    }
}

.name-anim-fire {
    background: linear-gradient(to top, #f12711, #f5af19, #fff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: nameFireImproved 0.8s ease-in-out infinite alternate;
    position: relative;
    display: block;
    width: 100%;
}

@keyframes nameFireImproved {
    0% {
        filter: drop-shadow(0 -2px 4px #f12711) brightness(1);
        transform: skewX(-1deg);
    }

    100% {
        filter: drop-shadow(0 -5px 10px #f5af19) brightness(1.2);
        transform: skewX(1deg);
    }
}

.name-anim-matrix {
    color: #00ff00 !important;
    -webkit-text-fill-color: #00ff00 !important;
    text-shadow: 0 0 8px #00ff00, 0 0 15px rgba(0, 255, 0, 0.5);
    animation: nameMatrixImproved 1.5s steps(4) infinite;
    font-family: 'Courier New', monospace;
    letter-spacing: 2px;
    display: block;
    width: 100%;
}

@keyframes nameMatrixImproved {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.7;
        text-shadow: 0 0 15px #00ff00, 0 0 25px #00ff00;
    }
}

.name-anim-gold {
    background: linear-gradient(135deg, #bf953f, #fcf6ba, #b38728, #fcf6ba, #bf953f);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: nameGoldImproved 3s linear infinite;
    font-weight: 900;
    display: block;
    width: 100%;
}

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

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

.name-anim-neon {
    color: #fff !important;
    -webkit-text-fill-color: #fff !important;
    text-shadow:
        0 0 5px #fff,
        0 0 10px #fff,
        0 0 20px #ff00ff,
        0 0 30px #ff00ff,
        0 0 40px #ff00ff;
    animation: nameNeonFlicker 2s infinite;
    display: block;
    width: 100%;
}

@keyframes nameNeonFlicker {

    0%,
    18%,
    22%,
    25%,
    53%,
    57%,
    100% {
        text-shadow: 0 0 5px #fff, 0 0 10px #fff, 0 0 20px #ff00ff, 0 0 30px #ff00ff, 0 0 40px #ff00ff;
    }

    20%,
    24%,
    55% {
        text-shadow: none;
        color: #444 !important;
        -webkit-text-fill-color: #444 !important;
    }
}

.name-anim-wave {
    display: block;
    width: 100%;
    animation: nameWaveImproved 2s ease-in-out infinite;
}

@keyframes nameWaveImproved {

    0%,
    100% {
        transform: translateY(0) rotate(0deg);
    }

    25% {
        transform: translateY(-3px) rotate(-1deg);
    }

    75% {
        transform: translateY(3px) rotate(1deg);
    }
}

.name-anim-glitch {
    position: relative;
    display: block;
    width: 100%;
    animation: nameGlitchImproved 0.4s cubic-bezier(.25, .46, .45, .94) both infinite;
}

@keyframes nameGlitchImproved {
    0% {
        transform: translate(0);
        text-shadow: none;
    }

    20% {
        transform: translate(-1px, 1px);
        text-shadow: 2px 0 #ff00ff, -2px 0 #00ffff;
    }

    40% {
        transform: translate(-1px, -1px);
        text-shadow: -2px 0 #ff00ff, 2px 0 #00ffff;
    }

    60% {
        transform: translate(1px, 1px);
        text-shadow: 2px 0 #ff00ff, -2px 0 #00ffff;
    }

    80% {
        transform: translate(1px, -1px);
        text-shadow: -2px 0 #ff00ff, 2px 0 #00ffff;
    }

    100% {
        transform: translate(0);
        text-shadow: none;
    }
}

.name-anim-shine {
    background: linear-gradient(120deg, transparent 0%, transparent 40%, rgba(255, 255, 255, 0.8) 50%, transparent 60%, transparent 100%);
    background-size: 200% 100%;
    -webkit-background-clip: text;
    background-clip: text;
    animation: nameShineImproved 2s infinite;
    background-color: var(--text-primary);
    display: block;
    width: 100%;
}

@keyframes nameShineImproved {
    0% {
        background-position: 100% 0;
    }

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

.name-anim-cyber {
    color: #00fff9 !important;
    -webkit-text-fill-color: #00fff9 !important;
    text-shadow: 0 0 10px rgba(0, 255, 249, 0.5);
    position: relative;
    font-family: 'Segoe UI', sans-serif;
    letter-spacing: 1px;
    display: block;
    width: 100%;
}

.name-anim-cyber::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: #ff00ff;
    animation: nameCyberScan 2s linear infinite;
    box-shadow: 0 0 10px #ff00ff;
    pointer-events: none;
}

@keyframes nameCyberScan {
    0% {
        top: 0%;
        opacity: 0;
    }

    50% {
        opacity: 1;
    }

    100% {
        top: 100%;
        opacity: 0;
    }
}

.name-anim-bounce {
    display: block;
    width: 100%;
    animation: nameBounceImproved 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275) infinite alternate;
}

@keyframes nameBounceImproved {
    0% {
        transform: translateY(0);
    }

    100% {
        transform: translateY(-8px);
    }
}

.name-anim-blur {
    display: block;
    width: 100%;
    animation: nameBlurImproved 3s ease-in-out infinite;
}

@keyframes nameBlurImproved {

    0%,
    100% {
        filter: blur(0px);
        opacity: 1;
    }

    50% {
        filter: blur(3px);
        opacity: 0.7;
    }
}

.name-anim-shake {
    display: block;
    width: 100%;
    animation: nameShakeImproved 0.1s linear infinite;
}

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

    25% {
        transform: translate(0.5px, 0.5px);
    }

    50% {
        transform: translate(-0.5px, -0.5px);
    }

    75% {
        transform: translate(0.5px, -0.5px);
    }

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

.name-anim-gradient {
    background: linear-gradient(90deg, #667eea, #764ba2, #f093fb, #f5576c, #f093fb, #764ba2, #667eea);
    background-size: 400% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: nameGradientMove 5s linear infinite;
    font-weight: bold;
    display: block;
    width: 100%;
}

@keyframes nameGradientMove {
    0% {
        background-position: 0% center;
    }

    100% {
        background-position: 400% center;
    }
}

.name-anim-typewriter {
    display: block;
    width: fit-content;
    margin: 0 auto;
    border-right: 3px solid var(--accent);
    white-space: nowrap;
    overflow: hidden;
    animation: nameTypewriterImproved 4s steps(20) infinite, nameCursor 0.8s step-end infinite;
}

@keyframes nameTypewriterImproved {

    0%,
    10%,
    100% {
        width: 0;
    }

    50%,
    90% {
        width: 100%;
    }
}

@keyframes nameCursor {

    from,
    to {
        border-color: transparent;
    }

    50% {
        border-color: var(--accent);
    }
}

.name-anim-magic {
    background: linear-gradient(90deg, #a8edea 0%, #fed6e3 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: nameMagic 3s ease-in-out infinite alternate;
    filter: drop-shadow(0 0 10px rgba(168, 237, 234, 0.5));
    display: block;
    width: 100%;
}

@keyframes nameMagic {
    0% {
        filter: hue-rotate(0deg) drop-shadow(0 0 5px #a8edea);
    }

    100% {
        filter: hue-rotate(360deg) drop-shadow(0 0 15px #fed6e3);
    }
}

.name-anim-ghost {
    animation: nameGhost 2s ease-in-out infinite;
    color: rgba(255, 255, 255, 0.6) !important;
    display: block;
    width: 100%;
}

@keyframes nameGhost {

    0%,
    100% {
        transform: translateY(0) scale(1);
        opacity: 0.6;
        filter: blur(1px);
    }

    50% {
        transform: translateY(-8px) scale(1.05);
        opacity: 0;
        filter: blur(4px);
    }
}

.name-anim-streak {
    background: linear-gradient(90deg, #45bd64, #3aa856, #45bd64);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: nameGold 2s linear infinite;
    font-weight: bold;
    text-shadow: 0 0 5px rgba(69, 189, 100, 0.3);
    display: block;
    width: 100%;
}


.name-anim-ghost {
    animation: nameGhost 2s ease-in-out infinite;
    color: rgba(255, 255, 255, 0.6) !important;
    display: block;
    width: 100%;
}

@keyframes nameGhost {

    0%,
    100% {
        transform: translateY(0) scale(1);
        opacity: 0.6;
        filter: blur(1px);
    }

    50% {
        transform: translateY(-8px) scale(1.05);
        opacity: 0;
        filter: blur(4px);
    }
}

/* === Ефекти профілю (Оновлені та Оптимізовані) === */
.profile-head {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
}

.profile-effect {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    border-radius: 16px;
}

/* Dots - крапки */
.profile-effect-dots {
    background-image: radial-gradient(rgba(255, 255, 255, 0.2) 1px, transparent 1px);
    background-size: 20px 20px;
    animation: dotsMove 30s linear infinite;
    opacity: 0.6;
}

@keyframes dotsMove {
    0% {
        background-position: 0 0;
    }

    100% {
        background-position: 100px 100px;
    }
}

/* Lines - лінії */
.profile-effect-lines {
    background: repeating-linear-gradient(45deg, transparent, transparent 15px, rgba(255, 255, 255, 0.03) 15px, rgba(255, 255, 255, 0.03) 16px);
    animation: linesMove 4s linear infinite;
}

@keyframes linesMove {
    0% {
        background-position: 0 0;
    }

    100% {
        background-position: 40px 40px;
    }
}

/* Bubbles - бульбашки */
.profile-effect-bubbles::before,
.profile-effect-bubbles::after {
    content: '🫧';
    position: absolute;
    animation: bubbleFloatImproved 4s ease-in-out infinite;
    font-size: 1rem;
    opacity: 0;
    filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.3));
}

.profile-effect-bubbles::before {
    left: 15%;
    animation-delay: 0s;
}

.profile-effect-bubbles::after {
    left: 75%;
    animation-delay: 2s;
    font-size: 0.8rem;
}

@keyframes bubbleFloatImproved {
    0% {
        bottom: -10%;
        opacity: 0;
        transform: scale(0.5) translateX(0);
    }

    20% {
        opacity: 0.6;
    }

    80% {
        opacity: 0.4;
    }

    100% {
        bottom: 110%;
        opacity: 0;
        transform: scale(1.2) translateX(15px);
    }
}

/* Sparkle - блискітки */
.profile-effect-sparkle::before,
.profile-effect-sparkle::after {
    content: '✨';
    position: absolute;
    animation: sparklePulse 2.5s infinite;
    font-size: 1.2rem;
    opacity: 0;
    filter: drop-shadow(0 0 8px #fff);
}

.profile-effect-sparkle::before {
    top: 10%;
    left: 10%;
    animation-delay: 0s;
}

.profile-effect-sparkle::after {
    bottom: 20%;
    right: 15%;
    animation-delay: 1.2s;
    font-size: 0.9rem;
}

@keyframes sparklePulse {

    0%,
    100% {
        transform: scale(0.5) rotate(0deg);
        opacity: 0;
    }

    50% {
        transform: scale(1.1) rotate(180deg);
        opacity: 0.8;
    }
}

/* Snow - сніг */
.profile-effect-snow::before,
.profile-effect-snow::after {
    content: '❄️';
    position: absolute;
    font-size: 0.8rem;
    opacity: 0;
    animation: snowFallImproved 4s linear infinite;
}

.profile-effect-snow::before {
    left: 25%;
    animation-delay: 0s;
}

.profile-effect-snow::after {
    left: 65%;
    animation-delay: 2s;
    font-size: 0.6rem;
}

@keyframes snowFallImproved {
    0% {
        top: -10%;
        opacity: 0;
        transform: translateX(0) rotate(0deg);
    }

    20% {
        opacity: 0.7;
    }

    80% {
        opacity: 0.5;
    }

    100% {
        top: 110%;
        opacity: 0;
        transform: translateX(20px) rotate(360deg);
    }
}

/* Hearts - серця */
.profile-effect-hearts::before,
.profile-effect-hearts::after {
    content: '❤️';
    position: absolute;
    animation: heartFloatImproved 3.5s ease-out infinite;
    font-size: 1rem;
    opacity: 0;
    filter: drop-shadow(0 0 5px rgba(255, 0, 0, 0.3));
}

.profile-effect-hearts::before {
    left: 20%;
    animation-delay: 0s;
}

.profile-effect-hearts::after {
    left: 70%;
    animation-delay: 1.7s;
    font-size: 0.8rem;
    content: '💕';
}

@keyframes heartFloatImproved {
    0% {
        bottom: -10%;
        opacity: 0;
        transform: scale(0.5) rotate(-15deg);
    }

    20% {
        opacity: 0.8;
        transform: scale(1);
    }

    100% {
        bottom: 110%;
        opacity: 0;
        transform: scale(0.8) rotate(15deg) translateX(10px);
    }
}

/* Fire - вогонь */
.profile-effect-fire {
    background: linear-gradient(to top, rgba(255, 80, 0, 0.3), rgba(255, 150, 0, 0.1) 40%, transparent 80%);
    animation: firePulseImproved 1s ease-in-out infinite alternate;
}

.profile-effect-fire::before,
.profile-effect-fire::after {
    content: '🔥';
    position: absolute;
    bottom: 5%;
    font-size: 1.2rem;
    opacity: 0.6;
    animation: fireFlickerImproved 1.2s ease-in-out infinite;
    filter: drop-shadow(0 0 10px #ff4500);
}

.profile-effect-fire::before {
    left: 20%;
    animation-delay: 0.1s;
}

.profile-effect-fire::after {
    right: 25%;
    animation-delay: 0.6s;
    font-size: 0.9rem;
}

@keyframes firePulseImproved {
    0% {
        opacity: 0.5;
    }

    100% {
        opacity: 0.9;
    }
}

@keyframes fireFlickerImproved {

    0%,
    100% {
        transform: translateY(0) scale(1);
        opacity: 0.6;
    }

    50% {
        transform: translateY(-10px) scale(1.2);
        opacity: 0.9;
    }
}

/* Stars - зорепад */
.profile-effect-stars::before,
.profile-effect-stars::after {
    content: '⭐';
    position: absolute;
    animation: starFlyImproved 3s linear infinite;
    font-size: 0.8rem;
    top: 30%;
    left: -10%;
    opacity: 0;
    filter: drop-shadow(0 0 5px var(--gold));
}

.profile-effect-stars::after {
    content: '🌟';
    animation-delay: 1.5s;
    top: 60%;
}

@keyframes starFlyImproved {
    0% {
        left: -10%;
        opacity: 0;
        transform: rotate(0deg) scale(0.5);
    }

    20% {
        opacity: 1;
    }

    80% {
        opacity: 0.8;
    }

    100% {
        left: 110%;
        opacity: 0;
        transform: rotate(720deg) scale(1.1);
    }
}

/* Matrix - матриця */
.profile-effect-matrix {
    background: linear-gradient(180deg, rgba(0, 255, 0, 0.1), transparent);
}

.profile-effect-matrix::before,
.profile-effect-matrix::after {
    content: '10110';
    color: #00ff00;
    position: absolute;
    font-size: 0.6rem;
    font-family: monospace;
    opacity: 0;
    animation: matrixRainImproved 3s linear infinite;
    top: -20px;
    text-shadow: 0 0 5px #00ff00;
}

.profile-effect-matrix::before {
    left: 20%;
    content: '010101';
}

.profile-effect-matrix::after {
    right: 30%;
    content: '110011';
    animation-delay: 1.5s;
}

@keyframes matrixRainImproved {
    0% {
        transform: translateY(0);
        opacity: 0;
    }

    20% {
        opacity: 1;
    }

    100% {
        transform: translateY(200px);
        opacity: 0;
    }
}

/* Rainbow - веселка */
.profile-effect-rainbow {
    background: linear-gradient(45deg, rgba(255, 0, 0, 0.05), rgba(255, 255, 0, 0.05), rgba(0, 255, 0, 0.05), rgba(0, 0, 255, 0.05));
    background-size: 400% 400%;
    animation: rainbowBgImproved 8s ease infinite;
    box-shadow: inset 0 0 30px rgba(255, 255, 255, 0.1);
}

@keyframes rainbowBgImproved {

    0%,
    100% {
        background-position: 0% 50%;
    }

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

/* Galaxy - галактика */
.profile-effect-galaxy {
    background: radial-gradient(circle at center, rgba(106, 17, 203, 0.1) 0%, transparent 70%);
}

.profile-effect-galaxy::before,
.profile-effect-galaxy::after {
    content: '✦';
    position: absolute;
    animation: galaxyGlow 4s ease-in-out infinite;
    color: #fff;
    font-size: 0.7rem;
    text-shadow: 0 0 10px #6a11cb, 0 0 20px #2575fc;
}

.profile-effect-galaxy::before {
    top: 20%;
    left: 20%;
}

.profile-effect-galaxy::after {
    bottom: 30%;
    right: 25%;
    animation-delay: 2s;
}

@keyframes galaxyGlow {

    0%,
    100% {
        opacity: 0.2;
        transform: scale(0.8);
    }

    50% {
        opacity: 1;
        transform: scale(1.3);
    }
}

/* === НОВІ ЕФЕКТИ === */

/* Cyber Scan - кібер-сканування */
.profile-effect-cyber-scan {
    background: rgba(0, 255, 255, 0.02);
}

.profile-effect-cyber-scan::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, #00ffff, transparent);
    box-shadow: 0 0 15px #00ffff;
    animation: scanMove 3s linear infinite;
}

@keyframes scanMove {
    0% {
        transform: translateY(0);
        opacity: 0;
    }

    10% {
        opacity: 1;
    }

    90% {
        opacity: 1;
    }

    100% {
        transform: translateY(250px);
        opacity: 0;
    }
}

/* Petals - пелюстки сакури */
.profile-effect-petals::before,
.profile-effect-petals::after {
    content: '🌸';
    position: absolute;
    font-size: 0.9rem;
    opacity: 0;
    top: -20px;
    animation: petalFall 5s linear infinite;
}

.profile-effect-petals::before {
    left: 10%;
    animation-delay: 0s;
}

.profile-effect-petals::after {
    left: 60%;
    animation-delay: 2.5s;
    font-size: 0.7rem;
}

@keyframes petalFall {
    0% {
        transform: translate(0, 0) rotate(0deg);
        opacity: 0;
    }

    20% {
        opacity: 0.8;
    }

    100% {
        transform: translate(100px, 250px) rotate(720deg);
        opacity: 0;
    }
}

/* Gold Dust - золотий пил */
.profile-effect-gold-dust {
    background: radial-gradient(circle at bottom, rgba(242, 201, 76, 0.05), transparent 70%);
}

.profile-effect-gold-dust::before,
.profile-effect-gold-dust::after {
    content: '✨';
    position: absolute;
    color: #f2c94c;
    font-size: 0.5rem;
    opacity: 0;
    animation: dustRise 4s ease-in-out infinite;
}

.profile-effect-gold-dust::before {
    bottom: 10%;
    left: 30%;
    animation-delay: 0s;
}

.profile-effect-gold-dust::after {
    bottom: 20%;
    right: 30%;
    animation-delay: 2s;
}

@keyframes dustRise {
    0% {
        transform: translateY(0) scale(0.5);
        opacity: 0;
    }

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

    100% {
        transform: translateY(-100px) scale(0.8);
        opacity: 0;
    }
}

/* Thunder - грім та блискавка */
.profile-effect-thunder {
    background: transparent;
    transition: background 0.1s;
}

.profile-effect-thunder::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0);
    animation: thunderFlash 6s infinite;
}

.profile-effect-thunder::after {
    content: '⚡';
    position: absolute;
    top: 10%;
    right: 20%;
    font-size: 1.5rem;
    opacity: 0;
    color: #fff;
    filter: drop-shadow(0 0 10px #00ffff);
    animation: lightningBolt 6s infinite;
}

@keyframes thunderFlash {

    0%,
    94%,
    98%,
    100% {
        background: rgba(255, 255, 255, 0);
    }

    95%,
    97% {
        background: rgba(255, 255, 255, 0.1);
    }
}

@keyframes lightningBolt {

    0%,
    94%,
    100% {
        opacity: 0;
        transform: scale(0);
    }

    95% {
        opacity: 1;
        transform: scale(1.2) rotate(-10deg);
    }

    97% {
        opacity: 1;
        transform: scale(1) rotate(5deg);
    }
}


/* === EVENT UNIQUE FRAMES === */
.avatar-frame-newyear {
    box-shadow: 0 0 0 4px #c41e3a, 0 0 20px rgba(196, 30, 58, 0.5), 0 0 30px rgba(0, 128, 0, 0.3);
    animation: frameNewyear 3s ease-in-out infinite;
    position: relative;
}

.avatar-frame-newyear::before {
    content: '🎄';
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 1rem;
    animation: newyearStar 2s ease-in-out infinite;
}

@keyframes frameNewyear {

    0%,
    100% {
        box-shadow: 0 0 0 4px #c41e3a, 0 0 15px rgba(196, 30, 58, 0.4);
    }

    50% {
        box-shadow: 0 0 0 4px #228b22, 0 0 25px rgba(34, 139, 34, 0.6);
    }
}

@keyframes newyearStar {

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

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

.avatar-frame-tropics {
    box-shadow: 0 0 0 4px #ff6b6b, 0 0 15px rgba(255, 107, 107, 0.4);
    animation: frameTropics 4s ease-in-out infinite;
    position: relative;
}

.avatar-frame-tropics::before {
    content: '🌺';
    position: absolute;
    top: -10px;
    right: -10px;
    font-size: 1rem;
    animation: tropicsFlower 3s ease-in-out infinite;
}

.avatar-frame-tropics::after {
    content: '🌴';
    position: absolute;
    bottom: -10px;
    left: -10px;
    font-size: 0.8rem;
}

@keyframes frameTropics {

    0%,
    100% {
        box-shadow: 0 0 0 4px #ff6b6b, 0 0 15px rgba(255, 107, 107, 0.4);
    }

    50% {
        box-shadow: 0 0 0 4px #feca57, 0 0 20px rgba(254, 202, 87, 0.5);
    }
}

@keyframes tropicsFlower {

    0%,
    100% {
        transform: rotate(0deg);
    }

    50% {
        transform: rotate(15deg);
    }
}

/* === EVENT UNIQUE TITLE EFFECTS === */
.title-effect-snowflakes {
    position: relative;
    display: inline-block;
}

.title-effect-snowflakes::before,
.title-effect-snowflakes::after,
.title-effect-snowflakes .snow1,
.title-effect-snowflakes .snow2,
.title-effect-snowflakes .snow3 {
    content: '❄️';
    position: absolute;
    font-size: 0.5rem;
    animation: titleSnowRandom 2.5s linear infinite;
    opacity: 0;
}

.title-effect-snowflakes::before {
    left: -18px;
    animation-delay: 0s;
}

.title-effect-snowflakes::after {
    right: -18px;
    animation-delay: 0.8s;
    font-size: 0.4rem;
}

@keyframes titleSnowRandom {
    0% {
        transform: translateY(-15px) rotate(0deg);
        opacity: 0;
    }

    20% {
        opacity: 0.9;
    }

    80% {
        opacity: 0.7;
    }

    100% {
        transform: translateY(15px) rotate(180deg) translateX(5px);
        opacity: 0;
    }
}

.title-effect-hohoho {
    position: relative;
    overflow: visible;
    animation: hohohoWiggle 2s ease-in-out infinite;
}

.title-effect-hohoho::before {
    content: '🎁';
    position: absolute;
    font-size: 0.6rem;
    animation: hohohoGift 3s ease-in-out infinite;
    opacity: 0;
    top: -12px;
    left: -8px;
}

.title-effect-hohoho::after {
    content: 'Ho!';
    position: absolute;
    font-size: 0.45rem;
    color: #ff4444;
    font-weight: bold;
    animation: hohohoFloat 2.5s ease-in-out infinite;
    opacity: 0;
    top: -8px;
    right: -22px;
    text-shadow: 0 0 5px rgba(255, 255, 255, 0.5);
}

@keyframes hohohoWiggle {

    0%,
    100% {
        transform: rotate(-1deg);
    }

    50% {
        transform: rotate(1deg);
    }
}

@keyframes hohohoFloat {

    0%,
    60% {
        opacity: 0;
        transform: translateY(0) scale(0.8);
    }

    75% {
        opacity: 1;
        transform: translateY(-5px) scale(1.1);
    }

    100% {
        opacity: 0;
        transform: translateY(-12px) scale(0.9);
    }
}

@keyframes hohohoGift {

    0%,
    70% {
        opacity: 0;
        transform: scale(0);
    }

    80% {
        opacity: 1;
        transform: scale(1.2);
    }

    100% {
        opacity: 0;
        transform: scale(0.8) translateY(-5px);
    }
}

.title-effect-water_drops {
    position: relative;
    animation: surferWave 3s ease-in-out infinite;
}

.title-effect-water_drops::before,
.title-effect-water_drops::after {
    content: '💧';
    position: absolute;
    font-size: 0.45rem;
    animation: waterDropFall 1.8s ease-out infinite;
    opacity: 0;
}

.title-effect-water_drops::before {
    left: -14px;
    animation-delay: 0.3s;
}

.title-effect-water_drops::after {
    right: -14px;
    animation-delay: 1.2s;
    content: '🌊';
}

@keyframes surferWave {

    0%,
    100% {
        transform: translateY(0) rotate(-1deg);
    }

    50% {
        transform: translateY(-2px) rotate(1deg);
    }
}

@keyframes waterDropFall {
    0% {
        transform: translateY(-8px) scale(0.5);
        opacity: 0;
    }

    30% {
        opacity: 0.9;
        transform: translateY(0) scale(1);
    }

    100% {
        transform: translateY(12px) scale(0.7);
        opacity: 0;
    }
}

.title-effect-relax_text {
    position: relative;
    animation: chillFloat 4s ease-in-out infinite;
}

.title-effect-relax_text::before {
    content: '✨';
    position: absolute;
    font-size: 0.5rem;
    animation: chillSparkle 3s ease-in-out infinite;
    opacity: 0;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
}

.title-effect-relax_text::after {
    content: '😎';
    position: absolute;
    font-size: 0.5rem;
    animation: chillEmoji 5s ease-in-out infinite;
    opacity: 0;
    top: -8px;
    right: -18px;
}

@keyframes chillFloat {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-3px);
    }
}

@keyframes chillSparkle {

    0%,
    70% {
        opacity: 0;
        transform: translateX(-50%) scale(0.5);
    }

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

    100% {
        opacity: 0;
        transform: translateX(-50%) scale(0.8) translateY(-8px);
    }
}

@keyframes chillEmoji {

    0%,
    80% {
        opacity: 0;
    }

    85% {
        opacity: 1;
        transform: rotate(-10deg);
    }

    95% {
        opacity: 1;
        transform: rotate(10deg);
    }

    100% {
        opacity: 0;
    }
}

/* === PROFILE ACCESSORIES === */
.avatar-container {
    position: relative;
    display: inline-block;
}

/* Шапка Діда Мороза - об'ємна */
.accessory-santa-hat {
    position: absolute;
    top: -30px;
    left: 50%;
    transform: translateX(-50%) rotate(-8deg);
    width: 70px;
    height: 45px;
    z-index: 10;
    filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.4));
    animation: santaHatBob 3s ease-in-out infinite;
}

.accessory-santa-hat::before {
    content: '';
    position: absolute;
    top: 12px;
    left: 5px;
    width: 60px;
    height: 35px;
    background: linear-gradient(135deg, #d42426, #ff3b3b, #c41e3a, #b22222);
    border-radius: 50% 50% 0 0 / 100% 100% 0 0;
    box-shadow: inset 0 -5px 15px rgba(0, 0, 0, 0.3), inset 0 5px 10px rgba(255, 255, 255, 0.2);
}

.accessory-santa-hat::after {
    content: '';
    position: absolute;
    top: 38px;
    left: 0;
    width: 70px;
    height: 12px;
    background: linear-gradient(180deg, #fff, #f5f5f5, #e8e8e8);
    border-radius: 6px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2), inset 0 2px 3px rgba(255, 255, 255, 0.8);
}

.accessory-santa-hat .pompom {
    position: absolute;
    top: -5px;
    right: -5px;
    width: 18px;
    height: 18px;
    background: radial-gradient(circle at 30% 30%, #fff, #f0f0f0, #ddd);
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    animation: pompomBounce 2s ease-in-out infinite;
}

@keyframes santaHatBob {

    0%,
    100% {
        transform: translateX(-50%) rotate(-8deg);
    }

    50% {
        transform: translateX(-50%) rotate(-5deg) translateY(-2px);
    }
}

@keyframes pompomBounce {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.1);
    }
}

/* Сонцезахисні окуляри - великі на голові */
.accessory-sunglasses {
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%) rotate(5deg);
    width: 65px;
    height: 25px;
    z-index: 10;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
    animation: sunglassesShine 4s ease-in-out infinite;
}

.accessory-sunglasses::before,
.accessory-sunglasses::after {
    content: '';
    position: absolute;
    top: 8px;
    width: 26px;
    height: 20px;
    background: linear-gradient(135deg, #1a1a1a, #333, #1a1a1a);
    border-radius: 4px 4px 8px 8px;
    border: 2px solid #222;
    box-shadow: inset 0 0 10px rgba(255, 255, 255, 0.1), 0 2px 4px rgba(0, 0, 0, 0.3);
}

.accessory-sunglasses::before {
    left: 0;
}

.accessory-sunglasses::after {
    right: 0;
}

.accessory-sunglasses .bridge {
    position: absolute;
    top: 12px;
    left: 50%;
    transform: translateX(-50%);
    width: 10px;
    height: 3px;
    background: linear-gradient(180deg, #333, #222);
    border-radius: 2px;
}

.accessory-sunglasses .arm-left,
.accessory-sunglasses .arm-right {
    position: absolute;
    top: 10px;
    width: 20px;
    height: 3px;
    background: linear-gradient(180deg, #333, #222);
}

.accessory-sunglasses .arm-left {
    left: -18px;
    transform: rotate(-15deg);
}

.accessory-sunglasses .arm-right {
    right: -18px;
    transform: rotate(15deg);
}

@keyframes sunglassesShine {

    0%,
    100% {
        filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
    }

    50% {
        filter: drop-shadow(0 2px 8px rgba(255, 255, 255, 0.2)) brightness(1.1);
    }
}

/* === EVENT CASE STYLES === */
.case-card.event-case {
    border: 2px solid transparent;
    animation: eventCaseGlow 3s ease-in-out infinite;
}

.case-card.event-winter {
    background: linear-gradient(135deg, #1a1a3e, #4a69bd, #82ccdd);
    border-color: #82ccdd;
}

.case-card.event-summer {
    background: linear-gradient(135deg, #f5af19, #f12711, #00d4ff);
    border-color: #feca57;
}

@keyframes eventCaseGlow {

    0%,
    100% {
        box-shadow: 0 0 15px rgba(255, 255, 255, 0.2);
    }

    50% {
        box-shadow: 0 0 25px rgba(255, 255, 255, 0.4);
    }
}

.event-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background: linear-gradient(135deg, #ff00ff, #00ffff);
    padding: 3px 8px;
    border-radius: 10px;
    font-size: 0.65rem;
    font-weight: bold;
    color: #000;
}

/* === СИСТЕМА РІВНІВ === */
.level-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: bold;
    color: white;
    margin-left: 8px;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.4);
}

.level-badge.mythic {
    background: linear-gradient(135deg, #f7d047, #ffd700, #f2c94c);
    color: #000;
    animation: mythicGlow 2s ease-in-out infinite;
}

@keyframes mythicGlow {

    0%,
    100% {
        box-shadow: 0 0 10px rgba(247, 208, 71, 0.5);
    }

    50% {
        box-shadow: 0 0 20px rgba(247, 208, 71, 0.8);
    }
}

.level-progress-container {
    margin: 10px 0;
    padding: 0 20px;
}

.level-progress-bar {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    height: 8px;
    overflow: hidden;
    position: relative;
}

.level-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #667eea, #764ba2);
    border-radius: 10px;
    transition: width 0.5s ease;
}

.level-progress-text {
    display: flex;
    justify-content: space-between;
    font-size: 0.7rem;
    color: var(--text-secondary);
    margin-top: 4px;
}

.xp-earned-popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(102, 126, 234, 0.95);
    padding: 20px 40px;
    border-radius: 16px;
    font-size: 1.5rem;
    font-weight: bold;
    color: white;
    z-index: 9999;
    animation: xpPopup 1.5s ease-out forwards;
    pointer-events: none;
}

@keyframes xpPopup {
    0% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.5);
    }

    20% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1.1);
    }

    40% {
        transform: translate(-50%, -50%) scale(1);
    }

    80% {
        opacity: 1;
    }

    100% {
        opacity: 0;
        transform: translate(-50%, -70%) scale(0.8);
    }
}

/* Level Up Modal */
.levelup-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.9);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

.levelup-content {
    background: linear-gradient(135deg, #1a1a2e, #16213e);
    border: 2px solid rgba(102, 126, 234, 0.5);
    border-radius: 24px;
    padding: 30px;
    text-align: center;
    max-width: 320px;
    width: 90%;
    animation: levelUpBounce 0.5s ease;
}

@keyframes levelUpBounce {
    0% {
        transform: scale(0.5) rotate(-10deg);
        opacity: 0;
    }

    50% {
        transform: scale(1.1) rotate(5deg);
    }

    100% {
        transform: scale(1) rotate(0);
        opacity: 1;
    }
}

.levelup-level {
    font-size: 4rem;
    font-weight: bold;
    background: linear-gradient(135deg, #667eea, #764ba2, #f7d047);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: levelPulse 1s ease-in-out infinite;
}

@keyframes levelPulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

.levelup-reward {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 15px;
    margin: 15px 0;
}

.levelup-reward-item {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 1.2rem;
    margin: 8px 0;
}

.levelup-claim-btn {
    background: linear-gradient(135deg, #667eea, #764ba2);
    border: none;
    padding: 15px 40px;
    border-radius: 12px;
    color: white;
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    margin-top: 15px;
    transition: transform 0.2s;
}

.levelup-claim-btn:active {
    transform: scale(0.95);
}

/* Pending rewards indicator */
.nav-btn.has-reward .nav-icon::after {
    content: '';
    position: absolute;
    top: -2px;
    right: -2px;
    width: 10px;
    height: 10px;
    background: #ff4757;
    border-radius: 50%;
    animation: rewardPulse 1s ease-in-out infinite;
}

.nav-btn .nav-icon {
    position: relative;
}

@keyframes rewardPulse {

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

    50% {
        transform: scale(1.3);
        opacity: 0.7;
    }
}

/* New items indicator — пульсуюча червона точка на nav кнопці */
.nav-btn.has-new-item::after {
    content: '';
    position: absolute;
    top: 4px;
    right: calc(50% - 18px);
    width: 10px;
    height: 10px;
    background: #ff4757;
    border-radius: 50%;
    animation: taskDotPulse 2s ease-in-out infinite;
    box-shadow: 0 0 6px rgba(255, 71, 87, 0.6);
    z-index: 10;
    pointer-events: none;
}

@keyframes taskDotPulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
        box-shadow: 0 0 6px rgba(255, 71, 87, 0.6);
    }
    50% {
        transform: scale(1.4);
        opacity: 0.7;
        box-shadow: 0 0 14px rgba(255, 71, 87, 0.8), 0 0 28px rgba(255, 71, 87, 0.3);
    }
}

.new-item-dot {
    position: absolute;
    top: -3px;
    right: -3px;
    width: 10px;
    height: 10px;
    background: #ff4757;
    border-radius: 50%;
    animation: newItemPulse 1.5s ease-in-out infinite;
    z-index: 10;
}

.category-new-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    background: #ff4757;
    border-radius: 50%;
    margin-left: 6px;
    animation: newItemPulse 1.5s ease-in-out infinite;
}

.item-new-dot {
    position: absolute;
    top: -4px;
    right: -4px;
    width: 10px;
    height: 10px;
    background: #ff4757;
    border-radius: 50%;
    animation: newItemPulse 1.5s ease-in-out infinite;
    z-index: 10;
    pointer-events: none;
}

@keyframes newItemPulse {

    0%,
    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(255, 71, 87, 0.4);
    }

    50% {
        transform: scale(1.1);
        box-shadow: 0 0 8px 2px rgba(255, 71, 87, 0.6);
    }
}

/* === УНІКАЛЬНІ ПРЕДМЕТИ РІВНІВ === */

/* Золота межа (рівень 30) - елітна квадратна рамка */
.frame-golden-edge {
    position: relative;
    border-radius: 12px !important;
    overflow: visible !important;
    background-size: cover !important;
    background-position: center !important;
    box-shadow:
        0 0 0 3px var(--bg-color),
        0 0 0 6px #ffd700,
        0 0 20px rgba(255, 215, 0, 0.6);
    animation: goldenEdgeGlow 3s ease infinite;
}

@keyframes goldenEdgeGlow {

    0%,
    100% {
        box-shadow: 0 0 0 3px var(--bg-color), 0 0 0 6px #ffd700, 0 0 20px rgba(255, 215, 0, 0.6);
    }

    50% {
        box-shadow: 0 0 0 3px var(--bg-color), 0 0 0 6px #ffec8b, 0 0 35px rgba(255, 215, 0, 0.9), 0 0 50px rgba(255, 236, 139, 0.4);
    }
}

.golden-star {
    position: absolute;
    font-size: 14px;
    animation: starAppear 2s ease-out forwards;
    pointer-events: none;
    z-index: 10;
    filter: drop-shadow(0 0 3px rgba(255, 215, 0, 0.8));
}

@keyframes starAppear {
    0% {
        opacity: 0;
        transform: scale(0) rotate(0deg);
    }

    20% {
        opacity: 1;
        transform: scale(1.3) rotate(20deg);
    }

    80% {
        opacity: 1;
        transform: scale(1) rotate(-10deg);
    }

    100% {
        opacity: 0;
        transform: scale(0.5) translateY(-25px) rotate(180deg);
    }
}

/* === АНІМОВАНІ ФОНИ === */
.bg-aurora {
    animation: auroraShift 8s ease-in-out infinite;
    background-size: 200% 200% !important;
}

@keyframes auroraShift {
    0% {
        background-position: 0% 50%;
        filter: hue-rotate(0deg);
    }

    50% {
        background-position: 100% 50%;
        filter: hue-rotate(30deg);
    }

    100% {
        background-position: 0% 50%;
        filter: hue-rotate(0deg);
    }
}

.bg-radio-waves {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #1a1a2e, #16213e) !important;
}

.bg-radio-waves::before,
.bg-radio-waves::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 10px;
    height: 10px;
    border: 2px solid rgba(102, 126, 234, 0.4);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
    animation: radioWaveOptimized 4s linear infinite;
}

.bg-radio-waves::after {
    animation-delay: 2s;
}

@keyframes radioWaveOptimized {
    0% {
        width: 0;
        height: 0;
        opacity: 1;
        border-width: 4px;
    }

    100% {
        width: 400px;
        height: 400px;
        opacity: 0;
        border-width: 1px;
    }
}

.bg-matrix {
    position: relative;
    overflow: hidden;
    background: #000 !important;
}

.bg-matrix::before,
.bg-matrix::after {
    content: '0 1 0 1 1 0 1 0 0 1 0 1 1 0 1 0 0 1 0 1 1 0 1 0 0 1 0 1 1 0 1 0 0 1 0 1 1 0 1 0 0 1 0 1 1 0 1 0 0 1 0 1 1 0 1 0 0 1 0 1 1 0 1 0 0 1 0 1 1 0 1 0 0 1 0 1 1 0 1 0 0 1 0 1 1 0 1 0 0 1 0 1 1 0 1 0 0 1 0 1 1 0 1 0 0 1 0 1 1 0 1 0 0 1 0 1 1 0 1 0';
    position: absolute;
    top: -100%;
    left: 0;
    width: 100%;
    color: rgba(0, 255, 0, 0.3);
    font-family: 'Courier New', monospace;
    font-size: 14px;
    line-height: 1.2;
    word-break: break-all;
    text-shadow: 0 0 8px rgba(0, 255, 0, 0.5);
    white-space: pre-wrap;
    pointer-events: none;
    animation: matrixFallSlow 12s linear infinite;
}

.bg-matrix::after {
    left: 10px;
    color: rgba(0, 255, 0, 0.15);
    animation-duration: 18s;
    animation-delay: 3s;
}

@keyframes matrixFallSlow {
    from {
        transform: translateY(0);
    }

    to {
        transform: translateY(50%);
    }
}

.bg-galaxy {
    background-size: 300% 300% !important;
    animation: galaxyRotation 15s linear infinite;
}

@keyframes galaxyRotation {
    0% {
        background-position: 0% 0%;
        filter: hue-rotate(0deg);
    }

    50% {
        background-position: 100% 100%;
        filter: hue-rotate(20deg);
    }

    100% {
        background-position: 0% 0%;
        filter: hue-rotate(0deg);
    }
}

.bg-diamond {
    background-size: 400% 400% !important;
    animation: diamondShine 6s ease infinite;
    position: relative;
}

.bg-diamond::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, transparent 45%, rgba(255, 255, 255, 0.4) 50%, transparent 55%);
    background-size: 200% 200%;
    animation: lightStreak 3s linear infinite;
}

@keyframes diamondShine {

    0%,
    100% {
        filter: brightness(1) contrast(1.1);
    }

    50% {
        filter: brightness(1.2) contrast(1.3);
    }
}

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

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

.bg-atlantis {
    position: relative;
    background-size: 200% 200% !important;
    animation: atlantisDeep 8s ease-in-out infinite;
}

.bg-atlantis::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 50% 50%, rgba(0, 255, 255, 0.1), transparent 70%);
    animation: atlantisPulse 4s ease-in-out infinite;
}

@keyframes atlantisDeep {

    0%,
    100% {
        background-position: 50% 0%;
    }

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

@keyframes atlantisPulse {

    0%,
    100% {
        opacity: 0.3;
        transform: scale(1);
    }

    50% {
        opacity: 0.6;
        transform: scale(1.1);
    }
}

.bg-divine {
    background-size: 300% 300% !important;
    animation: divineGlow 5s ease-in-out infinite;
    box-shadow: inset 0 0 50px rgba(255, 255, 255, 0.5);
}

@keyframes divineGlow {

    0%,
    100% {
        background-position: 0% 50%;
        filter: brightness(1);
    }

    50% {
        background-position: 100% 50%;
        filter: brightness(1.2);
    }
}

.bg-crystal-gold {
    background: linear-gradient(135deg, #f7d047, #ffd700, #ffec8b, #f2c94c, #daa520, #ffd700, #fff8dc) !important;
    background-size: 300% 300% !important;
    animation: crystalGoldShift 6s ease-in-out infinite !important;
    position: relative;
}

.bg-crystal-gold::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 50% 50%, rgba(255, 215, 0, 0.2), transparent 80%);
    animation: divineGlow 3s infinite;
}

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

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

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

/* Trophy DimanNews (рівень 100) */
.trophy-dimannews {
    background: linear-gradient(135deg, #f7d047, #ffd700);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: bold;
    animation: trophyShine 2s ease-in-out infinite;
}

@keyframes trophyShine {

    0%,
    100% {
        filter: brightness(1);
    }

    50% {
        filter: brightness(1.3);
    }
}

/* Mythic rarity style */
.rarity-mythic {
    background: linear-gradient(135deg, rgba(247, 208, 71, 0.2), rgba(255, 215, 0, 0.2));
    border-color: #ffd700 !important;
    box-shadow: 0 0 15px rgba(247, 208, 71, 0.3);
}

/* User profile view modal */
.user-profile-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.9);
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

.user-profile-content {
    background: var(--bg);
    border-radius: 20px;
    padding: 20px;
    max-width: 350px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
}

/* === 2048 ITEMS === */

/* Frame 2048 - Authentic Game Style */
.avatar-frame-profile-border-frame_2048 {
    /* Gradient mimicking 2048 tiles: 2->8->64->512->2048 */
    background: conic-gradient(from 0deg,
            #eee4da 0%,
            /* 2 */
            #f2b179 25%,
            /* 8 */
            #f65e3b 50%,
            /* 64 */
            #edc850 75%,
            /* 512 */
            #edc22e 100%
            /* 2048 */
        );
    border: 3px solid #776e65 !important;
    box-shadow: 0 0 15px rgba(237, 194, 46, 0.4);
    position: relative;
    overflow: visible;
    /* To allow label to pop out */
    animation: frame2048Rotate 4s linear infinite;
}

.avatar-frame-profile-border-frame_2048::before {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    right: 2px;
    bottom: 2px;
    background: var(--bg);
    /* Inner mask */
    border-radius: inherit;
    z-index: 0;
}

.avatar-frame-profile-border-frame_2048>* {
    position: relative;
    z-index: 1;
}

.avatar-frame-profile-border-frame_2048::after {
    content: '2048';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.65rem;
    font-weight: 900;
    color: #f9f6f2;
    background: #edc22e;
    padding: 2px 6px;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    border: 1px solid #776e65;
    z-index: 2;
}

@keyframes frame2048Rotate {
    0% {
        filter: hue-rotate(0deg);
    }

    100% {
        filter: hue-rotate(360deg);
    }
}

/* Frame Wheel - Fortune Wheel Style */
.avatar-frame-wheel {
    background: conic-gradient(from 0deg,
            #e74c3c 0deg 32deg,
            #f2c94c 32deg 65deg,
            #27ae60 65deg 98deg,
            #3498db 98deg 130deg,
            #9b59b6 130deg 163deg,
            #e67e22 163deg 196deg,
            #1abc9c 196deg 229deg,
            #e91e63 229deg 262deg,
            #f39c12 262deg 295deg,
            #8e44ad 295deg 328deg,
            #ffd700 328deg 360deg);
    border: 3px solid #f2c94c !important;
    box-shadow: 0 0 20px rgba(242, 201, 76, 0.5);
    animation: frameWheelSpin 6s linear infinite;
}

.avatar-frame-wheel::before {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    right: 3px;
    bottom: 3px;
    background: var(--bg);
    border-radius: inherit;
    z-index: 0;
}

.avatar-frame-wheel>* {
    position: relative;
    z-index: 1;
}

.avatar-frame-wheel::after {
    content: '🎰';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 12px;
    background: linear-gradient(135deg, #f2c94c, #f5af19);
    padding: 2px 6px;
    border-radius: 8px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
    z-index: 10;
}

@keyframes frameWheelSpin {
    0% {
        filter: hue-rotate(0deg);
    }

    100% {
        filter: hue-rotate(360deg);
    }
}

/* Wheel sector labels */
.wheel-labels {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.wheel-sector-label {
    position: absolute;
    top: 50%;
    left: 50%;
    transform-origin: 0 0;
    width: 45%;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding-right: 8px;
    font-size: 11px;
    font-weight: bold;
    color: #fff;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}

/* Безкоштовні прокрути */
.wheel-free-spins {
    position: absolute;
    top: 80px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #1abc9c, #16a085);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: bold;
    font-size: 14px;
    box-shadow: 0 4px 15px rgba(26, 188, 156, 0.4);
    animation: freeSpinPulse 2s ease-in-out infinite;
    z-index: 10;
}

@keyframes freeSpinPulse {

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

    50% {
        transform: translateX(-50%) scale(1.05);
        box-shadow: 0 6px 20px rgba(26, 188, 156, 0.6);
    }
}

/* Badge Legend 2048 - Tile Style */
.profile-badge-icon.badge-title_legend_2048 {
    background: linear-gradient(135deg, #edc22e, #f9f6f2);
    color: #776e65;
    font-size: 0.5rem;
    font-weight: 900;
    width: 22px;
    height: 22px;
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(237, 194, 46, 0.5);
    border: 2px solid #bbada0;
}

.profile-badge-icon.badge-title_legend_2048::after {
    content: '2048';
    font-size: 0.45rem;
    font-weight: 900;
    color: #776e65;
}

/* Effect: Tiles 2048 - Falling tiles */
.profile-effect-tiles_2048 {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
    z-index: 1;
}

.profile-effect-tiles_2048::before,
.profile-effect-tiles_2048::after {
    content: '2 4 8 16 32 64 128 256 512 1024 2048';
    position: absolute;
    font-size: 0.6rem;
    font-weight: 900;
    color: rgba(237, 194, 46, 0.3);
    white-space: nowrap;
    animation: tiles2048Fall 8s linear infinite;
}

.profile-effect-tiles_2048::before {
    top: -20px;
    left: 10%;
    animation-delay: 0s;
}

.profile-effect-tiles_2048::after {
    top: -20px;
    left: 60%;
    animation-delay: 4s;
}

@keyframes tiles2048Fall {
    0% {
        transform: translateY(-20px) rotate(0deg);
        opacity: 0;
    }

    10% {
        opacity: 0.6;
    }

    90% {
        opacity: 0.6;
    }

    100% {
        transform: translateY(150px) rotate(15deg);
        opacity: 0;
    }
}

/* === Accessory: Helper Bunny - sits on top of avatar === */
.accessory-helper-bunny {
    position: absolute;
    top: -45px;
    left: 50%;
    transform: translateX(-50%);
    width: 50px;
    height: 60px;
    z-index: 15;
    pointer-events: none;
}

/* Body - round white body */
.accessory-helper-bunny::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 35px;
    background: linear-gradient(180deg, #ffffff 0%, #f5f5f5 100%);
    border-radius: 50% 50% 45% 45%;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15);
}

/* Ears */
.accessory-helper-bunny .bunny-ear {
    position: absolute;
    top: 0;
    width: 12px;
    height: 28px;
    background: linear-gradient(180deg, #ffffff 0%, #f0f0f0 100%);
    border-radius: 50% 50% 40% 40%;
}

.accessory-helper-bunny .bunny-ear.left {
    left: 10px;
    transform: rotate(-8deg);
}

.accessory-helper-bunny .bunny-ear.right {
    right: 10px;
    transform: rotate(8deg);
}

/* Inner ear pink */
.accessory-helper-bunny .bunny-ear::after {
    content: '';
    position: absolute;
    top: 5px;
    left: 50%;
    transform: translateX(-50%);
    width: 6px;
    height: 16px;
    background: linear-gradient(180deg, #ffccd5 0%, #ffb6c1 100%);
    border-radius: 50%;
}

/* Face */
.accessory-helper-bunny .bunny-face {
    position: absolute;
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 18px;
    z-index: 16;
}

/* Eyes */
.accessory-helper-bunny .bunny-eye {
    position: absolute;
    width: 6px;
    height: 8px;
    background: #1a1a1a;
    border-radius: 50%;
    top: 0;
}

.accessory-helper-bunny .bunny-eye.left {
    left: 4px;
}

.accessory-helper-bunny .bunny-eye.right {
    right: 4px;
}

/* Eye shine */
.accessory-helper-bunny .bunny-eye::after {
    content: '';
    position: absolute;
    width: 2px;
    height: 3px;
    background: white;
    border-radius: 50%;
    top: 1px;
    left: 1px;
}

/* Nose */
.accessory-helper-bunny .bunny-nose {
    position: absolute;
    bottom: 2px;
    left: 50%;
    transform: translateX(-50%);
    width: 5px;
    height: 4px;
    background: #ffb6c1;
    border-radius: 50%;
}

/* Paws - hanging over avatar edge */
.accessory-helper-bunny .bunny-paw {
    position: absolute;
    bottom: -18px;
    width: 10px;
    height: 22px;
    background: linear-gradient(180deg, #ffffff 0%, #f5f5f5 100%);
    border-radius: 40% 40% 50% 50%;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    z-index: 1;
}

.accessory-helper-bunny .bunny-paw.left {
    left: 8px;
}

.accessory-helper-bunny .bunny-paw.right {
    right: 8px;
}

/* Pink paw pad */
.accessory-helper-bunny .bunny-paw::after {
    content: '';
    position: absolute;
    bottom: 3px;
    left: 50%;
    transform: translateX(-50%);
    width: 6px;
    height: 8px;
    background: #ffb6c1;
    border-radius: 40% 40% 50% 50%;
}

/* === WHEEL OF FORTUNE === */
.wheel-fortune-card {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%) !important;
    border: 2px solid #f2c94c !important;
    overflow: hidden;
}

.wheel-fortune-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    background: linear-gradient(135deg, #f2c94c, #f5af19);
    color: #1a1a2e;
    padding: 3px 8px;
    border-radius: 10px;
    font-size: 0.6rem;
    font-weight: 700;
    z-index: 3;
    animation: badgePulse 2s ease-in-out infinite;
}

@keyframes badgePulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

.wheel-settings-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 28px;
    height: 28px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    z-index: 5;
    cursor: pointer;
    transition: all 0.2s;
}

.wheel-settings-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: rotate(45deg);
}

.wheel-preview {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle, #2d2d44 0%, #1a1a2e 100%) !important;
}

.wheel-mini {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: conic-gradient(#e74c3c 0deg 45deg,
            #f2c94c 45deg 90deg,
            #27ae60 90deg 135deg,
            #3498db 135deg 180deg,
            #9b59b6 180deg 225deg,
            #e67e22 225deg 270deg,
            #1abc9c 270deg 315deg,
            #e91e63 315deg 360deg);
    position: relative;
    animation: wheelSpin 10s linear infinite;
    box-shadow: 0 0 20px rgba(242, 201, 76, 0.3);
}

@keyframes wheelSpin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

.wheel-mini::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 20px;
    height: 20px;
    background: linear-gradient(135deg, #f2c94c, #f5af19);
    border-radius: 50%;
    border: 3px solid #1a1a2e;
    z-index: 2;
}

.wheel-mini-inner {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    border: 2px dashed rgba(255, 255, 255, 0.2);
}

.wheel-lights {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 85px;
    height: 85px;
    border-radius: 50%;
    background: transparent;
    pointer-events: none;
}

.wheel-lights::before {
    content: '• • • • • • • • • • • •';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 8px;
    color: #f2c94c;
    letter-spacing: 3px;
    animation: lightsFlash 1s ease-in-out infinite;
}

@keyframes lightsFlash {

    0%,
    100% {
        opacity: 1;
        text-shadow: 0 0 5px #f2c94c;
    }

    50% {
        opacity: 0.5;
        text-shadow: none;
    }
}

/* Wheel Fortune Screen */
.wheel-fortune-screen {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, #1a1a2e 0%, #0d0d1a 100%);
    background-size: cover;
    background-position: center;
    z-index: 1000;
    display: none;
    flex-direction: column;
    overflow-y: auto;
}

.wheel-fortune-screen.active {
    display: flex;
}

/* Wheel Header */
.wheel-header {
    display: flex;
    align-items: center;
    padding: 15px;
    gap: 15px;
}

.wheel-title {
    flex: 1;
    text-align: center;
    font-size: 1.3rem;
    font-weight: 700;
    color: #f2c94c;
    margin: 0;
    margin-right: 60px;
}

/* Prizes Info */
.wheel-prizes-info {
    background: var(--card-bg);
    margin: 0 15px 15px;
    padding: 15px;
    border-radius: 16px;
    border: 1px solid rgba(242, 201, 76, 0.2);
}

.wheel-prizes-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 12px;
    text-align: center;
}

.wheel-prizes-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}

.wheel-prize {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 8px 4px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.05);
}

.wheel-prize .prize-icon {
    font-size: 1rem;
    margin-bottom: 2px;
}

.wheel-prize .prize-val {
    font-size: 0.8rem;
    font-weight: 700;
    color: white;
}

.wheel-prize .prize-chance {
    font-size: 0.65rem;
    color: var(--text-secondary);
    margin-top: 2px;
}

.wheel-prize.rarity-common {
    border-left: 2px solid #aaa;
}

.wheel-prize.rarity-uncommon {
    border-left: 2px solid #4ade80;
}

.wheel-prize.rarity-rare {
    border-left: 2px solid #60a5fa;
}

.wheel-prize.rarity-epic {
    border-left: 2px solid #a855f7;
}

.wheel-prize.rarity-legendary {
    border-left: 2px solid #f59e0b;
}

.wheel-prize.rarity-mythic {
    border-left: 2px solid #ec4899;
}

.wheel-prize.jackpot {
    background: linear-gradient(135deg, rgba(236, 72, 153, 0.2), rgba(168, 85, 247, 0.2));
    animation: jackpotPulse 2s ease-in-out infinite;
}

@keyframes jackpotPulse {

    0%,
    100% {
        box-shadow: 0 0 5px rgba(236, 72, 153, 0.3);
    }

    50% {
        box-shadow: 0 0 15px rgba(236, 72, 153, 0.5);
    }
}

/* Wheel Wrapper */
.wheel-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    min-height: 280px;
}

.wheel-outer {
    position: relative;
    width: 260px;
    height: 260px;
    border-radius: 50%;
    background: linear-gradient(135deg, #2c2c3e, #1a1a2e);
    box-shadow:
        0 0 0 6px #f2c94c,
        0 0 30px rgba(242, 201, 76, 0.4),
        inset 0 0 30px rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
}

.wheel-outer::before {
    content: '';
    position: absolute;
    width: 280px;
    height: 280px;
    border-radius: 50%;
    background: repeating-conic-gradient(#f2c94c 0deg 10deg,
            transparent 10deg 20deg);
    opacity: 0.3;
    animation: lightsRotate 4s linear infinite;
}

@keyframes lightsRotate {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

.wheel-main {
    width: 230px;
    height: 230px;
    border-radius: 50%;
    background: conic-gradient(#4ade80 0deg 45deg,
            #4ade80 45deg 90deg,
            #60a5fa 90deg 135deg,
            #3b82f6 135deg 180deg,
            #a855f7 180deg 225deg,
            #f59e0b 225deg 270deg,
            #ec4899 270deg 315deg,
            #f43f5e 315deg 360deg);
    position: relative;
    transition: transform 5s cubic-bezier(0.17, 0.67, 0.12, 0.99);
    box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.3);
}

/* Сектори рендеряться через SVG в JS */

/* Bottom Panel */
.wheel-bottom-panel {
    background: var(--card-bg);
    padding: 20px;
    margin: 15px;
    border-radius: 20px;
    border: 1px solid rgba(242, 201, 76, 0.2);
}

.wheel-info-row {
    display: flex;
    justify-content: space-around;
    margin-bottom: 15px;
}

.wheel-balance,
.wheel-price {
    text-align: center;
}

.wheel-label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.wheel-value {
    font-size: 1.2rem;
    font-weight: 700;
    color: white;
}

.wheel-value.gold {
    color: #f2c94c;
}

.wheel-spin-btn {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #f2c94c, #f5af19);
    border: none;
    border-radius: 16px;
    color: #1a1a2e;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    box-shadow: 0 5px 20px rgba(242, 201, 76, 0.4);
    transition: all 0.2s;
}

.wheel-spin-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(242, 201, 76, 0.5);
}

.wheel-spin-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.wheel-spin-btn .spin-icon {
    font-size: 1.3rem;
}

.wheel-spin-btn.spinning {
    animation: btnPulse 0.5s ease-in-out infinite;
}

@keyframes btnPulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(0.98);
    }
}

/* Wheel Settings Modal */
.wheel-settings-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.9);
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.wheel-settings-modal.active {
    display: flex;
}

.wheel-settings-content {
    background: #1e1e2e;
    border-radius: 20px;
    padding: 25px;
    width: 100%;
    max-width: 400px;
    max-height: 80vh;
    overflow-y: auto;
}

.wheel-settings-title {
    font-size: 1.3rem;
    font-weight: 700;
    color: #f2c94c;
    text-align: center;
    margin-bottom: 20px;
}

.wheel-setting-group {
    margin-bottom: 20px;
}

.wheel-setting-label {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 8px;
    display: block;
}

.wheel-bg-upload {
    width: 100%;
    height: 120px;
    border: 2px dashed rgba(242, 201, 76, 0.3);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    background-size: cover;
    background-position: center;
    position: relative;
}

.wheel-bg-upload:hover {
    border-color: #f2c94c;
    background-color: rgba(242, 201, 76, 0.05);
}

.wheel-bg-upload-icon {
    font-size: 2rem;
    margin-bottom: 8px;
}

.wheel-bg-upload-text {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.wheel-bg-upload.has-image .wheel-bg-upload-icon,
.wheel-bg-upload.has-image .wheel-bg-upload-text {
    display: none;
}

.wheel-bg-remove {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 28px;
    height: 28px;
    background: rgba(229, 92, 92, 0.9);
    border-radius: 50%;
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 0.8rem;
}

.wheel-bg-upload.has-image .wheel-bg-remove {
    display: flex;
}

.wheel-settings-btns {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.wheel-settings-btn {
    flex: 1;
    padding: 12px;
    border-radius: 12px;
    border: none;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.wheel-settings-btn.save {
    background: linear-gradient(135deg, #f2c94c, #f5af19);
    color: #1a1a2e;
}

.wheel-settings-btn.cancel {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

/* === BETA BANNER === */
.beta-banner {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.beta-banner-content {
    background: linear-gradient(135deg, #1e1e2e 0%, #2d2d44 100%);
    border-radius: 20px;
    padding: 25px;
    max-width: 340px;
    width: 100%;
    position: relative;
    border: 2px solid rgba(102, 126, 234, 0.4);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.beta-banner-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    color: white;
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.beta-banner-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

.beta-banner-icon {
    font-size: 3rem;
    text-align: center;
    margin-bottom: 10px;
}

.beta-banner-title {
    font-size: 1.4rem;
    font-weight: 700;
    text-align: center;
    color: #667eea;
    margin-bottom: 15px;
}

.beta-banner-text {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.6;
    text-align: center;
    margin-bottom: 20px;
}

.beta-banner-btn {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border: none;
    border-radius: 12px;
    color: white;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.beta-banner-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(102, 126, 234, 0.4);
}

/* Рамка Колесо Фортуни */
.avatar-frame-wheel {
    background: conic-gradient(from 0deg,
            #e74c3c 0%,
            #f2c94c 12.5%,
            #27ae60 25%,
            #3498db 37.5%,
            #9b59b6 50%,
            #e67e22 62.5%,
            #1abc9c 75%,
            #e91e63 87.5%,
            #e74c3c 100%);
    border: 3px solid #ffd700 !important;
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.5), inset 0 0 10px rgba(255, 255, 255, 0.2);
    position: relative;
    overflow: visible;
    animation: wheelFrameRotate 6s linear infinite;
}

@keyframes wheelFrameRotate {
    0% {
        filter: hue-rotate(0deg);
    }

    100% {
        filter: hue-rotate(360deg);
    }
}

.avatar-frame-wheel::before {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    right: 3px;
    bottom: 3px;
    background: var(--bg);
    border-radius: inherit;
    z-index: 0;
}

.avatar-frame-wheel>* {
    position: relative;
    z-index: 1;
}

.avatar-frame-wheel::after {
    content: '🎰';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.9rem;
    background: linear-gradient(135deg, #ffd700, #f2c94c);
    padding: 2px 8px;
    border-radius: 8px;
    z-index: 2;
    animation: wheelBadgePulse 2s infinite ease-in-out;
}

@keyframes wheelBadgePulse {

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

    50% {
        transform: translateX(-50%) scale(1.1);
    }
}

/* ============================================
   НОВІ СТИЛІ КОЛЕСА ФОРТУНИ
   ============================================ */

/* Контейнер екрану */
.wheel-fortune-screen {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #0d0d1a !important;
    z-index: 1000;
    display: none;
    flex-direction: column;
    overflow-y: auto;
}

.wheel-fortune-screen.active {
    display: flex;
}

/* ========== WHEEL OF FORTUNE - PREMIUM GOLD ========== */

#wheel-game-screen {
    position: relative;
    min-height: 100vh;
    padding: 16px;
    padding-bottom: 100px;
}

.wheel-screen-container {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

/* Back Button */
.wheel-back-btn {
    position: absolute;
    top: 0;
    left: 0;
    width: 44px;
    height: 44px;
    background: rgba(20, 18, 15, 0.7);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(212, 175, 85, 0.25);
    border-radius: 50%;
    color: #d4af55;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    z-index: 10;
}

.wheel-back-btn:active {
    transform: scale(0.95);
    background: rgba(212, 175, 85, 0.15);
}

/* Settings Button */
.wheel-settings-btn {
    position: absolute;
    top: 0;
    right: 0;
    width: 44px;
    height: 44px;
    background: rgba(20, 18, 15, 0.7);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(212, 175, 85, 0.25);
    border-radius: 50%;
    color: #d4af55;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
}

/* Free Spins Banner */
.wheel-free-banner {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    background: linear-gradient(90deg, rgba(212, 175, 85, 0.15), rgba(212, 175, 85, 0.08));
    border: 1px solid rgba(212, 175, 85, 0.35);
    border-radius: 25px;
    margin-top: 50px;
}

.wheel-free-text {
    font-size: 0.9rem;
    color: #d4af55;
    font-weight: 500;
}

.wheel-free-text strong {
    font-weight: 700;
}

/* ===== WHEEL WRAPPER ===== */
.wheel-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 10px;
}

/* Golden Ring Frame */
.wheel-golden-ring {
    position: relative;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    padding: 8px;
    background: linear-gradient(145deg,
            #f5e6c8 0%,
            #d4af55 15%,
            #9a7b3a 35%,
            #d4af55 50%,
            #9a7b3a 65%,
            #d4af55 85%,
            #f5e6c8 100%);
    box-shadow:
        0 0 60px rgba(212, 175, 85, 0.5),
        0 0 100px rgba(212, 175, 85, 0.25),
        0 0 150px rgba(212, 175, 85, 0.15),
        inset 0 0 40px rgba(0, 0, 0, 0.4);
    animation: wheelGlow 3s ease-in-out infinite;
}

@keyframes wheelGlow {

    0%,
    100% {
        box-shadow:
            0 0 60px rgba(212, 175, 85, 0.5),
            0 0 100px rgba(212, 175, 85, 0.25),
            0 0 150px rgba(212, 175, 85, 0.15),
            inset 0 0 40px rgba(0, 0, 0, 0.4);
    }

    50% {
        box-shadow:
            0 0 80px rgba(212, 175, 85, 0.6),
            0 0 120px rgba(212, 175, 85, 0.35),
            0 0 180px rgba(212, 175, 85, 0.2),
            inset 0 0 40px rgba(0, 0, 0, 0.4);
    }
}

/* Pointer Triangle - CSS трикутник */
.wheel-pointer {
    position: absolute;
    top: -6px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 30;
    width: 0;
    height: 0;
    border-left: 14px solid transparent;
    border-right: 14px solid transparent;
    border-top: 28px solid #d4a853;
    filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.5));
}

.wheel-pointer::after {
    content: '';
    position: absolute;
    top: -26px;
    left: -10px;
    width: 0;
    height: 0;
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-top: 22px solid #f5e6c8;
}

/* Wheel Spin Area */
.wheel-spin-area {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: #0a0908;
    overflow: hidden;
    transition: transform 5s cubic-bezier(0.17, 0.67, 0.12, 0.99);
    display: flex;
    align-items: center;
    justify-content: center;
}

.wheel-spin-area svg {
    width: 100%;
    height: 100%;
}

/* Center Circle - кругле! */
.wheel-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 20;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(145deg, #1a1815, #0d0c0a);
    border: 3px solid #d4a853;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow:
        0 4px 15px rgba(0, 0, 0, 0.6),
        inset 0 2px 8px rgba(212, 175, 85, 0.1);
}

.wheel-center-star {
    width: 28px;
    height: 28px;
}

/* ===== SPIN BUTTON ===== */
.wheel-spin-btn {
    width: 280px;
    padding: 16px 32px;
    background: linear-gradient(145deg,
            rgba(20, 18, 15, 0.95) 0%,
            rgba(15, 13, 10, 0.98) 100%);
    backdrop-filter: blur(20px);
    border: 2px solid rgba(212, 175, 85, 0.5);
    border-radius: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    cursor: pointer;
    transition: all 0.25s ease;
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

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

.wheel-spin-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.wheel-spin-text {
    font-size: 1.1rem;
    font-weight: 700;
    color: #f5e6c8;
    letter-spacing: 2px;
}

.wheel-spin-price {
    font-size: 1rem;
    font-weight: 700;
    color: #d4af55;
    padding-left: 16px;
    border-left: 1px solid rgba(212, 175, 85, 0.3);
}

/* Free spin state */
.wheel-spin-btn.free {
    border-color: #d4af55;
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.5),
        0 0 20px rgba(212, 175, 85, 0.2);
}

.wheel-spin-btn.free .wheel-spin-text {
    color: #d4af55;
}

.wheel-spin-btn.free .wheel-spin-price {
    display: none;
}

/* Disabled state */
.wheel-spin-btn.disabled {
    opacity: 0.6;
    border-color: rgba(150, 140, 130, 0.3);
}

.wheel-spin-btn.disabled .wheel-spin-text {
    color: rgba(200, 190, 180, 0.7);
}

/* Spinning state */
.wheel-spin-btn.spinning {
    opacity: 0.7;
    pointer-events: none;
}

.wheel-spin-btn.spinning .wheel-spin-text::after {
    content: '...';
    animation: dots 1.5s steps(4, end) infinite;
}

@keyframes dots {

    0%,
    20% {
        content: '';
    }

    40% {
        content: '.';
    }

    60% {
        content: '..';
    }

    80%,
    100% {
        content: '...';
    }
}

/* ===== CHANCES SECTION ===== */
.wheel-chances {
    width: 100%;
    max-width: 320px;
}

.wheel-chances-title {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
    padding-left: 4px;
}

.wheel-chances-title span {
    font-size: 0.85rem;
    font-weight: 600;
    color: rgba(212, 175, 85, 0.8);
    white-space: nowrap;
}

.wheel-chances-title::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, rgba(212, 175, 85, 0.3), transparent);
}

/* Chances Grid - подібний до кейсів */
.wheel-chances-grid {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.wheel-chance-item {
    display: flex;
    align-items: center;
    padding: 10px 14px;
    background: rgba(15, 13, 10, 0.6);
    border-radius: 10px;
    border-left: 3px solid;
    transition: background 0.2s;
}

.wheel-chance-item:active {
    background: rgba(212, 175, 85, 0.08);
}

.wheel-chance-icon {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
    font-size: 1.1rem;
}

.wheel-chance-name {
    flex: 1;
    font-size: 0.9rem;
    font-weight: 500;
    color: rgba(245, 240, 230, 0.9);
}

.wheel-chance-percent {
    font-size: 0.85rem;
    font-weight: 600;
    color: rgba(212, 175, 85, 0.8);
}

/* Tier colors */
.wheel-chance-item.tier-common {
    border-color: rgba(180, 170, 150, 0.5);
}

.wheel-chance-item.tier-common .wheel-chance-icon {
    color: #b4aa96;
}

.wheel-chance-item.tier-uncommon {
    border-color: rgba(130, 200, 140, 0.6);
}

.wheel-chance-item.tier-uncommon .wheel-chance-icon {
    color: #82c88c;
}

.wheel-chance-item.tier-rare {
    border-color: rgba(100, 160, 220, 0.7);
}

.wheel-chance-item.tier-rare .wheel-chance-icon {
    color: #64a0dc;
}

.wheel-chance-item.tier-epic {
    border-color: rgba(180, 120, 220, 0.7);
}

.wheel-chance-item.tier-epic .wheel-chance-icon {
    color: #b478dc;
}

.wheel-chance-item.tier-legendary {
    border-color: rgba(242, 201, 76, 0.7);
}

.wheel-chance-item.tier-legendary .wheel-chance-icon {
    color: #f2c94c;
}

.wheel-chance-item.tier-jackpot {
    border-color: #ffd700;
    background: linear-gradient(90deg, rgba(255, 215, 0, 0.1), rgba(212, 175, 85, 0.05));
}

.wheel-chance-item.tier-jackpot .wheel-chance-icon {
    color: #ffd700;
    animation: starPulse 2s ease-in-out infinite;
}

.wheel-chance-item.tier-jackpot .wheel-chance-name {
    color: #fff9e5;
    font-weight: 600;
}

.wheel-chance-item.tier-jackpot .wheel-chance-percent {
    color: #ffd700;
}

@keyframes starPulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 0.9;
    }

    50% {
        transform: scale(1.15);
        opacity: 1;
    }
}

/* ==========================================
   WHEEL RESULT MODAL - Premium Dark Style
   ========================================== */

.wheel-result-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(12px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: fadeIn 0.3s ease;
}

.wheel-result-modal {
    position: relative;
    width: 90%;
    max-width: 320px;
    background: linear-gradient(165deg,
            rgba(30, 27, 24, 0.98) 0%,
            rgba(20, 18, 16, 0.99) 100%);
    border: 1px solid rgba(212, 175, 85, 0.25);
    border-radius: 24px;
    padding: 32px 24px;
    text-align: center;
    box-shadow:
        0 0 0 1px rgba(0, 0, 0, 0.5),
        0 20px 60px rgba(0, 0, 0, 0.7),
        0 0 40px rgba(212, 175, 85, 0.1);
    animation: modalSlideUp 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    overflow: hidden;
}

@keyframes modalSlideUp {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
    }

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

/* Glow effect behind modal */
.wheel-result-glow {
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(ellipse at center,
            rgba(212, 175, 85, 0.08) 0%,
            transparent 60%);
    pointer-events: none;
}

/* Tier header */
.wheel-result-header {
    margin-bottom: 16px;
}

.wheel-result-tier {
    display: inline-block;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 2px;
    padding: 6px 16px;
    border-radius: 20px;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(100, 100, 100, 0.2);
    color: rgba(180, 170, 160, 0.8);
}

/* Tier-specific header colors */
.wheel-result-modal.common .wheel-result-tier {
    color: rgba(180, 170, 160, 0.8);
    border-color: rgba(100, 100, 100, 0.3);
}

.wheel-result-modal.uncommon .wheel-result-tier {
    color: rgba(130, 200, 140, 0.9);
    border-color: rgba(130, 200, 140, 0.3);
}

.wheel-result-modal.rare .wheel-result-tier {
    color: rgba(120, 160, 220, 0.95);
    border-color: rgba(120, 160, 220, 0.35);
}

.wheel-result-modal.epic .wheel-result-tier {
    color: rgba(180, 140, 220, 0.95);
    border-color: rgba(180, 140, 220, 0.35);
}

.wheel-result-modal.legendary .wheel-result-tier {
    color: #d4af55;
    border-color: rgba(212, 175, 85, 0.4);
    background: rgba(212, 175, 85, 0.1);
}

.wheel-result-modal.jackpot .wheel-result-tier {
    color: #ffd700;
    border-color: rgba(255, 215, 0, 0.5);
    background: linear-gradient(90deg, rgba(255, 215, 0, 0.15), rgba(212, 175, 85, 0.1));
    animation: jackpotGlow 1.5s ease-in-out infinite;
}

@keyframes jackpotGlow {

    0%,
    100% {
        box-shadow: 0 0 10px rgba(255, 215, 0, 0.2);
    }

    50% {
        box-shadow: 0 0 20px rgba(255, 215, 0, 0.4), 0 0 40px rgba(255, 215, 0, 0.15);
    }
}

/* Title */
.wheel-result-title {
    font-size: 1.3rem;
    font-weight: 700;
    color: rgba(245, 235, 220, 0.95);
    margin-bottom: 20px;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.wheel-result-modal.jackpot .wheel-result-title {
    color: #ffd700;
    text-shadow: 0 0 20px rgba(255, 215, 0, 0.3);
}

/* Content */
.wheel-result-content {
    margin-bottom: 24px;
}

.wheel-result-value {
    font-size: 2.5rem;
    font-weight: 800;
    color: #d4af55;
    margin-bottom: 8px;
    text-shadow: 0 2px 12px rgba(212, 175, 85, 0.3);
}

.wheel-result-modal.jackpot .wheel-result-value {
    color: #ffd700;
    font-size: 3rem;
    text-shadow: 0 0 30px rgba(255, 215, 0, 0.5);
    animation: valuePulse 1s ease-in-out infinite;
}

@keyframes valuePulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

.wheel-result-item {
    font-size: 1.4rem;
    font-weight: 700;
    color: #f2c94c;
    margin-bottom: 8px;
}

.wheel-result-profit {
    font-size: 1rem;
    font-weight: 600;
}

.wheel-result-subtext {
    font-size: 0.85rem;
    color: rgba(180, 170, 160, 0.7);
}

/* Button */
.wheel-result-btn {
    width: 100%;
    padding: 16px 32px;
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: 1px;
    color: rgba(30, 25, 20, 0.95);
    background: linear-gradient(165deg,
            #f5e6c8 0%,
            #d4af55 50%,
            #a08030 100%);
    border: none;
    border-radius: 14px;
    cursor: pointer;
    box-shadow:
        0 4px 16px rgba(212, 175, 85, 0.25),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    transition: all 0.2s ease;
}

.wheel-result-btn:hover {
    transform: translateY(-2px);
    box-shadow:
        0 6px 24px rgba(212, 175, 85, 0.35),
        inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

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

/* Legacy support */
.spin-btn {
    display: none;
}

.spin-btn-text {
    font-weight: 700;
}

.spin-btn-price {
    background: rgba(0, 0, 0, 0.2);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.9rem;
}

/* Підсвітка режиму */
.mode-tile.highlight-mode {
    animation: premiumHighlight 0.6s ease-in-out 3;
    border-color: rgba(212, 175, 85, 0.7);
}

@keyframes premiumHighlight {

    0%,
    100% {
        transform: translateY(0);
        box-shadow: 0 8px 32px rgba(0, 0, 0, 0.45), 0 0 25px rgba(212, 175, 85, 0.2);
    }

    50% {
        transform: translateY(-4px);
        box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5), 0 0 40px rgba(212, 175, 85, 0.3);
    }
}

/* ===========================================
   ФАЗА 3: Відключення iOS 26 Glass під час спіну
   Це значно покращує FPS на мобільних пристроях
   =========================================== */

/* Вимкнення multilayer pseudo-elements */
.spinning-active .header.glass-effect::before,
.spinning-active .header.glass-effect::after,
.spinning-active .bottom-nav.glass-effect::before,
.spinning-active .bottom-nav.glass-effect::after {
    display: none !important;
}

/* Спрощення glass-effect до простого фону */
.spinning-active .header.glass-effect,
.spinning-active .balance-badge {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

.spinning-active .header.glass-effect {
    background: rgba(15, 15, 25, 0.95) !important;
    box-shadow: none !important;
}

/* Навігація - мінімальний glass під час спіну */
.spinning-active .bottom-nav.glass-effect {
    backdrop-filter: blur(10px) !important;
    -webkit-backdrop-filter: blur(10px) !important;
    background: rgba(18, 18, 30, 0.9) !important;
}

/* Reduced motion - вимкнення анімацій */
@media (prefers-reduced-motion: reduce) {

    .header.glass-effect::before,
    .bottom-nav.glass-effect::before {
        transition: none !important;
    }
}

/* Спрощене модальне вікно для режиму без анімацій */
.no-anim-modal .win-modal {
    animation: none !important;
}

.no-anim-modal .win-modal-icon {
    animation: none !important;
}

/* ====== СИСТЕМА ДРУЗІВ ====== */
.privacy-toggle-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(0, 0, 0, 0.2);
    padding: 12px 14px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.friend-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(0, 0, 0, 0.2);
    padding: 10px 12px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.friend-item-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.friend-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(102, 126, 234, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    border: 2px solid rgba(255, 255, 255, 0.1);
}

.friend-avatar img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

.friend-name {
    font-weight: 600;
    font-size: 0.9rem;
    color: #fff;
}

.friend-username {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.5);
}

.friend-actions {
    display: flex;
    gap: 6px;
}

.friend-action-btn {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    padding: 6px 10px;
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s;
}

.friend-action-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.friend-action-btn.accept {
    background: rgba(69, 189, 100, 0.2);
    color: #45bd64;
}

.friend-action-btn.reject {
    background: rgba(229, 92, 92, 0.2);
    color: #e55c5c;
}

.friend-action-btn.view {
    background: rgba(102, 126, 234, 0.2);
    color: #667eea;
}

.friend-action-btn.remove {
    background: rgba(229, 92, 92, 0.15);
    color: #e55c5c;
}