/* Editorial, legal, and 404 surfaces.
   About / FAQ / Contact / Privacy / Terms stay parchment.
   404 loads shared threshold.css for the dark gate, then this file for
   ordinary School chrome. Do not copy threshold body/focus/font here. */

.page {
  max-width: var(--shell-editorial);
  margin: 0 auto;
  min-height: 100vh;
  background: var(--paper);
  padding: 0 22px 70px;
}

header,
.top {
  height: 68px;
  display: flex;
  align-items: center;
  border-bottom: var(--rule);
}

.logo,
.brand {
  font-family: var(--serif);
  letter-spacing: 2px;
  font-size: 16px;
  text-decoration: none;
  color: inherit;
}

.nav {
  margin-left: auto;
  display: flex;
  gap: var(--space-4);
  align-items: center;
  font-family: var(--sans);
  font-size: 13px;
}

.hero {
  padding: 56px 0 34px;
  border-bottom: var(--rule);
}

.eyebrow,
.page-label {
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 1.3px;
  text-transform: uppercase;
  color: var(--bronze);
  margin-bottom: 14px;
}

.hero h1,
.legal h1,
.error-stage h1 {
  font-family: var(--serif);
  font-size: 42px;
  font-weight: 400;
  line-height: 1.12;
  margin: 0 0 14px;
  color: var(--ink);
}

.lead,
.hero p {
  font-family: var(--serif);
  font-size: 18px;
  line-height: 1.7;
  color: var(--ink-secondary);
  max-width: var(--measure-reading);
  margin: 0;
}

.section,
.qa {
  padding: 34px 0;
  border-bottom: var(--rule);
}

.section h2,
.qa h2,
.channel h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 22px;
  margin: 0 0 14px;
  color: var(--ink);
}

.qa h2 {
  font-size: 20px;
  margin-bottom: 10px;
}

.section p,
.qa p,
.channel p,
.note p {
  font-family: var(--serif);
  line-height: 1.8;
  color: var(--ink-secondary);
  margin: 0 0 14px;
  font-size: 15px;
  max-width: var(--measure-reading);
}

.qa p {
  font-size: 15px;
  line-height: 1.75;
  margin-bottom: 10px;
}

.section a,
.qa a,
.channel a,
.foot a,
.legal a {
  color: var(--bronze);
  text-underline-offset: 3px;
}

.note {
  background: var(--paper-note);
  border: 0;
  border-left: 3px solid var(--bronze);
  border-radius: var(--radius-square);
  padding: 16px 18px;
  font-family: var(--serif);
  font-size: 14px;
  line-height: 1.7;
  color: var(--ink-secondary);
}

.contact-note {
  border-top: var(--rule);
  border-left: 0;
  background: transparent;
  padding: 26px 0 0;
  font-size: 13px;
  line-height: 1.75;
  color: var(--muted);
}

.foot,
footer {
  padding-top: 28px;
  font-family: var(--sans);
  font-size: 13px;
  color: var(--muted);
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* Contact directory — manuscript sections, not SaaS cards */

.directory {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-6) var(--space-5);
  padding: 30px 0;
}

.channel {
  background: transparent;
  border: 0;
  border-top: var(--rule);
  border-radius: var(--radius-square);
  padding: 22px 0 0;
}

.primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--target-essential);
  background: var(--ink);
  color: var(--paper) !important;
  text-decoration: none;
  padding: 12px 16px;
  border-radius: var(--radius-control);
  font-family: var(--sans);
  font-size: 13px;
}

.primary:hover {
  background: var(--charcoal);
}

/* Legal reading */

.legal {
  padding: 56px 0 0;
}

.legal .page-label {
  display: block;
  margin-bottom: 8px;
}

.legal .last-updated {
  display: block;
  font-family: var(--sans);
  font-size: 13px;
  color: var(--muted);
  margin: 0 0 40px;
}

.legal h2 {
  font-family: var(--sans);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.15em;
  color: var(--bronze);
  text-transform: uppercase;
  margin: 2.4rem 0 0.75rem;
}

