:root {
    /* Transparent Glass Theme */
    --bg: transparent;
    --bg-secondary: rgba(28, 28, 30, 0.4);
    --bg-card: rgba(44, 44, 46, 0.5);
    --bg-hover: rgba(58, 58, 60, 0.6);
    --bg-tertiary: rgba(72, 72, 74, 0.5);
    --text: #ffffff;
    --text-secondary: #e5e5ea;
    --text-dim: rgba(255, 255, 255, 0.6);
    /* Macintosh Beige Theme */
    --accent: #C9B59B;
    --accent-hover: #B8A48A;
    --accent-glow: rgba(201, 181, 155, 0.3);
    --border: rgba(255, 255, 255, 0.08);
    --separator: rgba(255, 255, 255, 0.06);
    /* Liquid Glass vars */
    --glass-bg: rgba(28, 28, 30, 0.4);
    --glass-border: rgba(255, 255, 255, 0.1);
    --glass-blur: 25px;
}

/* ===== SPLASH LOADING SCREEN ===== */
.splash-screen {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: #000000;
}

.splash-background {
    position: absolute;
    inset: -20px;
    background: linear-gradient(135deg,
            #050508 0%,
            #0a0a12 25%,
            #000000 50%,
            #050508 75%,
            #0a0a12 100%);
    background-size: 400% 400%;
    animation: splashGradient 8s ease infinite;
    filter: blur(20px);
}

.splash-background::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 30% 40%, rgba(0, 180, 216, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 70% 60%, rgba(0, 122, 255, 0.05) 0%, transparent 50%);
    animation: splashPulse 4s ease-in-out infinite;
}

@keyframes splashGradient {

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

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

@keyframes splashPulse {

    0%,
    100% {
        opacity: 0.5;
    }

    50% {
        opacity: 1;
    }
}

.splash-content {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 20px;
    padding: 20px;
    text-align: center;
}

.splash-logo {
    animation: splashFloat 3s ease-in-out infinite;
}

@keyframes splashFloat {

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

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

.splash-logo-img {
    width: 100px;
    height: 100px;
    object-fit: contain;
    filter: drop-shadow(0 0 20px rgba(0, 180, 216, 0.5));
    border-radius: 24px;
}

.splash-sticker {
    margin: 20px 0;
}

.splash-sticker-img {
    width: 250px;
    height: 250px;
    object-fit: contain;
    filter: drop-shadow(0 0 40px rgba(0, 122, 255, 0.4));
}

.splash-progress-container {
    width: 280px;
    max-width: 90vw;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.splash-progress-bar {
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    overflow: hidden;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.splash-progress-fill {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, #00b4d8 0%, #007aff 50%, #00b4d8 100%);
    background-size: 200% 100%;
    border-radius: 3px;
    transition: width 0.3s ease-out;
    animation: splashProgressGlow 2s ease-in-out infinite;
}

@keyframes splashProgressGlow {

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

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

.splash-progress-text {
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.5px;
}

.splash-screen.fade-out {
    animation: splashFadeOut 0.2s ease-out forwards;
}

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

    100% {
        opacity: 0;
        pointer-events: none;
    }
}

/* Animated WebP Stickers - GPU Optimized */
.animated-sticker {
    width: 120px;
    height: 120px;
    object-fit: contain;
    /* GPU acceleration for smooth animation */
    transform: translateZ(0);
    -webkit-transform: translateZ(0);
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    perspective: 1000px;
    will-change: transform;
    /* Smooth rendering */
    image-rendering: auto;
    /* Prevent layout shifts */
    contain: strict;
}

/* Payment Timer Styles */
.timer-normal {
    color: var(--text-dim);
    font-weight: 500;
}

.timer-warning {
    color: #ff9500;
    font-weight: 600;
    animation: pulse-warning 1s infinite;
}

.timer-expired {
    color: #ff3b30;
    font-weight: 600;
}

@keyframes pulse-warning {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.6;
    }
}

html {
    width: 100%;
    height: 100%;
    max-height: 100%;
    margin: 0;
    padding: 0;
    background: #1c1c1e;
    overflow: hidden !important;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    touch-action: none;
    -ms-touch-action: none;
    -webkit-text-size-adjust: 100%;
    -moz-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
    text-size-adjust: 100%;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overscroll-behavior: none;
    -webkit-overflow-scrolling: none;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
    touch-action: pan-x pan-y;
    -ms-touch-action: pan-x pan-y;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Text', 'Helvetica Neue', sans-serif;
    background: linear-gradient(180deg, #0a0e1a 0%, #0d1220 100%);
    color: var(--text);
    height: 100vh;
    height: 100dvh;
    max-height: 100vh;
    max-height: 100dvh;
    line-height: 1.47059;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow: hidden !important;
    overscroll-behavior: none;
    -webkit-overflow-scrolling: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    margin: 0;
    padding: 0;
    width: 100%;
    touch-action: none;
    -ms-touch-action: none;
    will-change: auto;
}

* {
    -webkit-tap-highlight-color: transparent;
}

/* Background removed - using simple body background */

/* ===== AUTH ===== */
.auth-screen {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 24px;
    position: relative;
    z-index: 1;
}

.auth-container {
    width: 100%;
    max-width: 340px;
    text-align: center;
}

.auth-container h1 {
    font-size: 32px;
    font-weight: 600;
    margin-bottom: 8px;
    letter-spacing: -0.5px;
}

.auth-container h1 .mgs-x-letter {
    font-weight: 300;
    color: #00b4d8;
    letter-spacing: 2px;
    text-shadow: 0 0 10px rgba(0, 180, 216, 0.5);
    font-style: italic;
    transform: skewX(-10deg);
    display: inline-block;
    margin-left: 4px;
}

.auth-container p {
    color: var(--text-dim);
    margin-bottom: 32px;
    font-size: 15px;
}

#telegramWidgetContainer {
    margin: 20px 0;
    text-align: center;
}

#telegramWidgetContainer iframe {
    border-radius: 12px;
    overflow: hidden;
}

#authLoading {
    text-align: center;
    padding: 20px;
}

#authLoading div:first-child {
    font-size: 32px;
    margin-bottom: 12px;
    animation: pulse 2s infinite;
}

#authLoading div:last-child {
    color: var(--text-dim);
    font-size: 15px;
}

/* ===== FORM ===== */
.form-input {
    width: 100%;
    padding: 14px 16px;
    margin-bottom: 12px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    color: var(--text);
    font-size: 15px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.form-input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

/* ===== TELEGRAM LOGIN BUTTON ===== */
.btn-telegram {
    width: 100%;
    padding: 16px 24px;
    background: linear-gradient(135deg, #0088cc 0%, #229ED9 100%);
    border: none;
    border-radius: 12px;
    color: white;
    font-size: 17px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px rgba(0, 136, 204, 0.3);
    margin-bottom: 16px;
    -webkit-tap-highlight-color: transparent;
}

.btn-telegram:hover {
    background: linear-gradient(135deg, #0077b6 0%, #1e8bc7 100%);
    box-shadow: 0 6px 16px rgba(0, 136, 204, 0.4);
    transform: translateY(-1px);
}

.btn-telegram:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(0, 136, 204, 0.3);
}

.telegram-btn-icon {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    display: block;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.form-input::placeholder {
    color: var(--text-dim);
}

#usernameCheckResult {
    margin-top: 12px;
    padding: 12px 16px;
    border-radius: 12px;
    font-size: 14px;
    line-height: 1.4;
    transition: all 0.12s ease;
}

#usernameCheckResult:empty {
    display: none !important;
}

#localAuthBtn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    pointer-events: none;
}

/* ===== BUTTONS (iOS Style) ===== */
.btn {
    display: block;
    width: 100%;
    padding: 14px 20px;
    border: none;
    border-radius: 10px;
    font-size: 17px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
    margin-top: 8px;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
}

.btn-primary {
    background: var(--accent);
    color: white;
}

.btn-primary:active {
    background: var(--accent-hover);
    transform: scale(0.98);
}

.btn-secondary {
    background: var(--bg-card);
    color: var(--accent);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    background: var(--bg-hover);
}

.btn-secondary:active {
    background: var(--bg-hover);
    opacity: 0.8;
}

/* ===== MAIN ===== */
#mainContent {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1;
    height: 100vh;
    max-height: 100vh;
    overflow: hidden;
    width: 100%;
    margin: 0;
    padding: 0;
    padding-bottom: 90px;
    background: linear-gradient(180deg, #0a0e1a 0%, #0d1220 100%);
    display: flex;
    flex-direction: column;
    will-change: auto;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

#catalogTab,
#profileTab {
    position: relative;
    top: 0;
    left: 0;
    transform: translateX(0) translateY(0);
    background: transparent;
    height: calc(100vh - 90px);
    max-height: calc(100vh - 90px);
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    will-change: auto;
}

