/*
 * ============================================================
 * ОБЩИЙ ДИЗАЙН ЮРИДИЧЕСКИХ И ИНФОРМАЦИОННЫХ СТРАНИЦ SKYMEMO
 * ============================================================
 */

.legal-page,
.information-page {
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
}

.legal-hero {
    position: relative;
    overflow: hidden;
    margin-bottom: 22px;
    padding: 34px;
    border: 1px solid rgba(74, 158, 255, 0.16);
    border-radius: 20px;
    background:
        linear-gradient(
            135deg,
            rgba(74, 158, 255, 0.13),
            rgba(15, 31, 53, 0.82) 55%,
            rgba(126, 87, 255, 0.09)
        );
}

.legal-hero::after {
    position: absolute;
    top: -90px;
    right: -80px;
    width: 250px;
    height: 250px;
    border-radius: 50%;
    background: rgba(74, 158, 255, 0.08);
    content: "";
    pointer-events: none;
}

.legal-hero-logo {
    position: relative;
    z-index: 1;
    display: inline-flex;
    width: 54px;
    height: 54px;
    align-items: center;
    justify-content: center;
    margin-bottom: 17px;
    padding: 3px;
    border-radius: 15px;
    background: transparent;
}

.legal-hero-logo img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter:
        drop-shadow(
            0 7px 14px
            rgba(0, 130, 255, 0.28)
        );
}

.legal-hero-icon {
    position: relative;
    z-index: 1;
    display: inline-flex;
    width: 52px;
    height: 52px;
    align-items: center;
    justify-content: center;
    margin-bottom: 17px;
    border-radius: 15px;
    background: rgba(74, 158, 255, 0.15);
    color: #4a9eff;
    font-size: 23px;
}

.legal-hero h1 {
    position: relative;
    z-index: 1;
    margin: 0;
    color: #ffffff;
    font-size: 30px;
    line-height: 1.25;
}

.legal-hero p {
    position: relative;
    z-index: 1;
    max-width: 800px;
    margin: 12px 0 0;
    color: #9bb1c5;
    font-size: 14px;
    line-height: 1.7;
}

.legal-hero-meta {
    position: relative;
    z-index: 1;
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin-top: 17px;
}

.legal-hero-badge {
    display: inline-flex;
    min-height: 32px;
    align-items: center;
    gap: 7px;
    padding: 7px 11px;
    border: 1px solid rgba(74, 158, 255, 0.16);
    border-radius: 999px;
    background: rgba(5, 18, 34, 0.28);
    color: #92abc0;
    font-size: 11px;
}

.legal-hero-badge i {
    color: #4a9eff;
}

.legal-grid {
    display: grid;
    grid-template-columns:
        minmax(0, 1fr)
        minmax(280px, 350px);
    gap: 22px;
    align-items: start;
}

.legal-main,
.legal-sidebar-card {
    border: 1px solid rgba(74, 158, 255, 0.14);
    border-radius: 17px;
    background: rgba(15, 31, 53, 0.78);
}

.legal-main {
    min-width: 0;
    padding: 5px 28px;
}

.legal-section {
    padding: 25px 0;
    border-bottom: 1px solid rgba(74, 158, 255, 0.09);
    scroll-margin-top: 90px;
}

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

.legal-section h2 {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 13px;
    color: #ffffff;
    font-size: 19px;
    line-height: 1.4;
}

.legal-section h2 i {
    width: 24px;
    flex: 0 0 24px;
    color: #4a9eff;
    font-size: 17px;
    text-align: center;
}

.legal-section h3 {
    margin: 21px 0 10px;
    color: #d5e4ef;
    font-size: 15px;
    line-height: 1.5;
}

.legal-section p {
    margin: 0 0 13px;
    color: #98aec1;
    font-size: 14px;
    line-height: 1.75;
}

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

.legal-section a {
    color: #71b5ff;
    text-decoration: none;
}

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

.legal-list {
    display: grid;
    gap: 9px;
    margin: 13px 0;
    padding: 0;
    list-style: none;
}

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

.legal-list li {
    position: relative;
    padding-left: 23px;
    color: #98aec1;
    font-size: 14px;
    line-height: 1.7;
}

.legal-list li::before {
    position: absolute;
    top: 10px;
    left: 4px;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #4a9eff;
    box-shadow: 0 0 0 4px rgba(74, 158, 255, 0.1);
    content: "";
}

.legal-numbered-list {
    display: grid;
    gap: 10px;
    margin: 13px 0;
    padding-left: 23px;
}

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

.legal-numbered-list li {
    padding-left: 4px;
    color: #98aec1;
    font-size: 14px;
    line-height: 1.7;
}

.legal-notice,
.legal-warning,
.legal-success {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin: 16px 0;
    padding: 16px;
    border-radius: 12px;
}

.legal-notice:last-child,
.legal-warning:last-child,
.legal-success:last-child {
    margin-bottom: 0;
}

.legal-notice {
    border: 1px solid rgba(74, 158, 255, 0.22);
    background: rgba(74, 158, 255, 0.07);
}

.legal-warning {
    border: 1px solid rgba(255, 163, 82, 0.22);
    background: rgba(255, 163, 82, 0.07);
}

