:root {
  --bg: #0f1117;
  --panel: #1a1d27;
  --border: #2a2f3d;
  --text: #e8eaed;
  --muted: #8b92a5;
  --accent: #5b8def;
  --accent-hover: #4a7de0;
  --danger: #e57373;
  --success: #3d9a6a;
  --warn: #d4a017;
  --gradient: linear-gradient(135deg, #5b8def 0%, #7c5cff 100%);
}

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

body {
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.6;
}

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

a:hover {
  text-decoration: underline;
}

.hidden {
  display: none !important;
}

.page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
  background: rgba(26, 29, 39, 0.8);
  backdrop-filter: blur(8px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text);
  text-decoration: none;
  letter-spacing: -0.01em;
}

.brand:hover {
  text-decoration: none;
}

.brand-mark {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--gradient);
  display: grid;
  place-items: center;
  font-size: 0.9rem;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 8px;
  border: 1px solid transparent;
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s, transform 0.1s;
}

.btn:hover {
  text-decoration: none;
}

.btn:active {
  transform: scale(0.98);
}

.btn-primary {
  background: var(--accent);
  color: #fff;
}

.btn-primary:hover {
  background: var(--accent-hover);
}

.btn-ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--border);
}

.btn-ghost:hover {
  background: var(--panel);
  border-color: var(--muted);
}

.btn-block {
  width: 100%;
}

.hero {
  flex: 1;
  display: grid;
  place-items: center;
  padding: 48px 24px 64px;
}

.hero-inner {
  max-width: 720px;
  text-align: center;
}

.hero-badge {
  display: inline-block;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--panel);
  border: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.8rem;
  margin-bottom: 20px;
}

.hero h1 {
  font-size: clamp(2rem, 5vw, 2.75rem);
  line-height: 1.15;
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.hero-lead {
  font-size: 1.1rem;
  color: var(--muted);
  max-width: 560px;
  margin: 0 auto 32px;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin-bottom: 48px;
}

.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 16px;
  max-width: 560px;
  margin: 0 auto;
}

.feature {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px;
  text-align: center;
}

.feature-icon {
  font-size: 1.5rem;
  margin-bottom: 8px;
}

.feature-label {
  font-size: 0.85rem;
  color: var(--muted);
}

.page-footer {
  padding: 24px;
  text-align: center;
  color: var(--muted);
  font-size: 0.85rem;
  border-top: 1px solid var(--border);
}

.auth-screen {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px 24px;
}

.auth-card {
  width: 100%;
  max-width: 420px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 32px;
}

.auth-card h1 {
  font-size: 1.35rem;
  margin-bottom: 8px;
}

.auth-hint {
  color: var(--muted);
  font-size: 0.9rem;
  margin-bottom: 24px;
}

.field {
  margin-bottom: 16px;
}

.field label {
  display: block;
  font-size: 0.85rem;
  color: var(--muted);
  margin-bottom: 6px;
}

.field input {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg);
  color: var(--text);
  font-size: 1rem;
}

.field input:focus {
  outline: none;
  border-color: var(--accent);
}

.form-error {
  background: rgba(229, 115, 115, 0.12);
  border: 1px solid rgba(229, 115, 115, 0.35);
  color: var(--danger);
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 0.9rem;
  margin-bottom: 16px;
}

.form-success {
  background: rgba(61, 154, 106, 0.12);
  border: 1px solid rgba(61, 154, 106, 0.35);
  color: var(--success);
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 0.9rem;
  margin-bottom: 16px;
}

.auth-footer {
  margin-top: 20px;
  text-align: center;
  font-size: 0.9rem;
  color: var(--muted);
}

.status-screen {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px 24px;
}

.status-card {
  width: 100%;
  max-width: 480px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 36px;
  text-align: center;
}

.status-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  margin: 0 auto 20px;
  font-size: 1.5rem;
}

.status-icon.pending {
  background: rgba(212, 160, 23, 0.15);
  color: var(--warn);
}

.status-icon.billing {
  background: rgba(229, 115, 115, 0.15);
  color: var(--danger);
}

.status-card h1 {
  font-size: 1.3rem;
  margin-bottom: 12px;
}

.status-card p {
  color: var(--muted);
  margin-bottom: 8px;
}

.status-email {
  font-size: 0.9rem;
  color: var(--text);
  margin: 16px 0 24px;
}

.status-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: center;
}

@media (max-width: 480px) {
  .page-header {
    padding: 16px;
  }

  .auth-card,
  .status-card {
    padding: 24px;
  }

  .hero-cta {
    flex-direction: column;
  }

  .hero-cta .btn {
    width: 100%;
  }
}
