/* Shared styling for the static legal pages under /legal.
   Hand-written, no build step: pandoc emits the body, this dresses it.
   Deliberately dependency-free — a rights-holder's lawyer should be able to
   read these with JavaScript off and a screen reader on. */

:root {
  color-scheme: light dark;
  --bg: #ffffff;
  --surface: #f6f7f9;
  --text: #16181d;
  --muted: #5b6270;
  --rule: #e2e5ea;
  --link: #1668a8;
  --accent: #fbb040;         /* TourMuse logo gold */
  --draft-bg: #fff6e4;
  --draft-rule: #fbb040;
  --draft-text: #5a4213;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #14161a;
    --surface: #1c1f25;
    --text: #e8eaee;
    --muted: #9aa2b1;
    --rule: #2c313a;
    --link: #6fc0f2;
    --draft-bg: #2e2413;
    --draft-rule: #fbb040;
    --draft-text: #f5d9a4;
  }
}
:root[data-theme="dark"] {
  --bg: #14161a;
  --surface: #1c1f25;
  --text: #e8eaee;
  --muted: #9aa2b1;
  --rule: #2c313a;
  --link: #6fc0f2;
  --draft-bg: #2e2413;
  --draft-rule: #fbb040;
  --draft-text: #f5d9a4;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  padding: 0 16px 64px;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.65 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
        "Helvetica Neue", Arial, sans-serif;
  -webkit-text-size-adjust: 100%;
}

.skip {
  position: absolute; left: -9999px;
}
.skip:focus {
  left: 16px; top: 16px; z-index: 10;
  background: var(--bg); color: var(--link);
  padding: 8px 12px; border: 2px solid var(--link); border-radius: 6px;
}

header.page-head, main, .draft, footer.page-foot {
  max-width: 44rem;
  margin-inline: auto;
}

header.page-head {
  padding: 40px 0 20px;
  border-bottom: 1px solid var(--rule);
}
.brand {
  margin: 0 0 6px;
  font-size: 13px; font-weight: 700; letter-spacing: .14em;
  text-transform: uppercase; color: var(--accent);
}
header.page-head h1 {
  margin: 0; font-size: 2rem; line-height: 1.2; letter-spacing: -.01em;
}
.subtitle, .effective {
  margin: 8px 0 0; color: var(--muted); font-size: .9rem;
}

.draft {
  margin-top: 24px; padding: 14px 16px;
  background: var(--draft-bg); color: var(--draft-text);
  border: 1px solid var(--draft-rule); border-left-width: 5px;
  border-radius: 8px; font-size: .94rem;
}
.draft strong { display: block; margin-bottom: 2px; }

main { padding-top: 8px; }

h1, h2, h3, h4 { line-height: 1.25; letter-spacing: -.005em; }
/* Sources use `#` for a numbered section and `##` for a subsection; the build
   shifts both down one level so the page title is the only <h1>. */
main h2 {
  margin: 40px 0 12px; padding-top: 20px;
  font-size: 1.3rem; border-top: 1px solid var(--rule);
}
main section:first-of-type h2 { border-top: 0; padding-top: 0; margin-top: 24px; }
main h3 { margin: 28px 0 10px; font-size: 1.08rem; }
main h4 { margin: 22px 0 8px; font-size: 1rem; color: var(--muted); }

p, li { overflow-wrap: break-word; }
ul, ol { padding-left: 1.3em; }
li { margin: .3em 0; }

a { color: var(--link); text-underline-offset: .15em; }
a:hover { text-decoration-thickness: 2px; }

strong { font-weight: 650; }

blockquote {
  margin: 18px 0; padding: 2px 16px;
  border-left: 3px solid var(--rule); color: var(--muted);
}

code {
  font: .9em/1.4 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  background: var(--surface); padding: .12em .35em; border-radius: 4px;
}

hr { border: 0; border-top: 1px solid var(--rule); margin: 32px 0; }

/* Tables carry real content in these documents (the agent details, the
   rights tables), so they must stay readable at phone width. */
.table-wrap, table { display: block; max-width: 100%; overflow-x: auto; }
table {
  border-collapse: collapse; margin: 18px 0; font-size: .95rem;
}
th, td {
  border: 1px solid var(--rule); padding: 8px 12px;
  text-align: left; vertical-align: top;
}
th { background: var(--surface); font-weight: 650; }

footer.page-foot {
  margin-top: 56px; padding-top: 20px;
  border-top: 1px solid var(--rule);
  color: var(--muted); font-size: .88rem;
}
footer.page-foot nav { margin-bottom: 12px; }
footer.page-foot nav a { margin-right: 18px; }

@media print {
  .draft { border-left-width: 1px; }
  .skip, footer.page-foot nav { display: none; }
}
