/* ============================================================
   WINXT clone — design tokens extracted from winxt.com
   ============================================================ */
:root{
  --brand:            #f7a600;   /* primary gold/orange (Sign Up) */
  --brand-hover:      #ffb624;
  --bg-header:        #08080c;   /* header + dark hero */
  --bg-dark:          #0b0b10;
  --bg-dark-2:        #101014;   /* dark app section */
  --bg-light:         #ffffff;
  --bg-light-2:       #f8f8f8;
  --text-dark:        #0d0d12;
  --text-muted:       #6b6f76;
  --text-on-dark:     #ffffff;
  --text-on-dark-dim: rgba(255,255,255,.62);
  --border:           #e8e8ec;
  --border-dark:      rgba(255,255,255,.08);
  --up:               #3ccb7f;   /* positive change */
  --down:             #f1595d;   /* negative change */
  --radius:           5px;
  --radius-lg:        14px;
  --maxw:             1200px;
  --header-h:         65px;
  --font: "Inter", Roboto, -apple-system, BlinkMacSystemFont, "Segoe UI",
          "Helvetica Neue", Arial, sans-serif;
}

*,*::before,*::after{ box-sizing:border-box; }
html,body{ margin:0; padding:0; overflow-x:hidden; }
body{
  font-family:var(--font);
  font-size:16px;
  color:var(--text-dark);
  background:var(--bg-light);
  -webkit-font-smoothing:antialiased;
  line-height:1.5;
}
a{ color:inherit; text-decoration:none; }
img{ max-width:100%; display:block; }
button{ font-family:inherit; cursor:pointer; }

.container{ width:100%; max-width:var(--maxw); margin:0 auto; padding:0 24px; }

/* ---------- Buttons ---------- */
.btn{
  display:inline-flex; align-items:center; justify-content:center;
  height:38px; padding:0 16px; border-radius:var(--radius);
  font-weight:500; font-size:14px; border:1px solid transparent;
  transition:background .18s ease, color .18s ease, border-color .18s ease;
  white-space:nowrap;
}
.btn-primary{ background:var(--brand); color:rgba(0,0,0,.87); }
.btn-primary:hover{ background:var(--brand-hover); }
.btn-ghost{ background:transparent; color:var(--text-on-dark); }
.btn-ghost:hover{ color:var(--brand); }
.btn-outline{ background:transparent; color:var(--text-dark); border-color:var(--border); }
.btn-outline:hover{ border-color:var(--brand); color:var(--brand); }
.btn-lg{ height:46px; padding:0 34px; font-size:15px; }

/* ============================================================
   HEADER
   ============================================================ */
.site-header{
  position:sticky; top:0; z-index:900;
  height:var(--header-h);
  background:var(--bg-header);
  color:var(--text-on-dark);
}
.header-inner{ height:var(--header-h); display:flex; align-items:center; gap:28px; }
.brand-logo{ height:30px; width:auto; }
.main-nav{ flex:1; }
.nav-list{ list-style:none; display:flex; gap:6px; margin:0; padding:0; }
.nav-item{ position:relative; }
.nav-link{
  background:none; border:none; color:var(--text-on-dark);
  font-size:14px; font-weight:500; height:var(--header-h);
  padding:0 12px; display:inline-flex; align-items:center; gap:6px;
}
.nav-link:hover{ color:var(--brand); }
.caret{ width:0;height:0;border-left:4px solid transparent;border-right:4px solid transparent;border-top:5px solid currentColor; opacity:.7; transition:transform .2s; }
.nav-item:hover .caret{ transform:rotate(180deg); }

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

/* Mega menus */
.mega{
  position:absolute; top:calc(var(--header-h) - 8px); left:0;
  background:#0f0f15; border:1px solid var(--border-dark);
  border-radius:10px; padding:10px;
  min-width:340px; box-shadow:0 24px 60px rgba(0,0,0,.5);
  opacity:0; visibility:hidden; transform:translateY(8px);
  transition:opacity .18s ease, transform .18s ease, visibility .18s;
  display:grid; gap:2px;
}
.nav-item.has-mega:hover .mega{ opacity:1; visibility:visible; transform:translateY(0); }
.mega-two{ grid-template-columns:1fr 1fr; min-width:560px; }
.mega-icons{ grid-template-columns:1fr 1fr; min-width:640px; }
.mega-item{
  display:block; padding:10px 12px; border-radius:8px;
}
.mega-item:hover{ background:rgba(255,255,255,.05); }
.mi-title{ display:block; color:var(--text-on-dark); font-weight:600; font-size:14px; }
.mi-sub{ display:block; color:var(--text-on-dark-dim); font-size:12px; margin-top:3px; line-height:1.35; }
.icon-item{ display:flex; gap:12px; align-items:flex-start; }
.icon-item img{ width:34px; height:34px; object-fit:contain; margin-top:2px; filter:drop-shadow(0 0 6px rgba(247,166,0,.15)); }

