:root {
    --bg: #090a0d;
    --bg-soft: #0d1016;
    --surface: rgba(255, 255, 255, 0.045);
    --surface-strong: rgba(255, 255, 255, 0.07);
    --surface-muted: rgba(255, 255, 255, 0.03);
    --text: #f7f9fc;
    --text-soft: #cdd3de;
    --muted: #8f9aab;
    --line: rgba(255, 255, 255, 0.12);
    --line-soft: rgba(255, 255, 255, 0.08);
    --teal: #00f0b5;
    --teal-soft: rgba(0, 240, 181, 0.14);
    --violet: #7b61ff;
    --violet-soft: rgba(123, 97, 255, 0.14);
    --shadow: 0 24px 80px rgba(0, 0, 0, 0.34);
    --radius: 8px;
    --radius-lg: 12px;
    --container: 1120px;
    --font: Geist, Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    --focus: 0 0 0 3px rgba(0, 240, 181, 0.28), 0 0 0 6px rgba(123, 97, 255, 0.18);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    background: var(--bg);
}

body {
    margin: 0;
    background: radial-gradient(72% 48% at 50% -12%, rgba(0, 240, 181, 0.11), rgba(9, 10, 13, 0) 62%),
    radial-gradient(42% 34% at 8% 8%, rgba(123, 97, 255, 0.12), rgba(9, 10, 13, 0) 58%),
    var(--bg);
    color: var(--text);
    font-family: var(--font);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

img,
svg {
    display: block;
}

a {
    color: inherit;
}

a:focus-visible,
button:focus-visible {
    outline: none;
    box-shadow: var(--focus);
}

.skip {
    position: fixed;
    top: 14px;
    left: 14px;
    z-index: 100;
    transform: translateY(-150%);
    border-radius: var(--radius);
    background: var(--text);
    color: var(--bg);
    padding: 10px 14px;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    transition: transform 180ms ease;
}

.skip:focus {
    transform: translateY(0);
}

.container {
    width: min(100% - 40px, var(--container));
    margin-inline: auto;
}

.header {
    position: sticky;
    top: 0;
    z-index: 50;
    border-bottom: 1px solid transparent;
    background: rgba(9, 10, 13, 0.72);
    backdrop-filter: blur(18px);
    transition: border-color 180ms ease, background 180ms ease;
}

.header.is-scrolled {
    border-color: var(--line-soft);
    background: rgba(9, 10, 13, 0.86);
}

.header__inner {
    width: min(100% - 40px, var(--container));
    min-height: 72px;
    margin-inline: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

.brand,
.footer__brand {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}

.brand__logo {
    width: 40px;
    height: 40px;
    object-fit: contain;
}

.btn {
    display: inline-flex;
    min-height: 44px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: 1px solid transparent;
    border-radius: var(--radius);
    padding: 12px 18px;
    font-size: 15px;
    font-weight: 700;
    line-height: 1;
    text-decoration: none;
    white-space: nowrap;
    transition: transform 180ms ease,
    border-color 180ms ease,
    background 180ms ease,
    color 180ms ease,
    box-shadow 180ms ease;
}

.btn:hover {
    transform: translateY(-1px);
}

.btn--primary {
    background: linear-gradient(135deg, var(--teal), #52ffd2);
    color: #03100d;
    box-shadow: 0 14px 38px rgba(0, 240, 181, 0.18);
}

.btn--primary:hover {
    box-shadow: 0 18px 48px rgba(0, 240, 181, 0.24);
}

.btn--sm {
    min-height: 40px;
    padding: 10px 14px;
    font-size: 14px;
}

.eyebrow {
    margin: 0 0 16px;
    color: var(--teal);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.14em;
    line-height: 1.2;
    text-transform: uppercase;
}

.h1 {
    max-width: 840px;
    margin: 0;
    color: var(--text);
    font-size: clamp(42px, 7vw, 82px);
    font-weight: 700;
    letter-spacing: -0.04em;
    line-height: 0.96;
}

.gradient-text {
    display: inline;
    background: linear-gradient(135deg, var(--teal), #d5fff4 48%, var(--violet));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.muted {
    color: var(--muted);
}

.legal-hero {
    position: relative;
    overflow: hidden;
    padding: 104px 0 74px;
    border-bottom: 1px solid var(--line-soft);
}

.legal-hero__bg {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: radial-gradient(34% 42% at 78% 22%, rgba(0, 240, 181, 0.13), transparent 68%),
    radial-gradient(28% 38% at 18% 4%, rgba(123, 97, 255, 0.15), transparent 64%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0));
}

.legal-hero__inner {
    position: relative;
}

.legal-hero__meta {
    margin: 22px 0 0;
    color: var(--text-soft);
    font-size: 17px;
    line-height: 1.6;
}

.legal-hero__sub {
    max-width: 760px;
    margin: 18px 0 0;
    color: var(--muted);
    font-size: 18px;
    line-height: 1.75;
}

.legal-content {
    padding: 72px 0 110px;
}

.legal-content__grid {
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr);
    gap: 28px;
    align-items: start;
}

.legal-sidebar {
    position: sticky;
    top: 96px;
}

.legal-card,
.legal-section {
    border: 1px solid var(--line-soft);
    border-radius: var(--radius-lg);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.058), rgba(255, 255, 255, 0.028)),
    rgba(255, 255, 255, 0.02);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.04) inset;
}

