:root {
    --bg-black: #000000;
    --bg-surface-1: #09090b;
    --bg-surface-2: #121215;
    --bg-surface-3: #18181c;
    --bg-surface-hover: #222228;
    
    --border-hairline: #1f1f24;
    --border-active: #3a3a44;
    --border-strong: #ffffff;
    
    --text-white: #ffffff;
    --text-sub: #a1a1aa;
    --text-muted: #52525b;
    --text-dark: #27272a;
    
    --emerald-win: #10b981;
    --emerald-bg: rgba(16, 185, 129, 0.08);
    --crimson-loss: #ef4444;
    --crimson-bg: rgba(239, 68, 68, 0.08);
    
    --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --font-mono: "SF Mono", Monaco, "Cascadia Code", "JetBrains Mono", Consolas, monospace;
    
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    -webkit-tap-highlight-color: transparent;
}

body {
    background-color: var(--bg-black);
    color: var(--text-white);
    font-family: var(--font-sans);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 16px;
    letter-spacing: -0.01em;
}

/* App Container - Engineered for TMA and Web */
.app-viewport {
    width: 100%;
    max-width: 500px;
    background-color: var(--bg-surface-1);
    border: 1px solid var(--border-hairline);
    border-radius: var(--radius-lg);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.9);
}

/* Header */
.app-header {
    background: var(--bg-surface-1);
    border-bottom: 1px solid var(--border-hairline);
    padding: 12px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.brand-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
}

.brand-logo-badge {
    background: #ffffff;
    color: #000000;
    font-weight: 900;
    font-size: 14px;
    width: 28px;
    height: 28px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    letter-spacing: -0.5px;
}

.brand-name {
    font-size: 16px;
    font-weight: 800;
    color: var(--text-white);
    letter-spacing: -0.5px;
}

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

/* Currency Picker Dropdown Button */
.currency-selector-btn {
    background: var(--bg-surface-2);
    border: 1px solid var(--border-hairline);
    border-radius: var(--radius-md);
    padding: 5px 8px;
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    transition: all 0.15s ease;
    color: var(--text-white);
}

.currency-selector-btn:hover {
    border-color: var(--border-active);
    background: var(--bg-surface-3);
}

