/*
 * Guide Hatch: components
 * Needs tokens.css first. Every class starts with "gh-" so it can sit next to any other CSS.
 *
 * The page is built as one framed column (.gh-frame) on a hatched background. Inside it,
 * blocks of text are wrapped in .gh-rule, which draws hairlines above and below that run
 * past the frame to the edges of the screen.
 */

/* Base: the hatched page and the framed column.
   html clips too, so the body keeps its own clip and the bleeding guide rules never make the page scroll sideways. */
html:has(> body.gh) { overflow-x: clip; }
.gh { margin: 0; min-height: 100vh; background: var(--gh-night) var(--gh-hatch-bg); color: var(--gh-text); font-family: var(--gh-sans); font-size: var(--gh-text-body); line-height: 1.6; -webkit-font-smoothing: antialiased; overflow-x: clip; }
.gh *, .gh *::before, .gh *::after { box-sizing: border-box; }
.gh a:not([class]) { color: inherit; }
.gh-frame { position: relative; width: min(100% - var(--gh-gutter) * 2, var(--gh-frame)); margin-inline: auto; background: var(--gh-night); border-inline: 1px solid var(--gh-line-strong); }
.gh-pad { padding-inline: var(--gh-pad); }
.gh-narrow { max-width: var(--gh-narrow); }
.gh-center { text-align: center; }
.gh-center .gh-lead, .gh-center.gh-narrow { margin-inline: auto; }
.gh-center .gh-actions { justify-content: center; }

/* Guide rules: hairlines above and below, running past the frame to the screen edges */
.gh-rule { position: relative; }
.gh-rule::before, .gh-rule::after { content: ""; position: absolute; left: -100vw; right: -100vw; height: 1px; background: var(--gh-line); pointer-events: none; }
.gh-rule::before { top: 0; }
.gh-rule::after { bottom: 0; }
.gh-rule--top::after { display: none; }
.gh-space { height: var(--gh-section); }
.gh-space--sm { height: calc(var(--gh-section) / 2); }
.gh-hatched { background: var(--gh-hatch-bg); }

/* Annotations: the tiny mono labels above each block, like dimensions on a drawing */
.gh-note { display: block; padding-block: 6px 4px; color: var(--gh-faint); font-family: var(--gh-mono); font-size: var(--gh-text-note); letter-spacing: .02em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gh-note b { color: var(--gh-sawdust); font-weight: 500; }
.gh-eyebrow { display: block; padding-block: 6px 4px; color: var(--gh-chalk); font-family: var(--gh-mono); font-size: var(--gh-text-note); font-weight: 500; letter-spacing: .14em; text-transform: uppercase; }
.gh-measure { color: var(--gh-sawdust); font-family: var(--gh-mono); font-size: .9em; }
.gh-code { color: var(--gh-chalk); font-family: var(--gh-mono); font-size: .9em; }

/* Type: one sans, tracked tight, never bold beyond 600 */
.gh-hero-title, .gh-h2, .gh-h3 { margin: 0; color: var(--gh-paper); font-family: var(--gh-sans); font-weight: 500; }
.gh-hero-title { font-size: var(--gh-text-hero); letter-spacing: var(--gh-tracking-hero); line-height: .98; padding-block: 4px 10px; text-wrap: balance; }
.gh-h2 { font-size: var(--gh-text-h2); letter-spacing: var(--gh-tracking-h2); line-height: 1.04; padding-block: 2px 8px; text-wrap: balance; }
.gh-h3 { font-size: var(--gh-text-h3); letter-spacing: -.02em; line-height: 1.25; }
.gh-lead { max-width: 640px; margin: 0; padding-block: 6px 10px; color: var(--gh-text); font-size: var(--gh-text-lead); line-height: 1.55; }
.gh-lead strong { color: var(--gh-paper); font-weight: 500; }
.gh-soft { color: var(--gh-soft); }

/* Nav: a ruled strip, logo left, links and a small action right */
.gh-nav { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding-block: 14px; }
.gh-logo { display: inline-flex; align-items: center; gap: 10px; color: var(--gh-paper); font-size: 18px; font-weight: 600; letter-spacing: -.03em; text-decoration: none; }
.gh-logo svg { flex: none; }
.gh-version { padding: 2px 8px; border-radius: var(--gh-radius-pill); background: var(--gh-panel-2); color: var(--gh-soft); font-family: var(--gh-mono); font-size: 11px; }
.gh-nav__links { display: flex; align-items: center; gap: 24px; font-size: var(--gh-text-small); }
.gh-nav__links a:not(.gh-btn) { color: var(--gh-text); text-decoration: none; }
.gh-nav__links a:not(.gh-btn):hover { color: var(--gh-paper); }
.gh-nav__links a.gh-nav__tag { padding: 2px 8px; border: 1px dashed var(--gh-chalk); color: var(--gh-chalk); }

/* Buttons: small pills. Chalk for the one action, a lifted panel for everything else */
.gh-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 9px 18px; border: 0; border-radius: var(--gh-radius-pill); font-family: var(--gh-sans); font-size: var(--gh-text-small); font-weight: 600; line-height: 1.2; text-decoration: none; white-space: nowrap; cursor: pointer; transition: background .2s var(--gh-ease), color .2s var(--gh-ease); }
.gh-btn--primary { background: var(--gh-chalk); color: var(--gh-night); }
.gh-btn--primary:hover { background: var(--gh-chalk-dark); }
.gh-btn--ghost { background: var(--gh-panel-2); color: var(--gh-paper); box-shadow: inset 0 0 0 1px var(--gh-line-strong); }
.gh-btn--ghost:hover { background: var(--gh-line-strong); }
.gh-btn--block { display: flex; width: 100%; }
.gh-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding-block: 14px; }
.gh-kbd { padding: 1px 6px; border-radius: 4px; background: var(--gh-panel-2); color: var(--gh-soft); font-family: var(--gh-mono); font-size: 11px; }
.gh-search { display: inline-flex; align-items: center; gap: 10px; min-width: 240px; padding: 8px 14px; border-radius: var(--gh-radius-pill); box-shadow: inset 0 0 0 1px var(--gh-line-strong); color: var(--gh-faint); font-size: var(--gh-text-small); }
.gh-search .gh-kbd { margin-left: auto; }

