/* ================================================================
   CatalogIQ — Premium SaaS Template
   ================================================================ */

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

:root {
    --primary: #7c3aed;
    --primary-dark: #6d28d9;
    --primary-darker: #5b21b6;
    --primary-light: #ede9fe;
    --primary-glow: rgba(124, 58, 237, 0.15);
    --accent: #f59e0b;
    --text: #0f172a;
    --text-secondary: #475569;
    --text-muted: #94a3b8;
    --bg: #ffffff;
    --bg-alt: #f8fafc;
    --bg-dark: #0f172a;
    --border: #e2e8f0;
    --border-light: #f1f5f9;
    --success: #059669;
    --success-bg: #ecfdf5;
    --success-border: #a7f3d0;
    --warning: #d97706;
    --warning-bg: #fffbeb;
    --warning-border: #fde68a;
    --danger: #dc2626;
    --danger-bg: #fef2f2;
    --danger-border: #fecaca;
    --radius: 12px;
    --radius-lg: 20px;
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
    --shadow: 0 4px 6px -1px rgba(0,0,0,0.07), 0 2px 4px -2px rgba(0,0,0,0.05);
    --shadow-md: 0 10px 25px -5px rgba(0,0,0,0.08), 0 8px 10px -6px rgba(0,0,0,0.04);
    --shadow-lg: 0 20px 50px -12px rgba(0,0,0,0.12);
    --shadow-glow: 0 0 40px rgba(124,58,237,0.12);
}

html { scroll-behavior: smooth; }

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: var(--text);
    background: var(--bg);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

a { color: var(--primary); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--primary-dark); }

img { max-width: 100%; height: auto; }

/* --- Layout --- */
.container { max-width: 1140px; margin: 0 auto; padding: 0 24px; }
.container-sm { max-width: 720px; margin: 0 auto; padding: 0 24px; }

/* --- Animations --- */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }

/* ================================================================
   NAV
   ================================================================ */
nav {
    position: fixed; top: 0; left: 0; right: 0; z-index: 100;
    padding: 0 0;
    transition: background 0.3s, box-shadow 0.3s, padding 0.3s;
}
nav.scrolled {
    background: rgba(255,255,255,0.92);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}
.nav-inner {
    display: flex; align-items: center; justify-content: space-between;
    padding: 18px 0;
    transition: padding 0.3s;
}
nav.scrolled .nav-inner { padding: 12px 0; }
.logo { font-size: 22px; font-weight: 800; color: var(--text); letter-spacing: -0.5px; }
.logo span { color: var(--primary); }
.nav-links { display: flex; align-items: center; gap: 32px; }
.nav-links a { color: var(--text-secondary); font-size: 14px; font-weight: 500; transition: color 0.2s; }
.nav-links a:hover { color: var(--primary); }
.nav-cta {
    background: var(--primary); color: #fff !important; padding: 8px 20px;
    border-radius: 8px; font-weight: 600; font-size: 13px;
    transition: background 0.2s, transform 0.15s;
}
.nav-cta:hover { background: var(--primary-dark); transform: translateY(-1px); color: #fff !important; }

/* Mobile nav */
.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 4px; }
.nav-toggle svg { width: 24px; height: 24px; color: var(--text); }

/* ================================================================
   BUTTONS
   ================================================================ */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 12px 28px; border-radius: 10px; font-weight: 600; font-size: 15px;
    border: none; cursor: pointer;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative; overflow: hidden;
}
.btn-lg { padding: 16px 36px; font-size: 16px; border-radius: 12px; }
.btn-primary {
    background: var(--primary); color: #fff;
    box-shadow: 0 4px 14px rgba(124,58,237,0.3);
}
.btn-primary:hover {
    background: var(--primary-dark);
    box-shadow: 0 6px 20px rgba(124,58,237,0.4);
    transform: translateY(-2px);
}
.btn-outline {
    background: transparent; color: var(--primary);
    border: 2px solid var(--primary);
}
.btn-outline:hover {
    background: var(--primary-light);
    transform: translateY(-2px);
}
.btn-white {
    background: #fff; color: var(--primary);
    box-shadow: var(--shadow);
}
.btn-white:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.btn:disabled { opacity: 0.55; cursor: not-allowed; transform: none !important; }

