/* Shared styles for long-form legal pages (privacy.html, terms.html). */
:root {
  --brand: #0C447C;
  --brand-soft: color-mix(in srgb, var(--brand) 8%, white);
  --brand-ink: var(--brand); /* brand color used as text */
  --ink: #0F172A;
  --body: #334155;
  --muted: #64748B;
  --line: #E2E8F0;
  --bg: #F4F5F7;
  --card: #FFFFFF;
  --note-bg: #FFFBEB;
  --note-line: #F59E0B;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Plus Jakarta Sans", system-ui, sans-serif;
  color: var(--body);
  background: var(--bg);
  line-height: 1.7;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.page { width: 100%; max-width: 880px; margin: 0 auto; padding: 48px 16px 56px; flex: 1; }

.card {
  background: var(--card); border-radius: 18px; overflow: hidden;
  box-shadow: 0 1px 2px rgba(15,23,42,.06), 0 24px 48px -20px rgba(15,23,42,.2);
}
.card-head { padding: 28px 40px; background: var(--brand); color: #E6F1FB; }
.eyebrow { margin: 0; font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: #85B7EB; }
h1 { margin: 4px 0 0; font-size: clamp(24px, 4vw, 32px); line-height: 1.2; letter-spacing: -.01em; color: #fff; }

.doc { padding: 32px 40px 40px; font-size: 15.5px; }
.doc > p:first-child { margin-top: 0; }
.doc .meta { color: var(--muted); font-size: 14px; font-weight: 600; }

/* Table of contents */
.toc {
  list-style: none; margin: 24px 0 36px; padding: 20px 24px; border-radius: 14px;
  background: var(--brand-soft); border: 1px solid var(--line);
  columns: 2; column-gap: 32px;
}
.toc::before {
  content: "On this page"; display: block; column-span: all; margin-bottom: 10px;
  font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted);
}
.toc li { break-inside: avoid; padding: 3px 0; font-size: 14.5px; }
.toc a { color: var(--brand-ink); text-decoration: none; font-weight: 600; }
.toc a:hover { text-decoration: underline; }

h2 {
  color: var(--ink); font-size: 21px; line-height: 1.3; margin: 44px 0 12px; padding-top: 20px;
  border-top: 1px solid var(--line); scroll-margin-top: 84px; letter-spacing: -.01em;
}
.toc + h2 { border-top: 0; padding-top: 0; margin-top: 0; }
h3 { color: var(--ink); font-size: 16.5px; margin: 26px 0 6px; }
p { margin: 0 0 14px; }
ul { margin: 0 0 16px; padding-left: 22px; }
li { margin-bottom: 6px; }
li::marker { color: var(--brand-ink); }
strong { color: var(--ink); }
.doc a { color: var(--brand-ink); font-weight: 600; word-break: break-word; }

/* Highlighted notices (Important Notice, Opt-Out, contact blocks…) */
.callout {
  margin: 18px 0 20px; padding: 16px 20px; border-radius: 12px;
  background: var(--note-bg); border-left: 4px solid var(--note-line);
}
.callout p:last-child { margin-bottom: 0; }

/* Tables scroll sideways on small screens instead of squashing */
.table-wrap { overflow-x: auto; margin: 16px 0 22px; border: 1px solid var(--line); border-radius: 12px; }
table { width: 100%; border-collapse: collapse; font-size: 14.5px; min-width: 520px; }
th, td { text-align: left; vertical-align: top; padding: 11px 14px; border-bottom: 1px solid var(--line); }
tr:last-child td { border-bottom: 0; }
th { background: var(--brand-soft); color: var(--ink); font-weight: 700; }

.to-top {
  position: fixed; right: 20px; bottom: 20px; width: 46px; height: 46px; border-radius: 50%;
  display: grid; place-items: center; background: var(--brand); color: #fff; text-decoration: none;
  box-shadow: 0 8px 20px -6px rgba(15,23,42,.45); opacity: 0; pointer-events: none; transition: opacity .2s;
}
.to-top.show { opacity: 1; pointer-events: auto; }
.to-top svg { width: 20px; height: 20px; }


@media (max-width: 640px) {
  .page { padding: 20px 10px 40px; }
  .card-head { padding: 22px 20px; }
  .doc { padding: 24px 20px 28px; font-size: 15px; }
  .toc { columns: 1; padding: 16px 18px; }
  h2 { font-size: 19px; margin-top: 36px; }
  .to-top { right: 14px; bottom: 14px; }
  /* Tables become stacked cards instead of scrolling sideways (labels come from site-footer.js) */
  .table-wrap { border: 0; overflow: visible; }
  table, tbody, tr, td { display: block; min-width: 0; width: 100%; }
  tr:first-child { display: none; }
  tr { margin-bottom: 12px; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: #fff; }
  tr:last-child td { border-bottom: 1px solid var(--line); }
  tr td:last-child, tr:last-child td:last-child { border-bottom: 0; }
  td::before { content: attr(data-label); display: block; margin-bottom: 2px; font-size: 11.5px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: #64748B; }
}
@media print {
  .site-header, .to-top, footer { display: none; }
  body { background: #fff; }
  .card { box-shadow: none; }
}
