/* ==========================================================================
   Guides (public/guides/*.html, generated by design/build-guides.py).
   Long-form reading on the same paper, ink and single blue as the product
   pages. Loaded after site.css, redesign.css and overrides.css, and scoped to
   body.guides so nothing here can reach another page.
   ========================================================================== */

.guides .guide-hero{ padding:clamp(40px, 6vw, 72px) 0 clamp(32px, 5vw, 56px); }
.guides .guide-hero .hero-inner{ max-width:1180px; }
.guides .guide-hero h1{
  max-width:20ch; margin:0 0 20px;
  font-size:clamp(2rem, 4.6vw, 3.1rem); font-weight:700; line-height:1.08; text-wrap:balance;
}
.guides .guide-hero .lead{ max-width:44rem; margin:0; font-size:1.14rem; line-height:1.6; color:var(--text); }
.guide-meta{ margin:18px 0 0; font-size:.86rem; color:var(--text-muted); }

.guide-crumbs{
  display:flex; flex-wrap:wrap; align-items:center; gap:.5rem;
  margin-bottom:22px; font-size:.86rem; color:var(--text-muted);
}
.guide-crumbs a{ color:var(--text-muted); font-weight:600; }
.guide-crumbs a:hover{ color:var(--primary); }

/* ------------------------------ article body ---------------------------- */
.guide{ background:var(--surface); border-top:1px solid var(--border); padding:clamp(32px, 5vw, 56px) 0 0; }
/* Text keeps a readable measure; figures, the CTA and the card rows may use
   the full shell width. */
.guide-wrap > .guide-facts,
.guide-section > *{ max-width:46rem; }
.guide-section > .guide-figure{ max-width:none; width:fit-content; }
.guide-section > .guide-figure--shot{ max-width:46rem; width:auto; }

.guide-facts{
  margin:0 0 8px; padding:22px 24px 20px;
  background:var(--bg); border:1px solid var(--border); border-left:3px solid var(--primary);
}
.guide-facts h2{
  margin:0 0 12px; font-size:.78rem; font-weight:700; letter-spacing:.09em; text-transform:uppercase;
  color:var(--primary);
}
.guide-facts ul{ margin:0; padding:0; list-style:none; display:grid; gap:8px; }
.guide-facts li{ font-size:.97rem; line-height:1.5; color:var(--text-muted); }
.guide-facts strong{ color:var(--text); font-weight:600; }