/* ================================================================
   HERO
   ================================================================ */
.hero {
    position: relative;
    padding: 160px 0 100px;
    overflow: hidden;
    background: linear-gradient(135deg, #f5f3ff 0%, #ede9fe 30%, #e0e7ff 60%, #f0f9ff 100%);
}
.hero::before {
    content: '';
    position: absolute; top: -50%; right: -20%; width: 800px; height: 800px;
    background: radial-gradient(circle, rgba(124,58,237,0.08) 0%, transparent 70%);
    border-radius: 50%;
}
.hero::after {
    content: '';
    position: absolute; bottom: -30%; left: -10%; width: 600px; height: 600px;
    background: radial-gradient(circle, rgba(245,158,11,0.06) 0%, transparent 70%);
    border-radius: 50%;
}
.hero .container { position: relative; z-index: 1; }

.hero-content { max-width: 680px; margin: 0 auto; text-align: center; }
.hero-badge {
    display: inline-flex; align-items: center; gap: 8px;
    background: #fff; padding: 6px 16px 6px 8px;
    border-radius: 50px; font-size: 13px; font-weight: 600;
    color: var(--text-secondary); border: 1px solid var(--border);
    margin-bottom: 28px; box-shadow: var(--shadow-sm);
}
.hero-badge-dot {
    width: 8px; height: 8px; border-radius: 50%;
    background: var(--success);
    box-shadow: 0 0 8px rgba(5,150,105,0.4);
    animation: pulse-dot 2s ease-in-out infinite;
}
@keyframes pulse-dot {
    0%, 100% { box-shadow: 0 0 4px rgba(5,150,105,0.3); }
    50% { box-shadow: 0 0 12px rgba(5,150,105,0.6); }
}

.hero h1 {
    font-size: 54px; font-weight: 800; line-height: 1.1;
    letter-spacing: -1.5px; margin-bottom: 20px;
    color: var(--text);
}
.hero h1 .gradient {
    background: linear-gradient(135deg, var(--primary) 0%, #a855f7 50%, var(--accent) 100%);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    background-clip: text;
}
.hero p {
    font-size: 19px; color: var(--text-secondary); max-width: 520px;
    margin: 0 auto 36px; line-height: 1.7;
}
.hero-buttons { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ================================================================
   STATS BAR
   ================================================================ */
.stats-bar {
    background: var(--bg-dark);
    padding: 36px 0;
}
.stats-grid {
    display: grid; grid-template-columns: repeat(4, 1fr);
    gap: 24px; text-align: center;
}
.stat-item {}
.stat-value {
    font-size: 32px; font-weight: 800; color: #fff;
    letter-spacing: -0.5px;
}
.stat-value span { color: var(--primary); }
.stat-label { font-size: 13px; color: var(--text-muted); margin-top: 4px; font-weight: 500; }

/* ================================================================
   SECTIONS
   ================================================================ */
section { padding: 88px 0; }
section.alt { background: var(--bg-alt); }

.section-header { text-align: center; max-width: 560px; margin: 0 auto 52px; }
.section-label {
    display: inline-block;
    font-size: 13px; font-weight: 700; text-transform: uppercase;
    letter-spacing: 1.5px; color: var(--primary);
    margin-bottom: 12px;
}
.section-title {
    font-size: 36px; font-weight: 800; line-height: 1.2;
    letter-spacing: -0.5px; margin-bottom: 14px;
    color: var(--text);
}
.section-subtitle {
    font-size: 17px; color: var(--text-secondary); line-height: 1.7;
}

/* ================================================================
   HOW IT WORKS
   ================================================================ */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.step {
    background: var(--bg); border: 1px solid var(--border);
    border-radius: var(--radius-lg); padding: 36px 28px;
    transition: transform 0.3s, box-shadow 0.3s;
    position: relative;
}
.step:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
}
.step-icon {
    width: 52px; height: 52px; border-radius: 14px;
    background: var(--primary-light);
    display: flex; align-items: center; justify-content: center;
    margin-bottom: 20px;
}
.step-icon svg { width: 24px; height: 24px; color: var(--primary); }
.step h3 { font-size: 18px; font-weight: 700; margin-bottom: 8px; }
.step p { font-size: 14px; color: var(--text-secondary); line-height: 1.7; }

/* Connector line between steps */
.step-connector {
    display: flex; align-items: center; justify-content: center;
    color: var(--text-muted); font-size: 20px;
}

/* ================================================================
   FEATURES
   ================================================================ */
.features-grid {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px;
}
.feature-card {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 32px 24px;
    transition: transform 0.3s, box-shadow 0.3s, border-color 0.3s;
}
.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary);
}
.feature-icon {
    width: 44px; height: 44px; border-radius: 10px;
    background: var(--primary-light);
    display: flex; align-items: center; justify-content: center;
    margin-bottom: 16px;
}
.feature-icon svg { width: 22px; height: 22px; color: var(--primary); }
.feature-card h3 { font-size: 16px; font-weight: 700; margin-bottom: 8px; }
.feature-card p { font-size: 14px; color: var(--text-secondary); line-height: 1.6; }