.coin-icon {
    font-size: 12px;
    font-weight: 700;
    color: #ffffff;
    background: var(--bg-surface-3);
    border: 1px solid var(--border-hairline);
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.coin-balance-display {
    font-family: var(--font-mono);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: -0.3px;
}

.coin-symbol-label {
    font-size: 10px;
    font-weight: 700;
    color: var(--text-sub);
}

.btn-icon-pure {
    background: var(--bg-surface-2);
    border: 1px solid var(--border-hairline);
    border-radius: var(--radius-md);
    color: var(--text-sub);
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 13px;
    transition: all 0.15s ease;
}

.btn-icon-pure:hover {
    color: var(--text-white);
    border-color: var(--border-active);
}

.brand-title-badge {
    font-size: 13px;
    font-weight: 900;
    letter-spacing: 1.5px;
    color: #ffffff;
    background: linear-gradient(90deg, #ffffff, #a1a1aa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* 2-Row Navigation Container */
.app-nav-wrapper {
    display: flex;
    flex-direction: column;
    border-bottom: 1px solid var(--border-hairline);
    background: #000000;
}

.nav-subrow {
    display: flex;
    align-items: center;
}

/* Row 1: Casino Games */
.nav-games-row {
    background: rgba(255, 255, 255, 0.02);
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

/* Row 2: Utilities */
.nav-util-row {
    background: #000000;
}

.nav-btn-pill {
    flex: 1;
    background: transparent;
    border: none;
    padding: 8px 4px;
    font-size: 11px;
    font-weight: 700;
    color: #71717a;
    cursor: pointer;
    transition: all 0.15s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    position: relative;
    border-bottom: 2px solid transparent;
}

.nav-btn-pill:hover {
    color: #d4d4d8;
    background: rgba(255, 255, 255, 0.03);
}

.nav-btn-pill.active {
    color: #ffffff;
    border-bottom-color: #ffffff;
    background: rgba(255, 255, 255, 0.04);
}

.nav-games-row .nav-btn-pill.active {
    border-bottom-color: #3b82f6;
    color: #ffffff;
}

.nav-live-dot {
    width: 6px;
    height: 6px;
    background: #10b981;
    border-radius: 50%;
    box-shadow: 0 0 6px #10b981;
    display: inline-block;
}

.badge-mini-soon {
    font-size: 8px;
    font-weight: 800;
    color: #fbbf24;
    background: rgba(245, 158, 11, 0.15);
    border: 1px solid rgba(245, 158, 11, 0.3);
    padding: 1px 4px;
    border-radius: 3px;
    line-height: 1;
    letter-spacing: 0.3px;
}

/* Fallback for legacy class queries */
.app-tabs {
    display: flex;
    border-bottom: 1px solid var(--border-hairline);
    background: var(--bg-black);
}

.tab-item {
    flex: 1;
    background: transparent;
    border: none;
    padding: 10px 4px;
    font-size: 11px;
    font-weight: 700;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.15s ease;
    border-bottom: 2px solid transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

/* Game Suite Dropdown & Badges */
.game-suite-btn {
    background: #18181c;
    border: 1px solid #27272a;
    color: #ffffff;
    font-size: 11px;
    font-weight: 800;
    padding: 5px 8px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    transition: all 0.15s ease;
}
.game-suite-btn:hover {
    border-color: #3b82f6;
}
.game-suite-menu {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    width: 190px;
    background: #09090b;
    border: 1px solid #27272a;
    border-radius: var(--radius-md);
    box-shadow: 0 10px 30px rgba(0,0,0,0.85);
    z-index: 1000;
    padding: 6px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.game-suite-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 10px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 700;
    color: #a1a1aa;
    cursor: pointer;
    transition: all 0.15s;
}
.game-suite-item:hover, .game-suite-item.active {
    background: #18181c;
    color: #ffffff;
}
.game-badge-live {
    font-size: 9px;
    font-weight: 800;
    color: #10b981;
    background: rgba(16, 185, 129, 0.15);
    padding: 2px 6px;
    border-radius: 4px;
}
.game-badge-soon {
    font-size: 9px;
    font-weight: 800;
    color: #60a5fa;
    background: rgba(59, 130, 246, 0.15);
    padding: 2px 6px;
    border-radius: 4px;
}

/* Bet Mode Switcher Bar (Inside Dice) */
.bet-mode-bar {
    display: flex;
    background: #09090b;
    border: 1px solid #1f1f24;
    border-radius: var(--radius-md);
    padding: 4px;
    margin: 10px 14px 4px 14px;
    gap: 4px;
}
.mode-pill {
    flex: 1;
    background: transparent;
    border: none;
    color: #71717a;
    font-size: 11px;
    font-weight: 800;
    padding: 8px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.15s ease;
    text-align: center;
}
.mode-pill.active {
    background: #18181c;
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.4);
    border: 1px solid #27272a;
}
    border: none;
    border-bottom: 2px solid transparent;
    color: var(--text-muted);
    font-size: 12px;
    font-weight: 700;
    padding: 10px 0;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.15s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.tab-item:hover {
    color: var(--text-sub);
}

.tab-item.active {
    color: var(--text-white);
    border-bottom-color: var(--text-white);
    background: rgba(255, 255, 255, 0.02);
}

/* Arena / Big Display */
.dice-arena {
    padding: 22px 18px;
    background: var(--bg-black);
    display: flex;
    flex-direction: column;
    align-items: center;
    border-bottom: 1px solid var(--border-hairline);
}

.roll-value-box {
    width: 100%;
    max-width: 320px;
    height: 96px;
    background: var(--bg-surface-1);
    border: 1px solid var(--border-hairline);
    border-radius: var(--radius-md);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
    transition: border-color 0.2s ease;
}

.roll-value-box.win {
    border-color: var(--emerald-win);
    background: var(--emerald-bg);
}

.roll-value-box.loss {
    border-color: var(--crimson-loss);
    background: var(--crimson-bg);
}

.roll-number-text {
    font-family: var(--font-mono);
    font-size: 56px;
    font-weight: 800;
    line-height: 1;
    color: var(--text-white);
    letter-spacing: -1.5px;
}

.win .roll-number-text {
    color: var(--emerald-win);
}

.loss .roll-number-text {
    color: var(--crimson-loss);
}

.roll-state-badge {
    position: absolute;
    bottom: -11px;
    background: var(--bg-surface-2);
    border: 1px solid var(--border-hairline);
    padding: 2px 10px;
    border-radius: var(--radius-sm);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: var(--text-sub);
}

.win .roll-state-badge {
    background: var(--emerald-win);
    color: #000000;
    border-color: var(--emerald-win);
}

.loss .roll-state-badge {
    background: var(--crimson-loss);
    color: #ffffff;
    border-color: var(--crimson-loss);
}

/* Slider Component */
.slider-shell {
    width: 100%;
    margin-top: 24px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.slider-track {
    position: relative;
    width: 100%;
    height: 10px;
    background: var(--bg-surface-3);
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.slider-fill-zone {
    position: absolute;
    top: 0;
    height: 100%;
    background: #3f3f46;
    transition: all 0.08s ease;
}

.slider-fill-zone.active-zone {
    background: var(--emerald-win);
}

.dice-range-input {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 10px;
    opacity: 0;
    cursor: pointer;
    z-index: 10;
}

.slider-ticks {
    display: flex;
    justify-content: space-between;
    font-family: var(--font-mono);
    font-size: 11px;
    color: var(--text-muted);
}

/* Key Metrics Cards */
.metrics-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 8px;
    width: 100%;
    margin-top: 18px;
}

.metric-cell {
    background: var(--bg-surface-1);
    border: 1px solid var(--border-hairline);
    border-radius: var(--radius-sm);
    padding: 10px 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
    transition: all 0.15s ease;
}

.metric-cell:hover {
    border-color: var(--border-active);
}

.metric-cell.clickable {
    cursor: pointer;
}

.metric-cell.clickable:hover {
    background: var(--bg-surface-2);
}

.cell-title {
    font-size: 10px;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.cell-value {
    font-family: var(--font-mono);
    font-size: 15px;
    font-weight: 800;
    color: var(--text-white);
    margin-top: 2px;
}

/* Betting Panel */
.bet-panel {
    padding: 16px;
    background: var(--bg-surface-1);
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.input-block-header {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    font-weight: 700;
    color: var(--text-sub);
    text-transform: uppercase;
}

.bet-input-container {
    display: flex;
    background: var(--bg-black);
    border: 1px solid var(--border-hairline);
    border-radius: var(--radius-sm);
    overflow: hidden;
    transition: border-color 0.15s;
}

.bet-input-container:focus-within {
    border-color: var(--text-white);
}

.bet-amount-input {
    flex: 1;
    background: transparent;
    border: none;
    padding: 12px 14px;
    color: #ffffff;
    font-family: var(--font-mono);
    font-size: 16px;
    font-weight: 700;
    outline: none;
}

.quick-modifiers {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 4px 6px;
}

.btn-modifier {
    background: var(--bg-surface-2);
    border: 1px solid var(--border-hairline);
    color: var(--text-sub);
    font-size: 11px;
    font-weight: 700;
    padding: 6px 9px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.15s;
}

.btn-modifier:hover {
    color: #ffffff;
    border-color: var(--border-active);
    background: var(--bg-surface-3);
}

/* Master Action Button */
.btn-action-roll {
    width: 100%;
    background: #ffffff;
    color: #000000;
    border: none;
    border-radius: var(--radius-sm);
    padding: 15px;
    font-size: 15px;
    font-weight: 900;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.15s ease;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
}

.btn-action-roll:hover {
    background: #e4e4e7;
    transform: translateY(-1px);
}

.btn-action-roll:active {
    transform: translateY(1px);
}

.btn-action-roll.running-bot {
    background: var(--crimson-loss);
    color: #ffffff;
}

/* Bot Configuration Card */
.bot-config-card {
    display: none;
    flex-direction: column;
    gap: 10px;
    background: var(--bg-black);
    border: 1px solid var(--border-hairline);
    border-radius: var(--radius-sm);
    padding: 14px;
}

.bot-config-card.active {
    display: flex;
}

.bot-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}

.bot-label {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-sub);
}

.bot-select, .bot-input {
    background: var(--bg-surface-2);
    border: 1px solid var(--border-hairline);
    border-radius: var(--radius-sm);
    color: #ffffff;
    padding: 6px 10px;
    font-size: 12px;
    font-family: var(--font-mono);
    outline: none;
}

.bot-input {
    width: 90px;
    text-align: right;
}

/* Viewport Tab Views (Dice View vs Chat View vs Wallet View) */
.view-panel {
    display: none;
}
.view-panel.active {
    display: block;
}

/* Community Chat Room */
.chat-room-container {
    display: flex;
    flex-direction: column;
    min-height: 520px;
    height: 560px;
    background: var(--bg-black);
    border-bottom: 1px solid var(--border-hairline);
}

.chat-message-list {
    flex: 1;
    overflow-y: auto;
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-height: 420px;
}

.chat-msg-row {
    display: flex;
    flex-direction: column;
    background: var(--bg-surface-1);
    border: 1px solid var(--border-hairline);
    border-radius: var(--radius-sm);
    padding: 8px 10px;
    font-size: 12px;
    transition: all 0.15s ease;
}

.chat-msg-row.mentioned {
    border-left: 3px solid #00f0ff !important;
    background: rgba(0, 240, 255, 0.06) !important;
}

.chat-msg-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 3px;
}

.chat-msg-sender {
    font-weight: 800;
    color: #ffffff;
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    transition: color 0.15s ease;
}

.chat-msg-sender:hover {
    color: #60a5fa;
    text-decoration: underline;
}

.chat-mention {
    display: inline-block;
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
    border: 1px solid rgba(59, 130, 246, 0.4);
    border-radius: 4px;
    padding: 1px 6px;
    font-weight: 700;
    font-size: 11px;
    cursor: pointer;
    margin: 0 2px;
    transition: all 0.15s ease;
}

.chat-mention:hover {
    background: rgba(59, 130, 246, 0.4);
    color: #93c5fd;
    border-color: #60a5fa;
}

.chat-badge {
    font-size: 9px;
    font-weight: 800;
    padding: 1px 4px;
    border-radius: 2px;
    background: var(--bg-surface-3);
    color: var(--text-sub);
}

.chat-badge.SYSTEM {
    background: #3b82f6;
    color: #ffffff;
}
.chat-badge.VIP {
    background: #eab308;
    color: #000000;
}
.chat-badge.PRO {
    background: var(--emerald-win);
    color: #000000;
}

.chat-msg-time {
    font-size: 10px;
    font-family: var(--font-mono);
    color: var(--text-muted);
}

.chat-msg-body {
    color: var(--text-sub);
    line-height: 1.4;
    word-break: break-word;
}

.chat-input-bar {
    display: flex;
    padding: 10px 14px;
    background: var(--bg-surface-1);
    border-top: 1px solid var(--border-hairline);
    gap: 8px;
}

.chat-input-field {
    flex: 1;
    background: var(--bg-black);
    border: 1px solid var(--border-hairline);
    border-radius: var(--radius-sm);
    padding: 8px 12px;
    color: #ffffff;
    font-size: 13px;
    outline: none;
}

.btn-chat-send {
    background: #ffffff;
    color: #000000;
    border: none;
    border-radius: var(--radius-sm);
    width: 42px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.15s ease;
    flex-shrink: 0;
}

.btn-chat-send:hover {
    background: #e4e4e7;
    transform: scale(1.05);
}

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

/* Wallet & Deposit View */
.wallet-view-container {
    padding: 18px;
    background: var(--bg-black);
    display: flex;
    flex-direction: column;
    gap: 16px;
    border-bottom: 1px solid var(--border-hairline);
}

.wallet-card-highlight {
    background: var(--bg-surface-1);
    border: 1px solid var(--border-hairline);
    border-radius: var(--radius-md);
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.deposit-address-box {
    background: var(--bg-black);
    border: 1px solid var(--border-hairline);
    border-radius: var(--radius-sm);
    padding: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: var(--font-mono);
    font-size: 12px;
    color: #ffffff;
    word-break: break-all;
    gap: 10px;
}

.btn-copy-address {
    background: var(--bg-surface-2);
    border: 1px solid var(--border-hairline);
    color: var(--text-sub);
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    font-size: 10px;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
}

.btn-copy-address:hover {
    color: #ffffff;
    border-color: var(--border-active);
}

/* Live Bets Table */
.bets-history-block {
    background: var(--bg-surface-1);
    border-top: 1px solid var(--border-hairline);
    padding: 16px 18px;
}

.bets-history-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.bets-history-title {
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
}

.bets-feed {
    display: flex;
    flex-direction: column;
    gap: 4px;
    max-height: 190px;
    overflow-y: auto;
}

.feed-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 10px;
    background: var(--bg-black);
    border: 1px solid var(--border-hairline);
    border-radius: var(--radius-sm);
    font-family: var(--font-mono);
    font-size: 12px;
    border-left: 3px solid var(--border-hairline);
}

.feed-row.win {
    border-left-color: var(--emerald-win);
}

.feed-row.loss {
    border-left-color: var(--crimson-loss);
}

.feed-profit.win {
    color: var(--emerald-win);
    font-weight: 700;
}

.feed-profit.loss {
    color: var(--crimson-loss);
    font-weight: 700;
}

.badge-mode-pill {
    font-size: 8px;
    font-weight: 800;
    padding: 1px 5px;
    border-radius: 3px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    display: inline-block;
    line-height: 1.2;
}
.badge-mode-pill.manual {
    background: rgba(0, 240, 255, 0.12);
    color: #00f0ff;
    border: 1px solid rgba(0, 240, 255, 0.35);
}
.badge-mode-pill.auto {
    background: rgba(245, 158, 11, 0.12);
    color: #f59e0b;
    border: 1px solid rgba(245, 158, 11, 0.35);
}

/* Replaced "Audit" with "Verify" */
.btn-verify-chip {
    background: var(--bg-surface-2);
    border: 1px solid var(--border-hairline);
    color: var(--text-sub);
    font-size: 10px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    transition: all 0.15s;
}

.btn-verify-chip:hover {
    color: #ffffff;
    border-color: var(--border-active);
    background: var(--bg-surface-3);
}

/* Footer Links & Status */
.app-footer {
    padding: 14px 18px;
    background: var(--bg-surface-1);
    border-top: 1px solid var(--border-hairline);
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11px;
    color: var(--text-muted);
}

.footer-nav-links {
    display: flex;
    gap: 12px;
}

.footer-link-btn {
    background: transparent;
    border: none;
    color: var(--text-sub);
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 4px;
    transition: color 0.15s;
}

.footer-link-btn:hover {
    color: #ffffff;
}

/* Modals */
.modal-backdrop {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.85);
    z-index: 999;
    justify-content: center;
    align-items: center;
    padding: 16px;
}

.modal-backdrop.open {
    display: flex;
}

.modal-window {
    width: 100%;
    max-width: 440px;
    background: var(--bg-surface-1);
    border: 1px solid var(--border-active);
    border-radius: var(--radius-md);
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-title {
    font-size: 15px;
    font-weight: 800;
    color: #ffffff;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.modal-close-btn {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 20px;
    cursor: pointer;
}

.modal-close-btn:hover {
    color: #ffffff;
}

.modal-item-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.modal-field-title {
    font-size: 11px;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
}

.modal-input-styled {
    background: var(--bg-black);
    border: 1px solid var(--border-hairline);
    border-radius: var(--radius-sm);
    padding: 10px 12px;
    color: #ffffff;
    font-family: var(--font-mono);
    font-size: 12px;
    outline: none;
    word-break: break-all;
}

.modal-input-styled:focus {
    border-color: var(--text-white);
}

.modal-btn-confirm {
    background: #ffffff;
    color: #000000;
    border: none;
    border-radius: var(--radius-sm);
    padding: 12px;
    font-size: 13px;
    font-weight: 800;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.15s;
}

.modal-btn-confirm:hover {
    background: #e4e4e7;
}

/* Currency Grid */
.currency-grid-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    max-height: 240px;
    overflow-y: auto;
}

.currency-option-card {
    background: var(--bg-black);
    border: 1px solid var(--border-hairline);
    border-radius: var(--radius-sm);
    padding: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: all 0.15s;
}

.currency-option-card:hover {
    border-color: var(--border-active);
    background: var(--bg-surface-2);
}

.currency-option-card.selected {
    border-color: #ffffff;
}

/* Emoji Reaction Chips in Chat */
.btn-emoji-chip {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    padding: 3px 6px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.15s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.btn-emoji-chip:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

/* Mobile Responsive Optimization (< 520px Universal Screen Support) */
@media (max-width: 520px) {
    body {
        padding: 0;
        align-items: stretch;
    }

    .app-viewport {
        border-radius: 0;
        border-left: none;
        border-right: none;
        border-top: none;
        max-width: 100vw;
        min-height: 100vh;
        box-shadow: none;
    }

    .app-header {
        padding: 10px 12px;
    }

    .currency-selector-btn {
        padding: 4px 6px;
        gap: 4px;
    }

    .coin-balance-display {
        font-size: 11px;
    }

    .tab-item {
        font-size: 10px;
        padding: 8px 2px;
        gap: 2px;
    }

    .tab-item svg {
        width: 12px;
        height: 12px;
    }

    .dice-arena {
        padding: 16px 12px;
    }

    .roll-value-box {
        height: 84px;
        max-width: 280px;
    }

    .roll-number-text {
        font-size: 48px;
    }

    .bet-panel {
        padding: 12px;
        gap: 10px;
    }

    .bet-input-container {
        flex-wrap: nowrap;
    }

    .bet-amount-input {
        font-size: 14px;
        padding: 10px 8px;
        min-width: 0;
    }

    .quick-modifiers {
        gap: 2px;
        padding: 2px 4px;
    }

    .btn-modifier {
        padding: 5px 6px;
        font-size: 10px;
    }

    .btn-action-roll {
        padding: 13px;
        font-size: 14px;
    }

    .wallet-view-container {
        padding: 12px;
        gap: 12px;
    }

    .wallet-card-highlight {
        padding: 12px;
    }

    .deposit-address-box {
        padding: 8px 10px;
        font-size: 11px;
    }

    .chat-room-container {
        height: calc(100vh - 290px);
        min-height: 320px;
    }

    .chat-input-bar {
        padding: 8px 10px;
    }

    .modal-window {
        padding: 16px;
        max-width: 95vw;
        border-radius: var(--radius-sm);
    }
}

/* ==========================================================================
   Professional Referral Sharing & QR UI/UX Suite
   ========================================================================== */
.ref-share-card {
    background: linear-gradient(180deg, #131318 0%, #0c0c10 100%);
    border: 1px solid #23232c;
    border-radius: 12px;
    padding: 18px 20px;
    display: flex;
    flex-direction: column;
    gap: 14px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.45);
}

.ref-share-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.ref-share-title {
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: #e4e4e7;
    display: flex;
    align-items: center;
    gap: 7px;
}

.ref-share-title svg {
    color: #c084fc;
}

.ref-input-group {
    display: flex;
    gap: 8px;
    align-items: stretch;
    flex-wrap: wrap;
}

.ref-link-field-wrap {
    flex: 1;
    min-width: 240px;
    position: relative;
    display: flex;
    align-items: center;
}

.ref-link-input {
    width: 100%;
    background: #08080b;
    border: 1px solid rgba(168, 85, 247, 0.35);
    border-radius: 8px;
    padding: 11px 14px 11px 36px;
    color: #c084fc;
    font-family: var(--font-mono);
    font-size: 12px;
    font-weight: 600;
    outline: none;
    transition: all 0.2s ease;
}

.ref-link-input:focus {
    border-color: #c084fc;
    box-shadow: 0 0 0 2px rgba(192, 132, 252, 0.25);
}

.ref-link-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #a855f7;
    pointer-events: none;
    display: flex;
    align-items: center;
}

.btn-ref-copy {
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.2) 0%, rgba(147, 51, 234, 0.32) 100%);
    border: 1px solid rgba(168, 85, 247, 0.55);
    color: #f3e8ff;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.5px;
    padding: 0 16px;
    border-radius: 8px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.btn-ref-copy:hover {
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.35) 0%, rgba(147, 51, 234, 0.5) 100%);
    border-color: #c084fc;
    color: #ffffff;
    box-shadow: 0 0 14px rgba(168, 85, 247, 0.4);
    transform: translateY(-1px);
}

