/* ============================================================
   Legal page template — shared across Privacy / Terms / Accessibility
   ============================================================ */

/* ---------- Hero (slim, no image) ---------- */
.legal-hero {
  background: var(--c-ivory);
  padding-top: 96px;
  padding-bottom: 48px;
}
@media (max-width: 767px) {
  .legal-hero { padding-top: 64px; padding-bottom: 32px; }
}
.legal-hero-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
  position: relative;
}
.legal-hero-rule {
  position: absolute;
  left: -8px;
  top: 8px;
  width: 1px;
  height: 96px;
  background: var(--c-sea);
  opacity: 0.4;
}
@media (max-width: 767px) {
  .legal-hero-rule { left: 0; height: 64px; }
}
.legal-hero-wrap {
  padding-left: 32px;
  position: relative;
}
@media (max-width: 767px) {
  .legal-hero-wrap { padding-left: 16px; }
}
.legal-hero .eyebrow { margin-bottom: 20px; color: var(--c-sea-text); }
.legal-hero .eyebrow::before { background: var(--c-sea); }
.legal-hero h1 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 56px;
  line-height: 1.05;
  letter-spacing: -0.005em;
  color: var(--c-deep);
  margin: 0 0 16px;
  max-width: 22ch;
}
@media (max-width: 767px) {
  .legal-hero h1 { font-size: 38px; line-height: 1.1; }
}
.legal-hero .last-updated {
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: 14px;
  line-height: 24px;
  color: var(--c-slate);
  margin: 0;
}
.legal-hero .last-updated .confirm-tag {
  font-family: "SFMono-Regular", ui-monospace, Menlo, monospace;
  font-size: 11px;
  letter-spacing: 0.04em;
  color: var(--c-sea-text);
  background: var(--c-pearl);
  padding: 2px 6px;
  border-radius: 3px;
  margin-left: 6px;
  font-style: normal;
}

/* ---------- Two-column content area ---------- */
.legal-content {
  background: var(--c-ivory);
  padding-top: 32px;
  padding-bottom: 128px;
}
@media (max-width: 767px) {
  .legal-content { padding-top: 24px; padding-bottom: 96px; }
}
.legal-content-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
}
.legal-grid {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 64px;
  align-items: start;
}
@media (max-width: 1023px) {
  .legal-grid { grid-template-columns: 1fr; gap: 0; }
}

/* ---------- TOC (desktop sticky) ---------- */
.legal-toc {
  position: sticky;
  top: 96px;
  max-height: calc(100vh - 120px);
  overflow-y: auto;
  padding-right: 16px;
}
@media (max-width: 1023px) {
  .legal-toc { display: none; }
}
.legal-toc-title {
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--c-slate);
  margin: 0 0 16px;
  line-height: 1.4;
}
.legal-toc ol {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: toc;
  border-left: 1px solid var(--c-stone);
}
.legal-toc li {
  margin: 0;
  padding: 0;
}
.legal-toc a {
  display: grid;
  grid-template-columns: 24px 1fr;
  gap: 4px;
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: 14px;
  line-height: 1.45;
  color: var(--c-ink);
  text-decoration: none;
  padding: 8px 12px 8px 16px;
  margin-left: -1px;
  border-left: 1px solid transparent;
  transition: background 200ms var(--ease-out), color 200ms var(--ease-out), border-left-color 200ms var(--ease-out);
}
.legal-toc a .num {
  font-variant-numeric: tabular-nums;
  color: var(--c-slate);
  font-weight: 600;
  font-size: 13px;
}
@media (hover: hover) and (pointer: fine) {
  .legal-toc a:hover {
    background: var(--c-mint);
    color: var(--c-deep);
    border-left-color: var(--c-sea);
  }
  .legal-toc a:hover .num { color: var(--c-deep); }
}
.legal-toc a:focus-visible {
  outline: 3px solid var(--c-deep);
  outline-offset: 2px;
  border-radius: 2px;
}