.hamburger{ display:none; flex-direction:column; gap:5px; background:none; border:none; padding:6px; }
.hamburger span{ width:22px; height:2px; background:#fff; display:block; }

/* ============================================================
   HERO
   ============================================================ */
.hero{ background:var(--bg-header); color:var(--text-on-dark); padding:70px 0 90px; }
.hero-grid{ display:grid; grid-template-columns:1.05fr .95fr; gap:48px; align-items:center; }
.hero-copy h1{ font-size:44px; line-height:1.15; font-weight:700; margin:0 0 18px; letter-spacing:-.5px; }
.hero-sub{ color:var(--text-on-dark-dim); font-size:17px; margin:0 0 28px; max-width:460px; }
.hero-form{ display:flex; gap:10px; max-width:440px; }
.hero-form input{
  flex:1; height:46px; border-radius:var(--radius);
  border:1px solid var(--border-dark); background:#12121a; color:#fff;
  padding:0 16px; font-size:14px;
}
.hero-form input::placeholder{ color:rgba(255,255,255,.4); }
.hero-form .btn{ height:46px; padding:0 26px; }

.hero-tickers{ display:grid; grid-template-columns:1fr 1fr; gap:16px; }
.ticker-card{
  background:#101018; border:1px solid var(--border-dark); border-radius:var(--radius-lg);
  padding:18px 20px;
}
.ticker-top{ display:flex; align-items:center; gap:10px; margin-bottom:10px; }
.ticker-sym{ font-weight:700; font-size:16px; }
.ticker-badge{ margin-left:auto; font-size:12px; padding:2px 8px; border-radius:20px; background:rgba(255,255,255,.06); color:var(--text-on-dark-dim); }
.ticker-price{ font-size:22px; font-weight:700; }
.ticker-change{ font-size:13px; margin-top:4px; font-weight:600; }
.up{ color:var(--up); }
.down{ color:var(--down); }
.spark{ margin-top:12px; height:40px; width:100%; }

/* ============================================================
   MARKET TABLE
   ============================================================ */
.market{ background:var(--bg-light); padding:72px 0; }
.section-head .eyebrow{ color:var(--brand); font-weight:600; font-size:14px; letter-spacing:.5px; }
.section-head h2{ font-size:34px; font-weight:600; margin:8px 0 0; letter-spacing:-.4px; }
.section-head.center{ text-align:center; }
.section-head{ margin-bottom:28px; }

.market-tabs{ display:flex; gap:8px; flex-wrap:wrap; margin-bottom:18px; }
.mtab{
  background:var(--bg-light-2); border:1px solid var(--border); color:var(--text-muted);
  height:34px; padding:0 16px; border-radius:20px; font-size:13px; font-weight:500;
}
.mtab.active{ background:var(--brand); border-color:var(--brand); color:rgba(0,0,0,.87); }

.table-wrap{ overflow-x:auto; border:1px solid var(--border); border-radius:var(--radius-lg); }
.coin-table{ width:100%; border-collapse:collapse; min-width:720px; }
.coin-table th{
  text-align:left; font-size:12px; text-transform:uppercase; letter-spacing:.4px;
  color:var(--text-muted); font-weight:600; padding:16px 20px; border-bottom:1px solid var(--border);
}
.coin-table td{ padding:14px 20px; border-bottom:1px solid var(--border); font-size:14px; vertical-align:middle; }
.coin-table tr:last-child td{ border-bottom:none; }
.coin-table tbody tr:hover{ background:var(--bg-light-2); }
.col-price,.col-change{ }
.cell-name{ display:flex; align-items:center; gap:12px; }
.coin-ic{ width:30px; height:30px; border-radius:50%; background:var(--brand); color:#000; font-weight:700; font-size:12px; display:flex; align-items:center; justify-content:center; }
.cell-name .pair{ font-weight:600; }
.cell-name .pair small{ color:var(--text-muted); font-weight:400; }
.mini-spark{ width:120px; height:34px; }
.op-btns{ display:flex; gap:8px; }
.op-btns .btn{ height:30px; padding:0 14px; font-size:12px; }
.market-more{ text-align:center; margin-top:26px; }

/* ============================================================
   APP SECTION
   ============================================================ */
.app-section{ background:var(--bg-dark-2); color:var(--text-on-dark); padding:80px 0; }
.app-grid{ display:grid; grid-template-columns:1fr 1fr; gap:48px; align-items:center; }
.app-copy h2{ font-size:34px; font-weight:600; margin:0 0 14px; }
.app-copy p{ color:var(--text-on-dark-dim); font-size:17px; max-width:420px; }
.store-badges{ display:flex; gap:14px; margin-top:26px; }
.store-badge{ border:1px solid var(--border-dark); border-radius:10px; padding:10px 18px; font-size:14px; color:#fff; }
.store-badge:hover{ border-color:var(--brand); }

.app-visual{ display:flex; justify-content:center; }
.phone{
  width:260px; height:520px; border-radius:36px; background:#08080c;
  border:8px solid #1b1b24; position:relative; padding:22px 16px;
  box-shadow:0 40px 90px rgba(0,0,0,.6);
}
.phone-notch{ position:absolute; top:12px; left:50%; transform:translateX(-50%); width:110px; height:20px; background:#1b1b24; border-radius:0 0 14px 14px; }
.phone-screen{ margin-top:24px; display:flex; flex-direction:column; gap:16px; }
.ps-row{ display:flex; justify-content:space-between; font-size:14px; font-weight:600; }
.ps-chart{ height:120px; border-radius:12px; background:linear-gradient(180deg,rgba(247,166,0,.25),rgba(247,166,0,0)); border:1px solid var(--border-dark); position:relative; overflow:hidden; }
.ps-chart::after{ content:""; position:absolute; inset:auto 0 20px 0; height:2px; background:var(--brand); box-shadow:0 0 16px var(--brand); }
.ps-bars{ display:flex; gap:8px; align-items:flex-end; height:70px; }
.ps-bars i{ flex:1; background:rgba(255,255,255,.15); border-radius:4px 4px 0 0; }
.ps-bars i:nth-child(1){height:40%} .ps-bars i:nth-child(2){height:70%;background:var(--brand)}
.ps-bars i:nth-child(3){height:55%} .ps-bars i:nth-child(4){height:85%;background:var(--brand)}
.ps-bars i:nth-child(5){height:30%} .ps-bars i:nth-child(6){height:60%} .ps-bars i:nth-child(7){height:45%}

/* ============================================================
   WHY
   ============================================================ */
.why{ background:var(--bg-light); padding:80px 0; }
.why-grid{ display:grid; grid-template-columns:repeat(3,1fr); gap:26px; margin-top:36px; }
.why-card{
  background:var(--bg-light-2); border:1px solid var(--border); border-radius:var(--radius-lg);
  padding:38px 30px; text-align:center; transition:transform .2s, box-shadow .2s;
}
.why-card:hover{ transform:translateY(-6px); box-shadow:0 20px 50px rgba(0,0,0,.08); }
.why-card img{ width:78px; height:78px; object-fit:contain; margin:0 auto 20px; }
.why-card h3{ font-size:20px; margin:0 0 10px; font-weight:600; }
.why-card p{ color:var(--text-muted); font-size:15px; margin:0; }

/* ============================================================
   CTA
   ============================================================ */
.cta{ background:var(--bg-header); color:var(--text-on-dark); padding:70px 0; }
.cta-inner{ text-align:center; }
.cta-inner h2{ font-size:32px; font-weight:600; margin:0 0 12px; }
.cta-inner p{ color:var(--text-on-dark-dim); margin:0 0 26px; }

/* ============================================================
   PARTNERS
   ============================================================ */
.partners{ background:var(--bg-light-2); padding:64px 0; }
.partner-row{ display:flex; flex-wrap:wrap; justify-content:center; gap:46px; margin-top:30px; }
.partner-row span{ color:var(--text-muted); font-weight:700; font-size:22px; opacity:.55; filter:grayscale(1); }

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer{ background:var(--bg-header); color:var(--text-on-dark); padding:56px 0 0; }
.footer-grid{ display:grid; grid-template-columns:1.4fr 1fr 1fr 1fr 1fr; gap:32px; }
.footer-logo{ height:28px; margin-bottom:14px; }
.footer-tag{ color:var(--text-on-dark-dim); font-size:14px; max-width:240px; }
.socials{ display:flex; gap:12px; margin-top:18px; }
.socials a{ width:36px; height:36px; border-radius:50%; border:1px solid var(--border-dark); display:flex; align-items:center; justify-content:center; }
.socials a:hover{ border-color:var(--brand); color:var(--brand); }
.footer-col h3{ font-size:15px; font-weight:600; margin:0 0 16px; }
.footer-col ul{ list-style:none; margin:0; padding:0; display:grid; gap:10px; }
.footer-col a{ color:var(--text-on-dark-dim); font-size:14px; }
.footer-col a:hover{ color:var(--brand); }
.footer-bottom{ border-top:1px solid var(--border-dark); margin-top:48px; padding:22px 0; }
.footer-bottom .container{ color:var(--text-on-dark-dim); font-size:13px; text-align:center; }

/* ============================================================
   COOKIE BANNER
   ============================================================ */
.cookie-banner{
  position:fixed; left:20px; right:20px; bottom:20px; z-index:1000;
  max-width:var(--maxw); margin:0 auto;
  background:#0f0f15; border:1px solid var(--border-dark); border-radius:12px;
  padding:16px 20px; display:flex; align-items:center; gap:20px;
  box-shadow:0 20px 60px rgba(0,0,0,.5); color:var(--text-on-dark-dim);
}
.cookie-banner p{ margin:0; font-size:13px; flex:1; }
.cookie-banner a{ color:var(--brand); }
.cookie-banner.hidden{ display:none; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 980px){
  .main-nav{ display:none; }
  .hamburger{ display:flex; }
  .header-actions{ margin-left:auto; }
  .hero-grid,.app-grid{ grid-template-columns:1fr; }
  .hero-copy h1{ font-size:34px; }
  .why-grid{ grid-template-columns:1fr; }
  .footer-grid{ grid-template-columns:1fr 1fr; }
  .app-visual{ order:-1; }
}
@media (max-width: 560px){
  .hero-tickers{ grid-template-columns:1fr; }
  .footer-grid{ grid-template-columns:1fr; }
  .section-head h2{ font-size:26px; }
  .cookie-banner{ flex-direction:column; align-items:flex-start; }
}

/* ============================================================
   SUBPAGE STYLES
   ============================================================ */
.mega-one{ min-width:340px; }

/* Generic page scaffold */
.page{ background:var(--bg-light); min-height:60vh; padding:48px 0 72px; }
.page > .container > h1{ font-size:34px; font-weight:700; margin:0 0 10px; }
.lede{ color:var(--text-muted); font-size:17px; max-width:640px; margin:0 0 26px; }
.muted{ color:var(--text-muted); }
.narrow{ max-width:520px; }
.center-page{ display:flex; align-items:center; }
.btn-block{ width:100%; }
.btn-outline-dark{ background:transparent; color:#fff; border-color:var(--border-dark); }
.btn-outline-dark:hover{ border-color:var(--brand); color:var(--brand); }

.page-head{ display:flex; align-items:center; justify-content:space-between; gap:20px; flex-wrap:wrap; margin-bottom:22px; }
.page-head h1{ margin:0; font-size:32px; font-weight:700; }
.seg{ display:inline-flex; background:var(--bg-light-2); border:1px solid var(--border); border-radius:24px; padding:3px; }
.seg-btn{ border:none; background:none; padding:7px 18px; border-radius:20px; font-size:14px; font-weight:500; color:var(--text-muted); }
.seg-btn.active{ background:var(--brand); color:rgba(0,0,0,.87); }

/* ---------- AUTH ---------- */
.page-auth{ background:var(--bg-dark); }
.auth-main{ min-height:calc(100vh - 65px); display:flex; align-items:center; justify-content:center; padding:48px 20px; background:radial-gradient(1200px 500px at 50% -10%, rgba(247,166,0,.10), transparent 60%), var(--bg-dark); }
.auth-card{ width:100%; max-width:420px; background:#0f0f15; border:1px solid var(--border-dark); border-radius:16px; padding:30px; color:var(--text-on-dark); box-shadow:0 30px 80px rgba(0,0,0,.5); }
.auth-secure{ display:flex; gap:12px; align-items:center; background:rgba(60,203,127,.08); border:1px solid rgba(60,203,127,.25); border-radius:10px; padding:10px 14px; margin-bottom:22px; }
.auth-secure .lock{ font-size:18px; }
.auth-secure-t{ display:block; font-size:12px; color:var(--text-on-dark-dim); }
.auth-secure-u{ display:block; font-size:13px; color:var(--up); font-weight:600; }
.auth-title{ font-size:26px; font-weight:700; margin:0 0 6px; }
.auth-switch{ font-size:14px; color:var(--text-on-dark-dim); margin:0 0 24px; }
.auth-switch a{ color:var(--brand); }
.auth-form{ display:flex; flex-direction:column; gap:16px; }
.auth-form .field{ display:flex; flex-direction:column; gap:7px; font-size:13px; color:var(--text-on-dark-dim); }
.auth-form .field > label{ font-size:13px; }
.auth-form input[type=email],.auth-form input[type=password],.auth-form input[type=text]{
  height:44px; border-radius:8px; border:1px solid var(--border-dark); background:#12121a; color:#fff; padding:0 14px; font-size:14px;
  transition:border-color .15s ease; }
.auth-form input:focus{ outline:none; border-color:var(--brand); }
.opt{ color:var(--text-muted); }
/* validation states */
.field.invalid input[type=email],.field.invalid input[type=password],.field.invalid input[type=text]{ border-color:var(--down); }
.field.valid input[type=email],.field.valid input[type=password]{ border-color:rgba(60,203,127,.55); }
.field-error{ color:var(--down); font-size:12px; min-height:0; display:none; }
.field.invalid .field-error{ display:block; }
.field-check.invalid .auth-check span{ color:var(--down); }
/* password strength meter */
.pw-meter{ height:5px; border-radius:4px; background:var(--border-dark); overflow:hidden; }
.pw-meter > span{ display:block; height:100%; width:0; background:var(--down); border-radius:4px; transition:width .2s ease, background .2s ease; }
.pw-meter > span.s0,.pw-meter > span.s1{ background:#f1595d; }
.pw-meter > span.s2{ background:#f7a600; }
.pw-meter > span.s3{ background:#f7c948; }
.pw-meter > span.s4,.pw-meter > span.s5{ background:#3ccb7f; }
.pw-error{ color:var(--down); font-size:12px; min-height:16px; }
/* status message */
.form-status{ font-size:13px; min-height:0; }
.form-status.success{ color:var(--up); }
.form-status.error{ color:var(--down); }
/* password show/hide toggle */
.pw-wrap{ position:relative; display:block; }
.pw-wrap input{ width:100%; padding-right:44px !important; }
.pw-toggle{ position:absolute; right:6px; top:50%; transform:translateY(-50%); width:34px; height:34px;
  display:flex; align-items:center; justify-content:center; background:none; border:none;
  color:var(--text-on-dark-dim); border-radius:6px; }
.pw-toggle:hover{ color:var(--brand); }
.pw-toggle:focus-visible{ outline:2px solid var(--brand); outline-offset:1px; }
/* remember me + forgot row */
.auth-row{ display:flex; align-items:center; justify-content:space-between; gap:12px; margin-top:-2px; }
.auth-remember{ display:flex; align-items:center; gap:8px; font-size:13px; color:var(--text-on-dark-dim); cursor:pointer; }
.auth-remember input{ width:16px; height:16px; accent-color:var(--brand); }
.auth-forgot.inline{ margin:0; font-size:13px; }
.auth-check{ flex-direction:row !important; align-items:center; gap:10px; font-size:13px; }
.auth-check input{ width:16px; height:16px; accent-color:var(--brand); }
.auth-check a{ color:var(--brand); }
.auth-form .btn{ height:46px; margin-top:4px; }
.auth-forgot{ text-align:center; font-size:13px; color:var(--text-on-dark-dim); }
.auth-forgot:hover{ color:var(--brand); }

/* ---------- MARKETS ---------- */
.market-toolbar{ display:flex; justify-content:space-between; gap:16px; flex-wrap:wrap; margin-bottom:16px; }
.market-search{ height:38px; border:1px solid var(--border); border-radius:8px; padding:0 14px; font-size:14px; min-width:240px; }
.market-search:focus{ outline:none; border-color:var(--brand); }
.market-filters{ display:flex; gap:8px; flex-wrap:wrap; }
.markets-table td small{ color:var(--text-muted); }
.markets-table .cell-name .pair small{ margin-left:2px; }

/* ---------- TRADE ---------- */
.page-trade{ background:var(--bg-dark); color:var(--text-on-dark); }
.trade-main{ padding:16px 16px 40px; }
.trade-top{ background:#0f0f15; border:1px solid var(--border-dark); border-radius:12px; padding:14px 18px; margin-bottom:14px; }
.pair-info{ display:flex; align-items:center; gap:26px; flex-wrap:wrap; }
.coin-ic.lg{ width:38px; height:38px; font-size:13px; }
.pair-name{ font-size:18px; font-weight:700; } .pair-name small{ color:var(--text-on-dark-dim); font-weight:400; }
.pair-sub{ font-size:12px; color:var(--text-on-dark-dim); }
.pair-price{ font-size:22px; font-weight:700; color:var(--brand); }
.pair-stat{ display:flex; flex-direction:column; font-size:13px; }
.pair-stat .lbl{ font-size:11px; color:var(--text-on-dark-dim); }
.trade-grid{ display:grid; grid-template-columns:280px minmax(0,1fr) 320px; gap:14px; max-width:100%; }
.trade-grid > *{ min-width:0; }
.panel{ background:#0f0f15; border:1px solid var(--border-dark); border-radius:12px; padding:14px; }
.panel-title{ font-size:14px; font-weight:600; margin-bottom:10px; }
.ob-head{ display:grid; grid-template-columns:1.2fr 1fr 1fr; font-size:11px; color:var(--text-on-dark-dim); padding-bottom:6px; }
.ob-row{ display:grid; grid-template-columns:1.2fr 1fr 1fr; font-size:12px; padding:2px 0; position:relative; }
.ob-row span{ position:relative; z-index:1; }
.ob-row i{ position:absolute; right:0; top:0; bottom:0; opacity:.10; }
.ob-row.ask i{ background:var(--down); } .ob-row.bid i{ background:var(--up); }
.ob-mid{ padding:8px 0; font-size:18px; font-weight:700; border-top:1px solid var(--border-dark); border-bottom:1px solid var(--border-dark); margin:6px 0; }
.chart-panel{ display:flex; flex-direction:column; }
.chart-tabs{ display:flex; align-items:center; gap:8px; margin-bottom:10px; }
.chart-tf{ margin-left:auto; font-size:12px; color:var(--text-on-dark-dim); letter-spacing:2px; }
.chip{ background:#181820; border:1px solid var(--border-dark); color:var(--text-on-dark-dim); padding:5px 12px; border-radius:7px; font-size:12px; font-weight:500; }
.chip.active{ background:var(--brand); color:#000; border-color:var(--brand); }
.fake-chart{ height:280px; border:1px solid var(--border-dark); border-radius:10px; background:linear-gradient(180deg,rgba(247,166,0,.06),transparent); margin-bottom:14px; }
.of-tabs{ display:flex; gap:8px; margin-bottom:14px; }
.of-cols{ display:grid; grid-template-columns:1fr 1fr; gap:16px; min-width:0; }
.of-cols > div{ min-width:0; }
.of-side{ font-weight:600; font-size:14px; margin-bottom:10px; }
.of-side.buy{ color:var(--up); } .of-side.sell{ color:var(--down); }
.order-form label{ display:block; font-size:12px; color:var(--text-on-dark-dim); margin-bottom:10px; }
.of-input{ display:flex; align-items:center; background:#12121a; border:1px solid var(--border-dark); border-radius:8px; margin-top:5px; padding:0 12px; min-width:0; }
.of-input input{ flex:1; min-width:0; width:0; background:none; border:none; color:#fff; height:38px; font-size:13px; outline:none; }
.of-input span{ font-size:12px; color:var(--text-on-dark-dim); }
.of-slider{ height:4px; background:var(--border-dark); border-radius:4px; margin:4px 0 12px; position:relative; }
.of-slider span{ position:absolute; left:0; top:50%; width:12px; height:12px; border-radius:50%; background:var(--brand); transform:translateY(-50%); }
.btn-buy{ background:var(--up); color:#04140b; } .btn-buy:hover{ filter:brightness(1.08); }
.btn-sell{ background:var(--down); color:#1a0405; } .btn-sell:hover{ filter:brightness(1.08); }
.of-note{ text-align:center; font-size:12px; color:var(--text-on-dark-dim); margin:16px 0 0; }
.of-note a{ color:var(--brand); }

/* ---------- SWAP ---------- */
.swap-card{ background:#fff; border:1px solid var(--border); border-radius:18px; padding:24px; box-shadow:0 20px 60px rgba(0,0,0,.06); }
.swap-row{ background:var(--bg-light-2); border:1px solid var(--border); border-radius:12px; padding:14px 16px; }
.swap-label{ font-size:12px; color:var(--text-muted); margin-bottom:8px; }
.swap-field{ display:flex; align-items:center; gap:12px; }
.swap-field input{ flex:1; border:none; background:none; font-size:24px; font-weight:600; outline:none; width:100%; }
.swap-select{ border:1px solid var(--border); background:#fff; border-radius:20px; padding:8px 14px; font-weight:600; font-size:14px; }
.swap-bal{ font-size:12px; color:var(--text-muted); margin-top:8px; }
.swap-flip{ display:block; margin:-10px auto; width:40px; height:40px; border-radius:50%; border:4px solid #fff; background:var(--brand); color:#000; font-size:16px; position:relative; z-index:2; }
.swap-meta{ display:flex; flex-direction:column; gap:8px; margin:18px 0; font-size:13px; }
.swap-meta > div{ display:flex; justify-content:space-between; color:var(--text-muted); }
.swap-meta b, .swap-meta span:last-child{ color:var(--text-dark); }

/* ---------- ABOUT ---------- */
.about-hero{ background:var(--bg-header); color:#fff; padding:72px 0; }
.about-hero .eyebrow{ color:var(--brand); }
.about-hero h1{ font-size:40px; font-weight:700; margin:10px 0 16px; }
.about-hero .lede{ color:var(--text-on-dark-dim); max-width:760px; }
.stats-grid{ display:grid; grid-template-columns:repeat(4,1fr); gap:20px; margin-top:40px; }
.stat{ background:#101018; border:1px solid var(--border-dark); border-radius:14px; padding:24px; }
.stat b{ display:block; font-size:30px; color:var(--brand); }
.stat span{ color:var(--text-on-dark-dim); font-size:14px; }
.about-sec{ background:var(--bg-light); padding:70px 0; }
.about-sec .eyebrow, .about-band .eyebrow{ color:var(--brand); }
.about-sec h2{ font-size:30px; margin:8px 0 22px; }
.check-list{ list-style:none; padding:0; margin:0; display:grid; gap:14px; max-width:720px; }
.check-list li{ position:relative; padding-left:34px; font-size:16px; }
.check-list li::before{ content:"\2713"; position:absolute; left:0; top:-2px; width:22px; height:22px; border-radius:50%; background:var(--brand); color:#000; font-size:13px; display:flex; align-items:center; justify-content:center; font-weight:700; }
.about-band{ background:var(--bg-light-2); padding:60px 0; }
.about-band h2{ font-size:28px; font-weight:600; max-width:900px; margin:8px 0 0; }
.about-timeline{ background:var(--bg-light); padding:70px 0; }
.about-timeline h2{ font-size:30px; margin:0 0 34px; }
.timeline{ list-style:none; margin:0; padding:0 0 0 24px; border-left:2px solid var(--border); }
.timeline li{ position:relative; padding:0 0 30px 26px; }
.timeline li::before{ content:""; position:absolute; left:-33px; top:2px; width:14px; height:14px; border-radius:50%; background:var(--brand); border:3px solid #fff; }
.tl-date{ display:block; font-size:13px; color:var(--brand); font-weight:600; }
.tl-title{ display:block; font-size:17px; font-weight:600; margin:4px 0; }
.tl-desc{ display:block; color:var(--text-muted); font-size:14px; max-width:640px; }

/* ---------- FEES ---------- */
.fee-h{ font-size:22px; margin:34px 0 16px; }
.fee-cards{ display:grid; grid-template-columns:1fr 1fr; gap:16px; }
.fee-card{ background:var(--bg-light-2); border:1px solid var(--border); border-radius:14px; padding:22px; display:flex; flex-direction:column; justify-content:space-between; gap:14px; }
.fee-card span{ color:var(--text-muted); font-size:14px; }
.fee-card b{ font-size:30px; color:var(--brand); }
.fees-table td small{ display:block; color:var(--text-muted); font-weight:400; }

/* ---------- FEATURE / TOOL PAGES ---------- */
.feature-hero{ background:var(--bg-header); color:#fff; padding:80px 0 70px; text-align:center; }
.feature-hero .eyebrow{ color:var(--brand); }
.feature-hero h1{ font-size:44px; font-weight:700; margin:12px 0 16px; }
.feature-hero .lede{ color:var(--text-on-dark-dim); margin:0 auto 30px; }
.feature-actions{ display:flex; gap:14px; justify-content:center; flex-wrap:wrap; }
.feature-grid-sec{ background:var(--bg-light); padding:66px 0; }
.feature-grid{ display:grid; grid-template-columns:repeat(2,1fr); gap:22px; max-width:900px; margin:0 auto; }
.feat-card{ background:var(--bg-light-2); border:1px solid var(--border); border-radius:14px; padding:28px; }
.feat-card h3{ margin:0 0 8px; font-size:18px; }
.feat-card p{ margin:0; color:var(--text-muted); font-size:15px; }

/* ---------- LEGAL ---------- */
.legal-page{ padding:40px 0 70px; }
.legal-wrap{ display:grid; grid-template-columns:240px 1fr; gap:40px; align-items:start; }
.legal-toc{ position:sticky; top:85px; border:1px solid var(--border); border-radius:12px; padding:16px; max-height:calc(100vh - 110px); overflow:auto; }
.legal-toc-t{ font-size:12px; text-transform:uppercase; letter-spacing:.5px; color:var(--text-muted); margin-bottom:10px; }
.legal-toc ul{ list-style:none; margin:0; padding:0; display:grid; gap:8px; }
.legal-toc a{ font-size:13px; color:var(--text-muted); }
.legal-toc a:hover{ color:var(--brand); }
.legal-body h1{ font-size:32px; font-weight:700; margin:0 0 6px; }
.legal-updated{ color:var(--text-muted); font-size:13px; margin:0 0 30px; }
.legal-sec{ margin-bottom:26px; scroll-margin-top:85px; }
.legal-sec h3{ font-size:18px; margin:0 0 8px; }
.legal-sec p{ color:var(--text-muted); font-size:15px; margin:0; }

@media (max-width: 980px){
  .trade-grid{ grid-template-columns:1fr; }
  .stats-grid{ grid-template-columns:1fr 1fr; }
  .feature-grid{ grid-template-columns:1fr; }
  .fee-cards{ grid-template-columns:1fr; }
  .legal-wrap{ grid-template-columns:1fr; }
  .legal-toc{ position:static; max-height:none; }
  .of-cols{ grid-template-columns:1fr; }
  .feature-hero h1{ font-size:32px; }
}

/* ============================================================
   MOBILE SLIDE-OUT NAV DRAWER
   ============================================================ */
.drawer-overlay{
  position:fixed; inset:0; z-index:1200;
  background:rgba(0,0,0,.55); backdrop-filter:blur(2px);
  opacity:0; visibility:hidden; transition:opacity .25s ease, visibility .25s ease;
}
.drawer-overlay.open{ opacity:1; visibility:visible; }

.drawer{
  position:fixed; top:0; right:0; z-index:1300;
  width:min(340px, 88vw); height:100%;
  background:var(--bg-header); color:var(--text-on-dark);
  border-left:1px solid var(--border-dark);
  display:flex; flex-direction:column;
  transform:translateX(100%); transition:transform .28s cubic-bezier(.4,0,.2,1);
  box-shadow:-20px 0 60px rgba(0,0,0,.5);
}
.drawer.open{ transform:translateX(0); }
.drawer-top{
  display:flex; align-items:center; justify-content:space-between;
  padding:16px 20px; border-bottom:1px solid var(--border-dark); flex:none;
}
.drawer-top .brand-logo{ height:28px; }
.drawer-close{ background:none; border:none; color:#fff; font-size:30px; line-height:1; padding:0 4px; }
.drawer-close:hover{ color:var(--brand); }
.drawer-scroll{ flex:1; overflow-y:auto; padding:8px 0; }

.drawer-sec{ border-bottom:1px solid var(--border-dark); }
.drawer-head{
  width:100%; background:none; border:none; color:#fff;
  display:flex; align-items:center; justify-content:space-between;
  padding:15px 20px; font-size:15px; font-weight:600; text-align:left;
}
.drawer-chev{ width:0; height:0; border-left:5px solid transparent; border-right:5px solid transparent; border-top:6px solid rgba(255,255,255,.5); transition:transform .2s ease; }
.drawer-sec.open .drawer-chev{ transform:rotate(180deg); }
.drawer-body{ max-height:0; overflow:hidden; transition:max-height .28s ease; }
.drawer-sec.open .drawer-body{ max-height:420px; }
.drawer-link{ display:block; padding:11px 20px 11px 34px; font-size:14px; color:var(--text-on-dark-dim); }
.drawer-link:hover{ color:var(--brand); background:rgba(255,255,255,.04); }
.drawer-solo{ display:block; padding:15px 20px; font-size:15px; font-weight:600; color:#fff; border-bottom:1px solid var(--border-dark); }
.drawer-solo:hover{ color:var(--brand); }
.drawer-actions{ flex:none; padding:16px 20px; display:grid; gap:10px; border-top:1px solid var(--border-dark); }

/* Drawer + hamburger only appear on small screens (nav collapses at 980px) */
@media (min-width: 981px){
  .drawer, .drawer-overlay{ display:none !important; }
}

/* ============================================================
   AUTHENTICATED DASHBOARD
   ============================================================ */
.page-dashboard{ background:var(--bg-dark); color:var(--text-on-dark); }
.ds-shell{ display:grid; grid-template-columns:248px 1fr; min-height:100vh; }

/* Sidebar */
.ds-sidebar{ background:var(--bg-header); border-right:1px solid var(--border-dark);
  display:flex; flex-direction:column; padding:18px 14px; position:sticky; top:0; height:100vh; }
.ds-brand{ padding:6px 8px 18px; }
.ds-brand img{ height:28px; }
.ds-nav{ display:flex; flex-direction:column; gap:4px; flex:1; }
.ds-side-foot{ display:flex; flex-direction:column; gap:4px; border-top:1px solid var(--border-dark); padding-top:10px; }
.ds-link{ display:flex; align-items:center; gap:12px; padding:11px 12px; border-radius:9px;
  color:var(--text-on-dark-dim); font-size:14px; font-weight:500; background:none; border:none; width:100%; text-align:left; }
.ds-link svg{ flex:none; }
.ds-link:hover{ background:rgba(255,255,255,.05); color:#fff; }
.ds-link.active{ background:rgba(247,166,0,.14); color:var(--brand); }

/* Body + topbar */
.ds-body{ display:flex; flex-direction:column; min-width:0; }
.ds-topbar{ display:flex; align-items:center; gap:16px; padding:14px 26px;
  border-bottom:1px solid var(--border-dark); position:sticky; top:0; background:rgba(11,11,16,.9);
  backdrop-filter:blur(8px); z-index:50; }
.ds-title{ font-size:20px; font-weight:700; flex:1; min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.ds-top-right{ margin-left:auto; display:flex; align-items:center; gap:14px; }
.ds-account{ display:flex; align-items:center; gap:10px; }
.ds-email{ font-size:13px; color:var(--text-on-dark-dim); max-width:180px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.avatar{ width:32px; height:32px; border-radius:50%; background:var(--brand); color:#000;
  display:flex; align-items:center; justify-content:center; font-weight:700; font-size:14px; flex:none; }
.ds-burger{ display:none; flex-direction:column; gap:5px; background:none; border:none; padding:4px; }
.ds-burger span{ width:22px; height:2px; background:#fff; display:block; }

.ds-main{ padding:26px; display:flex; flex-direction:column; gap:20px; max-width:1200px; width:100%; min-width:0; }

/* Cards */
.ds-card{ background:#0f0f15; border:1px solid var(--border-dark); border-radius:16px; padding:20px; min-width:0; }
.ds-card-head{ display:flex; align-items:center; justify-content:space-between; margin-bottom:16px; gap:12px; }
.ds-card-head h3{ margin:0; font-size:16px; font-weight:600; }
.see-all{ font-size:13px; color:var(--brand); }

/* Stat cards */
.ds-stats{ display:grid; grid-template-columns:repeat(4,1fr); gap:16px; }
.ds-stats.mini{ grid-template-columns:1fr 1fr; margin-top:16px; }
.stat-card{ background:#0f0f15; border:1px solid var(--border-dark); border-radius:16px; padding:18px 20px; display:flex; flex-direction:column; gap:6px; }
.stat-card.sm{ padding:14px 16px; }
.sc-label{ font-size:13px; color:var(--text-on-dark-dim); }
.sc-value{ font-size:26px; font-weight:700; }
.sc-value.big{ font-size:34px; }
.sc-sub{ font-size:13px; font-weight:500; }

.ds-grid-2{ display:grid; grid-template-columns:1.35fr 1fr; gap:20px; }

/* Charts */
.area{ width:100%; height:200px; display:block; }
.chart-range{ display:flex; gap:6px; }

/* Allocation donut */
.alloc{ display:flex; align-items:center; gap:20px; flex-wrap:wrap; }
.donut-wrap{ flex:none; }
.donut{ width:180px; height:180px; }
.donut-cap{ fill:var(--text-on-dark-dim); font-size:11px; }
.donut-val{ fill:#fff; font-size:16px; font-weight:700; }
.alloc-legend{ list-style:none; margin:0; padding:0; flex:1; min-width:180px; display:flex; flex-direction:column; gap:10px; }
.alloc-legend li{ display:grid; grid-template-columns:14px 46px 1fr auto; align-items:center; gap:10px; font-size:13px; }
.alloc-legend .dot{ width:10px; height:10px; border-radius:3px; }
.al-sym{ font-weight:600; }
.al-pct{ color:var(--text-on-dark-dim); }
.al-val{ text-align:right; }

/* Quick actions */
.quick-actions{ display:grid; grid-template-columns:repeat(4,1fr); gap:12px; }
.qa{ background:#12121a; border:1px solid var(--border-dark); border-radius:12px; padding:16px; text-align:center; font-weight:600; font-size:14px; }
.qa:hover{ border-color:var(--brand); color:var(--brand); }

/* Tables inside dashboard */
.ds-table{ min-width:560px; }
.ds-table th{ color:var(--text-on-dark-dim); border-bottom-color:var(--border-dark); }
.ds-table td{ border-bottom-color:var(--border-dark); }
.ds-table tbody tr:hover{ background:rgba(255,255,255,.03); }
.coin-ic.sm{ width:26px; height:26px; font-size:10px; }
.ds-table .op-btns .btn{ height:28px; padding:0 12px; font-size:12px; }
.page-dashboard .table-wrap{ border-color:var(--border-dark); background:transparent; }

/* Wallet head */
.wallet-head{ display:flex; align-items:flex-end; justify-content:space-between; gap:20px; flex-wrap:wrap; }
.wallet-actions{ display:flex; gap:10px; }

/* Tabs */
.ds-tabs{ display:flex; gap:8px; }

/* Deposit / withdraw */
.ds-field{ display:flex; flex-direction:column; gap:7px; font-size:13px; color:var(--text-on-dark-dim); margin-bottom:16px; }
.ds-field select, .ds-field input, .ds-field textarea{ border-radius:9px; border:1px solid var(--border-dark);
  background:#12121a; color:#fff; padding:0 14px; font-size:14px; font-family:var(--font); }
.ds-field select, .ds-field input{ height:44px; }
.ds-field textarea{ min-height:110px; padding:12px 14px; resize:vertical; }
.ds-field select:focus, .ds-field input:focus, .ds-field textarea:focus{ outline:none; border-color:var(--brand); }
.stacked-form{ display:flex; flex-direction:column; gap:4px; align-items:stretch; max-width:520px; }
.stacked-form .btn{ align-self:flex-start; }
.addr-box{ display:flex; gap:10px; align-items:center; background:#12121a; border:1px solid var(--border-dark); border-radius:9px; padding:8px 8px 8px 14px; }
.addr-box{ min-width:0; }
.addr-box code{ flex:1; min-width:0; font-size:13px; color:#fff; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.addr-box .btn{ height:32px; padding:0 14px; font-size:12px; flex:none; }
.qr{ margin:16px 0; }
.qr-inner{ display:inline-block; padding:10px; background:#fff; border-radius:10px; line-height:0; }
.wd-summary{ display:flex; justify-content:space-between; font-size:13px; color:var(--text-on-dark-dim); margin:6px 0 16px; }
.donut-seg{ cursor:pointer; transition:filter .15s ease; }
.donut-seg:hover{ filter:brightness(1.25); }

/* Profile / security */
.sec-row{ display:flex; align-items:center; justify-content:space-between; gap:16px; padding:14px 0; border-bottom:1px solid var(--border-dark); }
.sec-row:last-child{ border-bottom:none; }
.sec-row b{ display:block; font-size:14px; }
.switch-form{ flex:none; }
.switch{ position:relative; width:44px; height:24px; flex:none; display:block; }
.switch input{ opacity:0; width:0; height:0; }
.switch span{ position:absolute; inset:0; background:var(--border-dark); border-radius:20px; transition:.2s; cursor:pointer; }
.switch span::before{ content:""; position:absolute; width:18px; height:18px; left:3px; top:3px; background:#fff; border-radius:50%; transition:.2s; }
.switch input:checked + span{ background:var(--brand); }
.switch input:checked + span::before{ transform:translateX(20px); }
.danger-zone{ border-color:rgba(241,89,93,.3); }

.small{ font-size:12px; }
.empty{ padding:30px; text-align:center; color:var(--text-on-dark-dim); }
.hidden{ display:none !important; }

/* Overlay + toast */
.ds-overlay{ position:fixed; inset:0; background:rgba(0,0,0,.5); z-index:60; opacity:0; visibility:hidden; transition:.2s; }
.ds-overlay.open{ opacity:1; visibility:visible; }
.ds-toast{ position:fixed; left:50%; bottom:30px; transform:translate(-50%,20px); background:#12121a;
  border:1px solid var(--border-dark); color:#fff; padding:12px 20px; border-radius:10px; font-size:14px;
  z-index:2000; opacity:0; transition:.3s; box-shadow:0 20px 50px rgba(0,0,0,.5); }
.ds-toast.show{ opacity:1; transform:translate(-50%,0); }

/* Account menu in main header */
.account-item{ display:flex; align-items:center; }
.account-btn{ display:flex; align-items:center; gap:8px; background:none; border:none; color:#fff; font-size:14px; font-weight:500; height:var(--header-h); padding:0 6px; }
.account-btn .account-email{ max-width:150px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.account-menu{ right:0; left:auto; min-width:220px; }
.account-menu .logout-btn{ width:100%; text-align:left; background:none; border:none; }
.account-item:hover .caret{ transform:rotate(180deg); }

@media (max-width: 980px){
  .ds-shell{ grid-template-columns:1fr; }
  .ds-sidebar{ position:fixed; left:0; top:0; z-index:70; width:260px; transform:translateX(-100%); transition:transform .25s ease; }
  .ds-sidebar.open{ transform:translateX(0); }
  .ds-burger{ display:flex; }
  .ds-stats{ grid-template-columns:1fr 1fr; }
  .ds-grid-2{ grid-template-columns:1fr; }
  .quick-actions{ grid-template-columns:1fr 1fr; }
  .account-btn .account-email{ display:none; }
}
@media (max-width: 560px){
  .ds-stats{ grid-template-columns:1fr; }
  .ds-main{ padding:16px; }
  .ds-topbar{ padding:12px 16px; gap:10px; }
  .ds-email{ display:none; }
  .ds-top-right .btn-outline{ display:none; }
  .quick-actions{ grid-template-columns:1fr; }
}

/* Outline buttons need light text on the dark dashboard */
.page-dashboard .btn-outline{ color:#fff; border-color:var(--border-dark); }
.page-dashboard .btn-outline:hover{ border-color:var(--brand); color:var(--brand); }

/* ---- Trade order form: balances + disabled state ---- */
.of-avail{ font-size:12px; color:var(--text-on-dark-dim); margin:8px 0 10px; }
.of-bal{ color:#fff; }
.btn-disabled{ opacity:.5; pointer-events:none; }

/* ---- Swap: balance + Max ---- */
.swap-max{ background:rgba(247,166,0,.15); color:var(--brand); border:none; border-radius:6px;
  padding:2px 8px; font-size:11px; font-weight:600; margin-left:6px; }
.swap-max:hover{ background:rgba(247,166,0,.28); }

/* ---- Toast usable outside the dashboard too ---- */
.ds-toast{ position:fixed; left:50%; bottom:30px; transform:translate(-50%,20px); background:#12121a;
  border:1px solid var(--border-dark); color:#fff; padding:12px 20px; border-radius:10px; font-size:14px;
  z-index:2000; opacity:0; transition:.3s; box-shadow:0 20px 50px rgba(0,0,0,.5); }
.ds-toast.show{ opacity:1; transform:translate(-50%,0); }
.ds-toast.bad{ border-color:rgba(241,89,93,.6); }

/* ============================================================
   CONFIRMATION MODAL
   ============================================================ */
.modal-overlay{ position:fixed; inset:0; z-index:3000; display:flex; align-items:center; justify-content:center;
  padding:20px; background:rgba(0,0,0,.6); backdrop-filter:blur(3px);
  opacity:0; visibility:hidden; transition:opacity .2s ease, visibility .2s ease; }
.modal-overlay.open{ opacity:1; visibility:visible; }
.modal{ width:100%; max-width:400px; background:#0f0f15; color:var(--text-on-dark);
  border:1px solid var(--border-dark); border-radius:16px; padding:22px;
  box-shadow:0 30px 80px rgba(0,0,0,.6); transform:translateY(12px) scale(.98); transition:transform .2s ease; }
.modal-overlay.open .modal{ transform:none; }
.modal-head{ display:flex; align-items:center; justify-content:space-between; margin-bottom:16px; }
.modal-head h3{ margin:0; font-size:18px; font-weight:700; }
.modal-x{ background:none; border:none; color:var(--text-on-dark-dim); font-size:26px; line-height:1; padding:0 4px; }
.modal-x:hover{ color:#fff; }
.modal-rows{ display:flex; flex-direction:column; gap:2px; background:#12121a; border:1px solid var(--border-dark); border-radius:10px; padding:6px 14px; }
.modal-row{ display:flex; justify-content:space-between; gap:12px; padding:9px 0; font-size:14px; border-bottom:1px solid var(--border-dark); }
.modal-row:last-child{ border-bottom:none; }
.modal-row span:first-child{ color:var(--text-on-dark-dim); }
.modal-row span:last-child{ font-weight:600; }
.modal-note{ font-size:12px; color:var(--text-on-dark-dim); margin:14px 0 0; line-height:1.45; }
.modal-actions{ display:grid; grid-template-columns:1fr 1fr; gap:10px; margin-top:18px; }
.modal-actions .btn{ height:44px; }
.page-dashboard .modal .btn-outline,.page-trade .modal .btn-outline,.modal .btn-outline{ color:#fff; border-color:var(--border-dark); }
.modal .btn-outline:hover{ border-color:var(--brand); color:var(--brand); }

