/* Whale Hunter v5.0 — Main Styles */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg-primary: #0a0e1a;
    --bg-secondary: #111827;
    --bg-card: #1a1f2e;
    --bg-hover: #252b3d;
    --border: #2a3142;
    --text-primary: #f0f4f8;
    --text-secondary: #94a3b8;
    --accent-green: #00d4aa;
    --accent-red: #ff4757;
    --accent-blue: #3b82f6;
    --accent-purple: #8b5cf6;
    --accent-yellow: #fbbf24;
}

body {
    background: var(--bg-primary);
    color: var(--text-primary);
    font-family: 'Inter', sans-serif;
    min-height: 100vh;
}

/* بنر قیمت */
.ticker-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 42px;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border);
    overflow: hidden;
    z-index: 1000;
}

.ticker-content {
    display: flex;
    align-items: center;
    height: 100%;
    animation: ticker 40s linear infinite;
    white-space: nowrap;
}

@keyframes ticker {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

.ticker-item {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 0 30px;
    font-size: 13px;
    font-weight: 600;
    border-right: 1px solid var(--border);
}

.ticker-item img {
    width: 22px;
    height: 22px;
    border-radius: 50%;
}

.ticker-item .price {
    font-family: 'Courier New', monospace;
    font-weight: 700;
    font-size: 14px;
}

.ticker-item .change {
    font-size: 11px;
    padding: 3px 8px;
    border-radius: 6px;
}

.ticker-item .change.up {
    color: var(--accent-green);
    background: rgba(0, 212, 170, 0.12);
}

.ticker-item .change.down {
    color: var(--accent-red);
    background: rgba(255, 71, 87, 0.12);
}

/* لایوت */
.app-layout {
    display: flex;
    min-height: 100vh;
    padding-top: 42px;
}

/* سایدبار */
.sidebar {
    width: 260px;
    background: var(--bg-secondary);
    border-left: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    padding: 25px 0;
    position: fixed;
    top: 42px;
    bottom: 0;
    right: 0;
}

.sidebar-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 25px 30px;
    border-bottom: 1px solid var(--border);
    margin-bottom: 20px;
}

.sidebar-logo .whale {
    font-size: 36px;
}

.sidebar-logo span:last-child {
    font-size: 16px;
    font-weight: 800;
    line-height: 1.2;
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.sidebar-nav {
    flex: 1;
    padding: 0 15px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 18px;
    border-radius: 12px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: 0.3s;
    margin-bottom: 4px;
}

.nav-item:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.nav-item.active {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.15), rgba(139, 92, 246, 0.15));
    color: var(--accent-blue);
    border: 1px solid rgba(59, 130, 246, 0.2);
}

.nav-icon {
    font-size: 18px;
}

.sidebar-footer {
    padding: 20px 25px 0;
    border-top: 1px solid var(--border);
}

.user-info {
    margin-bottom: 15px;
}

.user-name {
    display: block;
    font-size: 14px;
    font-weight: 600;
}

.user-role {
    font-size: 11px;
    color: var(--accent-blue);
}

.logout-btn {
    width: 100%;
    padding: 10px;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text-secondary);
    font-size: 13px;
    cursor: pointer;
    transition: 0.3s;
}

.logout-btn:hover {
    border-color: var(--accent-red);
    color: var(--accent-red);
}

/* محتوا اصلی */
.main-content {
    flex: 1;
    margin-right: 260px;
    padding: 25px 30px;
}

.main-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.main-header h2 {
    font-size: 22px;
    font-weight: 700;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* Power Button */
.power-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: var(--bg-card);
    border: 2px solid var(--border);
    border-radius: 12px;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.3s;
}

.power-btn:hover {
    border-color: var(--accent-green);
    color: var(--accent-green);
}

.power-btn.active {
    background: rgba(0, 212, 170, 0.15);
    border-color: var(--accent-green);
    color: var(--accent-green);
    box-shadow: 0 0 20px rgba(0, 212, 170, 0.2);
}

.power-icon {
    font-size: 18px;
}

.bot-status {
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.bot-status.online {
    background: rgba(0, 212, 170, 0.15);
    color: var(--accent-green);
}

.bot-status.offline {
    background: rgba(148, 163, 184, 0.15);
    color: var(--text-secondary);
}

.clock {
    font-family: 'Courier New', monospace;
    color: var(--text-secondary);
    font-size: 14px;
}

/* گرید */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 20px;
}

.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 20px;
    transition: 0.3s;
}

.card:hover {
    border-color: var(--bg-hover);
}

