/* ============================================================
   AdsEarn — Master Stylesheet
   Dark Premium UI | Mobile First | Glassmorphism
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=Outfit:wght@400;600;700;800&display=swap');

/* ── RESET & BASE ─────────────────────────────────────────── */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --bg-900: #0a0c10;
    --bg-800: #10131a;
    --bg-700: #161b26;
    --bg-600: #1e2639;
    --bg-glass: rgba(22, 27, 38, 0.75);
    --border: rgba(255, 255, 255, 0.08);

    --accent: #6c63ff;
    --accent2: #a78bfa;
    --gold: #f59e0b;
    --gold2: #fbbf24;
    --green: #10b981;
    --red: #ef4444;
    --blue: #3b82f6;
    --pink: #ec4899;

    --text-1: #f1f5f9;
    --text-2: #94a3b8;
    --text-3: #64748b;

    --radius: 16px;
    --radius-sm: 10px;
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.6);

    --grad-accent: linear-gradient(135deg, #6c63ff, #a78bfa);
    --grad-gold: linear-gradient(135deg, #f59e0b, #fbbf24);
    --grad-green: linear-gradient(135deg, #059669, #10b981);
    --grad-hero: linear-gradient(135deg, #6c63ff 0%, #ec4899 50%, #f59e0b 100%);
    --grad-card: linear-gradient(135deg, rgba(108, 99, 255, 0.12), rgba(167, 139, 250, 0.06));
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background: var(--bg-900);
    color: var(--text-1);
    min-height: 100vh;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
}

input,
select,
textarea,
button {
    font-family: inherit;
}

/* ── SCROLLBAR ────────────────────────────────────────────── */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: var(--bg-800);
}

::-webkit-scrollbar-thumb {
    background: var(--accent);
    border-radius: 99px;
}

/* ── TYPOGRAPHY ───────────────────────────────────────────── */
.font-display {
    font-family: 'Outfit', sans-serif;
}

h1,
h2,
h3 {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
}

h1 {
    font-size: clamp(2rem, 5vw, 3.5rem);
}

h2 {
    font-size: clamp(1.5rem, 3vw, 2.2rem);
}

h3 {
    font-size: clamp(1.1rem, 2vw, 1.5rem);
}

/* ── LAYOUT ───────────────────────────────────────────────── */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.app-wrapper {
    display: flex;
    min-height: 100vh;
}

/* ── SIDEBAR ──────────────────────────────────────────────── */
.sidebar {
    width: 260px;
    background: var(--bg-800);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 100;
    transition: transform .3s cubic-bezier(.4, 0, .2, 1);
}

.sidebar-logo {
    padding: 28px 24px 20px;
    border-bottom: 1px solid var(--border);
}

.sidebar-logo .logo-text {
    font-family: 'Outfit', sans-serif;
    font-size: 1.6rem;
    font-weight: 800;
    background: var(--grad-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.sidebar-logo .logo-sub {
    font-size: .75rem;
    color: var(--text-3);
    margin-top: 2px;
}

.sidebar-nav {
    flex: 1;
    padding: 16px 12px;
    overflow-y: auto;
}

.nav-section-label {
    font-size: .65rem;
    font-weight: 600;
    letter-spacing: .1em;
    color: var(--text-3);
    text-transform: uppercase;
    padding: 12px 12px 6px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 14px;
    border-radius: var(--radius-sm);
    color: var(--text-2);
    font-size: .9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all .2s;
    margin-bottom: 2px;
    border: 1px solid transparent;
}

.nav-item:hover {
    background: var(--bg-600);
    color: var(--text-1);
    border-color: var(--border);
}

.nav-item.active {
    background: var(--grad-accent);
    color: #fff;
    box-shadow: 0 4px 20px rgba(108, 99, 255, 0.35);
}

.nav-item .nav-icon {
    width: 20px;
    font-size: 1.1rem;
    flex-shrink: 0;
}

.nav-badge {
    margin-left: auto;
    background: var(--red);
    color: #fff;
    font-size: .65rem;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: 99px;
}

.sidebar-footer {
    padding: 16px 12px;
    border-top: 1px solid var(--border);
}

.sidebar-user {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    background: var(--bg-700);
    margin-bottom: 8px;
}

.sidebar-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--grad-accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: .9rem;
    color: #fff;
    flex-shrink: 0;
}

.sidebar-user-info .user-name {
    font-size: .85rem;
    font-weight: 600;
}

.sidebar-user-info .user-email {
    font-size: .7rem;
    color: var(--text-3);
}

.btn-logout {
    width: 100%;
    padding: 10px;
    border-radius: var(--radius-sm);
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: var(--red);
    font-size: .85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all .2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-logout:hover {
    background: rgba(239, 68, 68, 0.2);
}

/* ── MAIN CONTENT ─────────────────────────────────────────── */
.main-content {
    flex: 1;
    margin-left: 260px;
    padding: 0;
    min-height: 100vh;
}

.page-header {
    padding: 28px 32px 20px;
    border-bottom: 1px solid var(--border);
    background: var(--bg-800);
    position: sticky;
    top: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.page-title {
    font-size: 1.4rem;
    font-weight: 700;
}

.page-subtitle {
    font-size: .85rem;
    color: var(--text-2);
    margin-top: 2px;
}

.page-body {
    padding: 28px 32px;
}

/* ── MOBILE TOPBAR ────────────────────────────────────────── */
.mobile-topbar {
    display: none;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    background: var(--bg-800);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 200;
}

.hamburger {
    background: none;
    border: none;
    color: var(--text-1);
    cursor: pointer;
    font-size: 1.4rem;
    padding: 4px;
}

.mobile-logo {
    font-family: 'Outfit', sans-serif;
    font-size: 1.3rem;
    font-weight: 800;
    background: var(--grad-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 99;
    backdrop-filter: blur(4px);
}

/* ── CARDS ────────────────────────────────────────────────── */
.card {
    background: var(--bg-800);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    transition: all .25s;
}

.card:hover {
    border-color: rgba(108, 99, 255, 0.3);
    box-shadow: var(--shadow);
}

.card-glass {
    background: var(--bg-glass);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
}

.stat-card {
    background: var(--bg-800);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 22px;
    position: relative;
    overflow: hidden;
    transition: all .25s;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
}

.stat-card.gold::before {
    background: var(--grad-gold);
}

.stat-card.purple::before {
    background: var(--grad-accent);
}

.stat-card.green::before {
    background: var(--grad-green);
}

.stat-card.blue::before {
    background: linear-gradient(135deg, #3b82f6, #60a5fa);
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow);
    border-color: rgba(108, 99, 255, 0.25);
}

.stat-icon {
    width: 46px;
    height: 46px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    margin-bottom: 14px;
}

.stat-icon.gold {
    background: rgba(245, 158, 11, 0.15);
}

.stat-icon.purple {
    background: rgba(108, 99, 255, 0.15);
}

.stat-icon.green {
    background: rgba(16, 185, 129, 0.15);
}

.stat-icon.blue {
    background: rgba(59, 130, 246, 0.15);
}

.stat-value {
    font-size: 1.85rem;
    font-weight: 800;
    font-family: 'Outfit', sans-serif;
}

.stat-label {
    font-size: .8rem;
    color: var(--text-2);
    margin-top: 4px;
}

.stat-change {
    font-size: .75rem;
    margin-top: 8px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.stat-change.up {
    color: var(--green);
}

.stat-change.down {
    color: var(--red);
}

.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

/* ── BUTTONS ──────────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: var(--radius-sm);
    font-size: .9rem;
    font-weight: 600;
    cursor: pointer;
    border: none;
    outline: none;
    transition: all .2s cubic-bezier(.4, 0, .2, 1);
    position: relative;
    overflow: hidden;
    white-space: nowrap;
}

.btn::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.08);
    opacity: 0;
    transition: opacity .2s;
}

.btn:hover::after {
    opacity: 1;
}

.btn:active {
    transform: scale(.97);
}

.btn:disabled {
    opacity: .5;
    cursor: not-allowed;
}

.btn:disabled::after {
    display: none;
}

.btn-primary {
    background: var(--grad-accent);
    color: #fff;
    box-shadow: 0 4px 20px rgba(108, 99, 255, 0.35);
}

.btn-primary:hover {
    box-shadow: 0 6px 30px rgba(108, 99, 255, 0.5);
    transform: translateY(-1px);
}

.btn-gold {
    background: var(--grad-gold);
    color: #1a1200;
    box-shadow: 0 4px 20px rgba(245, 158, 11, 0.35);
}

.btn-gold:hover {
    box-shadow: 0 6px 30px rgba(245, 158, 11, 0.5);
    transform: translateY(-1px);
}

.btn-green {
    background: var(--grad-green);
    color: #fff;
    box-shadow: 0 4px 20px rgba(16, 185, 129, 0.3);
}

.btn-green:hover {
    box-shadow: 0 6px 30px rgba(16, 185, 129, 0.45);
    transform: translateY(-1px);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-1);
}

.btn-outline:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.btn-danger {
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: var(--red);
}

.btn-danger:hover {
    background: rgba(239, 68, 68, 0.25);
}

.btn-sm {
    padding: 8px 16px;
    font-size: .8rem;
}

.btn-lg {
    padding: 16px 32px;
    font-size: 1rem;
}

.btn-full {
    width: 100%;
}

/* ── FORMS ────────────────────────────────────────────────── */
.form-group {
    margin-bottom: 18px;
}

.form-label {
    display: block;
    font-size: .85rem;
    font-weight: 500;
    color: var(--text-2);
    margin-bottom: 8px;
}

.form-input {
    width: 100%;
    padding: 13px 16px;
    background: var(--bg-700);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-1);
    font-size: .9rem;
    transition: all .2s;
    outline: none;
}

.form-input:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(108, 99, 255, 0.15);
}

.form-input::placeholder {
    color: var(--text-3);
}

.form-input-icon {
    position: relative;
}

.form-input-icon .form-input {
    padding-left: 44px;
}

.form-input-icon .input-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-3);
    font-size: 1rem;
    pointer-events: none;
}

.input-error {
    border-color: var(--red) !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1) !important;
}

.form-error {
    font-size: .78rem;
    color: var(--red);
    margin-top: 5px;
}

.form-hint {
    font-size: .78rem;
    color: var(--text-3);
    margin-top: 5px;
}

.form-select {
    width: 100%;
    padding: 13px 16px;
    background: var(--bg-700);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-1);
    font-size: .9rem;
    outline: none;
    appearance: none;
    cursor: pointer;
    transition: border-color .2s;
}

.form-select:focus {
    border-color: var(--accent);
}

/* ── BADGES / CHIPS ───────────────────────────────────────── */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 10px;
    border-radius: 99px;
    font-size: .72rem;
    font-weight: 600;
}