.legal-success {
    border: 1px solid rgba(63, 204, 143, 0.2);
    background: rgba(63, 204, 143, 0.06);
}

.legal-notice > i,
.legal-warning > i,
.legal-success > i {
    margin-top: 3px;
    font-size: 18px;
}

.legal-notice > i {
    color: #4a9eff;
}

.legal-warning > i {
    color: #ffad66;
}

.legal-success > i {
    color: #4bd69a;
}

.legal-notice p,
.legal-warning p,
.legal-success p {
    margin: 0;
}

.legal-warning p {
    color: #c6b09c;
}

.legal-success p {
    color: #9bc8b4;
}

.legal-table-wrap {
    overflow-x: auto;
    margin: 16px 0;
    border: 1px solid rgba(74, 158, 255, 0.12);
    border-radius: 12px;
}

.legal-table {
    width: 100%;
    min-width: 620px;
    border-collapse: collapse;
}

.legal-table th,
.legal-table td {
    padding: 13px 14px;
    border-bottom: 1px solid rgba(74, 158, 255, 0.09);
    color: #98aec1;
    font-size: 12px;
    line-height: 1.6;
    text-align: left;
    vertical-align: top;
}

.legal-table th {
    background: rgba(74, 158, 255, 0.07);
    color: #c6d8e6;
    font-weight: 700;
}

.legal-table tr:last-child td {
    border-bottom: 0;
}

.legal-aside {
    display: grid;
    gap: 18px;
}

.legal-sidebar-card {
    padding: 20px;
}

.legal-sidebar-card h2 {
    display: flex;
    align-items: center;
    gap: 9px;
    margin: 0 0 13px;
    color: #ffffff;
    font-size: 16px;
}

.legal-sidebar-card h2 i {
    color: #4a9eff;
}

.legal-sidebar-card p {
    margin: 0 0 12px;
    color: #8fa7bc;
    font-size: 12px;
    line-height: 1.65;
}

.legal-sidebar-card p:last-child {
    margin-bottom: 0;
}

.legal-navigation {
    display: grid;
    gap: 8px;
    margin-top: 13px;
}

.legal-navigation a {
    display: flex;
    min-height: 42px;
    align-items: center;
    gap: 10px;
    padding: 9px 11px;
    border: 1px solid rgba(74, 158, 255, 0.11);
    border-radius: 10px;
    background: rgba(74, 158, 255, 0.05);
    color: #9eb6c9;
    font-size: 12px;
    line-height: 1.4;
    text-decoration: none;
    transition:
        border-color 0.2s ease,
        background 0.2s ease,
        color 0.2s ease;
}

.legal-navigation a:hover {
    border-color: rgba(74, 158, 255, 0.35);
    background: rgba(74, 158, 255, 0.11);
    color: #d1e3ef;
}

.legal-navigation a i {
    width: 20px;
    color: #4a9eff;
    text-align: center;
}

.legal-documents {
    display: grid;
    gap: 10px;
    margin-top: 15px;
}

.legal-document {
    display: flex;
    min-height: 50px;
    align-items: center;
    gap: 11px;
    padding: 10px 12px;
    border: 1px solid rgba(74, 158, 255, 0.16);
    border-radius: 11px;
    background: rgba(74, 158, 255, 0.07);
    color: #a3bfd6;
    text-decoration: none;
    transition:
        border-color 0.2s ease,
        background 0.2s ease,
        transform 0.2s ease;
}

.legal-document:hover {
    border-color: rgba(74, 158, 255, 0.42);
    background: rgba(74, 158, 255, 0.13);
    transform: translateY(-1px);
}

.legal-document-icon {
    display: inline-flex;
    width: 34px;
    height: 34px;
    flex: 0 0 34px;
    align-items: center;
    justify-content: center;
    border-radius: 9px;
    background: rgba(74, 158, 255, 0.13);
    color: #4a9eff;
}

.legal-document-text {
    min-width: 0;
    flex: 1;
}

.legal-document-title {
    display: block;
    color: #c0d3e3;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.4;
}

.legal-document-type {
    display: block;
    margin-top: 2px;
    color: #6f8ba3;
    font-size: 10px;
}

.legal-document-arrow {
    color: #66859f;
    font-size: 11px;
}

.legal-details {
    display: grid;
    gap: 9px;
    margin: 0;
}

.legal-detail {
    padding-bottom: 9px;
    border-bottom: 1px solid rgba(74, 158, 255, 0.08);
}

.legal-detail:last-child {
    padding-bottom: 0;
    border-bottom: 0;
}

.legal-detail dt {
    margin: 0 0 3px;
    color: #6f8ba3;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.04em;
    line-height: 1.4;
    text-transform: uppercase;
}

.legal-detail dd {
    margin: 0;
    overflow-wrap: anywhere;
    color: #a8bdcd;
    font-size: 12px;
    line-height: 1.55;
}

.legal-detail a {
    color: #71b5ff;
    text-decoration: none;
}

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

.legal-trademark {
    border-color: rgba(126, 87, 255, 0.2);
    background:
        linear-gradient(
            135deg,
            rgba(126, 87, 255, 0.1),
            rgba(15, 31, 53, 0.8)
        );
}

