/* ─── GUIDES.CSS — shared styles for /guides/ content cluster ─── */
/* Scoped under .guide-page body class. Reused across every guide article. */

/* ─── NAV (same pattern as why.css) ─── */
.guide-page .nav-back {
  font-size: .82rem; font-weight: 600; color: var(--text-2);
  display: flex; align-items: center; gap: 5px;
  padding: 7px 14px; border-radius: 100px;
  border: 1px solid var(--border); text-decoration: none;
  transition: all .15s;
}
.guide-page .nav-back:hover { color: var(--blue); border-color: var(--blue); background: var(--blue-l); }
@media (max-width: 600px) {
  .guide-page .nav-back-text { display: none; }
  .guide-page .nav-back { padding: 7px 11px; }
}

/* ─── ARTICLE SHELL ───
   Everything (text, media, CTA, related-guides) shares the same 1200px
   container width — no separate narrower reading column. */
.guide-article {
  max-width: 1200px;
  margin: 0 auto;
  padding: 56px 24px 80px;
}
.guide-breadcrumb {
  font-size: .78rem; color: var(--text-3);
  margin-bottom: 20px;
}
.guide-breadcrumb a { color: var(--text-3); text-decoration: none; }
.guide-breadcrumb a:hover { color: var(--blue); }
.guide-eyebrow {
  font-size: .78rem; font-weight: 700; letter-spacing: .1em;
  text-transform: uppercase; color: var(--blue);
  margin-bottom: 14px;
}
.guide-article h1 {
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 4vw, 2.5rem);
  font-weight: 700; letter-spacing: -.03em;
  line-height: 1.15; color: var(--text);
  margin-bottom: 20px;
}
/* Direct-answer lead: the paragraph a GEO/answer-engine crawler should be able
   to lift verbatim. Kept visually distinct so it also reads as a real summary
   for a human skimming, not just an SEO trick. */
.guide-lead {
  /* border(4) + padding-left(22) = 26px inset — pulled back via negative
     margin so the inner text lines up flush with h1/h2/p above and below it,
     instead of starting 26px to the right of them. */
  margin-left: -26px; margin-bottom: 40px;
  font-size: 1.0625rem; line-height: 1.65; color: var(--text-2);
  padding: 18px 22px;
  background: var(--blue-l); border-left: 4px solid var(--blue);
  border-radius: 0 var(--r) var(--r) 0;
}
.guide-meta {
  display: flex; gap: 14px; align-items: center;
  font-size: .8rem; color: var(--text-3);
  margin-bottom: 28px;
}

/* ─── PROSE ─── */
.guide-article h2 {
  font-size: 1.375rem; font-weight: 600; letter-spacing: -.02em;
  color: var(--text); line-height: 1.25;
  margin: 48px 0 16px;
}
.guide-article p {
  font-size: 1rem; line-height: 1.68; color: var(--text-2);
  margin-bottom: 16px;
}
@media (max-width: 600px) {
  .guide-article h2 { font-size: 1.1875rem; }
  .guide-article p, .guide-lead { font-size: .9375rem; }
}

/* ─── MEDIA (image or video, same chrome as home's video-frame-wrap) ───
   .guide-frame wraps a chrome .guide-media + its .guide-media-caption so the
   whole card (toolbar included) shrinks to the media's own natural size and
   centers, instead of the old behavior of stretching video/img to fill the
   full 1200px article width regardless of their real resolution. */
.guide-frame {
  width: fit-content;
  max-width: 100%;
  margin: 28px auto 0;
}
.guide-media {
  border-radius: var(--r-lg) var(--r-lg) 0 0;
  overflow: hidden;
  border: 1px solid var(--border);
  border-bottom: none;
  box-shadow: var(--shadow);
  background: var(--text);
}
.guide-media-chrome {
  background: var(--surface-2);
  border-bottom: 1px solid var(--border);
  padding: 9px 14px;
  display: flex; align-items: center; gap: 10px;
}
.guide-media-chrome .chrome-dots span { width: 9px; height: 9px; }
.guide-media-chrome .chrome-bar { font-size: .72rem; padding: 4px 12px; }
.guide-media video, .guide-media img {
  display: block; width: auto; height: auto; max-width: 100%; margin: 0 auto;
}
.guide-media.plain {
  background: var(--surface); box-shadow: none;
  text-align: center; padding: 8px 0 0;
  margin: 0;
  border: none; border-radius: 0; overflow: visible;
}
.guide-media.plain img { max-width: min(100%, 480px); width: auto; height: auto; margin: 0 auto; }
/* .guide-frame.plain: unlike the chrome variant (whose natural width varies
   per video/screenshot, so it needs fit-content to shrink to it), a plain
   image is always capped at the same fixed 480px. Setting that width directly
   here, instead of relying on fit-content across .guide-media.plain img and
   .guide-media-caption as siblings, avoids a real bug where the browser's
   intrinsic-size calculation for fit-content picked a different (wrong,
   uncentered) result depending on viewport width — reproduced live at
   1920px, not at 1440px. width:auto + max-width is deterministic regardless
   of viewport, both children then simply fill the resolved 480px box. */
