* {
    box-sizing: border-box
}

html {
    scroll-behavior: smooth;
    color-scheme: dark;
    --bg: #1b1519;
    --panel: #201e22;
    --text: #f1edf0;
    --muted: #c3bac1;
    --line: #413b41;
    --accent: #ff9b9e
}

html[data-site=male] {
    --accent: #91bdff;
    --bg: #141c29
}

html[data-theme=light] {
    color-scheme: light;
    --bg: #fff3f5;
    --panel: #fff;
    --text: #242027;
    --muted: #554e58;
    --line: #ded6db;
    --accent: #a33239
}

html[data-site=male][data-theme=light] {
    --accent: #225ba5;
    --bg: #f6f9ff
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font: 17px/1.7 system-ui, sans-serif
}

a {
    color: var(--accent);
    text-underline-offset: 3px
}

header,
main,
footer {
    max-width: 1000px;
    margin: auto;
    padding: 24px
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    border-bottom: 1px solid var(--line)
}

button {
    font: inherit;
    background: var(--panel);
    color: var(--text);
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 8px 14px;
    cursor: pointer
}

h1,
h2,
h3 {
    line-height: 1.2
}

h1 {
    font-size: clamp(2.7rem, 7vw, 5rem);
    letter-spacing: -.055em;
    color: var(--accent);
    margin: 20px 0
}

h2 {
    font-size: 2rem;
    margin-top: 0
}

h3 {
    font-size: 1.25rem
}

section {
    padding: 34px 0;
    border-bottom: 1px solid var(--line);
    scroll-margin-top: 20px
}

.lead {
    font-size: 1.3rem;
    max-width: 760px
}

.eyebrow {
    letter-spacing: .12em;
    text-transform: uppercase;
    font-size: .75rem;
    font-weight: 700;
    color: var(--accent)
}

nav {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 22px
}

.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
    gap: 14px
}

article,
aside,
details {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 20px
}

article h3 {
    margin: 8px 0
}

article p {
    margin: 10px 0
}

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

details {
    margin: 12px 0
}

summary {
    cursor: pointer;
    font-weight: 650
}

table {
    width: 100%;
    border-collapse: collapse
}

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

.scroll {
    overflow-x: auto
}

a:focus-visible,
button:focus-visible,
summary:focus-visible {
    outline: 3px solid var(--accent);
    outline-offset: 4px
}

footer {
    font-size: .9rem;
    color: var(--muted)
}

@media(prefers-reduced-motion:reduce) {
    html {
        scroll-behavior: auto
    }
}

.toc {
    max-width: 480px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 22px 26px;
    margin-top: 28px
}

.toc h2 {
    font-size: 1.15rem;
    margin: 0 0 12px
}

.toc nav {
    display: flex;
    flex-direction: column;
    gap: 0
}

.toc a {
    padding: 8px 0;
    border-top: 1px solid var(--line)
}

blockquote {
    margin: 12px 0;
    padding: 10px 15px;
    border-left: 3px solid var(--accent);
    background: var(--bg)
}

.cite {
    font-size: .75em;
    vertical-align: super;
    text-decoration: none;
    margin-left: 3px
}

.cards {
    grid-template-columns: 1fr
}

details p {
    max-width: 80ch
}

.references {
    padding-inline-start: 2rem;
}

.references li {
    margin-block: 1rem;
    padding-inline-start: .4rem;
    overflow-wrap: anywhere;
    scroll-margin-top: 5rem;
}

.references li:target {
    outline: 1px solid currentColor;
    outline-offset: 5px;
    border-radius: 4px;
}