/* ============================================================
   LEGAL STYLESHEET — privacy.html & terms-of-service.html only.
   Loads alone (no style.css). Drafting-bay palette to match the
   main site while keeping full contrast and an isolated scope.
   Palette tokens:
     page / paper  #FBFAF2 (vellum) and reading band #F2F1EA
     ink / text    #2C2E2A (pencil lead)
     hero band     #3E4A3A (greeneback) with vellum-white text
     accent        #A8842C (mustard ink), rails #9A988C
   Legal pages carry their own strong colours. No rgba, no
   opacity decimals, no text gradients.
   ============================================================ */

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Trebuchet MS', 'Gill Sans', 'Segoe UI', Verdana, sans-serif;
  font-size: 16px;
  line-height: 1.75;
  color: #2C2E2A;
  background-color: #F2F1EA;
  overflow-x: hidden;
}

p {
  color: #2C2E2A;
}

a {
  color: #A8842C;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* ============================================================
   HTML default colour tied to leaf body so that unlinked text
   never inherits a link blue.
   ============================================================ */

h1, h2, h3, h4 {
  color: #2C2E2A;
  line-height: 1.3;
}

/* ------------------------------------------------------------------
   SITE-WIDE LAYER — legal page wraps everything in .legal-page.
   We scope every rule under .legal-page so nothing leaks style.css
   semantics onto a standalone sheet.
   ------------------------------------------------------------------ */

.legal-page {
  background-color: #F2F1EA;
  color: #2C2E2A;
}

/* ============================================================
   LEGAL HEADER (solid background, strong h1 contrast)
   ============================================================ */

.legal-header {
  background-color: #3E4A3A;
  border-bottom: 6px solid #A8842C;
}

.legal-header-inner {
  max-width: 880px;
  margin: 0 auto;
  padding: 44px 24px 38px 24px;
}

.legal-branding {
  display: inline-block;
  background-color: #3E4A3A;
  border: 1px solid #FBFAF2;
  border-top: 4px solid #A8842C;
  color: #FBFAF2;
  font-weight: 800;
  padding: 8px 14px;
  text-decoration: none;
  margin-bottom: 22px;
}

.legal-branding .lb-rule {
  color: #A8842C;
}

.legal-branding:hover {
  text-decoration: none;
}

.legal-kicker {
  text-transform: uppercase;
  letter-spacing: 0.24em;
  color: #F2F1EA;
  font-weight: 700;
  font-size: 0.84rem;
  margin: 0 0 10px 0;
}

.legal-kicker em {
  font-style: normal;
  color: #A8842C;
}

.legal-header h1 {
  color: #FBFAF2;
  margin: 0;
  font-size: clamp(1.8rem, 5vw, 3rem);
  line-height: 1.15;
}

.legal-lede {
  color: #E8E5DA;
  max-width: 760px;
  margin: 18px 0 0 0;
  font-size: 1.06rem;
}

/* ============================================================
   CONTENT + TABLE OF CONTENTS
   ============================================================ */

.legal-body {
  background-color: #F2F1EA;
  padding: 40px 0 0 0;
}

.legal-content {
  max-width: 880px;
  margin: 0 auto;
  padding: 0 24px 0 24px;
}

/* Isolate section surfaces: legal sections are transparent so the
   body band reads through. (See required scoped rule below.) */

.toc-panel {
  background-color: #FBFAF2;
  border: 1px solid #CFCCBE;
  border-left: 6px solid #A8842C;
  border-radius: 4px;
  padding: 22px 26px;
  margin: 0 0 34px 0;
  box-shadow: 4px 4px 0 #A7A99B;
}

.toc-panel h2 {
  margin: 0 0 10px 0;
  font-size: 1.25rem;
}

.toc-panel ol {
  columns: 2;
  column-gap: 40px;
  margin: 0;
  padding-left: 20px;
}

.toc-panel li {
  margin-bottom: 6px;
  break-inside: avoid;
}

.toc-panel a {
  color: #2C2E2A;
  font-weight: 600;
}

.toc-panel a:hover {
  color: #A8842C;
  text-decoration: none;
}

/* ============================================================
   LEGAL SECTIONS (only sections inside legal-content)
   Surfaces stay transparent so the page band reads through.
   The scope-isolation rule immediately below is required.
   ============================================================ */

.legal-page .legal-content section {
  background: transparent;
  background-color: transparent;
}

.legal-page .legal-content section {
  background: transparent !important;
  border: 0;
  border-radius: 0;
  padding: 0 0 6px 0;
  margin: 0 0 26px 0;
  box-shadow: none;
  scroll-margin-top: 20px;
}

.legal-page .legal-content section h2 {
  position: relative;
  color: #2C2E2A;
  font-size: 1.45rem;
  margin: 0 0 12px 0;
  padding-bottom: 10px;
  border-bottom: 2px solid #A8842C;
}

.legal-page .legal-content section h2::before {
  content: "";
  display: inline-block;
  width: 12px;
  height: 12px;
  background-color: #A8842C;
  border-radius: 2px;
  margin-right: 10px;
  transform: translateY(-1px);
}

.legal-page .legal-content section h3 {
  color: #2C2E2A;
  font-size: 1.12rem;
  margin: 18px 0 6px 0;
}

.legal-page .legal-content p {
  color: #2C2E2A;
  margin: 0 0 14px 0;
}

.legal-page .legal-content ul,
.legal-page .legal-content ol {
  color: #2C2E2A;
  margin: 0 0 14px 0;
  padding-left: 22px;
}

.legal-page .legal-content li {
  color: #2C2E2A;
  margin-bottom: 8px;
}

.legal-page .legal-content strong {
  color: #2C2E2A;
}

.legal-page .legal-content .aux-note {
  background-color: #8A937E;
  border-left: 5px solid #3E4A3A;
  color: #FBFAF2;
  padding: 12px 16px;
  margin: 10px 0 14px 0;
  font-size: 0.94rem;
}

.legal-page .legal-content .aux-note p,
.legal-page .legal-content .aux-note strong {
  color: #FBFAF2;
}

.legal-page .legal-content .revision-stamp {
  display: inline-block;
  background-color: #3E4A3A;
  border: 1px solid #A8842C;
  color: #F2F1EA;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: 3px;
  font-size: 0.76rem;
  margin: 4px 0 12px 0;
}

.legal-up {
  display: inline-block;
  margin-top: 4px;
  font-size: 0.9rem;
  color: #3E4A3A;
  font-weight: 700;
}

/* ============================================================
   LEGAL FOOTER — links home on drafting-bay base plates
   ============================================================ */

.legal-footer {
  margin-top: 36px;
  background-color: #3E4A3A;
  border-top: 6px solid #A8842C;
}

.legal-footer-inner {
  max-width: 880px;
  margin: 0 auto;
  padding: 34px 24px;
  text-align: center;
}

.legal-footer p {
  color: #E8E5DA;
  margin: 0 0 10px 0;
}

.legal-footer .lf-strong {
  color: #FBFAF2;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.legal-footer .lf-plate {
  display: inline-block;
  background-color: #FBFAF2;
  color: #2C2E2A;
  border: 1px solid #B7B4A7;
  padding: 12px 22px;
  border-radius: 4px;
  box-shadow: 0 4px 0 #26302A;
  font-size: 0.92rem;
  margin: 8px 0 4px 0;
}

.legal-footer .lf-home {
  display: inline-block;
  background-color: #A8842C;
  color: #FBFAF2;
  font-weight: 700;
  padding: 10px 20px;
  border-radius: 3px;
  margin-top: 12px;
  text-decoration: none;
}

.legal-footer .lf-home:hover {
  background-color: #96741F;
  text-decoration: none;
}

.legal-footer-inner a {
  color: #A8C29A;
}

.legal-footer-inner a:hover {
  color: #FBFAF2;
}

/* Footer link that sits at the end of the content column */
.legal-footer-links {
  margin: 6px 0 0 0;
  padding: 0 0 6px 0;
}

.legal-footer-links p {
  margin: 0;
}

.legal-footer-links .lf-home-inline {
  display: inline-block;
  background-color: #A8842C;
  color: #FBFAF2;
  font-weight: 700;
  padding: 9px 18px;
  border-radius: 3px;
  text-decoration: none;
}

.legal-footer-links .lf-home-inline:hover {
  background-color: #96741F;
  text-decoration: none;
}

/* Contact details plate inside content (must be opaque) */
.contact-plate-exact {
  background-color: #FBFAF2;
  border: 1px solid #D8D5C7;
  border-left: 6px solid #A8842C;
  border-radius: 4px;
  padding: 16px 20px;
  margin: 14px 0;
}

.contact-plate-exact p {
  margin: 0 0 4px 0;
  color: #2C2E2A;
}

.legal-content .contact-plate-exact a {
  color: #6A4E00;
  font-weight: 700;
}

/* Skip link for legal pages */
.legal-page .skip-link {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.legal-page .skip-link:focus {
  position: absolute;
  left: 10px;
  top: 8px;
  width: auto;
  height: auto;
  padding: 12px 18px;
  background-color: #A8842C;
  color: #FBFAF2;
  border-radius: 3px;
  font-weight: 700;
  z-index: 999;
  overflow: visible;
}

/* End of legal stylesheet */