.btn-ref-qr-toggle {
    background: #181820;
    border: 1px solid #2e2e3a;
    color: #d4d4d8;
    font-size: 11px;
    font-weight: 700;
    padding: 0 15px;
    border-radius: 8px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.btn-ref-qr-toggle:hover {
    border-color: #52525b;
    background: #23232c;
    color: #ffffff;
}

.btn-ref-qr-toggle.active {
    background: rgba(239, 68, 68, 0.14);
    border-color: rgba(239, 68, 68, 0.45);
    color: #fca5a5;
}

.ref-social-dock {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    padding-top: 8px;
    border-top: 1px solid #1a1a24;
}

.ref-social-label {
    font-size: 11px;
    font-weight: 700;
    color: #71717a;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-right: 4px;
}

.btn-social-share {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 7px 14px;
    border-radius: 7px;
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.btn-social-share.telegram {
    background: rgba(14, 165, 233, 0.1);
    border-color: rgba(14, 165, 233, 0.3);
    color: #38bdf8;
}

.btn-social-share.telegram:hover {
    background: rgba(14, 165, 233, 0.2);
    border-color: #38bdf8;
    box-shadow: 0 0 12px rgba(56, 189, 248, 0.3);
    transform: translateY(-1px);
}

.btn-social-share.twitter {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.22);
    color: #f4f4f5;
}

.btn-social-share.twitter:hover {
    background: rgba(255, 255, 255, 0.14);
    border-color: #ffffff;
    box-shadow: 0 0 12px rgba(255, 255, 255, 0.2);
    transform: translateY(-1px);
}

.btn-social-share.whatsapp {
    background: rgba(34, 197, 94, 0.1);
    border-color: rgba(34, 197, 94, 0.3);
    color: #4ade80;
}

.btn-social-share.whatsapp:hover {
    background: rgba(34, 197, 94, 0.2);
    border-color: #4ade80;
    box-shadow: 0 0 12px rgba(34, 197, 94, 0.3);
    transform: translateY(-1px);
}

.ref-qr-container-card {
    display: none;
    background: linear-gradient(180deg, #111116 0%, #070709 100%);
    border: 1px solid #282834;
    border-radius: 12px;
    padding: 18px;
    margin-top: 4px;
    box-shadow: 0 8px 26px rgba(0, 0, 0, 0.65);
    animation: refFadeInDown 0.22s ease-out;
}

@keyframes refFadeInDown {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}

.ref-qr-top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid #1c1c26;
}

.ref-qr-title {
    font-size: 11px;
    font-weight: 800;
    color: #e4e4e7;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    display: flex;
    align-items: center;
    gap: 7px;
}

.ref-qr-close-btn {
    background: #181822;
    border: 1px solid #2a2a38;
    color: #a1a1aa;
    width: 26px;
    height: 26px;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    transition: all 0.15s ease;
}

.ref-qr-close-btn:hover {
    background: #ef4444;
    border-color: #ef4444;
    color: #ffffff;
}

.ref-qr-body {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.ref-qr-frame {
    background: #ffffff;
    padding: 10px;
    border-radius: 12px;
    box-shadow: 0 0 24px rgba(168, 85, 247, 0.3);
    border: 2px solid #a855f7;
    display: inline-block;
}

.ref-qr-frame img {
    width: 140px;
    height: 140px;
    display: block;
    image-rendering: pixelated;
}

.ref-qr-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 10px;
    font-weight: 700;
    color: #10b981;
    background: rgba(16, 185, 129, 0.12);
    border: 1px solid rgba(16, 185, 129, 0.3);
    padding: 3px 10px;
    border-radius: 20px;
}

.ref-qr-caption {
    font-size: 11px;
    color: #a1a1aa;
    text-align: center;
    max-width: 320px;
    line-height: 1.45;
}


/* ==========================================================================
   Icon-only social share buttons
   ========================================================================== */
.btn-social-share.icon-only {
    width: 40px;
    height: 40px;
    padding: 0;
    justify-content: center;
    border-radius: 10px;
}
.ref-social-dock { gap: 10px; flex-wrap: nowrap; }

/* ==========================================================================
   Commission panel (per-asset cards with real logos)
   ========================================================================== */
.ref-commission-panel {
    background: linear-gradient(180deg, #121217 0%, #0b0b0f 100%);
    border: 1px solid #22222b;
    border-radius: 12px;
    padding: 16px 18px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}
.ref-commission-header { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
.ref-commission-title {
    display: inline-flex; align-items: center; gap: 8px;
    font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.6px; color: #e4e4e7;
}
.ref-commission-title svg { color: #c084fc; }
.ref-commission-live {
    display: inline-flex; align-items: center; gap: 6px;
    font-size: 10px; font-weight: 700; color: #10b981;
    background: rgba(16,185,129,0.1); border: 1px solid rgba(16,185,129,0.3);
    padding: 3px 10px; border-radius: 20px;
}
.ref-live-dot { width: 6px; height: 6px; border-radius: 50%; background: #10b981; animation: refPulse 1.8s infinite; }
@keyframes refPulse { 0%,100% { opacity: 1; } 50% { opacity: 0.3; } }
.ref-coin-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; }
.ref-coin-card {
    display: flex; align-items: center; gap: 10px;
    background: #0a0a0d; border: 1px solid #1c1c24; border-radius: 10px; padding: 10px 12px;
    transition: border-color .2s ease, transform .2s ease;
}
.ref-coin-card:hover { border-color: #3a3a48; transform: translateY(-1px); }
.ref-coin-card.has-earnings { border-color: rgba(168,85,247,0.4); background: linear-gradient(135deg, rgba(168,85,247,0.07), #0a0a0d); }
.ref-coin-logo, .ref-coin-logo-fallback {
    width: 30px; height: 30px; flex-shrink: 0; border-radius: 50%; object-fit: contain; background: #16161c;
}
.ref-coin-logo-fallback { align-items: center; justify-content: center; font-weight: 800; font-size: 13px; display: flex; }
.ref-coin-info { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1; }
.ref-coin-top { display: flex; justify-content: space-between; align-items: baseline; gap: 6px; }
.ref-coin-symbol { font-size: 12px; font-weight: 800; color: #f4f4f5; }
.ref-coin-usd { font-size: 10px; color: #71717a; font-family: var(--font-mono); }
.ref-coin-amount { font-family: var(--font-mono); font-size: 13px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* --- Web3 Wallet Connect & Account Styling --- */
.btn-wallet-connect-header {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.18) 0%, rgba(5, 150, 105, 0.25) 100%);
    border: 1px solid rgba(16, 185, 129, 0.45);
    color: #10b981;
    font-size: 11px;
    font-weight: 800;
    padding: 5px 10px;
    border-radius: var(--radius-md);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s ease;
    box-shadow: 0 0 10px rgba(16, 185, 129, 0.12);
}
.btn-wallet-connect-header:hover {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.3) 0%, rgba(5, 150, 105, 0.4) 100%);
    border-color: #10b981;
    color: #ffffff;
    box-shadow: 0 0 14px rgba(16, 185, 129, 0.3);
    transform: translateY(-1px);
}
.btn-wallet-connected-pill {
    background: var(--bg-surface-2);
    border: 1px solid rgba(16, 185, 129, 0.4);
    color: var(--text-white);
    font-size: 11px;
    font-weight: 700;
    padding: 4px 9px;
    border-radius: var(--radius-md);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: var(--font-mono);
    transition: all 0.15s ease;
}
.btn-wallet-connected-pill:hover {
    border-color: #10b981;
    background: var(--bg-surface-3);
}
.wallet-online-indicator {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #10b981;
    box-shadow: 0 0 8px #10b981;
    flex-shrink: 0;
}
.wallet-badge-network {
    font-size: 9px;
    font-weight: 800;
    padding: 2px 5px;
    border-radius: 4px;
    background: rgba(16, 185, 129, 0.15);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.3);
    letter-spacing: 0.4px;
}
/* Modern High-End Web3 Wallet Modal */
.wallet-connect-modal-window {
    max-width: 460px;
    background: radial-gradient(120% 120% at 50% 0%, #161722 0%, #0c0d12 100%) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.85), 0 0 35px rgba(16, 185, 129, 0.07) !important;
    border-radius: 18px !important;
    padding: 24px !important;
}
.wallet-modal-title-badge {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.2), rgba(6, 95, 70, 0.4));
    border: 1px solid rgba(16, 185, 129, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #10b981;
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.2);
}
.wallet-option-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 14px;
}
.wallet-option-card {
    display: flex;
    align-items: center;
    gap: 14px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 14px;
    padding: 13px 16px;
    cursor: pointer;
    text-align: left;
    transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
    width: 100%;
    position: relative;
    overflow: hidden;
}
.wallet-option-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; bottom: 0;
    width: 3px;
    background: transparent;
    transition: background 0.2s ease;
}
.wallet-option-card:hover {
    background: rgba(255, 255, 255, 0.05);
    transform: translateX(3px);
}
.wallet-option-card.evm-card:hover {
    border-color: rgba(246, 133, 27, 0.45);
    box-shadow: 0 8px 24px rgba(246, 133, 27, 0.12);
}
.wallet-option-card.evm-card:hover::before { background: #f6851b; }

.wallet-option-card.solana-card:hover {
    border-color: rgba(171, 92, 246, 0.45);
    box-shadow: 0 8px 24px rgba(171, 92, 246, 0.12);
}
.wallet-option-card.solana-card:hover::before { background: #ab5cf6; }

.wallet-option-card.multichain-card:hover {
    border-color: rgba(59, 130, 246, 0.45);
    box-shadow: 0 8px 24px rgba(59, 130, 246, 0.12);
}
.wallet-option-card.multichain-card:hover::before { background: #3b82f6; }

.wallet-option-card.ton-card:hover {
    border-color: rgba(0, 152, 234, 0.45);
    box-shadow: 0 8px 24px rgba(0, 152, 234, 0.12);
}
.wallet-option-card.ton-card:hover::before { background: #0098ea; }

.wallet-option-card.trust-card:hover {
    border-color: rgba(11, 101, 198, 0.5);
    box-shadow: 0 8px 24px rgba(11, 101, 198, 0.15);
}
.wallet-option-card.trust-card:hover::before { background: #0b65c6; }

.wallet-option-card.okx-card:hover {
    border-color: rgba(255, 255, 255, 0.5);
    box-shadow: 0 8px 24px rgba(255, 255, 255, 0.12);
}
.wallet-option-card.okx-card:hover::before { background: #ffffff; }
.wallet-option-icon.okx {
    background: #000000;
    border: 1px solid rgba(255, 255, 255, 0.2);
}
.wallet-deeplink-btn.okx {
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #ffffff;
}
.wallet-deeplink-btn.okx:hover {
    background: #ffffff;
    color: #000000;
    border-color: #ffffff;
}


.wallet-option-icon {
    width: 42px;
    height: 42px;
    border-radius: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: transform 0.2s ease;
}
.wallet-option-card:hover .wallet-option-icon {
    transform: scale(1.06);
}
.wallet-option-icon.evm {
    background: rgba(246, 133, 27, 0.12);
    border: 1px solid rgba(246, 133, 27, 0.25);
    color: #f6851b;
}
.wallet-option-icon.solana {
    background: rgba(171, 92, 246, 0.12);
    border: 1px solid rgba(171, 92, 246, 0.25);
    color: #ab5cf6;
}
.wallet-option-icon.multichain {
    background: rgba(59, 130, 246, 0.12);
    border: 1px solid rgba(59, 130, 246, 0.25);
    color: #60a5fa;
}

.wallet-option-icon.trust {
    background: rgba(11, 101, 198, 0.12);
    border: 1px solid rgba(11, 101, 198, 0.25);
    color: #0b65c6;
}

.wallet-option-icon.ton {
    background: rgba(0, 152, 234, 0.12);
    border: 1px solid rgba(0, 152, 234, 0.25);
    color: #0098ea;
}
.wallet-option-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 3px;
}
.wallet-option-name {
    font-size: 13.5px;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: -0.2px;
}
.wallet-option-desc {
    font-size: 11px;
    color: #71717a;
    font-weight: 500;
}
.wallet-status-badge {
    font-size: 10.5px;
    font-weight: 700;
    padding: 3px 9px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.04);
    color: #a1a1aa;
    border: 1px solid rgba(255, 255, 255, 0.08);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.wallet-status-badge.detected {
    background: rgba(16, 185, 129, 0.12);
    color: #10b981;
    border-color: rgba(16, 185, 129, 0.35);
}
.wallet-pulse-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #10b981;
    box-shadow: 0 0 6px #10b981;
    display: none;
}
.wallet-status-badge.detected .wallet-pulse-dot {
    display: inline-block;
    animation: pulseDotAnim 2s infinite ease-in-out;
}
.wallet-status-badge.uninstalled {
    background: rgba(245, 158, 11, 0.08);
    color: #fbbf24;
    border-color: rgba(245, 158, 11, 0.25);
}
.btn-instant-guest {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 11px 14px;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.08), rgba(6, 95, 70, 0.12));
    border: 1px solid rgba(16, 185, 129, 0.25);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-top: 12px;
}
.btn-instant-guest:hover {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.16), rgba(6, 95, 70, 0.24));
    border-color: #10b981;
    transform: translateY(-1px);
}
.wallet-help-box {
    background: rgba(245, 158, 11, 0.08);
    border: 1px solid rgba(245, 158, 11, 0.25);
    border-radius: 12px;
    padding: 14px;
    margin-top: 12px;
    display: none;
    text-align: left;
}
@keyframes pulseDotAnim {
    0%, 100% { transform: scale(0.9); opacity: 0.6; }
    50% { transform: scale(1.3); opacity: 1; }
}

.wallet-modal-security-footer {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 18px;
    padding: 12px 14px;
    background: rgba(16, 185, 129, 0.05);
    border: 1px solid rgba(16, 185, 129, 0.15);
    border-radius: 12px;
}
.security-footer-icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    color: #10b981;
}
.security-footer-text {
    font-size: 10.5px;
    color: #94a3b8;
    line-height: 1.45;
    font-weight: 500;
}

/* Provably Fair Bet Receipt Actions & Audit Card */
.btn-receipt-action {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 16px;
    font-size: 11px;
    font-weight: 700;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.15s ease;
    border: none;
    letter-spacing: 0.3px;
    text-transform: uppercase;
}
.btn-receipt-action.rotate {
    background: #18181b;
    border: 1px solid #27272a;
    color: #e4e4e7;
}
.btn-receipt-action.rotate:hover {
    background: #27272a;
    border-color: #3f3f46;
    color: #ffffff;
}
.btn-receipt-action.verify {
    background: #10b981;
    color: #09090b;
    font-weight: 800;
}
.btn-receipt-action.verify:hover {
    background: #059669;
    color: #ffffff;
}
.receipt-verification-card {
    background: #09090b;
    border: 1px solid rgba(16, 185, 129, 0.35);
    border-radius: 8px;
    padding: 14px;
    margin-top: 8px;
}
.receipt-audit-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    font-size: 11px;
    font-family: var(--font-mono);
    background: #000000;
    padding: 10px 12px;
    border-radius: 6px;
    border: 1px solid #1e1e24;
}


