/* ==========================================================================
   TestCosts.com — "Clearline" guide & prose styles
   --------------------------------------------------------------------------
   Companion to styles.css (tokens, shell, cards, buttons live there). This
   file styles the rich guide renderer (<article class="guide">): hero,
   answer callout, key takeaways, long-form body with tables, FAQ, related
   cities / tests / guides, and sources — plus cluster hub intros.

   Same palette as styles.css: navy #081A33/#0B2440/#12365F, cobalt
   #1D5BC4/#17479C, mint #5FE0A8/#0C7A57/#0A6246, ink #0F1D2E,
   porcelain #F7F9FC, ice #F2F7FD, hairlines #D9E2EF.
   ========================================================================== */

/* ------------------------------------------------------------ Article */
.guide {
  max-width: 72rem;
}

.guide-hero {
  padding: 0.5rem 0 1.75rem;
  border-bottom: 1px solid var(--tc-line);
  margin-bottom: 1.75rem;
}

.guide-hero .eyebrow {
  margin-bottom: 0.6rem;
}

.guide-hero h1 {
  max-width: 26ch;
  margin-bottom: 0.6rem;
}

.guide-byline {
  font-family: var(--tc-font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--tc-muted);
  margin: 0;
}

/* ------------------------------------------------------ Answer callout */
.guide-answer {
  max-width: 46rem;
  background: var(--tc-cobalt-50);
  border: 1px solid var(--tc-cobalt-100);
  border-left: 4px solid var(--tc-cobalt-600);
  border-radius: var(--tc-radius-md);
  padding: 1.1rem 1.25rem;
  margin: 0 0 1.75rem;
}

.guide-answer p {
  margin: 0;
  color: var(--tc-ink-soft);
  font-size: 1.05rem;
  line-height: 1.6;
}

/* --------------------------------------------------- Key takeaways */
.guide-takeaways {
  max-width: 46rem;
  background: var(--tc-paper);
  border: 1px solid var(--tc-line);
  border-top: 3px solid var(--tc-mint-600);
  border-radius: var(--tc-radius-lg);
  padding: 1.25rem 1.35rem 1.35rem;
  margin: 0 0 2rem;
  box-shadow: var(--tc-shadow-sm);
}

.guide-takeaways h2 {
  margin: 0 0 0.5rem;
  font-size: 1.15rem;
}

.guide-takeaways ul {
  margin: 0.5rem 0 0;
  padding-left: 1.2rem;
}

.guide-takeaways li {
  margin: 0.35rem 0;
  color: var(--tc-ink-soft);
}

.guide-takeaways li::marker {
  color: var(--tc-mint-600);
}

/* ------------------------------------------------------- Long-form body */
.guide-body {
  max-width: 46rem;
}

.guide-body h2 {
  position: relative;
  padding-bottom: 0.55rem;
  border-bottom: 1px solid var(--tc-line);
  margin: 2.25rem 0 1rem;
}

.guide-body h2::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -1px;
  width: 3rem;
  height: 3px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--tc-cobalt-600), var(--tc-mint-600));
}

.guide-body h3 {
  margin: 1.75rem 0 0.6rem;
  color: var(--tc-navy-900);
}

.guide-body p,
.guide-body li {
  color: var(--tc-ink-soft);
}

.guide-body ul,
.guide-body ol {
  margin: 0.75rem 0 1.25rem;
}

.guide-body li {
  margin: 0.35rem 0;
}

.guide-body li::marker {
  color: var(--tc-cobalt-600);
}

.guide-body strong {
  color: var(--tc-ink);
}

.guide-body a {
  color: var(--tc-cobalt-600);
}

/* Tables (data tables from guide bodies) */
.guide-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
  background: var(--tc-paper);
  border: 1px solid var(--tc-line);
  font-size: 0.95rem;
}

.guide-body th {
  background: var(--tc-navy-900);
  color: var(--tc-ice);
  text-align: left;
  font-weight: 650;
  padding: 0.65rem 0.85rem;
  font-size: 0.9rem;
}

.guide-body td {
  padding: 0.6rem 0.85rem;
  border-top: 1px solid var(--tc-line);
  color: var(--tc-ink-soft);
  vertical-align: top;
}

.guide-body tbody tr:nth-child(even) td {
  background: var(--tc-porcelain);
}

.guide-body caption {
  caption-side: bottom;
  padding-top: 0.5rem;
  font-size: 0.85rem;
  color: var(--tc-muted);
  text-align: left;
}

.guide-body blockquote {
  margin: 1.5rem 0;
  padding: 0.9rem 1.15rem;
  background: var(--tc-mint-50);
  border-left: 4px solid var(--tc-mint-600);
  border-radius: var(--tc-radius-sm);
  color: var(--tc-ink-soft);
}

.guide-body blockquote p:last-child {
  margin-bottom: 0;
}

.guide-body code {
  font-family: var(--tc-font-mono);
  font-size: 0.88em;
  background: var(--tc-cobalt-50);
  border: 1px solid var(--tc-cobalt-100);
  border-radius: 4px;
  padding: 0.1rem 0.35rem;
}

.guide-body hr {
  border: 0;
  border-top: 1px solid var(--tc-line);
  margin: 2rem 0;
}

/* ------------------------------------------------------------ FAQ */
.guide-faq {
  margin: 2.5rem 0;
}

.guide-faq > h2,
.guide-cities > h2,
.guide-more > h2,
.guide-related > h2,
.guide-sources > h2 {
  position: relative;
  padding-bottom: 0.55rem;
  border-bottom: 1px solid var(--tc-line);
  margin-bottom: 1.25rem;
}

.guide-faq > h2::after,
.guide-cities > h2::after,
.guide-more > h2::after,
.guide-related > h2::after,
.guide-sources > h2::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -1px;
  width: 3rem;
  height: 3px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--tc-cobalt-600), var(--tc-mint-600));
}

/* ------------------------------------------------- Related sections */
.guide-cities,
.guide-related,
.guide-sources {
  margin: 2.5rem 0;
}

.guide-cities .link-list,
.guide-related .link-list {
  margin: 0;
}

.guide-more {
  margin: 2.5rem 0;
}

.guide-more .card-grid {
  margin: 0;
}

/* The closing "browse all guides" line is also classed .guide-more (a <p>) */
p.guide-more {
  margin: 2.25rem 0 0;
  font-weight: 650;
}

p.guide-more a {
  text-decoration: none;
}

p.guide-more a::after {
  content: "\2192";
  margin-left: 0.35rem;
}

p.guide-more a:hover {
  text-decoration: underline;
}

/* ------------------------------------------------------------- Sources */
.guide-sources ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.guide-sources li {
  padding: 0.45rem 0;
  border-bottom: 1px solid var(--tc-line);
  font-size: 0.9rem;
}

.guide-sources a {
  color: var(--tc-cobalt-600);
  word-break: break-word;
}

/* -------------------------------------------------- Cluster hub intro */
.cluster-intro {
  max-width: 48rem;
  margin: 1.5rem 0 2rem;
}

.cluster-intro p {
  color: var(--tc-ink-soft);
}

.cluster-intro p:first-child {
  font-size: 1.08rem;
  color: var(--tc-ink);
}

/* ---------------------------------------------------------- Responsive */
@media (max-width: 640px) {
  .guide-hero {
    padding-bottom: 1.25rem;
    margin-bottom: 1.25rem;
  }

  .guide-body table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .guide-body table th,
  .guide-body table td {
    white-space: nowrap;
  }
}
