/* Developer reference pages (connect, client compatibility, API reference,
 * Windows quickstart, operating envelope, claims, retirement notices,
 * confirmation pages) in the site's one world. The body carries `h-site`, so
 * the collar, footer, type faces and tokens come from assets/remodel.css;
 * this file shapes the document components those pages use on the same
 * tokens. Scoped under `.h-site` throughout. */

.h-site .skip-link { position: absolute; left: -9999px; top: 10px; z-index: 200; padding: 10px 14px; background: var(--h-accent); color: var(--honua-on-accent); font: 500 12px/1 var(--h-mono); letter-spacing: .1em; text-transform: uppercase; }
.h-site .skip-link:focus { left: 10px; }
.h-site .sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

/* ---- document hero: back link, title, lede -------------------------------- */
.h-site .hub-doc-hero { padding-block: 48px 36px; border-bottom: 1px solid var(--h-line); }
.h-site .hub-doc-hero .h-back { margin-bottom: 26px; }
.h-site .hub-doc-hero h1 { max-width: 22ch; margin: 0 0 20px; font-size: var(--h-h1-doc); letter-spacing: -.035em; line-height: 1; }
.h-site .hub-doc-hero .h-lede { max-width: 62ch; margin: 0; }
.h-site .hub-doc-hero .h-lede + p { max-width: 70ch; margin-top: 16px; color: var(--h-muted); }
.h-site .hub-doc-hero .h-actions { margin-top: 26px; }

/* ---- document body -------------------------------------------------------- */
.h-site .hub-doc { max-width: 880px; padding-block: 40px 96px; }
.h-site .hub-doc.hub-doc-wide { max-width: 1040px; }
.h-site .hub-doc h2 { margin: 52px 0 16px; font-size: var(--h-h2-doc); letter-spacing: -.03em; line-height: 1.1; }
.h-site .hub-doc > h2:first-child, .h-site .hub-doc > section:first-child > h2:first-child { margin-top: 0; }
.h-site .hub-doc h3 { margin: 34px 0 10px; font-size: var(--h-h3-compact); letter-spacing: -.02em; line-height: 1.15; }
.h-site .hub-doc h4 { margin: 24px 0 8px; font-size: 16px; font-weight: 500; letter-spacing: -.01em; line-height: 1.3; }
.h-site .hub-doc p, .h-site .hub-doc li { max-width: 70ch; font-size: 16px; line-height: 1.7; color: var(--h-ink); }
.h-site .hub-doc p { margin: 0 0 16px; }
.h-site .hub-doc p + p { margin-top: 0; }
.h-site .hub-doc ul, .h-site .hub-doc ol { margin: 0 0 20px; padding-left: 22px; }
.h-site .hub-doc li + li { margin-top: 8px; }
.h-site .hub-doc li p { margin: 0; }
.h-site .hub-doc em { font-style: normal; color: var(--h-muted); }
.h-site .hub-doc strong { font-weight: 500; }
.h-site .hub-doc code { font: 500 13px var(--h-mono); padding: 2px 5px; background: var(--h-surface); color: var(--h-accent); overflow-wrap: anywhere; }
.h-site .hub-doc pre { max-width: 100%; margin: 0 0 20px; padding: 16px 18px; border: 1px solid var(--h-rule); background: var(--h-bg); overflow: auto; color: var(--h-ink); font: 400 12.5px/1.7 var(--h-mono); tab-size: 2; }
.h-site .hub-doc pre code { font: inherit; padding: 0; background: none; color: inherit; }
.h-site .hub-doc pre:focus-visible { outline: 2px solid var(--h-focus); outline-offset: -3px; }
.h-site .hub-doc hr { border: 0; border-top: 1px solid var(--h-line); margin: 40px 0; }

/* Notes and provenance lines: ruled, surfaced, never a coloured bar. */
.h-site .hub-doc .doc-note { max-width: 72ch; margin: 0 0 20px; padding: 14px 18px; border: 1px solid var(--h-line); background: var(--h-surface); color: var(--h-muted); font-size: 14px; line-height: 1.6; }
.h-site .hub-doc .doc-note strong { color: var(--h-ink); }
.h-site .hub-doc .prov, .h-site .hub-doc .kb-id { font: 500 12px/1.6 var(--h-mono); color: var(--h-muted); }
.h-site .hub-doc .prov { margin: -6px 0 24px; }
.h-site .hub-doc .h-callout { max-width: 72ch; }
.h-site .hub-doc .h-callout p { margin: 0; color: var(--h-ink); font-size: 15px; }
.h-site .hub-doc .h-callout p + p { margin-top: 10px; }
.h-site .hub-doc .evidence-badge { display: inline-block; padding: 1px 6px; border: 1px solid var(--h-rule); color: var(--h-amber); font: 500 11px/1.6 var(--h-mono); letter-spacing: .08em; text-transform: uppercase; white-space: nowrap; }