/* Mobile <details> jump-to-section */
.legal-mobile-toc {
  display: none;
  margin-bottom: 32px;
  border: 1px solid var(--c-stone);
  border-radius: 6px;
  background: var(--c-pearl);
  overflow: hidden;
}
@media (max-width: 1023px) {
  .legal-mobile-toc { display: block; }
}
.legal-mobile-toc summary {
  cursor: pointer;
  list-style: none;
  padding: 16px 20px;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 14px;
  letter-spacing: 0.04em;
  color: var(--c-deep);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.legal-mobile-toc summary::-webkit-details-marker { display: none; }
.legal-mobile-toc summary::after {
  content: "";
  width: 10px; height: 10px;
  border-right: 1.5px solid var(--c-deep);
  border-bottom: 1.5px solid var(--c-deep);
  transform: rotate(45deg);
  transition: transform 200ms var(--ease-out);
  margin-top: -4px;
}
.legal-mobile-toc[open] summary::after {
  transform: rotate(225deg);
  margin-top: 4px;
}
.legal-mobile-toc ol {
  list-style: none;
  margin: 0;
  padding: 8px 0 16px;
  border-top: 1px solid var(--c-stone);
}
.legal-mobile-toc a {
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 4px;
  font-family: var(--font-sans);
  font-size: 14px;
  line-height: 1.5;
  color: var(--c-ink);
  text-decoration: none;
  padding: 8px 20px;
}
.legal-mobile-toc a .num {
  color: var(--c-slate);
  font-weight: 600;
}
.legal-mobile-toc a:focus-visible {
  outline: 3px solid var(--c-deep);
  outline-offset: -3px;
}

/* ---------- Body ---------- */
.legal-body {
  max-width: 720px;
}
.legal-body > .intro p,
.legal-body > .legal-section p {
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: 16px;
  line-height: 28px;
  color: var(--c-ink);
  margin: 0 0 16px;
}
.legal-body > .intro {
  padding-bottom: 8px;
  margin-bottom: 8px;
}
.legal-body > .intro > p:last-child { margin-bottom: 0; }
.legal-body strong {
  font-weight: 600;
  color: var(--c-ink);
}
.legal-body a {
  color: var(--c-deep);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 180ms var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .legal-body a:hover { color: var(--c-sea); }
}
.legal-body a:focus-visible {
  outline: 3px solid var(--c-deep);
  outline-offset: 2px;
  border-radius: 2px;
}

/* Section divider */
.legal-body hr.legal-rule {
  border: none;
  border-top: 1px solid var(--c-stone);
  margin: 48px 0;
  height: 0;
}

/* Section heading */
.legal-body h2 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 32px;
  line-height: 1.2;
  color: var(--c-deep);
  margin: 16px 0 16px;
  scroll-margin-top: 200px;   /* clears the 188px sticky header */
  letter-spacing: -0.005em;
}
.legal-body .legal-section:first-child h2 {
  margin-top: 0;
}
@media (max-width: 767px) {
  .legal-body h2 { font-size: 24px; line-height: 1.25; }
}

/* Subsection heading */
.legal-body h3 {
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 18px;
  line-height: 22px;
  color: var(--c-deep);
  margin: 32px 0 12px;
  letter-spacing: 0;
}

/* Lists */
.legal-body ul {
  list-style: none;
  margin: 0 0 16px;
  padding: 0;
}
.legal-body ul li {
  position: relative;
  padding-left: 20px;
  margin: 0 0 8px;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 28px;
  color: var(--c-ink);
}
.legal-body ul li::before {
  content: "";
  position: absolute;
  left: 8px;
  top: 12px;
  width: 4px;
  height: 4px;
  border-radius: 999px;
  background: var(--c-sea);
}
.legal-body ul li:last-child { margin-bottom: 0; }

/* CONFIRM and DATE placeholder tags (inline) */
.legal-body .confirm-tag,
.legal-hero .confirm-tag {
  display: inline-block;
  font-family: "SFMono-Regular", ui-monospace, Menlo, monospace;
  font-size: 12px;
  letter-spacing: 0.02em;
  color: var(--c-sea-text);
  background: rgba(217, 233, 231, 0.45);
  border: 1px dashed rgba(45, 127, 131, 0.4);
  padding: 1px 6px;
  border-radius: 3px;
  font-style: normal;
  line-height: 1.5;
  vertical-align: baseline;
}

/* ---------- Bottom contact block ---------- */
.legal-contact {
  background: var(--c-ivory);
  padding-bottom: 96px;
}
@media (max-width: 767px) {
  .legal-contact { padding-bottom: 64px; }
}
.legal-contact-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
}
.legal-contact-card {
  margin: 0 auto;
  max-width: 720px;
  background: var(--c-mint);
  border-radius: 10px;
  padding: 48px 32px;
  text-align: center;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 28px;
  color: var(--c-ink);
}
.legal-contact-card p { margin: 0; }
.legal-contact-card .heading {
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 16px;
  margin: 0 0 8px;
  color: var(--c-ink);
}
.legal-contact-card a {
  color: var(--c-deep);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.legal-contact-card a:focus-visible {
  outline: 3px solid var(--c-deep);
  outline-offset: 3px;
  border-radius: 2px;
}
@media (max-width: 767px) {
  .legal-contact-card { padding: 40px 24px; }
}
