/* ==========================================================================
   blog.css — blog index, article shell, and question blocks.
   Loaded after styles.css; reuses its tokens. Note that styles.css resets
   `p` to muted with no margin and `a` to inherit/no-underline, so prose
   inside .post-body has to restate both.
   ========================================================================== */

/* ----- shared page shell ----- */
.blog-wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 72px 24px 24px;
}

.blog-head {
  max-width: 760px;
  margin-bottom: 40px;
}
.blog-head h1 {
  font-size: clamp(34px, 5.2vw, 48px);
  margin: 0 0 16px;
}
.blog-head p {
  font-size: 17px;
}

/* ----- post grid / cards (blog index) ----- */
.post-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
  padding-bottom: 72px;
}

.post-card {
  display: flex;
  color: inherit;
  flex-direction: column;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 26px;
  box-shadow: var(--shadow-card);
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.post-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-card-hover);
  border-color: var(--brand-border);
}
.post-card h2 {
  font-size: 22px;
  line-height: 1.25;
  margin: 0 0 10px;
}
.post-card:hover h2 { color: var(--brand); }
.post-card p {
  font-size: 15px;
  flex: 1;
}
.post-card .post-meta { margin-top: 18px; }

/* ----- byline / meta ----- */
.post-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  font-size: 13.5px;
  color: var(--muted);
}
.post-meta span + span::before {
  content: "\00b7";
  margin-right: 10px;
  color: var(--gray-300);
}

/* ----- article header ----- */
.post-shell {
  max-width: 760px;
  margin: 0 auto;
  padding: 64px 24px 0;
}
.post-header { margin-bottom: 40px; }
.post-header h1 {
  font-size: clamp(30px, 4.6vw, 42px);
  line-height: 1.14;
  margin: 16px 0 24px;
}
.post-header .post-meta {
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

/* ----- article body ----- */
.post-body {
  font-size: 17px;
  line-height: 1.72;
  color: var(--gray-700);
  padding-bottom: 8px;
}
.post-body p {
  color: inherit;
  margin: 0 0 22px;
}
.post-body h2 {
  font-size: 26px;
  line-height: 1.22;
  color: var(--ink);
  margin: 52px 0 16px;
  scroll-margin-top: 90px;
}
.post-body h3 {
  font-size: 19.5px;
  color: var(--ink);
  margin: 36px 0 12px;
  scroll-margin-top: 90px;
}
.post-body h2 + h3 { margin-top: 24px; }
.post-body ul,
.post-body ol {
  margin: 0 0 22px;
  padding-left: 24px;
}
.post-body li { margin: 9px 0; }
.post-body li::marker { color: var(--gray-400); }
.post-body strong { color: var(--ink); font-weight: 650; }
.post-body em { font-style: italic; }
.post-body a {
  color: var(--brand);
  text-decoration: underline;
  text-underline-offset: 2px;
  text-decoration-thickness: 1px;
  text-decoration-color: var(--brand-border);
}
.post-body a:hover {
  color: var(--brand-hover);
  text-decoration-color: currentColor;
}
.post-body hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 48px 0;
}
.post-body blockquote {
  margin: 0 0 22px;
  padding: 4px 0 4px 20px;
  border-left: 3px solid var(--brand-border);
  color: var(--gray-600);
  font-style: italic;
}

/* lead paragraph */
.post-body .lead {
  font-size: 19px;
  line-height: 1.62;
  color: var(--gray-600);
}

/* ----- callout ----- */
.callout {
  background: var(--brand-tint);
  border: 1px solid var(--brand-border);
  border-radius: var(--r-md);
  padding: 20px 24px;
  margin: 0 0 26px;
}
.callout p { margin: 0; }
.callout p + p { margin-top: 12px; }
.callout-title {
  display: block;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--brand);
  margin-bottom: 8px;
}
.callout-warn { background: var(--warn-tint); border-color: #fcd34d; }
.callout-warn .callout-title { color: var(--warn-ink); }

/* ----- question block ----- */
.question-block {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 26px 28px;
  margin: 0 0 28px;
  box-shadow: var(--shadow-card);
}
.q-source {
  display: block;
  font-size: 11.5px;
  font-weight: 650;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--gray-400);
  margin-bottom: 16px;
}
.question-block .q-stimulus {
  color: var(--ink);
  margin-bottom: 18px;
}
.question-block .q-stem {
  font-weight: 650;
  color: var(--ink);
  margin-bottom: 18px;
}

.q-choices {
  counter-reset: choice;
  list-style: none;
  margin: 0 !important;
  padding: 0 !important;
}
.q-choices li {
  position: relative;
  margin: 0 0 10px;
  padding: 10px 14px 10px 46px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--inset);
  font-size: 16px;
  line-height: 1.6;
}
.q-choices li::before {
  counter-increment: choice;
  content: counter(choice, upper-alpha);
  position: absolute;
  left: 12px;
  top: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--card);
  border: 1px solid var(--gray-300);
  font-size: 12.5px;
  font-weight: 700;
  color: var(--gray-600);
}
.q-choices li:last-child { margin-bottom: 0; }