.wallet-brand-logo {
    width: 28px;
    height: 28px;
    object-fit: contain;
    display: block;
}


/* ==============================================================================
   WALLET MODAL INTERACTIVE PANELS & MOBILE QR CODE SYSTEM
   ============================================================================== */
.wallet-subview-panel {
    display: none;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 6px 0;
    animation: fadeInModal 0.2s ease;
}
.wallet-subview-panel.active {
    display: flex;
}
@keyframes fadeInModal {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}
.wallet-qr-card {
    background: #ffffff;
    border-radius: 16px;
    padding: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 14px auto 10px auto;
    width: 210px;
    height: 210px;
    position: relative;
}
.wallet-qr-card svg, .wallet-qr-card img {
    width: 100%;
    height: 100%;
    border-radius: 6px;
    display: block;
}
.wallet-uri-box {
    width: 100%;
    display: flex;
    gap: 8px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 8px 12px;
    align-items: center;
    margin-top: 10px;
    box-sizing: border-box;
}
.wallet-uri-input {
    flex: 1;
    background: transparent;
    border: none;
    color: #94a3b8;
    font-size: 11px;
    font-family: monospace;
    overflow: hidden;
    text-overflow: ellipsis;
    outline: none;
}
.wallet-deeplink-row {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 12px;
    width: 100%;
}
.wallet-deeplink-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #e2e8f0;
    font-size: 11.5px;
    font-weight: 700;
    padding: 7px 12px;
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.2s ease;
    cursor: pointer;
}
.wallet-deeplink-btn:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.25);
    color: #ffffff;
}
.wallet-back-btn {
    align-self: flex-start;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: transparent;
    border: none;
    color: #a1a1aa;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    margin-bottom: 8px;
    padding: 5px 8px;
    border-radius: 6px;
    transition: all 0.15s ease;
}
.wallet-back-btn:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.08);
}

