:root{--tp-bg: #f5f7fa;--tp-surface: #ffffff;--tp-surface-2: #f8f9fa;--tp-surface-hover: #f0f0f0;--tp-input-bg: #ffffff;--tp-border: #e0e0e0;--tp-border-soft: #f0f0f0;--tp-text: #2c3e50;--tp-text-strong: #1a1a1a;--tp-text-muted: #6c757d;--tp-shadow: 0 2px 8px rgba(0, 0, 0, .05);--tp-shadow-sm: 0 1px 3px rgba(0, 0, 0, .05);--tp-success-bg: #d1fae5;--tp-success-bg-soft: #f0fdf6;--tp-success-text: #0f7a52;--tp-warning-bg: #fff3cd;--tp-warning-text: #856404;--tp-danger-bg: #ffe0e0;--tp-danger-bg-soft: #fff5f5;--tp-danger-text: #b4232c;--tp-info-bg: #f0f9ff;--tp-info-bg-strong: #dbeafe;--tp-info-text: #0369a1;--tp-amber-bg: #fef3c7;--tp-amber-text: #92400e;--tp-overlay: rgba(0, 0, 0, .6);--tp-green: #15803d;--tp-green-hover: #166534;--tp-pnl-positive: #15803d;--tp-pnl-negative: #d42a35;color-scheme:light}[data-theme=dark]{--tp-bg: #0f141c;--tp-surface: #171d28;--tp-surface-2: #1e2532;--tp-surface-hover: #242c3b;--tp-input-bg: #121822;--tp-border: #2c3445;--tp-border-soft: #232a38;--tp-text: #cfd6e2;--tp-text-strong: #f1f4f9;--tp-text-muted: #8c96a8;--tp-shadow: 0 2px 10px rgba(0, 0, 0, .45);--tp-shadow-sm: 0 1px 3px rgba(0, 0, 0, .5);--tp-success-bg: rgba(22, 199, 132, .16);--tp-success-bg-soft: rgba(22, 199, 132, .08);--tp-success-text: #4ade80;--tp-warning-bg: rgba(245, 158, 11, .14);--tp-warning-text: #fbbf24;--tp-danger-bg: rgba(234, 57, 67, .16);--tp-danger-bg-soft: rgba(234, 57, 67, .08);--tp-danger-text: #f87171;--tp-info-bg: rgba(59, 130, 246, .12);--tp-info-bg-strong: rgba(59, 130, 246, .2);--tp-info-text: #93c5fd;--tp-amber-bg: rgba(245, 158, 11, .15);--tp-amber-text: #fcd34d;--tp-overlay: rgba(0, 0, 0, .75);--tp-green: #16c784;--tp-green-hover: #13a770;--tp-pnl-positive: #34d399;--tp-pnl-negative: #f87171;color-scheme:dark}*{margin:0;padding:0;box-sizing:border-box}body{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,sans-serif;background:var(--tp-bg);color:var(--tp-text)}.layout{min-height:100vh;background:var(--tp-bg)}.header{background:var(--tp-surface);box-shadow:var(--tp-shadow-sm);border-bottom:1px solid var(--tp-border)}.header-container{max-width:1400px;margin:0 auto;padding:16px 20px;display:flex;align-items:center;justify-content:space-between}.header-logo{display:flex;align-items:center;gap:12px}.header-logo-icon{width:40px;height:40px;background:transparent;border-radius:12px;overflow:hidden;display:flex;align-items:center;justify-content:center}.header-logo-icon svg{width:24px;height:24px;color:#fff}.header-title h1{font-size:18px;font-weight:700;color:var(--tp-text-strong);margin-bottom:2px}.header-title p{font-size:12px;color:var(--tp-text-muted)}.header-nav{display:flex;align-items:center;gap:8px}.nav-link{display:flex;align-items:center;gap:8px;padding:8px 16px;border-radius:8px;text-decoration:none;font-size:14px;font-weight:500;color:var(--tp-text-muted);transition:all .2s}.nav-link:hover{background:var(--tp-surface-hover);color:var(--tp-text)}.nav-link.active{background:#3b82f6;color:#fff;box-shadow:0 2px 4px #3b82f64d}.nav-link svg{width:16px;height:16px}.logout-btn{display:flex;align-items:center;gap:8px;padding:8px 16px;border:none;border-radius:8px;background:transparent;color:#ea3943;font-size:14px;font-weight:500;cursor:pointer;transition:all .2s;margin-left:8px}.logout-btn:hover{background:var(--tp-danger-bg)}.theme-toggle{display:flex;align-items:center;gap:8px;padding:8px 14px;border:1px solid var(--tp-border);border-radius:8px;background:var(--tp-surface-2);color:var(--tp-text);font-size:14px;font-weight:500;cursor:pointer;transition:all .2s;margin-left:4px}.theme-toggle svg{width:16px;height:16px}.theme-toggle:hover{background:var(--tp-surface-hover);border-color:#3b82f6}.main-content{max-width:1400px;margin:0 auto;padding:20px}.card{background:var(--tp-surface);border-radius:12px;padding:24px;box-shadow:var(--tp-shadow);margin-bottom:20px}.stat-card{background:var(--tp-surface);padding:20px;border-radius:8px;box-shadow:var(--tp-shadow)}.stats-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:20px;margin-bottom:20px}.stat-label{font-size:12px;color:var(--tp-text-muted);margin-bottom:8px;text-transform:uppercase;font-weight:500;letter-spacing:.5px}.stat-value{font-size:28px;font-weight:600;color:var(--tp-text-strong)}.stat-value.positive{color:var(--tp-green)}.stat-value.negative{color:#ea3943}.stat-value.stat-positive{color:var(--tp-green)}.stat-value.stat-negative{color:#ea3943}.stat-value-secondary{font-size:16px;font-weight:600;margin-left:8px;opacity:.85;white-space:nowrap}.stat-subtitle{font-size:12px;color:var(--tp-text-muted);margin-top:4px}.btn{padding:12px 24px;border:none;border-radius:8px;font-size:14px;font-weight:600;cursor:pointer;transition:all .3s;text-transform:uppercase;letter-spacing:.5px;display:inline-flex;align-items:center;gap:8px}.btn-primary{background:var(--tp-green);color:#fff}.btn-primary:hover{background:var(--tp-green-hover);transform:translateY(-1px);box-shadow:0 4px 12px #16c7844d}.btn-secondary{background:var(--tp-surface);color:var(--tp-text-muted);border:1px solid var(--tp-border)}.btn-secondary:hover{background:var(--tp-surface-2)}.btn-success{background:var(--tp-green);color:#fff}.btn-success:hover{background:var(--tp-green-hover);transform:translateY(-1px)}.btn-danger{background:#ea3943;color:#fff}.btn-danger:hover{background:#d32f2f;transform:translateY(-1px)}.btn:disabled{opacity:.6;cursor:not-allowed}.buttons-row{display:flex;flex-wrap:wrap;gap:12px}.time-filters{display:flex;gap:8px}.time-filter{padding:6px 16px;border:1px solid var(--tp-border);background:var(--tp-surface);border-radius:6px;font-size:13px;cursor:pointer;transition:all .2s}.time-filter.active{background:#3b82f6;color:#fff;border-color:#3b82f6}.time-filter:hover:not(.active){border-color:#3b82f6}.chart-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:20px}.chart-title{font-size:18px;font-weight:600;color:var(--tp-text-strong)}.chart-placeholder{height:300px;display:flex;align-items:center;justify-content:center;background:var(--tp-surface-2);border-radius:8px;color:var(--tp-text-muted);font-size:16px}.stats-row{display:grid;grid-template-columns:300px 1fr;gap:20px;margin-bottom:20px}.stats-grid-2{display:grid;grid-template-columns:repeat(2,1fr);gap:30px}.stat-item{padding:16px 0;border-bottom:1px solid var(--tp-border-soft)}.stat-item:last-child{border-bottom:none}.stat-item-label{font-size:12px;color:var(--tp-text-muted);margin-bottom:8px}.stat-item-value{font-size:24px;font-weight:600}.allocation-placeholder{width:200px;height:200px;margin:0 auto 20px;display:flex;align-items:center;justify-content:center;background:var(--tp-surface-2);border-radius:50%;font-size:48px}.table-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:20px}.table-title{font-size:18px;font-weight:600;color:var(--tp-text-strong)}.search-box{padding:8px 16px;border:1px solid var(--tp-border);border-radius:8px;font-size:14px;width:200px;outline:none;transition:border .2s;background:var(--tp-input-bg);color:var(--tp-text)}.search-box:focus{border-color:#3b82f6;box-shadow:0 0 0 3px #3b82f61a}table{width:100%;border-collapse:collapse}thead th{text-align:left;padding:12px;font-size:12px;font-weight:600;color:var(--tp-text-muted);border-bottom:2px solid var(--tp-border-soft);text-transform:uppercase;letter-spacing:.5px}tbody td{padding:16px 12px;font-size:14px;border-bottom:1px solid var(--tp-border-soft)}tbody tr:hover{background:var(--tp-surface-2)}.trade-side-buy{color:var(--tp-green);font-weight:600}.trade-side-sell{color:#ea3943;font-weight:600}.text-positive{color:var(--tp-green)}.text-negative{color:#ea3943}.status-badges{display:flex;flex-wrap:wrap;gap:20px}.status-badge{display:inline-flex;align-items:center;gap:8px;padding:6px 16px;border-radius:12px;font-size:12px;font-weight:600}.status-online{background:var(--tp-success-bg);color:var(--tp-green)}.status-offline{background:var(--tp-danger-bg);color:#ea3943}.status-dot{width:6px;height:6px;border-radius:50%;background:currentColor}.error-message{background:var(--tp-danger-bg);border:1px solid #ea3943;border-radius:12px;padding:16px;display:flex;align-items:start;gap:12px;margin-bottom:20px}.error-message svg{width:20px;height:20px;color:#ea3943;flex-shrink:0;margin-top:2px}.error-title{font-weight:600;color:#ea3943;margin-bottom:4px}.error-text{color:#ea3943;font-size:14px}.table-title-group{display:flex;align-items:center;gap:10px}.sound-toggle{display:inline-flex;align-items:center;justify-content:center;width:32px;height:32px;border:1px solid var(--tp-border);border-radius:8px;background:var(--tp-surface-2);cursor:pointer;transition:all .2s}.sound-toggle svg{width:16px;height:16px}.sound-toggle.on{color:var(--tp-green);border-color:#16c78480}.sound-toggle.off{color:var(--tp-text-muted)}.sound-toggle.blocked{color:#f59e0b;border-color:#f59e0b99}.sound-toggle:hover{border-color:#3b82f6;background:var(--tp-surface-hover)}.profit-calendar-header{display:flex;justify-content:space-between;align-items:flex-start;gap:16px;margin-bottom:20px}.profit-calendar-label{font-size:11px;font-weight:600;letter-spacing:.06em;text-transform:uppercase;color:var(--tp-text-muted);margin-bottom:8px}.profit-calendar-scale{font-size:12px;color:var(--tp-text-muted);padding:4px 10px;border:1px solid var(--tp-border);border-radius:999px}.profit-calendar-total{font-size:32px;font-weight:700;margin-bottom:20px;display:flex;align-items:baseline;gap:12px}.profit-calendar-total.positive{color:var(--tp-green)}.profit-calendar-total.negative{color:#ea3943}.profit-calendar-trades{font-size:14px;font-weight:500;color:var(--tp-text-muted)}.profit-calendar-empty{height:200px;display:flex;align-items:center;justify-content:center;color:var(--tp-text-muted);border:1px dashed var(--tp-border);border-radius:8px}.date-range{position:relative;display:inline-block}.date-range-field{display:flex;align-items:center;gap:10px;padding:12px 16px;min-width:210px;border:1px solid var(--tp-border);border-radius:10px;background:var(--tp-surface-2);color:var(--tp-text-strong);font-size:15px;cursor:pointer;transition:border-color .2s}.date-range-field:hover,.date-range-field[aria-expanded=true]{border-color:#3b82f6}.date-range-field svg{width:16px;height:16px;color:var(--tp-text-muted)}.date-range-popover{position:absolute;top:calc(100% + 8px);left:0;z-index:50;display:flex;gap:12px;padding:12px;background:var(--tp-surface);border:1px solid var(--tp-border);border-radius:12px;box-shadow:0 12px 32px #0000002e}.date-range-presets{display:flex;flex-direction:column;gap:4px;padding-right:12px;border-right:1px solid var(--tp-border-soft)}.date-range-preset{text-align:left;white-space:nowrap;padding:8px 12px;border:none;border-radius:6px;background:transparent;color:var(--tp-text);font-size:13px;cursor:pointer}.date-range-preset:hover{background:var(--tp-surface-hover)}.date-range-calendar{width:252px}.date-range-nav{display:flex;align-items:center;justify-content:space-between;margin-bottom:8px;font-weight:600;color:var(--tp-text-strong)}.date-range-nav button{display:flex;padding:4px;border:none;border-radius:6px;background:transparent;color:var(--tp-text);cursor:pointer}.date-range-nav button:hover{background:var(--tp-surface-hover)}.date-range-nav svg{width:18px;height:18px}.date-range-grid{display:grid;grid-template-columns:repeat(7,36px);gap:0}.date-range-weekday{text-align:center;font-size:11px;color:var(--tp-text-muted);padding:4px 0}.date-range-day{height:34px;border:none;background:transparent;color:var(--tp-text);font-size:13px;cursor:pointer;border-radius:0}.date-range-day:hover{background:var(--tp-surface-hover)}.date-range-day.today{font-weight:700;text-decoration:underline}.date-range-day.in-range{background:var(--tp-info-bg-strong);color:var(--tp-text-strong)}.date-range-day.edge{background:#3b82f6;color:#fff;border-radius:6px}.date-range-hint{margin-top:8px;font-size:12px;color:var(--tp-text-muted);text-align:center}@media (max-width: 768px){.date-range-popover{flex-direction:column}.date-range-presets{flex-direction:row;flex-wrap:wrap;padding-right:0;border-right:none;border-bottom:1px solid var(--tp-border-soft);padding-bottom:8px}.profit-calendar-total{font-size:26px}}@media (max-width: 1024px){.stats-row{grid-template-columns:1fr}.header-nav span{display:none}}@media (max-width: 768px){.stats-grid,.stats-grid-2{grid-template-columns:1fr}}.bot-controls{display:flex;flex-direction:column;gap:12px}.bot-control{display:flex;align-items:center;justify-content:space-between;gap:16px;flex-wrap:wrap;padding:12px 16px;border:1px solid var(--tp-border-soft);border-radius:10px;background:var(--tp-surface-2)}.bot-control-label{display:flex;align-items:center;gap:10px;font-size:15px;color:var(--tp-text-strong)}.bot-control-state{font-size:13px;color:var(--tp-text-muted)}.bot-dot{width:10px;height:10px;border-radius:50%;display:inline-block}.bot-dot.on{background:var(--tp-green);box-shadow:0 0 0 3px #16c78433}.bot-dot.off{background:var(--tp-text-muted)}.quote-badge{margin-left:8px;font-size:11px;font-weight:600;padding:2px 6px;border-radius:999px;vertical-align:middle}.quote-badge.quote-USDT{background:#16c78426;color:var(--tp-green)}.quote-badge.quote-USDC{background:#2775ca26;color:#2775ca}.positions-layout{display:flex;gap:20px;align-items:flex-start}.positions-table{flex:1 1 auto;min-width:0}.positions-allocations{flex:0 0 300px;padding-left:20px;border-left:1px solid var(--tp-border-soft)}.positions-allocations-title{font-size:12px;font-weight:600;color:var(--tp-text-muted);text-transform:uppercase;letter-spacing:.5px;margin-bottom:8px}@media (max-width: 1000px){.positions-layout{flex-direction:column;align-items:stretch}.positions-allocations{flex-basis:auto;padding-left:0;border-left:none;border-top:1px solid var(--tp-border-soft);padding-top:16px}}@keyframes tp-spin{to{transform:rotate(360deg)}}
