/* CloseRead Agent Skill detail page — editorial long-form on the existing .xs-case system.
   Reuses site type, paper/blue palette, nav and 900px reading measure. No new imagery or motion. */
.crs-case {
  --crs-line: #dbe5ef;
  --crs-heading: #284f7a;
  --crs-body: #455f78;
  --crs-muted: #6b8195;
  --crs-measure: 38em;
  min-height: 100svh;
  background: var(--paper);
  color: var(--ink);
}
.crs-case button { font: inherit; color: inherit; background: transparent; border: 0; cursor: pointer; }
.crs-case button:focus-visible,
.crs-case a:focus-visible { outline: 1px solid #6689b0; outline-offset: 5px; }
.crs-nav { background: var(--paper); }

.crs-story {
  max-width: var(--xs-width);
  width: calc(100% - 2 * var(--xs-gutter));
  margin: auto;
  padding: 26px 0 110px;
}

/* Hero: title and positioning on the left, approved introduction on the right. */
.crs-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.06fr) minmax(0, .94fr);
  gap: 28px 60px;
  align-items: start;
  padding: 58px 0 64px;
}
.crs-case .crs-kicker { margin: 0; font-size: 11px; letter-spacing: .12em; color: #71879d; }
.crs-hero h1 {
  margin: 16px 0 0;
  font: 400 clamp(34px, 4.4vw, 48px)/1.12 var(--xs-heading);
  letter-spacing: -.01em;
  text-wrap: balance;
  color: var(--crs-heading);
}
.crs-lead {
  margin: 20px 0 0;
  max-width: 23em;
  font: italic 17px/1.6 var(--xs-heading);
  color: #3f6285;
}
.crs-case .crs-tags { margin: 24px 0 0; font-size: 11.5px; line-height: 1.9; letter-spacing: .02em; color: var(--crs-muted); }

.crs-case .crs-intro-label { margin: 4px 0 8px; font-size: 11px; letter-spacing: .1em; color: #71879d; }
.crs-case .crs-intro { margin: 0; font-size: 13.5px; line-height: 1.95; color: var(--crs-body); }
.crs-case .crs-principle-lead { margin: 22px 0 0; font-size: 12px; color: var(--crs-muted); }
.crs-principle { margin: 12px 0 0; padding: 4px 0 4px 20px; border-left: 2px solid #a8bfd9; }
.crs-principle p:first-child {
  margin: 0;
  max-width: 26em;
  font: italic 17px/1.55 Georgia, serif;
  color: #294d75;
}
.crs-principle .crs-principle-note { margin: 10px 0 0; font-size: 12px; line-height: 1.8; color: var(--crs-muted); }

/* Chapters: number, title, subtitle, then a reading measure that opens for tables and cards. */
.crs-chapter { margin-top: 72px; padding-top: 30px; border-top: 1px solid var(--crs-line); }
.crs-chapter:first-of-type { margin-top: 18px; }
.crs-chapter-head { margin-bottom: 26px; }
.crs-num { display: block; margin-bottom: 9px; font: italic 13px Georgia, serif; letter-spacing: .06em; color: #7d91a6; }
.crs-chapter h2 { margin: 0; font: 500 28px/1.25 var(--xs-heading); color: var(--crs-heading); }
.crs-case .crs-sub { margin: 9px 0 0; max-width: 32em; font: italic 16px/1.6 var(--xs-heading); color: #3f6285; }
.crs-chapter-body > p { max-width: var(--crs-measure); margin: 0 0 15px; font-size: 14px; line-height: 1.95; color: var(--crs-body); }
.crs-chapter-body > p:last-child { margin-bottom: 0; }

/* 02 — three task paths, then the Understand → Select → Explain decision flow. */
.crs-paths { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 26px; margin-top: 32px; }
.crs-path { padding-top: 15px; border-top: 1px solid #c9d8e6; }
.crs-path h3 { margin: 0 0 8px; font: 500 15px/1.5 var(--xs-heading); color: #294d75; }
.crs-path p { max-width: none; margin: 0; font-size: 13px; line-height: 1.85; color: #4a6480; }

.crs-flow-block {
  margin-top: 38px;
  padding: 24px 26px 22px;
  background: #f1f7fc;
  border: 1px solid #dbe7f1;
  border-radius: 14px;
}
.crs-case .crs-flow-lead { margin: 0 0 16px; font-size: 12px; letter-spacing: .03em; color: #5c7489; }
.crs-flow { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 40px; margin: 0; padding: 0; list-style: none; }
.crs-flow li {
  position: relative;
  padding: 8px 17px;
  border: 1px solid #c9dcec;
  border-radius: 999px;
  background: #fff;
  font-size: 13px;
  letter-spacing: .02em;
  color: #2c5578;
}
.crs-flow li + li::before {
  content: "→";
  position: absolute;
  left: -20px;
  top: 50%;
  transform: translate(-50%, -50%);
  color: #8aa9c2;
  font-size: 14px;
}
.crs-case .crs-flow-note { margin: 16px 0 0; font: italic 12.5px/1.7 var(--xs-heading); color: var(--crs-muted); }

/* 03 — light CEFR table: row headers, no horizontal scrolling. */
.crs-table { margin-top: 24px; }
.crs-table table { width: 100%; border-collapse: collapse; table-layout: fixed; }
.crs-table th,
.crs-table td { padding: 14px 20px 14px 0; border-bottom: 1px solid #e2ebf3; text-align: left; vertical-align: top; }
.crs-table th { width: 104px; font: 600 13px/1.7 var(--font-body); color: #2c5578; }
.crs-table td { font-size: 13.5px; line-height: 1.85; color: var(--crs-body); }
.crs-case .crs-note { max-width: 44em; margin: 22px 0 0; font-size: 12.5px; line-height: 1.85; color: #5c7489; }

/* 04 — three static example cards. */
.crs-case .crs-case .crs-topic { margin: 0 0 10px; font-weight: 600; color: #2c5578; }
.crs-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; margin-top: 30px; }
.crs-card {
  display: flex;
  flex-direction: column;
  padding: 22px 20px 24px;
  background: #fbfdff;
  border: 1px solid #dbe6f0;
  border-radius: 12px;
}
.crs-card-num { font: italic 12px Georgia, serif; letter-spacing: .05em; color: #7d91a6; }
.crs-card h3 { margin: 10px 0 10px; font: 500 15px/1.5 var(--xs-heading); color: #294d75; }
.crs-card p { max-width: none; margin: 0; font-size: 13px; line-height: 1.85; color: #4a6480; }
.crs-case code {
  padding: 1px 5px;
  border-radius: 4px;
  background: #eef5fb;
  font: 12.5px/1.6 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  color: #2c5578;
}

/* 05 — rules as a text-first definition list. */
.crs-rules { margin-top: 8px; }
.crs-rule { display: grid; grid-template-columns: 176px minmax(0, 1fr); gap: 28px; padding: 19px 0; border-top: 1px solid #e2ebf3; }
.crs-rule:first-child { border-top: 0; }
.crs-rule h3 { margin: 0; font: 500 15px/1.6 var(--xs-heading); color: #294d75; }
.crs-rule p { max-width: 40em; margin: 0; font-size: 13.5px; line-height: 1.9; color: var(--crs-body); }

/* 06 — status, source entry, signature. */
.crs-source { margin-top: 38px; padding-top: 26px; border-top: 1px solid var(--crs-line); }
.crs-source a {
  display: inline-flex;
  align-items: baseline;
  gap: 9px;
  padding-bottom: 5px;
  border-bottom: 1px solid #a8bfd9;
  font: 500 15px/1.5 var(--xs-heading);
  color: #2c5578;
  text-decoration: none;
}
.crs-source a span { font-size: 12px; color: #71879d; }
.crs-case .crs-signature { margin: 24px 0 0; font: italic 13px/1.7 var(--xs-heading); color: var(--crs-muted); }

.crs-footer { margin-top: 56px; padding-top: 24px; border-top: 1px solid var(--crs-line); }
.crs-return { padding: 6px 0; font-size: 12.5px; color: #5c7489; }

@media (max-width: 820px) {
  .crs-hero { grid-template-columns: minmax(0, 1fr); gap: 30px; padding: 42px 0 46px; }
  .crs-lead { font-size: 16px; }
  .crs-paths,
  .crs-cards { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .crs-rule { grid-template-columns: minmax(0, 1fr); gap: 6px; padding: 15px 0; }
  .crs-rule h3 { margin-bottom: 2px; }
}

@media (max-width: 700px) {
  .crs-story { padding-bottom: 80px; }
  .crs-hero { padding: 34px 0 40px; }
  .crs-hero h1 { font-size: 30px; }
  .crs-tags { font-size: 11px; }
  .crs-chapter { margin-top: 48px; padding-top: 22px; }
  .crs-chapter:first-of-type { margin-top: 12px; }
  .crs-chapter-head { margin-bottom: 20px; }
  .crs-chapter h2 { font-size: 23px; }
  .crs-sub { font-size: 14.5px; }
  .crs-chapter-body > p { font-size: 13.5px; line-height: 1.9; }
  .crs-flow-block { margin-top: 30px; padding: 20px 18px; }
  .crs-flow { flex-direction: column; align-items: flex-start; gap: 20px; }
  .crs-flow li + li::before {
    content: "↓";
    left: 20px;
    top: -19px;
    transform: translateX(-50%);
    font-size: 12px;
  }
  .crs-flow-note { margin-top: 14px; }
  .crs-table th { width: 82px; padding-right: 12px; font-size: 12px; }
  .crs-table td { padding-right: 0; font-size: 13px; }
  .crs-card { padding: 18px 16px 20px; }
  .crs-case .crs-note { margin-top: 18px; }
  .crs-source { margin-top: 30px; }
  .crs-footer { margin-top: 42px; }
}
