:root {
    --legal-bg: #050615;
    --legal-panel: rgba(12, 15, 38, 0.78);
    --legal-text: #eef3ff;
    --legal-muted: rgba(222, 231, 255, 0.62);
    --legal-line: rgba(126, 151, 255, 0.16);
    --legal-cyan: #45d6ff;
    --legal-violet: #b45cff;
    --legal-display: 'Exo 2', sans-serif;
    --legal-body: 'Inter', sans-serif;
}

* { box-sizing: border-box; }

html { min-height: 100%; background: var(--legal-bg); }

body.legal-page {
    min-height: 100vh;
    margin: 0;
    overflow-x: hidden;
    overflow-y: auto;
    background:
        radial-gradient(circle at 12% 6%, rgba(180, 92, 255, 0.14), transparent 34%),
        radial-gradient(circle at 88% 88%, rgba(69, 214, 255, 0.10), transparent 38%),
        var(--legal-bg);
    color: var(--legal-text);
    font-family: var(--legal-body);
    line-height: 1.75;
}

body.legal-page::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background:
        repeating-linear-gradient(to right, rgba(222, 231, 255, 0.025) 0 1px, transparent 1px 120px),
        repeating-linear-gradient(to bottom, rgba(222, 231, 255, 0.02) 0 1px, transparent 1px 120px);
}

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

.legal-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 28px;
}

.legal-brand,
.legal-back {
    color: var(--legal-text);
    font-family: var(--legal-display);
    text-decoration: none;
}

.legal-brand {
    font-size: 16px;
    font-weight: 800;
    letter-spacing: 0.22em;
}

.legal-brand span { color: var(--legal-cyan); }

.legal-back {
    border: 1px solid var(--legal-line);
    border-radius: 10px;
    padding: 9px 13px;
    color: var(--legal-muted);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    transition: border-color .2s ease, color .2s ease, background .2s ease;
}

.legal-back:hover,
.legal-back:focus-visible {
    border-color: rgba(69, 214, 255, 0.55);
    background: rgba(69, 214, 255, 0.08);
    color: var(--legal-text);
}

.legal-card {
    overflow: hidden;
    border: 1px solid var(--legal-line);
    border-radius: 24px;
    background: var(--legal-panel);
    box-shadow: 0 28px 90px rgba(0, 0, 0, 0.36), inset 0 1px 0 rgba(255, 255, 255, 0.04);
    backdrop-filter: blur(22px);
}

.legal-hero {
    position: relative;
    overflow: hidden;
    padding: clamp(28px, 5vw, 56px);
    border-bottom: 1px solid var(--legal-line);
}

.legal-hero::after {
    content: "";
    position: absolute;
    top: -120px;
    right: -80px;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: rgba(69, 214, 255, 0.12);
    filter: blur(70px);
}

.legal-kicker {
    margin: 0 0 12px;
    color: var(--legal-cyan);
    font-family: var(--legal-display);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

.legal-hero h1 {
    position: relative;
    z-index: 1;
    max-width: 760px;
    margin: 0;
    font-family: var(--legal-display);
    font-size: clamp(30px, 5vw, 54px);
    line-height: 1.08;
}

.legal-date {
    position: relative;
    z-index: 1;
    margin: 18px 0 0;
    color: var(--legal-muted);
    font-size: 13px;
}

.legal-content { padding: clamp(26px, 5vw, 54px); }

.legal-summary,
.legal-note {
    margin: 0 0 30px;
    border: 1px solid rgba(69, 214, 255, 0.18);
    border-radius: 16px;
    background: rgba(69, 214, 255, 0.055);
    padding: 18px 20px;
    color: rgba(238, 243, 255, 0.84);
}

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

.legal-section h2 {
    margin: 0 0 14px;
    color: var(--legal-text);
    font-family: var(--legal-display);
    font-size: 21px;
    line-height: 1.3;
}

.legal-section p { margin: 10px 0; color: var(--legal-muted); }
.legal-section strong { color: var(--legal-text); font-weight: 600; }
.legal-section ul { margin: 12px 0; padding-left: 22px; color: var(--legal-muted); }
.legal-section li + li { margin-top: 7px; }
.legal-section a { color: var(--legal-cyan); }

.contact-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.contact-card {
    display: flex;
    min-height: 160px;
    flex-direction: column;
    justify-content: space-between;
    border: 1px solid var(--legal-line);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.025);
    padding: 20px;
    color: var(--legal-text);
    text-decoration: none;
    transition: transform .2s ease, border-color .2s ease, background .2s ease;
}

.contact-card:hover,
.contact-card:focus-visible {
    transform: translateY(-2px);
    border-color: rgba(69, 214, 255, 0.46);
    background: rgba(69, 214, 255, 0.06);
}

.contact-card span {
    color: var(--legal-cyan);
    font-family: var(--legal-display);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .13em;
    text-transform: uppercase;
}

.contact-card strong { font-size: 16px; overflow-wrap: anywhere; }
.contact-card small { color: var(--legal-muted); line-height: 1.5; }

.legal-footer-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin-top: 22px;
}

.legal-footer-nav a {
    border: 1px solid var(--legal-line);
    border-radius: 9px;
    padding: 8px 11px;
    color: var(--legal-muted);
    font-size: 11px;
    text-decoration: none;
}

@media (max-width: 720px) {
    .legal-shell { width: min(100% - 20px, 980px); padding-top: 14px; }
    .legal-topbar { margin-bottom: 14px; }
    .legal-brand { font-size: 13px; }
    .legal-back { padding: 8px 10px; font-size: 9px; }
    .legal-card { border-radius: 18px; }
    .contact-grid { grid-template-columns: 1fr; }
    .contact-card { min-height: 130px; }
}
