:root {
  --bg: #05070f;
  --panel: #0a1020;
  --panel-2: #0b1226;
  --text: #f6f7fb;
  --muted: #9da9d1;
  --line: rgba(255,255,255,0.08);
  --primary: #3b1dff;
  --success: #39ff14;
  --gold: #ffe600;
  --danger: #ff5f6d;
}
* { box-sizing: border-box; }
body { margin: 0; font-family: Inter, Arial, sans-serif; background: radial-gradient(circle at top left, #0b1330, var(--bg) 35%); color: var(--text); }
a { color: inherit; text-decoration: none; }
input, select, textarea, button { font: inherit; }
input, select, textarea {
  width: 100%; padding: 14px 16px; border-radius: 12px; border: 1px solid var(--line);
  background: #050913; color: var(--text);
}
textarea { min-height: 110px; resize: vertical; }
button, .btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 0; border-radius: 12px; padding: 13px 18px; background: rgba(255,255,255,0.08); color: var(--text); cursor: pointer;
}
.btn.primary { background: linear-gradient(90deg, #2d14df, #5136ff); }
.btn.success { background: rgba(57,255,20,0.18); color: #9dff8e; }
.btn.danger { background: rgba(255,95,109,0.18); color: #ffb0b8; }
.btn.small { padding: 8px 12px; border-radius: 10px; }
.page-title { margin: 0 0 24px; font-size: 2rem; }
.app-shell { display: grid; grid-template-columns: 290px 1fr; min-height: 100vh; }
.sidebar { padding: 24px 16px; border-right: 1px solid var(--line); background: rgba(0,0,0,0.42); }
.brand { font-size: 1.8rem; font-weight: 800; margin-bottom: 24px; }
.wallet-card, .panel, .metric-card, .auth-card { background: linear-gradient(180deg, rgba(9,15,33,0.98), rgba(4,7,17,0.98)); border: 1px solid var(--line); border-radius: 22px; }
.wallet-card { padding: 18px; margin-bottom: 18px; }
.wallet-value { font-size: 2rem; font-weight: 800; margin-top: 6px; }
.nav-links { display: grid; gap: 10px; }
.nav-links a { padding: 14px 16px; border-radius: 14px; color: var(--text); }
.nav-links a.active, .nav-links a:hover { background: linear-gradient(90deg, #2310ab, #3619f3); }
.content { padding: 28px; }
.cards-grid { display: grid; gap: 18px; }
.cards-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.cards-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.layout-main { grid-template-columns: minmax(0, 2fr) minmax(340px, 1fr); align-items: start; }
.metric-card { padding: 24px; min-height: 170px; }
.metric-card.blue { background: linear-gradient(135deg, #0a1030, #06112c 65%, #081f54); }
.metric-card.blue-soft { background: linear-gradient(135deg, #10122c, #091432 70%, #083764); }
.metric-card.green { background: linear-gradient(135deg, #08170d, #08130f 60%, #114e1c); }
.metric-card.gold { background: linear-gradient(135deg, #181404, #121007 60%, #554200); }
.card-title { font-size: 1.05rem; font-weight: 700; margin-bottom: 10px; }
.card-subtitle { font-size: 0.98rem; color: var(--muted); margin-bottom: 10px; }
.card-big { font-size: 2.35rem; font-weight: 800; margin: 18px 0 10px; }
.panel { padding: 22px; }
.panel.compact { padding: 18px; }
.panel-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.panel-header h2, .panel h3 { margin: 0; }
.big-number { font-size: 2rem; font-weight: 800; margin: 10px 0; }
.muted { color: var(--muted); }
.mt-12 { margin-top: 12px; }
.mt-24 { margin-top: 24px; }
.stack-form { display: grid; gap: 14px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.public-shell { min-height: 100vh; padding: 32px; }
.hero { display: grid; grid-template-columns: 1.2fr 1fr; gap: 24px; max-width: 1400px; margin: 0 auto; align-items: start; }
.hero-copy h1 { font-size: 3.4rem; line-height: 1.05; margin: 8px 0 16px; max-width: 900px; }
.hero-copy p { color: var(--muted); font-size: 1.1rem; max-width: 740px; }
.eyebrow { color: #8ca2ff; text-transform: uppercase; letter-spacing: 0.08em; font-size: 0.8rem; }
.cta-row { display: flex; gap: 12px; margin-top: 22px; }
.hero-cards { display: grid; gap: 18px; }
.auth-card { width: min(460px, 100%); margin: 8vh auto; padding: 28px; }
.auth-card.wide { width: min(520px, 100%); }
.flash-wrap { display: grid; gap: 10px; margin-bottom: 18px; }
.flash-wrap.public { max-width: 1200px; margin: 0 auto 18px; }
.flash { padding: 14px 16px; border-radius: 12px; }
.flash.success { background: rgba(57,255,20,0.15); color: #b9ffaf; }
.flash.error { background: rgba(255,95,109,0.18); color: #ffc0c5; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 14px 10px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
th { color: var(--muted); font-weight: 600; }
.inline { display: inline-flex; margin-right: 8px; }
.text-green { color: #7fff63; }
.text-red { color: #ff7f8a; }
.strategy-block { margin-top: 20px; }
.strategy-title { margin-bottom: 12px; color: var(--muted); font-weight: 600; }
.chart-panel canvas, .strategy-block canvas { width: 100% !important; height: 260px !important; }
.stack-col { display: grid; gap: 18px; }
.stats-inline { display: flex; flex-wrap: wrap; gap: 12px; color: var(--muted); font-size: 0.95rem; }
@media (max-width: 1100px) {
  .cards-3, .cards-4, .layout-main, .hero { grid-template-columns: 1fr; }
}
@media (max-width: 800px) {
  .app-shell { grid-template-columns: 1fr; }
  .sidebar { border-right: 0; border-bottom: 1px solid var(--line); }
  .content, .public-shell { padding: 18px; }
  .hero-copy h1 { font-size: 2.3rem; }
  .grid-3 { grid-template-columns: 1fr; }
}