@keyframes fadeInTab {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* ===== LOADING ===== */
.loading-overlay {
    position: fixed;
    inset: 0;
    background: rgba(13, 13, 15, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.loading-overlay p {
    color: var(--text-dim);
    font-size: 15px;
}

/* ===== SCREEN HEADERS (iOS Style) ===== */
.ios-screen-header {
    padding: 16px 20px 8px;
    position: relative;
    background: transparent;
    width: 100%;
    margin: 0;
}

.currency-switcher {
    position: absolute;
    top: 16px;
    right: 20px;
    display: flex;
    gap: 4px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 2px;
}

.currency-btn {
    padding: 6px 12px;
    background: transparent;
    border: none;
    border-radius: 6px;
    color: var(--text-dim);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    -webkit-tap-highlight-color: transparent;
}

.currency-btn.active {
    background: var(--accent);
    color: #fff;
}

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

.ios-screen-title {
    font-size: 34px;
    font-weight: 700;
    color: var(--text);
    letter-spacing: -0.5px;
    margin: 0;
    padding: 0;
}

.mgs-x-letter {
    font-weight: 300;
    color: #00b4d8;
    letter-spacing: 2px;
    text-shadow: 0 0 10px rgba(0, 180, 216, 0.5);
    font-style: italic;
    transform: skewX(-10deg);
    display: inline-block;
    margin-left: 4px;
}

.ios-screen-subtitle {
    font-size: 15px;
    color: var(--text-dim);
    margin-top: 4px;
    font-weight: 400;
}

.ios-back-btn {
    background: none;
    border: none;
    color: var(--accent);
    font-size: 24px;
    font-weight: 400;
    padding: 8px 12px;
    margin-bottom: 8px;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    transition: all 0.12s ease;
    line-height: 1;
    position: relative;
    display: inline-block;
}

.ios-back-btn:active {
    transform: translateX(-8px) scale(0.9);
    opacity: 0.7;
}

.ios-back-btn::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0;
}

.ios-back-btn:active::before {
    width: 20px;
    opacity: 0.5;
}

/* Анимация для кнопки назад при клике */
@keyframes backButtonPress {
    0% {
        transform: translateX(0) scale(1);
    }

    50% {
        transform: translateX(-12px) scale(0.85);
    }

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

.ios-back-btn.animate-press {
    animation: backButtonPress 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===== SCREEN TRANSITIONS (iOS Style) ===== */
#categoriesScreen,
#subcategoriesScreen,
#productsContainer {
    position: relative;
    top: 0;
    left: 0;
    transform: translateX(0) translateY(0);
    position: relative;
    transition: transform 0.15s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.15s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform, opacity;
    width: 100%;
    top: 0;
    left: 0;
    transform: translateX(0) translateY(0);
}

.screen-in {
    animation: slideInRight 0.15s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.screen-out-left {
    animation: slideOutLeft 0.15s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.screen-out-right {
    animation: slideOutRight 0.15s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }

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

@keyframes slideOutLeft {
    from {
        transform: translateX(0);
        opacity: 1;
    }

    to {
        transform: translateX(-100%);
        opacity: 0;
    }
}

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }

    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* Плавные переходы для вкладок */
#catalogTab,
#swapTab,
#profileTab {
    animation: tabFadeIn 0.15s cubic-bezier(0.4, 0, 0.2, 1);
    background: transparent;
    min-height: calc(100vh - 90px);
}

@keyframes tabFadeIn {
    from {
        opacity: 0;
        transform: translateY(8px);
    }

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

/* ===== CATEGORIES (iOS Style) ===== */
#categoriesScreen,
#subcategoriesScreen {
    padding: 0;
}

.categories-grid {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin-top: 8px;
    padding: 0;
    width: 100%;
}

/* Stagger animation for category cards */
.categories-grid .ios-category-card {
    opacity: 0;
    animation: categoryCardSlideIn 0.1s ease-out forwards;
}

.categories-grid .ios-category-card:nth-child(1) {
    animation-delay: 0s;
}

.categories-grid .ios-category-card:nth-child(2) {
    animation-delay: 0.02s;
}

.categories-grid .ios-category-card:nth-child(3) {
    animation-delay: 0.03s;
}

.categories-grid .ios-category-card:nth-child(4) {
    animation-delay: 0.04s;
}

.categories-grid .ios-category-card:nth-child(5) {
    animation-delay: 0.05s;
}

.categories-grid .ios-category-card:nth-child(6) {
    animation-delay: 0.06s;
}

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

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

.ios-category-card {
    display: flex;
    align-items: center;
    padding: 14px 16px;
    background: rgba(28, 28, 30, 0.5);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 14px;
    -webkit-tap-highlight-color: transparent;
    margin: 6px 16px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    width: calc(100% - 32px);
    position: relative;
    transition: all 0.08s ease;
}

/* No glows or highlights */
.ios-category-card::before,
.ios-category-card::after {
    display: none;
}

/* No hover effects for mobile */
.ios-category-card:active {
    opacity: 0.8;
}


.ios-category-card:active {
    transform: scale(0.97);
    border-color: var(--accent);
}

.ios-category-icon {
    font-size: 32px;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
    flex-shrink: 0;
    color: var(--accent);
}

.telegram-logo-icon {
    width: 32px;
    height: 32px;
    object-fit: contain;
    display: block;
}

.stars-logo-icon {
    width: 32px;
    height: 32px;
    object-fit: contain;
    display: block;
}

.premium-logo-icon {
    width: 32px;
    height: 32px;
    object-fit: contain;
    display: block;
}

.product-stars-icon {
    width: 32px;
    height: 32px;
    object-fit: contain;
    display: block;
}

.product-premium-icon {
    width: 32px;
    height: 32px;
    object-fit: contain;
    display: block;
}

.roblox-logo-icon {
    width: 32px;
    height: 32px;
    object-fit: contain;
    display: block;
    filter: brightness(0) invert(1) !important;
    /* Делаем логотип белым */
}

.ios-category-icon .roblox-logo-icon {
    filter: brightness(0) invert(1) !important;
    /* Убеждаемся что в категориях тоже белый */
}

.product-roblox-icon {
    width: 32px;
    height: 32px;
    object-fit: contain;
    display: block;
    filter: brightness(0) invert(1);
    /* Делаем логотип белым */
}

/* Roblox orders admin panel */
.roblox-order-item {
    position: relative;
}

.roblox-order-actions {
    display: flex;
    gap: 8px;
    margin-left: 8px;
}

.roblox-approve-btn,
.roblox-cancel-btn {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    border: none;
    font-size: 18px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: center;
}

.roblox-approve-btn {
    background: rgba(34, 197, 94, 0.2);
    color: #22c55e;
}

.roblox-approve-btn:hover {
    background: rgba(34, 197, 94, 0.3);
    transform: scale(1.1);
}

.roblox-cancel-btn {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

.roblox-cancel-btn:hover {
    background: rgba(239, 68, 68, 0.3);
    transform: scale(1.1);
}

.roblox-approve-btn:active,
.roblox-cancel-btn:active {
    transform: scale(0.95);
}

.ios-category-content {
    flex: 1;
    min-width: 0;
}

.ios-category-name {
    font-size: 17px;
    font-weight: 400;
    color: var(--text);
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.ios-category-desc {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Roblox confirmation modal */
.roblox-confirmation {
    text-align: center;
    padding: 20px;
}

.roblox-confirmation-icon {
    margin-bottom: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.roblox-confirmation-logo {
    width: 48px;
    height: 48px;
    object-fit: contain;
    filter: brightness(0) invert(1);
    /* Делаем логотип белым */
}

.roblox-confirmation-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 8px;
}

.roblox-confirmation-description {
    font-size: 15px;
    color: var(--text-dim);
    margin-bottom: 16px;
    line-height: 1.4;
}

.roblox-confirmation-price {
    font-size: 28px;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 20px;
}

.roblox-confirmation-warning {
    background: rgba(251, 191, 36, 0.1);
    border: 1px solid rgba(251, 191, 36, 0.3);
    border-radius: 10px;
    padding: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 24px;
    text-align: left;
}

.roblox-confirmation-warning .warning-icon {
    font-size: 20px;
    flex-shrink: 0;
}

.roblox-confirmation-warning .warning-text {
    font-size: 13px;
    color: #fbbf24;
    line-height: 1.4;
    flex: 1;
}

.roblox-confirm-btn {
    width: 100%;
    padding: 14px 20px;
    background: linear-gradient(135deg, var(--accent) 0%, #4f46e5 100%);
    color: white;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: all 0.12s ease;
    border: none;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
    margin-bottom: 12px;
}

.roblox-confirm-btn:hover {
    transform: scale(1.02);
    box-shadow: 0 6px 16px rgba(99, 102, 241, 0.4);
}

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

/* Roblox success screen */
.roblox-success {
    text-align: center;
    padding: 20px;
}

.roblox-success-info {
    margin: 20px 0;
}

.roblox-order-id {
    font-size: 14px;
    color: var(--text-dim);
    margin-bottom: 12px;
}

.roblox-order-id code {
    background: var(--bg-card);
    padding: 4px 8px;
    border-radius: 6px;
    font-family: monospace;
    font-size: 13px;
    color: var(--text);
}

.roblox-success-message {
    font-size: 14px;
    color: var(--text-dim);
    line-height: 1.5;
    margin-bottom: 20px;
}

.roblox-contact-manager-btn {
    width: 100%;
    padding: 14px 20px;
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    color: white;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: all 0.12s ease;
    border: none;
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.3);
    margin-bottom: 12px;
}

.roblox-contact-manager-btn:hover {
    transform: scale(1.02);
    box-shadow: 0 6px 16px rgba(34, 197, 94, 0.4);
}

.roblox-contact-manager-btn:active {
    transform: scale(0.98);
}

.ios-category-desc {
    font-size: 15px;
    color: var(--text-dim);
}

.ios-category-count {
    font-size: 17px;
    font-weight: 400;
    color: var(--text-dim);
    margin-left: 8px;
    flex-shrink: 0;
}

/* ===== PRODUCTS (iOS Style) ===== */
#productsContainer {
    padding: 0;
}

#productsContainer .ios-screen-header {
    padding: 16px 20px 8px;
    display: flex;
    align-items: flex-start;
    gap: 8px;
}

#productsContainer #categoryTitle {
    font-size: 17px;
    font-weight: 400;
    margin: 0;
    padding: 0;
    letter-spacing: 0;
}

.products-grid {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin-top: 8px;
    padding: 0;
    width: 100%;
}

.ios-product-card {
    display: flex;
    align-items: center;
    padding: 14px 16px;
    background: rgba(28, 28, 30, 0.5);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 14px;
    cursor: pointer;
    transition: all 0.15s ease;
    -webkit-tap-highlight-color: transparent;
    margin: 6px 16px;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.06);
    width: calc(100% - 32px);
}

.ios-product-card:active {
    background: var(--bg-hover);
}

.ios-product-card.selected {
    background: var(--bg-hover);
    border: 1px solid var(--accent);
}

.ios-product-icon {
    font-size: 32px;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
    flex-shrink: 0;
}

.ios-product-icon img {
    width: 32px;
    height: 32px;
    object-fit: contain;
    display: block;
}

.ios-product-content {
    flex: 1;
    min-width: 0;
}

.ios-product-name {
    font-size: 17px;
    font-weight: 400;
    color: var(--text);
    margin-bottom: 2px;
    display: flex;
    align-items: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    align-items: center;
    gap: 4px;
}

/* Молния для моментальной доставки */
.instant-badge {
    font-size: 10px;
    opacity: 0.6;
    margin-left: 2px;
}

.ios-product-subtitle {
    font-size: 15px;
    color: var(--text-dim);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.ios-product-description {
    font-size: 13px;
    color: var(--text-dim);
    margin-top: 4px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.ios-product-price {
    text-align: right;
    margin-left: 8px;
    flex-shrink: 0;
}

.ios-price-main {
    font-size: 17px;
    font-weight: 400;
    color: var(--text);
    margin-bottom: 2px;
}

.ios-price-sub {
    font-size: 15px;
    color: var(--text-dim);
}

.ios-price-rub-equivalent {
    font-size: 12px;
    color: var(--text-dim);
    opacity: 0.6;
    margin-top: 2px;
    font-weight: 400;
}

/* ===== MODAL (iOS Style) ===== */
.modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 20px;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    animation: fadeIn 0.2s ease-out;
}

.modal-content {
    background: var(--bg-secondary);
    border-radius: 14px;
    width: 100%;
    max-width: 380px;
    max-height: 85vh;
    overflow-y: auto;
    position: relative;
    border: none;
    padding: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    animation: modalSlideUp 0.15s cubic-bezier(0.32, 0.72, 0, 1);
    -webkit-overflow-scrolling: touch;
}

@keyframes modalSlideUp {
    from {
        opacity: 0;
        transform: translateY(10px) scale(0.98);
    }

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

.modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 44px;
    height: 44px;
    border-radius: 0;
    background: none;
    border: none;
    color: var(--text-dim);
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.15s;
    -webkit-tap-highlight-color: transparent;
    z-index: 10;
}

.modal-close:active {
    opacity: 0.6;
}

.modal-content h2,
.modal-content h3 {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 20px;
    letter-spacing: -0.3px;
    text-align: center;
}

.modal-content p {
    color: var(--text-dim);
    margin-bottom: 12px;
    font-size: 14px;
}

.modal-content p strong {
    color: var(--accent);
    font-weight: 600;
}

/* ===== PAYMENT ===== */
.payment-methods {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin: 20px 0;
}

.payment-methods .btn {
    background: var(--bg);
    border: 1px solid var(--border);
    text-align: left;
    padding-left: 18px;
}

.payment-methods .btn:hover {
    border-color: var(--accent);
    background: var(--bg-hover);
}

/* ===== BOTTOM NAV (iOS Native App Style) ===== */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(10, 10, 12, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 6px 8px max(10px, env(safe-area-inset-bottom));
    z-index: 10000;
    min-height: 70px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.bottom-nav::before,
.bottom-nav::after {
    display: none;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    padding: 10px 20px;
    color: rgba(255, 255, 255, 0.45);
    -webkit-tap-highlight-color: transparent;
    user-select: none;
    position: relative;
    flex: 1;
    border-radius: 14px;
    transition: color 0.12s ease, transform 0.1s ease;
    cursor: pointer;
}

/* Smooth active pill effect */
.nav-item.active::before {
    content: '';
    position: absolute;
    inset: 4px 8px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    z-index: -1;
}

.nav-icon {
    width: 26px;
    height: 26px;
    stroke-width: 1.6;
    transition: stroke-width 0.1s ease;
}

.nav-text {
    font-size: 11px;
    font-weight: 500;
    letter-spacing: -0.1px;
}

/* Active state - brighter and bolder */
.nav-item.active {
    color: #fff;
}

.nav-item.active .nav-icon {
    stroke-width: 2.2;
}

.nav-item.active .nav-text {
    font-weight: 600;
}

/* Touch feedback - instant response */
.nav-item:active {
    transform: scale(0.95);
    opacity: 0.8;
}

/* ===== CASINO/DICE (Modern Web App Style) ===== */
#diceTab {
    height: calc(100vh - 80px);
    max-height: calc(100vh - 80px);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.casino-container {
    height: 100%;
    max-height: 100%;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    display: flex;
    flex-direction: column;
    padding: 0;
    max-width: 100%;
    margin: 0;
    position: relative;
    z-index: 1;
    background: #0a0a0a;
    background-image:
        radial-gradient(circle at 20% 50%, rgba(0, 122, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(90, 200, 250, 0.1) 0%, transparent 50%),
        linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.3) 100%);
    animation: casinoContainerAppear 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    padding-bottom: 80px;
    /* Отступ для нижней навигации */
    box-sizing: border-box;
}

@keyframes casinoContainerAppear {
    0% {
        opacity: 0;
        transform: translateY(8px);
    }

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

/* Top Bar */
.casino-top-bar {
    background: rgba(20, 20, 20, 0.9);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 20px;
}

@keyframes casinoTopBarSlide {
    0% {
        opacity: 0;
        transform: translateY(-30px);
    }

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

.casino-icon-btn {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.12s ease;
}

.casino-icon-btn svg {
    width: 20px;
    height: 20px;
}

.casino-icon-btn:active {
    transform: scale(0.95);
    background: rgba(255, 255, 255, 0.1);
}

.casino-currency-top {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(0, 122, 255, 0.15);
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 16px;
    border: 1px solid rgba(0, 122, 255, 0.3);
}

.casino-rolls-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    color: #5ac8fa;
}

.casino-rolls-logo svg {
    width: 100%;
    height: 100%;
    animation: rollsLogoPulse 2s ease-in-out infinite;
}

@keyframes rollsLogoPulse {

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

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

.casino-balance-display {
    display: flex;
    align-items: center;
    gap: 6px;
}

.casino-rolls-label {
    font-size: 12px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.7);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.casino-add-btn {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: linear-gradient(135deg, #007aff, #5ac8fa);
    border: none;
    color: white;
    font-size: 24px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.12s ease;
    box-shadow: 0 4px 12px rgba(0, 122, 255, 0.3);
}

.casino-add-btn:active {
    transform: scale(0.95);
}

/* NFT Prize Display */
.casino-nft-prize {
    margin: 4px 20px;
    padding: 8px;
    background: rgba(30, 30, 35, 0.95);
    border-radius: 20px;
    border: 1px solid rgba(255, 215, 0, 0.2);
    max-height: 160px;
    overflow: hidden;
    position: relative;
}

.casino-nft-prize-image-container {
    width: 100%;
    height: 80px;
    max-height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 6px;
    border-radius: 14px;
    overflow: hidden;
    background: linear-gradient(180deg,
            rgba(30, 30, 35, 0.9) 0%,
            rgba(20, 20, 25, 0.95) 100%);
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.casino-nft-prize-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 16px;
}

.casino-nft-prize-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    height: 100%;
    color: rgba(255, 255, 255, 0.5);
}

.casino-nft-prize-icon {
    font-size: 32px;
    opacity: 0.5;
}

.casino-nft-prize-text {
    font-size: 14px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.4);
}

.casino-nft-prize-info {
    text-align: center;
}

.casino-nft-prize-name {
    font-size: 15px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 2px;
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.6), 0 0 20px rgba(138, 43, 226, 0.4);
    letter-spacing: 0.5px;
}

.casino-nft-prize-model {
    font-size: 11px;
    color: rgba(255, 215, 0, 0.8);
    font-weight: 600;
    text-shadow: 0 0 8px rgba(255, 215, 0, 0.3);
}

.casino-admin-hint {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.5);
    margin-top: 4px;
    font-style: italic;
}

.casino-admin-loading {
    padding: 16px;
    text-align: center;
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
}

/* Main Game Display */
.casino-game-display {
    margin: 4px 20px 6px 20px;
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border-radius: 0;
    border: none;
    height: auto;
    min-height: 80px;
    max-height: none;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px 20px;
    overflow: hidden;
    box-shadow: none;
    transition: none;
    position: relative;
    animation: none;
}

@keyframes casinoGameDisplayAppear {
    0% {
        opacity: 0;
        transform: scale(0.95) translateY(30px);
        filter: blur(10px);
    }

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

.casino-game-display.casino-lose-highlight {
    background: transparent;
    border: none;
    box-shadow: none;
    animation: none;
}

@keyframes losePulse {
    0% {
        transform: scale(1);
        box-shadow:
            0 8px 32px rgba(0, 0, 0, 0.4),
            inset 0 1px 0 rgba(255, 255, 255, 0.1);
    }

    50% {
        transform: scale(0.98);
        box-shadow:
            0 8px 32px rgba(255, 59, 48, 0.5),
            inset 0 1px 0 rgba(255, 59, 48, 0.3),
            0 0 40px rgba(255, 59, 48, 0.6);
    }

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

.casino-game-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    height: 100%;
    max-height: 100%;
    overflow: hidden;
    position: relative;
}

.casino-loading-ball {
    width: 70px;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    /* Убрано вращение - кубик не крутится */
}

.casino-loading-sticker {
    width: 70px;
    height: 70px;
    max-width: 70px;
    max-height: 70px;
    object-fit: contain;
    flex-shrink: 0;
}

.casino-loading-sticker-static {
    width: 140px;
    height: 140px;
    max-width: 140px;
    max-height: 140px;
    object-fit: contain;
    flex-shrink: 0;
    /* Без вращения */
}

.casino-waiting-text {
    margin-top: 16px;
    color: #00b4d8;
    font-size: 16px;
    font-weight: 500;
    text-align: center;
}

.casino-loading-text {
    color: #00b4d8;
    font-size: 16px;
    font-weight: 500;
}

.casino-game-timer {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    max-height: 100%;
    gap: 20px;
    overflow: hidden;
    position: relative;
}

.casino-timer-number-inline {
    font-size: 80px;
    font-weight: 700;
    color: #00b4d8;
    text-shadow: none;
    animation: none;
    line-height: 1;
    max-height: 80px;
    overflow: hidden;
    flex-shrink: 0;
}

.casino-bet-info {
    text-align: center;
}

.casino-bet-label-inline {
    font-size: 18px;
    color: rgba(255, 255, 255, 0.8);
    font-weight: 500;
}

.casino-bet-label-inline span {
    font-size: 24px;
    font-weight: 700;
    color: #5ac8fa;
    text-shadow: 0 0 10px rgba(90, 200, 250, 0.5);
    margin-left: 8px;
}

.casino-game-dice {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    max-height: 100%;
    gap: 12px;
    overflow: hidden;
    position: relative;
    background: transparent;
    border: none;
    padding: 0;
}

.casino-game-dice-img {
    width: 140px;
    height: 140px;
    max-width: 140px;
    max-height: 140px;
    object-fit: contain;
    transition: none;
    filter: none;
    animation: none;
    flex-shrink: 0;
    position: relative;
    z-index: 1;
    display: none;
    /* Временно скрыт */
}

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

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

.casino-game-dice-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    width: 100%;
    max-width: 100%;
    overflow: hidden;
    flex-shrink: 1;
}

.casino-game-dice-result {
    font-size: 16px;
    font-weight: 600;
    color: #00b4d8;
    text-align: center;
    padding: 8px 16px;
    background: transparent;
    backdrop-filter: none;
    border-radius: 0;
    margin-top: 8px;
    border: none;
}

.casino-game-dice-result #casinoGameDiceNumber {
    font-size: 20px;
    font-weight: 700;
    color: #00b4d8;
    display: inline-block;
    margin-left: 6px;
}

/* Ваша ставка (всегда снизу) */
.casino-your-bet-display {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    margin: 8px 20px;
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border-radius: 0;
    border: none;
}

.casino-your-bet-label {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
}

.casino-your-bet-value {
    font-size: 18px;
    font-weight: 700;
    color: #00b4d8;
}

/* Result Message Inline */
.casino-result-message-inline {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    margin-top: 20px;
    width: 100%;
}

.casino-result-text-inline {
    font-size: 24px;
    font-weight: 700;
    text-align: center;
    padding: 16px 24px;
    border-radius: 16px;
    background: rgba(28, 28, 30, 0.8);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
    width: 100%;
    max-width: 300px;
}

.casino-result-text-inline.win {
    color: #34c759;
    text-shadow: 0 0 15px rgba(52, 199, 89, 0.8), 0 0 30px rgba(52, 199, 89, 0.6);
    background: rgba(52, 199, 89, 0.2);
    border-color: rgba(52, 199, 89, 0.5);
    box-shadow: 0 0 20px rgba(52, 199, 89, 0.4);
}

.casino-result-text-inline.win strong {
    color: #30d158;
    text-shadow: 0 0 20px rgba(48, 209, 88, 1);
}

.casino-result-text-inline.lose {
    color: #ff3b30;
    text-shadow: 0 0 15px rgba(255, 59, 48, 0.6);
    background: rgba(255, 59, 48, 0.15);
    border-color: rgba(255, 59, 48, 0.3);
}

.casino-back-btn-inline {
    padding: 12px 24px;
    background: rgba(28, 28, 30, 0.6);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.casino-back-btn-inline:hover {
    background: rgba(28, 28, 30, 0.8);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.casino-back-btn-inline:active {
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

/* Info Cards */
.casino-info-cards {
    display: flex;
    gap: 12px;
    padding: 0 20px;
    margin-top: 4px;
    margin-bottom: 8px;
    animation: casinoInfoCardsAppear 0.15s cubic-bezier(0.4, 0, 0.2, 1) 0.05s both;
}

@keyframes casinoInfoCardsAppear {
    0% {
        opacity: 0;
        transform: translateY(8px);
    }

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

.casino-info-card {
    flex: 1;
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border-radius: 0;
    padding: 12px 16px;
    border: none;
    transition: none;
}

.casino-info-card-green {
    background: transparent;
    border: none;
}

.casino-info-label {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 6px;
}

.casino-info-value {
    font-size: 24px;
    font-weight: 700;
    color: #00b4d8;
    text-shadow: none;
}

.casino-info-card-green .casino-info-value {
    color: #00b4d8;
    text-shadow: none;
}

/* Dice Selection */
.casino-dice-selection {
    padding: 0 20px;
    margin-bottom: 8px;
    margin-top: 8px;
    animation: casinoDiceSelectionAppear 0.15s cubic-bezier(0.4, 0, 0.2, 1) 0.08s both;
}

@keyframes casinoDiceSelectionAppear {
    0% {
        opacity: 0;
        transform: translateY(8px);
    }

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

.casino-dice-selection-label {
    font-size: 15px;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 12px;
    font-weight: 500;
}

.casino-dice-selection-label-bottom {
    padding: 0 20px;
    margin-top: 12px;
    margin-bottom: 8px;
    font-size: 15px;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
    text-align: center;
    animation: casinoDiceSelectionAppear 0.15s cubic-bezier(0.4, 0, 0.2, 1) 0.08s both;
}

.casino-dice-prediction-select {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
}

/* Timer Overlay */
.casino-timer-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(10px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 10000;
}

.casino-timer-number {
    font-size: 200px;
    font-weight: 900;
    color: #34c759;
    /* По умолчанию зеленый для 3 */
    text-shadow: 0 0 60px currentColor, 0 0 120px currentColor;
    animation: timerPulse 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
    margin-bottom: 40px;
    line-height: 1;
}

.casino-bet-display {
    position: absolute;
    bottom: 60px;
    left: 0;
    right: 0;
    text-align: center;
    padding: 20px;
}

.casino-bet-label {
    font-size: 18px;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 8px;
}

.casino-bet-value {
    font-size: 48px;
    font-weight: 900;
    color: #5ac8fa;
    text-shadow: 0 0 20px rgba(90, 200, 250, 0.6);
}

@keyframes timerPulse {
    0% {
        transform: scale(0.3) rotate(-10deg);
        opacity: 0;
        filter: blur(10px);
    }

    50% {
        transform: scale(1.15) rotate(5deg);
    }

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

/* Shaker Glass Overlay */
.casino-shaker-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10001;
}

.casino-shaker-container {
    width: 200px;
    height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.casino-shaker-glass {
    width: 120px;
    height: 200px;
    position: relative;
    transform-style: preserve-3d;
}

.casino-shaker-top {
    width: 100%;
    height: 30px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0.1));
    border-radius: 10px 10px 0 0;
    border: 2px solid rgba(255, 255, 255, 0.4);
    border-bottom: none;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.2);
}

.casino-shaker-body {
    width: 100%;
    height: 140px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.05));
    border-left: 2px solid rgba(255, 255, 255, 0.4);
    border-right: 2px solid rgba(255, 255, 255, 0.4);
    box-shadow: inset 0 0 30px rgba(0, 0, 0, 0.3);
}

.casino-shaker-bottom {
    width: 100%;
    height: 30px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0.1));
    border-radius: 0 0 10px 10px;
    border: 2px solid rgba(255, 255, 255, 0.4);
    border-top: none;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.2);
}

