/* ===================================
   Legal pages (privacy, terms)
   Shares the page shell of the changelog: floating brand + controls, atmosphere
   background, centred column. Only the content blocks are defined here.
   =================================== */

.legal-page {
    max-width: 780px;
    margin: 0 auto;
    padding: 7rem 1.5rem 8rem;
    position: relative;
    z-index: 1;
}

.legal-hero {
    text-align: center;
    margin-bottom: 2.5rem;
}

.legal-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.35rem 0.85rem;
    border-radius: 999px;
    background: var(--water-light);
    color: var(--primary-color);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    margin-bottom: 1rem;
}

.legal-title {
    font-family: var(--font-primary);
    font-size: clamp(2rem, 5vw, 2.75rem);
    font-weight: 800;
    color: var(--text-primary);
    margin: 0 0 0.75rem;
    line-height: 1.15;
}

.legal-subtitle {
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.6;
    margin: 0;
}

/* Draft notice. Amber rather than red: this is a "not finished yet" state, not
   an error, and it should not read as a broken page. */
.legal-notice {
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
    padding: 1.1rem 1.25rem;
    border-radius: var(--border-radius);
    background: rgba(245, 166, 35, 0.10);
    border: 1px solid rgba(245, 166, 35, 0.30);
    color: var(--text-primary);
    font-size: 0.925rem;
    line-height: 1.6;
    margin-bottom: 2rem;
}

.legal-notice i {
    color: var(--warning-color);
    font-size: 1.25rem;
    flex-shrink: 0;
    margin-top: 0.1rem;
}

/* Section jump list. Wraps into chips rather than a sidebar so it needs no
   layout change on narrow screens. */
.legal-toc {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 2rem;
}

.legal-toc a {
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    background: var(--water-light);
    border: 1px solid transparent;
    color: var(--text-secondary);
    font-size: 0.825rem;
    font-weight: 500;
    text-decoration: none;
    transition: color var(--transition-fast), border-color var(--transition-fast);
}

.legal-toc a:hover {
    color: var(--primary-color);
    border-color: var(--primary-color);
}

/* Operator details that still have to be filled in. Deliberately loud: this
   must not be missed before the pages go live. */
.legal-placeholder {
    padding: 0.85rem 1rem;
    border-radius: var(--border-radius);
    background: rgba(245, 166, 35, 0.10);
    border: 1px dashed var(--warning-color);
    color: var(--text-primary) !important;
    font-family: var(--font-secondary);
    font-size: 0.9rem !important;
}

/* Anchor targets clear the floating header when jumped to */
.legal-card[id] {
    scroll-margin-top: 6rem;
}

.legal-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
    padding: 1.75rem;
    margin-bottom: 1.25rem;
}

.legal-card h2 {
    font-family: var(--font-primary);
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 0.75rem;
}

.legal-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.7;
    margin: 0 0 0.85rem;
}

.legal-card p:last-child {
    margin-bottom: 0;
}

.legal-card ul {
    margin: 0 0 0.85rem;
    padding-left: 1.25rem;
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.7;
}

.legal-card li {
    margin-bottom: 0.35rem;
}

.legal-card a {
    color: var(--primary-color);
    text-decoration: none;
}

.legal-card a:hover {
    text-decoration: underline;
}

.legal-updated {
    text-align: center;
    color: var(--text-light);
    font-size: 0.825rem;
    margin-top: 1.5rem;
}

@media (max-width: 600px) {
    .legal-page {
        padding: 6rem 1rem 7rem;
    }

    .legal-card {
        padding: 1.35rem;
    }
}