/* ================================================================
   UNDERWRITING TOOL
   ================================================================ */
.tool-grid {
    display: grid; grid-template-columns: 380px 1fr; gap: 36px; align-items: start;
}
.tool-form {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 32px;
    box-shadow: var(--shadow);
    position: sticky; top: 90px;
}
.tool-form h3 {
    font-size: 18px; font-weight: 700; margin-bottom: 24px;
    display: flex; align-items: center; gap: 10px;
}
.field { margin-bottom: 18px; }
.field label {
    display: block; font-size: 13px; font-weight: 600;
    color: var(--text); margin-bottom: 6px;
}
.field input, .field select {
    width: 100%; padding: 11px 14px; border: 1.5px solid var(--border);
    border-radius: 9px; font-size: 14px; color: var(--text);
    background: var(--bg); transition: border-color 0.2s, box-shadow 0.2s;
    font-family: inherit;
}
.field input:focus, .field select:focus {
    outline: none; border-color: var(--primary);
    box-shadow: 0 0 0 4px var(--primary-glow);
}
.field select { cursor: pointer; appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%2394a3b8' viewBox='0 0 16 16'%3E%3Cpath d='M4.5 6l3.5 4 3.5-4z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 36px; }

.upload-area {
    border: 2px dashed var(--border); border-radius: var(--radius);
    padding: 32px 20px; text-align: center;
    cursor: pointer; transition: all 0.2s;
    position: relative; background: var(--bg-alt);
}
.upload-area:hover, .upload-area.dragover {
    border-color: var(--primary); background: var(--primary-light);
}
.upload-area input[type="file"] { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.upload-icon { margin-bottom: 10px; color: var(--text-muted); }
.upload-icon svg { width: 36px; height: 36px; }
.upload-area p { font-size: 14px; color: var(--text-secondary); }
.upload-area .hint { font-size: 12px; color: var(--text-muted); margin-top: 4px; }
.upload-area .file-name {
    font-size: 13px; color: var(--primary); font-weight: 600;
    margin-top: 8px;
}

/* ================================================================
   RESULTS
   ================================================================ */
.results { min-height: 200px; }
.results-placeholder {
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    height: 400px;
    border: 2px dashed var(--border); border-radius: var(--radius-lg);
    color: var(--text-muted); text-align: center;
    padding: 40px;
}
.results-placeholder svg { width: 48px; height: 48px; margin-bottom: 16px; opacity: 0.4; }
.results-placeholder p { font-size: 16px; font-weight: 500; }
.results-placeholder span { font-size: 13px; margin-top: 6px; }

/* Status banners */
.status-banner {
    padding: 16px 24px; border-radius: var(--radius);
    font-weight: 600; font-size: 15px; margin-bottom: 28px;
    display: flex; align-items: flex-start; gap: 10px; flex-wrap: wrap;
}
.status-approved { background: var(--success-bg); color: var(--success); border: 1px solid var(--success-border); }
.status-partial  { background: var(--warning-bg); color: var(--warning); border: 1px solid var(--warning-border); }
.status-denied   { background: var(--danger-bg); color: var(--danger); border: 1px solid var(--danger-border); }
.denial-reason { font-size: 13px; color: var(--text-secondary); font-weight: 400; width: 100%; margin-top: 4px; }

/* Metric cards */
.metrics-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(155px, 1fr));
    gap: 14px; margin-bottom: 28px;
}
.metric-card {
    background: var(--bg-alt); border: 1px solid var(--border-light);
    border-radius: var(--radius); padding: 16px 18px;
    transition: transform 0.2s, box-shadow 0.2s;
}
.metric-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.metric-card .label {
    font-size: 11px; color: var(--text-muted); font-weight: 600;
    text-transform: uppercase; letter-spacing: 0.7px; margin-bottom: 6px;
}
.metric-card .value { font-size: 21px; font-weight: 700; color: var(--text); line-height: 1.2; }
.metric-card .sub { font-size: 12px; color: var(--text-muted); margin-top: 4px; }

