/* ============================================================
   SAWIX Trade — Ultra-premium tech trading platform CSS
   Design: Dark navy/black, gold (#f59e0b), blue (#3b82f6)
   ============================================================ */

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

:root {
  --bg-primary:    #030712;
  --bg-secondary:  #0b0f19;
  --bg-card:       rgba(17, 24, 39, 0.7);
  --bg-card-hover: rgba(31, 41, 55, 0.8);
  --border:        rgba(255, 255, 255, 0.05);
  --border-gold:   rgba(245, 158, 11, 0.25);
  --gold:          #d97706;
  --gold-light:    #fbbf24;
  --blue:          #2563eb;
  --blue-light:    #60a5fa;
  --green:         #10b981;
  --red:           #ef4444;
  --text-primary:  #f3f4f6;
  --text-secondary:#9ca3af;
  --text-muted:    #6b7280;
  --sidebar-width: 240px;
  --topbar-height: 64px;
  --radius:        16px;
  --radius-sm:     10px;
  --shadow:        0 10px 30px -10px rgba(0, 0, 0, 0.7);
  --shadow-gold:   0 0 25px rgba(245, 158, 11, 0.12);
  --transition:    300ms cubic-bezier(0.16, 1, 0.3, 1);
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: 'Outfit', sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  font-size: 15px;
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  letter-spacing: -0.02em;
}

a { color: var(--blue-light); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--gold); }

img { max-width: 100%; display: block; }

/* ============================================================
   LAYOUT — Sidebar + Main
   ============================================================ */

.app-layout {
  display: flex;
  min-height: 100vh;
}

/* ---- Sidebar ---- */
.sidebar {
  width: var(--sidebar-width);
  background: var(--bg-secondary);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  z-index: 40;
  transition: transform 0.3s ease;
}

.sidebar-logo {
  padding: 20px 20px 16px;
  border-bottom: 1px solid var(--border);
}

.sidebar-logo .logo-text {
  font-family: 'Orbitron', sans-serif;
  font-size: 18px;
  font-weight: 700;
  color: var(--gold);
  letter-spacing: 0.05em;
}

.sidebar-logo .logo-sub {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
}

.sidebar-nav {
  flex: 1;
  padding: 12px 0;
  overflow-y: auto;
}

.nav-section-label {
  font-size: 10px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 16px 20px 6px;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 20px;
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
  border-radius: 0;
  transition: all var(--transition);
  cursor: pointer;
  position: relative;
}

.nav-link svg { width: 18px; height: 18px; flex-shrink: 0; }

.nav-link:hover {
  color: var(--text-primary);
  background: rgba(255,255,255,0.04);
}

.nav-link.active {
  color: var(--gold);
  background: rgba(245,158,11,0.08);
}

.nav-link.active::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: var(--gold);
  border-radius: 0 3px 3px 0;
}

.sidebar-footer {
  padding: 16px 20px;
  border-top: 1px solid var(--border);
}

.sidebar-footer .user-email {
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ---- Topbar ---- */
.topbar {
  height: var(--topbar-height);
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  position: fixed;
  top: 0;
  left: var(--sidebar-width);
  right: 0;
  z-index: 30;
}

.topbar-left { display: flex; align-items: center; gap: 12px; }
.topbar-right { display: flex; align-items: center; gap: 16px; }

.topbar-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
}

.balance-chip {
  background: rgba(245,158,11,0.1);
  border: 1px solid var(--border-gold);
  border-radius: 20px;
  padding: 5px 14px;
  font-size: 13px;
  font-weight: 600;
  color: var(--gold);
  font-family: 'Orbitron', monospace;
}

.trial-badge {
  background: rgba(59,130,246,0.12);
  border: 1px solid rgba(59,130,246,0.3);
  border-radius: 20px;
  padding: 4px 12px;
  font-size: 11px;
  font-weight: 600;
  color: var(--blue-light);
}

.trial-badge.expired {
  background: rgba(239,68,68,0.1);
  border-color: rgba(239,68,68,0.3);
  color: #fca5a5;
}

/* ---- Main content ---- */
.main-content {
  margin-left: var(--sidebar-width);
  margin-top: var(--topbar-height);
  padding: 28px 28px;
  min-height: calc(100vh - var(--topbar-height));
  flex: 1;
}

/* ============================================================
   CARDS
   ============================================================ */

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.card:hover { border-color: rgba(255,255,255,0.12); }

