:root {
    --bg: #0b0d10;
    --bg-elev: #12161b;
    --fg: #e6edf3;
    --muted: #a9b5c1;
    --accent: #6ad3ff;
    --accent-2: #8bffb3;
    --border: #1f2530;
    --maxw: 1120px;
    --radius: 14px;
    --shadow: 0 8px 28px rgba(0, 0, 0, .28);
}

@media (prefers-color-scheme: light) {
    :root {
        --bg: #ffffff;
        --bg-elev: #f6f8fa;
        --fg: #0b0d10;
        --muted: #5b6772;
        --border: #e5e7eb;
    }
}

* {
    box-sizing: border-box;
}

html, body {
    height: 100%;
}

body {
    margin: 0;
    font: 16px/1.6 system-ui, -apple-system, Segoe UI, Roboto, "Helvetica Neue", Arial, "Noto Sans", "Apple Color Emoji", "Segoe UI Emoji";
    background: radial-gradient(1200px 600px at 80% -10%, rgba(106, 211, 255, .15), transparent),
    radial-gradient(1200px 600px at 10% 110%, rgba(139, 255, 179, .10), transparent),
    var(--bg);
    color: var(--fg);
}

.container {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 16px 24px;
}

/* Header */
.site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

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

.logo {
    font-size: 1.35rem;
}

.wordmark {
    letter-spacing: .2px;
}

.site-header nav a {
    color: var(--fg);
    opacity: .85;
    text-decoration: none;
    margin-left: 16px;
}

.site-header nav a:hover {
    opacity: 1;
}

/* Hero */
.hero {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    align-items: center;
    gap: 40px;
    padding: 32px 24px 8px;
}

.hero__copy h1 {
    font-size: clamp(2rem, 1.2rem + 2.5vw, 3rem);
    line-height: 1.1;
    margin: .2em 0 .4em;
}

.lede {
    font-size: 1.125rem;
    color: var(--muted);
    margin: 0 0 1em;
}

.cta-row {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin: 16px 0 10px;
}

.btn {
    display: inline-block;
    padding: 12px 18px;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 600;
    border: 1px solid transparent;
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent), var(--accent-2));
    color: #041014;
}

.btn-primary:hover {
    filter: saturate(105%) brightness(1.03);
}

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

.btn-ghost:hover {
    background: var(--bg-elev);
}

.mini-points {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    padding: 0;
    margin: 12px 0 0;
    list-style: none;
    color: var(--muted);
}

.hero__art img {
    width: 100%;
    height: auto;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    background: var(--bg-elev);
}

.features {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    padding: 8px 24px 48px;
}

.feature {
    padding: 20px;
    border: 1px solid var(--border);
    background: var(--bg-elev);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.feature h2 {
    margin: .5em 0 .2em;
    font-size: 1.15rem;
}

.feature p {
    margin: 0;
    color: var(--muted);
}

.feature img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 10px;
    background: #0e1318;
}

.site-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 24px;
    color: var(--muted);
    border-top: 1px solid var(--border);
}

.site-footer a {
    color: var(--muted);
    text-decoration: none;
    margin-right: 12px;
}

.site-footer a:hover {
    color: var(--fg);
}

/* Docs */
.doc-header h1 {
    margin: .2em 0 0;
}

.doc {
    padding-bottom: 48px;
}

.doc p, .doc li {
    color: var(--fg);
    line-height: 1.7;
}

.doc ul, .doc ol {
    margin: .5em 0 1em 0;
    padding-left: 1.5em;
}

.doc li {
    margin-bottom: .4em;
}

.doc h2 {
    margin: 1.8em 0 .6em;
    font-size: 1.5rem;
    border-bottom: 1px solid var(--border);
    padding-bottom: .3em;
}

.doc h3 {
    margin: 1.4em 0 .5em;
    font-size: 1.2rem;
    color: var(--accent);
}

.doc .muted, .doc .small {
    color: var(--muted);
}

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

.doc a:hover {
    text-decoration: underline;
}

.doc hr {
    border: none;
    border-top: 1px solid var(--border);
    margin: 2em 0;
}

.legal-note {
    color: var(--muted);
    font-size: .95rem;
    margin-top: 2em;
    padding: 16px;
    background: var(--bg-elev);
    border-radius: 8px;
    border-left: 3px solid var(--border);
}

.brand {
    font-weight: 700;
}

.perm-table {
    width: 100%;
    border-collapse: collapse;
    margin: 12px 0 24px;
}

.perm-table th, .perm-table td {
    border: 1px solid var(--border);
    padding: 10px;
    text-align: left;
    vertical-align: top;
}

.perm-table th {
    background: var(--bg-elev);
    font-weight: 600;
}

.perm-table code {
    font-size: .9em;
}

code {
    background: rgba(128, 128, 128, .15);
    padding: 2px 6px;
    border-radius: 6px;
    font-family: 'Monaco', 'Consolas', monospace;
    font-size: .9em;
}

/* Utilities */
.muted {
    color: var(--muted);
}

.small {
    font-size: .95rem;
}

.skip-link {
    position: absolute;
    left: -9999px;
    top: auto;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.skip-link:focus {
    position: static;
    width: auto;
    height: auto;
    padding: 8px;
    background: #000;
    color: #fff;
    border-radius: 8px;
}

/* Responsive */
@media (max-width: 960px) {
    .hero {
        grid-template-columns: 1fr;
    }

    .features {
        grid-template-columns: 1fr;
    }
}