@keyframes shakeGlass {

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

    5% {
        transform: translateX(-25px) rotate(-8deg) scale(1.05);
    }

    10% {
        transform: translateX(25px) rotate(8deg) scale(1.05);
    }

    15% {
        transform: translateX(-25px) rotate(-8deg) scale(1.05);
    }

    20% {
        transform: translateX(25px) rotate(8deg) scale(1.05);
    }

    25% {
        transform: translateX(-25px) rotate(-8deg) scale(1.05);
    }

    30% {
        transform: translateX(25px) rotate(8deg) scale(1.05);
    }

    35% {
        transform: translateX(-20px) rotate(-6deg) scale(1.03);
    }

    40% {
        transform: translateX(20px) rotate(6deg) scale(1.03);
    }

    45% {
        transform: translateX(-15px) rotate(-4deg) scale(1.02);
    }

    50% {
        transform: translateX(15px) rotate(4deg) scale(1.02);
    }

    60% {
        transform: translateX(-10px) rotate(-2deg) scale(0.95);
    }

    70% {
        transform: translateX(5px) rotate(1deg) scale(0.9);
    }

    80% {
        transform: translateX(-2px) rotate(0deg) scale(0.85);
    }

    90% {
        transform: translateX(0) rotate(0deg) scale(0.8);
        opacity: 0.5;
    }

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

/* Dice Roll Overlay */
.casino-dice-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(10px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 10001;
}

.casino-dice-image-container {
    width: 300px;
    height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 40px;
}

.casino-dice-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: all 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
    filter: drop-shadow(0 10px 30px rgba(0, 122, 255, 0.4));
}

.casino-dice-result-text {
    font-size: 28px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.9);
    text-align: center;
    margin-top: 30px;
    padding: 20px 30px;
    background: rgba(28, 28, 30, 0.6);
    backdrop-filter: blur(20px);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
}

.casino-dice-result-text #casinoDiceResultNumber {
    font-size: 42px;
    font-weight: 900;
    color: #5ac8fa;
    text-shadow: 0 0 20px rgba(90, 200, 250, 0.8);
    display: inline-block;
    margin-left: 8px;
    animation: numberPulse 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

    50% {
        transform: scale(1.2);
    }

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

/* Result Overlay */
.casino-result-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(15px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 10002;
    gap: 30px;
}

.casino-result-message {
    font-size: 64px;
    font-weight: 900;
    text-align: center;
    padding: 60px 80px;
    border-radius: 32px;
    animation: resultAppear 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow:
        0 20px 60px rgba(0, 0, 0, 0.6),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    letter-spacing: -1px;
}

.casino-result-message.win {
    color: #34c759;
    text-shadow: 0 0 50px rgba(52, 199, 89, 1), 0 0 100px rgba(52, 199, 89, 0.6);
    background: linear-gradient(135deg, rgba(52, 199, 89, 0.2), rgba(52, 199, 89, 0.05));
    border: 3px solid rgba(52, 199, 89, 0.5);
}

.casino-result-message.lose {
    color: #ff3b30;
    text-shadow: 0 0 50px rgba(255, 59, 48, 1), 0 0 100px rgba(255, 59, 48, 0.6);
    background: linear-gradient(135deg, rgba(255, 59, 48, 0.2), rgba(255, 59, 48, 0.05));
    border: 3px solid rgba(255, 59, 48, 0.5);
}

.casino-back-btn {
    padding: 16px 32px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 16px;
    color: var(--text);
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.casino-back-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

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

/* Add Rolls Modal */
.casino-add-rolls-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10003;
    padding: 20px;
}

.casino-add-rolls-content {
    background: rgba(28, 28, 30, 0.95);
    backdrop-filter: blur(20px);
    border-radius: 24px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    max-width: 400px;
    width: 100%;
    padding: 24px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.casino-add-rolls-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.casino-add-rolls-header h2 {
    font-size: 24px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.9);
    margin: 0;
}

.casino-modal-close {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: rgba(255, 255, 255, 0.7);
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    line-height: 1;
}

.casino-modal-close:hover {
    background: rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.9);
}

.casino-add-rolls-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 20px;
}