.guide-section{ margin-top:clamp(36px, 5vw, 52px); }
.guide-section h2{
  margin:0 0 14px; font-size:clamp(1.4rem, 2.6vw, 1.75rem); font-weight:700; line-height:1.2;
  scroll-margin-top:96px; text-wrap:balance;
}
.guide-section p,
.guide-section li{ font-size:1.04rem; line-height:1.68; color:#3A434D; }
.guide-section p{ margin:0 0 16px; }
.guide-section > ul{ margin:0 0 16px; padding-left:1.15rem; display:grid; gap:8px; }
.guide-section a{ font-weight:600; text-decoration:underline; text-decoration-color:color-mix(in srgb, var(--primary) 35%, transparent); text-underline-offset:3px; }
.guide-section a:hover{ text-decoration-color:currentColor; }
.guide-section strong{ color:var(--text); font-weight:600; }

/* Step list: the same numbered rail as the custom page's steps. */
.guide-steps{ list-style:none; margin:20px 0; padding:0; counter-reset:step; border-top:1px solid var(--border); }
.guide-steps li{
  counter-increment:step; position:relative;
  padding:18px 0 18px 58px; border-bottom:1px solid var(--border);
}
.guide-steps li::before{
  content:counter(step, decimal-leading-zero);
  position:absolute; left:0; top:19px;
  font-family:var(--mono); font-size:.82rem; font-weight:600; letter-spacing:.04em; color:var(--primary);
}
.guide-steps h3{ margin:0 0 4px; font-size:1.06rem; font-weight:650; }
.guide-steps p{ margin:0; font-size:1rem; }

/* Tables scroll inside their own box, so the page itself never does. */
.guide-table-wrap{ margin:20px 0; overflow-x:auto; border:1px solid var(--border); -webkit-overflow-scrolling:touch; }
.guide-table{ width:100%; min-width:30rem; border-collapse:collapse; font-size:.95rem; line-height:1.45; background:var(--surface); }
.guide-table caption{
  caption-side:bottom; padding:10px 14px; text-align:left;
  font-size:.84rem; color:var(--text-muted); border-top:1px solid var(--border); background:var(--bg);
}
.guide-table th,
.guide-table td{ padding:11px 14px; text-align:left; vertical-align:top; border-bottom:1px solid var(--border); }
.guide-table thead th{
  font-size:.76rem; font-weight:700; letter-spacing:.07em; text-transform:uppercase;
  color:var(--text); background:var(--bg); white-space:nowrap;
}
.guide-table tbody th{ font-weight:600; color:var(--text); width:26%; }
.guide-table td{ color:#3A434D; }
.guide-table tbody tr:last-child > *{ border-bottom:0; }
.guide-table a{ white-space:nowrap; }

/* Figures. A flow diagram is drawn twice (row and column) and one is shown,
   so the labels stay readable on a phone instead of scaling down. */
.guide-figure{ margin:24px 0; padding:20px; background:var(--bg); border:1px solid var(--border); }
.guide-svg{ display:block; width:100%; height:auto; font-family:var(--font); }
.guide-svg--narrow{ display:none; }
.guide-figure figcaption{ margin-top:14px; font-size:.86rem; line-height:1.5; color:var(--text-muted); }
.guide-figure--shot{ padding:0; background:var(--surface); }
.guide-figure--shot img{ display:block; width:100%; height:auto; }
.guide-figure--shot figcaption{ margin:0; padding:10px 14px; border-top:1px solid var(--border); background:var(--bg); }
/* Below the shell width a five-box row would shrink its labels, so the
   column version takes over well before a phone. */
@media (max-width:1180px){
  .guide-svg--wide{ display:none; }
  .guide-svg--narrow{ display:block; }
}
@media (max-width:760px){
  .guide-figure{ padding:16px; }
  .guide-section > .guide-figure{ width:auto; }
}

.guide-quote{ margin:20px 0; padding:4px 0 4px 20px; border-left:3px solid var(--primary); }
.guide-quote p{ font-size:1.2rem; line-height:1.5; color:var(--text); font-weight:500; margin:0 0 6px; }
.guide-quote footer{ font-size:.86rem; color:var(--text-muted); }

.guide-faq .faq-list{ margin-top:8px; }
.guide-faq .faq-item h3{ font-size:1.04rem; }

/* ------------------------------ CTA + cards ----------------------------- */
.guide-cta{ margin-top:clamp(40px, 6vw, 64px); }
.guide-cta h2{ font-size:1.5rem; }

.guide-related{ margin-top:clamp(40px, 6vw, 64px); padding-bottom:clamp(40px, 6vw, 64px); }
.guide-related > h2{ font-size:1.35rem; margin:0 0 18px; }
.guide-all{ margin:18px 0 0; font-weight:600; }

.guide-cards{ display:grid; grid-template-columns:repeat(3, minmax(0, 1fr)); gap:16px; }
.guide-card{
  display:flex; flex-direction:column; padding:22px 22px 20px;
  background:var(--surface); border:1px solid var(--border); border-radius:var(--radius);
  box-shadow:var(--sh-plate); color:var(--text);
  transition:transform .16s ease, box-shadow .16s ease, border-color .16s ease;
}
.guide-card:hover{ text-decoration:none; color:var(--text); transform:translateY(-2px); box-shadow:var(--sh-plate-hover); border-color:color-mix(in srgb, var(--primary) 35%, var(--border)); }
.guide-card-key{
  font-family:var(--mono); font-size:.7rem; font-weight:600; letter-spacing:.09em; text-transform:uppercase;
  color:var(--primary); margin-bottom:10px;
}
.guide-card h3{ margin:0 0 8px; font-size:1.08rem; font-weight:700; line-height:1.3; letter-spacing:-.015em; }
.guide-card p{ margin:0 0 16px; font-size:.92rem; line-height:1.5; color:var(--text-muted); }
.guide-card-more{ margin-top:auto; font-size:.86rem; font-weight:600; color:var(--primary); }

/* ---------------------------------- hub --------------------------------- */
.guide-hub{ padding-bottom:clamp(40px, 6vw, 64px); }
.guide-group + .guide-group{ margin-top:clamp(40px, 6vw, 60px); }
.guide-group-head{ display:flex; flex-wrap:wrap; align-items:baseline; gap:6px 18px; margin-bottom:18px; padding-bottom:12px; border-bottom:1px solid var(--border); }
.guide-group-head h2{ margin:0; font-size:1.45rem; font-weight:700; }
.guide-group-head p{ margin:0; font-size:.97rem; color:var(--text-muted); }

/* The article sits on the white surface right down to the footer. */
.guides .site-footer{ margin-top:0; }
.guides .site-nav .nav-link{ font-weight:600; }

@media (max-width:900px){
  .guide-cards{ grid-template-columns:repeat(2, minmax(0, 1fr)); }
}
@media (max-width:600px){
  /* Two- and three-column tables fit a phone without scrolling; only the
     four-column ones keep their minimum width and scroll in their box. */
  .guide-table--c2, .guide-table--c3{ min-width:0; font-size:.88rem; }
  .guide-table--c2 th, .guide-table--c2 td,
  .guide-table--c3 th, .guide-table--c3 td{ padding:9px 10px; }
  .guide-table thead th{ white-space:normal; }
  .guide-table a{ white-space:normal; }
  .guide-cards{ grid-template-columns:1fr; }
  .guide-steps li{ padding-left:44px; }
  .guides .guide-hero .lead{ font-size:1.05rem; }
}