.card.highlight {
    background: linear-gradient(135deg, var(--bg-card), rgba(59, 130, 246, 0.05));
    border-color: rgba(59, 130, 246, 0.3);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.card-header h3 {
    font-size: 12px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

.badge {
    padding: 4px 10px;
    background: rgba(0, 212, 170, 0.15);
    color: var(--accent-green);
    font-size: 10px;
    font-weight: 700;
    border-radius: 6px;
}

.count-badge {
    padding: 4px 12px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 12px;
    font-weight: 700;
    border-radius: 20px;
}

.live-badge {
    color: var(--accent-red);
    font-size: 11px;
    font-weight: 700;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.big-number {
    font-size: 36px;
    font-weight: 800;
    font-family: 'Courier New', monospace;
    margin: 10px 0;
}

.pnl-display {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 15px;
}

.pnl-display.positive {
    color: var(--accent-green);
}

.pnl-display.negative {
    color: var(--accent-red);
}

.mini-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
    padding-top: 15px;
    border-top: 1px solid var(--border);
}

.mini-stats .label {
    display: block;
    font-size: 11px;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.mini-stats .val {
    font-size: 14px;
    font-weight: 700;
    font-family: monospace;
}

/* پوزیشن */
.positions-list {
    max-height: 300px;
    overflow-y: auto;
}

.position-item {
    display: grid;
    grid-template-columns: auto 1fr auto auto;
    gap: 12px;
    align-items: center;
    padding: 12px;
    border-radius: 10px;
    margin-bottom: 8px;
    background: var(--bg-secondary);
    transition: 0.3s;
}

.position-item:hover {
    background: var(--bg-hover);
}

.position-item.long {
    border-right: 3px solid var(--accent-green);
}

.position-item.short {
    border-right: 3px solid var(--accent-red);
}

.pos-side {
    font-size: 11px;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 6px;
}

.pos-side.long {
    background: rgba(0, 212, 170, 0.15);
    color: var(--accent-green);
}

.pos-side.short {
    background: rgba(255, 71, 87, 0.15);
    color: var(--accent-red);
}

.pos-pnl {
    font-family: monospace;
    font-weight: 700;
    font-size: 15px;
}

.pos-pnl.positive {
    color: var(--accent-green);
}

.pos-pnl.negative {
    color: var(--accent-red);
}

.pos-trailing {
    font-size: 10px;
    padding: 3px 10px;
    border-radius: 6px;
    background: rgba(251, 191, 36, 0.15);
    color: var(--accent-yellow);
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-secondary);
}

.empty-icon {
    font-size: 40px;
    display: block;
    margin-bottom: 10px;
}

.empty-state p {
    font-size: 14px;
    margin-bottom: 5px;
}

.empty-hint {
    font-size: 12px;
    opacity: 0.7;
}

/* نهنگ */
.whales-list {
    max-height: 300px;
    overflow-y: auto;
}

.whale-item {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 10px;
    align-items: center;
    padding: 10px;
    border-radius: 8px;
    margin-bottom: 6px;
    background: var(--bg-secondary);
    font-size: 12px;
}

.whale-type {
    font-weight: 700;
    font-size: 11px;
}

.whale-type.buy {
    color: var(--accent-green);
}

.whale-type.sell {
    color: var(--accent-red);
}

/* ترند */
.trends-list {
    max-height: 250px;
    overflow-y: auto;
}

.trend-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    border-radius: 8px;
    margin-bottom: 5px;
    background: var(--bg-secondary);
    font-size: 13px;
}

.trend-badge {
    padding: 3px 10px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
}

.trend-badge.uptrend {
    background: rgba(0, 212, 170, 0.15);
    color: var(--accent-green);
}

.trend-badge.downtrend {
    background: rgba(255, 71, 87, 0.15);
    color: var(--accent-red);
}

.trend-badge.neutral {
    background: rgba(148, 163, 184, 0.15);
    color: var(--text-secondary);
}

/* قیمت */
.prices-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.price-item {
    background: var(--bg-secondary);
    padding: 12px;
    border-radius: 10px;
    text-align: center;
    font-size: 12px;
}

.price-item .coin-name {
    color: var(--text-secondary);
    display: block;
    margin-bottom: 5px;
}

.price-item .coin-price {
    font-family: monospace;
    font-weight: 700;
    font-size: 15px;
}

/* تاریخچه */
.history-list {
    max-height: 250px;
    overflow-y: auto;
}

.history-item {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 10px;
    align-items: center;
    padding: 10px;
    border-radius: 8px;
    margin-bottom: 6px;
    background: var(--bg-secondary);
    font-size: 12px;
}

.hist-pnl {
    font-family: monospace;
    font-weight: 700;
}

.hist-pnl.positive {
    color: var(--accent-green);
}

.hist-pnl.negative {
    color: var(--accent-red);
}

.hist-reason {
    color: var(--text-secondary);
    font-size: 11px;
}

/* تنظیمات */
.settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.settings-card .setting-item {
    margin-bottom: 20px;
}

.settings-card label {
    display: block;
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 8px;
    font-weight: 500;
}

.settings-card input {
    width: 100%;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text-primary);
    font-size: 14px;
    outline: none;
    transition: 0.3s;
}