.casino-rolls-option {
    background: rgba(28, 28, 30, 0.6);
    backdrop-filter: blur(20px);
    border-radius: 16px;
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.casino-rolls-option:hover {
    border-color: rgba(90, 200, 250, 0.5);
    background: rgba(28, 28, 30, 0.8);
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(90, 200, 250, 0.2);
}

.casino-rolls-option-best {
    border-color: rgba(52, 199, 89, 0.5);
    background: rgba(52, 199, 89, 0.1);
}

.casino-rolls-option-best:hover {
    border-color: rgba(52, 199, 89, 0.7);
    box-shadow: 0 4px 16px rgba(52, 199, 89, 0.3);
}

.casino-rolls-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: linear-gradient(135deg, #34c759, #30d158);
    color: white;
    font-size: 11px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(52, 199, 89, 0.4);
}

.casino-rolls-option-amount {
    font-size: 20px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 8px;
}

.casino-rolls-option-price {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
}

.casino-rolls-old-price {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.4);
    text-decoration: line-through;
}

.casino-rolls-new-price {
    font-size: 18px;
    font-weight: 700;
    color: #5ac8fa;
    text-shadow: 0 0 10px rgba(90, 200, 250, 0.5);
}

.casino-rolls-option-btn {
    width: 100%;
    padding: 12px;
    background: linear-gradient(135deg, #007aff, #5ac8fa);
    border: none;
    border-radius: 12px;
    color: white;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px rgba(0, 122, 255, 0.3);
}

.casino-rolls-option-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 122, 255, 0.4);
}

.casino-rolls-option-btn:active {
    transform: translateY(0);
}

.casino-add-rolls-note {
    text-align: center;
    padding: 12px;
    background: rgba(90, 200, 250, 0.1);
    border-radius: 12px;
    border: 1px solid rgba(90, 200, 250, 0.2);
    margin-top: 20px;
}

.casino-add-rolls-note p {
    margin: 0;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
}

/* Custom Rolls Input Section */
.casino-custom-rolls-section {
    margin-top: 20px;
    padding: 16px;
    background: rgba(28, 28, 30, 0.4);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.casino-custom-rolls-label {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 12px;
    font-weight: 500;
}

.casino-custom-rolls-input-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.casino-custom-rolls-input {
    flex: 1;
    padding: 12px 16px;
    background: rgba(20, 20, 22, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    color: var(--text);
    font-size: 16px;
    font-weight: 500;
    transition: all 0.2s;
}

.casino-custom-rolls-input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.1);
}

.casino-custom-rolls-input::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.casino-custom-rolls-label-suffix {
    font-size: 16px;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
    white-space: nowrap;
}

.casino-custom-rolls-price {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    background: rgba(52, 199, 89, 0.1);
    border: 1px solid rgba(52, 199, 89, 0.2);
    border-radius: 8px;
    margin-bottom: 12px;
}

.casino-custom-rolls-price-label {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
}

.casino-custom-rolls-price-value {
    font-size: 18px;
    font-weight: 700;
    color: #34c759;
}

.casino-custom-rolls-btn {
    width: 100%;
    padding: 14px 20px;
    background: linear-gradient(135deg, #007aff, #5ac8fa);
    border: none;
    border-radius: 12px;
    color: white;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px rgba(0, 122, 255, 0.3);
}

.casino-custom-rolls-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 122, 255, 0.4);
}

.casino-custom-rolls-btn:active:not(:disabled) {
    transform: translateY(0);
}

.casino-custom-rolls-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: rgba(28, 28, 30, 0.6);
}

/* Action Buttons with Prize Info */
.casino-action-buttons {
    padding: 0 20px;
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.casino-prize-info {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    padding: 12px;
    background: rgba(52, 199, 89, 0.1);
    border-radius: 12px;
    border: 1px solid rgba(52, 199, 89, 0.3);
}

.casino-prize-label {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
}

.casino-prize-value {
    font-size: 18px;
    font-weight: 700;
    color: #34c759;
    text-shadow: 0 0 10px rgba(52, 199, 89, 0.5);
}

.casino-spin-wrapper {
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: center;
}

.casino-win-chance {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.6);
    font-weight: 500;
}

.casino-win-chance span {
    color: #5ac8fa;
    font-weight: 700;
}

/* Admin NFT Settings */
.casino-admin-section {
    margin: 20px;
    padding: 20px;
    background: rgba(28, 28, 30, 0.6);
    backdrop-filter: blur(20px);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    animation: casinoAdminSectionAppear 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) 0.6s both;
}

@keyframes casinoAdminSectionAppear {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }

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

.casino-admin-header h3 {
    margin: 0 0 16px 0;
    font-size: 18px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.9);
}

.casino-admin-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.casino-admin-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.casino-admin-field label {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
}

.casino-admin-input {
    padding: 12px 16px;
    background: rgba(20, 20, 22, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 15px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.casino-admin-input:focus {
    outline: none;
    border-color: rgba(90, 200, 250, 0.5);
    box-shadow: 0 0 0 3px rgba(90, 200, 250, 0.1);
}

.casino-admin-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.casino-admin-progress {
    padding: 16px;
    background: rgba(20, 20, 22, 0.6);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.casino-admin-progress-label {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 8px;
    font-weight: 500;
}

.casino-admin-progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
}

.casino-admin-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #5ac8fa, #007aff);
    border-radius: 4px;
    transition: width 0.3s ease;
}

.casino-admin-save-btn {
    padding: 14px 24px;
    background: linear-gradient(135deg, #007aff, #5ac8fa);
    border: none;
    border-radius: 12px;
    color: white;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px rgba(0, 122, 255, 0.3);
}

.casino-admin-save-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 122, 255, 0.4);
}

.casino-admin-save-btn:active {
    transform: translateY(0);
}

/* Confetti Canvas */
.casino-confetti-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 10004;
    display: none;
}

.casino-result-display {
    margin-top: 20px;
    padding: 16px;
    background: rgba(28, 28, 30, 0.7);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
}

.casino-dice-spinner {
    width: 200px;
    height: 200px;
    position: relative;
    perspective: 1000px;
    margin-bottom: 40px;
}

.casino-dice-3d {
    width: 100%;
    height: 100%;
    position: relative;
    transform-style: preserve-3d;
    /* Убрана зацикленная анимация */
}

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

    25% {
        transform: rotate(90deg) scale(1.2);
    }

    50% {
        transform: rotate(180deg) scale(0.8);
    }

    75% {
        transform: rotate(270deg) scale(1.2);
    }

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

.dice-face {
    position: absolute;
    width: 200px;
    height: 200px;
    background: linear-gradient(135deg, #007aff, #5ac8fa);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 80px;
    font-weight: 900;
    color: white;
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.5);
    box-shadow: 0 0 30px rgba(0, 122, 255, 0.5);
}

.dice-face-1 {
    transform: rotateY(0deg) translateZ(100px);
}

.dice-face-2 {
    transform: rotateY(90deg) translateZ(100px);
}

.dice-face-3 {
    transform: rotateY(180deg) translateZ(100px);
}

.dice-face-4 {
    transform: rotateY(-90deg) translateZ(100px);
}

.dice-face-5 {
    transform: rotateX(90deg) translateZ(100px);
}

.dice-face-6 {
    transform: rotateX(-90deg) translateZ(100px);
}

.casino-dice-result {
    text-align: center;
}

.casino-dice-result-number {
    font-size: 120px;
    font-weight: 900;
    color: #5ac8fa;
    text-shadow: 0 0 40px rgba(90, 200, 250, 0.8);
    margin-bottom: 20px;
    animation: resultAppear 0.5s ease-out;
}

@keyframes resultAppear {
    0% {
        transform: scale(0.3) rotate(-10deg);
        opacity: 0;
        filter: blur(20px);
    }

    50% {
        transform: scale(1.1) rotate(2deg);
    }

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

.casino-dice-result-text {
    font-size: 24px;
    font-weight: 600;
    color: var(--text);
}

/* History Modal */
.casino-history-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    z-index: 10002;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.casino-history-modal-content {
    background: var(--bg-card);
    border-radius: 20px;
    width: 100%;
    max-width: 500px;
    max-height: 80vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.casino-history-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid var(--border);
}

.casino-history-modal-header h3 {
    font-size: 20px;
    font-weight: 600;
}

.casino-history-close {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: var(--text);
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.casino-history-close:hover {
    background: rgba(255, 255, 255, 0.15);
}

.casino-history-list {
    padding: 20px;
    overflow-y: auto;
    flex: 1;
}

.casino-history-item {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 12px;
}

.casino-history-item.win {
    border-color: rgba(52, 199, 89, 0.5);
    background: rgba(52, 199, 89, 0.1);
}

.casino-history-item.lose {
    border-color: rgba(255, 59, 48, 0.5);
    background: rgba(255, 59, 48, 0.1);
}

.casino-deposit-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 16px;
    text-align: center;
}

.casino-deposit-label {
    font-size: 14px;
    color: var(--text-dim);
    margin-bottom: 8px;
}

.casino-deposit-amount {
    font-size: 32px;
    font-weight: 600;
    color: var(--accent);
}

.casino-redemption-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 16px;
    margin-bottom: 24px;
}

.casino-redemption-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    font-size: 15px;
    font-weight: 500;
}

.casino-redemption-progress {
    margin-top: 12px;
}

.casino-redemption-progress-bar {
    width: 100%;
    height: 8px;
    background: var(--bg-secondary);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 8px;
}

.casino-redemption-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--accent), var(--accent-hover));
    transition: width 0.3s ease;
}

.casino-redemption-progress-text {
    font-size: 13px;
    color: var(--text-dim);
    text-align: center;
}

.casino-dice-selector {
    margin-bottom: 24px;
}

.casino-dice-selector-label {
    font-size: 15px;
    color: var(--text-secondary);
    margin-bottom: 12px;
    display: block;
}