.card-gold {
  border-color: var(--border-gold);
  box-shadow: var(--shadow-gold);
}

.card-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.07em;
  margin-bottom: 10px;
}

.card-value {
  font-family: 'Orbitron', monospace;
  font-size: 28px;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.2;
}

.card-value.gold { color: var(--gold); }
.card-value.green { color: var(--green); }
.card-value.red   { color: var(--red); }
.card-value.blue  { color: var(--blue-light); }

.card-sub {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 6px;
}

/* Stats grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 28px;
}

/* ============================================================
   BUTTONS
   ============================================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: all var(--transition);
  line-height: 1;
  white-space: nowrap;
}

.btn:disabled { opacity: 0.5; cursor: not-allowed; }

.btn-gold {
  background: linear-gradient(135deg, var(--gold), #d97706);
  color: #0a0f1e;
}
.btn-gold:hover { background: linear-gradient(135deg, var(--gold-light), var(--gold)); box-shadow: 0 4px 16px rgba(245,158,11,0.35); }

.btn-blue {
  background: linear-gradient(135deg, var(--blue), #1d4ed8);
  color: #fff;
}
.btn-blue:hover { background: linear-gradient(135deg, var(--blue-light), var(--blue)); box-shadow: 0 4px 16px rgba(59,130,246,0.35); }

.btn-green {
  background: linear-gradient(135deg, var(--green), #059669);
  color: #fff;
}
.btn-green:hover { background: linear-gradient(135deg, #34d399, var(--green)); box-shadow: 0 4px 16px rgba(16,185,129,0.35); }

.btn-red {
  background: linear-gradient(135deg, var(--red), #b91c1c);
  color: #fff;
}
.btn-red:hover { box-shadow: 0 4px 16px rgba(239,68,68,0.35); }

.btn-outline {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-secondary);
}
.btn-outline:hover { border-color: var(--gold); color: var(--gold); }

.btn-sm { padding: 6px 14px; font-size: 12px; }
.btn-lg { padding: 14px 28px; font-size: 16px; }
.btn-block { width: 100%; }

/* ============================================================
   TABLES
   ============================================================ */

.table-container {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.table-header {
  padding: 18px 24px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.table-header h3 {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
}

table {
  width: 100%;
  border-collapse: collapse;
}

thead th {
  background: rgba(255,255,255,0.02);
  padding: 12px 20px;
  text-align: left;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border-bottom: 1px solid var(--border);
}

tbody td {
  padding: 14px 20px;
  font-size: 13px;
  color: var(--text-secondary);
  border-bottom: 1px solid rgba(255,255,255,0.04);
}

tbody tr:last-child td { border-bottom: none; }

tbody tr:hover td { background: rgba(255,255,255,0.02); color: var(--text-primary); }

.symbol-cell {
  font-family: 'Orbitron', monospace;
  font-size: 12px;
  font-weight: 600;
  color: var(--gold);
}

.price-cell {
  font-family: 'Orbitron', monospace;
  font-size: 12px;
  font-weight: 500;
}

.pnl-positive { color: var(--green); font-weight: 600; }
.pnl-negative { color: var(--red); font-weight: 600; }
.pnl-zero { color: var(--text-muted); }

/* ============================================================
   FORMS
   ============================================================ */

.form-group { margin-bottom: 18px; }

label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 6px;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
select,
textarea {
  width: 100%;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  font-size: 14px;
  color: var(--text-primary);
  font-family: inherit;
  transition: border-color var(--transition), box-shadow var(--transition);
  outline: none;
}

input:focus, select:focus, textarea:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(59,130,246,0.1);
}

select option { background: var(--bg-card); color: var(--text-primary); }

textarea { resize: vertical; min-height: 100px; }

/* Toggle switch */
.toggle-wrapper {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
}

.toggle {
  position: relative;
  width: 44px;
  height: 24px;
}

.toggle input { opacity: 0; width: 0; height: 0; }

.toggle-slider {
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.1);
  border-radius: 24px;
  transition: background 0.3s;
  cursor: pointer;
}

.toggle-slider::before {
  content: '';
  position: absolute;
  width: 18px; height: 18px;
  left: 3px; top: 3px;
  background: var(--text-secondary);
  border-radius: 50%;
  transition: transform 0.3s, background 0.3s;
}

.toggle input:checked + .toggle-slider {
  background: var(--gold);
}

