/* ==========================================
   Dragon Fortune Casino - Premium Style Sheet
   ========================================== */

/* Variables & Base Configurations */
:root {
    --bg-dark: #070404;
    --bg-card: rgba(22, 14, 16, 0.9);
    --primary-red: #d11a2a;
    --primary-red-hover: #b11220;
    --primary-gold: #f3c644;
    --primary-gold-dark: #cc991e;
    --gold-glow: 0 0 15px rgba(243, 198, 68, 0.4);
    --red-glow: 0 0 15px rgba(209, 26, 42, 0.4);
    --text-color: #fcebeb;
    --text-muted: #a89495;
    --border-color: rgba(243, 198, 68, 0.25);
    --border-highlight: rgba(243, 198, 68, 0.6);
    --font-cn: 'Noto Sans SC', system-ui, -apple-system, sans-serif;
    --font-en: 'Outfit', sans-serif;
    --font-logo: 'Cinzel', serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-color);
    font-family: var(--font-cn);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
    padding-bottom: 60px; /* Space for bottom ticker */
}

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 6px;
}
::-webkit-scrollbar-track {
    background: var(--bg-dark);
}
::-webkit-scrollbar-thumb {
    background: var(--primary-red);
    border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--primary-gold);
}

/* Background Ambient Lights */
.ambient-glow {
    position: fixed;
    width: 600px;
    height: 600px;
    border-radius: 50%;
    filter: blur(140px);
    z-index: -2;
    opacity: 0.15;
    pointer-events: none;
}
.bg-glow-1 {
    background: var(--primary-red);
    top: -10%;
    left: -10%;
}
.bg-glow-2 {
    background: var(--primary-gold-dark);
    bottom: -10%;
    right: -10%;
}

/* Floating Lanterns */
.lantern {
    position: fixed;
    font-size: 3rem;
    z-index: -1;
    opacity: 0.25;
    user-select: none;
    pointer-events: none;
}
.lantern.left {
    top: 15%;
    left: 4%;
}
.lantern.right {
    top: 25%;
    right: 4%;
}

/* Micro Animations */
@keyframes float {
    0%, 100% { transform: translateY(0) rotate(-2deg); }
    50% { transform: translateY(-15px) rotate(2deg); }
}
.animate-float {
    animation: float 6s ease-in-out infinite;
}
.animate-float-delayed {
    animation: float 7s ease-in-out infinite;
    animation-delay: 2s;
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.8; transform: scale(1.05); }
}
.animate-pulse {
    animation: pulse 2.5s infinite ease-in-out;
}

/* Falling Gold Coin Particles */
#coin-particle-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 9999;
}
.coin-particle {
    position: absolute;
    font-size: 24px;
    opacity: 0.9;
    user-select: none;
    animation: coin-fall linear forwards;
}

@keyframes coin-fall {
    0% {
        transform: translateY(-50px) rotate(0deg);
        opacity: 1;
    }
    100% {
        transform: translateY(105vh) rotate(720deg);
        opacity: 0;
    }
}

/* Buttons */
.btn {
    border: none;
    border-radius: 8px;
    padding: 10px 20px;
    font-family: var(--font-cn);
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-transform: uppercase;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-gold), var(--primary-gold-dark));
    color: #000;
    box-shadow: var(--gold-glow);
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 25px rgba(243, 198, 68, 0.7);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-color);
    border: 1px solid rgba(255, 255, 255, 0.15);
}
.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
}

.btn-success {
    background: linear-gradient(135deg, #10b981, #047857);
    color: #fff;
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.3);
}
.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 25px rgba(16, 185, 129, 0.6);
}

.btn-danger {
    background: linear-gradient(135deg, var(--primary-red), #8b0000);
    color: #fff;
    box-shadow: var(--red-glow);
}
.btn-danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 25px rgba(209, 26, 42, 0.7);
}

.btn-full {
    width: 100%;
    justify-content: center;
    padding: 14px;
    font-size: 1.1rem;
}

