:root {
  --bg: #0f1419;
  --bg-card: #1a2230;
  --bg-elev: #222c3d;
  --accent: #2dd4bf;
  --accent-2: #3b82f6;
  --accent-hover: #14b8a6;
  --text: #e6edf3;
  --text-dim: #8b98a9;
  --border: #2a3546;
  --danger: #ef4444;
  --success: #22c55e;
  --warning: #f59e0b;
  --radius: 14px;
  --shadow: 0 10px 30px rgba(0,0,0,.35);
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); }

.container { max-width: 1140px; margin: 0 auto; padding: 0 20px; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(15,20,25,.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.site-header .container {
  display: flex; align-items: center; justify-content: space-between;
  height: 64px;
}
.logo { font-size: 22px; font-weight: 800; letter-spacing: -.5px; color: var(--text); display: flex; align-items: center; gap: 8px; }
.logo span { color: var(--accent); }
.nav { display: flex; align-items: center; gap: 16px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 22px; border-radius: 10px; font-size: 15px; font-weight: 600;
  border: none; cursor: pointer; transition: all .18s ease; white-space: nowrap;
}
.btn-primary { background: linear-gradient(135deg, var(--accent), var(--accent-2)); color: #06121a; }
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 8px 20px rgba(45,212,191,.3); color: #06121a; }
.btn-ghost { background: transparent; color: var(--text); border: 1px solid var(--border); }
.btn-ghost:hover { background: var(--bg-elev); color: var(--text); }
.btn-block { width: 100%; }
.btn-lg { padding: 15px 30px; font-size: 17px; }
.btn:disabled { opacity: .5; cursor: not-allowed; transform: none; }

/* Hero */
.hero { padding: 90px 0 70px; text-align: center; }
.hero h1 { font-size: 52px; font-weight: 800; letter-spacing: -1.5px; line-height: 1.1; margin-bottom: 20px; }
.hero h1 .grad { background: linear-gradient(135deg, var(--accent), var(--accent-2)); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.hero p.lead { font-size: 20px; color: var(--text-dim); max-width: 640px; margin: 0 auto 36px; }
.hero-cta { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* Sections */
.section { padding: 70px 0; }
.section h2 { font-size: 36px; font-weight: 800; text-align: center; margin-bottom: 12px; letter-spacing: -.8px; }
.section .subtitle { text-align: center; color: var(--text-dim); font-size: 18px; margin-bottom: 48px; }

/* Feature grid */
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.feature {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 28px;
}
.feature .ico { font-size: 30px; margin-bottom: 14px; }
.feature h3 { font-size: 19px; margin-bottom: 8px; }
.feature p { color: var(--text-dim); font-size: 15px; }

/* Pricing */
.pricing-card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 20px; padding: 40px; max-width: 460px; margin: 0 auto;
  box-shadow: var(--shadow); text-align: center;
}
.pricing-card .price { font-size: 56px; font-weight: 800; letter-spacing: -2px; }
.pricing-card .price small { font-size: 20px; color: var(--text-dim); font-weight: 500; }
.pricing-card ul { list-style: none; text-align: left; margin: 28px 0; }
.pricing-card ul li { padding: 9px 0; display: flex; align-items: center; gap: 10px; color: var(--text); border-bottom: 1px solid var(--border); }
.pricing-card ul li::before { content: '✓'; color: var(--accent); font-weight: 800; }

.months-select { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; margin: 20px 0; }
.month-opt {
  padding: 10px 16px; border: 1px solid var(--border); border-radius: 10px;
  cursor: pointer; transition: all .15s; background: var(--bg-elev); font-weight: 600;
}
.month-opt:hover { border-color: var(--accent); }
.month-opt.active { background: var(--accent); color: #06121a; border-color: var(--accent); }

/* Auth */
.auth-wrap { min-height: calc(100vh - 64px); display: flex; align-items: center; justify-content: center; padding: 40px 20px; }
.auth-card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 20px; padding: 40px; width: 100%; max-width: 420px; box-shadow: var(--shadow);
}
.auth-card h1 { font-size: 28px; margin-bottom: 6px; text-align: center; }
.auth-card .sub { text-align: center; color: var(--text-dim); margin-bottom: 28px; }
.tabs { display: flex; background: var(--bg-elev); border-radius: 10px; padding: 4px; margin-bottom: 24px; }
.tab { flex: 1; padding: 10px; text-align: center; border-radius: 8px; cursor: pointer; font-weight: 600; color: var(--text-dim); transition: all .15s; }
.tab.active { background: var(--accent); color: #06121a; }

.field { margin-bottom: 16px; }
.field label { display: block; font-size: 14px; color: var(--text-dim); margin-bottom: 6px; }
.field input {
  width: 100%; padding: 13px 14px; background: var(--bg-elev);
  border: 1px solid var(--border); border-radius: 10px; color: var(--text);
  font-size: 15px; transition: border-color .15s;
}
.field input:focus { outline: none; border-color: var(--accent); }
.row-2 { display: flex; gap: 12px; }
.row-2 .field { flex: 1; }

/* Alerts */
.alert { padding: 12px 16px; border-radius: 10px; margin-bottom: 16px; font-size: 14px; display: none; }
.alert.show { display: block; }
.alert-error { background: rgba(239,68,68,.12); border: 1px solid rgba(239,68,68,.3); color: #fca5a5; }
.alert-success { background: rgba(34,197,94,.12); border: 1px solid rgba(34,197,94,.3); color: #86efac; }
.alert-warning { background: rgba(245,158,11,.12); border: 1px solid rgba(245,158,11,.3); color: #fcd34d; }

/* Dashboard */
.dash { padding: 36px 0 70px; }
.dash-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; margin-top: 24px; }
.card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 26px;
}
.card h3 { font-size: 18px; margin-bottom: 16px; display: flex; align-items: center; gap: 8px; }
.card.full { grid-column: 1 / -1; }
.badge { display: inline-block; padding: 4px 12px; border-radius: 20px; font-size: 13px; font-weight: 700; }
.badge-active { background: rgba(34,197,94,.15); color: var(--success); }
.badge-inactive { background: rgba(139,152,169,.15); color: var(--text-dim); }
.badge-expired { background: rgba(239,68,68,.15); color: var(--danger); }
.stat-row { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid var(--border); }
.stat-row:last-child { border-bottom: none; }
.stat-row .k { color: var(--text-dim); }
.stat-row .v { font-weight: 700; }
.ref-code {
  font-family: 'SF Mono', Menlo, monospace; font-size: 24px; font-weight: 800;
  letter-spacing: 3px; background: var(--bg-elev); padding: 14px; border-radius: 10px;
  text-align: center; border: 1px dashed var(--accent); color: var(--accent); margin-bottom: 14px;
}
.welcome { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px; }
.welcome h1 { font-size: 30px; }
.welcome .email { color: var(--text-dim); }

/* Footer */
.site-footer { border-top: 1px solid var(--border); padding: 36px 0; text-align: center; color: var(--text-dim); font-size: 14px; }

.hidden { display: none !important; }
.text-dim { color: var(--text-dim); }
.mt-16 { margin-top: 16px; }
.center { text-align: center; }

@media (max-width: 860px) {
  .features { grid-template-columns: 1fr; }
  .dash-grid { grid-template-columns: 1fr; }
  .hero h1 { font-size: 38px; }
  .hero p.lead { font-size: 17px; }
  .section h2 { font-size: 28px; }
}