/* Windows: a flat panel with three dots, for product UI */
.gh-window { border-radius: var(--gh-radius); background: var(--gh-panel); box-shadow: var(--gh-shadow); overflow: hidden; }
.gh-window__bar { display: flex; align-items: center; gap: 7px; padding: 12px 14px; border-bottom: var(--gh-border); }
.gh-window__bar i { width: 9px; height: 9px; border-radius: 50%; background: var(--gh-line-strong); }
.gh-window__bar span { margin-left: 10px; color: var(--gh-faint); font-family: var(--gh-mono); font-size: var(--gh-text-note); }
.gh-window__body { padding: 18px; }

/* Cut sheet: the signature product visual. A board with labelled pieces and hatched waste */
.gh-sheet { position: relative; display: grid; gap: 3px; padding: 3px; border-radius: var(--gh-radius-sm); background: var(--gh-line-strong); aspect-ratio: 2 / 1; }
.gh-piece { position: relative; display: flex; flex-direction: column; justify-content: flex-end; gap: 2px; padding: 8px 10px; background: var(--gh-panel-2); color: var(--gh-paper); font-size: 12px; font-weight: 500; overflow: hidden; }
.gh-piece small { color: var(--gh-sawdust); font-family: var(--gh-mono); font-size: 10px; font-weight: 400; }
.gh-piece--hot { background: var(--gh-chalk-soft); box-shadow: inset 0 0 0 1px var(--gh-chalk); }
.gh-piece--waste { background: var(--gh-panel) var(--gh-hatch-bg); color: var(--gh-faint); }
.gh-piece--waste small { color: var(--gh-faint); }
.gh-dim { display: flex; align-items: center; gap: 8px; margin-top: 10px; color: var(--gh-sawdust); font-family: var(--gh-mono); font-size: var(--gh-text-note); }
.gh-dim::before, .gh-dim::after { content: ""; flex: 1; height: 1px; background: var(--gh-sawdust); opacity: .5; }