/* FLOATING IN-APP NOTIFICATION TOAST SYSTEM */
.toast-container {
    position: fixed;
    top: 24px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 100000;
    display: flex;
    flex-direction: column;
    gap: 8px;
    pointer-events: none;
}
.toast-pill {
    background: #18181b;
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #ffffff;
    padding: 10px 18px;
    border-radius: 999px;
    font-size: 12.5px;
    font-weight: 700;
    box-shadow: 0 10px 30px rgba(0,0,0,0.6);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    pointer-events: auto;
    animation: toastSlideDown 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    transition: opacity 0.3s, transform 0.3s;
}
.toast-pill.success {
    background: linear-gradient(135deg, #064e3b 0%, #065f46 100%);
    border-color: #10b981;
    color: #ecfdf5;
}
.toast-pill.error {
    background: linear-gradient(135deg, #7f1d1d 0%, #991b1b 100%);
    border-color: #ef4444;
    color: #fef2f2;
}
.toast-pill.warn {
    background: linear-gradient(135deg, #78350f 0%, #92400e 100%);
    border-color: #f59e0b;
    color: #fffbeb;
}
@keyframes toastSlideDown {
    from { opacity: 0; transform: translateY(-16px); }
    to { opacity: 1; transform: translateY(0); }
}

/* --- Professional Guest Mode & Live Feed Enhancements --- */
.guest-mode-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 32px;
    padding: 0 10px;
    background: rgba(245, 158, 11, 0.08);
    border: 1px solid rgba(245, 158, 11, 0.3);
    border-radius: 6px;
    font-size: 11px;
    font-weight: 700;
    color: #fbbf24;
    letter-spacing: 0.3px;
    white-space: nowrap;
    flex-shrink: 0;
    box-sizing: border-box;
}
.guest-indicator-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #f59e0b;
    box-shadow: 0 0 6px rgba(245, 158, 11, 0.8);
    animation: pulseSlow 2s infinite ease-in-out;
}
@keyframes pulseSlow {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.4; transform: scale(0.85); }
}

