:root {
    --bg: #0b0b10;
    --surface: #141425;
    --surface-2: #1b1b31;
    --primary: #7c3aed;
    --accent: #a855f7;
    --text-primary: #e5e7eb;
    --text-secondary: #9ca3af;
    --border: rgba(168, 85, 247, 0.25);
    --shadow-glow: 0 0 0 1px rgba(168, 85, 247, 0.16), 0 12px 40px rgba(124, 58, 237, 0.22);
    --radius-lg: 18px;
    --radius-md: 12px;
    --max-content: 860px;
    --max-layout: 1240px;
    --transition: 260ms ease;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: "Inter", sans-serif;
    background: var(--bg);
    color: var(--text-primary);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    overflow-x: hidden;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 500ms ease, transform 500ms ease;
}

body.loaded {
    opacity: 1;
    transform: translateY(0);
}

body::before,
body::after {
    content: "";
    position: fixed;
    width: 48rem;
    height: 48rem;
    border-radius: 999px;
    filter: blur(80px);
    z-index: -2;
    pointer-events: none;
    opacity: 0.2;
}

body::before {
    top: -15rem;
    left: -12rem;
    background: radial-gradient(circle, rgba(124, 58, 237, 0.75) 0%, rgba(124, 58, 237, 0) 62%);
    animation: driftA 14s ease-in-out infinite alternate;
}

body::after {
    right: -14rem;
    bottom: -20rem;
    background: radial-gradient(circle, rgba(168, 85, 247, 0.7) 0%, rgba(168, 85, 247, 0) 60%);
    animation: driftB 16s ease-in-out infinite alternate;
}

.page-noise {
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background-image: radial-gradient(rgba(255, 255, 255, 0.03) 0.6px, transparent 0.6px);
    background-size: 2px 2px;
    opacity: 0.45;
}

@keyframes driftA {
    from {
        transform: translate(0, 0) scale(1);
    }
    to {
        transform: translate(5rem, 2rem) scale(1.08);
    }
}

@keyframes driftB {
    from {
        transform: translate(0, 0) scale(1);
    }
    to {
        transform: translate(-4rem, -3rem) scale(1.1);
    }
}

.skip-link {
    position: absolute;
    top: -100px;
    left: 12px;
    background: var(--surface);
    color: var(--text-primary);
    border: 1px solid var(--border);
    padding: 10px 14px;
    border-radius: 10px;
}

.skip-link:focus {
    top: 12px;
    z-index: 30;
}

.footer-links a,
.toc a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color var(--transition), background-color var(--transition), border-color var(--transition);
}

.hero {
    max-width: var(--max-layout);
    margin: 0 auto;
    padding: 56px 20px 36px;
}

.hero-card {
    position: relative;
    padding: 32px;
    border-radius: var(--radius-lg);
    background: linear-gradient(155deg, rgba(20, 20, 37, 0.94), rgba(18, 18, 30, 0.86));
    border: 1px solid rgba(168, 85, 247, 0.25);
    box-shadow: var(--shadow-glow);
    overflow: hidden;
}

.hero-card::before {
    content: "";
    position: absolute;
    inset: -40% auto auto -12%;
    width: 320px;
    height: 320px;
    background: radial-gradient(circle, rgba(168, 85, 247, 0.32) 0%, rgba(168, 85, 247, 0) 65%);
    pointer-events: none;
}

.hero h1 {
    margin: 0;
    font-size: clamp(2rem, 4vw, 3rem);
    letter-spacing: -0.02em;
}

.hero p {
    max-width: 68ch;
    margin: 16px 0 0;
    color: var(--text-secondary);
    font-size: 1.03rem;
}

.last-updated {
    display: inline-block;
    margin-top: 18px;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(124, 58, 237, 0.18);
    border: 1px solid rgba(168, 85, 247, 0.34);
    color: #d8c9ff;
    font-size: 0.84rem;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.layout {
    max-width: var(--max-layout);
    margin: 0 auto;
    padding: 16px 20px 80px;
    display: grid;
    grid-template-columns: minmax(0, var(--max-content)) 280px;
    justify-content: center;
    gap: 28px;
}

.document {
    min-width: 0;
}

.legal-card {
    background: linear-gradient(180deg, rgba(20, 20, 37, 0.88), rgba(17, 17, 30, 0.72));
    border: 1px solid rgba(168, 85, 247, 0.22);
    border-radius: var(--radius-lg);
    padding: clamp(22px, 4vw, 34px);
    box-shadow: 0 10px 30px rgba(8, 8, 13, 0.55), inset 0 0 0 1px rgba(255, 255, 255, 0.015);
    position: relative;
}

.legal-card::after {
    content: "";
    position: absolute;
    inset: -1px;
    border-radius: var(--radius-lg);
    pointer-events: none;
    border: 1px solid transparent;
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.38), rgba(124, 58, 237, 0.08)) border-box;
    -webkit-mask: linear-gradient(#000 0 0) padding-box, linear-gradient(#000 0 0);
    mask: linear-gradient(#000 0 0) padding-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
}

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

.legal-section h2 {
    margin: 0 0 8px;
    font-size: clamp(1.25rem, 2.2vw, 1.5rem);
    letter-spacing: -0.01em;
}

.legal-section h3 {
    margin: 18px 0 8px;
    font-size: 1.03rem;
    color: #dbcfff;
}

.legal-section p {
    margin: 10px 0;
    color: var(--text-secondary);
}

.legal-section ul,
.legal-section ol {
    margin: 8px 0 12px 20px;
    color: var(--text-secondary);
}

.legal-section li {
    margin: 7px 0;
}

.legal-section strong {
    color: var(--text-primary);
}

.toc {
    position: sticky;
    top: 24px;
    align-self: start;
    padding: 18px;
    border-radius: var(--radius-md);
    background: rgba(20, 20, 37, 0.72);
    border: 1px solid rgba(168, 85, 247, 0.2);
    box-shadow: 0 8px 24px rgba(8, 8, 12, 0.5);
}

.toc h2 {
    margin: 0 0 12px;
    font-size: 0.9rem;
    color: #ddd2ff;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.toc ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.toc a {
    display: block;
    padding: 8px 10px;
    border-radius: 8px;
    border: 1px solid transparent;
    font-size: 0.94rem;
}

.toc a:hover,
.toc a.active {
    color: var(--text-primary);
    border-color: rgba(168, 85, 247, 0.28);
    background: rgba(124, 58, 237, 0.16);
}

.site-footer {
    border-top: 1px solid rgba(168, 85, 247, 0.18);
    background: linear-gradient(180deg, rgba(11, 11, 16, 0.95), rgba(11, 11, 16, 1));
}

.footer-shell {
    max-width: var(--max-layout);
    margin: 0 auto;
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}

.footer-shell p {
    margin: 0;
    color: var(--text-secondary);
    font-size: 0.92rem;
}

.footer-links {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
}

.footer-links a:hover {
    color: var(--text-primary);
}

.footer-links a.active {
    color: var(--text-primary);
}

.reveal {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 420ms ease, transform 420ms ease;
}

.reveal.show {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 1024px) {
    .layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .toc {
        display: none;
    }
}

@media (max-width: 768px) {
    .hero-card {
        padding: 24px;
    }

    .legal-card {
        padding: 22px 18px;
    }
}

@media (max-width: 420px) {
    .hero,
    .layout,
    .footer-shell {
        padding-left: 14px;
        padding-right: 14px;
    }

    .hero p,
    .legal-section p,
    .legal-section li {
        font-size: 0.96rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation: none !important;
        transition: none !important;
    }

    html {
        scroll-behavior: auto;
    }
}
