/* ── Reset & Base ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
:root {
    --bg: #0a0a0f;
    --surface: #12121a;
    --surface2: #1a1a26;
    --border: #2a2a3a;
    --text: #e4e4ef;
    --text-muted: #8888a0;
    --primary: #6c5ce7;
    --primary-glow: #7c6cf7;
    --accent: #00cec9;
    --success: #00b894;
    --warning: #fdcb6e;
    --danger: #e17055;
    --radius: 8px;
    --radius-lg: 12px;
}
body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; background: var(--bg); color: var(--text); line-height: 1.6; min-height: 100vh; display: flex; flex-direction: column; }
a { color: var(--primary-glow); text-decoration: none; }
a:hover { text-decoration: underline; }
.container { max-width: 1100px; margin: 0 auto; padding: 0 20px; width: 100%; }

/* ── Navbar ── */
.navbar { background: var(--surface); border-bottom: 1px solid var(--border); padding: 14px 0; position: sticky; top: 0; z-index: 100; }
.nav-inner { display: flex; align-items: center; justify-content: space-between; }
.logo { font-size: 1.3rem; font-weight: 700; color: var(--text); }
.logo .accent { color: var(--accent); }
.nav-links { display: flex; align-items: center; gap: 20px; }
.nav-links a { color: var(--text-muted); font-size: 0.9rem; }
.nav-links a:hover { color: var(--text); text-decoration: none; }
.nav-email { color: var(--text-muted); font-size: 0.85rem; }

/* ── Buttons ── */
.btn { display: inline-block; padding: 10px 22px; border-radius: var(--radius); font-size: 0.9rem; font-weight: 600; border: none; cursor: pointer; transition: all 0.2s; text-align: center; }
.btn-sm { padding: 6px 14px; font-size: 0.82rem; }
.btn-primary { background: var(--primary); color: white; }
.btn-primary:hover { background: var(--primary-glow); text-decoration: none; }
.btn-outline { background: transparent; border: 1px solid var(--border); color: var(--text); }
.btn-outline:hover { border-color: var(--text-muted); text-decoration: none; }
.btn-danger { background: var(--danger); color: white; }
.btn-danger:hover { opacity: 0.85; text-decoration: none; }
.btn-accent { background: var(--accent); color: var(--bg); }
.btn-accent:hover { opacity: 0.85; text-decoration: none; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }

/* ── Cards ── */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 24px; margin-bottom: 20px; }
.card h3 { margin-bottom: 16px; font-size: 1.1rem; }
.card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }

/* ── Stats ── */
.stat { text-align: center; }
.stat-value { font-size: 2rem; font-weight: 700; color: var(--accent); }
.stat-label { font-size: 0.85rem; color: var(--text-muted); margin-top: 4px; }

/* ── Tables ── */
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 12px 16px; border-bottom: 1px solid var(--border); }
th { color: var(--text-muted); font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.05em; font-weight: 600; }
td { font-size: 0.9rem; }
.badge { display: inline-block; padding: 3px 10px; border-radius: 20px; font-size: 0.78rem; font-weight: 600; }
.badge-active { background: rgba(0, 184, 148, 0.15); color: var(--success); }
.badge-cancelled { background: rgba(225, 112, 85, 0.15); color: var(--danger); }
.badge-starter { background: rgba(136, 136, 160, 0.15); color: var(--text-muted); }
.badge-growth { background: rgba(108, 92, 231, 0.15); color: var(--primary-glow); }
.badge-enterprise { background: rgba(0, 206, 201, 0.15); color: var(--accent); }

/* ── Forms ── */
.form-group { margin-bottom: 18px; }
.form-group label { display: block; margin-bottom: 6px; font-size: 0.9rem; color: var(--text-muted); }
input[type="text"], input[type="email"], input[type="password"], select {
    width: 100%; padding: 10px 14px; background: var(--bg); border: 1px solid var(--border);
    border-radius: var(--radius); color: var(--text); font-size: 0.9rem;
}
input:focus, select:focus { outline: none; border-color: var(--primary); }