.guide-frame.plain {
  width: auto;
  max-width: min(100%, 480px);
}
.guide-frame.plain .guide-media-caption { max-width: 100%; }
/* .wide: same flat/no-chrome look as .plain, but scales up to the full
   article width instead of the fixed 480px cap. For diagrams with small
   text labels (e.g. the 3-panel IMDF conversion diagram) that need real
   width on desktop to stay legible, not a fixed thumbnail size. */
.guide-media.wide {
  background: var(--surface); box-shadow: none;
  text-align: center; padding: 8px 0 0;
  margin: 0;
  border: none; border-radius: 0; overflow: visible;
}
.guide-media.wide img { max-width: 100%; width: 100%; height: auto; margin: 0 auto; }
.guide-frame.wide { width: 100%; max-width: 100%; }
.guide-frame.wide .guide-media-caption { max-width: 100%; }
/* Context banner — same pattern as oodi.html's .venue-context: attached directly
   under the media frame, no gap, rounded only at the bottom. */
.guide-media-caption {
  background: var(--blue-l); border: 1px solid var(--blue-l2);
  border-top: none; border-radius: 0 0 var(--r-lg) var(--r-lg);
  padding: 16px 18px; margin: 0 0 32px;
  display: flex; gap: 12px; align-items: flex-start;
  text-align: left;
}
.guide-media-caption svg { flex-shrink: 0; margin-top: 2px; color: var(--blue); }
.guide-media-caption-label {
  font-size: .78rem; font-weight: 700; color: var(--blue); margin-bottom: 3px;
}
.guide-media-caption-text { font-size: .8rem; color: var(--text-2); line-height: 1.6; }

/* ─── FLOW DIAGRAM (pill + arrow, same pattern as about/index.html's
   "one dataset, every surface" diagram, ported to the light guide-page
   palette instead of the dark hero section it lives on there) ───
   Use for a process/structure visual, not a photo or screenshot. */
.guide-flow-card {
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: var(--r-lg); padding: 32px 24px;
  margin: 32px 0;
}
.guide-flow {
  display: flex; align-items: center; justify-content: center;
  gap: 14px; flex-wrap: wrap;
}
.gf-node {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 100px; padding: 10px 18px;
  font-size: .85rem; font-weight: 600; color: var(--text);
  white-space: nowrap;
}
.gf-node.gf-core { background: var(--blue); border-color: var(--blue); color: #fff; }
.gf-arrow { color: var(--text-3); font-size: 1.1rem; flex-shrink: 0; }
.gf-outs { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.gf-out {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 100px; padding: 8px 14px;
  font-size: .8rem; font-weight: 500; color: var(--text-2);
  white-space: nowrap;
}
@media (max-width: 640px) {
  .guide-flow { flex-direction: column; gap: 10px; }
  .guide-flow .gf-arrow { transform: rotate(90deg); }
}

/* ─── CLOSING CTA ─── */
.guide-cta {
  margin-top: 48px; padding: 28px 26px;
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: var(--r-lg); text-align: center;
}
.guide-cta p { max-width: none; color: var(--text); font-weight: 600; margin-bottom: 16px; }
.guide-cta a.btn {
  display: inline-block; padding: 12px 24px; border-radius: var(--r);
  background: var(--blue); color: #fff; font-weight: 600; font-size: .95rem;
  text-decoration: none; transition: all .15s;
}
.guide-cta a.btn:hover { background: var(--blue-d); transform: translateY(-1px); }

/* ─── RELATED GUIDES ("You might also be interested in") ─── */
.guide-related {
  margin-top: 56px; padding-top: 32px; border-top: 1px solid var(--border);
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px;
}
.guide-related-h {
  grid-column: 1 / -1;
  font-size: .78rem; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; color: var(--text-3); margin-bottom: 4px;
}
.guide-related .guide-card { margin-bottom: 0; }
@media (max-width: 640px) {
  .guide-related { grid-template-columns: 1fr; }
}

/* ─── GUIDES INDEX (hub page) ───
   980px matches the brand book's documented content grid max-width
   (section 3 of bb.html), instead of the old 760px reading column that
   left most of a wide viewport empty. 2-col grid gives the 5 cards
   some density; the last (odd) card spans full width via --wide. */
.guide-index-list {
  max-width: 980px; margin: 0 auto; padding: 8px 24px 80px;
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px;
}
.guide-card {
  display: block; text-decoration: none;
  background: var(--white); border: 1px solid var(--border);
  border-radius: var(--r-lg); padding: 24px;
  margin-bottom: 16px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow .2s, transform .2s;
}
.guide-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-2px); }
.guide-index-list .guide-card { margin-bottom: 0; }
.guide-index-list .guide-card.guide-card--wide {
  grid-column: 1 / -1;
  display: flex; align-items: center; gap: 24px;
}
.guide-card--wide .guide-card-illo { margin-bottom: 0; flex-shrink: 0; }
.guide-card--wide > div:last-child { flex: 1; min-width: 0; }
.guide-card--wide .guide-card-tier,
.guide-card--wide .guide-card-h { margin-bottom: 6px; }
.guide-card--wide .guide-card-p { margin-bottom: 0; }
@media (max-width: 640px) {
  .guide-index-list .guide-card.guide-card--wide { flex-direction: column; align-items: flex-start; gap: 0; }
  .guide-card--wide .guide-card-illo { margin-bottom: 16px; }
}
.guide-card-illo { width: 60px; height: 60px; margin-bottom: 16px; }
.guide-card-illo svg { display: block; width: 100%; height: 100%; }
@media (max-width: 640px) {
  .guide-index-list { grid-template-columns: 1fr; }
}
.guide-card-tier {
  font-size: .68rem; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; color: var(--blue); margin-bottom: 8px;
}
.guide-card-h { font-size: 1.05rem; font-weight: 700; color: var(--text); margin-bottom: 6px; }
.guide-card-p { font-size: .875rem; color: var(--text-2); line-height: 1.6; }

