:root {
    --bg-dark: #0D0D14;
    --bg-card: #1A1A24;
    --bg-input: #252530;
    --text-main: #FFFFFF;
    --text-muted: #9CA3AF;
    --accent-purple: #9333EA;
    --accent-purple-light: #A855F7;
    --accent-green: #22C55E;
    --accent-cyan: #00E5A0;
    --accent-gold: #EAB308;
    --border-dark: #2A2A35;
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-main);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

.app-container {
    max-width: 430px; /* Mobile width */
    margin: 0 auto;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
    background: radial-gradient(circle at 50% 30%, #1a1a2b 0%, var(--bg-dark) 70%);
}

/* --- TOP BAR --- */
.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    z-index: 10;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
}

.balance-pill {
    display: flex;
    align-items: center;
    background-color: rgba(26, 26, 36, 0.8);
    backdrop-filter: blur(8px);
    border: 1px solid var(--border-dark);
    border-radius: 20px;
    padding: 6px 12px;
    gap: 8px;
}

.balance-amount {
    font-weight: 600;
    font-size: 14px;
    letter-spacing: 0.5px;
}

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

.wallet-btn {
    background-color: var(--accent-purple);
    border: none;
    border-radius: 8px;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(147, 51, 234, 0.5);
}

.profile-avatar img {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: #2C2C3A;
    border: 1px solid var(--border-dark);
}

/* --- MAIN AREA --- */
.betting-area {
    flex: 1;
    display: flex;
    flex-direction: column;
    position: relative;
}

/* --- MULTIPLIERS --- */
.multipliers {
    position: relative;
    height: 80px;
    width: 100%;
}

.badge {
    position: absolute;
    background-color: rgba(13, 13, 20, 0.6);
    backdrop-filter: blur(4px);
    border: 1px solid var(--border-dark);
    border-radius: 12px;
    color: var(--accent-green);
    font-size: 12px;
    font-weight: 600;
    padding: 4px 8px;
    display: flex;
    align-items: center;
    gap: 4px;
    transform: translateY(0);
    animation: float 3s ease-in-out infinite;
}

.badge.active {
    border-color: var(--accent-green);
    background-color: rgba(34, 197, 94, 0.1);
    z-index: 2;
}

.badge .dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
}
.dot.green { background-color: var(--accent-green); box-shadow: 0 0 5px var(--accent-green); }
.dot.gold { background-color: var(--accent-gold); box-shadow: 0 0 5px var(--accent-gold); }

.grid-btn {
    position: absolute;
    background-color: rgba(26, 26, 36, 0.8);
    border: 1px solid var(--border-dark);
    border-radius: 8px;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}

/* --- HERO SLOT MACHINE --- */
.hero-section {
    position: relative;
    height: 320px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 20px 0;
}

.casino-bg {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: radial-gradient(ellipse at center, rgba(234, 179, 8, 0.15) 0%, transparent 70%);
    z-index: 0;
}

.slot-machine {
    position: relative;
    z-index: 10;
    width: 280px;
    background: linear-gradient(180deg, #3a3a48 0%, #252530 100%);
    border-radius: 16px;
    padding: 16px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.5), inset 0 2px 0 rgba(255,255,255,0.1);
    border: 1px solid #4a4a58;
}