.settings-card input:focus {
    border-color: var(--accent-blue);
}

.settings-card .hint {
    display: block;
    font-size: 11px;
    color: var(--text-secondary);
    margin-top: 6px;
    opacity: 0.8;
}

.settings-actions {
    display: flex;
    gap: 15px;
}

.save-btn, .reset-btn {
    padding: 14px 30px;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.3s;
    border: none;
}

.save-btn {
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
    color: white;
}

.save-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(59, 130, 246, 0.3);
}

.reset-btn {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    color: var(--text-secondary);
}

.reset-btn:hover {
    border-color: var(--accent-red);
    color: var(--accent-red);
}

/* جدول تاریخچه */
.history-table-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    overflow: hidden;
}

.history-table {
    width: 100%;
    border-collapse: collapse;
}

.history-table th {
    background: var(--bg-secondary);
    padding: 14px;
    text-align: right;
    font-size: 12px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
    border-bottom: 1px solid var(--border);
}

.history-table td {
    padding: 14px;
    font-size: 13px;
    border-bottom: 1px solid var(--border);
}

.history-table tr:hover {
    background: var(--bg-hover);
}

.history-table tr.win {
    background: rgba(0, 212, 170, 0.05);
}

.history-table tr.loss {
    background: rgba(255, 71, 87, 0.05);
}

.side-badge {
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 700;
}

.side-badge.long {
    background: rgba(0, 212, 170, 0.15);
    color: var(--accent-green);
}

.side-badge.short {
    background: rgba(255, 71, 87, 0.15);
    color: var(--accent-red);
}

.pnl {
    font-family: monospace;
    font-weight: 700;
}

.pnl.positive {
    color: var(--accent-green);
}

.pnl.negative {
    color: var(--accent-red);
}

.reason {
    font-size: 11px;
    color: var(--text-secondary);
}

.time {
    font-size: 11px;
    color: var(--text-secondary);
    font-family: monospace;
}

.empty-cell {
    text-align: center;
    color: var(--text-secondary);
    padding: 40px;
}

/* فیلتر */
.filter-bar {
    display: flex;
    gap: 10px;
}

.filter-btn {
    padding: 8px 20px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text-secondary);
    font-size: 13px;
    cursor: pointer;
    transition: 0.3s;
}

.filter-btn:hover, .filter-btn.active {
    background: var(--accent-blue);
    color: white;
    border-color: var(--accent-blue);
}

/* کیف‌پول */
.wallets-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.wallet-card {
    padding: 20px;
}

.wallet-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.wallet-rank {
    font-size: 20px;
}

.wallet-chain {
    padding: 4px 12px;
    background: var(--bg-secondary);
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
}

.wallet-address {
    font-family: monospace;
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 15px;
    padding: 10px;
    background: var(--bg-secondary);
    border-radius: 8px;
}

.wallet-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 15px;
}

.wallet-stats .label {
    display: block;
    font-size: 11px;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.wallet-stats .val {
    font-size: 14px;
    font-weight: 700;
    font-family: monospace;
}

.wallet-stats .val.positive {
    color: var(--accent-green);
}

.track-btn {
    width: 100%;
    padding: 12px;
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
    border: none;
    border-radius: 10px;
    color: white;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.3s;
}

.track-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(59, 130, 246, 0.3);
}

/* ریسپانسیو */
@media (max-width: 1100px) {
    .sidebar {
        width: 200px;
    }
    .main-content {
        margin-right: 200px;
    }
}

@media (max-width: 900px) {
    .sidebar {
        display: none;
    }
    .main-content {
        margin-right: 0;
    }
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}

/* ======================== LOGIN PAGE STYLES ======================== */
.login-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, #0a0e1a 0%, #1a1f2e 50%, #0f1629 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    padding: 20px;
    overflow-y: auto;
}