.legal-card {
    padding: 22px;
}

.legal-card--toc {
    padding: 18px;
}

.legal-card__label {
    margin: 0 0 12px;
    color: var(--text);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.08em;
    line-height: 1.2;
    text-transform: uppercase;
}

.legal-summary {
    position: relative;
    overflow: hidden;
    margin-bottom: 18px;
    background: linear-gradient(180deg, rgba(0, 240, 181, 0.08), rgba(123, 97, 255, 0.045)),
    rgba(255, 255, 255, 0.03);
}

.legal-summary::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 3px;
    background: linear-gradient(180deg, var(--teal), var(--violet));
}

.legal-summary p {
    margin: 0;
}

.toc {
    display: grid;
    gap: 2px;
}

.toc a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 38px;
    border-radius: var(--radius);
    padding: 9px 10px;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.35;
    text-decoration: none;
    transition: background 180ms ease, color 180ms ease, transform 180ms ease;
}

.toc a::after {
    content: "";
    width: 5px;
    height: 5px;
    flex: 0 0 auto;
    border-top: 1px solid currentColor;
    border-right: 1px solid currentColor;
    opacity: 0.5;
    transform: rotate(45deg);
}

.toc a:hover {
    background: rgba(255, 255, 255, 0.045);
    color: var(--text);
    transform: translateX(2px);
}

.legal-main {
    min-width: 0;
}

.legal-section {
    scroll-margin-top: 104px;
    padding: 30px;
}

.legal-section + .legal-section {
    margin-top: 18px;
}

.legal-section h2 {
    margin: 0 0 18px;
    color: var(--text);
    font-size: clamp(24px, 3vw, 34px);
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1.08;
}

.legal-section h3 {
    margin: 28px 0 10px;
    color: var(--text-soft);
    font-size: 17px;
    font-weight: 700;
    letter-spacing: -0.01em;
    line-height: 1.35;
}

.legal-section p,
.legal-section li,
.legal-summary p {
    color: var(--text-soft);
    font-size: 16px;
    line-height: 1.8;
}

.legal-section p {
    margin: 0 0 16px;
}

.legal-section p:last-child {
    margin-bottom: 0;
}

.legal-section strong,
.legal-summary strong {
    color: var(--text);
    font-weight: 700;
}

.legal-section ul {
    display: grid;
    gap: 10px;
    margin: 0 0 18px;
    padding: 0;
    list-style: none;
}

.legal-section li {
    position: relative;
    padding-left: 24px;
}

.legal-section li::before {
    content: "";
    position: absolute;
    top: 0.72em;
    left: 0;
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: var(--teal);
    box-shadow: 0 0 0 4px rgba(0, 240, 181, 0.1);
}

.legal-section a,
.legal-summary a {
    color: var(--text);
    font-weight: 700;
    text-decoration-color: rgba(0, 240, 181, 0.42);
    text-decoration-thickness: 1px;
    text-underline-offset: 4px;
    transition: color 180ms ease, text-decoration-color 180ms ease;
}

.legal-section a:hover,
.legal-summary a:hover {
    color: var(--teal);
    text-decoration-color: rgba(0, 240, 181, 0.85);
}