/* Tables: the world's capability table, in a scrolling frame. */
.h-site .hub-doc .h-table-wrap { margin: 14px 0 26px; max-height: none; }
.h-site .hub-doc .h-table-wrap table { width: 100%; min-width: 640px; border-collapse: collapse; text-align: left; font-size: 13.5px; line-height: 1.55; }
.h-site .hub-doc .h-table-wrap th { padding: 12px 16px; border-bottom: 1px solid var(--h-line); background: var(--h-surface); color: var(--h-muted); font: 500 11px/1.6 var(--h-mono); letter-spacing: .1em; text-transform: uppercase; white-space: nowrap; position: sticky; top: 0; z-index: 1; }
.h-site .hub-doc .h-table-wrap td { padding: 12px 16px; border-bottom: 1px solid var(--h-line); vertical-align: top; }
.h-site .hub-doc .h-table-wrap tr:last-child td { border-bottom: 0; }
.h-site .hub-doc .h-table-wrap td code { white-space: nowrap; }
.h-site .hub-doc .h-table-wrap td.area { width: 24%; color: var(--h-ink); font-weight: 500; }
.h-site .hub-doc .h-table-wrap .endpoint-table td:first-child { white-space: nowrap; }
.h-site .hub-doc .h-table-wrap .endpoint-table td code { white-space: normal; overflow-wrap: anywhere; }

/* A committed render: the figure stays inside the measure. */
.h-site .hub-doc .live-render { margin: 26px 0; }
.h-site .hub-doc .live-render img { display: block; width: 100%; max-width: 800px; height: auto; border: 1px solid var(--h-rule); background: var(--h-surface); }
.h-site .hub-doc .live-render figcaption { max-width: 800px; margin-top: 10px; color: var(--h-muted); font-size: 13px; line-height: 1.55; }

/* ---- API reference -------------------------------------------------------- */
.h-site .hub-doc .method { display: inline-block; min-width: 52px; padding: 2px 8px; border: 1px solid var(--h-rule); text-align: center; font: 500 11px/1.6 var(--h-mono); letter-spacing: .08em; }
.h-site .hub-doc .method.get { color: var(--h-accent); border-color: var(--h-teal); }
.h-site .hub-doc .method.post { color: var(--h-blue); border-color: var(--honua-blue); }
.h-site .hub-doc .method.put, .h-site .hub-doc .method.patch { color: var(--h-amber); border-color: var(--honua-amber); }
.h-site .hub-doc .method.delete { color: var(--honua-danger); border-color: var(--honua-danger); }
.h-site .hub-doc .api-spec { margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--h-line); }
.h-site .hub-doc .api-op { margin: 22px 0 26px; }
.h-site .hub-doc .api-op h4 { display: flex; flex-wrap: wrap; align-items: baseline; gap: 10px; margin: 0 0 6px; font-size: 15px; }
.h-site .hub-doc .api-op h4 code { font-size: 13px; }
.h-site .hub-doc .op-summary { margin: 0 0 8px; font-size: 14px; color: var(--h-muted); }
.h-site .hub-doc .op-tags { margin-left: 8px; font: 500 11px var(--h-mono); letter-spacing: .08em; text-transform: uppercase; color: var(--h-muted); }
.h-site .hub-doc .op-line, .h-site .hub-doc .op-none { margin: 0 0 8px; font-size: 13.5px; color: var(--h-muted); }
.h-site .hub-doc .api-toc { display: flex; flex-wrap: wrap; gap: 8px 16px; margin: 14px 0 22px; padding: 0; list-style: none; }
.h-site .hub-doc .api-toc li { margin: 0; }
.h-site .hub-doc .api-toc a { font: 500 12px var(--h-mono); }
.h-site .hub-doc .api-group { margin: 12px 0; border: 1px solid var(--h-line); background: var(--h-surface); }
.h-site .hub-doc .api-group > summary { display: flex; flex-wrap: wrap; align-items: baseline; gap: 12px; min-height: 44px; padding: 10px 16px; cursor: pointer; list-style: none; }
.h-site .hub-doc .api-group > summary::-webkit-details-marker { display: none; }
.h-site .hub-doc .api-group > summary::before { content: "+"; flex: 0 0 auto; color: var(--h-accent); font: 500 16px/1 var(--h-mono); }
.h-site .hub-doc .api-group[open] > summary::before { content: "\2212"; }
.h-site .hub-doc .api-group > summary h4 { display: inline; margin: 0; font-size: 15px; }
.h-site .hub-doc .api-group[open] > summary { border-bottom: 1px solid var(--h-line); }
.h-site .hub-doc .api-group .h-table-wrap { margin: 0; border: 0; }
.h-site .hub-doc .group-meta { font: 500 11px var(--h-mono); letter-spacing: .08em; text-transform: uppercase; color: var(--h-muted); }