/* Header */
.app-header {
    background: rgba(7, 4, 4, 0.95);
    border-bottom: 1px solid var(--border-color);
    backdrop-filter: blur(15px);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 5%;
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
}
.logo-icon {
    font-size: 2.2rem;
    color: var(--primary-red);
    filter: drop-shadow(0 0 5px var(--primary-red));
}
.logo-text {
    font-family: var(--font-logo);
    font-size: 1.6rem;
    font-weight: 900;
    background: linear-gradient(135deg, #ffffff, var(--primary-gold));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: flex;
    flex-direction: column;
}
.logo-text small {
    font-family: var(--font-en);
    font-size: 0.65rem;
    letter-spacing: 2px;
    color: var(--text-muted);
}

.user-stats {
    display: flex;
    align-items: center;
    gap: 15px;
}

.vip-badge-header {
    background: linear-gradient(135deg, #000, #3a2d0c);
    border: 1px solid var(--primary-gold);
    color: var(--primary-gold);
    padding: 6px 12px;
    border-radius: 4px;
    font-weight: 900;
    font-family: var(--font-en);
    box-shadow: var(--gold-glow);
}
.text-gold {
    color: var(--primary-gold) !important;
}

.stat-box {
    background: rgba(0, 0, 0, 0.7);
    border: 1px solid var(--border-color);
    padding: 8px 16px;
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-en);
    font-size: 1.1rem;
    font-weight: 700;
}
.gold-coin {
    color: var(--primary-gold);
    font-size: 1.2rem;
    filter: drop-shadow(0 0 3px var(--primary-gold));
}

/* Jackpot Banner */
.jackpot-banner {
    background: radial-gradient(circle, #8b0000 0%, #200002 100%);
    border-bottom: 2px solid var(--primary-gold);
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    padding: 10px 0;
    text-shadow: 0 0 8px #ff0000;
}
.jackpot-label {
    font-weight: 900;
    color: var(--primary-gold);
    letter-spacing: 1px;
}
.jackpot-counter {
    font-family: var(--font-en);
    font-size: 1.8rem;
    font-weight: 900;
    color: #fff;
    letter-spacing: 2px;
}

/* Game Switch Tabs */
.game-navigation-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}
.game-tab-btn {
    flex: 1;
    background: #191012;
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    font-family: var(--font-cn);
    font-size: 1.1rem;
    font-weight: 900;
    padding: 15px;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}
.game-tab-btn.active {
    background: linear-gradient(135deg, var(--primary-red), #64050b);
    color: #fff;
    border-color: var(--primary-gold);
    box-shadow: var(--red-glow);
}
.game-tab-btn:hover:not(.active) {
    border-color: var(--primary-gold);
    color: var(--text-color);
}

.game-arena-content {
    display: none;
}
.game-arena-content.active {
    display: block;
}

/* Layout */
.app-container {
    display: grid;
    grid-template-columns: 310px 1fr 280px;
    gap: 25px;
    max-width: 1600px;
    margin: 20px auto;
    padding: 0 20px;
}

/* Sidebar & Live Feed */
.app-sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.sidebar-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 20px;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(15px);
}

.card-glow-bg {
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(243, 198, 68, 0.08) 0%, transparent 60%);
    pointer-events: none;
}
.red-glow-bg {
    background: radial-gradient(circle, rgba(209, 26, 42, 0.08) 0%, transparent 60%);
}

.share-card h3, .live-feed h3, .vip-card h3 {
    font-size: 1.2rem;
    margin-bottom: 12px;
    color: var(--primary-gold);
    display: flex;
    align-items: center;
    gap: 8px;
}
.share-card h3 small, .live-feed h3 small, .vip-card h3 small {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-family: var(--font-en);
    display: block;
}

.share-card p {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 15px;
}

.share-input-group {
    display: flex;
    gap: 5px;
}
.share-input-group input {
    flex: 1;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 8px;
    color: var(--text-muted);
    font-size: 0.75rem;
}
.share-input-group input:focus {
    outline: none;
    border-color: var(--primary-gold);
}

.toast-mini {
    background: #10b981;
    color: #fff;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.8rem;
    margin-top: 10px;
    text-align: center;
    display: none;
}