.badge-success {
    background: rgba(16, 185, 129, 0.15);
    color: var(--green);
    border: 1px solid rgba(16, 185, 129, 0.25);
}

.badge-warning {
    background: rgba(245, 158, 11, 0.15);
    color: var(--gold);
    border: 1px solid rgba(245, 158, 11, 0.25);
}

.badge-danger {
    background: rgba(239, 68, 68, 0.15);
    color: var(--red);
    border: 1px solid rgba(239, 68, 68, 0.25);
}

.badge-info {
    background: rgba(108, 99, 255, 0.15);
    color: var(--accent2);
    border: 1px solid rgba(108, 99, 255, 0.25);
}

/* ── TABLE ────────────────────────────────────────────────── */
.table-wrap {
    overflow-x: auto;
    border-radius: var(--radius);
    border: 1px solid var(--border);
}

table {
    width: 100%;
    border-collapse: collapse;
}

thead {
    background: var(--bg-700);
}

th {
    padding: 13px 18px;
    text-align: left;
    font-size: .78rem;
    font-weight: 600;
    color: var(--text-2);
    text-transform: uppercase;
    letter-spacing: .06em;
}

td {
    padding: 14px 18px;
    font-size: .85rem;
    border-top: 1px solid var(--border);
}

tr:hover td {
    background: rgba(255, 255, 255, 0.02);
}