.toggle input:checked + .toggle-slider::before {
  transform: translateX(20px);
  background: #fff;
}

/* Checkboxes */
.pair-checkbox { display: flex; align-items: center; gap: 8px; cursor: pointer; }
.pair-checkbox input[type="checkbox"] { width: 16px; height: 16px; cursor: pointer; accent-color: var(--gold); }
.pair-checkbox span { font-size: 13px; color: var(--text-secondary); }
.pair-checkbox:hover span { color: var(--text-primary); }

/* ============================================================
   BADGES / STATUS CHIPS
   ============================================================ */

.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
}

.badge-gold   { background: rgba(245,158,11,0.12); color: var(--gold); border: 1px solid var(--border-gold); }
.badge-blue   { background: rgba(59,130,246,0.12); color: var(--blue-light); border: 1px solid rgba(59,130,246,0.3); }
.badge-green  { background: rgba(16,185,129,0.12); color: var(--green); border: 1px solid rgba(16,185,129,0.3); }
.badge-red    { background: rgba(239,68,68,0.1); color: #fca5a5; border: 1px solid rgba(239,68,68,0.3); }
.badge-gray   { background: rgba(255,255,255,0.06); color: var(--text-muted); border: 1px solid var(--border); }

.status-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  display: inline-block;
}
.dot-green  { background: var(--green); box-shadow: 0 0 6px var(--green); }
.dot-red    { background: var(--red); }
.dot-gold   { background: var(--gold); box-shadow: 0 0 6px var(--gold); }
.dot-gray   { background: var(--text-muted); }

/* ============================================================
   FLASH MESSAGES
   ============================================================ */

.flash-container {
  position: fixed;
  top: calc(var(--topbar-height) + 16px);
  right: 20px;
  z-index: 100;
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 380px;
}

.flash-message {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 500;
  border: 1px solid transparent;
  animation: slideIn 0.3s ease;
  backdrop-filter: blur(10px);
  cursor: pointer;
}

.flash-message.success {
  background: rgba(16,185,129,0.12);
  border-color: rgba(16,185,129,0.3);
  color: #6ee7b7;
}
.flash-message.danger {
  background: rgba(239,68,68,0.12);
  border-color: rgba(239,68,68,0.3);
  color: #fca5a5;
}
.flash-message.warning {
  background: rgba(245,158,11,0.1);
  border-color: var(--border-gold);
  color: var(--gold-light);
}
.flash-message.info {
  background: rgba(59,130,246,0.1);
  border-color: rgba(59,130,246,0.3);
  color: var(--blue-light);
}

@keyframes slideIn {
  from { transform: translateX(100%); opacity: 0; }
  to   { transform: translateX(0); opacity: 1; }
}

/* ============================================================
   LANDING PAGE
   ============================================================ */

.landing-body {
  background: var(--bg-primary);
  overflow-x: hidden;
}

/* Navbar */
.landing-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  background: rgba(10,15,30,0.85);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  padding: 0 5%;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.landing-nav .logo {
  font-family: 'Orbitron', sans-serif;
  font-size: 20px;
  font-weight: 700;
  color: var(--gold);
}

.landing-nav-links { display: flex; align-items: center; gap: 28px; }
.landing-nav-links a { font-size: 14px; color: var(--text-secondary); font-weight: 500; transition: color var(--transition); }
.landing-nav-links a:hover { color: var(--text-primary); }

.landing-nav-cta { display: flex; gap: 10px; }

/* Hero */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 100px 5% 80px;
  position: relative;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 50% at 50% 0%, rgba(245,158,11,0.08) 0%, transparent 70%),
    radial-gradient(ellipse 40% 40% at 80% 50%, rgba(59,130,246,0.06) 0%, transparent 60%),
    radial-gradient(ellipse 30% 30% at 20% 60%, rgba(16,185,129,0.04) 0%, transparent 50%);
}

.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 0%, transparent 100%);
}

.hero-content { position: relative; z-index: 2; max-width: 860px; margin: 0 auto; }

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(245,158,11,0.08);
  border: 1px solid var(--border-gold);
  border-radius: 20px;
  padding: 5px 16px;
  font-size: 12px;
  font-weight: 600;
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 24px;
}

.hero h1 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(32px, 5vw, 68px);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: 24px;
  background: linear-gradient(135deg, var(--text-primary) 30%, var(--gold-light) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-shadow: 0 0 40px rgba(255,255,255,0.05);
}