.results h4 {
    font-size: 17px; font-weight: 700; margin-bottom: 16px; padding-top: 8px;
    color: var(--text); display: flex; align-items: center; gap: 8px;
}
.results h4::before {
    content: ''; display: inline-block;
    width: 4px; height: 20px; border-radius: 2px;
    background: var(--primary);
}

/* Valuation breakdown */
.val-detail { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 28px; }
.val-detail-card {
    background: var(--bg-alt); border-radius: var(--radius);
    padding: 20px; border: 1px solid var(--border-light);
}
.val-detail-card h5 { font-size: 14px; font-weight: 700; margin-bottom: 10px; color: var(--text); }
.val-detail-card p { font-size: 13px; color: var(--text-secondary); line-height: 1.8; }

/* ================================================================
   PRICING
   ================================================================ */
.pricing-card {
    max-width: 440px; margin: 0 auto;
    background: var(--bg); border: 2px solid var(--primary);
    border-radius: var(--radius-lg); padding: 44px 40px;
    text-align: center; position: relative;
    box-shadow: var(--shadow-glow);
}
.pricing-badge {
    position: absolute; top: -14px; left: 50%; transform: translateX(-50%);
    background: var(--primary); color: #fff; font-size: 12px; font-weight: 700;
    padding: 4px 16px; border-radius: 50px; text-transform: uppercase;
    letter-spacing: 1px;
}
.pricing-card .price {
    font-size: 48px; font-weight: 800; color: var(--text);
    margin-top: 8px;
}
.pricing-card .price span { font-size: 16px; font-weight: 400; color: var(--text-muted); }
.pricing-card .price-sub { font-size: 14px; color: var(--text-secondary); margin-bottom: 24px; }
.pricing-card ul { list-style: none; text-align: left; margin: 24px 0; }
.pricing-card li { padding: 8px 0; font-size: 15px; color: var(--text-secondary); display: flex; align-items: center; gap: 10px; }
.pricing-card li svg { width: 18px; height: 18px; color: var(--primary); flex-shrink: 0; }

/* ================================================================
   CTA BANNER
   ================================================================ */