/* ── TOAST ────────────────────────────────────────────────── */
.ae-toast {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: var(--bg-700);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 14px 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: .88rem;
    font-weight: 500;
    box-shadow: var(--shadow-lg);
    z-index: 9999;
    transform: translateY(100px);
    opacity: 0;
    transition: all .35s cubic-bezier(.4, 0, .2, 1);
    max-width: 360px;
}

.ae-toast-show {
    transform: translateY(0);
    opacity: 1;
}

.ae-toast-success {
    border-left: 3px solid var(--green);
}

.ae-toast-error {
    border-left: 3px solid var(--red);
}

.ae-toast-warning {
    border-left: 3px solid var(--gold);
}

.ae-toast-info {
    border-left: 3px solid var(--accent);
}

.toast-icon {
    font-size: 1.1rem;
}

/* ── LOADING OVERLAY ──────────────────────────────────────── */
#ae-loading-overlay {
    position: fixed;
    inset: 0;
    background: rgba(10, 12, 16, 0.85);
    backdrop-filter: blur(8px);
    z-index: 9998;
    display: none;
    align-items: center;
    justify-content: center;
}

.ae-loader-box {
    text-align: center;
}

.ae-spinner {
    width: 50px;
    height: 50px;
    border: 3px solid var(--border);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin .8s linear infinite;
    margin: 0 auto 14px;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.ae-loader-box p {
    color: var(--text-2);
    font-size: .9rem;
}

/* ── SECTION HEADER ───────────────────────────────────────── */
.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.section-title {
    font-size: 1.1rem;
    font-weight: 700;
}

.section-subtitle {
    font-size: .8rem;
    color: var(--text-2);
    margin-top: 2px;
}

/* ── ACTIVITY ITEM ────────────────────────────────────────── */
.activity-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 0;
    border-bottom: 1px solid var(--border);
}

.activity-item:last-child {
    border-bottom: none;
}

.activity-icon {
    width: 40px;
    height: 40px;
    flex-shrink: 0;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
}

.activity-icon.earn {
    background: rgba(16, 185, 129, 0.15);
}

.activity-icon.spend {
    background: rgba(239, 68, 68, 0.15);
}

.activity-icon.ref {
    background: rgba(108, 99, 255, 0.15);
}

.activity-icon.game {
    background: rgba(245, 158, 11, 0.15);
}

.activity-body {
    flex: 1;
}

.activity-desc {
    font-size: .88rem;
    font-weight: 500;
}

.activity-time {
    font-size: .75rem;
    color: var(--text-3);
    margin-top: 2px;
}

.activity-coins {
    font-size: .88rem;
    font-weight: 700;
}

.activity-coins.positive {
    color: var(--green);
}

.activity-coins.negative {
    color: var(--red);
}

/* ── GAMES ────────────────────────────────────────────────── */
.game-card {
    background: var(--bg-700);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    text-align: center;
    cursor: pointer;
    transition: all .25s;
    position: relative;
    overflow: hidden;
}

.game-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    opacity: 0;
    transition: opacity .25s;
}