/* Ruled cells: a grid whose gaps are the guide lines (features, logos, stats) */
.gh-cells { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1px; background: var(--gh-line); }
.gh-cell { display: flex; flex-direction: column; gap: 10px; padding: clamp(20px, 2.6vw, 32px); background: var(--gh-night); }
.gh-cell p { margin: 0; color: var(--gh-soft); font-size: 15px; }
.gh-cell--logo { align-items: center; justify-content: center; min-height: 120px; color: var(--gh-soft); font-size: 22px; font-weight: 600; letter-spacing: -.03em; }
.gh-icon { display: grid; place-items: center; width: 36px; height: 36px; border-radius: var(--gh-radius-sm); background: var(--gh-panel-2); box-shadow: inset 0 0 0 1px var(--gh-line-strong); color: var(--gh-chalk); }
.gh-stat { color: var(--gh-paper); font-size: clamp(36px, 4vw, 52px); font-weight: 500; letter-spacing: -.05em; line-height: 1; }

/* Badges and chips */
.gh-badge { align-self: flex-start; display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: var(--gh-radius-pill); background: var(--gh-chalk-soft); color: var(--gh-chalk); font-family: var(--gh-mono); font-size: 11px; font-weight: 500; white-space: nowrap; }
.gh-badge--amber { background: var(--gh-sawdust-soft); color: var(--gh-sawdust); }
.gh-badge--line { background: transparent; box-shadow: inset 0 0 0 1px var(--gh-line-strong); color: var(--gh-soft); }
.gh-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--gh-green); }

/* Quote */
.gh-quote { margin: 0; color: var(--gh-paper); font-size: clamp(22px, 2.6vw, 32px); font-weight: 400; letter-spacing: -.03em; line-height: 1.3; }
.gh-cite { display: block; margin-top: 16px; color: var(--gh-soft); font-family: var(--gh-mono); font-size: 12px; font-style: normal; }

/* Forms: hairline fields, mono labels */
.gh-field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.gh-label { color: var(--gh-soft); font-family: var(--gh-mono); font-size: 12px; }
.gh-input, .gh-select { width: 100%; padding: 11px 14px; border: 1px solid var(--gh-line-strong); border-radius: var(--gh-radius-sm); background: var(--gh-panel); color: var(--gh-paper); font-family: var(--gh-sans); font-size: 15px; outline: none; transition: border-color .2s var(--gh-ease), box-shadow .2s var(--gh-ease); }
.gh-input::placeholder { color: var(--gh-faint); }
.gh-input:focus, .gh-select:focus { border-color: var(--gh-chalk); box-shadow: 0 0 0 3px var(--gh-chalk-soft); }
.gh-hint { color: var(--gh-faint); font-size: 13px; }
.gh-check { display: flex; align-items: flex-start; gap: 10px; color: var(--gh-soft); font-size: 14px; }
.gh-check input { margin-top: 3px; accent-color: var(--gh-chalk); }
.gh-choice { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; border-radius: var(--gh-radius-sm); background: var(--gh-line-strong); overflow: hidden; }
.gh-choice label { display: block; padding: 10px 8px; background: var(--gh-panel); color: var(--gh-soft); font-size: 13px; text-align: center; cursor: pointer; }
.gh-choice input { position: absolute; opacity: 0; pointer-events: none; }
.gh-choice input:checked + label { background: var(--gh-chalk-soft); color: var(--gh-chalk); }