/* VIP Card Details */
.vip-level-display {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    font-weight: 700;
    margin-bottom: 8px;
}
.progress-bar-container {
    background: rgba(255, 255, 255, 0.08);
    height: 8px;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 6px;
    border: 1px solid rgba(255,255,255,0.05);
}
.progress-bar-fill {
    background: linear-gradient(90deg, var(--primary-gold), #fff);
    height: 100%;
    box-shadow: var(--gold-glow);
}
.progress-details {
    font-size: 0.7rem;
    color: var(--text-muted);
}

/* Live Activity feed */
.feed-container {
    height: 250px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding-right: 5px;
}

.feed-item {
    background: rgba(255, 255, 255, 0.03);
    border-left: 3px solid var(--primary-gold);
    padding: 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    animation: slideIn 0.3s ease-out;
}
.feed-user {
    color: var(--text-muted);
}
.feed-action {
    color: var(--text-color);
}
.feed-gain {
    color: var(--primary-gold);
    font-weight: 700;
}

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

/* Main Area - Marquee Alert */
.marquee-alert {
    background: rgba(209, 26, 42, 0.15);
    border: 1px solid rgba(209, 26, 42, 0.4);
    border-radius: 8px;
    padding: 10px 15px;
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 25px;
    overflow: hidden;
}
.marquee-alert i {
    color: var(--primary-red);
    font-size: 1.2rem;
    animation: shake 1.5s infinite;
}
.marquee-text {
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    position: relative;
    height: 20px;
}
.marquee-text span {
    position: absolute;
    width: 100%;
    height: 100%;
    margin: 0;
    line-height: 20px;
    text-align: left;
    transform: translateX(10%);
    animation: scroll-marquee 25s linear infinite;
    font-size: 0.85rem;
}

@keyframes scroll-marquee {
    0% { transform: translateX(100%); }
    100% { transform: translateX(-100%); }
}

/* Game Board */
.game-section {
    background: var(--bg-card);
    border: 2px solid var(--border-color);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.7);
    position: relative;
}
.game-section::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    pointer-events: none;
}

.game-header {
    text-align: center;
    margin-bottom: 30px;
}
.game-header h2 {
    font-size: 2.2rem;
    font-weight: 900;
    color: var(--primary-gold);
    text-shadow: 0 0 10px rgba(243, 198, 68, 0.3);
}
.game-header h2 small {
    display: block;
    font-family: var(--font-en);
    font-size: 0.9rem;
    color: var(--text-muted);
}
.game-subtitle {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-top: 5px;
}

/* The Dice Shaking Arena */
.game-arena {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
}

.dice-container {
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, #3d0309 0%, #150002 100%);
    border: 6px solid var(--primary-gold);
    border-radius: 50%;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 15px 30px rgba(0,0,0,0.6), inset 0 0 30px rgba(0,0,0,0.8);
}

.dice-plate {
    display: flex;
    gap: 15px;
    z-index: 1;
}

.dice {
    font-size: 2.8rem;
    color: #fff;
    filter: drop-shadow(0 4px 6px rgba(0,0,0,0.5));
    transition: transform 0.15s ease-out;
}
.dice i.fa-dice-one, .dice i.fa-dice-four {
    color: var(--primary-red);
}

.dice-lid {
    position: absolute;
    width: 210px;
    height: 210px;
    background: radial-gradient(circle, #8f0e1a 0%, #3d0309 80%, #1a0104 100%);
    border: 3px solid var(--primary-gold);
    border-radius: 50%;
    z-index: 5;
    box-shadow: 0 10px 20px rgba(0,0,0,0.8);
    transition: transform 0.8s cubic-bezier(0.77, 0, 0.175, 1);
    transform: scale(1);
    display: flex;
    align-items: center;
    justify-content: center;
}
.dice-lid::after {
    content: '福';
    font-size: 4rem;
    color: var(--primary-gold);
    text-shadow: 0 0 15px rgba(243, 198, 68, 0.7);
    font-family: var(--font-cn);
    font-weight: 900;
}

@keyframes shake-cup {
    0% { transform: translate(0, 0) rotate(0deg); }
    10% { transform: translate(-8px, -5px) rotate(-5deg); }
    20% { transform: translate(8px, 5px) rotate(5deg); }
    30% { transform: translate(-10px, 8px) rotate(-8deg); }
    40% { transform: translate(10px, -8px) rotate(8deg); }
    50% { transform: translate(-8px, 5px) rotate(-5deg); }
    60% { transform: translate(8px, -5px) rotate(5deg); }
    70% { transform: translate(-5px, 8px) rotate(-3deg); }
    80% { transform: translate(5px, -5px) rotate(3deg); }
    90% { transform: translate(-2px, 2px) rotate(-1deg); }
    100% { transform: translate(0, 0) rotate(0deg); }
}
.shaking {
    animation: shake-cup 0.8s ease-in-out infinite;
}

.lid-open {
    transform: translateY(-240px) scale(0.95);
    opacity: 0.1;
    pointer-events: none;
}

.roll-result-overlay {
    background: rgba(7, 4, 4, 0.95);
    border: 2px solid var(--primary-gold);
    color: var(--primary-gold);
    padding: 10px 30px;
    border-radius: 50px;
    font-size: 1.5rem;
    font-weight: 900;
    box-shadow: var(--gold-glow);
    display: none;
    animation: fadeIn 0.4s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.8); }
    to { opacity: 1; transform: scale(1); }
}