.casino-dice-selector-buttons {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.casino-dice-btn {
    background: var(--bg-card);
    border: 2px solid var(--border);
    border-radius: 12px;
    padding: 16px 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.casino-dice-btn:hover {
    border-color: var(--accent);
    background: var(--bg-hover);
}

.casino-dice-btn.active {
    border-color: var(--accent);
    background: rgba(0, 122, 255, 0.1);
}

.casino-dice-btn-count {
    font-size: 24px;
    font-weight: 600;
    color: var(--text);
}

.casino-dice-btn-price {
    font-size: 13px;
    color: var(--text-dim);
}

.casino-dice-btn-multiplier {
    font-size: 12px;
    color: var(--accent);
    font-weight: 500;
}

.casino-dice-predictions {
    margin-bottom: 24px;
}

.casino-dice-prediction-item {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.casino-dice-prediction-label {
    font-size: 15px;
    color: var(--text-secondary);
}

.casino-dice-prediction-select {
    display: flex;
    gap: 8px;
}

.casino-dice-prediction-select button {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    background: transparent;
    backdrop-filter: none;
    color: rgba(255, 255, 255, 0.8);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: none;
}

.casino-dice-prediction-select button:hover {
    border-color: #00b4d8;
    background: rgba(0, 180, 216, 0.1);
}

.casino-dice-prediction-select button:active {
    transform: scale(0.95);
}

.casino-dice-prediction-select button.selected {
    border-color: #00b4d8;
    background: #00b4d8;
    color: white;
}

/* Action Buttons */
.casino-action-buttons {
    padding: 0 20px 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    animation: casinoActionButtonsAppear 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) 0.5s both;
}

@keyframes casinoActionButtonsAppear {
    0% {
        opacity: 0;
        transform: translateY(30px);
    }

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

.casino-spin-btn-main {
    width: 100%;
    padding: 16px 24px;
    background: #007aff;
    border: none;
    border-radius: 16px;
    color: white;
    font-size: 17px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 122, 255, 0.3);
}

.casino-spin-btn-main:hover:not(:disabled):not(.casino-spin-btn-disabled) {
    background: #0051d5;
    box-shadow: 0 4px 12px rgba(0, 122, 255, 0.4);
}

.casino-spin-btn-main:active:not(:disabled):not(.casino-spin-btn-disabled) {
    transform: scale(0.98);
}

.casino-spin-btn-main:disabled,
.casino-spin-btn-main.casino-spin-btn-disabled {
    opacity: 0.4;
    cursor: not-allowed;
    background: rgba(142, 142, 147, 0.3);
    box-shadow: none;
}

.casino-spin-btn-main:disabled:hover,
.casino-spin-btn-main.casino-spin-btn-disabled:hover {
    background: rgba(142, 142, 147, 0.3);
    box-shadow: none;
}

.casino-result {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 24px;
    text-align: center;
}

.casino-result-dice {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-bottom: 16px;
}

.casino-result-dice img {
    width: 60px;
    height: 60px;
    object-fit: contain;
}

.casino-result-text {
    font-size: 18px;
    font-weight: 500;
}

.casino-result-text.win {
    color: #34c759;
}

.casino-result-text.lose {
    color: #ff3b30;
}

.casino-history {
    margin-top: 24px;
}

.casino-history-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    font-size: 15px;
    font-weight: 500;
}

.casino-history-toggle {
    background: none;
    border: none;
    color: var(--accent);
    font-size: 15px;
    cursor: pointer;
    padding: 4px 8px;
}

.casino-history-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.casino-history-item {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
}

.casino-history-item.win {
    border-left: 3px solid #34c759;
}

.casino-history-item.lose {
    border-left: 3px solid #ff3b30;
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar {
    width: 4px;
}

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

::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 2px;
}

/* ===== PAYMENT BUTTONS (div-based) ===== */
.pay-method-btn {
    display: block;
    width: 100%;
    padding: 14px 20px;
    margin-bottom: 10px;
    background: var(--accent);
    color: var(--text);
    border-radius: 12px;
    font-size: 16px;
    font-weight: 500;
    text-align: center;
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
    transition: transform 0.15s, background 0.15s;
}

.pay-method-btn:hover {
    background: #4f46e5;
}

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

.check-pay-btn,
.retry-check-btn,
.close-success-btn {
    display: block;
    width: 100%;
    padding: 14px 20px;
    margin-top: 16px;
    background: var(--accent);
    color: var(--text);
    border-radius: 12px;
    font-size: 16px;
    font-weight: 500;
    text-align: center;
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
    transition: transform 0.15s, background 0.15s;
}

.check-pay-btn:hover,
.retry-check-btn:hover,
.close-success-btn:hover {
    background: #c9a86c;
}

.check-pay-btn:active,
.retry-check-btn:active,
.close-success-btn:active {
    transform: scale(0.98);
}

.cancel-btn-wrap {
    display: block;
    width: 100%;
    padding: 10px 16px;
    margin-top: 8px;
    background: var(--bg-hover);
    color: var(--text-dim);
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    text-align: center;
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.cancel-btn-wrap:hover {
    background: #2a2a2f;
}

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

/* ===== RECIPIENT SELECTION ===== */
.recipient-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 24px 0;
}

.recipient-option {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    background: rgba(28, 28, 30, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.recipient-option:hover {
    background: var(--bg-hover);
    border-color: var(--accent);
}

.recipient-option.selected {
    background: var(--accent);
    border-color: var(--accent);
}

.recipient-icon {
    font-size: 32px;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
}

.recipient-text {
    font-size: 18px;
    font-weight: 500;
}

.recipient-next-btn {
    display: block;
    width: 100%;
    padding: 14px 20px;
    margin-top: 24px;
    background: var(--accent);
    color: var(--text);
    border-radius: 12px;
    font-size: 16px;
    font-weight: 500;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
}

.recipient-next-btn.disabled {
    background: var(--bg-hover);
    color: var(--text-dim);
    cursor: not-allowed;
    opacity: 0.5;
}

.recipient-next-btn:not(.disabled):hover {
    background: #4f46e5;
}

/* ===== FRIEND INPUT ===== */
.friend-input-container {
    margin: 20px 0;
    animation: slideDown 0.3s ease-out;
}

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

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

.friend-input {
    width: 100%;
    padding: 14px 16px;
    background: var(--bg-card);
    border: 2px solid var(--border);
    border-radius: 12px;
    color: var(--text);
    font-size: 16px;
    transition: border-color 0.2s;
}

.friend-input:focus {
    outline: none;
    border-color: var(--accent);
}

.friend-check-result {
    margin-top: 12px;
    padding: 12px;
    border-radius: 12px;
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.friend-check-result.checking {
    background: rgba(99, 102, 241, 0.1);
    color: var(--accent);
}

.friend-check-result.error {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
}

.friend-check-result.success {
    background: rgba(34, 197, 94, 0.1);
}

.user-found {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
}

.user-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.avatar-placeholder {
    width: 100%;
    height: 100%;
    background: var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: 600;
    color: var(--text);
}

.user-info {
    flex: 1;
}

.user-name {
    font-size: 16px;
    font-weight: 500;
    color: var(--text);
}

.user-username {
    font-size: 14px;
    color: var(--text-dim);
    margin-top: 2px;
}

/* ===== DELIVERY ANIMATION ===== */
.delivery-content {
    max-width: 500px;
    text-align: center;
}

.delivery-step {
    padding: 40px 20px;
}

.delivery-icon {
    font-size: 64px;
    margin-bottom: 16px;
    animation: pulse 2s infinite;
}

@keyframes pulse {

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

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

.delivery-stars-count {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 24px;
    color: var(--accent);
}

.delivery-webp-container {
    margin: 24px 0;
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.delivery-webp {
    font-size: 80px;
    animation: bounce 1s infinite;
}

@keyframes bounce {

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

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

.delivery-text {
    font-size: 18px;
    color: var(--text-dim);
    margin-top: 16px;
}

.delivery-success {
    padding: 60px 20px 40px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 400px;
}

.delivery-icon-container {
    width: 120px;
    height: 120px;
    margin-bottom: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.delivery-tgs-icon {
    width: 100%;
    height: 100%;
}

.delivery-icon-simple {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 64px;
    color: white;
    font-weight: 300;
    animation: successScale 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

    50% {
        transform: scale(1.1);
    }

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

.delivery-title {
    font-size: 28px;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text);
    letter-spacing: -0.5px;
}

.delivery-subtitle {
    font-size: 16px;
    color: var(--text-dim);
    margin-bottom: 16px;
}

.delivery-thanks {
    font-size: 14px;
    color: #22c55e;
    margin-bottom: 24px;
    font-weight: 500;
}

/* ============ Успешная доставка - Анимированная галочка ============ */
.success-checkmark-container {
    width: 100px;
    height: 100px;
    margin: 0 auto 24px;
}

.success-checkmark {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    display: block;
    stroke-width: 2;
    stroke: #22c55e;
    stroke-miterlimit: 10;
    animation: fill-success 0.4s ease-in-out 0.4s forwards, scale-success 0.3s ease-in-out 0.9s both;
}

.success-checkmark-circle {
    stroke-dasharray: 166;
    stroke-dashoffset: 166;
    stroke-width: 2;
    stroke-miterlimit: 10;
    stroke: #22c55e;
    fill: none;
    animation: stroke-success 0.6s cubic-bezier(0.65, 0, 0.45, 1) forwards;
}

.success-checkmark-check {
    transform-origin: 50% 50%;
    stroke-dasharray: 48;
    stroke-dashoffset: 48;
    stroke-width: 3;
    stroke: #22c55e;
    animation: stroke-success 0.3s cubic-bezier(0.65, 0, 0.45, 1) 0.8s forwards;
}

@keyframes stroke-success {
    100% {
        stroke-dashoffset: 0;
    }
}

@keyframes fill-success {
    100% {
        box-shadow: inset 0 0 0 60px rgba(34, 197, 94, 0.1);
    }
}

@keyframes scale-success {

    0%,
    100% {
        transform: none;
    }

    50% {
        transform: scale3d(1.1, 1.1, 1);
    }
}

.success-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 16px;
    letter-spacing: -0.5px;
}

.success-stars {
    font-size: 42px;
    font-weight: 700;
    color: #22c55e;
    margin-bottom: 8px;
}

.success-recipient {
    font-size: 16px;
    color: var(--text-dim);
    margin-bottom: 32px;
}

.delivery-details {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 24px;
    text-align: left;
}

.delivery-detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
}

.delivery-detail-row:last-child {
    border-bottom: none;
}

.delivery-label {
    color: var(--text-dim);
    font-size: 14px;
}

.delivery-value {
    color: var(--text);
    font-weight: 500;
    font-size: 14px;
}

.delivery-value.code {
    font-family: monospace;
    font-size: 12px;
    background: var(--bg-hover);
    padding: 4px 8px;
    border-radius: 4px;
}

.delivery-thanks {
    font-size: 20px;
    font-weight: 500;
    color: var(--accent);
    margin-bottom: 24px;
}

.delivery-error {
    color: #ef4444;
    margin-top: 12px;
    font-size: 14px;
}

/* ===== PROFILE (iOS Style) ===== */
.profile-container {
    padding: 0;
    max-width: 100%;
    margin: 0;
    background: rgba(10, 10, 10, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    position: relative;
    min-height: 100vh;
    padding-bottom: 80px;
    /* Место для кнопки копирования */
}

.profile-header {
    text-align: center;
    padding: 32px 20px;
    background: rgba(28, 28, 30, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.profile-avatar-large {
    width: 80px;
    height: 80px;
    margin: 0 auto 12px;
    border-radius: 50%;
    overflow: hidden;
}

.profile-userid {
    transition: all 0.2s ease;
    padding: 4px 8px;
    border-radius: 8px;
}

.profile-userid:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: scale(1.05);
}

.avatar-placeholder-large {
    width: 100%;
    height: 100%;
    background: var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    font-weight: 600;
    color: var(--text);
}

.profile-name-large {
    font-size: 22px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 4px;
}

.profile-username-large {
    font-size: 15px;
    color: var(--text-dim);
}

.profile-section {
    margin-top: 0;
    padding: 0 16px;
}

.profile-section h3 {
    font-size: 22px;
    font-weight: 700;
    color: var(--text);
    margin: 24px 0 8px;
    padding: 0 4px;
}

.purchase-history {
    margin-top: 8px;
}

/* ===== iOS LIST STYLE ===== */
.ios-list-container {
    background: rgba(28, 28, 30, 0.5);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 14px;
    overflow: hidden;
    margin: 0 16px 16px;
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.ios-list-item {
    display: flex;
    align-items: center;
    padding: 14px 16px;
    background: transparent;
    border-bottom: 0.5px solid rgba(255, 255, 255, 0.08);
    cursor: pointer;
    transition: all 0.15s ease;
    -webkit-tap-highlight-color: transparent;
}

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

.ios-list-item:active {
    background: rgba(255, 255, 255, 0.08);
}

.ios-item-icon {
    font-size: 28px;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
    flex-shrink: 0;
    transition: transform 0.15s ease;
}

.ios-item-content {
    flex: 1;
    min-width: 0;
}

.ios-item-title {
    font-size: 17px;
    font-weight: 400;
    color: var(--text);
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.ios-item-subtitle {
    font-size: 15px;
    color: var(--text-dim);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.ios-item-value {
    font-size: 17px;
    font-weight: 400;
    color: var(--text);
    margin-right: 8px;
    flex-shrink: 0;
}

.ios-item-chevron {
    font-size: 20px;
    color: var(--text-dim);
    margin-left: 4px;
    flex-shrink: 0;
}

.ios-empty-state {
    text-align: center;
    padding: 80px 20px;
    color: var(--text-dim);
}

.ios-empty-icon {
    font-size: 64px;
    margin-bottom: 16px;
    opacity: 0.6;
}

.ios-empty-text {
    font-size: 17px;
    color: var(--text-dim);
}

/* ===== HISTORY ANIMATIONS & SVG ICONS ===== */

/* Контейнер списка с анимацией */
.history-list-animated {
    animation: historyListFadeIn 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

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

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

/* Элемент списка с каскадной анимацией */
.history-item-animated {
    opacity: 0;
    animation: historyItemSlideIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes historyItemSlideIn {
    from {
        opacity: 0;
        transform: translateX(-20px) scale(0.95);
    }

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

/* Плавный hover эффект */
.history-item-animated:hover {
    background: var(--bg-hover);
    transform: scale(1.01);
}

.history-item-animated:active {
    transform: scale(0.98);
    transition: transform 0.1s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Обёртка иконки */
.history-icon-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* SVG иконка звёзд в истории */
.history-stars-icon {
    width: 32px;
    height: 32px;
    filter: drop-shadow(0 2px 8px rgba(255, 193, 7, 0.4));
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.history-item-animated:hover .history-stars-icon {
    filter: drop-shadow(0 4px 12px rgba(255, 193, 7, 0.6));
    transform: scale(1.1) rotate(5deg);
}

/* SVG иконка Premium в истории */
.history-premium-icon {
    width: 32px;
    height: 32px;
    filter: drop-shadow(0 2px 8px rgba(94, 53, 177, 0.4));
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.history-item-animated:hover .history-premium-icon {
    filter: drop-shadow(0 4px 12px rgba(94, 53, 177, 0.6));
    transform: scale(1.1) rotate(-5deg);
}

/* SVG иконка Roblox в истории */
.history-roblox-icon {
    width: 32px;
    height: 32px;
    filter: brightness(0) invert(1) drop-shadow(0 2px 8px rgba(255, 255, 255, 0.3));
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.history-item-animated:hover .history-roblox-icon {
    filter: brightness(0) invert(1) drop-shadow(0 4px 12px rgba(255, 255, 255, 0.5));
    transform: scale(1.1) rotate(5deg);
}

/* Иконка в деталях транзакции */
.details-icon-svg {
    width: 48px;
    height: 48px;
    filter: drop-shadow(0 3px 10px rgba(255, 193, 7, 0.4));
    animation: detailsIconPulse 3s ease-in-out infinite;
}

@keyframes detailsIconPulse {

    0%,
    100% {
        transform: scale(1);
        filter: drop-shadow(0 3px 10px rgba(255, 193, 7, 0.4));
    }

    50% {
        transform: scale(1.03);
        filter: drop-shadow(0 4px 12px rgba(255, 193, 7, 0.5));
    }
}

/* Маленькая инлайн иконка */
.inline-stars-icon {
    width: 18px;
    height: 18px;
    vertical-align: middle;
    margin-left: 4px;
}

/* Анимация контента деталей */
.details-content-animated {
    animation: detailsContentFadeIn 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

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

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

/* Анимация заголовка деталей */
.details-header-animated {
    animation: detailsHeaderBounce 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

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

/* Плавные переходы для шеврона */
.ios-item-chevron {
    transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1), color 0.2s;
}

.history-item-animated:hover .ios-item-chevron {
    transform: translateX(3px);
    color: var(--text);
}

/* ===== iOS MODAL STYLE ===== */
.ios-modal {
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.ios-modal-content {
    background: rgba(28, 28, 30, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    max-height: 90vh;
    background: var(--bg-secondary);
    border-radius: 14px 14px 0 0;
    display: flex;
    flex-direction: column;
    animation: iosModalSlideUp 0.3s cubic-bezier(0.32, 0.72, 0, 1);
}

@keyframes iosModalSlideUp {
    from {
        transform: translateY(100%);
    }

    to {
        transform: translateY(0);
    }
}

.ios-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    border-bottom: 0.5px solid var(--separator);
    min-height: 44px;
}

.ios-modal-close {
    background: none;
    border: none;
    color: var(--accent);
    font-size: 17px;
    font-weight: 400;
    padding: 0;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

.ios-modal-title {
    font-size: 17px;
    font-weight: 600;
    color: var(--text);
    flex: 1;
    text-align: center;
}

.ios-modal-body {
    background: rgba(28, 28, 30, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    flex: 1;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 20px;
    overscroll-behavior: contain;
}

/* ===== iOS DETAILS STYLE ===== */
.ios-details-content {
    padding: 20px 16px;
}

.ios-details-header {
    text-align: center;
    margin-bottom: 32px;
    padding-bottom: 24px;
    border-bottom: 0.5px solid var(--separator);
}

.ios-details-icon-large {
    font-size: 64px;
    margin-bottom: 12px;
}

.ios-details-title-large {
    font-size: 28px;
    font-weight: 700;
    color: var(--text);
}

.ios-details-section {
    background: var(--bg-card);
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 16px;
}

.ios-detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-bottom: 0.5px solid var(--separator);
    min-height: 44px;
}

.ios-detail-row:last-child {
    border-bottom: none;
}

.ios-detail-label {
    font-size: 15px;
    color: var(--text-dim);
    font-weight: 400;
}

.ios-detail-value {
    font-size: 15px;
    color: var(--text);
    font-weight: 400;
    text-align: right;
    max-width: 60%;
    word-break: break-word;
}

.ios-detail-code {
    font-family: 'SF Mono', 'Monaco', 'Menlo', monospace;
    font-size: 13px;
    color: var(--accent);
    background: var(--bg-tertiary);
    padding: 4px 8px;
    border-radius: 6px;
    display: inline-block;
    max-width: 100%;
    word-break: break-all;
    cursor: pointer;
    transition: background-color 0.15s;
    -webkit-tap-highlight-color: transparent;
}

.ios-detail-code:active {
    background: var(--bg-hover);
    opacity: 0.8;
}

/* ===== PAYMENT MODAL - NO SCROLL, COMPACT ===== */
.payment-modal-content {
    overflow: hidden !important;
    max-height: 95vh;
    display: flex;
    flex-direction: column;
    padding: 16px;
}

.payment-modal-content #paymentModalBody {
    overflow: hidden;
    display: flex;
    flex-direction: column;
    flex: 1;
}

/* ===== IMPROVED PAYMENT DESIGN ===== */
.payment-header-sbp {
    text-align: center;
    margin-bottom: 12px;
}

.payment-header-sbp h3 {
    font-size: 18px;
    margin-bottom: 8px;
}

.payment-amount-block {
    margin-top: 8px;
}

.payment-amount-large {
    font-size: 28px;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 8px;
}

.copy-amount-btn {
    font-size: 12px;
    padding: 6px 12px;
    margin-top: 4px;
}

.sbp-details {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 12px;
}

.sbp-phone-block {
    background: var(--bg-card);
    border: 2px solid var(--accent);
    border-radius: 12px;
    padding: 12px;
    text-align: center;
}

.sbp-label {
    font-size: 11px;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.sbp-phone-value {
    font-size: 22px;
    font-weight: 700;
    color: var(--text);
    font-family: monospace;
    margin: 6px 0;
    word-break: break-all;
}

.copy-btn {
    display: inline-block;
    padding: 8px 16px;
    background: var(--accent);
    color: var(--text);
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    margin-top: 4px;
}

.copy-btn:hover {
    background: #4f46e5;
    transform: scale(1.02);
}

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

/* Кнопка "Я оплатил" */
.check-payment-btn {
    display: block;
    width: 100%;
    padding: 12px 16px;
    margin-top: 8px;
    background: #22c55e;
    color: white;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
}

.check-payment-btn:hover {
    background: #16a34a;
}

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

.sbp-bank-block {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--bg-card);
    border-radius: 10px;
    padding: 10px 12px;
    border: 1px solid var(--border);
}

.sbp-bank-logo {
    font-size: 28px;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(99, 102, 241, 0.1);
    border-radius: 8px;
    flex-shrink: 0;
}

.sbp-bank-info {
    flex: 1;
}

.sbp-bank-name {
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
}

.sbp-recipient-block {
    background: var(--bg-card);
    border-radius: 10px;
    padding: 10px 12px;
    border: 1px solid var(--border);
}

.sbp-value {
    font-size: 14px;
    font-weight: 500;
    color: var(--text);
    margin-top: 2px;
}

.payment-warning-block {
    background: rgba(251, 191, 36, 0.1);
    border: 1px solid rgba(251, 191, 36, 0.3);
    border-radius: 10px;
    padding: 10px 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 10px 0;
}

.warning-icon {
    font-size: 20px;
    flex-shrink: 0;
}

.warning-text {
    flex: 1;
    font-size: 12px;
    color: #fbbf24;
    line-height: 1.4;
}

.card-details {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 12px;
}

.card-number-block {
    background: var(--bg-card);
    border: 2px solid var(--accent);
    border-radius: 16px;
    padding: 20px;
    text-align: center;
}

.card-number-value {
    font-size: 20px;
    font-weight: 600;
    color: var(--text);
    font-family: monospace;
    margin: 12px 0;
    word-break: break-all;
}

.card-payment-link {
    margin: 24px 0;
    text-align: center;
}

.btn-large {
    padding: 16px 32px;
    font-size: 18px;
    font-weight: 600;
}

/* ===== SUPPORT BUTTON ===== */
.support-btn {
    display: block;
    width: 100%;
    padding: 14px 20px;
    margin-top: 16px;
    background: #22c55e;
    color: var(--text);
    border-radius: 12px;
    font-size: 16px;
    font-weight: 500;
    text-align: center;
    cursor: pointer;
    user-select: none;
    transition: all 0.2s;
}

.support-btn:hover {
    background: #16a34a;
    transform: scale(1.02);
}

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

/* ===== ERROR CONTAINER ===== */
.error-container {
    text-align: center;
    padding: 20px 0;
}

.error-icon {
    font-size: 64px;
    margin-bottom: 16px;
}

.error-title {
    font-size: 24px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 12px;
}

.error-message {
    font-size: 16px;
    color: var(--text-dim);
    margin-bottom: 24px;
    line-height: 1.5;
}

.error-message {
    color: #ef4444;
}

/* ===== RATE LIMIT (iOS Style) ===== */
.ios-rate-limit {
    text-align: center;
    padding: 20px;
    animation: rateLimitFadeIn 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes rateLimitFadeIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }

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

/* Круговой прогресс */
.rate-limit-circle-container {
    position: relative;
    width: 140px;
    height: 140px;
    margin: 0 auto 20px;
}

.rate-limit-circle {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.rate-limit-circle-bg {
    fill: none;
    stroke: var(--bg-hover);
    stroke-width: 6;
}

.rate-limit-circle-progress {
    fill: none;
    stroke: var(--accent);
    stroke-width: 6;
    stroke-linecap: round;
    transition: stroke-dashoffset 1s linear;
}

.rate-limit-timer-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 28px;
    font-weight: 700;
    color: var(--text);
    font-family: monospace;
}

.ios-rate-limit-icon {
    font-size: 64px;
    margin-bottom: 20px;
    animation: pulse 2s infinite;
}

.ios-rate-limit-icon.success {
    animation: rateLimitSuccessBounce 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
    color: #22c55e;
}

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

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

.ios-rate-limit-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 8px;
}

.ios-rate-limit-message {
    font-size: 14px;
    color: var(--text-dim);
    margin-bottom: 20px;
    line-height: 1.4;
}

/* Rate limit success */
.rate-limit-success-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 40px;
    color: white;
    animation: rateLimitSuccessBounce 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 8px 24px rgba(34, 197, 94, 0.4);
}

.rate-limit-done-btn {
    display: block;
    width: 100%;
    padding: 14px 20px;
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    color: white;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.3);
}

.rate-limit-done-btn:hover {
    transform: scale(1.02);
    box-shadow: 0 6px 16px rgba(34, 197, 94, 0.4);
}

.rate-limit-done-btn:active {
    transform: scale(0.98);
}

.ios-rate-limit-timer {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
}

.ios-timer-value {
    font-size: 32px;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 8px;
    font-variant-numeric: tabular-nums;
}

.ios-timer-label {
    font-size: 13px;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ===== MOBILE ===== */
@media (max-width: 480px) {

    #categoriesScreen,
    #productsContainer {
        padding: 20px 16px;
    }

    .modal-content {
        padding: 24px 20px;
    }

    .delivery-stars-big {
        font-size: 56px;
    }

    .delivery-icon {
        font-size: 48px;
    }
}

/* ===== SWAP SCREEN ===== */
#swapTab {
    padding: 0;
    position: relative;
    top: 0;
    left: 0;
    transform: translateX(0) translateY(0);
}

.swap-container {
    padding: 0;
    max-width: 100%;
    margin: 0;
}

.swap-header {
    padding: 20px 20px 16px;
    border-bottom: 0.5px solid var(--separator);
}

.swap-title {
    font-size: 28px;
    font-weight: 700;
    color: var(--text);
    margin: 0;
    letter-spacing: -0.5px;
}

.swap-form {
    padding: 24px 16px 120px;
    /* Увеличено снизу, чтобы кнопка не залазила на меню */
    padding-bottom: calc(24px + env(safe-area-inset-bottom, 0px) + 80px);
    /* Учитываем безопасную зону */
}

.swap-section {
    margin-bottom: 24px;
    animation: swapSectionFadeIn 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    animation-fill-mode: both;
}

.swap-section:nth-child(1) {
    animation-delay: 0.1s;
}

.swap-section:nth-child(2) {
    animation-delay: 0.2s;
}

.swap-section:nth-child(3) {
    animation-delay: 0.3s;
}

.swap-section:nth-child(4) {
    animation-delay: 0.4s;
}

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

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

.swap-section-label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-dim);
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.swap-input-group {
    display: flex;
    align-items: center;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    animation: swapInputFadeIn 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.swap-input-group:focus-within {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-glow);
    transform: scale(1.01);
}

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

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

.swap-input {
    flex: 1;
    padding: 16px;
    background: transparent;
    border: none;
    color: var(--text);
    font-size: 20px;
    font-weight: 600;
    outline: none;
    min-width: 0;
}

.swap-input::placeholder {
    color: var(--text-dim);
    font-weight: 400;
}

.swap-input[readonly] {
    cursor: default;
    color: var(--text-dim);
}

.swap-currency-selector {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 16px;
    background: var(--bg-secondary);
    border-left: 1px solid var(--border);
    cursor: default;
    user-select: none;
    flex-shrink: 0;
    transition: background-color 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.swap-currency-selector-clickable {
    cursor: pointer;
}

.swap-currency-selector-clickable:active {
    background: var(--bg-hover);
}

.swap-currency-arrow {
    width: 14px;
    height: 14px;
    opacity: 0.6;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.swap-currency-selector-clickable:active .swap-currency-arrow {
    transform: rotate(180deg);
}

.swap-currency-icon {
    font-size: 24px;
    line-height: 1;
}

.swap-currency-name {
    font-size: 16px;
    font-weight: 600;
    color: var(--text);
}

.swap-rate {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 16px 0;
    color: var(--text-dim);
    font-size: 14px;
}

.swap-rate-icon {
    width: 16px;
    height: 16px;
    stroke: var(--text-dim);
}

#swapRateText {
    font-weight: 500;
}

.swap-wallet-group {
    display: flex;
    gap: 8px;
    align-items: stretch;
}

.swap-wallet-input {
    flex: 1;
}

.swap-connect-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 16px 20px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    color: var(--text);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
    -webkit-tap-highlight-color: transparent;
    white-space: nowrap;
    flex-shrink: 0;
}

#swapConnectWalletBtn {
    min-width: 120px;
    display: flex;
    align-items: center;
}

/* Стили для кнопки TON Connect UI */
#swapConnectWalletBtn button,
#swapConnectWalletBtn .tc-connect-button {
    width: 100% !important;
    min-height: 48px !important;
    padding: 12px 20px !important;
    background: var(--bg-card) !important;
    border: 1px solid var(--border) !important;
    border-radius: 12px !important;
    color: var(--text) !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Text', 'Helvetica Neue', sans-serif !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

#swapConnectWalletBtn button:hover,
#swapConnectWalletBtn .tc-connect-button:hover {
    background: var(--bg-hover) !important;
    border-color: var(--accent) !important;
}

#swapConnectWalletBtn button:active,
#swapConnectWalletBtn .tc-connect-button:active {
    opacity: 0.8 !important;
}

.swap-connect-btn:active {
    background: var(--bg-hover);
    opacity: 0.8;
}

.swap-wallet-icon {
    width: 20px;
    height: 20px;
    stroke: var(--accent);
}

.swap-wallet-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    margin-top: 8px;
    font-size: 14px;
    color: var(--text);
    font-family: monospace;
}

.swap-disconnect-btn {
    background: transparent;
    border: none;
    color: var(--text-dim);
    font-size: 18px;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 6px;
    transition: all 0.15s;
    -webkit-tap-highlight-color: transparent;
}

.swap-disconnect-btn:active {
    background: var(--bg-hover);
    color: var(--text);
}

.swap-submit-btn {
    width: 100%;
    padding: 18px 24px;
    background: var(--accent);
    border: none;
    border-radius: 12px;
    color: #fff;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    -webkit-tap-highlight-color: transparent;
    margin-top: 8px;
    box-shadow: 0 4px 12px var(--accent-glow);
}

.swap-submit-btn:not(:disabled):hover {
    background: var(--accent-hover);
    box-shadow: 0 6px 16px var(--accent-glow);
    transform: translateY(-1px);
}

.swap-submit-btn:not(:disabled):active {
    transform: translateY(0);
    box-shadow: 0 2px 8px var(--accent-glow);
}

.swap-submit-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

.swap-error {
    margin-top: 16px;
    padding: 12px 16px;
    background: rgba(255, 59, 48, 0.1);
    border: 1px solid rgba(255, 59, 48, 0.3);
    border-radius: 12px;
    color: #ff3b30;
    font-size: 14px;
    line-height: 1.4;
    text-align: center;
}

.swap-error[style*="color: #34c759"],
.swap-error[style*="color: #ff9500"] {
    background: rgba(52, 199, 89, 0.1);
    border-color: rgba(52, 199, 89, 0.3);
}

.swap-error[style*="color: #ff9500"] {
    background: rgba(255, 149, 0, 0.1);
    border-color: rgba(255, 149, 0, 0.3);
    color: #ff9500;
}

/* ================= ACCOUNTING ================= */
.accounting-container {
    padding: 20px;
    padding-bottom: 100px;
    max-width: 100%;
    margin: 0 auto;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    height: calc(100vh - 80px);
    /* Высота минус навигация */
    max-height: calc(100vh - 80px);
}

.accounting-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 24px;
}

.accounting-action-btn {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    -webkit-tap-highlight-color: transparent;
}

.accounting-action-btn:active {
    transform: scale(0.95);
    background: var(--bg-hover);
}

.action-btn-icon {
    font-size: 32px;
    margin-bottom: 8px;
    font-weight: 300;
}

.action-btn-text {
    font-size: 14px;
    color: var(--text);
    font-weight: 500;
}

.accounting-stats {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 24px;
}

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

.stats-title {
    font-size: 20px;
    font-weight: 600;
    color: var(--text);
}

.stats-period-selector {
    display: flex;
    gap: 8px;
}

.period-btn {
    padding: 6px 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text-dim);
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.period-btn.active {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}

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

.stats-content {
    margin-top: 16px;
}

.stats-summary {
    margin-top: 16px;
}

.stats-summary-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

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

.stat-label {
    font-size: 12px;
    color: var(--text-dim);
    margin-bottom: 4px;
}

.stat-value {
    font-size: 18px;
    font-weight: 600;
}

.stat-value.positive {
    color: #34c759;
}

.stat-value.negative {
    color: #ff3b30;
}

.chart-container {
    display: flex;
    align-items: flex-end;
    justify-content: space-around;
    height: 150px;
    margin-top: 16px;
    gap: 8px;
}

.chart-bar-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    height: 100%;
}

.chart-bar {
    width: 100%;
    max-width: 40px;
    border-radius: 4px 4px 0 0;
    transition: all 0.3s;
    min-height: 2px;
}

.chart-bar.bar-positive {
    background: #34c759;
}

.chart-bar.bar-negative {
    background: #ff3b30;
}

.chart-label {
    margin-top: 8px;
    font-size: 10px;
    color: var(--text-dim);
    text-align: center;
}

.chart-empty {
    text-align: center;
    color: var(--text-dim);
    padding: 40px 20px;
    font-size: 14px;
}

.accounting-history {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 20px;
}

.history-footer {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--border);
    text-align: center;
}

.view-all-btn {
    width: 100%;
    padding: 14px 20px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 12px;
    color: var(--text);
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    -webkit-tap-highlight-color: transparent;
}

.view-all-btn:active {
    transform: scale(0.98);
    background: var(--bg-hover);
}

.view-all-btn:hover {
    background: var(--bg-hover);
}

.history-header {
    margin-bottom: 16px;
}

.history-title {
    font-size: 20px;
    font-weight: 600;
    color: var(--text);
}

.accounting-history-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-height: 400px;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    /* Стилизация скроллбара для WebKit браузеров */
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}

.accounting-history-list::-webkit-scrollbar {
    width: 6px;
}

.accounting-history-list::-webkit-scrollbar-track {
    background: transparent;
}

.accounting-history-list::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 3px;
}

.accounting-history-list::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

.accounting-history-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px;
    background: var(--bg-secondary);
    border-radius: 12px;
    border: 1px solid var(--border);
    transition: all 0.2s;
}

.accounting-history-item:active {
    transform: scale(0.98);
    background: var(--bg-hover);
}

.history-item-content {
    flex: 1;
}

.history-item-main {
    font-size: 16px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 4px;
}

.history-item-details {
    font-size: 13px;
    color: var(--text-dim);
}

.history-item-net {
    font-size: 16px;
    font-weight: 600;
    margin: 0 12px;
    min-width: 80px;
    text-align: right;
}

.history-item-net.positive {
    color: #34c759;
}

.history-item-net.negative {
    color: #ff3b30;
}

.history-item-net.transfer {
    color: var(--text-dim);
    font-size: 14px;
    line-height: 1.4;
    font-weight: 500;
}

.accounting-history-item.withdrawal-item {
    opacity: 0.8;
}

.history-item-menu {
    background: transparent;
    border: none;
    color: var(--text-dim);
    font-size: 20px;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 8px;
    transition: all 0.2s;
    -webkit-tap-highlight-color: transparent;
}

.history-item-menu:active {
    background: var(--bg-hover);
    color: var(--text);
}

/* Balances Modal */
.accounting-modal-content {
    max-width: 90%;
    max-height: 90vh;
    overflow-y: auto;
}

.balances-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 20px 0;
}

.balance-card {
    display: flex;
    align-items: center;
    padding: 16px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    transition: all 0.2s;
}

.balance-card:active {
    transform: scale(0.98);
    background: var(--bg-hover);
}

.balance-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: 600;
    margin-right: 12px;
}

.balance-icon.ton-icon {
    background: rgba(0, 180, 216, 0.2);
    color: #00b4d8;
}

.balance-icon.usdt-icon {
    background: rgba(52, 199, 89, 0.2);
    color: #34c759;
}

.balance-icon.yoomoney-icon {
    background: rgba(255, 149, 0, 0.2);
    color: #ff9500;
}

.balance-icon.ozon-icon {
    background: rgba(0, 122, 255, 0.2);
    color: #007aff;
}

.balance-info {
    flex: 1;
}

.balance-name {
    font-size: 16px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 4px;
}

.balance-amount {
    font-size: 18px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 2px;
}

.balance-rub {
    font-size: 12px;
    color: var(--text-dim);
}

.balance-action-btn {
    background: var(--accent);
    border: none;
    color: #fff;
    font-size: 16px;
    padding: 8px 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    -webkit-tap-highlight-color: transparent;
}

.balance-action-btn:active {
    transform: scale(0.95);
    background: var(--accent-hover);
}

.transfer-indicator {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 16px;
    margin: 8px 0;
}

.transfer-arrows {
    font-size: 24px;
    color: var(--text-dim);
    margin-bottom: 8px;
    animation: transferPulse 2s infinite;
}

@keyframes transferPulse {

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

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

.transfer-btn {
    background: var(--accent);
    border: none;
    color: #fff;
    padding: 10px 20px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    -webkit-tap-highlight-color: transparent;
}

.transfer-btn:active {
    transform: scale(0.95);
    background: var(--accent-hover);
}

/* Add Sale Modal */
.add-sale-form {
    padding: 20px 0;
}

.add-sale-form h3 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 20px;
    color: var(--text);
}

.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    font-size: 14px;
    color: var(--text-dim);
    margin-bottom: 8px;
}

.form-input,
.form-select {
    width: 100%;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 12px;
    color: var(--text);
    font-size: 16px;
    -webkit-appearance: none;
    appearance: none;
}

.form-input:focus,
.form-select:focus {
    outline: none;
    border-color: var(--accent);
}

.form-submit-btn {
    width: 100%;
    padding: 14px;
    background: var(--accent);
    border: none;
    border-radius: 12px;
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    margin-top: 8px;
    -webkit-tap-highlight-color: transparent;
}

.form-submit-btn:active {
    transform: scale(0.98);
    background: var(--accent-hover);
}

/* Operation Menu Modal */
.operation-menu-modal {
    max-width: 90%;
    border-radius: 16px 16px 0 0;
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
    from {
        transform: translateX(-50%) translateY(100%);
    }

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

.operation-menu-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 20px;
}

.menu-action-btn {
    padding: 14px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    color: var(--text);
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    -webkit-tap-highlight-color: transparent;
}

.menu-action-btn:active {
    transform: scale(0.98);
    background: var(--bg-hover);
}

.menu-action-btn.danger {
    color: #ff3b30;
}

.menu-action-btn.danger:active {
    background: rgba(255, 59, 48, 0.1);
}

/* Balance Edit Form */
.balance-edit-form {
    padding: 20px 0;
}

.balance-edit-form h3 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 20px;
    color: var(--text);
}

.form-cancel-btn {
    width: 100%;
    padding: 14px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 12px;
    color: var(--text);
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    -webkit-tap-highlight-color: transparent;
}

.form-cancel-btn:active {
    transform: scale(0.98);
    background: var(--bg-hover);
}

/* ================= TOAST NOTIFICATIONS ================= */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 12px;
    pointer-events: none;
}