.contact-list {
    display: grid;
    gap: 0;
    margin: 20px 0 0;
    border: 1px solid var(--line-soft);
    border-radius: var(--radius);
    overflow: hidden;
    background: rgba(255, 255, 255, 0.024);
}

.contact-list div {
    display: grid;
    grid-template-columns: 180px 1fr;
    gap: 18px;
    padding: 15px 18px;
    border-bottom: 1px solid var(--line-soft);
}

.contact-list div:last-child {
    border-bottom: 0;
}

.contact-list dt,
.contact-list dd {
    margin: 0;
    font-size: 15px;
    line-height: 1.55;
}

.contact-list dt {
    color: var(--text);
    font-weight: 700;
}

.contact-list dd {
    color: var(--text-soft);
}

.footer {
    border-top: 1px solid var(--line-soft);
    background: rgba(9, 10, 13, 0.72);
    padding: 34px 0;
}

.footer__inner {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 24px;
    align-items: center;
}

.footer__logo {
    width: 36px;
    height: 36px;
    object-fit: contain;
}

.footer__meta {
    margin: 0;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.65;
}

.footer__links {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    justify-content: flex-end;
}

.footer__links a {
    color: var(--muted);
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: color 180ms ease;
}

.footer__links a:hover,
.footer__links a[aria-current="page"] {
    color: var(--text);
}

@media (max-width: 980px) {
    .legal-content__grid {
        grid-template-columns: 1fr;
    }

    .legal-sidebar {
        position: static;
    }

    .legal-card--toc {
        padding: 16px;
    }

    .toc {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .footer__inner {
        grid-template-columns: 1fr;
        justify-items: start;
    }

    .footer__links {
        justify-content: flex-start;
    }
}

@media (max-width: 720px) {
    .container,
  .header__inner {
        width: min(100% - 32px, var(--container));
    }

    .header__inner {
        min-height: 66px;
    }

    .brand__logo {
        width: 36px;
        height: 36px;
    }

    .legal-hero {
        padding: 72px 0 52px;
    }

    .h1 {
        font-size: clamp(40px, 13vw, 58px);
        line-height: 1;
    }

    .legal-hero__meta {
        font-size: 16px;
    }

    .legal-hero__sub {
        font-size: 16px;
        line-height: 1.7;
    }

    .legal-content {
        padding: 44px 0 78px;
    }

    .toc {
        grid-template-columns: 1fr;
    }

    .toc a {
        min-height: 36px;
    }

    .legal-section,
  .legal-card {
        padding: 20px;
    }

    .legal-section h2 {
        font-size: 25px;
        line-height: 1.14;
    }

    .legal-section h3 {
        margin-top: 24px;
    }

    .legal-section p,
  .legal-section li,
  .legal-summary p {
        font-size: 15px;
        line-height: 1.75;
    }

    .contact-list div {
        grid-template-columns: 1fr;
        gap: 4px;
        padding: 14px 16px;
    }
}

@media (max-width: 420px) {
    .btn--sm {
        min-height: 38px;
        padding: 10px 12px;
        font-size: 13px;
    }

    .legal-section,
  .legal-card {
        padding: 18px;
    }
}

.legal-section table {
    width: 100%;
    border-collapse: collapse;
    margin: 16px 0 22px;
    border: 1px solid var(--line-soft);
    border-radius: var(--radius);
    overflow: hidden;
    font-size: 15px;
}

.legal-section thead {
    background: rgba(255, 255, 255, 0.04);
}

.legal-section th {
    padding: 11px 16px;
    text-align: left;
    color: var(--text);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    border-bottom: 1px solid var(--line);
}

.legal-section td {
    padding: 13px 16px;
    color: var(--text-soft);
    border-bottom: 1px solid var(--line-soft);
    line-height: 1.6;
    vertical-align: top;
}

.legal-section tr:last-child td {
    border-bottom: 0;
}

.legal-section code {
    padding: 2px 7px;
    background: rgba(255, 255, 255, 0.07);
    border-radius: 4px;
    font-size: 13px;
    font-family: "SF Mono", "Fira Code", ui-monospace, monospace;
    color: var(--teal);
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
  *::before,
  *::after {
        transition: none !important;
    }
}