.login-overlay::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(ellipse at 20% 80%, rgba(59, 130, 246, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 20%, rgba(139, 92, 246, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 50%, rgba(0, 212, 170, 0.05) 0%, transparent 70%);
    pointer-events: none;
}

.login-box {
    position: relative;
    background: linear-gradient(145deg, rgba(26, 31, 46, 0.95), rgba(17, 24, 39, 0.95));
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 24px;
    padding: 50px 45px;
    width: 100%;
    max-width: 480px;
    text-align: center;
    box-shadow: 
        0 25px 80px rgba(0, 0, 0, 0.6),
        0 0 60px rgba(59, 130, 246, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    animation: loginAppear 0.6s ease-out;
}

@keyframes loginAppear {
    0% { opacity: 0; transform: translateY(30px) scale(0.95); }
    100% { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20% { transform: translateX(-10px); }
    40% { transform: translateX(10px); }
    60% { transform: translateX(-10px); }
    80% { transform: translateX(10px); }
}

.login-box .whale-icon {
    font-size: 72px;
    margin-bottom: 20px;
    display: block;
    animation: whaleFloat 3s ease-in-out infinite;
    filter: drop-shadow(0 0 30px rgba(59, 130, 246, 0.4));
}

@keyframes whaleFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.login-box h1 {
    font-size: 32px;
    font-weight: 800;
    margin-bottom: 8px;
    background: linear-gradient(135deg, #3b82f6, #8b5cf6, #00d4aa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: 2px;
}

.login-box .tagline {
    font-size: 15px;
    color: #94a3b8;
    margin-bottom: 35px;
    font-weight: 400;
}

.login-box input {
    width: 100%;
    padding: 16px 20px;
    margin-bottom: 16px;
    background: rgba(10, 14, 26, 0.8);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 14px;
    color: #f0f4f8;
    font-size: 15px;
    font-family: 'Inter', sans-serif;
    outline: none;
    transition: all 0.3s ease;
    text-align: right;
}

.login-box input::placeholder {
    color: #64748b;
    font-size: 14px;
}

.login-box input:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.15), 0 0 20px rgba(59, 130, 246, 0.1);
    background: rgba(10, 14, 26, 0.95);
}

.login-box button {
    width: 100%;
    padding: 16px;
    margin-top: 10px;
    background: linear-gradient(135deg, #3b82f6, #8b5cf6);
    border: none;
    border-radius: 14px;
    color: white;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Inter', sans-serif;
    position: relative;
    overflow: hidden;
}

.login-box button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.login-box button:hover::before {
    left: 100%;
}

.login-box button:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 40px rgba(59, 130, 246, 0.4);
}

.login-box button:active {
    transform: translateY(0);
}

.login-box .error {
    display: none;
    margin-top: 15px;
    padding: 12px;
    background: rgba(255, 71, 87, 0.1);
    border: 1px solid rgba(255, 71, 87, 0.3);
    border-radius: 10px;
    color: #ff4757;
    font-size: 13px;
    font-weight: 500;
    animation: errorPulse 0.3s ease;
}

@keyframes errorPulse {
    0% { transform: scale(0.95); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

/* Stats preview */
.stats-preview {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-top: 30px;
    padding-top: 25px;
    border-top: 1px solid rgba(42, 49, 66, 0.5);
}

.stat-item {
    text-align: center;
    padding: 12px 8px;
    background: rgba(10, 14, 26, 0.5);
    border-radius: 12px;
    border: 1px solid rgba(42, 49, 66, 0.3);
    transition: all 0.3s;
}

.stat-item:hover {
    border-color: rgba(59, 130, 246, 0.3);
    transform: translateY(-2px);
}

.stat-item .stat-icon {
    font-size: 22px;
    display: block;
    margin-bottom: 6px;
}

.stat-item .stat-val {
    display: block;
    font-size: 18px;
    font-weight: 800;
    color: #3b82f6;
    font-family: 'Courier New', monospace;
}

.stat-item .stat-label {
    display: block;
    font-size: 11px;
    color: #64748b;
    margin-top: 4px;
}

/* Balance toggle */
.balance-toggle {
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border);
}

.balance-label {
    display: block;
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 10px;
    font-weight: 500;
}

.toggle-group {
    display: flex;
    gap: 8px;
}

.toggle-btn {
    flex: 1;
    padding: 10px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text-secondary);
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    font-family: 'Inter', sans-serif;
}

.toggle-btn:hover {
    border-color: var(--accent-blue);
    color: var(--text-primary);
}

.toggle-btn.active {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.2), rgba(139, 92, 246, 0.2));
    border-color: var(--accent-blue);
    color: var(--accent-blue);
}

