:root {
    --bg: #ffffff;
    --bg-soft: #f8fafc;
    --bg-muted: #f1f5f9;
    --text: #0f172a;
    --text-muted: #64748b;
    --text-faint: #94a3b8;
    --primary: #6366f1;
    --primary-soft: rgba(99, 102, 241, 0.1);
    --border: #e2e8f0;
    --border-strong: #cbd5e1;
}

* { box-sizing: border-box; }

html, body {
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: var(--bg);
    color: var(--text);
    -webkit-font-smoothing: antialiased;
    line-height: 1.6;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

a { color: inherit; }

img { max-width: 100%; height: auto; display: block; }

/* ---------- Header ---------- */
.site-header {
    border-bottom: 1px solid var(--border);
    padding: 1rem 1.5rem;
    background: var(--bg);
}

.site-header-inner {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.site-header a.logo-link img {
    height: 36px;
    width: auto;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s ease;
}

.back-link:hover { color: var(--text); }

.back-link svg { width: 16px; height: 16px; }

/* ---------- Legal page layout ---------- */
.legal {
    flex: 1;
    max-width: 880px;
    width: 100%;
    margin: 0 auto;
    padding: 4rem 1.5rem 5rem;
}

.legal header { margin-bottom: 3rem; }

.legal .eyebrow {
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--primary);
    margin: 0 0 1rem;
}

.legal h1 {
    font-size: clamp(2rem, 4vw, 2.5rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    margin: 0 0 1rem;
    color: var(--text);
}

.legal .lead {
    font-size: 1.075rem;
    color: var(--text-muted);
    margin: 0 0 1rem;
}

.legal .meta {
    font-size: 0.875rem;
    color: var(--text-faint);
    margin: 0;
}

.legal section {
    margin-bottom: 2.5rem;
}

.legal h2 {
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0 0 1rem;
    color: var(--text);
    letter-spacing: -0.01em;
}

.legal h3 {
    font-size: 1.05rem;
    font-weight: 600;
    margin: 1.5rem 0 0.5rem;
    color: var(--text);
}

.legal p { margin: 0 0 1rem; color: var(--text-muted); }

.legal strong { color: var(--text); font-weight: 600; }

.legal a {
    color: var(--primary);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.legal a:hover { text-decoration: none; }

.legal ul, .legal ol {
    margin: 0 0 1rem;
    padding-left: 1.5rem;
    color: var(--text-muted);
}

.legal ul li, .legal ol li { margin-bottom: 0.4rem; }

.legal .toc {
    background: var(--bg-soft);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 1.25rem 1.5rem;
    margin-bottom: 2.5rem;
}

.legal .toc-title {
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin: 0 0 0.75rem;
    color: var(--text);
}

.legal .toc ol {
    margin: 0;
    padding-left: 1.25rem;
    columns: 1;
    font-size: 0.92rem;
}

@media (min-width: 640px) {
    .legal .toc ol { columns: 2; column-gap: 2rem; }
}

.legal .callout {
    font-size: 0.9rem;
    font-style: italic;
    color: var(--primary);
    margin: 0 0 1rem;
    font-weight: 500;
}

.legal .info-list {
    list-style: none;
    padding: 0;
    margin: 0 0 1rem;
    border-left: 3px solid var(--border-strong);
    padding-left: 1rem;
}

.legal .info-list li { margin-bottom: 0.4rem; }

.legal table {
    width: 100%;
    border-collapse: collapse;
    margin: 0 0 1rem;
    font-size: 0.92rem;
}

.legal table thead th {
    text-align: left;
    padding: 0.6rem 1rem 0.6rem 0;
    border-bottom: 1px solid var(--border-strong);
    font-weight: 600;
    color: var(--text);
}

.legal table tbody td {
    padding: 0.6rem 1rem 0.6rem 0;
    border-bottom: 1px solid var(--border);
    vertical-align: top;
    color: var(--text-muted);
}

.legal .table-wrap { overflow-x: auto; margin-bottom: 1rem; }

.legal .footer-note {
    margin-top: 3rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* ---------- Site footer (shared) ---------- */
.site-footer {
    background: var(--bg-soft);
    border-top: 1px solid var(--border);
    padding: 2.5rem 1.5rem 2rem;
    margin-top: auto;
}

.site-footer-inner {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem 2rem;
    justify-content: center;
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.92rem;
    transition: color 0.2s ease;
}

.footer-links a:hover { color: var(--text); }

.footer-bottom {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--border);
    color: var(--text-faint);
    font-size: 0.85rem;
}

.footer-bottom a { color: var(--text-faint); text-decoration: none; }
.footer-bottom a:hover { color: var(--text); }

@media (min-width: 640px) {
    .footer-bottom { flex-direction: row; justify-content: space-between; }
}

/* ---------- Coming soon ---------- */
.coming-soon-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 5rem 1.5rem;
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
}

.coming-soon-main img.logo {
    max-width: 220px;
    margin-bottom: 2.5rem;
}

.coming-soon-main h1 {
    font-size: clamp(2.25rem, 5vw, 3.5rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    margin: 0 0 1rem;
    background: linear-gradient(135deg, #1e293b 0%, #6366f1 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.coming-soon-main p {
    font-size: 1.125rem;
    color: var(--text-muted);
    max-width: 540px;
    line-height: 1.6;
    margin: 0;
}
