/* ============================================================
   Cordelle — help center

   Loaded AFTER /assets/styles.css on every /help/ page; it leans on the
   site's tokens (--bg, --text, --dim, --accent, --line, radii, shadows)
   and defines ONLY the contract's help classes:

     help-wrap, help-crumbs, help-article, help-lede,
     help-callout (+ help-callout-warn), help-steps, help-faq,
     help-table, help-kbd, help-foot, help-grid, help-card

   Everything else is element styling scoped inside those classes, plus
   one attribute selector giving the site nav an active state.

   TYPE DECISION — senior-first for everyone. Rather than a per-audience
   scoping class (which would grow the contract's fixed class list), the
   article base is set generously for ALL help pages: 18px body, 1.68
   line height, ~68ch measure. Traveler and guide pages therefore meet
   the senior-first sizing bar with the same markup operators get; no
   page has to opt in, and no page can forget to.

   Headings stay in Figtree: Fraunces is reserved for tenant surfaces
   (the phone mockups) per docs/BRAND.md, and help pages are Cordelle
   speaking in its own voice.
   ============================================================ */

/* ───────── nav: active item ─────────
   Article pages mark the Help link with aria-current="page". */
.nav-links a[aria-current="page"] {
  color: var(--text);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 2px;
  text-underline-offset: 7px;
}

/* ───────── page shell ───────── */
.help-wrap {
  width: min(100% - 40px, 864px);
  margin-inline: auto;
  padding: 46px 0 96px;
}

/* Shared heading voice for the hub (headings sit directly in .help-wrap)
   and for articles (headings sit inside .help-article). */
.help-wrap h1 {
  font-size: clamp(30px, 4.4vw, 42px);
  line-height: 1.1;
  letter-spacing: -0.026em;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 16px;
  text-wrap: balance;
}
.help-wrap h2 {
  font-size: clamp(21px, 2.4vw, 25px);
  line-height: 1.22;
  letter-spacing: -0.018em;
  font-weight: 700;
  color: var(--text);
  margin: 48px 0 14px;
  text-wrap: balance;
}

/* ───────── crumbs — quiet ───────── */
.help-crumbs {
  font-size: 14px;
  color: var(--dim);
  margin: 0 0 32px;
}
.help-crumbs a {
  color: var(--dim);
  text-decoration: none;
  transition: color .16s ease;
}
.help-crumbs a:hover { color: var(--accent); }

/* ───────── article ───────── */
.help-article {
  max-width: 68ch;
  font-size: 18px;
  line-height: 1.68;
  /* Reading ink: firmer than the marketing --dim, softer than headline text. */
  color: color-mix(in srgb, var(--text) 72%, var(--dim));
}
.help-article h3 {
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.012em;
  color: var(--text);
  margin: 30px 0 10px;
}
.help-article p { margin: 0 0 17px; }
.help-article ul,
.help-article ol { margin: 0 0 20px; padding-left: 26px; }
.help-article li { margin-bottom: 9px; }
.help-article li:last-child { margin-bottom: 0; }
.help-article a { color: var(--accent); text-underline-offset: 2px; }
.help-article strong,
.help-article b { color: var(--text); font-weight: 600; }
.help-article hr {
  border: 0;
  border-top: 1px solid var(--line-soft);
  margin: 36px 0;
}

.help-lede {
  font-size: clamp(17.5px, 1.6vw, 20px);
  line-height: 1.6;
  color: var(--dim);
  margin: 0 0 36px;
  max-width: 62ch;
}

/* ───────── callouts ───────── */
.help-callout {
  margin: 26px 0;
  padding: 15px 19px;
  background: var(--accent-wash);
  border: 1px solid color-mix(in srgb, var(--accent) 26%, transparent);
  border-left: 4px solid var(--accent);
  border-radius: var(--r-sm);
  font-size: 16.5px;
  line-height: 1.6;
}
.help-callout > :first-child { margin-top: 0; }
.help-callout > :last-child { margin-bottom: 0; }
/* Warm variant, derived from the site's danger tone (#C2453B — the form's
   error color), washed the same way --accent-wash washes the accent. */
.help-callout-warn {
  background: rgba(194, 69, 59, .06);
  border-color: rgba(194, 69, 59, .30);
  border-left-color: #C2453B;
}

