:root {
    --bg: #ffffff;
    --surface: #f6f8fa;
    --border: #d1d9e0;
    --text: #1f2328;
    --text-dim: #59636e;
    --link: #0969da;
    --accent: #1a7f37;
    --danger: #cf222e;
    --code-bg: #f6f8fa;
    --radius: 8px;
}

@media (prefers-color-scheme: dark) {
    :root {
        --bg: #0d1117;
        --surface: #161b22;
        --border: #30363d;
        --text: #e6edf3;
        --text-dim: #9198a1;
        --link: #4493f8;
        --accent: #3fb950;
        --danger: #f85149;
        --code-bg: #161b22;
    }
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0 24px 80px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, system-ui, sans-serif;
    font-size: 16px;
    line-height: 1.65;
    color: var(--text);
    background: var(--bg);
}

.container {
    max-width: 760px;
    margin: 0 auto;
}

/* ---------- masthead ---------- */

.masthead {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 24px 0;
    margin-bottom: 8px;
    border-bottom: 1px solid var(--border);
}

.masthead img {
    width: 32px;
    height: 32px;
    border-radius: 6px;
}

.masthead__name {
    font-weight: 600;
    font-size: 15px;
    flex: 1;
}

.masthead a {
    font-size: 14px;
    color: var(--text-dim);
}

.masthead a:hover {
    color: var(--link);
}

/* ---------- hero ---------- */

.hero {
    padding: 56px 0 40px;
    text-align: center;
    border-bottom: 1px solid var(--border);
}

.hero h1 {
    margin: 0 0 12px;
    font-size: 2.4rem;
    line-height: 1.15;
    letter-spacing: -0.02em;
}

.hero p {
    max-width: 540px;
    margin: 0 auto 28px;
    font-size: 1.1rem;
    color: var(--text-dim);
}

.cta-row {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    color: var(--text);
    background: var(--surface);
}

.cta:hover {
    border-color: var(--text-dim);
}

.cta--primary {
    color: #fff;
    background: #1f883d;
    border-color: rgba(31, 136, 61, 0.4);
}

.cta--primary:hover {
    background: #1a7f37;
    border-color: rgba(31, 136, 61, 0.6);
}

/* ---------- typography ---------- */

h2 {
    margin: 48px 0 12px;
    font-size: 1.45rem;
    letter-spacing: -0.01em;
    scroll-margin-top: 20px;
}

h3 {
    margin: 28px 0 8px;
    font-size: 1.1rem;
}

a {
    color: var(--link);
}

code {
    padding: 2px 5px;
    font-family: ui-monospace, SFMono-Regular, 'SF Mono', Menlo, monospace;
    font-size: 0.87em;
    background: var(--code-bg);
    border: 1px solid var(--border);
    border-radius: 5px;
}

pre {
    padding: 14px 16px;
    overflow-x: auto;
    font-size: 13.5px;
    line-height: 1.55;
    background: var(--code-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

pre code {
    padding: 0;
    border: none;
    background: none;
    font-size: inherit;
}

/* ---------- step list ---------- */

.steps {
    counter-reset: step;
    padding: 0;
    margin: 24px 0;
    list-style: none;
}

.steps > li {
    position: relative;
    counter-increment: step;
    padding: 0 0 4px 44px;
    margin-bottom: 24px;
}

.steps > li::before {
    content: counter(step);
    position: absolute;
    left: 0;
    top: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    font-size: 14px;
    font-weight: 600;
    color: var(--text);
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 50%;
}

.steps > li > strong {
    display: block;
    margin-bottom: 4px;
    font-size: 1.02rem;
}

/* ---------- callouts ---------- */

.note {
    padding: 12px 16px;
    margin: 20px 0;
    font-size: 15px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-left: 3px solid var(--link);
    border-radius: var(--radius);
}

.note--warn {
    border-left-color: #bf8700;
}

.note strong:first-child {
    display: block;
    margin-bottom: 2px;
}

/* ---------- tables ---------- */

table {
    width: 100%;
    margin: 20px 0;
    border-collapse: collapse;
    font-size: 15px;
}

th,
td {
    padding: 9px 12px;
    text-align: left;
    border: 1px solid var(--border);
    vertical-align: top;
}

th {
    background: var(--surface);
    font-weight: 600;
}

td code {
    white-space: nowrap;
}

.table-scroll {
    overflow-x: auto;
}

/* ---------- footer ---------- */

.footer {
    margin-top: 64px;
    padding-top: 24px;
    font-size: 14px;
    color: var(--text-dim);
    border-top: 1px solid var(--border);
}

.footer a {
    margin-right: 16px;
}

/* ---------- misc ---------- */

.updated {
    color: var(--text-dim);
    font-size: 0.88rem;
    margin-bottom: 32px;
}

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

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

.feature h3 {
    margin: 0 0 4px;
    font-size: 1rem;
}

.feature p {
    margin: 0;
    font-size: 14px;
    color: var(--text-dim);
}
