/* Methodology-guide layer over home-parity.css (guide pages only).
 * The shell (nav, footer, buttons, type scale, focus, reduced-motion) comes
 * from the parity foundation; everything gd-* below is the guide family's own
 * article grammar — deliberately distinct from landing bands and the blog's
 * purple overlay composition.
 */

/* ---------- Article frame ---------- */

.gd-article {
  padding: 56px 0 72px;
}

.gd-measure {
  max-width: 740px;
  margin-left: auto;
  margin-right: auto;
}

.gd-article h1 {
  margin: 0 0 16px;
}

.gd-lead {
  font-size: 17px;
  line-height: 1.6;
  color: #3d3d3d;
  margin: 0 0 24px;
}

.gd-article h2 {
  font-size: 21.4px;
  margin: 40px 0 12px;
}

.gd-article h3 {
  font-size: 18.2px;
  margin: 28px 0 10px;
}

.gd-article p,
.gd-article li {
  font-size: 15px;
  line-height: 1.6;
}

.gd-article p {
  margin: 12px 0;
}

.gd-article ul,
.gd-article ol {
  margin: 12px 0;
  padding-left: 1.4em;
}

.gd-article li {
  margin: 6px 0;
}

.gd-article a {
  color: #643995;
  text-decoration: underline;
}

/* Buttons inside articles keep their own colors (the generic link rule above
 * would otherwise paint button text purple-on-purple). */
.gd-article a.button {
  text-decoration: none;
}

.gd-article a.button--accent-bg {
  color: white;
}

.gd-muted {
  color: #6d6d6d;
  font-size: 13px;
}

/* ---------- Breadcrumb ---------- */

.gd-breadcrumb {
  font-size: 13px;
  color: #6d6d6d;
  margin: 0 0 20px;
}

.gd-breadcrumb a {
  color: #643995;
  text-decoration: none;
}

.gd-breadcrumb a:hover {
  text-decoration: underline;
}

/* ---------- Callouts & panels ---------- */

.gd-note {
  margin: 24px 0;
  padding: 16px 20px;
  background-color: #f2eeec;
  border-left: 4px solid #643995;
  border-radius: 0 4px 4px 0;
  font-size: 15px;
  line-height: 1.6;
}

.gd-example {
  margin: 20px 0;
  padding: 16px 20px;
  background-color: #f2eeec;
  border-radius: 8px;
  font-size: 15px;
}

.gd-example p {
  margin: 6px 0;
  font-size: 15px;
}

.gd-tree-sample {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 14px;
  line-height: 1.7;
  background-color: #f2eeec;
  border-radius: 8px;
  padding: 16px 20px;
  margin: 20px 0;
  overflow-x: auto;
  white-space: pre;
}

/* ---------- Evidence frame (approved recipe) ---------- */

.gd-frame {
  padding: 8px;
  border: 1px solid #e3dedd;
  border-radius: 10px;
  background-color: #faf8f6;
  box-shadow: 0 1px 2px rgba(37, 44, 97, 0.06), 0 12px 32px rgba(37, 44, 97, 0.06);
  margin: 24px 0;
}

.gd-frame img,
.gd-frame video {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 6px;
  background-color: white;
}

/* ---------- Cards (parallel short points) ---------- */

.gd-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin: 24px 0;
}

.gd-card {
  padding: 18px 20px;
  border: 1px solid #e3dedd;
  border-radius: 8px;
  background-color: white;
}

.gd-card h3 {
  margin: 0 0 8px;
}

.gd-card p {
  margin: 0;
}

/* ---------- Numbered procedural steps ---------- */

.gd-steps {
  list-style: none;
  counter-reset: gd-step;
  margin: 24px 0;
  padding: 0;
}

.gd-steps > li {
  counter-increment: gd-step;
  position: relative;
  padding: 0 0 24px 52px;
}

.gd-steps > li:last-child {
  padding-bottom: 0;
}

.gd-steps > li::before {
  content: counter(gd-step);
  position: absolute;
  left: 0;
  top: 0;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid #643995;
  color: #643995;
  background-color: white;
  font-weight: 700;
  font-size: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gd-steps h3 {
  margin: 2px 0 8px;
}

/* ---------- Data table ---------- */

.gd-table-scroll {
  overflow-x: auto;
  margin: 20px 0;
}

.gd-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
}

.gd-table th,
.gd-table td {
  padding: 10px 14px;
  border-bottom: 1px solid #e3dedd;
  text-align: left;
  vertical-align: top;
}

.gd-table th {
  white-space: nowrap;
}

/* ---------- FAQ ---------- */

.gd-faq details {
  border-bottom: 1px solid #e3dedd;
}

.gd-faq summary {
  padding: 14px 0;
  font-weight: 700;
  font-size: 15px;
  color: #303030;
  cursor: pointer;
}

.gd-faq summary:hover {
  color: #643995;
}

.gd-faq summary:focus-visible {
  outline: 2px solid #643995;
  outline-offset: 2px;
}