.hero p {
  font-size: clamp(15px, 1.5vw, 18px);
  color: var(--text-secondary);
  max-width: 580px;
  margin: 0 auto 36px;
  line-height: 1.7;
}

.hero-cta { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

.hero-stats {
  margin-top: 64px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 16px;
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}

.hero-stat {
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
}

.hero-stat-value {
  font-family: 'Orbitron', monospace;
  font-size: 24px;
  font-weight: 700;
  color: var(--gold);
}

.hero-stat-label {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
}

/* Section */
.section {
  padding: 80px 5%;
  max-width: 1200px;
  margin: 0 auto;
}

.section-eyebrow {
  font-size: 11px;
  font-weight: 600;
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 12px;
}

.section-title {
  font-family: 'Orbitron', sans-serif;
  font-size: clamp(24px, 3vw, 40px);
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.section-subtitle {
  font-size: 16px;
  color: var(--text-secondary);
  max-width: 580px;
  margin-bottom: 52px;
  line-height: 1.7;
}

/* Features grid */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}

.feature-card:hover {
  border-color: var(--border-gold);
  box-shadow: var(--shadow-gold);
  transform: translateY(-2px);
}

.feature-icon {
  width: 48px; height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.feature-icon.gold  { background: rgba(245,158,11,0.1); color: var(--gold); }
.feature-icon.blue  { background: rgba(59,130,246,0.1); color: var(--blue-light); }
.feature-icon.green { background: rgba(16,185,129,0.1); color: var(--green); }

.feature-card h3 { font-size: 16px; font-weight: 700; color: var(--text-primary); margin-bottom: 8px; }
.feature-card p  { font-size: 14px; color: var(--text-secondary); line-height: 1.65; }

/* How it works */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 24px;
}

.step-card {
  text-align: center;
  padding: 32px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.step-number {
  font-family: 'Orbitron', monospace;
  font-size: 36px;
  font-weight: 700;
  color: var(--gold);
  opacity: 0.4;
  margin-bottom: 12px;
}

.step-card h3 { font-size: 15px; font-weight: 700; color: var(--text-primary); margin-bottom: 8px; }
.step-card p  { font-size: 13px; color: var(--text-secondary); }

/* Pricing */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  max-width: 700px;
  margin: 0 auto;
}

.pricing-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 36px;
  position: relative;
  overflow: hidden;
}

.pricing-card.featured {
  border-color: var(--border-gold);
  box-shadow: var(--shadow-gold);
}

.pricing-card.featured::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--gold), var(--gold-light));
}

.pricing-tag {
  display: inline-block;
  background: rgba(245,158,11,0.1);
  color: var(--gold);
  font-size: 11px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 20px;
  margin-bottom: 14px;
}

.pricing-price {
  font-family: 'Orbitron', monospace;
  font-size: 40px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.pricing-price sup { font-size: 18px; color: var(--gold); }
.pricing-period { font-size: 13px; color: var(--text-muted); margin-bottom: 24px; }

.pricing-features { list-style: none; margin-bottom: 28px; }
.pricing-features li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 0;
  font-size: 14px;
  color: var(--text-secondary);
  border-bottom: 1px solid rgba(255,255,255,0.04);
}
.pricing-features li:last-child { border-bottom: none; }
.pricing-features li svg { color: var(--green); flex-shrink: 0; }

/* Spots gauge */
.spots-bar {
  background: rgba(255,255,255,0.06);
  border-radius: 20px;
  height: 8px;
  overflow: hidden;
  margin: 12px 0;
}

.spots-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--green), var(--gold));
  border-radius: 20px;
  transition: width 0.5s ease;
}

/* Footer */
.landing-footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  padding: 40px 5%;
  text-align: center;
}

.footer-logo {
  font-family: 'Orbitron', sans-serif;
  font-size: 22px;
  font-weight: 700;
  color: var(--gold);
  margin-bottom: 12px;
}

.footer-links { display: flex; justify-content: center; gap: 24px; flex-wrap: wrap; margin-bottom: 16px; }
.footer-links a { font-size: 13px; color: var(--text-muted); }
.footer-links a:hover { color: var(--text-primary); }

.footer-copy { font-size: 12px; color: var(--text-muted); }

/* ============================================================
   AUTH PAGES
   ============================================================ */

.auth-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: var(--bg-primary);
  position: relative;
}