.toast {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    min-width: 280px;
    max-width: 400px;
    opacity: 0;
    transform: translateX(400px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: auto;
}

.toast.toast-show {
    opacity: 1;
    transform: translateX(0);
}

.toast-icon {
    font-size: 20px;
    flex-shrink: 0;
}

.toast-message {
    font-size: 14px;
    color: var(--text);
    line-height: 1.4;
    flex: 1;
}

.toast-success {
    border-left: 4px solid #34c759;
    background: rgba(52, 199, 89, 0.1);
}

.toast-error {
    border-left: 4px solid #ff3b30;
    background: rgba(255, 59, 48, 0.1);
}

.toast-warning {
    border-left: 4px solid #ff9500;
    background: rgba(255, 149, 0, 0.1);
}

.toast-info {
    border-left: 4px solid var(--accent);
    background: rgba(0, 122, 255, 0.1);
}

/* ================= GIVEAWAYS STYLES ================= */

.giveaways-container {
    padding: 16px;
    padding-bottom: 100px;
}

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

.giveaways-header h2 {
    font-size: 24px;
    font-weight: 700;
    color: var(--text);
    margin: 0;
}

.admin-add-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--accent);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: 300;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 122, 255, 0.3);
    transition: all 0.2s;
}

.admin-add-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 16px rgba(0, 122, 255, 0.4);
}

