/* Privacy / cookie pages, cookie banner + settings, referral invite page (legal.py, referral.py). Theme vars from
   app.css (--gs-*) with fallbacks, because the banner is injected into every page. */
.lg-wrap { max-width: 880px; margin: 0 auto; padding: 7.5rem 1.25rem 4rem; color: var(--gs-fg, #e8eef8); }
.lg-crumb { font-size: .8rem; color: var(--gs-muted, #93a7c8); margin: 0 0 .75rem; }
.lg-crumb a { color: inherit; } .lg-crumb a:hover { color: #3b82f6; }
.lg-wrap h1 { font-size: 2rem; font-weight: 700; letter-spacing: -.01em; margin: 0 0 .35rem; }
.lg-updated { font-size: .82rem; color: var(--gs-muted, #93a7c8); margin: 0 0 1rem; }
.lg-intro { color: var(--gs-muted, #93a7c8); margin: 0 0 1.5rem; line-height: 1.6; }
.lg-toc { border: 1px solid var(--gs-border, rgba(96,165,250,.22)); background: var(--gs-card, rgba(37,99,235,.1));
          border-radius: 1rem; padding: 1rem 1.25rem; margin: 0 0 2rem; }
.lg-toc h2 { font-size: .85rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; margin: 0 0 .5rem;
             color: var(--gs-muted, #93a7c8); }
.lg-toc ol { list-style: decimal; margin: 0; padding-left: 1.25rem; columns: 2; column-gap: 2rem; font-size: .9rem; }
.lg-toc li { margin: .15rem 0; break-inside: avoid; }
.lg-toc a, .lg-sec a, .lg-links a { color: #60a5fa; text-decoration: underline; text-underline-offset: 2px; }
html.light .lg-toc a, html.light .lg-sec a, html.light .lg-links a { color: #1d4ed8; }
.lg-sec { margin: 0 0 1.75rem; scroll-margin-top: 6rem; }
.lg-sec h2 { font-size: 1.25rem; font-weight: 700; margin: 0 0 .5rem; }
.lg-sec p { margin: 0 0 .75rem; line-height: 1.65; }
.lg-sec ul { list-style: disc; margin: 0 0 .75rem; padding-left: 1.4rem; line-height: 1.6; }
.lg-sec li { margin: .2rem 0; }
.lg-links { font-size: .9rem; margin: .25rem 0 0; }
.lg-table-wrap { overflow-x: auto; margin: .25rem 0 1rem; }
.lg-table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.lg-table th, .lg-table td { text-align: left; vertical-align: top; padding: .55rem .6rem;
                             border-bottom: 1px solid var(--gs-border, rgba(96,165,250,.22)); }
.lg-table th { font-size: .75rem; text-transform: uppercase; letter-spacing: .04em; color: var(--gs-muted, #93a7c8); }
.lg-table code, .lg-sec code { font-size: .85em; padding: .05rem .35rem; border-radius: .35rem;
                               background: rgba(148,163,184,.15); white-space: nowrap; }
.lg-card { border: 1px solid var(--gs-border, rgba(96,165,250,.22)); background: var(--gs-card, rgba(37,99,235,.1));
           border-radius: 1rem; padding: 1.25rem; margin: 0 0 1.5rem; }
.lg-saved { border: 1px solid rgba(16,185,129,.45); background: rgba(16,185,129,.12); color: #a7f3d0; border-radius: .75rem;
            padding: .6rem .9rem; margin: 0 0 1rem; font-size: .9rem; }
html.light .lg-saved { color: #047857; background: #ecfdf5; }
.lg-opt { display: flex; gap: .75rem; align-items: flex-start; padding: .7rem 0;
          border-bottom: 1px solid var(--gs-border, rgba(96,165,250,.22)); }
.lg-opt:last-of-type { border-bottom: 0; }
.lg-opt input { width: 1.1rem; height: 1.1rem; margin-top: .2rem; accent-color: #3b82f6; flex-shrink: 0; }
.lg-opt strong { display: block; font-weight: 650; }
.lg-opt-txt { display: block; }
.lg-opt-txt > span { display: block; font-size: .85rem; color: var(--gs-muted, #93a7c8); }
.lg-pill { font-style: normal; display: inline-block; font-size: .7rem; font-weight: 650; padding: .05rem .5rem; border-radius: 999px;
           border: 1px solid currentColor; color: #4ade80; margin-left: .35rem; }
html.light .lg-pill { color: #15803d; }
.lg-btns { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: 1rem; }
.lg-btn { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; padding: .6rem 1.1rem;
          border-radius: .75rem; font-weight: 650; font-size: .92rem; cursor: pointer; text-decoration: none;
          border: 1px solid transparent; line-height: 1.2; }
.lg-btn--primary { background: linear-gradient(90deg, #3b82f6, #6366f1); color: #fff; }
.lg-btn--primary:hover { filter: brightness(1.08); }
.lg-btn--ghost { border-color: rgba(148,163,184,.45); color: var(--gs-fg, #e8eef8); background: transparent; }
.lg-btn--ghost:hover { border-color: #3b82f6; }
.lg-btn:focus-visible { outline: 2px solid #60a5fa; outline-offset: 2px; }
html.light .lg-btn--ghost { color: #0f172a; border-color: #cbd5e1; background: #fff; }
.lg-code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 1.05rem; letter-spacing: .04em; }
.lg-muted { color: var(--gs-muted, #93a7c8); font-size: .88rem; }

/* Cookie banner (injected before </body> until a choice is made) */
.gs-cb { position: fixed; left: 1rem; right: 1rem; bottom: 1rem; z-index: 9999; max-width: 46rem; margin: 0 auto;
         background: #0f2547; color: #e8eef8; border: 1px solid rgba(96,165,250,.35); border-radius: 1rem;
         box-shadow: 0 20px 50px -12px rgba(0,0,0,.6); padding: 1.1rem 1.25rem; font-size: .92rem; line-height: 1.5;
         font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, sans-serif; }
html.light .gs-cb { background: #fff; color: #0f172a; border-color: #cbd5e1; box-shadow: 0 20px 50px -16px rgba(15,23,42,.35); }
.gs-cb h2 { font-size: 1rem; font-weight: 700; margin: 0 0 .35rem; color: inherit; }
.gs-cb p { margin: 0; color: inherit; opacity: .92; }
.gs-cb form { margin: 0; }
.gs-cb .lg-btns { margin-top: .85rem; }
.gs-cb .lg-btn--ghost { color: inherit; }
@media (max-width: 520px) { .gs-cb { left: .5rem; right: .5rem; bottom: .5rem; padding: 1rem; }
  .gs-cb .lg-btn { flex: 1 1 100%; } .lg-toc ol { columns: 1; } .lg-wrap h1 { font-size: 1.6rem; } }
@media (prefers-reduced-motion: no-preference) { .lg-btn { transition: filter .15s, border-color .15s; } }
