:root {
    --bg: #070b14;
    --surface: #0f1626;
    --surface-elevated: #141e33;
    --border: rgba(148, 163, 184, 0.16);
    --text: #f1f5f9;
    --text-muted: #94a3b8;
    --accent: #10b981;
    --accent-cyan: #06b6d4;
    --danger: #f43f5e;
    --warn: #f59e0b;
    --radius: 14px;
    --font-sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Inter, sans-serif;
    --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

* { box-sizing: border-box; }

html, body {
    margin: 0;
    padding: 0;
    background: radial-gradient(circle at 50% 0%, #10203a 0%, var(--bg) 52%);
    color: var(--text);
    font-family: var(--font-sans);
    line-height: 1.6;
    min-height: 100vh;
}

.skip-link {
    position: absolute;
    left: -9999px;
    top: 8px;
    background: var(--accent);
    color: #031510;
    padding: 10px 16px;
    font-weight: 700;
    border-radius: 8px;
    z-index: 1000;
    text-decoration: none;
}
.skip-link:focus { left: 16px; }

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

header.topbar {
    border-bottom: 1px solid var(--border);
    backdrop-filter: blur(12px);
    position: sticky;
    top: 0;
    z-index: 20;
    background: rgba(7, 11, 20, 0.85);
}

.topbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
    gap: 16px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--text);
    font-weight: 700;
    letter-spacing: -0.02em;
}

.brand-mark {
    width: 30px;
    height: 30px;
    border-radius: 8px;
    background: linear-gradient(135deg, var(--accent), var(--accent-cyan));
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #041310;
    font-weight: 800;
    font-size: 14px;
}

nav.nav-links {
    display: flex;
    align-items: center;
    gap: 18px;
}

nav.nav-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
}
nav.nav-links a:hover, nav.nav-links a:focus-visible { color: var(--text); }

.nav-cta {
    background: rgba(16, 185, 129, 0.14);
    border: 1px solid rgba(16, 185, 129, 0.45);
    color: #6ee7b7 !important;
    padding: 7px 14px;
    border-radius: 999px;
    font-weight: 600 !important;
}

main { padding: 56px 0 80px; }

.hero { text-align: center; max-width: 780px; margin: 0 auto 40px; }

.eyebrow {
    display: inline-block;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #6ee7b7;
    background: rgba(16, 185, 129, 0.12);
    border: 1px solid rgba(16, 185, 129, 0.3);
    padding: 5px 12px;
    border-radius: 999px;
    margin-bottom: 18px;
}

h1 {
    font-size: clamp(2rem, 4.4vw, 3.1rem);
    line-height: 1.12;
    letter-spacing: -0.03em;
    margin: 0 0 16px;
}

.hero p {
    color: var(--text-muted);
    font-size: 1.08rem;
    margin: 0 0 28px;
}

.audit-form {
    display: flex;
    gap: 10px;
    background: var(--surface);
    border: 1px solid var(--border);
    padding: 8px;
    border-radius: var(--radius);
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.45);
}

.audit-form input {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text);
    font-size: 16px;
    padding: 12px 14px;
    outline: none;
}

.audit-form button {
    background: linear-gradient(135deg, var(--accent), var(--accent-cyan));
    color: #031510;
    border: none;
    border-radius: 10px;
    padding: 12px 24px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
}
.audit-form button:disabled { opacity: 0.65; cursor: wait; }

.quick-samples {
    margin-top: 12px;
    font-size: 13px;
    color: var(--text-muted);
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
}

.sample-btn {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-muted);
    border-radius: 999px;
    padding: 3px 11px;
    font-size: 12px;
    cursor: pointer;
}
.sample-btn:hover { color: var(--text); border-color: var(--accent-cyan); }

.status-banner {
    margin: 20px auto;
    max-width: 780px;
    padding: 14px 18px;
    border-radius: 10px;
    display: none;
    font-size: 14px;
}
.status-banner.error {
    display: block;
    background: rgba(244, 63, 94, 0.12);
    border: 1px solid rgba(244, 63, 94, 0.4);
    color: #fda4af;
}
.status-banner.loading {
    display: block;
    background: rgba(6, 182, 212, 0.12);
    border: 1px solid rgba(6, 182, 212, 0.35);
    color: #67e8f9;
}

#results { display: none; margin-top: 32px; }
#results.visible { display: block; }

.results-header {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 20px;
}

.btn-secondary {
    background: var(--surface-elevated);
    border: 1px solid var(--border);
    color: var(--text);
    padding: 9px 16px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.btn-secondary:hover { border-color: var(--accent); }

.score-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px;
}

.score-label { font-size: 13px; color: var(--text-muted); margin-bottom: 6px; }
.score-value { font-size: 2.3rem; font-weight: 800; letter-spacing: -0.03em; line-height: 1.1; }
.grade-pill {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 700;
    margin-left: 8px;
    vertical-align: middle;
}
.grade-good { background: rgba(16, 185, 129, 0.18); color: #6ee7b7; }
.grade-mid { background: rgba(245, 158, 11, 0.18); color: #fcd34d; }
.grade-bad { background: rgba(244, 63, 94, 0.18); color: #fda4af; }

.two-col {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(310px, 1fr));
    gap: 18px;
    margin-bottom: 24px;
}

h2 { font-size: 1.25rem; margin: 0 0 12px; letter-spacing: -0.02em; }
h3 { font-size: 1rem; margin: 0 0 8px; }

.issue-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.issue-item {
    background: var(--surface-elevated);
    border: 1px solid var(--border);
    border-left: 3px solid var(--danger);
    border-radius: 10px;
    padding: 12px 14px;
    font-size: 14px;
}
.issue-item.warn { border-left-color: var(--warn); }
.issue-item.pass { border-left-color: var(--accent); }
.issue-code { font-family: var(--font-mono); font-size: 12px; color: var(--text-muted); display: block; margin-bottom: 3px; }
.issue-fix { color: #a7f3d0; font-size: 13px; margin-top: 6px; display: block; }

.partner-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 16px;
    margin-top: 14px;
}

.partner-card {
    background: var(--surface-elevated);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 18px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 12px;
}

.partner-badge {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: #67e8f9;
    letter-spacing: 0.05em;
}

.lead-box {
    margin-top: 24px;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.1), rgba(6, 182, 212, 0.08));
    border: 1px solid rgba(16, 185, 129, 0.35);
    border-radius: var(--radius);
    padding: 24px;
}

.lead-form {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 14px;
}
.lead-form input {
    flex: 1 1 240px;
    background: var(--surface);
    border: 1px solid var(--border);
    color: var(--text);
    padding: 11px 14px;
    border-radius: 10px;
    font-size: 14px;
}
.lead-form button {
    background: var(--accent);
    color: #031510;
    border: none;
    border-radius: 10px;
    padding: 11px 20px;
    font-weight: 700;
    cursor: pointer;
}

.features-section { margin-top: 56px; }
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 16px;
}

footer {
    border-top: 1px solid var(--border);
    padding: 28px 0 40px;
    color: var(--text-muted);
    font-size: 13px;
}
.footer-inner {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 12px;
}
footer a { color: var(--text-muted); text-decoration: none; }
footer a:hover { color: var(--text); }

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

@media (max-width: 640px) {
    .audit-form { flex-direction: column; }
    .audit-form button { width: 100%; }
}

@media print {
    header.topbar, .audit-form, .quick-samples, .lead-box, .no-print { display: none !important; }
    body { background: #fff; color: #111; }
    .card, .issue-item { background: #fff; border: 1px solid #ccc; color: #111; }
    .issue-fix { color: #065f46; }
}
