.legal-page {
    max-width: 48rem;
    margin: 0 auto;
}

.legal-nav {
    margin-bottom: 2rem;
}

.legal-nav-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 1rem;
    list-style: none;
    padding: 0;
    margin: 0;
}

.legal-nav-link {
    color: var(--text-muted);
    font-size: 0.95rem;
    font-weight: 500;
    text-decoration: none;
}

.legal-nav-link:hover,
.legal-nav-link.active {
    color: var(--primary-color);
}

.legal-nav-link.active {
    font-weight: 600;
}

.legal-content h1 {
    font-family: var(--font-display);
    font-weight: 600;
    letter-spacing: -0.02em;
    margin-bottom: 1.5rem;
}

.legal-body {
    background: transparent;
    border-radius: 0;
    padding: 0;
    color: var(--text-color);
    line-height: 1.75;
    border-top: 1px solid var(--hairline);
    padding-top: 1.5rem;
}

.legal-body p + p {
    margin-top: 1rem;
}

.legal-draft-notice {
    margin: 1.75rem 0 0;
    padding: 0.75rem 1rem;
    border-left: 3px solid var(--primary-color);
    background: color-mix(in srgb, var(--primary-color) 8%, transparent);
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.5;
}

.how-it-works-strip {
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--hairline);
}

.how-it-works-strip__label {
    margin: 0 0 0.75rem;
    font-family: var(--font-ui);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.how-it-works-strip__steps {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.35rem 0.5rem;
    list-style: none;
    margin: 0;
    padding: 0;
    font-size: 0.95rem;
    line-height: 1.45;
    color: var(--text-color);
}

.how-it-works-strip__steps li {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.how-it-works-strip__steps li:not(:last-child)::after {
    content: "→";
    color: var(--text-muted);
    font-weight: 600;
}

.main-footer .how-it-works-strip {
    margin: 1.25rem auto 0;
    max-width: 40rem;
    border-top: 1px solid color-mix(in srgb, var(--text-on-dark) 18%, transparent);
    padding-top: 1rem;
}

.main-footer .how-it-works-strip__label {
    color: color-mix(in srgb, var(--text-on-dark) 70%, transparent);
}

.main-footer .how-it-works-strip__steps {
    justify-content: center;
    color: var(--text-on-dark);
}

.main-footer .how-it-works-strip__steps li:not(:last-child)::after {
    color: color-mix(in srgb, var(--text-on-dark) 55%, transparent);
}

.footer-legal {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.35rem 0.75rem;
    margin-top: 0.75rem;
    font-size: 0.9rem;
}

.footer-legal a {
    color: var(--footer-link-color);
    text-decoration: none;
}

.footer-legal a:hover {
    text-decoration: underline;
}

.footer-legal-separator {
    opacity: var(--footer-text-opacity);
    user-select: none;
}

.cookie-banner {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: var(--surface-color);
    border-top: 1px solid var(--hairline);
    box-shadow: none;
    padding: 1rem 0;
}

html.cookie-banner-visible .cookie-banner {
    display: block;
}

html.cookie-banner-visible body {
    padding-bottom: 5.5rem;
}

.cookie-banner-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem 1.5rem;
}

.cookie-banner-text {
    flex: 1 1 16rem;
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.6;
    color: var(--text-muted);
}

.cookie-banner-text a {
    color: var(--primary-color);
    font-weight: 600;
    text-decoration: none;
}

.cookie-banner-text a:hover {
    text-decoration: underline;
}

.cookie-banner-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    flex-shrink: 0;
}

[data-theme="dark"] .cookie-banner,
[data-theme="high-contrast"] .cookie-banner {
    border-top-color: rgba(255, 255, 255, 0.12);
}

@media (max-width: 640px) {
    html.cookie-banner-visible body {
        padding-bottom: 8rem;
    }

    .cookie-banner-inner {
        flex-direction: column;
        align-items: stretch;
    }

    .cookie-banner-actions {
        justify-content: stretch;
    }

    .cookie-banner-actions .btn {
        flex: 1 1 auto;
    }
}