.legal p,
.legal li {
  font-family: var(--serif);
  font-size: 16px;
  line-height: 1.8;
  color: var(--ink-secondary);
}

.legal p {
  margin: 0 0 1rem;
  max-width: var(--measure-reading);
}

.legal ul {
  margin: 0.5rem 0 1rem 1.4rem;
  max-width: var(--measure-reading);
}

.legal li {
  margin-bottom: 0.45rem;
}

.legal .note {
  margin: 1.4rem 0;
}

/* 404 — shared threshold gate + School chrome.
   Body canvas, Georgia, and gold focus come from threshold.css.
   .page is parchment in this file, so the 404 shell must override it.
   .error-stage avoids the threshold form-message .error box. */

html.threshold.error-page body {
  display: block;
}

html.error-page .page {
  max-width: none;
  min-height: 100dvh;
  background: var(--threshold-bg);
  color: var(--threshold-text);
  display: flex;
  flex-direction: column;
  padding: 0 22px 48px;
}

html.error-page header {
  max-width: var(--shell-editorial);
  width: 100%;
  margin: 0 auto;
  border-bottom-color: var(--threshold-line);
}

html.error-page .logo {
  color: var(--threshold-heading);
}

html.error-page .nav a {
  color: var(--threshold-muted);
  text-decoration: none;
}

html.error-page .nav a:hover {
  color: var(--threshold-heading);
  text-decoration: underline;
  text-decoration-color: rgba(184, 168, 120, 0.45);
  text-underline-offset: 3px;
}

html.error-page .nav a:focus-visible {
  outline: 3px solid var(--threshold-focus);
  outline-offset: 3px;
  box-shadow: none;
}

html.error-page ::selection {
  background: var(--threshold-heading);
  color: var(--threshold-bg);
}

.error-stage {
  flex: 1;
  width: 100%;
  max-width: var(--shell-onboarding);
  margin: 0 auto;
  padding: 72px 0 40px;
}

.error-stage .eyebrow {
  color: var(--threshold-heading);
}

html.error-page .error-stage h1 {
  color: var(--threshold-heading);
  margin: 0 0 14px;
}

.error-stage .copy {
  font-family: var(--serif);
  font-size: 18px;
  line-height: 1.7;
  color: var(--threshold-muted);
  max-width: var(--measure-reading);
  margin: 0 0 28px;
}

.error-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.error-actions a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--target-essential);
  padding: 12px 16px;
  font-family: var(--sans);
  font-size: 13px;
  text-decoration: none;
  border-radius: var(--radius-threshold-control);
}

.error-actions .primary {
  background: var(--threshold-heading);
  color: var(--threshold-bg) !important;
  border: 1px solid var(--threshold-heading);
}

.error-actions .primary:hover {
  background: var(--threshold-heading-hover);
}

.error-actions .secondary {
  background: transparent;
  color: var(--threshold-text);
  border: 1px solid var(--threshold-line);
}

.error-actions .secondary:hover {
  border-color: var(--threshold-heading);
  color: var(--threshold-heading);
}

@media (max-width: 620px) {
  header,
  .top {
    height: auto;
    min-height: 62px;
    padding: 14px 0;
    flex-wrap: wrap;
    row-gap: 10px;
  }

  .nav {
    gap: 10px;
    flex-wrap: wrap;
  }

  .nav a.nav-secondary {
    display: none;
  }

  .hero {
    padding-top: 38px;
  }

  .hero h1,
  .legal h1,
  .error-stage h1 {
    font-size: 34px;
  }

  .directory {
    grid-template-columns: 1fr;
    padding-top: 6px;
  }

  /* Single column: the first channel's top rule doubled with the hero's
     bottom rule, leaving a stranded gap. Drop the doubled hairline. */
  .directory .channel:first-child {
    border-top: 0;
    padding-top: 10px;
  }

  .legal {
    padding-top: 38px;
  }

  .error-stage {
    padding-top: 48px;
  }
}
