/* ═══════════════════════════════════════════
   Veloveer — Komplettes Stylesheet v3.0
   Common + Header + Dashboard + Modal + Notifications + Tooltips + Login
   ═══════════════════════════════════════════ */

/* ═══════════════ VARIABLEN ═══════════════ */

:root {
    --bg: #0f172a;
    --surface: #1e293b;
    --surface2: #334155;
    --border: #475569;
    --text: #e2e8f0;
    --text-muted: #94a3b8;
    --accent: #38bdf8;
    --green: #22c55e;
    --red: #ef4444;
    --orange: #f97316;
    --yellow: #eab308;
    --purple: #a78bfa;
    --mono: 'Cascadia Code', 'Fira Code', Consolas, monospace;
}

[x-cloak] { display: none !important; }
* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    background: var(--bg);
    color: var(--text);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* ═══════════════ HEADER ═══════════════ */

.vv-header {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    padding: 0 20px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-shrink: 0;
}

.vv-header-left { display: flex; align-items: center; gap: 12px; }

.vv-brand { font-size: 17px; font-weight: 700; letter-spacing: 1px; text-decoration: none; flex-shrink: 0; }
.vv-brand .velo { color: var(--accent); }
.vv-brand .veer { color: var(--text); }

.vv-badge-mode {
    font-size: 10px; font-weight: 700; padding: 2px 8px; border-radius: 4px;
    text-transform: uppercase; letter-spacing: 0.8px; flex-shrink: 0;
}
.vv-badge-sim { background: rgba(56,189,248,0.12); color: var(--accent); }
.vv-badge-live { background: rgba(249,115,22,0.15); color: var(--orange); }

.vv-header-sep { width: 1px; height: 24px; background: var(--border); flex-shrink: 0; }

.vv-nav { display: flex; gap: 2px; }
.vv-nav-item {
    display: flex; align-items: center; gap: 6px;
    color: var(--text-muted); text-decoration: none; font-size: 13px; font-weight: 500;
    padding: 6px 14px; border-radius: 6px; transition: all 0.15s; white-space: nowrap;
}
.vv-nav-item:hover { color: var(--text); background: var(--surface2); }
.vv-nav-item.active { color: var(--accent); background: rgba(56,189,248,0.1); }
.vv-nav-icon { display: inline-flex; align-items: center; width: 18px; height: 18px; }

.vv-header-right { display: flex; align-items: center; gap: 12px; }

.vv-profile-link {
    display: flex; align-items: center; gap: 8px; text-decoration: none;
    padding: 4px 10px; border-radius: 6px; transition: all 0.15s;
}
.vv-profile-link:hover { background: var(--surface2); }
.vv-profile-link.active { background: rgba(56,189,248,0.1); }

.vv-avatar {
    width: 28px; height: 28px; border-radius: 50%; background: var(--surface2);
    border: 2px solid var(--border); display: flex; align-items: center; justify-content: center;
    overflow: hidden; flex-shrink: 0; transition: border-color 0.15s;
}
.vv-profile-link:hover .vv-avatar,
.vv-profile-link.active .vv-avatar { border-color: var(--accent); }
.vv-avatar img { width: 100%; height: 100%; object-fit: cover; }
.vv-avatar-initials { font-size: 12px; font-weight: 700; color: var(--accent); line-height: 1; }
.vv-user-email { font-size: 12px; color: var(--text-muted); }

.vv-btn-logout {
    background: none; border: 1px solid var(--border); border-radius: 6px;
    color: var(--text-muted); font-size: 11px; padding: 4px 10px; text-decoration: none; transition: all 0.15s;
}
.vv-btn-logout:hover { border-color: var(--red); color: var(--red); }

/* ═══════════════ LAYOUT ═══════════════ */

.layout {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 16px;
    padding: 16px;
    flex: 1;
    overflow: hidden;
}

.main { display: flex; flex-direction: column; gap: 16px; overflow-y: auto; }
.sidebar { display: flex; flex-direction: column; gap: 12px; overflow-y: auto; }
.sidebar .card { padding: 14px 16px; }
.sidebar .card-label { font-size: 9px; margin-bottom: 8px; }

/* ═══════════════ CARDS ═══════════════ */

.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 16px 18px;
    flex-shrink: 0;
}

.card-label {
    font-size: 10px; font-weight: 600; color: var(--text-muted);
    text-transform: uppercase; letter-spacing: 1.5px; margin-bottom: 10px;
}

.card-label-hint { font-size: 9px; font-weight: 400; text-transform: none; letter-spacing: 0; }

/* ═══════════════ TOP ROW ═══════════════ */

.top-row { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 16px; }

/* ═══════════════ PRICE ═══════════════ */

