:root {
    --legal-bg: #f4f8fa;
    --legal-card: #ffffff;
    --legal-text: #1f2d3d;
    --legal-muted: #5f6b7a;
    --legal-border: rgba(12, 49, 74, 0.12);
    --legal-accent: #0ebfc1;
    --legal-accent-dark: #0c314a;
    --legal-warning-bg: #fff7e6;
    --legal-warning-border: rgba(133, 100, 4, 0.22);
}

* {
    box-sizing: border-box;
}

body.legal-page {
    margin: 0;
    font-family: 'Geist', 'Inter', sans-serif;
    color: var(--legal-text);
    background: var(--legal-bg);
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
}

body.legal-page::before {
    content: "";
    position: fixed;
    inset: 0 auto auto 0;
    width: 100%;
    height: 360px;
    background:
        linear-gradient(180deg, rgba(12, 49, 74, 0.28), rgba(12, 49, 74, 0.12)),
        url('/assets/img/hero-bg.png') center top / cover no-repeat;
    pointer-events: none;
    z-index: 0;
}

body.legal-page::after {
    content: "";
    position: fixed;
    inset: 0;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0, rgba(244, 248, 250, 0) 220px, var(--legal-bg) 360px, var(--legal-bg) 100%);
    pointer-events: none;
    z-index: 0;
}

.legal-shell {
    width: min(1080px, calc(100% - 32px));
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.legal-bg-orb {
    display: none;
}

.legal-topbar {
    padding: 24px 0 18px;
}

.legal-topbar__row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 16px 20px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.06);
    backdrop-filter: blur(14px);
}

.legal-branding,
.legal-actions {
    display: flex;
    align-items: center;
    gap: 18px;
    flex-wrap: wrap;
}

.legal-topbar__back {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: rgba(255, 255, 255, 0.88);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.96rem;
}

.legal-topbar__back:hover {
    color: #ffffff;
}

.legal-nav {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}

.legal-nav a {
    color: rgba(255, 255, 255, 0.76);
    text-decoration: none;
    font-weight: 500;
    font-family: 'Inter', sans-serif;
    transition: color 0.2s ease, opacity 0.2s ease;
}

.legal-nav a:hover,
.legal-nav a[aria-current="page"] {
    color: #ffffff;
}

.legal-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: var(--legal-accent);
    color: #ffffff;
    border-radius: 8px;
    font-size: 16px;
    padding: 14px 24px;
    border: 2px solid transparent;
    font-weight: 600;
    line-height: 1.2;
    text-decoration: none;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.legal-cta:hover {
    color: #ffffff;
    transform: translateY(-1px);
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.16);
    background: #11b3b6;
}

.legal-logo img {
    height: 36px;
    width: auto;
}

.legal-hero {
    padding: 36px 0 38px;
    color: #ffffff;
}

.legal-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.legal-hero h1 {
    margin: 18px 0 12px;
    font-size: clamp(2rem, 4vw, 3rem);
    line-height: 1.08;
    letter-spacing: -0.04em;
    color: var(--legal-accent-dark);
}

.legal-hero p {
    margin: 0;
    font-size: 1.05rem;
    line-height: 1.7;
    color: var(--legal-text);
}

.legal-hero-panel {
    width: 100%;
    padding: 28px 34px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(12, 49, 74, 0.08);
    box-shadow: 0 16px 32px rgba(12, 49, 74, 0.08);
    backdrop-filter: blur(10px);
}

.legal-hero-panel p {
    color: var(--legal-text);
}

.legal-hero-panel .legal-eyebrow {
    background: rgba(12, 49, 74, 0.08);
    color: var(--legal-accent-dark);
}

.legal-meta {
    margin-top: 18px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.legal-chip {
    display: inline-flex;
    align-items: center;
    padding: 7px 12px;
    border-radius: 999px;
    background: rgba(12, 49, 74, 0.08);
    color: var(--legal-accent-dark);
    font-size: 0.92rem;
    font-weight: 600;
}

.legal-content {
    padding-bottom: 48px;
}

.legal-card {
    background: var(--legal-card);
    border: 1px solid var(--legal-border);
    border-radius: 24px;
    box-shadow: 0 22px 60px rgba(12, 49, 74, 0.08);
    padding: 34px;
}

.legal-note {
    margin-bottom: 20px;
    padding: 16px 18px;
    border-radius: 16px;
    border: 1px solid rgba(14, 191, 193, 0.22);
    background: linear-gradient(135deg, rgba(14, 191, 193, 0.1), rgba(14, 191, 193, 0.04));
}

.legal-note.warning {
    border-color: var(--legal-warning-border);
    background: var(--legal-warning-bg);
}

.legal-note p {
    margin: 0;
    line-height: 1.7;
    color: var(--legal-text);
}

.legal-section + .legal-section {
    margin-top: 28px;
    padding-top: 28px;
    border-top: 1px solid rgba(12, 49, 74, 0.08);
}

.legal-section h2 {
    margin: 0 0 12px;
    font-size: 1.32rem;
    color: var(--legal-accent-dark);
    letter-spacing: -0.03em;
}

.legal-section p,
.legal-section li {
    margin: 0;
    line-height: 1.8;
    color: var(--legal-text);
    font-family: 'Inter', sans-serif;
}

.legal-section p + p {
    margin-top: 12px;
}

.legal-section ul {
    margin: 12px 0 0;
    padding-left: 20px;
}

.legal-section li + li {
    margin-top: 8px;
}

.legal-section a {
    color: var(--legal-accent-dark);
    font-weight: 700;
}

.legal-footer {
    padding: 0 0 48px;
}

.legal-footer__row {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    align-items: center;
    color: var(--legal-muted);
    font-size: 0.95rem;
    padding: 18px 20px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(12, 49, 74, 0.08);
    box-shadow: 0 12px 34px rgba(12, 49, 74, 0.06);
}

.legal-footer__links {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.legal-footer__links a {
    color: var(--legal-accent-dark);
    text-decoration: none;
    font-weight: 700;
}

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

@media (max-width: 768px) {
    .legal-topbar__row {
        flex-direction: column;
        align-items: stretch;
    }

    .legal-branding,
    .legal-actions {
        justify-content: space-between;
    }

    .legal-nav {
        width: 100%;
    }

    .legal-cta {
        width: 100%;
    }

    .legal-card {
        border-radius: 18px;
        padding: 20px;
    }

    .legal-hero-panel {
        padding: 20px;
        border-radius: 18px;
    }

    .legal-hero {
        padding: 18px 0 26px;
    }
}