/* =============================================================================
   LEGAL.CSS - Shared styles for public legal pages (privacy, terms)
   All selectors scoped to #legalPage
   Self-contained: does NOT load the app's base.css. Brand colours mirror
   theme.css. Dark is default; light via [data-theme="light"] on <html>.
   ============================================================================= */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,600;9..144,700;9..144,900&family=Outfit:wght@400;500;600;700&display=swap');

/* -----------------------------------------------------------------------------
   Tokens (dark default)
   ----------------------------------------------------------------------------- */
#legalPage {
    --l-purple: #764ba2;
    --l-purple-light: #667eea;
    --l-orange: #f97316;
    --l-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 60%, #9333ea 100%);
    --l-bg: #16162a;
    --l-surface: #1e2332;
    --l-surface-2: #262b3d;
    --l-ink: rgba(255, 255, 255, 0.96);
    --l-soft: rgba(255, 255, 255, 0.68);
    --l-muted: rgba(255, 255, 255, 0.45);
    --l-line: rgba(255, 255, 255, 0.1);
}

[data-theme="light"] #legalPage {
    --l-bg: #f7f4fc;
    --l-surface: #ffffff;
    --l-surface-2: #f4f0fa;
    --l-ink: #221a33;
    --l-soft: #574a6e;
    --l-muted: #8b80a0;
    --l-line: rgba(118, 75, 162, 0.14);
}

/* -----------------------------------------------------------------------------
   Base
   ----------------------------------------------------------------------------- */
html, body {
    margin: 0;
    padding: 0;
    background: #16162a;
}

[data-theme="light"] html,
[data-theme="light"] body {
    background: #f7f4fc;
}

#legalPage * {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

#legalPage {
    font-family: 'Outfit', system-ui, sans-serif;
    color: var(--l-ink);
    background: var(--l-bg);
    line-height: 1.6;
    min-height: 100vh;
}

/* -----------------------------------------------------------------------------
   Header
   ----------------------------------------------------------------------------- */
#legalPage .legal-header {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    height: 106px;
    padding: 0 32px;
    max-width: 1280px;
    margin: 0 auto;
}

#legalPage .legal-header-right {
    display: flex;
    align-items: center;
    gap: 22px;
}

#legalPage .legal-nav {
    display: flex;
    gap: 24px;
}

#legalPage .legal-nav-link {
    text-decoration: none;
    color: var(--l-soft);
    font-weight: 600;
    font-size: 0.95rem;
}

#legalPage .legal-nav-link:hover {
    color: var(--l-purple-light);
}

#legalPage .legal-theme-toggle {
    background: var(--l-surface-2);
    border: 1px solid var(--l-line);
    cursor: pointer;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--l-ink);
}

/* -----------------------------------------------------------------------------
   Hero
   ----------------------------------------------------------------------------- */
#legalPage .legal-hero {
    text-align: center;
    padding: 20px 24px 40px;
}

#legalPage .legal-hero-title {
    font-family: 'Fraunces', serif;
    font-weight: 900;
    font-size: clamp(2rem, 5vw, 3rem);
    line-height: 1.05;
    margin-bottom: 12px;
}

#legalPage .legal-hero-sub {
    color: var(--l-soft);
    font-size: 1.05rem;
}

/* -----------------------------------------------------------------------------
   Content
   ----------------------------------------------------------------------------- */
#legalPage .legal-main {
    max-width: 760px;
    margin: 0 auto;
    padding: 0 24px 70px;
}

#legalPage .legal-section {
    background: var(--l-surface);
    border: 1px solid var(--l-line);
    border-radius: 16px;
    padding: 24px 26px;
    margin-bottom: 16px;
}

#legalPage .legal-section h2 {
    font-family: 'Fraunces', serif;
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--l-purple-light);
    margin-bottom: 12px;
}

#legalPage .legal-section p {
    color: var(--l-soft);
    margin-bottom: 12px;
}

#legalPage .legal-section p:last-child {
    margin-bottom: 0;
}

#legalPage .legal-section strong {
    color: var(--l-ink);
}

#legalPage .legal-section ul {
    list-style: none;
    margin: 0 0 12px;
    padding: 0;
}

#legalPage .legal-section li {
    color: var(--l-soft);
    padding-left: 22px;
    position: relative;
    margin-bottom: 7px;
}

#legalPage .legal-section li::before {
    content: '🍺';
    position: absolute;
    left: 0;
    font-size: 0.85rem;
}

#legalPage .legal-section a {
    color: var(--l-purple-light);
    text-decoration: none;
}

#legalPage .legal-section a:hover {
    text-decoration: underline;
}

#legalPage .legal-meta {
    color: var(--l-muted);
    font-size: 0.85rem;
    margin-top: 24px;
    text-align: center;
}

#legalPage .legal-meta p {
    margin-bottom: 6px;
}

/* -----------------------------------------------------------------------------
   Footer
   ----------------------------------------------------------------------------- */
#legalPage .legal-footer {
    padding: 40px 24px;
    text-align: center;
    border-top: 1px solid var(--l-line);
}

#legalPage .legal-footer-links {
    display: flex;
    gap: 22px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 16px;
}

#legalPage .legal-footer-link {
    color: var(--l-soft);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
}

#legalPage .legal-footer-link:hover {
    color: var(--l-purple-light);
}

#legalPage .legal-footer-copy {
    color: var(--l-muted);
    font-size: 0.85rem;
}