/* Professional Dark Theme + Realistic Banking UI */

:root {
    --bg-main: #0b111a;
    --bg-card: #151f2e;
    --primary: #2563eb;
    --accent: #10b981;
    --text-primary: #f8fafc;
    --text-sec: #94a3b8;
    --danger: #ef4444;
    --warn: #f59e0b;
}

body {
    background: var(--bg-main);
    color: var(--text-primary);
    font-family: 'Tajawal', sans-serif;
    margin: 0;
    height: 100vh;
    display: flex;
    justify-content: center;
    overflow: hidden;
}

/* Auth & Overlays */
.overlay {
    position: fixed;
    inset: 0;
    background: url('https://w.forfun.com/fetch/f2/f247a8274642f4c2c77609787ff823bc.jpeg') center/cover;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.auth-box {
    background: rgba(11, 17, 26, 0.95);
    backdrop-filter: blur(10px);
    padding: 2.5rem;
    border-radius: 16px;
    width: 100%;
    max-width: 400px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    border: 1px solid #1e293b;
    text-align: center;
}

.input-group {
    position: relative;
    margin-bottom: 1.5rem;
    text-align: left;
}

.input-group input {
    width: 100%;
    padding: 12px;
    background: #1e293b;
    border: 1px solid #334155;
    border-radius: 8px;
    color: white;
}

.input-group label {
    position: absolute;
    top: -8px;
    right: 10px;
    background: #0b111a;
    padding: 0 5px;
    font-size: 0.8rem;
    color: var(--primary);
}

/* Game Interface */
#game-ui {
    width: 100%;
    max-width: 600px;
    background: var(--bg-card);
    display: flex;
    flex-direction: column;
    height: 100vh;
    border-left: 1px solid #1e293b;
    border-right: 1px solid #1e293b;
}

.top-bar {
    padding: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #0f1623;
    border-bottom: 1px solid #1e293b;
}

.user-block {
    display: flex;
    align-items: center;
    gap: 10px;
}

.avatar {
    width: 35px;
    height: 35px;
    background: #334155;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.balance-card {
    background: linear-gradient(135deg, #1e3a8a, #172554);
    padding: 8px 16px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.deposit-icon-btn {
    background: var(--accent);
    color: #000;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: none;
    font-weight: bold;
    cursor: pointer;
}

/* Main Game Area */
.game-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 20px;
}

#plinko-board-container {
    height: 400px;
    position: relative;
    margin-bottom: 10px;
}

.peg {
    position: absolute;
    width: 6px;
    height: 6px;
    background: white;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    box-shadow: 0 0 5px rgba(255, 255, 255, 0.5);
}

.game-ball {
    position: absolute;
    width: 14px;
    height: 14px;
    background: #fbbf24;
    border-radius: 50%;
    box-shadow: 0 0 8px #fbbf24;
    z-index: 100;
}

#betting-sections {
    display: flex;
    gap: 4px;
    height: 40px;
}

.bucket {
    flex: 1;
    background: #1e293b;
    border-radius: 4px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: bold;
    color: #cbd5e1;
}

/* Controls */
.controls-bar {
    padding: 20px;
    background: #0f1623;
    display: flex;
    gap: 15px;
    border-top: 1px solid #1e293b;
}

.bet-control {
    flex: 1;
    display: flex;
    background: #1e293b;
    border-radius: 10px;
    padding: 4px;
    align-items: center;
    justify-content: space-between;
}

.adj {
    width: 40px;
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
}

.play-btn {
    flex: 1.5;
    background: var(--accent);
    color: #000;
    font-weight: 900;
    font-size: 1.2rem;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: 0.1s;
}

.play-btn:active {
    transform: translateY(2px);
}

/* Banking Portal */
.modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
    z-index: 5000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.banking-portal {
    width: 90%;
    max-width: 900px;
    height: 600px;
    background: #1e293b;
    border-radius: 16px;
    display: flex;
    overflow: hidden;
    box-shadow: 0 0 50px rgba(0, 0, 0, 0.5);
}

.portal-sidebar {
    width: 200px;
    background: #0f1623;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.nav-item {
    background: transparent;
    border: none;
    color: #94a3b8;
    text-align: right;
    padding: 12px;
    cursor: pointer;
    font-size: 1rem;
    border-radius: 8px;
}

.nav-item.active {
    background: #1e293b;
    color: white;
    font-weight: bold;
    border-right: 3px solid var(--primary);
}

.portal-balance {
    margin-top: auto;
    color: #94a3b8;
    font-size: 0.8rem;
}

#portal-balance {
    display: block;
    font-size: 1.2rem;
    color: white;
    font-weight: bold;
}

.portal-content {
    flex: 1;
    background: #151f2e;
    padding: 30px;
    position: relative;
    overflow-y: auto;
}

/* Wizard Steps */
.steps-indicator {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
    border-bottom: 1px solid #334155;
    padding-bottom: 15px;
}

.step {
    color: #64748b;
    font-size: 0.9rem;
}

.step.active {
    color: var(--primary);
    font-weight: bold;
}

.methods-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 15px;
}

.payment-card {
    background: #1e293b;
    border: 1px solid #334155;
    padding: 20px;
    border-radius: 12px;
    cursor: pointer;
    text-align: center;
    position: relative;
    transition: 0.2s;
}

.payment-card:hover {
    border-color: var(--primary);
    background: #252f3f;
}

.payment-card .badge {
    position: absolute;
    top: -8px;
    right: 10px;
    background: var(--accent);
    color: black;
    font-size: 0.6rem;
    padding: 2px 6px;
    border-radius: 4px;
}

.icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    margin: 0 auto 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

.sc {
    background: #e11d48;
    color: white;
}

.sh {
    background: #fbbf24;
    color: black;
}

.transfer-box {
    background: rgba(37, 99, 235, 0.1);
    border: 1px dashed var(--primary);
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.copy-box {
    display: flex;
    justify-content: space-between;
    background: #0f1623;
    padding: 10px;
    border-radius: 6px;
    margin: 10px 0;
    align-items: center;
}

.code {
    font-family: monospace;
    font-size: 1.2rem;
    letter-spacing: 1px;
    color: var(--primary);
}

.copy-btn {
    background: #334155;
    border: none;
    padding: 5px 10px;
    color: white;
    border-radius: 4px;
    cursor: pointer;
}

.upload-zone {
    border: 2px dashed #475569;
    padding: 40px;
    text-align: center;
    border-radius: 12px;
    margin: 20px 0;
    cursor: pointer;
    background: #1e293b;
}

.upload-zone:hover {
    border-color: var(--primary);
}

.confirm-pay-btn {
    width: 100%;
    padding: 15px;
    background: var(--primary);
    border: none;
    color: white;
    font-weight: bold;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
}

.next-btn {
    width: 100%;
    padding: 12px;
    background: var(--primary);
    border: none;
    color: white;
    border-radius: 8px;
    cursor: pointer;
    margin-top: 10px;
}

.back-text-btn {
    background: none;
    border: none;
    color: #94a3b8;
    width: 100%;
    margin-top: 10px;
    cursor: pointer;
    text-decoration: underline;
}

/* Status Badges */
.status-badge {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: bold;
}

.pending {
    background: rgba(245, 158, 11, 0.2);
    color: #f59e0b;
}

.success {
    background: rgba(16, 185, 129, 0.2);
    color: #10b981;
}

.txn-item {
    display: flex;
    justify-content: space-between;
    padding: 15px;
    border-bottom: 1px solid #334155;
}