/* Betting Board */
.betting-board {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 15px;
    width: 100%;
}

.bet-area {
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px 10px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
}
.bet-area:hover {
    background: rgba(209, 26, 42, 0.1);
    border-color: var(--primary-red);
}
.bet-area.selected {
    background: rgba(209, 26, 42, 0.25);
    border-color: var(--primary-gold);
    box-shadow: inset 0 0 15px rgba(243, 198, 68, 0.2);
}

.bet-area.highlight {
    border-color: rgba(243, 198, 68, 0.5);
}

.bet-title {
    font-size: 1.8rem;
    font-weight: 900;
    color: var(--text-color);
}
.bet-area.highlight .bet-title {
    color: var(--primary-gold);
}
.bet-title small {
    display: block;
    font-size: 0.75rem;
    color: var(--text-muted);
    font-family: var(--font-en);
}

.bet-odds {
    font-family: var(--font-en);
    color: var(--primary-gold);
    font-size: 1.1rem;
    font-weight: 700;
    margin: 5px 0;
}
.bet-desc {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.placed-bet-chips {
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, var(--primary-red), #5c0005);
    color: #fff;
    font-family: var(--font-en);
    font-size: 0.8rem;
    font-weight: 700;
    padding: 2px 10px;
    border-radius: 20px;
    border: 1px solid var(--primary-gold);
    box-shadow: 0 2px 5px rgba(0,0,0,0.5);
    opacity: 0;
    transition: opacity 0.3s, transform 0.3s;
    z-index: 10;
}
.placed-bet-chips.has-chips {
    opacity: 1;
    transform: translateX(-50%) translateY(-2px);
}

/* Bet Controls */
.bet-controls {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 10px;
}

.chip-selector {
    display: flex;
    justify-content: center;
    gap: 12px;
}

.chip-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 3px dashed var(--primary-gold);
    background: radial-gradient(circle, #222 0%, #000 100%);
    color: var(--primary-gold);
    font-family: var(--font-en);
    font-weight: 900;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 6px rgba(0,0,0,0.3);
}
.chip-btn:hover {
    transform: scale(1.1);
    border-style: solid;
}
.chip-btn.active {
    background: radial-gradient(circle, var(--primary-red) 0%, #3a0003 100%);
    border: 3px solid var(--primary-gold);
    color: #fff;
    transform: scale(1.15);
    box-shadow: var(--gold-glow);
}

.action-buttons {
    display: flex;
    gap: 15px;
    width: 100%;
}
.action-buttons .btn {
    flex: 1;
    justify-content: center;
    padding: 12px;
}

/* Roulette Specific Styles */
.roulette-wrapper {
    position: relative;
    width: 280px;
    height: 280px;
    margin: 10px auto;
}
.roulette-pointer {
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 2.5rem;
    color: var(--primary-gold);
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.8));
    z-index: 20;
}
.roulette-wheel {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 8px solid var(--primary-gold);
    box-shadow: 0 15px 30px rgba(0,0,0,0.8), inset 0 0 20px rgba(0,0,0,0.9);
    position: relative;
    /* Create visual look of sections using CSS conic gradient (0 to 36 sections) */
    background: conic-gradient(
        #07c160 0% 2.7%,
        #d11a2a 2.7% 8.1%, #111 8.1% 13.5%,
        #d11a2a 13.5% 18.9%, #111 18.9% 24.3%,
        #d11a2a 24.3% 29.7%, #111 29.7% 35.1%,
        #d11a2a 35.1% 40.5%, #111 40.5% 45.9%,
        #d11a2a 45.9% 51.3%, #111 51.3% 56.7%,
        #d11a2a 56.7% 62.1%, #111 62.1% 67.5%,
        #d11a2a 67.5% 72.9%, #111 72.9% 78.3%,
        #d11a2a 78.3% 83.7%, #111 83.7% 89.1%,
        #d11a2a 89.1% 94.5%, #111 94.5% 100%
    );
    transition: transform 5s cubic-bezier(0.06, 0.8, 0.1, 1);
}
.wheel-center {
    position: absolute;
    width: 80px;
    height: 80px;
    background: radial-gradient(circle, #3d0309 0%, #1a0104 100%);
    border: 4px solid var(--primary-gold);
    border-radius: 50%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 4px 10px rgba(0,0,0,0.8);
}
.wheel-logo {
    color: var(--primary-gold);
    font-size: 2.2rem;
    font-weight: 900;
    text-shadow: 0 0 10px rgba(243, 198, 68, 0.8);
}

.roulette-betting-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    width: 100%;
}
.roulette-betting-grid .bet-area.highlight {
    grid-column: span 1;
}
.roulette-betting-grid .gold-bet {
    grid-column: span 2;
    border-color: var(--primary-gold);
}
.roulette-betting-grid .gold-bet .bet-title {
    color: var(--primary-gold);
}