.game-card.spin::before {
    background: radial-gradient(circle at top, rgba(108, 99, 255, 0.12) 0%, transparent 70%);
}

.game-card.scratch::before {
    background: radial-gradient(circle at top, rgba(245, 158, 11, 0.12) 0%, transparent 70%);
}

.game-card.quiz::before {
    background: radial-gradient(circle at top, rgba(16, 185, 129, 0.12) 0%, transparent 70%);
}

.game-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow);
    border-color: rgba(108, 99, 255, 0.4);
}

.game-card:hover::before {
    opacity: 1;
}

.game-emoji {
    font-size: 3rem;
    margin-bottom: 12px;
    display: block;
}

.game-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 6px;
}

.game-desc {
    font-size: .82rem;
    color: var(--text-2);
    margin-bottom: 16px;
}

.game-reward {
    font-size: .8rem;
    background: var(--bg-600);
    border-radius: 99px;
    padding: 4px 12px;
    display: inline-block;
    color: var(--gold);
    font-weight: 600;
}

/* ── SPIN WHEEL ───────────────────────────────────────────── */
.spin-wheel-container {
    position: relative;
    display: inline-block;
}

#spinCanvas {
    border-radius: 50%;
}

.spin-pointer {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 12px solid transparent;
    border-right: 12px solid transparent;
    border-top: 24px solid var(--gold);
    filter: drop-shadow(0 2px 8px rgba(245, 158, 11, 0.6));
}

/* ── SCRATCH CARD ─────────────────────────────────────────── */
.scratch-card-wrap {
    position: relative;
    width: 280px;
    height: 180px;
    border-radius: var(--radius);
    overflow: hidden;
    margin: 0 auto;
    cursor: crosshair;
    box-shadow: var(--shadow-lg);
}

.scratch-reveal {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, #1e293b, #0f172a);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.scratch-reveal .coins-text {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--gold);
}

.scratch-canvas {
    position: absolute;
    inset: 0;
}

/* ── QUIZ ─────────────────────────────────────────────────── */
.quiz-question {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 20px;
    line-height: 1.5;
}

.quiz-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.quiz-option {
    padding: 14px 16px;
    background: var(--bg-700);
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-size: .88rem;
    font-weight: 500;
    transition: all .2s;
    text-align: center;
}

.quiz-option:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: rgba(108, 99, 255, 0.05);
}

.quiz-option.correct {
    border-color: var(--green);
    background: rgba(16, 185, 129, 0.1);
    color: var(--green);
}

.quiz-option.wrong {
    border-color: var(--red);
    background: rgba(239, 68, 68, 0.1);
    color: var(--red);
}

.quiz-badge {
    font-size: .75rem;
    color: var(--text-3);
    margin-bottom: 8px;
}

/* ── LEADERBOARD ──────────────────────────────────────────── */
.lb-row {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 0;
    border-bottom: 1px solid var(--border);
}

.lb-row:last-child {
    border-bottom: none;
}

.lb-rank {
    width: 32px;
    text-align: center;
    font-weight: 700;
    font-size: .95rem;
    flex-shrink: 0;
}

.lb-rank.top1 {
    color: #ffd700;
    font-size: 1.2rem;
}

.lb-rank.top2 {
    color: #c0c0c0;
}

.lb-rank.top3 {
    color: #cd7f32;
}

.lb-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--grad-accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1rem;
    color: #fff;
    flex-shrink: 0;
}

.lb-info {
    flex: 1;
}

.lb-name {
    font-weight: 600;
    font-size: .9rem;
}

.lb-sub {
    font-size: .75rem;
    color: var(--text-3);
}

.lb-coins {
    font-weight: 800;
    color: var(--gold);
    font-size: 1rem;
}

/* ── WALLET ───────────────────────────────────────────────── */
.wallet-balance-card {
    background: var(--grad-accent);
    border-radius: var(--radius);
    padding: 32px;
    color: #fff;
    position: relative;
    overflow: hidden;
}

.wallet-balance-card::before {
    content: '';
    position: absolute;
    width: 200px;
    height: 200px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 50%;
    top: -60px;
    right: -60px;
}

.wallet-balance-card::after {
    content: '';
    position: absolute;
    width: 130px;
    height: 130px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 50%;
    bottom: -40px;
    left: 30px;
}

.wallet-label {
    font-size: .85rem;
    opacity: .8;
    margin-bottom: 12px;
}

.wallet-inr {
    font-size: 3rem;
    font-weight: 900;
    font-family: 'Outfit', sans-serif;
}

.wallet-coins {
    font-size: .9rem;
    opacity: .75;
    margin-top: 6px;
}

/* ── REFERRAL ─────────────────────────────────────────────── */
.referral-box {
    background: var(--bg-700);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 14px 18px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.referral-link-text {
    flex: 1;
    font-size: .88rem;
    color: var(--accent2);
    word-break: break-all;
}

/* ── MODAL ────────────────────────────────────────────────── */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-overlay.active {
    display: flex;
}

.modal {
    background: var(--bg-800);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 32px;
    max-width: 500px;
    width: 100%;
    position: relative;
    animation: modalIn .3s cubic-bezier(.4, 0, .2, 1);
}

@keyframes modalIn {
    from {
        opacity: 0;
        transform: scale(.9) translateY(20px);
    }

    to {
        opacity: 1;
        transform: none;
    }
}

.modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: var(--bg-700);
    border: 1px solid var(--border);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text-2);
    font-size: 1rem;
    transition: all .2s;
}