/* ─── CONVERSION: inline CTA, quote form, table, steps (add-indoor-map-google-maps) ─── */
.guide-inline-cta { display:flex; align-items:center; gap:14px; flex-wrap:wrap; margin:8px 0 28px; }
.guide-inline-cta span { font-size:.85rem; color:var(--text-3); }
.guide-inline-cta a.btn, .guide-quote-form .btn {
  display:inline-block; padding:12px 24px; border-radius:var(--r); background:var(--blue); color:#fff;
  font-weight:600; font-size:.95rem; text-decoration:none; border:0; cursor:pointer; font-family:inherit; transition:all .15s;
}
.guide-inline-cta a.btn:hover, .guide-quote-form .btn:hover { background:var(--blue-d); transform:translateY(-1px); }
.guide-quote-form .btn:disabled { opacity:.6; cursor:default; transform:none; }
.guide-cta { scroll-margin-top:90px; }
.guide-cta .guide-cta-h { margin:0 0 8px; font-size:1.35rem; }
.guide-quote-form { display:flex; flex-direction:column; gap:10px; max-width:460px; margin:18px auto 0; }
.guide-quote-form .gq-input {
  width:100%; padding:12px 14px; border:1px solid var(--border); border-radius:var(--r);
  background:var(--white); color:var(--text); font:inherit; font-size:.95rem; box-sizing:border-box;
}
.guide-quote-form .gq-input:focus { outline:2px solid var(--blue); outline-offset:1px; }
.gq-note { font-size:.8rem; color:var(--text-3); margin:14px 0 0; max-width:none; font-weight:400; }
.gq-success { color:var(--verdure); font-weight:600; margin:0; }
.gq-error { color:var(--alert); font-size:.85rem; margin:0; }
.guide-table-wrap { overflow-x:auto; margin:16px 0 8px; }
.guide-table { width:100%; border-collapse:collapse; font-size:.9rem; }
.guide-table th, .guide-table td { text-align:left; padding:10px 12px; border-bottom:1px solid var(--border); vertical-align:top; }
.guide-table thead th { font-size:.78rem; letter-spacing:.06em; text-transform:uppercase; color:var(--text-3); }
.guide-table tbody th { font-weight:600; color:var(--text); white-space:nowrap; }
.guide-steps, .guide-checklist { padding-left:1.3em; margin:12px 0 20px; }
.guide-steps li, .guide-checklist li { margin-bottom:8px; line-height:1.6; }
.guide-article .guide-meta { margin-top:-4px; }
@media (max-width:640px) { .guide-page .nav-cta { padding:7px 12px; font-size:.8rem; } }

/* ─── In-body links (internal linking for SEO: must read as links) ─── */
.guide-article p a:not(.btn), .guide-article li a:not(.btn), .guide-article td a:not(.btn) {
  color: var(--blue); text-decoration: underline; text-underline-offset: 2px; text-decoration-thickness: 1px;
}
.guide-article p a:not(.btn):hover, .guide-article li a:not(.btn):hover, .guide-article td a:not(.btn):hover { color: var(--blue-d); }
