/* cases.css – styles for cases.html only. Loaded after styles.css. */

:root {
  --ink: #1b2430;
  --body: #2b3542;
  --slate: #5a6676;
  --rule: #d9dee6;
  --wash: #f3f5f8;
  --accent: #2f4fa8;
  --serif: "IBM Plex Serif", Georgia, "Times New Roman", serif;
  --sans: "IBM Plex Sans", "Segoe UI", system-ui, -apple-system, Arial, sans-serif;
}

body.cases-page {
  background-color: #fff;
  color: var(--body);
  font-family: var(--sans);
}

.cases {
  max-width: 1080px;
  margin: 0 auto;
  padding: 3.5rem 2rem 5rem;
}

/* ---------- Introduction ---------- */
.cases-intro {
  max-width: 40rem;
  margin-bottom: 3rem;
}

.cases-intro h1 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 2.5rem;
  line-height: 1.15;
  color: var(--ink);
  margin: 0 0 1rem;
}

.cases-intro .standfirst {
  font-size: 1.25rem;
  line-height: 1.55;
  color: var(--ink);
  margin: 0 0 1rem;
}

.cases-intro .note {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--slate);
  margin: 0;
}

/* ---------- Index ---------- */
.case-index {
  list-style: none;
  margin: 0 0 1rem;
  padding: 0;
  border-bottom: 1px solid var(--rule);
}

.case-index li {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 2rem;
  padding: 0.8rem 0;
  border-top: 1px solid var(--rule);
}

.case-index a {
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
}

.case-index a:hover {
  color: var(--accent);
  text-decoration: underline;
}

.case-index span {
  color: var(--slate);
  font-size: 0.9rem;
  white-space: nowrap;
}

/* ---------- Case ---------- */
.case {
  display: grid;
  grid-template-columns: 13rem minmax(0, 1fr);
  column-gap: 3.5rem;
  padding: 3.5rem 0;
  border-top: 1px solid var(--rule);
  scroll-margin-top: 1rem;
}

.case-meta dl {
  margin: 0;
}

.case-meta dt {
  font-size: 0.85rem;
  color: var(--slate);
  margin: 0 0 0.15rem;
}

.case-meta dd {
  margin: 0 0 1.1rem;
  font-size: 0.95rem;
  line-height: 1.45;
  color: var(--ink);
}

.case-main h2 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.75rem;
  line-height: 1.25;
  color: var(--ink);
  margin: 0 0 1rem;
  max-width: 30rem;
}

.case-main .lead {
  font-size: 1.125rem;
  line-height: 1.6;
  color: var(--ink);
  max-width: 40rem;
  margin: 0 0 1.75rem;
}

.case-main p {
  line-height: 1.7;
  max-width: 40rem;
  margin: 0 0 1rem;
}

.case-main figure {
  margin: 0 0 1.75rem;
}

.figure-scroll {
  overflow-x: auto;
  border: 1px solid var(--rule);
  background-color: #fff;
}

.figure-scroll img {
  display: block;
  width: 100%;
  min-width: 560px;
  height: auto;
}

.case-main figcaption {
  font-size: 0.85rem;
  color: var(--slate);
  margin-top: 0.5rem;
}

/* ---------- Further engagements ---------- */
.further {
  padding-top: 3.5rem;
  border-top: 1px solid var(--rule);
}

.further h2 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.75rem;
  color: var(--ink);
  margin: 0 0 2rem;
}

.further dl {
  margin: 0;
}

.further .row-item {
  display: grid;
  grid-template-columns: 13rem minmax(0, 1fr);
  column-gap: 3.5rem;
  padding: 0.9rem 0;
  border-top: 1px solid var(--rule);
}

.further .row-item:last-child {
  border-bottom: 1px solid var(--rule);
}

.further dt {
  font-weight: 600;
  color: var(--ink);
  font-size: 0.95rem;
  line-height: 1.5;
}

.further dt span {
  display: block;
  font-weight: 400;
  color: var(--slate);
  font-size: 0.85rem;
}

.further dd {
  margin: 0;
  line-height: 1.6;
  max-width: 40rem;
}

a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* ---------- Small screens ---------- */
@media (max-width: 800px) {
  .cases {
    padding: 2.25rem 1.25rem 3.5rem;
  }

  .cases-intro h1 {
    font-size: 2rem;
  }

  .case,
  .further .row-item {
    grid-template-columns: 1fr;
  }

  .case {
    padding: 2.5rem 0;
  }

  .case-meta {
    order: 2;
    margin-top: 0.5rem;
  }

  .case-index li {
    flex-direction: column;
    gap: 0.15rem;
  }

  .case-index span {
    white-space: normal;
  }

  .further .row-item {
    row-gap: 0.25rem;
  }
}