.gd-faq details p {
  margin: 0 0 14px;
}

/* ---------- Related guides ---------- */

.gd-related {
  margin: 40px 0 0;
  padding-top: 20px;
  border-top: 1px solid #e3dedd;
}

.gd-related ul {
  list-style: none;
  padding: 0;
  margin: 8px 0 0;
}

/* ---------- CTA rows and end band ---------- */

.gd-cta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
  margin: 24px 0;
}

.gd-cta {
  margin-top: 56px;
  padding: 32px 24px;
  border: 1px solid #e3dedd;
  border-radius: 10px;
  background-color: #faf8f6;
  text-align: center;
}

.gd-cta h2 {
  margin: 0 0 8px;
}

.gd-cta p {
  margin: 0 0 20px;
}

/* ---------- Responsive ---------- */

@media (max-width: 640px) {
  .gd-article {
    padding: 40px 0 56px;
  }

  .gd-article h1 {
    font-size: 28px;
  }
}

/* ---------- Figures (product evidence with captions) ---------- */

.gd-figure {
  margin: 24px 0;
}

.gd-figure .gd-frame {
  margin: 0;
}

.gd-figure figcaption {
  font-size: 13px;
  line-height: 1.5;
  color: #6d6d6d;
  margin-top: 8px;
}

/* ---------- At-a-glance orientation panel ---------- */

.gd-glance {
  margin: 24px 0 28px;
  padding: 16px 20px;
  border: 1px solid #d3c4ea;
  border-radius: 8px;
  background-color: #f5f0ff;
}

.gd-glance__row {
  display: flex;
  gap: 16px;
  align-items: baseline;
  padding: 8px 0;
}

.gd-glance__row + .gd-glance__row {
  border-top: 1px solid #e4d8f5;
}

.gd-glance__label {
  flex: 0 0 116px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #643995;
}

.gd-glance__row p {
  margin: 0;
  font-size: 14.5px;
}

/* ---------- Severity tiers (stacked rows, neutral lavender chips) ---------- */

.gd-severity {
  margin: 20px 0;
}

.gd-severity__row {
  display: flex;
  gap: 18px;
  padding: 16px 0;
  border-top: 1px solid #e3dedd;
}

.gd-severity__row:last-child {
  border-bottom: 1px solid #e3dedd;
}

.gd-severity__tier {
  flex: 0 0 90px;
  align-self: flex-start;
  font-size: 15px;
  font-weight: 700;
  color: #303030;
}

.gd-severity__body p {
  margin: 0;
}

.gd-severity__body .gd-severity__example {
  display: inline-block;
  margin: 10px 0 0;
  padding: 6px 12px;
  background-color: #f2eeec;
  border-radius: 6px;
  font-size: 13.5px;
}

/* ---------- Corrected/rewrite state (approved mint #f3fce3) ---------- */

.gd-example .gd-rewrite {
  margin: 12px -8px -4px;
  padding: 8px 12px;
  background-color: #f3fce3;
  border-radius: 6px;
}

.gd-table td.gd-td-rewrite {
  background-color: #f3fce3;
}

/* ---------- Product chapter (Detect / Review / Interpret) ----------
 * One contained lavender surface; breaks out of the 740px measure to at most
 * 900px (clamped below viewport). Text stays on a centered reading column;
 * figures use the full chapter width so product screenshots stay legible.
 */

.gd-product-chapter {
  box-sizing: border-box;
  width: min(900px, calc(100vw - 32px));
  position: relative;
  left: 50%;
  transform: translateX(-50%);
  margin: 48px 0;
  padding: 28px 32px 32px;
  border: 1px solid #d3c4ea;
  border-radius: 12px;
  background-color: white;
}

.gd-product-chapter > h2 {
  margin-top: 0;
}

.gd-product-chapter > h2,
.gd-product-chapter > p,
.gd-product-chapter > .gd-kicker,
.gd-product-chapter figcaption {
  max-width: 676px;
  margin-left: auto;
  margin-right: auto;
}

.gd-product-chapter .gd-figure {
  margin: 16px 0 28px;
}

.gd-product-chapter .gd-figure--narrow {
  max-width: 781px; /* setup capture is 765px native + frame padding; never upscale */
  margin-left: auto;
  margin-right: auto;
}

.gd-kicker {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 28px;
  margin-bottom: 10px;
  font-size: 15px;
  font-weight: 700;
  color: #303030;
}

.gd-kicker__num {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 2px solid #643995;
  color: #643995;
  background-color: white;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
}

@media (max-width: 640px) {
  .gd-glance__row {
    display: block;
  }

  .gd-glance__label {
    display: block;
    margin-bottom: 2px;
  }

  .gd-severity__row {
    display: block;
  }

  .gd-severity__tier {
    display: block;
    margin-bottom: 6px;
  }

  .gd-product-chapter {
    padding: 20px 16px 22px;
  }
}
