@import url('https://fonts.googleapis.com/css2?family=Syne:wght@400;500;600;700;800&family=DM+Sans:wght@300;400;500;600&display=swap');

*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  /* Colors */
  --bg:        #0a0d14;
  --bg2:       #0f1320;
  --bg3:       #161b2e;
  --surface:   #1a2035;
  --border:    rgba(255,255,255,0.07);
  --border2:   rgba(255,255,255,0.13);

  --blue:      #3d8ef8;
  --blue-dark: #2563eb;
  --blue-glow: rgba(61,142,248,0.25);
  --blue-dim:  rgba(61,142,248,0.12);

  --amber:     #f5a623;
  --amber-dim: rgba(245,166,35,0.12);
  --amber-glow:rgba(245,166,35,0.25);

  --green:     #22c55e;
  --green-dim: rgba(34,197,94,0.12);

  --red:       #ef4444;
  --red-dim:   rgba(239,68,68,0.12);

  --text:      #f0f4ff;
  --text2:     #8892aa;
  --text3:     #4a5568;

  /* Spacing */
  --r:  12px;
  --r2: 8px;
  --r3: 16px;

  /* Shadows */
  --shadow:    0 2px 12px rgba(0,0,0,0.4);
  --shadow2:   0 8px 32px rgba(0,0,0,0.5);
  --glow-blue: 0 0 20px rgba(61,142,248,0.3);
  --glow-amber:0 0 20px rgba(245,166,35,0.3);
}

html { font-size: 16px; scroll-behavior: smooth; }

body {
  font-family: 'DM Sans', sans-serif;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

h1,h2,h3,h4,h5,h6 {
  font-family: 'Syne', sans-serif;
}

a { text-decoration: none; color: inherit; }

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: 'Syne', sans-serif;
  font-size: 14px;
  font-weight: 700;
  border: none;
  cursor: pointer;
  border-radius: var(--r2);
  transition: all .2s;
  letter-spacing: .2px;
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: var(--blue);
  color: #fff;
  padding: 12px 28px;
  box-shadow: 0 0 0 0 var(--blue-glow);
}
.btn-primary:hover {
  background: #5aa0ff;
  transform: translateY(-1px);
  box-shadow: var(--glow-blue);
}

.btn-ghost {
  background: var(--surface);
  color: var(--text2);
  padding: 11px 24px;
  border: 1px solid var(--border2);
}
.btn-ghost:hover {
  background: var(--bg3);
  color: var(--text);
  border-color: var(--border2);
}

.btn-amber {
  background: var(--amber);
  color: #0a0d14;
  padding: 12px 28px;
  font-weight: 800;
}
.btn-amber:hover {
  background: #fbbf24;
  box-shadow: var(--glow-amber);
  transform: translateY(-1px);
}

.btn-green {
  background: var(--green);
  color: #fff;
  padding: 8px 16px;
}
.btn-green:hover { background: #16a34a; }

.btn-sm { font-size: 12px; padding: 7px 14px; }
.btn-full { width: 100%; }
.btn:disabled { opacity: .5; cursor: not-allowed; transform: none !important; box-shadow: none !important; }

/* ── Inputs ── */
.field { margin-bottom: 18px; }

.field-label {
  display: block;
  font-family: 'Syne', sans-serif;
  font-size: 11px;
  font-weight: 700;
  color: var(--text3);
  letter-spacing: .8px;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.inp {
  width: 100%;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r2);
  padding: 12px 16px;
  font-family: 'DM Sans', sans-serif;
  font-size: 14px;
  color: var(--text);
  outline: none;
  transition: border-color .2s, box-shadow .2s;
}
.inp:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px var(--blue-dim);
}
.inp::placeholder { color: var(--text3); }
.inp.err { border-color: var(--red); box-shadow: 0 0 0 3px var(--red-dim); }

/* ── Cards ── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r3);
  padding: 24px;
}

/* ── Badges ── */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 20px;
  font-family: 'Syne', sans-serif;
  letter-spacing: .3px;
}
.badge-amber { background: var(--amber-dim); color: var(--amber); }
.badge-green { background: var(--green-dim); color: var(--green); }
.badge-blue  { background: var(--blue-dim);  color: var(--blue); }
.badge-red   { background: var(--red-dim);   color: var(--red); }

/* ── Error msg ── */
.err-msg {
  font-size: 12px;
  color: var(--red);
  margin-top: 6px;
  display: none;
}
.err-msg.show { display: block; }

/* ── Toast ── */
#toast {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  background: var(--surface);
  border: 1px solid var(--border2);
  color: var(--text);
  padding: 13px 24px;
  border-radius: var(--r);
  font-size: 14px;
  font-weight: 500;
  z-index: 9999;
  transition: transform .35s cubic-bezier(.34,1.56,.64,1);
  pointer-events: none;
  box-shadow: var(--shadow2);
  white-space: nowrap;
}
#toast.show { transform: translateX(-50%) translateY(0); }

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border2); border-radius: 3px; }

/* ── Utility ── */
.hidden { display: none !important; }
.text-blue   { color: var(--blue); }
.text-amber  { color: var(--amber); }
.text-green  { color: var(--green); }
.text-muted  { color: var(--text2); }