/* Pricing: ruled columns, the featured one gets a chalk frame */
.gh-toggle { display: inline-flex; padding: 3px; border-radius: var(--gh-radius-pill); box-shadow: inset 0 0 0 1px var(--gh-line-strong); }
.gh-toggle button { padding: 7px 16px; border: 0; border-radius: var(--gh-radius-pill); background: transparent; color: var(--gh-soft); font: 500 13px var(--gh-sans); cursor: pointer; white-space: nowrap; }
.gh-toggle button[aria-pressed="true"] { background: var(--gh-panel-2); color: var(--gh-paper); }
.gh-plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1px; background: var(--gh-line); }
.gh-plan { display: flex; flex-direction: column; gap: 18px; padding: clamp(24px, 3vw, 36px); background: var(--gh-night); }
.gh-plan .gh-btn { margin-top: auto; }
.gh-plan--featured { position: relative; background: var(--gh-panel); box-shadow: inset 0 0 0 1px var(--gh-chalk); }
.gh-plan__name { display: flex; align-items: center; justify-content: space-between; gap: 10px; color: var(--gh-paper); font-size: 18px; font-weight: 500; }
.gh-price { color: var(--gh-paper); font-size: 52px; font-weight: 500; letter-spacing: -.05em; line-height: 1; }
.gh-price small { color: var(--gh-soft); font-size: 15px; letter-spacing: 0; font-weight: 400; }
.gh-list { display: flex; flex-direction: column; gap: 10px; margin: 0; padding: 0; list-style: none; font-size: 15px; }
.gh-list li { display: flex; gap: 10px; }
.gh-list li::before { content: "+"; flex: none; width: 14px; color: var(--gh-chalk); font-family: var(--gh-mono); }
.gh-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.gh-table th, .gh-table td { padding: 14px 12px; border-bottom: var(--gh-border); text-align: left; }
.gh-table th { color: var(--gh-faint); font-family: var(--gh-mono); font-size: 11px; font-weight: 400; text-transform: uppercase; letter-spacing: .1em; }
.gh-table td:first-child { color: var(--gh-paper); }
.gh-table-wrap { overflow-x: auto; }
.gh-faq { border-top: var(--gh-border); }
.gh-faq details { border-bottom: var(--gh-border); padding-block: 18px; }
.gh-faq summary { display: flex; justify-content: space-between; gap: 16px; color: var(--gh-paper); font-weight: 500; cursor: pointer; list-style: none; }
.gh-faq summary::after { content: "+"; color: var(--gh-chalk); font-family: var(--gh-mono); }
.gh-faq details[open] summary::after { content: "-"; }
.gh-faq p { margin: 10px 0 0; color: var(--gh-soft); }

/* Article: a narrow column, ruled headings, annotations in the margin */
.gh-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; color: var(--gh-soft); font-size: 14px; }
.gh-avatar { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--gh-panel-2); color: var(--gh-chalk); font-family: var(--gh-mono); font-size: 12px; box-shadow: inset 0 0 0 1px var(--gh-line-strong); }
.gh-prose { color: var(--gh-text); font-size: 17px; line-height: 1.75; }
.gh-prose p { margin: 0 0 22px; }
.gh-prose h2 { margin: 44px 0 14px; color: var(--gh-paper); font-size: 28px; font-weight: 500; letter-spacing: -.03em; line-height: 1.2; }
.gh-prose ul { margin: 0 0 22px; padding-left: 20px; }
.gh-prose li { margin-bottom: 8px; }
.gh-prose li::marker { color: var(--gh-chalk); }
.gh-prose code { padding: 1px 6px; border-radius: 4px; background: var(--gh-panel-2); color: var(--gh-chalk); font-family: var(--gh-mono); font-size: .86em; }
.gh-prose blockquote { margin: 28px 0; padding: 4px 0 4px 20px; border-left: 2px solid var(--gh-sawdust); color: var(--gh-paper); font-size: 20px; letter-spacing: -.02em; }
.gh-callout { margin: 28px 0; padding: 18px 20px; border-radius: var(--gh-radius-sm); background: var(--gh-panel); box-shadow: inset 0 0 0 1px var(--gh-line-strong); font-size: 15px; }
.gh-callout strong { color: var(--gh-sawdust); font-family: var(--gh-mono); font-size: 12px; font-weight: 500; display: block; margin-bottom: 4px; }

/* Footer */
.gh-footer { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 32px; padding-block: 48px; font-size: 14px; }
.gh-footer h4 { margin: 0 0 12px; color: var(--gh-faint); font-family: var(--gh-mono); font-size: 11px; font-weight: 400; letter-spacing: .12em; text-transform: uppercase; }
.gh-footer a { display: block; margin-bottom: 8px; color: var(--gh-soft); text-decoration: none; }
.gh-footer a:hover { color: var(--gh-paper); }
.gh-footer p { margin: 12px 0 0; color: var(--gh-faint); max-width: 280px; }
.gh-legal { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; padding-block: 16px; color: var(--gh-faint); font-family: var(--gh-mono); font-size: 11px; }

/* Phone */
@media (max-width: 820px) {
  .gh-nav__links a:not(.gh-btn):not(.gh-nav__keep) { display: none; }
  .gh-footer { grid-template-columns: 1fr 1fr; }
  .gh-search { min-width: 0; flex: 1; }
}
@media (max-width: 520px) {
  .gh-footer { grid-template-columns: 1fr; gap: 20px; }
  .gh-cells--logos { grid-template-columns: 1fr 1fr; }
  .gh-cell--logo { min-height: 84px; font-size: 18px; }
  .gh-search { display: none; }
}
