/* =============================================================
   KASDAP ONE — DESIGN TOKENS
   Brand: Kasdap sky-blue (#2598c8) + navy (#1a3d7c)
   Theme: dark (default) + light, toggled via [data-theme]
   Mode:  b2b (only)
============================================================= */

:root {
  /* ---- type ---- */
  --ff-display: 'Bricolage Grotesque', sans-serif;
  --ff-body: 'Hanken Grotesk', sans-serif;
  --ff-mono: 'JetBrains Mono', monospace;

  /* ---- radii ---- */
  --r6: 6px; --r10: 10px; --r14: 14px; --r18: 18px; --r24: 24px; --r-pill: 999px;

  /* ---- semantic fixed colors ---- */
  --emerald: #00b86b; --emerald-soft: rgba(0,184,107,.13);
  --indigo: #2598c8;  --indigo-soft: rgba(37,152,200,.14);
  --kasdap-blue: #2598c8; --kasdap-navy: #1a3d7c;
  --coral: #ff7a45;
  --amber: #f5a623; --amber-soft: rgba(245,166,35,.13);
  --rose: #fb5c7e;  --rose-soft: rgba(251,92,126,.13);
  --sky: #4f9bf7;   --sky-soft: rgba(79,155,247,.13);

  /* ---- elevation ---- */
  --shadow-1: 0 1px 2px rgba(2,6,18,.18);
  --shadow-2: 0 8px 30px rgba(2,6,18,.30);
  --shadow-3: 0 24px 70px rgba(2,6,18,.45);

  --topbar: 60px;
  --bottomnav: 64px;
  --maxw: 1480px;
}

/* ============== DARK (default) ============== */
:root, [data-theme="dark"] {
  --bg:        #070a11;
  --bg-grad:   radial-gradient(1200px 600px at 80% -10%, rgba(37,152,200,.07), transparent 60%),
               radial-gradient(900px 500px at -10% 110%, rgba(26,61,124,.06), transparent 55%);
  --surface:   #10151f;
  --surface-2: #171e2c;
  --surface-3: #1f2839;
  --surface-hi:#283248;
  --line:      rgba(160,182,224,.14);
  --line-2:    rgba(160,182,224,.24);
  --line-3:    rgba(160,182,224,.38);
  --text:      #f4f7fd;
  --text-2:    #b4c2da;   /* brighter for body readability */
  --text-3:    #8595b1;   /* meta/labels — still clearly legible */
  --glass:     rgba(11,15,24,.82);
  --on-accent: #04130c;
}

/* ============== LIGHT ============== */
[data-theme="light"] {
  --bg:        #e9edf6;
  --bg-grad:   radial-gradient(1200px 600px at 80% -10%, rgba(37,152,200,.10), transparent 60%),
               radial-gradient(900px 500px at -10% 110%, rgba(26,61,124,.08), transparent 55%);
  --surface:   #ffffff;
  --surface-2: #f3f6fc;
  --surface-3: #e9eff8;
  --surface-hi:#dde6f3;
  --line:      rgba(20,33,61,.13);
  --line-2:    rgba(20,33,61,.22);
  --line-3:    rgba(20,33,61,.34);
  --text:      #0a1020;
  --text-2:    #3a485f;   /* darker for crisp body text */
  --text-3:    #5d6c84;   /* meta/labels — readable on light bg */
  --glass:     rgba(255,255,255,.82);
  --on-accent: #ffffff;
}

/* ============== MODE ACCENT (Kasdap blue — B2B only) ============== */
:root, [data-mode="b2b"], [data-mode="d2c"] {
  --accent:      #2598c8;
  --accent-rgb:  37,152,200;
  --accent-soft: rgba(37,152,200,.14);
  --accent-2:    #1a3d7c;
  --on-accent:   #ffffff;
  --mode-label:  'B2B · Trade';
}
/* light-mode: slightly deeper for contrast on white */
[data-theme="light"], [data-theme="light"][data-mode="b2b"], [data-theme="light"][data-mode="d2c"] {
  --accent: #1a7ab0; --accent-2: #1a3d7c; --accent-soft: rgba(26,122,176,.12); --accent-rgb: 26,122,176;
}

/* ============== RESET / BASE ============== */
* , *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }
html { font-size: 16px; -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  font-family: var(--ff-body);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.5;
  letter-spacing: -0.011em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  transition: background .35s ease;
}
body::before {
  content: ''; position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background: var(--bg-grad);
  transition: background .5s ease;
}
#root { position: relative; z-index: 1; }
img, svg { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
input, select, textarea { font-family: inherit; color: inherit; }
a { color: inherit; text-decoration: none; }
h1,h2,h3,h4 { font-family: var(--ff-display); font-weight: 700; letter-spacing: -0.025em; line-height: 1.04; }
::selection { background: rgba(var(--accent-rgb),.28); }

::-webkit-scrollbar { width: 9px; height: 9px; }
::-webkit-scrollbar-thumb { background: var(--line-2); border-radius: 99px; border: 2px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-thumb:hover { background: var(--line-3); background-clip: padding-box; }
::-webkit-scrollbar-track { background: transparent; }

/* ============== UTILITY ============== */
.mono { font-family: var(--ff-mono); font-feature-settings: 'tnum' 1; }
.eyebrow {
  font-family: var(--ff-mono); font-size: .62rem; font-weight: 500;
  letter-spacing: .18em; text-transform: uppercase; color: var(--text-3);
}
.accent-text { color: var(--accent); }
.muted { color: var(--text-2); }
.faint { color: var(--text-3); }
.no-scrollbar::-webkit-scrollbar { display: none; }
.no-scrollbar { scrollbar-width: none; }

@keyframes ksFadeUp { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes ksPop { from { opacity: 0; transform: scale(.92); } to { opacity: 1; transform: none; } }
@keyframes ksSlideIn { from { opacity: 0; transform: translateX(-10px); } to { opacity: 1; transform: none; } }
@keyframes ksPulse { 0%,100% { box-shadow: 0 0 0 0 rgba(var(--accent-rgb),.5);} 50% { box-shadow: 0 0 0 7px rgba(var(--accent-rgb),0);} }
@keyframes ksSpin { to { transform: rotate(360deg); } }
@keyframes ksShimmer { 0% { background-position: -360px 0; } 100% { background-position: 360px 0; } }
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .001ms !important; transition-duration: .08s !important; }
}