.modal-close:hover {
    color: var(--text-1);
    border-color: var(--accent);
}

.modal-title {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.modal-subtitle {
    font-size: .85rem;
    color: var(--text-2);
    margin-bottom: 24px;
}

/* ── TABS ─────────────────────────────────────────────────── */
.tab-bar {
    display: flex;
    gap: 4px;
    background: var(--bg-700);
    border-radius: 10px;
    padding: 4px;
    margin-bottom: 24px;
}

.tab-btn {
    flex: 1;
    padding: 10px 16px;
    border-radius: 8px;
    border: none;
    background: none;
    color: var(--text-2);
    font-size: .88rem;
    font-weight: 600;
    cursor: pointer;
    transition: all .2s;
}

.tab-btn.active {
    background: var(--grad-accent);
    color: #fff;
    box-shadow: 0 4px 15px rgba(108, 99, 255, 0.3);
}

/* ── PROGRESS BAR ─────────────────────────────────────────── */
.progress-wrap {
    height: 8px;
    background: var(--bg-700);
    border-radius: 99px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    border-radius: 99px;
    background: var(--grad-accent);
    transition: width .6s ease;
}

/* ── DAILY REWARD BUTTON ──────────────────────────────────── */
.daily-reward-btn {
    background: var(--grad-gold);
    border: none;
    border-radius: var(--radius);
    padding: 18px 24px;
    color: #1a1200;
    font-weight: 800;
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    transition: all .25s;
    box-shadow: 0 4px 24px rgba(245, 158, 11, 0.4);
    position: relative;
    overflow: hidden;
}

.daily-reward-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 36px rgba(245, 158, 11, 0.5);
}

.daily-reward-btn:disabled {
    background: var(--bg-700);
    color: var(--text-3);
    box-shadow: none;
    cursor: not-allowed;
    transform: none;
}

.daily-reward-btn .btn-emoji {
    font-size: 1.6rem;
}

.daily-reward-btn .btn-text {
    text-align: left;
}

.daily-reward-btn .btn-text small {
    display: block;
    font-size: .75rem;
    font-weight: 500;
    opacity: .75;
}

/* ── ADS WATCH CARD ───────────────────────────────────────── */
.ad-card {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.12), rgba(108, 99, 255, 0.08));
    border: 1px solid rgba(59, 130, 246, 0.25);
    border-radius: var(--radius);
    padding: 24px;
    text-align: center;
}

.ad-progress {
    font-size: 2rem;
    font-weight: 800;
    color: var(--blue);
}

.ad-limit {
    font-size: .82rem;
    color: var(--text-2);
    margin-top: 4px;
}

/* ── EMPTY STATE ──────────────────────────────────────────── */
.empty-state {
    text-align: center;
    padding: 48px 24px;
}

.empty-icon {
    font-size: 3rem;
    margin-bottom: 16px;
}

.empty-title {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.empty-desc {
    font-size: .85rem;
    color: var(--text-2);
}

/* ── UTILITY ──────────────────────────────────────────────── */
.mb-0 {
    margin-bottom: 0;
}

.mb-4 {
    margin-bottom: 4px;
}

.mb-8 {
    margin-bottom: 8px;
}

.mb-12 {
    margin-bottom: 12px;
}

.mb-16 {
    margin-bottom: 16px;
}

.mb-20 {
    margin-bottom: 20px;
}

.mb-24 {
    margin-bottom: 24px;
}

.mb-32 {
    margin-bottom: 32px;
}

.mt-4 {
    margin-top: 4px;
}

.mt-8 {
    margin-top: 8px;
}

.mt-12 {
    margin-top: 12px;
}

.mt-16 {
    margin-top: 16px;
}

.mt-20 {
    margin-top: 20px;
}

.mt-24 {
    margin-top: 24px;
}

.mt-32 {
    margin-top: 32px;
}

.text-center {
    text-align: center;
}

.text-right {
    text-align: right;
}

.text-muted {
    color: var(--text-2);
}

.text-sm {
    font-size: .82rem;
}

.text-xs {
    font-size: .73rem;
}

.text-gold {
    color: var(--gold);
}

.text-green {
    color: var(--green);
}

.text-red {
    color: var(--red);
}

.text-accent {
    color: var(--accent2);
}

.fw-600 {
    font-weight: 600;
}

.fw-700 {
    font-weight: 700;
}

.fw-800 {
    font-weight: 800;
}

.d-flex {
    display: flex;
}

.align-center {
    align-items: center;
}

.gap-8 {
    gap: 8px;
}

.gap-12 {
    gap: 12px;
}

.gap-16 {
    gap: 16px;
}

.w-100 {
    width: 100%;
}

/* ── AUTH PAGES ───────────────────────────────────────────── */
.auth-page {
    min-height: 100vh;
    display: flex;
    position: relative;
    overflow: hidden;
}

.auth-bg {
    position: fixed;
    inset: 0;
    background: var(--bg-900);
    z-index: 0;
}

.auth-bg::before {
    content: '';
    position: absolute;
    width: 600px;
    height: 600px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(108, 99, 255, 0.15) 0%, transparent 70%);
    top: -200px;
    left: -200px;
}