/* ---- claims: the scoreboard as a datasheet -------------------------------- */
.h-site .claims-sheet { max-width: none; margin-top: 30px; }
.h-site .claims-sheet dl { display: grid; grid-template-columns: 240px 1fr; margin: 0; }
.h-site .claims-sheet dd { text-transform: none; letter-spacing: .02em; }
.h-site .claims-sheet dd b { color: var(--h-accent); font-weight: 500; }
.h-site .claims-sheet dd span { color: var(--h-muted); }
.h-site .claims-links { max-width: none; margin-top: 24px; }
.h-site .claims-links dl { display: grid; grid-template-columns: 220px 1fr; margin: 0; }
.h-site .claims-links dd { text-transform: none; letter-spacing: .02em; }
.h-site .claims-links dd a { text-decoration: underline; text-decoration-color: var(--h-rule); text-underline-offset: 4px; }
.h-site .hub-doc .claims-table .legacy { max-width: 60ch; }

/* ---- confirmation pages (404, thanks) ------------------------------------- */
.h-site .confirmation-page { min-height: 52vh; display: flex; flex-direction: column; justify-content: center; padding-block: 72px; }
.h-site .confirmation-page h1 { max-width: 18ch; margin: 0 0 18px; font-size: var(--h-h1-doc); letter-spacing: -.035em; line-height: 1; }
.h-site .confirmation-page .h-lede { max-width: 56ch; }
.h-site .confirmation-page .h-actions { margin-top: 28px; }

@media (max-width: 760px) {
  .h-site .hub-doc { padding-block: 30px 72px; }
  .h-site .hub-doc h2 { margin-top: 40px; }
  .h-site .hub-doc-hero { padding-block: 36px 28px; }
  .h-site .claims-sheet dl, .h-site .claims-links dl { grid-template-columns: 120px 1fr; }
  .h-site .confirmation-page { padding-block: 48px; min-height: 0; }
}
@media (max-width: 600px) {
  .h-site .hub-doc .h-actions .h-button { width: 100%; justify-content: space-between; white-space: normal; }
}

/* The generated SDK matrix keeps the generator's own hooks; they read the same as the world table and note. */
.h-site .hub-doc .table-wrap { width: 100%; overflow: auto; border: 1px solid var(--h-line); margin: 14px 0 26px; }
.h-site .hub-doc .table-wrap table { width: 100%; min-width: 640px; border-collapse: collapse; text-align: left; font-size: 13.5px; line-height: 1.55; }
.h-site .hub-doc .table-wrap th { padding: 12px 16px; border-bottom: 1px solid var(--h-line); background: var(--h-surface); color: var(--h-muted); font: 500 11px/1.6 var(--h-mono); letter-spacing: .1em; text-transform: uppercase; white-space: nowrap; }
.h-site .hub-doc .table-wrap td { padding: 12px 16px; border-bottom: 1px solid var(--h-line); vertical-align: top; }
.h-site .hub-doc .table-wrap tr:last-child td { border-bottom: 0; }
.h-site .hub-doc p.note { max-width: 72ch; margin: 0 0 20px; padding: 14px 18px; border: 1px solid var(--h-line); background: var(--h-surface); color: var(--h-muted); font-size: 14px; line-height: 1.6; }
.h-site .hub-doc p.note strong { color: var(--h-ink); }

/* phones: long URLs and code in reference documents break anywhere rather than widening the page */
@media(max-width:600px){.h-site .hub-doc a,.h-site .hub-doc code,.h-site .hub-doc-hero a{overflow-wrap:anywhere}}