.legal-trademark-badge {
    display: inline-flex;
    width: 46px;
    height: 46px;
    align-items: center;
    justify-content: center;
    margin-bottom: 13px;
    border-radius: 13px;
    background: rgba(126, 87, 255, 0.15);
    color: #b5a2ff;
    font-size: 20px;
    font-weight: 800;
}

.legal-trademark strong {
    color: #c5b8ff;
}

.legal-company-note {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid rgba(126, 87, 255, 0.13);
    color: #877eb0;
    font-size: 11px;
    line-height: 1.6;
}

.legal-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-top: 22px;
    padding: 18px 21px;
    border: 1px solid rgba(74, 158, 255, 0.11);
    border-radius: 14px;
    background: rgba(15, 31, 53, 0.55);
    color: #728ba1;
    font-size: 12px;
    line-height: 1.6;
}

.legal-footer a {
    color: #92aabd;
    text-decoration: none;
}

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

.legal-footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px 16px;
}

/*
 * ============================================================
 * СВЕТЛАЯ ТЕМА
 * ============================================================
 */

html[data-theme="light"] .legal-hero,
html[data-theme="light"] .legal-main,
html[data-theme="light"] .legal-sidebar-card,
html[data-theme="light"] .legal-footer {
    border-color: #d5e0e8;
    background: #ffffff;
}

html[data-theme="light"] .legal-hero {
    background:
        linear-gradient(
            135deg,
            #edf7ff,
            #ffffff 60%,
            #f7f4ff
        );
}

html[data-theme="light"] .legal-hero h1,
html[data-theme="light"] .legal-section h2,
html[data-theme="light"] .legal-section h3,
html[data-theme="light"] .legal-sidebar-card h2 {
    color: #172433;
}

html[data-theme="light"] .legal-hero p,
html[data-theme="light"] .legal-section p,
html[data-theme="light"] .legal-list li,
html[data-theme="light"] .legal-numbered-list li,
html[data-theme="light"] .legal-sidebar-card p {
    color: #526c82;
}

html[data-theme="light"] .legal-hero-badge {
    border-color: #d4e3ee;
    background: rgba(255, 255, 255, 0.8);
    color: #526c82;
}

html[data-theme="light"] .legal-section {
    border-bottom-color: #e4eaef;
}

html[data-theme="light"] .legal-navigation a,
html[data-theme="light"] .legal-document {
    border-color: #d2e1ec;
    background: #f4f9fc;
    color: #526c82;
}

html[data-theme="light"] .legal-document-title {
    color: #314c63;
}

html[data-theme="light"] .legal-detail {
    border-bottom-color: #e4eaef;
}

html[data-theme="light"] .legal-detail dt {
    color: #71879a;
}

html[data-theme="light"] .legal-detail dd {
    color: #405d73;
}

html[data-theme="light"] .legal-table-wrap {
    border-color: #d5e0e8;
}

html[data-theme="light"] .legal-table th {
    background: #f2f7fa;
    color: #314c63;
}

html[data-theme="light"] .legal-table th,
html[data-theme="light"] .legal-table td {
    border-bottom-color: #e4eaef;
}

html[data-theme="light"] .legal-table td {
    color: #526c82;
}

html[data-theme="light"] .legal-notice {
    border-color: #cbdff0;
    background: #f2f8fd;
}

html[data-theme="light"] .legal-warning {
    border-color: #f0d3b9;
    background: #fff8f1;
}

html[data-theme="light"] .legal-warning p {
    color: #73563d;
}

html[data-theme="light"] .legal-success {
    border-color: #c4e7d7;
    background: #f1fbf6;
}

html[data-theme="light"] .legal-success p {
    color: #3f705b;
}

html[data-theme="light"] .legal-trademark {
    border-color: #d9cff7;
    background:
        linear-gradient(
            135deg,
            #f5f1ff,
            #ffffff
        );
}

html[data-theme="light"] .legal-footer {
    color: #60798e;
}

/*
 * ============================================================
 * АДАПТИВНОСТЬ
 * ============================================================
 */

@media (max-width: 900px) {
    .legal-grid {
        grid-template-columns: 1fr;
    }

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

    .legal-aside .legal-sidebar-card:first-child {
        grid-column: 1 / -1;
    }
}

@media (max-width: 620px) {
    .legal-hero {
        padding: 25px 20px;
    }

    .legal-hero h1 {
        font-size: 24px;
    }

    .legal-main {
        padding: 4px 19px;
    }

    .legal-section {
        padding: 21px 0;
    }

    .legal-section h2 {
        align-items: flex-start;
        font-size: 17px;
    }

    .legal-section p,
    .legal-list li,
    .legal-numbered-list li {
        font-size: 13px;
    }

    .legal-aside {
        grid-template-columns: 1fr;
    }

    .legal-aside .legal-sidebar-card:first-child {
        grid-column: auto;
    }

    .legal-footer {
        align-items: flex-start;
        flex-direction: column;
        gap: 10px;
    }

    .legal-footer-links {
        justify-content: flex-start;
    }
}