.red-bet:hover {
    background: rgba(209, 26, 42, 0.15) !important;
}
.black-bet:hover {
    background: rgba(255, 255, 255, 0.05) !important;
}

/* Rules Tables */
.rules-section {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 25px;
    margin-top: 25px;
}
.rules-section h3 {
    color: var(--primary-gold);
    margin-bottom: 15px;
}
.rules-table-container {
    overflow-x: auto;
}
.rules-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
    text-align: left;
}
.rules-table th, .rules-table td {
    padding: 12px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
}
.rules-table th {
    background: rgba(243,198,68,0.1);
    color: var(--primary-gold);
    font-weight: 700;
}
.rules-table tr:hover {
    background: rgba(255,255,255,0.02);
}

/* Advertisements Sidebar */
.app-ads-sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.ad-title-tag {
    font-size: 0.8rem;
    text-transform: uppercase;
    color: var(--text-muted);
    letter-spacing: 2px;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding-bottom: 8px;
}

.fictive-ad {
    background: rgba(22, 14, 16, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 15px;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s;
}
.fictive-ad:hover {
    transform: translateY(-3px);
    border-color: var(--ad-color);
}

.ad-glow {
    position: absolute;
    width: 100px;
    height: 100px;
    background: var(--ad-color);
    filter: blur(40px);
    border-radius: 50%;
    top: -20px;
    right: -20px;
    opacity: 0.15;
    transition: opacity 0.3s;
}
.fictive-ad:hover .ad-glow {
    opacity: 0.35;
}

.ad-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    background: var(--ad-color);
    color: #000;
    font-size: 0.6rem;
    font-weight: 900;
    padding: 2px 6px;
    border-radius: 3px;
    letter-spacing: 1px;
}