.auth-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 50% 60% at 30% 40%, rgba(59,130,246,0.05) 0%, transparent 60%),
    radial-gradient(ellipse 40% 50% at 70% 60%, rgba(245,158,11,0.05) 0%, transparent 60%);
}

.auth-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 40px;
  width: 100%;
  max-width: 440px;
  position: relative;
  z-index: 1;
  box-shadow: 0 24px 64px rgba(0,0,0,0.5);
}

.auth-logo {
  font-family: 'Orbitron', sans-serif;
  font-size: 22px;
  font-weight: 700;
  color: var(--gold);
  text-align: center;
  margin-bottom: 6px;
}

.auth-subtitle {
  font-size: 13px;
  color: var(--text-muted);
  text-align: center;
  margin-bottom: 32px;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
  color: var(--text-muted);
  font-size: 12px;
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

/* ============================================================
   PRICE TICKER
   ============================================================ */

.price-ticker {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: 'Orbitron', monospace;
  font-size: 12px;
}

.price-up { color: var(--green); }
.price-down { color: var(--red); }

/* ============================================================
   PAIR GRID (Trade page)
   ============================================================ */

.pair-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 10px;
}

.pair-btn {
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition);
}

.pair-btn:hover {
  border-color: var(--border-gold);
  background: rgba(245,158,11,0.04);
}

.pair-btn.selected {
  border-color: var(--gold);
  background: rgba(245,158,11,0.08);
}

.pair-btn .pair-name {
  font-family: 'Orbitron', monospace;
  font-size: 11px;
  font-weight: 600;
  color: var(--gold);
  margin-bottom: 4px;
}

.pair-btn .pair-price {
  font-size: 13px;
  color: var(--text-secondary);
}

/* ============================================================
   ADMIN
   ============================================================ */

.admin-topbar-title {
  font-family: 'Orbitron', sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: var(--gold);
  letter-spacing: 0.05em;
}

.admin-badge {
  background: rgba(245,158,11,0.1);
  border: 1px solid var(--border-gold);
  color: var(--gold);
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* Registration gauge */
.gauge-bar {
  height: 10px;
  background: rgba(255,255,255,0.06);
  border-radius: 10px;
  overflow: hidden;
  margin: 10px 0 6px;
}

.gauge-fill {
  height: 100%;
  border-radius: 10px;
  background: linear-gradient(90deg, var(--blue), var(--gold));
  transition: width 0.6s ease;
}

/* ============================================================
   UTILS
   ============================================================ */

.text-gold  { color: var(--gold); }
.text-blue  { color: var(--blue-light); }
.text-green { color: var(--green); }
.text-red   { color: var(--red); }
.text-muted { color: var(--text-muted); }
.text-sm    { font-size: 13px; }
.text-xs    { font-size: 12px; }
.text-mono  { font-family: 'Orbitron', monospace; }

.mt-0  { margin-top: 0; }
.mt-1  { margin-top: 6px; }
.mt-2  { margin-top: 12px; }
.mt-4  { margin-top: 24px; }
.mt-6  { margin-top: 36px; }
.mb-2  { margin-bottom: 12px; }
.mb-4  { margin-bottom: 24px; }
.mb-6  { margin-bottom: 36px; }

.flex   { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-2  { gap: 10px; }
.gap-4  { gap: 20px; }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }

.page-title {
  font-family: 'Orbitron', sans-serif;
  font-size: 22px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.page-subtitle {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 28px;
}

.section-divider {
  height: 1px;
  background: var(--border);
  margin: 28px 0;
}

/* KSA SAR symbol styling */
.sar-symbol {
  font-size: 11px;
  color: var(--gold);
  font-weight: 700;
}

/* API Connection status */
.api-connection-card {
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  margin-bottom: 12px;
}

.api-connection-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.api-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

.api-fields { display: grid; gap: 10px; }

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 1024px) {
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  .sidebar {
    transform: translateX(-100%);
  }
  .sidebar.open {
    transform: translateX(0);
  }
  .topbar {
    left: 0;
  }
  .main-content {
    margin-left: 0;
    padding: 16px;
  }
  .grid-2 { grid-template-columns: 1fr; }
  .grid-3 { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .landing-nav-links { display: none; }
  .hero h1 { font-size: 28px; }
  .features-grid { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .stats-grid { grid-template-columns: 1fr; }
  .auth-card { padding: 28px 20px; }
  .hero-cta { flex-direction: column; align-items: center; }
}

/* Scrollbar */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.1); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.2); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}