.price-main {
    font-family: var(--mono); font-size: 30px; font-weight: 700; color: var(--accent);
}
.price-details { display: flex; gap: 16px; margin-top: 6px; font-size: 12px; color: var(--text-muted); }
.price-details span { font-family: var(--mono); }
.price-ask { color: var(--green); }
.price-time { font-size: 10px; color: var(--text-muted); margin-top: 6px; }
.sparkline-wrap { margin-top: 8px; }
.sparkline-wrap canvas { width: 100%; height: 60px; border-radius: 6px; }

/* ═══════════════ SIGNAL ═══════════════ */

.signal-direction { font-size: 22px; font-weight: 700; margin-bottom: 6px; }
.signal-buy { color: var(--green); }
.signal-sell { color: var(--red); }
.signal-hold { color: var(--yellow); }
.confidence-bar { height: 5px; background: var(--surface2); border-radius: 3px; overflow: hidden; margin: 8px 0; }
.confidence-fill { height: 100%; border-radius: 3px; transition: width 0.5s; }
.signal-reason { font-size: 12px; color: var(--text-muted); line-height: 1.5; }
.signal-age { font-size: 10px; color: var(--text-muted); margin-top: 6px; }

/* ═══════════════ ACCOUNT ═══════════════ */

.account-balance { font-family: var(--mono); font-size: 24px; font-weight: 700; }
.account-details { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-top: 10px; }
.account-item { font-size: 12px; }
.account-item .label { color: var(--text-muted); font-size: 10px; }
.account-item .val { font-family: var(--mono); font-size: 13px; }

/* ═══════════════ ACTIONS ═══════════════ */

