/* ========================================
   LEGAL PAGES — privacy.html, terms.html
   ========================================

   Shares the palette and type of the landing page, but not its layout: these
   are documents, so they get one narrow column, generous line height, and no
   decoration competing with the text.
   ======================================== */

:root {
    --legal-measure: 42rem;
}

body.legal {
    background: var(--dark-bg);
    color: var(--text-primary);
}

.legal-main {
    max-width: var(--legal-measure);
    margin: 0 auto;
    padding: 160px var(--container-padding) 120px;
}

.legal-kicker {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
}

.legal-main h1 {
    font-size: clamp(2.1rem, 5vw, 2.9rem);
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1.1;
    margin-bottom: 1rem;
}

.legal-updated {
    font-size: 0.95rem;
    color: var(--text-secondary);
    padding-bottom: 2.5rem;
    margin-bottom: 2.5rem;
    border-bottom: 1px solid var(--border-color);
}

/* A short statement of the point of the document, before the detail. */
.legal-summary {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 14px;
    padding: 1.5rem 1.6rem;
    margin-bottom: 3rem;
}

.legal-summary p {
    margin: 0;
    font-size: 1.02rem;
    line-height: 1.65;
    color: var(--text-primary);
}

.legal-main h2 {
    font-size: 1.35rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin: 3rem 0 1rem;
}

.legal-main h3 {
    font-size: 1.05rem;
    font-weight: 600;
    margin: 2rem 0 0.75rem;
}

.legal-main p,
.legal-main li {
    font-size: 1rem;
    line-height: 1.75;
    color: var(--text-secondary);
}

.legal-main p {
    margin-bottom: 1.1rem;
}

.legal-main strong {
    color: var(--text-primary);
    font-weight: 600;
}

.legal-main ul {
    margin: 0 0 1.4rem;
    padding-left: 1.3rem;
}

.legal-main li {
    margin-bottom: 0.6rem;
}

.legal-main a {
    color: var(--text-primary);
    text-decoration: underline;
    text-underline-offset: 3px;
    text-decoration-color: rgba(255, 255, 255, 0.35);
}

.legal-main a:hover {
    text-decoration-color: var(--text-primary);
}

/* Data tables: what is collected, why, and where it goes. */
.legal-table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0 2.2rem;
    font-size: 0.95rem;
}

.legal-table th {
    text-align: left;
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-secondary);
    padding: 0 1rem 0.7rem 0;
    border-bottom: 1px solid var(--border-color);
}

.legal-table td {
    padding: 0.9rem 1rem 0.9rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    color: var(--text-secondary);
    line-height: 1.55;
    vertical-align: top;
}

.legal-table td:first-child {
    color: var(--text-primary);
    font-weight: 500;
    white-space: nowrap;
}

.legal-contact {
    margin-top: 3.5rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
}

.legal-back {
    display: inline-block;
    margin-top: 2.5rem;
    font-size: 0.95rem;
    color: var(--text-secondary);
    text-decoration: none;
}

.legal-back:hover {
    color: var(--text-primary);
}

@media (max-width: 768px) {
    .legal-main {
        padding: 120px var(--container-padding) 80px;
    }

    /* Stacked cells beat a squeezed table on a phone. */
    .legal-table,
    .legal-table tbody,
    .legal-table tr,
    .legal-table td {
        display: block;
        width: 100%;
    }

    .legal-table thead {
        display: none;
    }

    .legal-table tr {
        padding: 0.9rem 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    }

    .legal-table td {
        border: 0;
        padding: 0.15rem 0;
        white-space: normal;
    }

    .legal-table td:first-child {
        font-size: 1rem;
        margin-bottom: 0.25rem;
    }
}