.cta-banner {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-darker) 100%);
    padding: 72px 0; text-align: center;
}
.cta-banner h2 { font-size: 32px; font-weight: 800; color: #fff; margin-bottom: 12px; }
.cta-banner p { font-size: 17px; color: rgba(255,255,255,0.8); margin-bottom: 32px; }
.waitlist-form { display: flex; gap: 10px; max-width: 480px; margin: 0 auto; }
.waitlist-form input {
    flex: 1; padding: 14px 18px; border: none; border-radius: 10px;
    font-size: 15px; font-family: inherit;
}
.waitlist-form input:focus { outline: none; box-shadow: 0 0 0 3px rgba(255,255,255,0.3); }
.waitlist-msg { text-align: center; margin-top: 12px; font-size: 14px; color: rgba(255,255,255,0.9); }

/* ================================================================
   FOOTER
   ================================================================ */
footer { background: var(--bg-dark); padding: 56px 0 32px; color: rgba(255,255,255,0.6); }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 48px; margin-bottom: 48px; }
.footer-brand .logo { color: #fff; font-size: 22px; margin-bottom: 12px; }
.footer-brand .logo span { color: var(--primary); }
.footer-brand p { font-size: 14px; line-height: 1.7; max-width: 260px; }
.footer-col h4 { color: #fff; font-size: 14px; font-weight: 700; margin-bottom: 16px; text-transform: uppercase; letter-spacing: 0.5px; }
.footer-col a { display: block; font-size: 14px; color: rgba(255,255,255,0.5); padding: 4px 0; transition: color 0.2s; }
.footer-col a:hover { color: #fff; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.08); padding-top: 24px; font-size: 13px; text-align: center; }

/* ================================================================
   RESPONSIVE
   ================================================================ */
@media (max-width: 900px) {
    .steps { grid-template-columns: 1fr; }
    .features-grid { grid-template-columns: 1fr 1fr; }
    .tool-grid { grid-template-columns: 1fr; }
    .tool-form { position: static; }
    .stats-grid { grid-template-columns: repeat(2, 1fr); }
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .val-detail { grid-template-columns: 1fr; }
    .hero h1 { font-size: 36px; }
}

@media (max-width: 600px) {
    .hero { padding: 120px 0 60px; }
    .hero h1 { font-size: 30px; }
    .hero p { font-size: 16px; }
    .hero-buttons { flex-direction: column; align-items: center; }
    .features-grid { grid-template-columns: 1fr; }
    .stats-grid { grid-template-columns: 1fr 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
    .waitlist-form { flex-direction: column; }
    .nav-links { display: none; }
    .nav-toggle { display: block; }
    section { padding: 56px 0; }
}

/* ================================================================
   UTILITIES
   ================================================================ */
.spinner {
    display: inline-block; width: 18px; height: 18px;
    border: 2.5px solid rgba(255,255,255,0.4); border-top-color: #fff;
    border-radius: 50%; animation: spin 0.6s linear infinite;
    vertical-align: middle;
}
@keyframes spin { to { transform: rotate(360deg); } }

.text-center { text-align: center; }
.mt-2 { margin-top: 8px; }
.mt-4 { margin-top: 16px; }
.hidden { display: none !important; }

/* ================================================================
   NAV AUTH / USER PILL
   ================================================================ */
.nav-auth { display: flex; align-items: center; gap: 10px; }
.btn-sm { padding: 8px 16px; font-size: 13px; border-radius: 8px; }

.nav-user { display: flex; align-items: center; gap: 10px; }
.nav-user-avatar {
    width: 32px; height: 32px; border-radius: 50%;
    background: var(--primary); color: #fff;
    font-size: 13px; font-weight: 700;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.nav-user-name { font-size: 14px; font-weight: 600; color: var(--text); }
.nav-user-logout {
    font-size: 13px; color: var(--text-muted); background: none; border: none;
    cursor: pointer; padding: 4px 8px; border-radius: 6px;
    transition: color 0.2s, background 0.2s;
}
.nav-user-logout:hover { color: var(--danger); background: var(--danger-bg); }

/* ================================================================
   AUTH MODAL
   ================================================================ */
.modal-overlay {
    position: fixed; inset: 0; z-index: 200;
    background: rgba(15, 23, 42, 0);
    display: flex; align-items: center; justify-content: center;
    padding: 24px;
    opacity: 0; pointer-events: none;
    transition: opacity 0.2s, background 0.2s;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
}
.modal-overlay.open {
    opacity: 1; pointer-events: all;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.modal {
    background: var(--bg); border-radius: var(--radius-lg);
    padding: 36px 40px; width: 100%; max-width: 420px;
    box-shadow: var(--shadow-lg);
    position: relative;
    transform: translateY(16px);
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}
.modal-overlay.open .modal { transform: translateY(0); }

.modal-close {
    position: absolute; top: 16px; right: 20px;
    background: none; border: none; cursor: pointer;
    font-size: 22px; color: var(--text-muted); line-height: 1;
    padding: 4px; border-radius: 6px;
    transition: color 0.2s, background 0.2s;
}
.modal-close:hover { color: var(--text); background: var(--border-light); }

.modal-tabs {
    display: flex; gap: 4px; margin-bottom: 28px;
    background: var(--bg-alt); border-radius: 10px; padding: 4px;
}
.modal-tab {
    flex: 1; padding: 8px; border: none; background: none;
    border-radius: 8px; font-size: 14px; font-weight: 600;
    color: var(--text-muted); cursor: pointer;
    transition: all 0.2s;
}
.modal-tab.active { background: #fff; color: var(--primary); box-shadow: var(--shadow-sm); }

.auth-form .field { margin-bottom: 16px; }
.auth-form label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; color: var(--text); }
.auth-form input {
    width: 100%; padding: 11px 14px; border: 1.5px solid var(--border);
    border-radius: 8px; font-size: 15px; font-family: inherit;
    color: var(--text); background: var(--bg);
    transition: border-color 0.2s, box-shadow 0.2s;
}
.auth-form input:focus {
    outline: none; border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-glow);
}

.auth-error {
    font-size: 13px; color: var(--danger);
    background: var(--danger-bg); border: 1px solid var(--danger-border);
    border-radius: 8px; padding: 8px 12px;
    margin-bottom: 14px;
    display: none;
}
.auth-error:not(:empty) { display: block; }

.auth-switch { font-size: 13px; color: var(--text-muted); text-align: center; margin-top: 16px; }
.auth-switch a { font-weight: 600; }

.terms-field { margin-top: 4px; }
.terms-check-label {
    display: flex; gap: 10px; align-items: flex-start;
    font-size: 13px; color: var(--text-secondary); cursor: pointer; line-height: 1.5;
}
.terms-check-label input[type="checkbox"] {
    width: 16px; height: 16px; flex-shrink: 0; margin-top: 2px;
    accent-color: var(--primary); cursor: pointer;
}
.terms-check-label a { font-weight: 600; }

/* ================================================================
   TERMS MODAL
   ================================================================ */
.terms-overlay { z-index: 300; }

.terms-modal {
    max-width: 640px; max-height: 88vh;
    display: flex; flex-direction: column; padding: 36px 40px 0;
}

.terms-title { font-size: 20px; font-weight: 800; color: var(--text); margin-bottom: 4px; }
.terms-meta  { font-size: 12px; color: var(--text-muted); margin-bottom: 20px; }

.terms-body {
    overflow-y: auto; flex: 1;
    padding-right: 8px; padding-bottom: 8px;
    font-size: 14px; color: var(--text-secondary); line-height: 1.75;
}
.terms-body h3 {
    font-size: 14px; font-weight: 700; color: var(--text);
    margin: 20px 0 6px;
}
.terms-body h3:first-child { margin-top: 0; }
.terms-body p  { margin-bottom: 8px; }
.terms-body ul { padding-left: 18px; margin-bottom: 8px; }
.terms-body li { margin-bottom: 4px; }
.terms-body a  { font-weight: 600; }

.terms-footer {
    padding: 20px 0 28px;
    border-top: 1px solid var(--border-light);
    margin-top: 4px;
}