/* Balance display */
.balance-display {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 16px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
}

.balance-mode {
    font-size: 12px;
    font-weight: 600;
    padding: 4px 10px;
    background: rgba(0, 212, 170, 0.15);
    color: var(--accent-green);
    border-radius: 6px;
}

.balance-amount {
    font-family: 'Courier New', monospace;
    font-weight: 700;
    font-size: 15px;
    color: var(--text-primary);
}

/* Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    padding: 20px;
    backdrop-filter: blur(10px);
}

.modal-box {
    background: linear-gradient(145deg, var(--bg-card), var(--bg-secondary));
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 40px;
    max-width: 450px;
    width: 100%;
    text-align: center;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.5);
}

.modal-icon {
    font-size: 48px;
    margin-bottom: 15px;
}

.modal-box h3 {
    font-size: 20px;
    margin-bottom: 10px;
    color: var(--accent-yellow);
}

.modal-box p {
    color: var(--text-secondary);
    font-size: 14px;
    margin-bottom: 15px;
}

.modal-warning {
    background: rgba(255, 71, 87, 0.1);
    border: 1px solid rgba(255, 71, 87, 0.3);
    border-radius: 12px;
    padding: 15px;
    margin: 20px 0;
    text-align: right;
}

.modal-warning p {
    margin: 5px 0;
    font-size: 13px;
    color: var(--text-primary);
}

.modal-stats {
    background: rgba(59, 130, 246, 0.1);
    border-radius: 12px;
    padding: 15px;
    margin: 15px 0;
}

.modal-actions {
    display: flex;
    gap: 12px;
    margin-top: 25px;
}

.modal-btn {
    flex: 1;
    padding: 14px;
    border: none;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    font-family: 'Inter', sans-serif;
}

.modal-btn.confirm {
    background: linear-gradient(135deg, var(--accent-red), #dc2626);
    color: white;
}

.modal-btn.confirm:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(255, 71, 87, 0.3);
}

.modal-btn.cancel {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    color: var(--text-secondary);
}

.modal-btn.cancel:hover {
    border-color: var(--text-primary);
    color: var(--text-primary);
}

/* Stats grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
}

.stat-card {
    text-align: center;
    padding: 30px 20px;
    transition: all 0.3s;
}

.stat-card:hover {
    transform: translateY(-5px);
    border-color: var(--accent-blue);
}

.stat-card.win:hover {
    border-color: var(--accent-green);
}

.stat-card.loss:hover {
    border-color: var(--accent-red);
}

.stat-icon-big {
    font-size: 36px;
    margin-bottom: 15px;
}

.stat-value {
    font-size: 32px;
    font-weight: 800;
    font-family: 'Courier New', monospace;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.stat-card.win .stat-value {
    color: var(--accent-green);
}

.stat-card.loss .stat-value {
    color: var(--accent-red);
}

.stat-label-big {
    font-size: 13px;
    color: var(--text-secondary);
    font-weight: 500;
}

/* Export button */
.export-btn {
    padding: 14px 30px;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.3s;
    border: none;
    background: linear-gradient(135deg, var(--accent-green), #059669);
    color: white;
    font-family: 'Inter', sans-serif;
}

.export-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0, 212, 170, 0.3);
}

/* Chart card */
.chart-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 20px;
    height: 650px;
}

#tradingview-chart {
    width: 100%;
    height: 100%;
    border-radius: 12px;
    overflow: hidden;
}

.coin-selector select {
    padding: 12px 20px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    color: var(--text-primary);
    font-size: 14px;
    font-family: 'Inter', sans-serif;
    outline: none;
    cursor: pointer;
    min-width: 200px;
}

.coin-selector select:focus {
    border-color: var(--accent-blue);
}

/* Loading dots */
.loading-dots {
    text-align: center;
    padding: 40px;
    color: var(--text-secondary);
    font-size: 14px;
}

/* Responsive login */
@media (max-width: 520px) {
    .login-box {
        padding: 35px 25px;
        max-width: 100%;
    }

    .login-box h1 {
        font-size: 26px;
    }

    .stats-preview {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .stat-item {
        display: flex;
        align-items: center;
        justify-content: space-between;
        text-align: right;
    }

    .stat-item .stat-icon {
        margin-bottom: 0;
        margin-left: 10px;
    }
}