.slot-title {
    background: linear-gradient(90deg, #7C3AED, #9333EA, #7C3AED);
    border-radius: 20px;
    padding: 6px 0;
    text-align: center;
    margin-bottom: 16px;
    box-shadow: 0 4px 10px rgba(147, 51, 234, 0.4);
    border: 1px solid #A855F7;
}

.pasino-text {
    font-family: 'Pacifico', cursive;
    font-size: 20px;
    color: white;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

.slot-display-container {
    background: #111118;
    border-radius: 12px;
    padding: 12px;
    position: relative;
    border: 2px solid #0D0D14;
    box-shadow: inset 0 10px 20px rgba(0,0,0,0.8);
}

.slot-display {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    height: 60px;
    overflow: hidden;
}

.reel-column {
    flex: 1;
    background: linear-gradient(180deg, #252530 0%, #3a3a48 50%, #252530 100%);
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    border: 1px solid #1A1A24;
}

.reel {
    font-size: 36px;
    font-weight: 700;
    color: white;
    text-shadow: 0 2px 5px rgba(0,0,0,0.5);
    /* For animation, we would translate this Y */
}

.spin-btn {
    display: block;
    width: 100px;
    margin: 20px auto 0;
    background: linear-gradient(180deg, #581C87, #3B0764);
    border: 2px solid #7C3AED;
    border-radius: 8px;
    color: white;
    font-weight: 700;
    font-size: 14px;
    padding: 8px 0;
    box-shadow: 0 4px 0 #2E1065, 0 8px 15px rgba(0,0,0,0.5);
    cursor: pointer;
    transition: all 0.1s;
}

.spin-btn:active {
    transform: translateY(4px);
    box-shadow: 0 0 0 #2E1065, 0 4px 10px rgba(0,0,0,0.5);
}

/* Character Placeholders (to match the flat vector style) */
.character {
    position: absolute;
    z-index: 5;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}

.character-left {
    width: 120px;
    height: 150px;
    bottom: -20px;
    left: -20px;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><path d="M20,90 Q30,40 50,40 T80,90 Z" fill="%236b7280"/><circle cx="50" cy="30" r="20" fill="%236b7280"/><circle cx="45" cy="25" r="3" fill="black"/><circle cx="55" cy="25" r="3" fill="black"/></svg>');
    filter: drop-shadow(0 10px 10px rgba(0,0,0,0.5));
}

.character-bottom {
    width: 100px;
    height: 100px;
    bottom: -40px;
    left: 50%;
    transform: translateX(-50%);
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><rect x="30" y="50" width="40" height="50" rx="5" fill="%234b5563"/><text x="35" y="80" fill="%231f2937" font-size="20" font-family="sans-serif" font-weight="bold">RIP</text><circle cx="20" cy="90" r="10" fill="%23EAB308"/></svg>');
}

.character-right {
    width: 110px;
    height: 140px;
    bottom: 0;
    right: -10px;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><path d="M80,90 Q70,40 50,40 T20,90 Z" fill="%231f2937"/><path d="M50,10 Q30,30 50,50 Q70,30 50,10 Z" fill="%239333EA"/></svg>');
}

/* --- CONTROLS SECTION --- */
.controls-section {
    padding: 0 16px;
    z-index: 10;
}

.range-labels {
    display: flex;
    justify-content: space-between;
    margin-bottom: 16px;
}

.range-box {
    background-color: var(--bg-card);
    border: 1px solid var(--border-dark);
    border-radius: 12px;
    padding: 12px 24px;
    color: var(--text-muted);
    font-size: 14px;
    font-weight: 500;
}

.main-bet-btn {
    width: 100%;
    background: linear-gradient(90deg, #7C3AED, #9333EA);
    color: white;
    border: none;
    border-radius: 16px;
    padding: 16px;
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 20px;
    box-shadow: 0 4px 15px rgba(147, 51, 234, 0.3);
    cursor: pointer;
}

.bet-details-card {
    background-color: transparent;
}

.bet-input-row {
    display: flex;
    gap: 16px;
    margin-bottom: 16px;
}

.input-group {
    flex: 1;
}

.input-group label {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 8px;
    padding-left: 4px;
}

.chance {
    color: var(--text-main);
}

.input-field {
    display: flex;
    align-items: center;
    background-color: var(--bg-input);
    border-radius: 12px;
    padding: 12px;
    gap: 8px;
    border: 1px solid var(--border-dark);
}

.input-field input {
    background: transparent;
    border: none;
    color: white;
    font-size: 16px;
    font-weight: 600;
    width: 100%;
    outline: none;
    font-family: 'Inter', sans-serif;
}

.input-field input.readonly-input {
    color: var(--text-main);
}

.quick-amounts {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
}

.quick-btn {
    flex: 1;
    background-color: var(--bg-card);
    border: 1px solid var(--border-dark);
    border-radius: 8px;
    color: var(--text-muted);
    padding: 10px 0;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
}

.profit-row label {
    font-size: 12px;
    color: var(--text-muted);
    padding-left: 4px;
}

/* --- BOTTOM NAV --- */
.bottom-nav {
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 12px 0 24px; /* extra bottom padding for iOS home indicator */
    background-color: rgba(13, 13, 20, 0.9);
    backdrop-filter: blur(10px);
    border-top: 1px solid var(--border-dark);
    margin-top: auto;
}

.nav-item {
    background: transparent;
    border: none;
    color: var(--text-muted);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    cursor: pointer;
}

.nav-item span {
    font-size: 10px;
    font-weight: 500;
}

.nav-item:hover, .nav-item.active {
    color: var(--text-main);
}