.auth-bg::after {
    content: '';
    position: absolute;
    width: 500px;
    height: 500px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(236, 72, 153, 0.12) 0%, transparent 70%);
    bottom: -150px;
    right: -150px;
}

.auth-left {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px;
    position: relative;
    z-index: 1;
}

.auth-right {
    width: 480px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px;
    background: rgba(16, 19, 26, 0.85);
    backdrop-filter: blur(20px);
    border-left: 1px solid var(--border);
    position: relative;
    z-index: 1;
}

.auth-card {
    width: 100%;
    max-width: 400px;
}

.auth-logo {
    font-family: 'Outfit', sans-serif;
    font-size: 2.2rem;
    font-weight: 900;
    background: var(--grad-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 6px;
}

.auth-tagline {
    font-size: .9rem;
    color: var(--text-2);
    margin-bottom: 36px;
}

.auth-title {
    font-size: 1.6rem;
    font-weight: 800;
    margin-bottom: 6px;
}

.auth-sub {
    font-size: .88rem;
    color: var(--text-2);
    margin-bottom: 28px;
}

.auth-divider {
    text-align: center;
    position: relative;
    margin: 20px 0;
}

.auth-divider::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    width: 100%;
    height: 1px;
    background: var(--border);
}

.auth-divider span {
    background: var(--bg-800);
    /* same as auth-right bg */
    padding: 0 12px;
    position: relative;
    font-size: .8rem;
    color: var(--text-3);
}

.auth-link {
    font-size: .88rem;
    color: var(--text-2);
    text-align: center;
    margin-top: 20px;
}

.auth-link a {
    color: var(--accent2);
    font-weight: 600;
}

.auth-link a:hover {
    text-decoration: underline;
}

.hero-feature {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 20px;
}

.hero-feature-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: var(--bg-700);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    flex-shrink: 0;
}

.hero-feature-text h4 {
    font-size: .95rem;
    font-weight: 600;
}

.hero-feature-text p {
    font-size: .8rem;
    color: var(--text-2);
}