.ad-content {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.ad-icon {
    font-size: 1.5rem;
    color: var(--ad-color);
}

.ad-content h4 {
    font-size: 0.95rem;
    color: var(--text-color);
}
.ad-content p {
    font-size: 0.75rem;
    color: var(--text-muted);
    line-height: 1.3;
}
.ad-btn {
    font-size: 0.75rem;
    color: var(--ad-color);
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 5px;
    margin-top: 5px;
}

/* Modals & Popups */
.modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(15px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.3s ease-out;
}
.modal-overlay.active {
    display: flex;
    opacity: 1;
}

.modal-card {
    background: #171113;
    border: 2px solid var(--primary-gold);
    width: 100%;
    max-width: 520px;
    border-radius: 20px;
    padding: 30px;
    position: relative;
    box-shadow: 0 20px 50px rgba(0,0,0,0.8), var(--gold-glow);
    transform: scale(0.9);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.modal-overlay.active .modal-card {
    transform: scale(1);
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 20px;
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 1.8rem;
    cursor: pointer;
    transition: color 0.2s;
}
.modal-close:hover {
    color: var(--primary-red);
}

.modal-header {
    text-align: center;
    margin-bottom: 25px;
}
.modal-header h2 {
    color: var(--primary-gold);
    font-size: 1.8rem;
}
.modal-header h2 small {
    display: block;
    font-family: var(--font-en);
    font-size: 0.8rem;
    color: var(--text-muted);
}
.modal-header p {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 5px;
}

/* Modal Tabs */
.payment-tabs {
    display: flex;
    border-bottom: 2px solid rgba(255,255,255,0.05);
    margin-bottom: 20px;
}
.pay-tab {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-family: var(--font-cn);
    font-size: 0.95rem;
    font-weight: 700;
    padding: 12px;
    cursor: pointer;
    transition: all 0.3s;
    border-bottom: 2px solid transparent;
}
.pay-tab i {
    margin-right: 5px;
}
.pay-tab.active {
    color: var(--primary-gold);
    border-bottom-color: var(--primary-gold);
}
.pay-tab[data-target="alipay"].active {
    color: #409eff;
    border-bottom-color: #409eff;
}
.pay-tab[data-target="wechat"].active {
    color: #07c160;
    border-bottom-color: #07c160;
}

/* Payment Body details */
.payment-method-details {
    display: none;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}
.payment-method-details.active {
    display: flex;
}

/* QR Code Container and Scanning Laser Animation */
.qr-container {
    width: 140px;
    height: 140px;
    background: #fff;
    border-radius: 8px;
    padding: 10px;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border: 3px solid var(--primary-gold);
}
.qr-placeholder {
    font-size: 6.5rem;
    color: #409eff;
}
.qr-desc {
    font-size: 0.6rem;
    color: #000;
    font-family: var(--font-en);
    margin-top: 2px;
    text-align: center;
}

.qr-scanner-line {
    position: absolute;
    width: 100%;
    height: 3px;
    background: rgba(255, 0, 0, 0.7);
    box-shadow: 0 0 8px red;
    top: 0;
    left: 0;
    animation: scanner 2s linear infinite;
    pointer-events: none;
}

@keyframes scanner {
    0% { top: 0; }
    50% { top: 100%; }
    100% { top: 0; }
}

/* Form Fields inside Modal */
.payment-fields {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.pay-field {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.pay-field .label {
    font-size: 0.75rem;
    color: var(--text-muted);
}
.input-copy-group {
    display: flex;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 6px 10px;
    align-items: center;
    justify-content: space-between;
}
.value-text {
    font-family: var(--font-en);
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--primary-gold);
}
.highlight-memo {
    background: rgba(209, 26, 42, 0.15);
    border: 1px dashed var(--primary-red);
    padding: 4px 10px;
    border-radius: 4px;
    width: max-content;
}

.btn-sm {
    padding: 4px 10px;
    font-size: 0.75rem;
}

/* Simulation input */
.simulation-form {
    width: 100%;
    border-top: 1px solid rgba(255,255,255,0.05);
    padding-top: 20px;
    margin-top: 10px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.simulation-form label {
    font-size: 0.8rem;
    color: var(--text-muted);
}
.simulation-form input {
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 12px;
    color: #fff;
    font-size: 1.2rem;
    font-family: var(--font-en);
    font-weight: 700;
    text-align: center;
}
.simulation-form input:focus {
    outline: none;
    border-color: var(--primary-gold);
}

.modal-toast {
    position: absolute;
    bottom: -40px;
    left: 50%;
    transform: translateX(-50%);
    background: #10b981;
    color: #fff;
    padding: 8px 20px;
    border-radius: 30px;
    font-size: 0.9rem;
    box-shadow: 0 4px 10px rgba(0,0,0,0.5);
    display: none;
    z-index: 1010;
    width: max-content;
}

/* Bottom Scrolling Payout Ticker */
.app-bottom-ticker {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 44px;
    background: #000;
    border-top: 1.5px solid var(--primary-red);
    z-index: 999;
    display: flex;
    align-items: center;
    overflow: hidden;
}
.ticker-wrapper {
    width: 100%;
    overflow: hidden;
}
.ticker-content {
    display: flex;
    white-space: nowrap;
    gap: 50px;
    animation: marquee-bottom 40s linear infinite;
    font-size: 0.85rem;
    font-weight: 700;
}
.ticker-content span {
    color: #fff;
}
.ticker-content b {
    color: var(--primary-gold);
}

@keyframes marquee-bottom {
    0% { transform: translateX(100%); }
    100% { transform: translateX(-100%); }
}

/* Responsive Scaling */
@media (max-width: 1024px) {
    .app-container {
        grid-template-columns: 1fr;
    }
    .app-sidebar, .app-ads-sidebar {
        order: 2;
    }
    .lantern {
        display: none;
    }
}

@media (max-width: 500px) {
    .app-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    .betting-board, .roulette-betting-grid {
        grid-template-columns: 1fr;
    }
    .roulette-betting-grid .gold-bet {
        grid-column: span 1;
    }
    .chip-selector {
        flex-wrap: wrap;
    }
    .jackpot-banner {
        flex-direction: column;
        gap: 5px;
        text-align: center;
    }
}