.giveaways-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Старые стили удалены - используем .giveaway-card */

.giveaway-form {
    padding: 8px;
}

.giveaway-form h3 {
    text-align: center;
    margin-bottom: 20px;
    color: var(--text);
}

.giveaway-form .form-group {
    margin-bottom: 16px;
}

.giveaway-form label {
    display: block;
    font-size: 14px;
    color: var(--text-dim);
    margin-bottom: 6px;
}

.giveaway-form input[type="text"],
.giveaway-form input[type="number"] {
    width: 100%;
    padding: 12px 16px;
    border-radius: 12px;
    border: 1px solid var(--border);
    background: var(--bg-card);
    color: var(--text);
    font-size: 16px;
    box-sizing: border-box;
}

.giveaway-form input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-right: 8px;
    vertical-align: middle;
}

.prize-type-toggle {
    display: flex;
    gap: 8px;
}

.prize-type-toggle .toggle-btn {
    flex: 1;
    padding: 10px;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: var(--bg-card);
    color: var(--text-dim);
    cursor: pointer;
    transition: all 0.2s;
}

.prize-type-toggle .toggle-btn.active {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
}

/* History Section */
.giveaways-history-section {
    margin-top: 32px;
    padding-top: 24px;
    border-top: 1px solid var(--border);
}

.giveaways-history-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 16px;
}

.giveaways-history-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 400px;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    padding: 8px 0;
}

.giveaways-history-list::-webkit-scrollbar {
    width: 4px;
}

.giveaways-history-list::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 2px;
}

.giveaways-history-list::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 2px;
}

.giveaways-history-list::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

.history-loading {
    padding: 16px;
    text-align: center;
}

.history-empty {
    text-align: center;
    color: var(--text-dim);
    font-size: 14px;
    padding: 20px;
}

.history-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: var(--bg-card);
    border-radius: 12px;
    border: 1px solid var(--border);
}

.history-item-icon {
    font-size: 24px;
}

.history-item-content {
    flex: 1;
}

.history-item-title {
    font-size: 15px;
    font-weight: 500;
    color: var(--text);
    margin-bottom: 2px;
}

.history-item-subtitle {
    font-size: 12px;
    color: var(--text-dim);
}

.history-item-check {
    padding: 8px 12px;
    background: var(--accent);
    color: white;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.history-item-check:hover {
    background: var(--accent-hover);
    transform: scale(1.05);
}

/* ================= NEW GIVEAWAY CARD STYLES ================= */

.giveaway-card {
    background: linear-gradient(145deg, #2a2a2e 0%, #1f1f23 100%);
    border-radius: 20px;
    padding: 20px;
    margin-bottom: 16px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 255, 255, 0.05);
    transition: all 0.3s ease;
    animation: fadeInUp 0.5s ease-out;
}

.giveaway-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(255, 255, 255, 0.1);
}

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

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

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }

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

@keyframes pulse {

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

    50% {
        transform: scale(1.05);
    }
}

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

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

.giveaways-list {
    animation: fadeInUp 0.6s ease-out;
}

.giveaway-card {
    animation: fadeInUp 0.5s ease-out;
    animation-fill-mode: both;
}