.feed-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 7px 10px;
    background: var(--bg-black);
    border: 1px solid var(--border-hairline);
    border-radius: var(--radius-sm);
    font-family: var(--font-mono);
    font-size: 12px;
    border-left: 3px solid var(--border-hairline);
    gap: 8px;
}
.feed-col-meta {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-width: 160px;
}
.feed-time {
    font-family: var(--font-mono);
    font-size: 11px;
    color: #71717a;
    font-weight: 600;
}
.feed-player {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    font-size: 11px;
    font-weight: 700;
    color: #e4e4e7;
    background: #18181b;
    padding: 1px 6px;
    border-radius: 4px;
    border: 1px solid #27272a;
    max-width: 110px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.badge-game-pill {
    font-size: 9px;
    font-weight: 800;
    color: #00f0ff;
    background: rgba(0, 240, 255, 0.1);
    border: 1px solid rgba(0, 240, 255, 0.2);
    padding: 1px 5px;
    border-radius: 3px;
}
.feed-col-target {
    font-size: 11px;
    color: #d4d4d8;
    flex: 1;
}
.feed-col-profit {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

/* Luxury VIP Vector Badge Styling */
.vip-badge-flex {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.vip-badge-svg {
    display: inline-block;
    vertical-align: middle;
}

/* Anonymous Mode Toggle Switch */
.toggle-switch-container {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
    flex-shrink: 0;
}
.toggle-switch-container input {
    opacity: 0;
    width: 0;
    height: 0;
}
.toggle-switch-slider {
    position: absolute;
    cursor: pointer;
    inset: 0;
    background-color: #27272a;
    border: 1px solid #3f3f46;
    transition: all 0.25s ease;
    border-radius: 24px;
}
.toggle-switch-slider:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 3px;
    bottom: 3px;
    background-color: #a1a1aa;
    transition: all 0.25s ease;
    border-radius: 50%;
}
.toggle-switch-container input:checked + .toggle-switch-slider {
    background-color: #8b5cf6;
    border-color: #a78bfa;
    box-shadow: 0 0 10px rgba(139, 92, 246, 0.4);
}
.toggle-switch-container input:checked + .toggle-switch-slider:before {
    transform: translateX(20px);
    background-color: #ffffff;
}


/* ==========================================================================
   BC.GAME AUTHENTIC BETS FEED & BET SLIP STYLING
   ========================================================================== */

/* Tabs Navigation */
.bets-tabs-nav {
    display: inline-flex;
    align-items: center;
    background: #0d0d12;
    padding: 3px;
    border-radius: 8px;
    border: 1px solid #1f1f28;
    gap: 4px;
}
.bets-tab-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 6px;
    border: 1px solid transparent;
    background: transparent;
    color: #a1a1aa;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.15s ease;
}
.bets-tab-btn:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.04);
}
.bets-tab-btn.active {
    background: #1e1e28;
    color: #ffffff;
    border-color: #2e2e3e;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}
.tab-indicator-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #10b981;
    box-shadow: 0 0 6px #10b981;
}

