.legal-page {
    position: relative;
    padding: 0 20px 140px;
    background:
        radial-gradient(circle at top left, rgba(68, 70, 233, 0.12), transparent 32%),
        radial-gradient(circle at top right, rgba(253, 179, 173, 0.16), transparent 28%),
        linear-gradient(180deg, #f8fbff 0%, #ffffff 22%, #ffffff 100%);
}

.legal-page__hero {
    position: relative;
    max-width: 1240px;
    margin: 48px auto 28px;
    overflow: hidden;
    border: 1px solid rgba(221, 228, 244, 0.95);
    border-radius: 32px;
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.96), rgba(240, 244, 252, 0.92));
    box-shadow: 0 24px 70px rgba(51, 53, 176, 0.08);
}

.legal-page__backdrop {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(135deg, rgba(68, 70, 233, 0.08), transparent 42%),
        linear-gradient(225deg, rgba(253, 179, 173, 0.12), transparent 36%);
    pointer-events: none;
}

.legal-page__hero-inner {
    position: relative;
    padding: 42px 46px 38px;
}

.legal-page .page-header {
    max-width: none;
    margin: 0 0 28px;
    padding: 0;
    display: block;
}

.legal-page .page-header .entry-title {
    width: 100%;
    margin-bottom: 14px;
    font-family: Lexend, sans-serif;
    font-size: 52px;
    font-weight: 600;
    line-height: 1.02;
    letter-spacing: -0.04em;
}

.legal-page .page-header .entry-subtitle,
.legal-page .page-header .entry-kicker {
    width: 100%;
    max-width: 780px;
    color: #5f6880;
    margin: 0;
}

.legal-page .page-header .entry-subtitle {
    font-size: 18px;
    line-height: 1.65;
}

.legal-page .page-header .entry-kicker {
    margin-top: 12px;
    color: #4446e9;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.legal-page__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 18px;
    color: #4446e9;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.legal-page__eyebrow::before {
    content: "";
    width: 28px;
    height: 1px;
    background: currentColor;
}

.legal-page__nav {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.legal-page__nav-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 10px 18px;
    border: 1px solid #d7dff5;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.72);
    color: #39445f;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.2s ease;
}

.legal-page__nav-link:hover,
.legal-page__nav-link:focus-visible {
    border-color: #4446e9;
    background: #f3f5ff;
    color: #2733d6;
}

.legal-page__nav-link.is-active {
    border-color: #4446e9;
    background: #4446e9;
    color: #fff;
    box-shadow: 0 14px 30px rgba(68, 70, 233, 0.2);
}

.legal-page__shell {
    max-width: 1240px;
    margin: 0 auto;
}

.legal-page .page-content {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 36px 38px 44px;
    border: 1px solid #e4eaf7;
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.95);
    box-shadow: 0 24px 70px rgba(42, 50, 82, 0.06);
    font-size: 17px;
    line-height: 1.85;
    color: #31405f;
}

.legal-page .page-content > * {
    width: 100%;
    margin: 0 0 18px !important;
}

.legal-page .page-content > *:last-child {
    margin-bottom: 0 !important;
}

.legal-page .page-content h2,
.legal-page .page-content h3,
.legal-page .page-content h4,
.legal-page .page-content h5,
.legal-page .page-content h6 {
    position: relative;
    left: auto;
    width: 100%;
    margin: 40px 0 16px !important;
    color: #202d49;
    font-family: Lexend, sans-serif;
    font-size: 26px;
    font-weight: 600;
    line-height: 1.2;
    letter-spacing: -0.03em;
}

.legal-page .page-content h3 {
    font-size: 22px;
}

.legal-page .page-content p,
.legal-page .page-content li {
    color: #45526d;
}

.legal-page .page-content ul,
.legal-page .page-content ol {
    padding-left: 24px;
    list-style: initial;
}

.legal-page .page-content ol {
    list-style: decimal;
}

.legal-page .page-content li {
    margin-bottom: 12px;
}

.legal-page .page-content a {
    color: #1f4fd6;
    text-decoration: underline;
    text-decoration-thickness: 1.5px;
    text-underline-offset: 0.16em;
}

.legal-page .page-content a:hover,
.legal-page .page-content a:focus-visible {
    color: #173aa3;
}

.legal-page .page-content strong {
    color: #223150;
}

.legal-page .page-content table {
    width: 100%;
    overflow: hidden;
    border: 1px solid #dfe6f5;
    border-radius: 18px;
    background: #fff;
}

.legal-page .page-content td,
.legal-page .page-content th {
    padding: 14px 16px;
    border-bottom: 1px solid #edf1fa;
    text-align: left;
    vertical-align: top;
}

.legal-page .page-content tr:last-child td {
    border-bottom: none;
}

.legal-page .page-content blockquote {
    margin: 30px 0 !important;
    border: none;
    border-radius: 22px;
    background: linear-gradient(180deg, #f6f8ff 0%, #eef2ff 100%);
    color: #263654;
}

@media screen and (max-width: 768px) {
    .legal-page {
        padding: 0 12px 88px;
    }

    .legal-page__hero {
        margin-top: 20px;
        border-radius: 24px;
    }

    .legal-page__hero-inner {
        padding: 28px 20px 24px;
    }

    .legal-page .page-header .entry-title {
        font-size: 34px;
        line-height: 1.05;
    }

    .legal-page .page-header .entry-subtitle {
        font-size: 16px;
    }

    .legal-page .page-content {
        padding: 24px 20px 28px;
        border-radius: 22px;
        font-size: 16px;
    }

    .legal-page .page-content h2,
    .legal-page .page-content h3,
    .legal-page .page-content h4,
    .legal-page .page-content h5,
    .legal-page .page-content h6 {
        margin-top: 28px !important;
        font-size: 22px;
    }

    .legal-page .page-content h3 {
        font-size: 20px;
    }
}