.giveaway-card:nth-child(1) {
    animation-delay: 0.1s;
}

.giveaway-card:nth-child(2) {
    animation-delay: 0.2s;
}

.giveaway-card:nth-child(3) {
    animation-delay: 0.3s;
}

.giveaway-card:nth-child(4) {
    animation-delay: 0.4s;
}

.giveaway-card:nth-child(5) {
    animation-delay: 0.5s;
}

.giveaway-card-image {
    animation: pulse 3s ease-in-out infinite;
}

.giveaway-join-btn {
    position: relative;
    overflow: hidden;
}

.giveaway-join-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    animation: shimmer 2s infinite;
}

.giveaway-card:hover .giveaway-card-image {
    animation: pulse 1s ease-in-out infinite;
}

.giveaways-container {
    animation: fadeInUp 0.4s ease-out;
}

.giveaways-header {
    animation: slideInRight 0.5s ease-out;
}

.giveaway-card-actions button {
    transition: all 0.3s ease;
}

.giveaway-card-actions button:active {
    transform: scale(0.95);
}

/* Loading animation */
.giveaways-list .ios-empty-state {
    animation: pulse 2s ease-in-out infinite;
}

.giveaway-card-top {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 16px;
    position: relative;
}

.giveaway-card-title {
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-align: center;
    margin-bottom: 8px;
}

.giveaway-card-status-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 12px;
}

.giveaway-card-status {
    font-size: 11px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.8);
    background: rgba(255, 255, 255, 0.15);
    padding: 4px 10px;
    border-radius: 12px;
    white-space: nowrap;
}

.giveaway-card-date {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.6);
}

.giveaway-card-timer {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
}

.giveaway-card-timer {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.7);
    background: rgba(255, 255, 255, 0.1);
    padding: 6px 12px;
    border-radius: 20px;
}

.giveaway-card-image {
    width: 120px;
    height: 120px;
    margin: 0 auto 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.giveaway-card-image img {
    filter: brightness(0.85) contrast(1.1);
    opacity: 0.9;
}

.giveaway-card-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.giveaway-card-emoji {
    font-size: 64px;
}

.giveaway-card-prize {
    text-align: center;
    font-size: 16px;
    font-weight: 600;
    color: #fff;
    margin-bottom: 8px;
}

.giveaway-card-info {
    display: flex;
    justify-content: center;
    gap: 20px;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: 12px;
}

.giveaway-card-info span {
    filter: grayscale(100%) brightness(1.2);
}

.giveaway-card-winners {
    margin-top: 12px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
}

.giveaway-card-winners-title {
    font-size: 13px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 8px;
    text-align: center;
}

.giveaway-card-winners-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.giveaway-winner-item {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.7);
    padding: 6px 8px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 6px;
    text-align: center;
}

.giveaway-card-tickets {
    text-align: center;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 16px;
    padding: 8px;
    background: rgba(102, 126, 234, 0.15);
    border-radius: 8px;
    border: 1px solid rgba(102, 126, 234, 0.3);
}

.giveaway-card-actions {
    display: flex;
    gap: 10px;
}

.giveaway-join-btn {
    flex: 1;
    padding: 14px 20px;
    border-radius: 12px;
    border: none;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    transition: all 0.2s;
}

.giveaway-join-btn:hover {
    transform: scale(1.02);
    box-shadow: 0 4px 20px rgba(102, 126, 234, 0.4);
}

.giveaway-info-btn {
    width: 50px;
    padding: 14px;
    border-radius: 12px;
    border: none;
    font-size: 18px;
    cursor: pointer;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    transition: all 0.2s;
}

.giveaway-info-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.giveaway-joined-btn {
    flex: 1;
    padding: 14px 20px;
    border-radius: 12px;
    border: none;
    font-size: 15px;
    font-weight: 600;
    cursor: default;
    background: rgba(52, 199, 89, 0.2);
    color: #34c759;
    border: 1px solid rgba(52, 199, 89, 0.3);
}

/* Image Upload Area */
.image-upload-area {
    border: 2px dashed var(--border);
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    background: var(--bg-card);
}

.image-upload-area:hover {
    border-color: var(--accent);
    background: rgba(0, 122, 255, 0.05);
}

.image-upload-placeholder {
    color: var(--text-dim);
    font-size: 14px;
}

.image-preview {
    max-width: 100%;
    max-height: 150px;
    border-radius: 8px;
    object-fit: contain;
}

.giveaway-delete-btn {
    width: 50px;
    padding: 14px;
    border-radius: 12px;
    border: none;
    font-size: 16px;
    cursor: pointer;
    background: rgba(255, 59, 48, 0.2);
    color: #ff3b30;
    transition: all 0.2s;
}

.giveaway-delete-btn:hover {
    background: rgba(255, 59, 48, 0.3);
}

/* ================= GIVEAWAY INFO MODAL ================= */

.giveaway-info-modal {
    padding: 8px;
}

.giveaway-info-header {
    text-align: center;
    margin-bottom: 20px;
}

.giveaway-info-emoji {
    font-size: 48px;
    margin-bottom: 8px;
}

.giveaway-info-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--text);
    margin: 0;
}

.giveaway-info-prize {
    text-align: center;
    margin-bottom: 20px;
}

.giveaway-info-image {
    width: 100px;
    height: 100px;
    object-fit: contain;
    border-radius: 16px;
    margin-bottom: 8px;
}

.giveaway-info-prize-name {
    font-size: 16px;
    font-weight: 600;
    color: var(--text);
}

.giveaway-info-stats {
    display: flex;
    justify-content: space-around;
    background: var(--bg-card);
    border-radius: 16px;
    padding: 16px;
    margin-bottom: 20px;
    border: 1px solid var(--border);
}

.giveaway-info-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.giveaway-info-stat .stat-icon {
    font-size: 20px;
}

.giveaway-info-stat .stat-value {
    font-size: 18px;
    font-weight: 700;
    color: var(--text);
}

.giveaway-info-stat .stat-label {
    font-size: 11px;
    color: var(--text-dim);
}

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

.giveaway-info-section-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 12px;
}

.giveaway-info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    font-size: 14px;
    color: var(--text-dim);
}

.ticket-badge {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
}

.giveaway-ref-link {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--bg);
    padding: 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.giveaway-ref-link:hover {
    background: var(--accent);
}

.giveaway-ref-link:hover .ref-link-text {
    color: white;
}

.ref-link-text {
    flex: 1;
    font-size: 12px;
    color: var(--text-dim);
    word-break: break-all;
}

.ref-link-copy {
    font-size: 16px;
}

.giveaway-info-join-btn {
    width: 100%;
    padding: 16px;
    border-radius: 12px;
    border: none;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    margin-bottom: 12px;
    transition: all 0.2s;
}

.giveaway-info-join-btn:hover {
    transform: scale(1.02);
    box-shadow: 0 4px 20px rgba(102, 126, 234, 0.4);
}

/* Referral Modal */
.giveaway-referral-modal {
    padding: 8px;
    text-align: center;
}

.giveaway-referral-emoji {
    font-size: 64px;
    margin-bottom: 16px;
}

.giveaway-referral-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 12px;
}

.giveaway-referral-prize {
    font-size: 18px;
    color: var(--text-dim);
    margin-bottom: 24px;
}

.giveaway-referral-join-btn {
    width: 100%;
    padding: 16px;
    border-radius: 12px;
    border: none;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    margin-bottom: 12px;
    transition: all 0.2s;
}

.giveaway-referral-join-btn:hover {
    transform: scale(1.02);
    box-shadow: 0 4px 20px rgba(102, 126, 234, 0.4);
}

/* ===== TON EXCHANGE PAYMENT BUTTONS ===== */
.payment-method-btn {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    background: rgba(45, 45, 50, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 14px;
    margin-bottom: 10px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    -webkit-tap-highlight-color: transparent;
}

.payment-method-btn:hover {
    background: rgba(55, 55, 60, 0.95);
    border-color: rgba(0, 122, 255, 0.4);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.payment-method-btn:active {
    background: rgba(60, 60, 65, 1);
    transform: scale(0.98);
    border-color: var(--accent);
}

.payment-method-btn .method-icon {
    font-size: 24px;
    flex-shrink: 0;
}

.payment-method-btn .method-name {
    font-size: 16px;
    font-weight: 600;
    color: var(--text);
    flex: 1;
}

/* Заголовок модального окна оплаты */
.payment-header-sbp {
    text-align: center;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 16px;
}

.payment-header-sbp h3 {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 12px;
    text-align: center;
}


.payment-amount-large {
    font-size: 32px;
    font-weight: 700;
    color: #34c759;
    letter-spacing: -0.5px;
    text-align: center;
}

/* Кнопка отмены */
.cancel-btn-wrap {
    display: block;
    width: 100%;
    padding: 14px;
    background: rgba(60, 60, 67, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    text-align: center;
    font-size: 16px;
    font-weight: 500;
    color: var(--text-dim);
    cursor: pointer;
    transition: all 0.2s ease;
    margin-top: 8px;
}

.cancel-btn-wrap:hover {
    background: rgba(70, 70, 77, 0.8);
}

.cancel-btn-wrap:active {
    transform: scale(0.98);
    background: rgba(80, 80, 87, 1);
}

.payment-method-btn .method-arrow {
    font-size: 24px;
    color: var(--text-dim);
    font-weight: 300;
    opacity: 0.6;
    transition: all 0.2s ease;
}

.payment-method-btn:hover .method-arrow {
    opacity: 1;
    transform: translateX(4px);
    color: var(--accent);
}

/* Центрирование заголовков в модальных окнах */
#recipientModalBody h2,
#paymentModalBody h2 {
    text-align: center;
    margin-bottom: 20px;
}

#recipientModalBody .recipient-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 20px;
}

#recipientModalBody .recipient-next-btn {
    text-align: center;
}

.history-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    padding: 16px;
    margin-top: 8px;
}

.history-pagination-btn {
    background: rgba(0, 122, 255, 0.15);
    border: 1px solid rgba(0, 122, 255, 0.3);
    border-radius: 10px;
    color: var(--accent);
    padding: 10px 20px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 600;
}

.history-pagination-btn:active {
    transform: scale(0.95);
    background: rgba(0, 122, 255, 0.25);
}

.history-pagination-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
    color: var(--text-dim);
    background: var(--bg-card);
    border-color: var(--border);
}

.history-pagination-info {
    color: var(--text-dim);
    font-size: 14px;
    font-weight: 500;
}

/* TON icon in swap form */
.swap-currency-icon-img {
    width: 24px;
    height: 24px;
    object-fit: contain;
    display: block;
    flex-shrink: 0;
}

/* Swap currency selector fix */
.swap-currency-selector {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 16px;
    background: transparent;
}

/* History TON icon */
.history-ton-icon {
    width: 28px;
    height: 28px;
    object-fit: contain;
}

/* ===== PAYMENT CANCEL CONFIRMATION ===== */
.ios-confirmation-dialog {
    text-align: center;
    padding: 32px 24px;
    animation: fadeInDialog 0.3s ease-out;
}

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

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

.confirmation-icon {
    font-size: 48px;
    margin-bottom: 16px;
}

.confirmation-title {
    font-size: 20px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 12px;
}

.confirmation-message {
    font-size: 15px;
    color: var(--text-dim);
    line-height: 1.5;
    margin-bottom: 24px;
}

.confirmation-buttons {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.confirm-cancel-btn {
    background: rgba(255, 59, 48, 0.15);
    border: 1px solid rgba(255, 59, 48, 0.3);
    border-radius: 12px;
    color: #ff3b30;
    padding: 14px 24px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.confirm-cancel-btn:active {
    transform: scale(0.98);
    background: rgba(255, 59, 48, 0.25);
}

.confirm-back-btn {
    background: rgba(0, 122, 255, 0.15);
    border: 1px solid rgba(0, 122, 255, 0.3);
    border-radius: 12px;
    color: var(--accent);
    padding: 14px 24px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.confirm-back-btn:active {
    transform: scale(0.98);
    background: rgba(0, 122, 255, 0.25);
}

/* ===== HIDE ACCOUNTING TAB ===== */
#navAccounting {
    display: none !important;
}

.nav-item[data-tab="accounting"] {
    display: none !important;
}

/* ===== TRANSPARENT BOTTOM NAVIGATION ===== */
.bottom-nav {
    position: fixed;
    bottom: 16px;
    left: 16px;
    right: 16px;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-around;
    padding: 10px 6px;
    background: rgba(28, 28, 30, 0.6);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border-radius: 24px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    transition: all 0.2s ease;
    overflow: hidden;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    padding: 8px 16px;
    border-radius: 16px;
    cursor: pointer;
    transition: all 0.15s ease;
    -webkit-tap-highlight-color: transparent;
    position: relative;
    background: transparent;
}

.nav-item::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.1);
    opacity: 0;
    transition: all 0.15s ease;
}

.nav-item:active::before,
.nav-item.active::before {
    opacity: 1;
}

.nav-icon {
    width: 24px;
    height: 24px;
    color: rgba(255, 255, 255, 0.5);
    transition: all 0.15s ease;
    position: relative;
    z-index: 1;
}

.nav-item.active .nav-icon {
    color: #ffffff;
}

.nav-text {
    font-size: 10px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.5);
    transition: all 0.15s ease;
    position: relative;
    z-index: 1;
    text-align: center;
}

.nav-item.active .nav-text {
    color: #ffffff;
    font-weight: 600;
}

.nav-item:active {
    transform: scale(0.95);
}

/* Safe area support for iPhone */
@supports (padding-bottom: env(safe-area-inset-bottom)) {
    .bottom-nav {
        bottom: calc(16px + env(safe-area-inset-bottom));
    }
}