/* 5-Column Table Header */
.bets-table-header {
    display: grid;
    grid-template-columns: 1.4fr 1.2fr 1.3fr 0.9fr 1.2fr;
    column-gap: 14px;
    padding: 10px 16px;
    background: #09090d;
    border: 1px solid #1a1a24;
    border-radius: 8px 8px 0 0;
    margin-top: 8px;
    font-size: 11px;
    font-weight: 700;
    color: #71717a;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.bth-col.bth-bet {
    text-align: right;
    padding-right: 4px;
}
.bth-col.bth-mult {
    text-align: center;
}
.bth-col.bth-profit {
    text-align: right;
}

/* Feed Rows */
.bets-feed {
    display: flex;
    flex-direction: column;
    gap: 3px;
    background: #09090d;
    border: 1px solid #1a1a24;
    border-top: none;
    border-radius: 0 0 8px 8px;
    max-height: 290px;
    overflow-y: auto;
    padding: 3px;
}
.feed-row-bc {
    display: grid;
    grid-template-columns: 1.4fr 1.2fr 1.3fr 0.9fr 1.2fr;
    column-gap: 14px;
    align-items: center;
    padding: 10px 16px;
    background: #0f0f15;
    border-radius: 6px;
    font-size: 12px;
    font-family: var(--font-mono);
    color: #e4e4e7;
    transition: background 0.12s ease;
    border: 1px solid transparent;
}
.feed-row-bc:hover {
    background: #151620;
    border-color: #242533;
}
.feed-col-game {
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 700;
    color: #ffffff;
    font-size: 12px;
    cursor: pointer;
    user-select: none;
    transition: color 0.15s ease;
}
.feed-col-game:hover {
    color: #60a5fa;
}
.feed-col-game:hover .game-link-title {
    text-decoration: underline;
}
.mybet-id-link {
    color: #10b981;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.15s ease;
}
.mybet-id-link:hover {
    text-decoration: underline;
    color: #34d399;
}
.feed-col-user {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #a1a1aa;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.feed-col-bet {
    text-align: right;
    color: #d4d4d8;
    font-weight: 600;
}
.feed-col-mult {
    text-align: right;
    color: #a1a1aa;
    font-weight: 600;
}
.feed-col-profit {
    text-align: right;
    font-weight: 700;
}
.feed-col-profit.win {
    color: #10b981;
}
.feed-col-profit.loss {
    color: #ef4444;
}

