:root {
    color-scheme: dark;
    --ink: #040c18;
    --ink-deep: #02060d;
    --ink-rise: #081628;
    --paper: #f5f8fc;
    --paper-soft: rgba(245, 248, 252, 0.76);
    --paper-mute: rgba(245, 248, 252, 0.52);
    --paper-dim: rgba(245, 248, 252, 0.28);
    --cyan: #26a9e1;
    --cyan-bright: #6cc8ee;
    --cyan-soft: rgba(38, 169, 225, 0.12);
    --line: rgba(245, 248, 252, 0.11);
    --line-strong: rgba(245, 248, 252, 0.18);
    --max: 1120px;
    --gutter: clamp(1.2rem, 5vw, 4rem);
    font-size: 16px;
}

*, *::before, *::after {
    box-sizing: border-box;
}

html {
    background: var(--ink);
    color: var(--paper);
    font-family: "Geist", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    min-height: 100vh;
    margin: 0;
    color: var(--paper-soft);
    background:
        linear-gradient(180deg, rgba(8, 22, 40, 0.96) 0, var(--ink) 34rem, var(--ink-deep) 100%);
    line-height: 1.75;
    text-rendering: optimizeLegibility;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    opacity: 0.18;
    background-image:
        linear-gradient(to right, rgba(245, 248, 252, 0.045) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(245, 248, 252, 0.028) 1px, transparent 1px);
    background-size: calc(100vw / 12) 4.5rem;
    mask-image: linear-gradient(180deg, black, transparent 76%);
}

a {
    color: var(--cyan-bright);
    text-decoration-thickness: 1px;
    text-underline-offset: 0.22em;
}

a:hover {
    color: var(--paper);
}

.topbar,
.legal-footer {
    width: min(100%, var(--max));
    margin: 0 auto;
    padding-inline: var(--gutter);
}

.topbar {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 1rem;
    padding-block: 1.25rem;
    border-bottom: 1px solid var(--line);
}

.brand {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    line-height: 1;
    transition: opacity 240ms ease;
}

.brand-logo {
    display: block;
    height: clamp(1.5rem, 2.4vw, 1.85rem);
    width: auto;
    transition: filter 240ms ease, transform 600ms cubic-bezier(0.22, 1, 0.36, 1);
}

.brand:hover .brand-logo {
    filter: drop-shadow(0 0 14px rgba(38, 169, 225, 0.45));
}

.brand {
    justify-self: start;
    text-decoration: none;
}