.actions-row { display: flex; gap: 10px; }
.btn-trade {
    flex: 1; padding: 14px; border: none; border-radius: 8px;
    font-size: 15px; font-weight: 700; cursor: pointer;
    letter-spacing: 1px; transition: all 0.15s; font-family: inherit;
}
.btn-trade:active { transform: scale(0.97); }
.btn-buy { background: var(--green); color: #fff; }
.btn-buy:hover { background: #16a34a; }
.btn-sell { background: var(--red); color: #fff; }
.btn-sell:hover { background: #dc2626; }
.btn-close-all { background: var(--surface2); color: var(--text); border: 1px solid var(--border); }
.btn-close-all:hover { border-color: var(--orange); color: var(--orange); }

/* ═══════════════ MARKET HOURS ═══════════════ */

.market-row {
    display: flex; justify-content: space-between; align-items: center;
    padding: 5px 0; border-bottom: 1px solid rgba(71,85,105,0.3); font-size: 12px;
}
.market-row:last-child { border-bottom: none; }
.market-left { display: flex; align-items: center; gap: 8px; }
.market-name { color: var(--text); font-weight: 500; }
.market-time { color: var(--text-muted); font-family: var(--mono); font-size: 11px; }
.market-status { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.market-open { background: var(--green); box-shadow: 0 0 6px rgba(34,197,94,0.4); }
.market-soon { background: var(--yellow); box-shadow: 0 0 6px rgba(234,179,8,0.4); animation: pulse-soon 1.5s infinite; }
@keyframes pulse-soon { 0%,100% { opacity: 1; } 50% { opacity: 0.4; } }
.market-closed { background: var(--red); opacity: 0.5; }
.market-countdown { font-size: 10px; color: var(--yellow); font-weight: 600; font-family: var(--mono); }

/* ═══════════════ DAY STATS ═══════════════ */

.stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.stat-item { background: var(--surface2); border-radius: 8px; padding: 10px 12px; text-align: center; }
.stat-item .stat-val { font-family: var(--mono); font-size: 18px; font-weight: 700; }
.stat-item .stat-lbl { font-size: 9px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 1px; margin-top: 2px; }

/* ═══════════════ SIGNAL HISTORY ═══════════════ */

.sig-hist-item {
    display: flex; justify-content: space-between; align-items: center;
    padding: 4px 0; border-bottom: 1px solid rgba(71,85,105,0.3); font-size: 11px;
}
.sig-hist-item:last-child { border-bottom: none; }
.sig-badge { font-size: 10px; font-weight: 700; padding: 1px 8px; border-radius: 3px; text-transform: uppercase; }
.sig-badge-buy { background: rgba(34,197,94,0.15); color: var(--green); }
.sig-badge-sell { background: rgba(239,68,68,0.15); color: var(--red); }
.sig-badge-hold { background: rgba(234,179,8,0.15); color: var(--yellow); }

/* ═══════════════ TOP PAIRS ═══════════════ */

.pair-row {
    display: flex; justify-content: space-between; align-items: center;
    padding: 5px 0; border-bottom: 1px solid rgba(71,85,105,0.3); font-size: 11px; cursor: default;
}
.pair-row:last-child { border-bottom: none; }
.pair-row:hover { background: rgba(56,189,248,0.04); margin: 0 -16px; padding: 5px 16px; }
.pair-rank {
    font-size: 10px; font-weight: 700; color: var(--bg); background: var(--accent);
    width: 18px; height: 18px; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.pair-rank.gold { background: #eab308; }
.pair-rank.silver { background: #94a3b8; }
.pair-rank.bronze { background: #cd7f32; }
.pair-left { display: flex; align-items: center; gap: 8px; }
.pair-name { font-weight: 600; color: var(--text); }
.pair-score { font-family: var(--mono); font-size: 11px; color: var(--accent); }
.pair-meta { font-size: 10px; color: var(--text-muted); text-align: right; line-height: 1.4; }
.pair-trend-up { color: var(--green); }
.pair-trend-down { color: var(--red); }
.pair-trend-flat { color: var(--text-muted); }

.pair-actions { display: flex; gap: 4px; margin-top: 4px; }
.pair-btn-watch {
    background: var(--surface2); border: 1px solid var(--border); border-radius: 4px;
    color: var(--accent); font-size: 9px; padding: 2px 6px; cursor: pointer; font-family: inherit;
}
.pair-btn-trade {
    background: var(--green); border: none; border-radius: 4px;
    color: #fff; font-size: 9px; padding: 2px 6px; cursor: pointer; font-family: inherit;
}
.pair-limit-hint { font-size: 9px; color: var(--text-muted); }
.pair-status-active { font-size: 9px; color: var(--green); margin-top: 3px; }
.pair-status-watched { font-size: 9px; color: var(--accent); margin-top: 3px; }

/* ═══════════════ WATCHLIST CARDS ═══════════════ */

.wl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.wl-card { background: var(--surface); border: 1px solid var(--border); border-radius: 10px; padding: 14px 16px; }
.wl-card-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.wl-card-pair { font-size: 14px; font-weight: 600; }
.wl-card-price { font-family: var(--mono); font-size: 20px; font-weight: 700; color: var(--accent); }
.wl-card-details { display: flex; gap: 12px; font-size: 11px; color: var(--text-muted); margin-top: 4px; }
.wl-card-actions { display: flex; gap: 6px; margin-top: 10px; }
.wl-btn-activate {
    flex: 1; background: var(--green); border: none; border-radius: 6px;
    color: #fff; font-size: 11px; font-weight: 600; padding: 6px;
    cursor: pointer; transition: all 0.15s; font-family: inherit;
}
.wl-btn-activate:hover { background: #16a34a; }
.wl-btn-remove {
    background: none; border: 1px solid var(--border); border-radius: 6px;
    color: var(--text-muted); font-size: 11px; padding: 6px 10px;
    cursor: pointer; transition: all 0.15s; font-family: inherit;
}
.wl-btn-remove:hover { border-color: var(--red); color: var(--red); }

/* ═══════════════ SYSTEM INFO ═══════════════ */

.system-info { font-size: 11px; color: var(--text-muted); line-height: 1.8; }
.system-active { color: var(--green); }
.system-last { margin-top: 6px; }

/* ═══════════════ TABLES ═══════════════ */

.data-table { width: 100%; border-collapse: collapse; font-size: 12px; margin-top: 6px; }
.data-table th {
    text-align: left; padding: 6px 10px; font-size: 10px; color: var(--text-muted);
    text-transform: uppercase; letter-spacing: 0.8px; border-bottom: 1px solid var(--border);
}
.data-table td {
    padding: 6px 10px; border-bottom: 1px solid rgba(71,85,105,0.4);
    font-family: var(--mono); font-size: 12px;
}
.data-table tbody tr:hover { background: rgba(56,189,248,0.03); }
.data-empty { text-align: center; padding: 20px; color: var(--text-muted); font-size: 13px; }
.td-time { font-family: inherit !important; font-size: 11px !important; }

.btn-close-trade {
    background: none; border: 1px solid var(--border); border-radius: 4px;
    color: var(--text-muted); padding: 2px 6px; cursor: pointer; font-size: 10px;
    font-family: inherit; transition: all 0.15s;
}
.btn-close-trade:hover { border-color: var(--red); color: var(--red); }

/* ═══════════════ BADGES ═══════════════ */

.badge-sm {
    display: inline-block; font-size: 9px; font-weight: 600;
    padding: 1px 6px; border-radius: 3px; text-transform: uppercase;
    letter-spacing: 0.5px; vertical-align: middle;
}
.badge-major { background: rgba(56,189,248,0.12); color: var(--accent); }
.badge-minor { background: rgba(167,139,250,0.12); color: var(--purple); }
.badge-exotic { background: rgba(249,115,22,0.12); color: var(--orange); }

/* ═══════════════ P&L ═══════════════ */

.pnl-pos { color: var(--green); }
.pnl-neg { color: var(--red); }

/* ═══════════════ DOTS ═══════════════ */

.dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 5px; }
.dot-green { background: var(--green); }
.dot-red { background: var(--red); }

/* ═══════════════ COMMON BUTTONS ═══════════════ */

.btn-primary {
    background: var(--accent); color: var(--bg); border: none; border-radius: 6px;
    padding: 10px 20px; font-size: 13px; font-weight: 700; font-family: inherit;
    cursor: pointer; transition: all 0.15s;
}
.btn-primary:hover { background: #7dd3fc; }

.btn-reset-sm {
    background: var(--surface2); border: 1px solid var(--border); border-radius: 6px;
    color: var(--text-muted); font-size: 14px; width: 28px; height: 28px;
    cursor: pointer; padding: 0; display: inline-flex; align-items: center; justify-content: center;
    transition: all 0.15s; vertical-align: middle; margin-left: 6px; font-family: inherit;
}
.btn-reset-sm:hover { border-color: var(--accent); color: var(--accent); background: rgba(56,189,248,0.08); }

/* ═══════════════ FORMS ═══════════════ */

.form-group { margin-bottom: 14px; }
.form-group label {
    display: block; font-size: 12px; font-weight: 600; color: var(--text-muted);
    text-transform: uppercase; letter-spacing: 1px; margin-bottom: 4px;
}
.form-input {
    width: 100%; padding: 8px 12px; background: var(--bg); border: 1px solid var(--border);
    border-radius: 6px; color: var(--text); font-size: 14px; font-family: inherit;
    outline: none; transition: border-color 0.15s;
}
.form-input:focus { border-color: var(--accent); }
.form-input-mono { font-family: var(--mono); }
.form-input-error { border-color: var(--red); }
.form-error { font-size: 11px; color: var(--red); margin-top: 4px; }

/* ═══════════════ TOGGLE ═══════════════ */

.toggle {
    position: relative; width: 34px; height: 18px;
    background: var(--surface2); border-radius: 9px; cursor: pointer;
    transition: background 0.2s; border: 1px solid var(--border);
    display: inline-block; vertical-align: middle;
}
.toggle.on { background: var(--green); border-color: var(--green); }
.toggle::after {
    content: ''; position: absolute; top: 2px; left: 2px;
    width: 12px; height: 12px; border-radius: 50%; background: #fff; transition: transform 0.2s;
}
.toggle.on::after { transform: translateX(16px); }

/* ═══════════════ MESSAGES ═══════════════ */

.msg { padding: 10px 14px; border-radius: 6px; font-size: 13px; margin-bottom: 16px; }
.msg-ok { background: rgba(34,197,94,0.1); border: 1px solid var(--green); color: var(--green); }
.msg-error { background: rgba(239,68,68,0.1); border: 1px solid var(--red); color: var(--red); }
.msg-info { background: rgba(56,189,248,0.1); border: 1px solid var(--accent); color: var(--accent); }

/* ═══════════════ SECTIONS ═══════════════ */

.section { margin-bottom: 32px; }
.section-title {
    font-size: 14px; font-weight: 600; text-transform: uppercase;
    letter-spacing: 1.5px; color: var(--accent); margin-bottom: 14px;
    padding-bottom: 8px; border-bottom: 1px solid var(--border);
}

.info-box {
    font-size: 12px; color: var(--text-muted); line-height: 1.6;
    padding: 12px 16px; background: rgba(59,130,246,0.06);
    border-left: 3px solid #3b82f6; border-radius: 0 8px 8px 0; margin-bottom: 16px;
}
.hint {
    font-size: 12px; color: var(--text-muted); line-height: 1.6;
    padding: 12px 16px; background: rgba(249,115,22,0.06);
    border-left: 3px solid var(--orange); border-radius: 0 8px 8px 0; margin-top: 12px;
}
.hint strong { color: var(--orange); }

/* ═══════════════ CONFIG ROWS ═══════════════ */

.tt-config-row {
    display: flex; justify-content: space-between; align-items: center;
    padding: 8px 0; border-bottom: 1px solid rgba(71,85,105,0.3); font-size: 13px;
}
.tt-config-row:last-child { border-bottom: none; }
.tt-config-label { color: var(--text); font-weight: 600; }
.tt-config-desc { font-size: 11px; color: var(--text-muted); margin-top: 2px; }

/* ═══════════════ TOAST ═══════════════ */

.toast {
    position: fixed; bottom: 20px; right: 20px;
    background: var(--surface); border: 1px solid var(--border); border-radius: 8px;
    padding: 12px 18px; font-size: 13px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.4);
    transform: translateY(100px); opacity: 0; transition: all 0.3s; z-index: 100;
}
.toast.show { transform: translateY(0); opacity: 1; }
.toast-success { border-color: var(--green); color: var(--green); }
.toast-error { border-color: var(--red); color: var(--red); }

/* ═══════════════ SPINNER ═══════════════ */

.spinner {
    display: inline-block; width: 16px; height: 16px;
    border: 2px solid rgba(15,23,42,0.3); border-top-color: #0f172a;
    border-radius: 50%; animation: spin 0.6s linear infinite;
    vertical-align: middle; margin-right: 8px;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ═══════════════ MONO ═══════════════ */

.mono { font-family: var(--mono); }

/* ═══════════════ MODAL ═══════════════ */

.vv-modal-overlay {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(15,23,42,0.8); backdrop-filter: blur(4px);
    z-index: 10000; display: flex; align-items: center; justify-content: center;
    padding: 20px; opacity: 0; transition: opacity 0.2s;
}
.vv-modal-overlay.show { opacity: 1; }

.vv-modal {
    background: var(--surface); border: 1px solid var(--border); border-radius: 14px;
    padding: 28px 32px 24px; max-width: 420px; width: 100%;
    box-shadow: 0 16px 48px rgba(0,0,0,0.5);
    transform: scale(0.95) translateY(10px); transition: transform 0.2s; text-align: center;
}
.vv-modal-overlay.show .vv-modal { transform: scale(1) translateY(0); }

.vv-modal-icon { margin-bottom: 16px; }
.vv-modal-title { font-size: 17px; font-weight: 700; color: var(--text); margin-bottom: 8px; }
.vv-modal-danger .vv-modal-title { color: var(--red); }
.vv-modal-message { font-size: 14px; color: var(--text-muted); line-height: 1.6; margin-bottom: 24px; }
.vv-modal-buttons { display: flex; gap: 10px; justify-content: center; }
.vv-modal-buttons button {
    padding: 10px 24px; border-radius: 8px; font-size: 14px; font-weight: 600;
    font-family: inherit; cursor: pointer; transition: all 0.15s; border: none; min-width: 110px;
}
.vv-modal-buttons button:focus { outline: 2px solid var(--accent); outline-offset: 2px; }
.vv-modal-btn-primary { background: var(--accent); color: var(--bg); }
.vv-modal-btn-primary:hover { background: #7dd3fc; }
.vv-modal-btn-danger { background: var(--red); color: #fff; }
.vv-modal-btn-danger:hover { background: #dc2626; }
.vv-modal-soft .vv-modal { max-width: 360px; padding: 22px 28px 20px; }
.vv-modal-soft .vv-modal-title { font-size: 15px; color: var(--text-muted); }
.vv-modal-soft .vv-modal-message { font-size: 13px; margin-bottom: 18px; }
.vv-modal-btn-soft { background: var(--surface2); color: var(--text); border: 1px solid var(--border); }
.vv-modal-btn-soft:hover { background: var(--border); }
.vv-modal-btn-cancel { background: var(--surface2); color: var(--text-muted); border: 1px solid var(--border); }
.vv-modal-btn-cancel:hover { color: var(--text); border-color: var(--text-muted); }
.vv-modal-reveal { text-align: left; max-width: 460px; }
.vv-modal-reveal .vv-modal-icon { text-align: center; }

/* ═══════════════ NOTIFICATIONS ═══════════════ */

#vv-notify-container {
    position: fixed; top: 60px; right: 16px; z-index: 9000;
    display: flex; flex-direction: column; gap: 8px; max-width: 380px; pointer-events: none;
}
.vv-notification {
    background: var(--surface); border: 1px solid var(--border); border-radius: 10px;
    padding: 14px 16px; display: flex; gap: 12px; align-items: flex-start;
    box-shadow: 0 8px 32px rgba(0,0,0,0.5); pointer-events: auto;
    transform: translateX(400px); opacity: 0; transition: all 0.3s ease;
}
.vv-notification.show { transform: translateX(0); opacity: 1; }
.vv-notify-signal { border-left: 4px solid var(--green); }
.vv-notify-market { border-left: 4px solid var(--accent); }
.vv-notify-price { border-left: 4px solid var(--yellow); }
.vv-notify-warning { border-left: 4px solid var(--red); }
.vv-notify-info { border-left: 4px solid var(--purple); }
.notify-icon { font-size: 24px; flex-shrink: 0; width: 32px; text-align: center; }
.notify-body { flex: 1; min-width: 0; }
.notify-title { font-size: 13px; font-weight: 700; color: var(--text); margin-bottom: 4px; }
.vv-notify-signal .notify-title { color: var(--green); }
.vv-notify-market .notify-title { color: var(--accent); }
.vv-notify-price .notify-title { color: var(--yellow); }
.vv-notify-warning .notify-title { color: var(--red); }
.notify-msg { font-size: 12px; color: var(--text-muted); line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.notify-time { font-size: 10px; color: var(--border); margin-top: 4px; }
.notify-close { background: none; border: none; color: var(--border); font-size: 18px; cursor: pointer; padding: 0 4px; line-height: 1; flex-shrink: 0; transition: color 0.15s; }
.notify-close:hover { color: var(--text); }
.notify-badge {
    background: var(--red); color: #fff; font-size: 10px; font-weight: 700;
    min-width: 20px; height: 20px; border-radius: 10px;
    display: flex; align-items: center; justify-content: center; padding: 0 6px;
    cursor: pointer; transition: all 0.15s;
}
.notify-badge:hover { background: #dc2626; }

/* ═══════════════ TOOLTIPS ═══════════════ */

#vv-tooltip {
    position: fixed; z-index: 9999; max-width: 340px;
    background: var(--surface); border: 1px solid var(--accent); border-radius: 10px;
    padding: 14px 18px; box-shadow: 0 8px 32px rgba(0,0,0,0.5);
    pointer-events: none; opacity: 0; transform: translateY(4px);
    transition: opacity 0.15s, transform 0.15s;
}
#vv-tooltip.visible { opacity: 1; transform: translateY(0); }
.vv-tt-title { font-size: 13px; font-weight: 700; color: var(--accent); margin-bottom: 6px; }
.vv-tt-text { font-size: 12px; color: var(--text); line-height: 1.6; }
[data-tt] { cursor: help; border-bottom: 1px dotted rgba(56,189,248,0.3); }
[data-tt]:hover { border-bottom-color: var(--accent); }
[data-tt].tt-disabled { cursor: default; border-bottom: none; }

/* ═══════════════ LOGIN ═══════════════ */

.login-page { display: flex; align-items: center; justify-content: center; min-height: 100vh; }
.login-box {
    background: var(--surface); border: 1px solid var(--border); border-radius: 12px;
    padding: 40px; width: 440px; max-width: 90vw;
}
.login-brand { color: var(--accent); font-size: 28px; text-align: center; margin-bottom: 4px; }
.login-sub { color: var(--text-muted); text-align: center; font-size: 14px; margin-bottom: 32px; }

.input-with-toggle { position: relative; }
.input-with-toggle .form-input { padding-right: 44px; }
.pw-toggle {
    position: absolute; right: 8px; top: 50%; transform: translateY(-50%);
    background: none; border: none; cursor: pointer; color: var(--text-muted);
    padding: 4px; display: flex; align-items: center; transition: color 0.15s;
}
.pw-toggle:hover { color: var(--accent); }

.alert-error {
    display: none; background: rgba(239,68,68,0.1); border: 1px solid var(--red);
    border-radius: 8px; padding: 10px 14px; color: var(--red); font-size: 13px; margin-bottom: 16px;
}
.alert-success {
    display: none; background: rgba(34,197,94,0.1); border: 1px solid var(--green);
    border-radius: 8px; padding: 10px 14px; color: var(--green); font-size: 13px; margin-bottom: 16px;
}

.login-footer { text-align: center; margin-top: 16px; font-size: 13px; }
.login-footer a { color: var(--accent); text-decoration: none; white-space: nowrap; }
.login-footer a:hover { text-decoration: underline; }
.login-sep { color: var(--border); margin: 0 10px; }
.login-info { color: var(--text-muted); font-size: 13px; line-height: 1.6; margin-bottom: 20px; }
.login-info strong { color: var(--accent); font-family: var(--mono); }
.login-view-hidden { display: none; }

.generator-output {
    display: flex; align-items: center; gap: 12px;
    background: var(--bg); border: 1px solid var(--border); border-radius: 8px;
    padding: 14px 18px; margin-bottom: 16px;
}
.generated-passphrase { flex: 1; font-family: var(--mono); font-size: 18px; font-weight: 700; color: var(--accent); letter-spacing: 0.5px; }
.generator-actions { margin-bottom: 12px; }

.btn-sm {
    padding: 5px 12px; font-size: 12px; font-weight: 600;
    background: var(--surface2); color: var(--text-muted);
    border: 1px solid var(--border); border-radius: 6px;
    cursor: pointer; font-family: inherit; transition: all 0.15s;
}
.btn-sm:hover { background: var(--border); color: var(--text); }

.btn-block { display: block; width: 100%; }

/* ═══════════════ RESPONSIVE ═══════════════ */

@media (max-width: 1100px) { .layout { grid-template-columns: 1fr 280px; } }
@media (max-width: 900px) {
    .layout { grid-template-columns: 1fr; }
    .sidebar { flex-direction: row; flex-wrap: wrap; overflow-y: visible; }
    .sidebar .card { flex: 1; min-width: 250px; }
    .top-row { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
    .vv-header { padding: 0 12px; height: 46px; }
    .vv-brand { font-size: 14px; }
    .vv-nav-item { font-size: 12px; padding: 4px 8px; }
    .vv-nav-icon { display: none; }
    .vv-user-email { display: none; }
    .vv-header-sep { display: none; }
}
@media (max-width: 600px) {
    .layout { padding: 10px; gap: 10px; }
    .price-main { font-size: 24px; }
    .account-balance { font-size: 20px; }
    .actions-row { flex-direction: column; }
    .sidebar { flex-direction: column; }
    .sidebar .card { min-width: auto; }
    .vv-modal { padding: 20px; }
    .vv-modal-buttons { flex-direction: column; }
    .vv-modal-buttons button { min-width: auto; }
    #vv-notify-container { right: 8px; left: 8px; max-width: none; }
}

/* ═══════════════ SETTINGS ═══════════════ */

.settings-layout { display: grid; grid-template-columns: 220px 1fr; min-height: calc(100vh - 52px); }
.settings-nav { background: var(--surface); border-right: 1px solid var(--border); padding: 20px 0; }
.settings-nav-title { font-size: 10px; font-weight: 600; text-transform: uppercase; letter-spacing: 1.5px; color: var(--text-muted); padding: 0 20px; margin-bottom: 10px; }
.settings-nav .nav-item { display: flex; align-items: center; gap: 10px; padding: 10px 20px; cursor: pointer; color: var(--text-muted); font-size: 13px; font-weight: 500; border-left: 3px solid transparent; transition: all 0.15s; text-decoration: none; }
.settings-nav .nav-item:hover { color: var(--text); background: rgba(56,189,248,0.04); }
.settings-nav .nav-item.active { color: var(--accent); border-left-color: var(--accent); background: rgba(56,189,248,0.06); }
.settings-nav .nav-item .nav-icon { font-size: 16px; width: 20px; text-align: center; }
.tab-panel { display: none; }
.tab-panel.active { display: block; }
.container { padding: 24px 32px; }

.pair-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.pair-table th { text-align: left; padding: 8px 10px; font-size: 10px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.8px; border-bottom: 1px solid var(--border); cursor: pointer; user-select: none; transition: color 0.15s; white-space: nowrap; }
.pair-table th:hover { color: var(--accent); }
.pair-table th .sort-icon { font-size: 9px; margin-left: 3px; opacity: 0.4; }
.pair-table th.sorted .sort-icon { opacity: 1; color: var(--accent); }
.pair-table td { padding: 7px 10px; border-bottom: 1px solid rgba(71,85,105,0.3); vertical-align: middle; }
.pair-table tr:hover { background: rgba(56,189,248,0.03); }

.btn-scan { background: var(--accent); color: var(--bg); border: none; border-radius: 8px; padding: 10px 24px; font-size: 14px; font-weight: 700; cursor: pointer; transition: all 0.15s; min-width: 180px; font-family: inherit; }
.btn-scan:hover { background: #7dd3fc; }
.btn-scan:disabled { opacity: 0.7; cursor: not-allowed; }
.status-msg { font-size: 13px; margin-top: 10px; padding: 8px 12px; border-radius: 6px; display: none; }
.status-msg.show { display: block; }
.status-ok { background: rgba(34,197,94,0.1); color: var(--green); }
.status-err { background: rgba(239,68,68,0.1); color: var(--red); }

.sim-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 20px; }
.sim-param { background: var(--surface2); border-radius: 10px; padding: 14px 18px; }
.sim-param-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 4px; }
.sim-param-label { font-size: 13px; font-weight: 600; color: var(--text); }
.sim-param-value { font-family: var(--mono); font-size: 15px; font-weight: 700; color: var(--accent); }
.sim-param-desc { font-size: 11px; color: var(--text-muted); line-height: 1.5; margin-bottom: 8px; }
.sim-slider { width: 100%; -webkit-appearance: none; appearance: none; height: 6px; background: var(--border); border-radius: 3px; outline: none; }
.sim-slider::-webkit-slider-thumb { -webkit-appearance: none; width: 16px; height: 16px; background: var(--accent); border-radius: 50%; cursor: pointer; }
.sim-slider::-moz-range-thumb { width: 16px; height: 16px; background: var(--accent); border-radius: 50%; cursor: pointer; border: none; }
.sim-result { background: var(--surface); border: 2px solid var(--accent); border-radius: 12px; padding: 20px 24px; text-align: center; }
.sim-score-big { font-family: var(--mono); font-size: 48px; font-weight: 700; color: var(--accent); }
.sim-score-label { font-size: 11px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 1.5px; }
.sim-breakdown { display: flex; justify-content: center; gap: 20px; margin-top: 12px; flex-wrap: wrap; }
.sim-part { text-align: center; font-size: 12px; }
.sim-part-val { font-family: var(--mono); font-size: 16px; font-weight: 700; }
.sim-part-lbl { font-size: 10px; color: var(--text-muted); }
.sim-bar { height: 8px; background: var(--surface2); border-radius: 4px; overflow: hidden; margin-top: 16px; }
.sim-bar-inner { display: flex; height: 100%; }
.sim-bar-seg { height: 100%; transition: width 0.3s; }
.sim-example { background: var(--surface2); border-radius: 8px; padding: 14px 18px; font-size: 12px; line-height: 1.8; margin-top: 8px; }
.sim-example strong { color: var(--accent); }
.sim-example .good { color: var(--green); }
.sim-example .bad { color: var(--red); }

.legend-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; font-size: 12px; }
.legend-item { background: var(--surface2); border-radius: 8px; padding: 10px 14px; }
.legend-item strong { color: var(--accent); font-size: 13px; }
.legend-item p { color: var(--text-muted); margin-top: 4px; line-height: 1.5; }

.preset-card { background: var(--surface); border: 1px solid var(--border); border-radius: 10px; padding: 16px 18px; cursor: pointer; transition: all 0.15s; }
.preset-card:hover { border-color: var(--accent); }
.preset-card.preset-active { border-color: var(--accent); background: rgba(56,189,248,0.06); }
.preset-header { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.preset-icon { flex-shrink: 0; display: flex; align-items: center; }
.preset-label { font-size: 15px; font-weight: 700; color: var(--accent); }
.preset-desc { font-size: 12px; color: var(--text-muted); line-height: 1.5; }
.preset-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; }

.row-dimmed { opacity: 0.4; }
.td-pair { font-weight: 600; }
.td-score { color: var(--accent); font-weight: 700; }
.td-warn { color: var(--red); }

.api-key-row { flex-wrap: wrap; gap: 8px; }
.api-key-info { flex: 1; min-width: 150px; }
.api-key-actions { display: flex; gap: 6px; align-items: center; flex-shrink: 0; }
.btn-api-reveal, .btn-api-edit { width: auto !important; padding: 0 10px !important; font-size: 11px !important; height: 28px; white-space: nowrap; }
.api-key-masked { font-size: 11px; color: var(--text-muted); background: var(--surface2); padding: 4px 10px; border-radius: 4px; letter-spacing: 0.5px; font-family: var(--mono); }
.api-key-revealed { display: block; font-size: 12px; color: var(--accent); background: var(--bg); border: 1px solid var(--border); border-radius: 6px; padding: 10px 40px 10px 14px; word-break: break-all; font-family: var(--mono); user-select: all; }
.btn-copy-reveal { position: absolute; top: 8px; right: 8px; background: none; border: none; cursor: pointer; padding: 2px; }
.api-mode-badge { font-size: 12px; font-weight: 600; }
.api-mode-demo { color: var(--accent); }
.api-mode-live { color: var(--orange); }
.model-select { background: var(--surface2); border: 1px solid var(--border); border-radius: 6px; color: var(--accent); font-family: var(--mono); font-size: 12px; padding: 4px 8px; }
.model-hint { font-size: 11px; color: var(--text-muted); padding: 6px 0; line-height: 1.6; }
.api-edit-row { display: flex; gap: 6px; align-items: flex-start; width: 100%; }
.api-edit-label { min-width: 100px; padding-top: 7px; }
.api-edit-fields { flex: 1; }
.api-edit-input-row { display: flex; gap: 6px; align-items: center; }
.api-edit-input { flex: 1; font-size: 12px; }

.wl-settings-row { background: var(--surface2); padding: 8px 14px; border-radius: 8px; display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.wl-settings-name { font-weight: 500; }
.wl-settings-actions { display: flex; gap: 6px; }
.price-alert-row { display: flex; justify-content: space-between; align-items: center; padding: 6px 0; border-bottom: 1px solid rgba(71,85,105,0.3); font-size: 12px; }

@media (max-width: 900px) {
    .settings-layout { grid-template-columns: 1fr; }
    .settings-nav { border-right: none; border-bottom: 1px solid var(--border); padding: 12px 0; display: flex; overflow-x: auto; gap: 0; }
    .settings-nav-title { display: none; }
    .settings-nav .nav-item { border-left: none; border-bottom: 2px solid transparent; padding: 8px 16px; white-space: nowrap; }
    .settings-nav .nav-item.active { border-left: none; border-bottom-color: var(--accent); }
}
@media (max-width: 768px) {
    .container { padding: 16px; }
    .pair-table { font-size: 10px; }
    .legend-grid { grid-template-columns: 1fr; }
    .sim-grid { grid-template-columns: 1fr; }
    .preset-grid { grid-template-columns: 1fr; }
}