/* ───────── numbered steps ───────── */
.help-steps {
  list-style: none;
  counter-reset: help-step;
  margin: 28px 0;
  padding: 0;
  display: grid;
  gap: 20px;
}
.help-steps > li {
  counter-increment: help-step;
  position: relative;
  padding-left: 48px;
  min-height: 32px;
  margin-bottom: 0;
}
.help-steps > li::before {
  content: counter(help-step);
  position: absolute;
  left: 0;
  top: 0;
  width: 31px;
  height: 31px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--on-accent);
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 15px;
  font-variant-numeric: tabular-nums;
}
.help-steps > li > p:last-child { margin-bottom: 0; }

/* ───────── FAQ list ───────── */
.help-faq { margin: 28px 0; }
.help-faq dt {
  font-weight: 600;
  color: var(--text);
  margin: 30px 0 0;
  padding-top: 26px;
  border-top: 1px solid var(--line-soft);
}
.help-faq dt:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}
.help-faq dd { margin: 9px 0 0; }

/* ───────── tables ─────────
   Written for a wrapper (<div class="help-table"><table>…), with a
   fallback so a bare <table class="help-table"> still scrolls. */
.help-table {
  margin: 26px 0;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--surface);
}
.help-table table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15.5px;
  line-height: 1.5;
}
table.help-table {
  display: block;
  border-collapse: separate;
  border-spacing: 0;
}
.help-table th {
  text-align: left;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--text);
  background: var(--bg);
  padding: 11px 16px;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
.help-table td {
  padding: 11px 16px;
  border-bottom: 1px solid var(--line-soft);
  vertical-align: top;
  color: color-mix(in srgb, var(--text) 72%, var(--dim));
}
.help-table tr:last-child td { border-bottom: 0; }

/* ───────── inline UI/key labels ───────── */
.help-kbd {
  display: inline-block;
  padding: 1px 8px 2px;
  border: 1px solid var(--line);
  border-bottom-width: 2px;
  border-radius: 7px;
  background: var(--surface);
  color: var(--text);
  font-size: .85em;
  font-weight: 600;
  white-space: nowrap;
}

/* ───────── page foot ───────── */
.help-related {
  font-size: 0.95rem;
  margin: 0 0 10px;
}
.help-related b { font-weight: 600; margin-right: 4px; }

.help-foot {
  margin-top: 60px;
  padding-top: 26px;
  border-top: 1px solid var(--line);
  color: var(--dim);
  font-size: 15.5px;
  line-height: 1.6;
}
.help-foot p { margin: 0 0 6px; }
.help-foot p:last-child { margin-bottom: 0; }
.help-foot a { color: var(--accent); text-underline-offset: 2px; }

/* ───────── hub: card grid ─────────
   Same feel as the site's .cap-grid; auto-fill so a short row keeps
   card-sized cards instead of stretching one across the page. */
.help-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  margin: 20px 0 44px;
}
.help-card {
  display: block;
  background: var(--raised);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: 20px 22px 22px;
  text-decoration: none;
  color: inherit;
  transition: border-color .18s ease, transform .18s ease, box-shadow .18s ease;
}
.help-card:hover {
  border-color: rgba(38, 69, 197, .38);
  transform: translateY(-2px);
  box-shadow: var(--shadow-1);
}
.help-card h3 {
  margin: 0 0 7px;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--text);
  transition: color .16s ease;
}
.help-card:hover h3 { color: var(--accent); }
.help-card p {
  margin: 0;
  color: var(--dim);
  font-size: 15px;
  line-height: 1.55;
}
@media (prefers-reduced-motion: reduce) {
  .help-card:hover { transform: none; }
}

/* ───────── small screens ───────── */
@media (max-width: 560px) {
  .help-wrap { padding-top: 32px; }
  .help-article { font-size: 17.5px; }
  .help-steps { gap: 18px; }
  .help-steps > li { padding-left: 44px; }
}

/* ───────── print ───────── */
@media print {
  .nav, .footer, .skip { display: none; }
  .help-wrap { width: auto; padding: 0; }
  .help-article { max-width: none; color: #000; }
  .help-crumbs { color: #555; }
  .help-callout {
    background: none;
    border-color: #999;
    border-left-color: #555;
  }
  .help-card, .help-table { box-shadow: none; }
  .help-article a, .help-foot a { color: inherit; }
}