/* ── LANDING PAGE ─────────────────────────────────────────── */
.nav-bar {
    padding: 16px 0;
    border-bottom: 1px solid var(--border);
    background: rgba(10, 12, 16, 0.95);
    backdrop-filter: blur(20px);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-logo {
    font-family: 'Outfit', sans-serif;
    font-size: 1.6rem;
    font-weight: 900;
    background: var(--grad-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 24px;
}

.nav-links a {
    font-size: .88rem;
    color: var(--text-2);
    transition: color .2s;
}

.nav-links a:hover {
    color: var(--text-1);
}

.nav-cta {
    display: flex;
    align-items: center;
    gap: 12px;
}

.hero-section {
    padding: 100px 0 80px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    width: 800px;
    height: 800px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(108, 99, 255, 0.12) 0%, transparent 65%);
    top: -200px;
    left: 50%;
    transform: translateX(-50%);
    pointer-events: none;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(108, 99, 255, 0.12);
    border: 1px solid rgba(108, 99, 255, 0.25);
    border-radius: 99px;
    padding: 8px 18px;
    font-size: .82rem;
    font-weight: 600;
    color: var(--accent2);
    margin-bottom: 28px;
    animation: fadeInDown .6s ease;
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-title {
    margin-bottom: 20px;
    animation: fadeInDown .7s ease;
}

.hero-title .gradient-text {
    background: var(--grad-hero);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-desc {
    font-size: 1.1rem;
    color: var(--text-2);
    max-width: 560px;
    margin: 0 auto 36px;
    animation: fadeInUp .7s ease .1s both;
}

.hero-cta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    flex-wrap: wrap;
    animation: fadeInUp .7s ease .2s both;
}

.stats-bar {
    display: flex;
    justify-content: center;
    gap: 48px;
    flex-wrap: wrap;
    padding: 40px 0;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.stats-bar-item {
    text-align: center;
}

.stats-bar-value {
    font-size: 2rem;
    font-weight: 800;
    font-family: 'Outfit', sans-serif;
    background: var(--grad-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.stats-bar-label {
    font-size: .8rem;
    color: var(--text-2);
    margin-top: 4px;
}

.features-section {
    padding: 80px 0;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-top: 48px;
}

.feature-card {
    background: var(--bg-800);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px;
    text-align: center;
    transition: all .25s;
}

.feature-card:hover {
    transform: translateY(-6px);
    border-color: rgba(108, 99, 255, 0.3);
    box-shadow: var(--shadow);
}

.feature-icon {
    font-size: 2.5rem;
    margin-bottom: 16px;
}

.feature-title {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.feature-desc {
    font-size: .83rem;
    color: var(--text-2);
}

.how-section {
    padding: 80px 0;
    background: var(--bg-800);
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
    margin-top: 48px;
}

.step-card {
    text-align: center;
    padding: 24px 16px;
}

.step-number {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--grad-accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    font-weight: 800;
    color: #fff;
    margin: 0 auto 16px;
    box-shadow: 0 4px 20px rgba(108, 99, 255, 0.4);
}

.step-title {
    font-size: .95rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.step-desc {
    font-size: .82rem;
    color: var(--text-2);
}

.cta-section {
    padding: 80px 0;
    text-align: center;
    background: linear-gradient(135deg, rgba(108, 99, 255, 0.08), rgba(236, 72, 153, 0.06));
}

.footer {
    background: var(--bg-800);
    border-top: 1px solid var(--border);
    padding: 40px 0 24px;
}

.footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-logo {
    font-family: 'Outfit', sans-serif;
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--text-2);
}

.footer-links {
    display: flex;
    gap: 24px;
}

.footer-links a {
    font-size: .82rem;
    color: var(--text-3);
    transition: color .2s;
}

.footer-links a:hover {
    color: var(--text-1);
}

.footer-copy {
    font-size: .78rem;
    color: var(--text-3);
    text-align: center;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
}

/* ── ADMIN-SPECIFIC ───────────────────────────────────────── */
.admin-sidebar .sidebar-logo .logo-text {
    color: var(--gold);
    -webkit-text-fill-color: var(--gold);
    background: none;
}

.admin-tag {
    font-size: .65rem;
    background: var(--gold);
    color: #1a1200;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: 700;
    margin-left: 6px;
}

.action-btns {
    display: flex;
    gap: 8px;
}

/* ── PULSE ANIMATION ──────────────────────────────────────── */
.pulse {
    animation: pulse 2s ease infinite;
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.03);
    }
}

/* ── SHIMMER LOADING ──────────────────────────────────────── */
.shimmer {
    background: linear-gradient(90deg, var(--bg-700) 25%, var(--bg-600) 50%, var(--bg-700) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 8px;
}

@keyframes shimmer {
    from {
        background-position: 200% 0;
    }

    to {
        background-position: -200% 0;
    }
}

/* ── RESPONSIVE ───────────────────────────────────────────── */
@media (max-width: 1024px) {
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }

    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .steps-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .auth-left {
        display: none;
    }

    .auth-right {
        width: 100%;
        border-left: none;
    }
}

@media (max-width: 768px) {

    /* Sidebar */
    .sidebar {
        transform: translateX(-100%);
        z-index: 101;
    }

    .sidebar.open {
        transform: translateX(0);
    }

    .sidebar-overlay.active {
        display: block;
    }

    /* Topbar */
    .mobile-topbar {
        display: flex;
    }

    .main-content {
        margin-left: 0;
    }

    .page-header {
        padding: 20px;
        display: none;
    }

    .page-body {
        padding: 16px 14px;
        padding-bottom: 90px;
    }

    /* room for bottom nav */

    /* Grids */
    .grid-3,
    .grid-2 {
        grid-template-columns: 1fr;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .steps-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Misc */
    .stats-bar {
        gap: 24px;
    }

    .nav-links {
        display: none;
    }

    .footer-inner {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }

    .quiz-options {
        grid-template-columns: 1fr;
    }

    .wallet-balance-card {
        padding: 20px;
    }

    .wallet-inr {
        font-size: 2rem;
    }

    .stat-card {
        padding: 16px;
    }

    .stat-value {
        font-size: 1.5rem;
    }

    .stat-icon {
        width: 38px;
        height: 38px;
        font-size: 1.1rem;
        margin-bottom: 10px;
    }

    /* Auth pages — full screen form */
    .auth-right {
        padding: 32px 20px;
        min-height: 100vh;
        justify-content: flex-start;
        padding-top: 48px;
    }

    .auth-title {
        font-size: 1.4rem;
    }

    /* Tables — horizontal scroll */
    .table-wrap {
        border-radius: var(--radius-sm);
    }

    th,
    td {
        padding: 10px 12px;
        font-size: .78rem;
    }

    /* Toasts above bottom nav */
    .ae-toast {
        bottom: 80px;
        right: 12px;
        left: 12px;
        max-width: none;
    }

    /* Modal */
    .modal {
        padding: 24px 18px;
        margin: 12px;
    }

    .modal-overlay {
        padding: 12px;
        align-items: flex-end;
    }

    .modal {
        border-radius: 20px 20px 16px 16px;
        animation: modalSlideUp .3s ease;
    }

    @keyframes modalSlideUp {
        from {
            transform: translateY(100%);
        }

        to {
            transform: translateY(0);
        }
    }

    /* Tab bar */
    .tab-btn {
        padding: 9px 10px;
        font-size: .78rem;
    }

    /* Cards */
    .card {
        padding: 16px;
    }

    .section-title {
        font-size: 1rem;
    }

    /* Daily reward button */
    .daily-reward-btn {
        padding: 14px 18px;
    }

    .daily-reward-btn .btn-emoji {
        font-size: 1.3rem;
    }

    /* Landing sections */
    .hero-section {
        padding: 60px 0 40px;
    }

    .features-section {
        padding: 52px 0;
    }

    .how-section {
        padding: 52px 0;
    }

    .cta-section {
        padding: 52px 0;
    }

    /* Referral box */
    .referral-box {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .referral-box .btn {
        width: 100%;
    }

    /* Top3 podium on leaderboard */
    .top3-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .top3-card {
        padding: 18px 12px;
    }

    /* Scratch card */
    .scratch-wrap,
    canvas#scratchCanvas {
        width: 100% !important;
        max-width: 320px;
    }

    /* Spin wheel */
    #spinCanvas {
        width: 240px !important;
        height: 240px !important;
    }

    /* Games grid */
    .game-card {
        padding: 18px;
    }

    .game-emoji {
        font-size: 2.2rem;
    }

    /* Profile card */
    #profileAvatar {
        width: 60px;
        height: 60px;
        font-size: 1.4rem;
    }
}

@media (max-width: 480px) {
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }

    .steps-grid {
        grid-template-columns: 1fr;
    }

    .card {
        padding: 14px;
        border-radius: var(--radius-sm);
    }

    .page-body {
        padding: 12px;
        padding-bottom: 90px;
    }

    .stat-value {
        font-size: 1.3rem;
    }

    .btn-lg {
        padding: 14px 20px;
        font-size: .95rem;
    }

    .auth-right {
        padding: 24px 16px;
        padding-top: 40px;
    }

    .hero-cta {
        flex-direction: column;
        gap: 10px;
    }

    .hero-cta .btn {
        width: 100%;
        max-width: 280px;
    }

    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
}

/* ── BOTTOM NAV BAR (Mobile App Feel) ───────────────────────── */
.bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--bg-800);
    border-top: 1px solid var(--border);
    z-index: 150;
    padding: 8px 0 env(safe-area-inset-bottom, 8px);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.bottom-nav-inner {
    display: flex;
    justify-content: space-around;
    align-items: center;
}

.bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    padding: 6px 12px;
    border-radius: 12px;
    text-decoration: none;
    color: var(--text-3);
    font-size: .62rem;
    font-weight: 600;
    transition: all .2s;
    min-width: 56px;
    cursor: pointer;
    border: none;
    background: none;
}