/* ==========================================================================
   BC.GAME AUTHENTIC TICKET BET SLIP
   ========================================================================== */
.bet-slip-card {
    background: #14151b !important;
    border: 1px solid #272833 !important;
    border-radius: 16px !important;
    padding: 0 !important;
    max-width: 440px !important;
    width: 92% !important;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.7) !important;
}
.bet-slip-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 18px;
    background: #171821;
    border-bottom: 1px solid #22232e;
}
.bet-slip-title {
    font-size: 15px;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: -0.3px;
}
.btn-slip-share {
    background: #20222d;
    border: 1px solid #2f3140;
    color: #a1a1aa;
    border-radius: 6px;
    padding: 5px 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    transition: all 0.15s;
}
.btn-slip-share:hover {
    color: #ffffff;
    border-color: #3b82f6;
}

/* Payout Box */
.bet-slip-payout-box {
    padding: 20px 20px 14px 20px;
    text-align: center;
    background: linear-gradient(180deg, #181a24 0%, #14151e 100%);
}
.slip-payout-label {
    font-size: 11px;
    font-weight: 700;
    color: #71717a;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.slip-payout-val {
    font-size: 26px;
    font-weight: 900;
    font-family: var(--font-mono);
    margin-top: 4px;
    letter-spacing: -0.5px;
}
.slip-payout-val.win {
    color: #10b981;
}
.slip-payout-val.loss {
    color: #ef4444;
}
.slip-payout-sub {
    font-size: 12px;
    color: #71717a;
    margin-top: 2px;
    font-family: var(--font-mono);
}

.slip-metrics-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: 14px;
    background: #0f1016;
    border: 1px solid #1f202b;
    border-radius: 8px;
    padding: 10px 14px;
}
.slip-metric-cell {
    display: flex;
    flex-direction: column;
    text-align: left;
}
.slip-sub-label {
    font-size: 10px;
    color: #71717a;
    font-weight: 700;
    text-transform: uppercase;
}
.slip-sub-val {
    font-size: 13px;
    font-weight: 800;
    color: #ffffff;
    font-family: var(--font-mono);
    margin-top: 2px;
}

/* Perforation Divider */
.bet-slip-perforation {
    display: flex;
    align-items: center;
    position: relative;
    height: 18px;
    background: #14151b;
}
.slip-notch {
    width: 14px;
    height: 18px;
    background: rgba(0, 0, 0, 0.7);
    position: absolute;
    top: 0;
}
.slip-notch.left {
    left: 0;
    border-radius: 0 10px 10px 0;
    box-shadow: inset -2px 0 4px rgba(0, 0, 0, 0.4);
}
.slip-notch.right {
    right: 0;
    border-radius: 10px 0 0 10px;
    box-shadow: inset 2px 0 4px rgba(0, 0, 0, 0.4);
}
.slip-dash-line {
    flex: 1;
    margin: 0 18px;
    border-bottom: 2px dashed #262836;
}

/* Slip Body */
.bet-slip-body {
    padding: 8px 18px 20px 18px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    background: #14151b;
}
.slip-user-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
}
.slip-user-meta {
    display: flex;
    align-items: center;
    gap: 8px;
}
.slip-avatar {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #20222d;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    border: 1px solid #2e3040;
}
.slip-username {
    font-size: 12px;
    font-weight: 800;
    color: #ffffff;
}
.slip-timestamp {
    font-size: 10px;
    color: #71717a;
}
.slip-bet-id-wrap {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 2px;
}
.slip-bet-id-chip {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: #1a1c26;
    border: 1px solid #282a3a;
    padding: 3px 8px;
    border-radius: 6px;
    font-size: 11px;
    font-family: var(--font-mono);
    color: #10b981;
    cursor: pointer;
    transition: all 0.15s;
}
.slip-bet-id-chip:hover {
    border-color: #10b981;
}

/* Slip Game Card */
.slip-game-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #191b24;
    border: 1px solid #272938;
    border-radius: 10px;
    padding: 10px 14px;
}
.slip-game-icon {
    font-size: 22px;
}
.slip-game-title {
    font-size: 13px;
    font-weight: 800;
    color: #ffffff;
}
.slip-game-sub {
    font-size: 10px;
    color: #71717a;
}
.btn-slip-play {
    background: transparent;
    border: none;
    color: #3b82f6;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
}
.btn-slip-play:hover {
    text-decoration: underline;
}

/* Detail & Provably Fair Cards */
.slip-game-detail-card, .slip-pf-card {
    background: #101117;
    border: 1px solid #1d1e28;
    border-radius: 10px;
    padding: 12px 14px;
}
.slip-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11px;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 8px;
}
.slip-badge-verified {
    font-size: 9px;
    font-weight: 800;
    color: #10b981;
    background: rgba(16, 185, 129, 0.12);
    border: 1px solid rgba(16, 185, 129, 0.3);
    padding: 2px 6px;
    border-radius: 4px;
}
.slip-detail-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}
.slip-detail-pill {
    background: #171822;
    border: 1px solid #232534;
    border-radius: 6px;
    padding: 6px 10px;
    display: flex;
    flex-direction: column;
}
.detail-label {
    font-size: 9px;
    color: #71717a;
    text-transform: uppercase;
    font-weight: 700;
}
.detail-value {
    font-size: 12px;
    font-weight: 800;
    color: #ffffff;
    font-family: var(--font-mono);
    margin-top: 2px;
}

/* Action Area */
.slip-notice-global {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    background: #161822;
    border: 1px solid #232636;
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 11px;
    color: #a1a1aa;
    line-height: 1.4;
    margin-top: 6px;
}
.btn-slip-verify-primary {
    width: 100%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: #10b981;
    color: #000000;
    font-size: 13px;
    font-weight: 800;
    padding: 11px 16px;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.25);
    transition: all 0.15s ease;
}
.btn-slip-verify-primary:hover {
    background: #059669;
    transform: translateY(-1px);
}


/* Accordion for Game Detail & Provably Fair */
.slip-accordion-wrap {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.slip-accordion-btn {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #191b24;
    border: 1px solid #272938;
    border-radius: 10px;
    padding: 12px 14px;
    cursor: pointer;
    user-select: none;
    transition: all 0.15s ease;
}
.slip-accordion-btn:hover {
    background: #20222f;
    border-color: #35384c;
}
.slip-accordion-title {
    font-size: 13px;
    font-weight: 800;
    color: #ffffff;
}
.slip-accordion-arrow {
    display: flex;
    align-items: center;
    color: #a1a1aa;
    transition: transform 0.2s ease;
}
.slip-accordion-btn.expanded .slip-accordion-arrow {
    transform: rotate(90deg);
}
.slip-accordion-content {
    display: none;
    flex-direction: column;
    gap: 10px;
    animation: fadeInSlip 0.2s ease-in-out;
}
.slip-accordion-content.expanded {
    display: flex;
}
@keyframes fadeInSlip {
    from { opacity: 0; transform: translateY(-4px); }
    to { opacity: 1; transform: translateY(0); }
}