.language-switch {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    justify-self: center;
    color: var(--paper-dim);
    font-family: "Geist Mono", ui-monospace, monospace;
    font-size: 0.72rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.language-switch a,
.topbar-link,
.legal-footer a {
    color: var(--paper-mute);
    text-decoration: none;
}

.language-switch a:hover,
.topbar-link:hover,
.legal-footer a:hover {
    color: var(--cyan-bright);
}

.topbar-link {
    justify-self: end;
    font-family: "Geist Mono", ui-monospace, monospace;
    font-size: 0.72rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

main {
    position: relative;
    z-index: 1;
    width: min(100%, var(--max));
    margin: 0 auto;
    padding: clamp(4rem, 10vw, 8rem) var(--gutter) clamp(5rem, 10vw, 8rem);
}

.eyebrow,
.section-number,
.updated,
.mini-label {
    font-family: "Geist Mono", ui-monospace, monospace;
    font-size: 0.68rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.eyebrow,
.section-number {
    color: var(--cyan);
}

h1,
h2,
h3 {
    color: var(--paper);
    font-family: "Fraunces", Georgia, serif;
    font-weight: 400;
    letter-spacing: -0.025em;
    text-wrap: balance;
}

h1 {
    max-width: 13ch;
    margin: 0.85rem 0 1.35rem;
    font-size: clamp(3.2rem, 9vw, 7rem);
    line-height: 0.94;
}

.title-translation {
    color: var(--cyan);
    font-style: italic;
}

.lede {
    max-width: 68ch;
    margin: 0;
    color: var(--paper-soft);
    font-size: clamp(1.05rem, 2vw, 1.28rem);
}

.lede [lang="en"] {
    display: block;
    margin-top: 0.85rem;
    color: var(--paper-mute);
    font-size: 0.92em;
}

.updated {
    display: block;
    margin-top: 2rem;
    color: var(--paper-mute);
}

.quick-summary {
    margin-top: clamp(3.5rem, 9vw, 7rem);
    border-block: 1px solid var(--line-strong);
    background: linear-gradient(180deg, rgba(8, 22, 40, 0.52), rgba(2, 6, 13, 0.28));
}

.quick-summary-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.2rem 0 1rem;
    border-bottom: 1px solid var(--line);
}

.quick-summary h2 {
    margin: 0;
    font-size: clamp(1.45rem, 3vw, 2.2rem);
}

.quick-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.quick-grid p {
    margin: 0;
    padding: 1rem clamp(1rem, 3vw, 2rem) 1rem 0;
    border-bottom: 1px solid var(--line);
}

.quick-grid p [lang="en"] {
    display: block;
    margin-top: 0.38rem;
    color: var(--paper-mute);
    font-size: 0.9em;
    line-height: 1.62;
}

.quick-grid p:nth-child(odd) {
    border-right: 1px solid var(--line);
}

.quick-grid p:nth-child(even) {
    padding-left: clamp(1rem, 3vw, 2rem);
}

.language-block {
    max-width: 800px;
    margin: clamp(5rem, 12vw, 9rem) auto 0;
    scroll-margin-top: 2rem;
}

.language-heading {
    margin-bottom: clamp(3rem, 7vw, 5rem);
}

.language-heading h2 {
    max-width: 15ch;
    margin: 0.7rem 0 0;
    font-size: clamp(2.4rem, 7vw, 5rem);
    line-height: 0.98;
}

.legal-section {
    display: grid;
    grid-template-columns: 4.5rem minmax(0, 1fr);
    gap: clamp(1rem, 3vw, 2rem);
    padding-bottom: clamp(2.6rem, 6vw, 4.4rem);
    margin-bottom: clamp(2.6rem, 6vw, 4.4rem);
    border-bottom: 1px solid var(--line);
    scroll-margin-top: 2rem;
}

.legal-section:last-child {
    margin-bottom: 0;
}

.legal-section h3 {
    margin: 0 0 1.1rem;
    font-size: clamp(1.55rem, 3.5vw, 2.45rem);
    line-height: 1.06;
}

.legal-section p,
.legal-section ul {
    max-width: 72ch;
}

.legal-section p {
    margin: 0 0 1rem;
}

.legal-section ul {
    display: grid;
    gap: 0.58rem;
    margin: 0.9rem 0 1rem;
    padding-left: 1.1rem;
}

strong {
    color: var(--paper);
    font-weight: 500;
}

.note {
    margin-top: 1.35rem;
    padding: 1rem 1.15rem;
    border-left: 2px solid var(--cyan);
    background: var(--cyan-soft);
    color: var(--paper-soft);
}

.legal-footer {
    position: relative;
    z-index: 1;
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem 1.5rem;
    justify-content: space-between;
    padding-block: 2rem 3rem;
    border-top: 1px solid var(--line);
    color: var(--paper-dim);
    font-family: "Geist Mono", ui-monospace, monospace;
    font-size: 0.7rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.legal-footer nav {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

@media (max-width: 760px) {
    .topbar {
        grid-template-columns: 1fr auto;
    }

    .language-switch {
        grid-column: 1 / -1;
        grid-row: 2;
        justify-self: start;
    }

    .topbar-link {
        grid-column: 2;
    }

    .quick-grid,
    .legal-section {
        grid-template-columns: 1fr;
    }

    .quick-grid p,
    .quick-grid p:nth-child(odd),
    .quick-grid p:nth-child(even) {
        padding-inline: 0;
        border-right: 0;
    }

    .section-number {
        margin-bottom: 0.2rem;
    }
}

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