/* ── Alerts ── */
.alert { padding: 14px 18px; border-radius: var(--radius); margin-bottom: 20px; font-size: 0.9rem; }
.alert-info { background: rgba(108, 92, 231, 0.12); border: 1px solid rgba(108, 92, 231, 0.25); color: var(--primary-glow); }
.alert-success { background: rgba(0, 184, 148, 0.12); border: 1px solid rgba(0, 184, 148, 0.25); color: var(--success); }
.alert-error { background: rgba(225, 112, 85, 0.12); border: 1px solid rgba(225, 112, 85, 0.25); color: var(--danger); }

/* ── Landing ── */
.hero { text-align: center; padding: 80px 20px 60px; }
.hero h1 { font-size: 3rem; font-weight: 800; margin-bottom: 16px; }
.hero h1 .accent { color: var(--accent); }
.hero p { font-size: 1.2rem; color: var(--text-muted); max-width: 600px; margin: 0 auto 32px; }
.hero-actions { display: flex; gap: 14px; justify-content: center; }
.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 24px; padding: 40px 0 80px; }
.feature { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 28px; }
.feature h3 { color: var(--accent); margin-bottom: 8px; }
.feature p { color: var(--text-muted); font-size: 0.92rem; }

/* ── Pricing ── */
.pricing-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; margin-top: 24px; }
.pricing-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 28px; text-align: center; }
.pricing-card.featured { border-color: var(--primary); }
.pricing-card h4 { font-size: 1.1rem; margin-bottom: 8px; }
.pricing-price { font-size: 2.2rem; font-weight: 700; }
.pricing-price span { font-size: 0.9rem; color: var(--text-muted); font-weight: 400; }
.pricing-features { list-style: none; margin: 18px 0; text-align: left; }
.pricing-features li { padding: 6px 0; font-size: 0.9rem; color: var(--text-muted); }
.pricing-features li::before { content: "✓ "; color: var(--success); font-weight: 700; }

/* ── Progress bar ── */
.progress-bar { background: var(--surface2); border-radius: 10px; height: 10px; overflow: hidden; margin-top: 8px; }
.progress-fill { height: 100%; background: var(--accent); border-radius: 10px; transition: width 0.4s; }
.progress-fill.warning { background: var(--warning); }
.progress-fill.danger { background: var(--danger); }

/* ── Page header ── */
.page-header { padding: 32px 0 24px; }
.page-header h1 { font-size: 1.8rem; font-weight: 700; }
.page-header p { color: var(--text-muted); margin-top: 4px; }

/* ── Login ── */
.login-wrapper { max-width: 420px; margin: 80px auto; }

/* ── Key display ── */
.key-display { background: var(--bg); border: 1px solid var(--border); padding: 12px 16px; border-radius: var(--radius); font-family: monospace; font-size: 0.88rem; word-break: break-all; }

/* ── Footer ── */
.footer { margin-top: auto; padding: 24px 0; border-top: 1px solid var(--border); text-align: center; }
.footer p { color: var(--text-muted); font-size: 0.82rem; }
main { flex: 1; }

/* ── Modal ── */
.modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.7); z-index: 1000; display: flex; align-items: center; justify-content: center; }
.modal-overlay.hidden { display: none; }
.modal { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 32px; max-width: 520px; width: 90%; }
.modal h2 { font-size: 1.3rem; margin-bottom: 8px; }
.modal .modal-warning { color: var(--warning); font-size: 0.9rem; margin-bottom: 16px; }
.modal .key-box { background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 16px; font-family: 'Courier New', monospace; font-size: 0.92rem; word-break: break-all; user-select: all; margin-bottom: 16px; color: var(--accent); }
.modal .modal-actions { display: flex; flex-direction: column; gap: 12px; }
.modal .copy-btn { width: 100%; }
.modal .save-check { display: flex; align-items: center; gap: 8px; font-size: 0.9rem; color: var(--text-muted); cursor: pointer; }
.modal .save-check input { width: 18px; height: 18px; accent-color: var(--primary); cursor: pointer; }
.modal .done-btn { width: 100%; }

/* ── Responsive ── */
@media (max-width: 768px) {
    .hero h1 { font-size: 2rem; }
    .nav-links { gap: 12px; }
    .card-grid { grid-template-columns: 1fr; }
}