.bottom-nav-item .bn-icon {
    font-size: 1.3rem;
    line-height: 1;
    transition: transform .2s;
}

.bottom-nav-item.active {
    color: var(--accent2);
    background: rgba(108, 99, 255, 0.12);
}

.bottom-nav-item.active .bn-icon {
    transform: scale(1.15);
}

.bottom-nav-item:hover {
    color: var(--text-1);
}

/* Show bottom nav on mobile */
@media (max-width: 768px) {
    .bottom-nav {
        display: block;
    }

    /* Remove redundant left menu icons when bottom nav active */
    .main-content {
        padding-bottom: 0;
    }
}

/* ── MOBILE COIN TICKER (top bar) ───────────────────────────── */
.mobile-coin-badge {
    background: rgba(245, 158, 11, 0.15);
    border: 1px solid rgba(245, 158, 11, 0.3);
    border-radius: 99px;
    padding: 4px 10px;
    font-size: .75rem;
    font-weight: 700;
    color: var(--gold);
    display: flex;
    align-items: center;
    gap: 4px;
}

/* ── TOUCH IMPROVEMENTS ─────────────────────────────────────── */
@media (hover: none) and (pointer: coarse) {

    /* Larger tap targets */
    .nav-item {
        padding: 13px 14px;
    }

    .btn {
        min-height: 44px;
    }

    .btn-sm {
        min-height: 36px;
    }

    .form-input {
        font-size: 16px;
    }

    /* Prevent iOS zoom on focus */
    .form-select {
        font-size: 16px;
    }

    .quiz-option {
        padding: 16px;
        min-height: 52px;
    }

    .activity-item {
        padding: 16px 0;
    }

    .bottom-nav-item {
        padding: 8px 12px;
        min-height: 54px;
    }

    /* Remove hover effects that feel wrong on touch */
    .stat-card:hover {
        transform: none;
    }

    .game-card:hover {
        transform: none;
    }

    .btn-primary:hover {
        transform: none;
    }

    .btn-gold:hover {
        transform: none;
    }

    .btn-green:hover {
        transform: none;
    }
}

/* ── LANDSCAPE MOBILE ───────────────────────────────────────── */
@media (max-width: 768px) and (orientation: landscape) {
    .auth-right {
        padding-top: 24px;
        min-height: auto;
    }

    .page-body {
        padding-bottom: 80px;
    }

    .bottom-nav {
        padding: 4px 0;
    }

    .bottom-nav-item {
        padding: 4px 12px;
    }

    .bottom-nav-item .bn-icon {
        font-size: 1.1rem;
    }
}

/* ── PWA / NOTCH SAFE ZONES ─────────────────────────────────── */
@supports (padding-bottom: env(safe-area-inset-bottom)) {
    .bottom-nav {
        padding-bottom: calc(8px + env(safe-area-inset-bottom));
    }

    @media (max-width: 768px) {
        .page-body {
            padding-bottom: calc(70px + env(safe-area-inset-bottom));
        }
    }
}