/* correct / eliminated states, used when a post walks the choices */
.q-choices .is-correct {
  border-color: var(--good);
  background: var(--good-tint);
}
.q-choices .is-correct::before {
  border-color: var(--good);
  background: var(--good);
  color: #fff;
}
.q-choices .is-out {
  color: var(--gray-500);
}
.q-choices .is-out::before {
  border-style: dashed;
  color: var(--gray-400);
}

/* answer reveal */
.q-reveal {
  margin-top: 20px;
  border-top: 1px solid var(--line);
  padding-top: 16px;
}
.q-reveal > summary {
  cursor: pointer;
  list-style: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14.5px;
  font-weight: 650;
  color: var(--brand);
}
.q-reveal > summary::-webkit-details-marker { display: none; }
.q-reveal > summary::after {
  content: "";
  width: 7px;
  height: 7px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg) translate(-2px, -2px);
  transition: transform .2s ease;
}
.q-reveal[open] > summary::after {
  transform: rotate(-135deg) translate(-1px, -1px);
}
.q-reveal > summary:hover { color: var(--brand-hover); }
.q-answer {
  margin-top: 16px;
  font-size: 15.5px;
  line-height: 1.68;
}
.q-answer p { margin: 0 0 12px; }
.q-answer p:last-child { margin-bottom: 0; }
.q-answer .q-key {
  font-weight: 700;
  color: var(--good-ink);
}

/* ----- passage block (Reading Comprehension) ----- */
.passage-block {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 26px 28px;
  margin: 0 0 28px;
  box-shadow: var(--shadow-card);
}
.passage-text { counter-reset: para; }
.passage-block .passage-text p {
  position: relative;
  padding-left: 34px;
  margin: 0 0 16px;
  font-size: 16px;
  line-height: 1.68;
  color: var(--ink);
}
.passage-block .passage-text p:last-child { margin-bottom: 0; }
.passage-block .passage-text p::before {
  counter-increment: para;
  content: counter(para);
  position: absolute;
  left: 0;
  top: 3px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 21px;
  height: 21px;
  border-radius: 50%;
  background: var(--inset);
  border: 1px solid var(--line);
  font-size: 11.5px;
  font-weight: 700;
  color: var(--gray-500);
}

/* the five-part map, rendered as a labelled card */
.map-card {
  background: var(--brand-tint);
  border: 1px solid var(--brand-border);
  border-radius: var(--r-md);
  padding: 22px 26px;
  margin: 0 0 28px;
}
.map-card > .callout-title { margin-bottom: 14px; }
.map-card dl { margin: 0; }
.map-card dt {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .03em;
  color: var(--brand);
  margin-bottom: 4px;
}
.map-card dd {
  margin: 0 0 16px;
  font-size: 15.5px;
  line-height: 1.62;
  color: var(--gray-700);
}
.map-card dd:last-child { margin-bottom: 0; }
.map-card dd ul {
  margin: 6px 0 0 !important;
  padding-left: 20px !important;
}
.map-card dd li { margin: 4px 0; }

/* ----- CTA ----- */
.post-cta {
  background: var(--card);
  border: 1px solid var(--brand-border);
  border-radius: var(--r-lg);
  padding: 30px 32px;
  margin: 52px 0 0;
  box-shadow: var(--shadow-card);
}
.post-cta h2 {
  font-size: 22px;
  margin: 0 0 12px;
  color: var(--ink);
}
.post-cta p {
  font-size: 16px;
  margin: 0 0 16px;
  color: var(--muted);
}
.post-cta ul {
  margin: 0 0 20px;
  padding: 0;
  list-style: none;
}
.post-cta li {
  position: relative;
  margin: 0 0 9px;
  padding-left: 26px;
  font-size: 15.5px;
  color: var(--gray-600);
}
.post-cta li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 8px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gradient);
}
.post-cta-foot {
  padding-top: 18px;
  border-top: 1px solid var(--line);
  font-size: 15px;
  margin: 0 !important;
}

/* ----- related posts ----- */
.related {
  max-width: 760px;
  margin: 0 auto;
  padding: 56px 24px 72px;
}
.related h2 {
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--muted);
  margin-bottom: 18px;
}
.related-list {
  display: grid;
  gap: 12px;
}
.related-list a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: 16px 20px;
  font-size: 16px;
  font-weight: 600;
  color: var(--ink);
  transition: border-color .2s ease, transform .2s ease;
}
.related-list a:hover {
  border-color: var(--brand-border);
  color: var(--brand);
  transform: translateX(2px);
}
.related-list a::after {
  content: "\2192";
  color: var(--gray-400);
  flex-shrink: 0;
}
.related-list a:hover::after { color: var(--brand); }

/* ----- back link ----- */
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--muted);
}
.back-link:hover { color: var(--brand); }
.back-link::before { content: "\2190"; }

/* ----- responsive ----- */
@media (max-width: 720px) {
  .blog-wrap { padding: 52px 20px 20px; }
  .post-shell { padding: 44px 20px 0; }
  .related { padding: 44px 20px 60px; }
  .post-body { font-size: 16.5px; }
  .post-body h2 { font-size: 23px; margin-top: 44px; }
  .question-block { padding: 22px 20px; }
  .q-choices li { padding: 10px 12px 10px 42px; font-size: 15.5px; }
  .post-cta { padding: 26px 22px; }
}
