/* ─────────────────────────────────────────────
   case-study.css — Case Study Page Styles
   Sections:
     1.  Hero
     2.  Sticky Section Nav
     3.  Layout Primitives (column / breakout)
     4.  Section Base & Typography
     5.  Overview (Problem / Solution)
     6.  Quotes (pull-quotes & user stories)
     7.  Process Flow Timeline
     8.  Image Blocks & Grids
     9.  Pain Point Matrix
     10. Competitor Table
     11. Usability Testing Stats
     12. Learnings
     13. Next Project
     14. Sitemap Chart
     15. Responsive
──────────────────────────────────────────────── */


/* ══ 1. Hero ══ */

.cs-hero {
  padding-top: var(--nav-h);
}

.cs-hero__intro {
  max-width: 740px;
  margin: 0 auto;
  padding: var(--sp-6) var(--gutter) var(--sp-5);
}

.cs-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 400;
  color: var(--clr-ink-2);
  margin-bottom: var(--sp-4);
  transition: color var(--t-fast) var(--ease-out);
}

.cs-back:hover {
  color: var(--clr-ink);
}

.cs-hero__title {
  font-size: clamp(40px, 6vw, 72px);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.0;
  color: var(--clr-ink);
  margin-bottom: var(--sp-3);
}

.cs-hero__sub {
  font-size: clamp(17px, 2vw, 21px);
  font-weight: 400;
  line-height: 1.55;
  color: var(--clr-ink-2);
  max-width: 580px;
  margin-bottom: var(--sp-5);
}

.cs-hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-4);
  padding-top: var(--sp-4);
  border-top: 1px solid var(--clr-border);
}

.cs-meta-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.cs-meta-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--clr-ink-3);
}

.cs-meta-value {
  font-size: 15px;
  font-weight: 400;
  color: var(--clr-ink);
}

/* Full-width cover image */
.cs-hero__cover {
  width: 100%;
  height: 66.67vh;
  overflow: hidden;
  background: var(--clr-surface);
  display: flex;
  align-items: center;
  justify-content: center;
}

.cs-hero__cover img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}


/* ══ 2. Sticky Section Nav ══ */

.cs-section-nav {
  position: sticky;
  top: var(--nav-h);
  z-index: 80;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--clr-border);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.cs-section-nav::-webkit-scrollbar {
  display: none;
}

.cs-section-nav__inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--gutter);
  display: flex;
  align-items: center;
  gap: var(--sp-4);
  height: 48px;
}

.cs-section-nav__link {
  font-size: 13px;
  font-weight: 400;
  color: var(--clr-ink-2);
  white-space: nowrap;
  flex-shrink: 0;
  position: relative;
  padding-bottom: 2px;
  transition: color var(--t-fast) var(--ease-out);
}

.cs-section-nav__link::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--clr-ink);
  transition: width var(--t-base) var(--ease-out);
}

.cs-section-nav__link:hover,
.cs-section-nav__link.is-active {
  color: var(--clr-ink);
}

.cs-section-nav__link:hover::after,
.cs-section-nav__link.is-active::after {
  width: 100%;
}


/* ══ 3. Layout Primitives ══ */

/*
  Hybrid layout system:
  .cs-column  — narrow reading column (740px), for text
  .cs-breakout — wide container (max-w), for artifacts & images
*/

.cs-column {
  max-width: 740px;
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* Space between consecutive content columns */
.cs-column + .cs-column,
.cs-breakout + .cs-column {
  margin-top: var(--sp-6);
}

.cs-breakout {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--gutter);
}


/* ══ 4. Section Base & Typography ══ */

.cs-section {
  padding-bottom: var(--sp-8);
}

/* Background shift replaces the border as a section separator */

.cs-section__header {
  background: var(--clr-surface);
  padding: var(--sp-6) 0;
  margin-bottom: var(--sp-6);
  overflow: hidden;
}

.cs-section__header-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-4);
}

.cs-section__header .eyebrow {
  margin-bottom: var(--sp-1);
}

.cs-section__header .cs-h2 {
  margin-bottom: 0;
}

/* Large muted section number — background watermark */
.cs-section__num {
  font-size: clamp(72px, 11vw, 128px);
  font-weight: 700;
  letter-spacing: -0.05em;
  line-height: 1;
  color: rgba(29, 29, 31, 0.07);
  flex-shrink: 0;
  user-select: none;
}

.cs-h2 {
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 600;
  letter-spacing: -0.025em;
  color: var(--clr-ink);
  margin-bottom: var(--sp-3);
}

.cs-h3 {
  font-size: clamp(18px, 2.2vw, 24px);
  font-weight: 500;
  letter-spacing: -0.015em;
  color: var(--clr-ink);
  margin-bottom: var(--sp-2);
  margin-top: var(--sp-5);
  border-left: 3px solid var(--clr-accent-warm);
  padding-left: 13px;
}

.cs-h3:first-child {
  margin-top: 0;
}

.cs-body {
  font-size: 17px;
  line-height: 1.72;
  color: var(--clr-ink-2);
}

.cs-body + .cs-body {
  margin-top: var(--sp-2);
}

/* MVP feature cards */
.mvp-grid {
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
  margin-top: var(--sp-5);
}

.mvp-card {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  background: var(--clr-surface);
  border-radius: var(--r-lg);
  padding: var(--sp-3) var(--sp-4);
  transition:
    transform var(--t-base) var(--ease-out),
    box-shadow var(--t-base) var(--ease-out);
  cursor: default;
}

.mvp-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.mvp-card__icon {
  width: 40px;
  height: 40px;
  border-radius: var(--r-sm);
  background: var(--clr-accent-warm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: rgba(29, 29, 31, 0.65);
}

.mvp-card__icon svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.mvp-card__title {
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -0.005em;
  line-height: 1.45;
  color: var(--clr-ink);
}

.cs-list {
  list-style: none;
  margin-top: var(--sp-3);
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
}

.cs-list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 16px;
  line-height: 1.65;
  color: var(--clr-ink-2);
}

.cs-list li::before {
  content: '—';
  color: var(--clr-accent-warm);
  font-weight: 700;
  flex-shrink: 0;
}


/* ══ 5. Overview — Problem / Solution ══ */

.cs-two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--sp-3);
  margin-top: var(--sp-4);
}

.cs-callout-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--sp-3);
  align-items: center;
  margin-top: var(--sp-4);
}

.cs-callout-row .cs-image {
  margin: 0;
}

.cs-callout {
  background: var(--clr-surface);
  border-radius: var(--r-lg);
  padding: var(--sp-4);
}

.cs-callout__label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--clr-ink-3);
  margin-bottom: var(--sp-2);
}

.cs-callout p {
  font-size: 16px;
  line-height: 1.68;
  color: var(--clr-ink);
}


/* ══ 6. Quotes — interview pull-quotes & user stories ══ */

.cs-quotes {
  margin-top: var(--sp-4);
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
}

.cs-quote {
  padding-left: var(--sp-3);
  border-left: 3px solid var(--clr-accent-warm);
}

.cs-quote p {
  font-size: 19px;
  line-height: 1.6;
  color: var(--clr-ink);
  font-style: italic;
}

.cs-quote__cite {
  display: block;
  margin-top: var(--sp-2);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-style: normal;
  color: var(--clr-ink-3);
}


/* ══ 7. Process Flow Timeline ══ */

/*
  Reusable for any sequential process across case studies.

  Layout:
    [label] ──────────────────────── ●  |
    description text                    |  ← amber track
                                        |
    [label] ──────────────────────── ●  |
    ...

  Each row: label (shrink) + rule (flex:1 stretch) + dot.
  Dot uses margin-right: -5px to sit centered on the track edge.
*/

/* ── Software pipeline ── */
.pipeline {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1fr;
  align-items: stretch;
  margin: var(--sp-5) 0;
}

.pipeline__step {
  background: #fff;
  border: 1px solid var(--clr-border);
  border-radius: var(--r-lg);
  padding: 32px 28px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.pipeline__num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--clr-accent-warm);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.03em;
  color: rgba(29, 29, 31, 0.7);
  flex-shrink: 0;
}

.pipeline__tool {
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.015em;
  color: var(--clr-ink);
  line-height: 1.2;
}

.pipeline__desc {
  font-size: 14px;
  line-height: 1.7;
  color: var(--clr-ink-2);
  margin: 0;
}

.pipeline__arrow {
  align-self: center;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  color: var(--clr-ink-3);
  flex-shrink: 0;
}

.pipeline__arrow svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}


/* ══ 8. Image Blocks & Grids ══ */

/* Single image — stays in reading column or breaks out */
.cs-image {
  width: 100%;
  border-radius: var(--r-md);
  overflow: hidden;
  background: var(--clr-surface);
  margin: var(--sp-4) 0;
}

.cs-image img {
  width: 100%;
  height: auto;
  display: block;
}


/* 2-column image grid (wireframes, mockups, etc.) */
.cs-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(12px, 2vw, 20px);
  margin: var(--sp-4) 0;
}

.cs-grid .cs-image {
  margin: 0;
}

/* Spacer between text and image blocks */
.cs-image-gap {
  margin-top: var(--sp-5);
}


/* ══ 9. Pain Point Matrix ══ */

/*
  Reusable 2×2 priority matrix with sticky notes.
  Axes run from -4 to 4.

  Sticky note positioning formula:
    left: ((x + 4) / 8 * 100)%    e.g. x = -1  →  37.5%
    top:  ((4 - y) / 8 * 100)%    e.g. y =  2  →  25%

  Set --rot on each .sticky-note for slight rotation variety.
*/

.pain-matrix {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--sp-2);
  max-width: 900px;
  margin: var(--sp-5) auto;
}

.pain-matrix__row {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  width: 100%;
}

/* The actual plot area — sticky notes position here */
.pain-matrix__plot {
  position: relative;
  flex: 1;
  aspect-ratio: 1 / 1;
}

/* Axis labels */
.pain-matrix__lbl {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--clr-ink-2);
  text-align: center;
  line-height: 1.45;
  flex-shrink: 0;
}

.pain-matrix__lbl--left,
.pain-matrix__lbl--right {
  max-width: 72px;
}

/* X axis */
.pain-matrix__x-axis {
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 1.5px;
  background: var(--clr-ink);
  transform: translateY(-50%);
}

.pain-matrix__x-axis::before {
  content: '';
  position: absolute;
  left: -1px;
  top: 50%;
  transform: translateY(-50%);
  border-right: 7px solid var(--clr-ink);
  border-top: 4px solid transparent;
  border-bottom: 4px solid transparent;
}

.pain-matrix__x-axis::after {
  content: '';
  position: absolute;
  right: -1px;
  top: 50%;
  transform: translateY(-50%);
  border-left: 7px solid var(--clr-ink);
  border-top: 4px solid transparent;
  border-bottom: 4px solid transparent;
}

/* Y axis */
.pain-matrix__y-axis {
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 1.5px;
  background: var(--clr-ink);
  transform: translateX(-50%);
}

.pain-matrix__y-axis::before {
  content: '';
  position: absolute;
  top: -1px;
  left: 50%;
  transform: translateX(-50%);
  border-bottom: 7px solid var(--clr-ink);
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
}

.pain-matrix__y-axis::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 50%;
  transform: translateX(-50%);
  border-top: 7px solid var(--clr-ink);
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
}

/* Sticky notes — fixed size so all notes are identical */
.sticky-note {
  position: absolute;
  width: 120px;
  height: 120px;
  overflow: hidden;
  background: var(--clr-accent-warm);
  border-radius: 2px;
  padding: 8px 10px;
  box-shadow:
    2px 4px 12px rgba(0, 0, 0, 0.12),
    0 1px 3px rgba(0, 0, 0, 0.07);
  font-family: 'Caveat', cursive;
  font-size: 17px;
  line-height: 1.35;
  color: rgba(0, 0, 0, 0.82);
  font-weight: 600;
  transform: translate(-50%, -50%) rotate(var(--rot, -1deg));
  z-index: 1;
}


/* ══ 10. Competitor Table ══ */

.comp-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: var(--sp-4) 0;
  scrollbar-width: thin;
  scrollbar-color: var(--clr-border) transparent;
}

.comp-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  min-width: 620px;
}

.comp-table thead th {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--clr-ink-2);
  text-align: center;
  padding: 0 var(--sp-2) var(--sp-3);
  border-bottom: 1px solid var(--clr-border);
  vertical-align: bottom;
  line-height: 1.4;
}

.comp-table thead th:first-child {
  text-align: left;
  padding-left: 0;
}

.comp-table tbody td {
  padding: var(--sp-3) var(--sp-2);
  border-bottom: 1px solid var(--clr-surface-2);
  text-align: center;
  vertical-align: middle;
}

.comp-table tbody td:first-child {
  text-align: left;
  padding-left: 0;
}

.comp-table tbody tr:last-child td {
  border-bottom: none;
}

/* Product cell */
.comp-table__product {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
}

/* Logo — initials show until a real logo image is added */
.comp-table__logo {
  position: relative;
  width: 64px;
  height: 64px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.comp-table__logo-init {
  display: none;
}

/* When a real logo is added, it covers the initials */
.comp-table__logo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 0;
  background: transparent;
}

.comp-table__name {
  font-size: 14px;
  font-weight: 500;
  color: var(--clr-ink);
  white-space: nowrap;
}

/* Check / cross indicators */
.comp-check {
  font-size: 17px;
  font-weight: 700;
  color: var(--clr-accent-warm);
  line-height: 1;
}

.comp-cross {
  font-size: 15px;
  color: var(--clr-ink-3);
  line-height: 1;
}


/* ══ 11. Usability Testing Stats ══ */

.ut-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--sp-3);
  margin-top: var(--sp-4);
}

.ut-stats--2col {
  grid-template-columns: repeat(2, 1fr);
}

.ut-stat {
  background: var(--clr-surface);
  border-radius: var(--r-md);
  padding: var(--sp-4) var(--sp-3);
  display: flex;
  flex-direction: column;
  gap: var(--sp-1);
  border-top: 3px solid var(--clr-accent-warm);
}

.ut-stat__pct {
  font-size: 52px;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1;
  color: var(--clr-accent-warm);
}

.ut-stat__desc {
  font-size: 13px;
  line-height: 1.6;
  color: var(--clr-ink-2);
}


/* ══ 12. Learnings ══ */

.cs-learnings {
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
  margin-top: var(--sp-4);
}

.cs-learning {
  display: flex;
  gap: var(--sp-3);
  align-items: flex-start;
}

.cs-learning__num {
  font-size: 13px;
  font-weight: 600;
  color: var(--clr-ink-3);
  padding-top: 3px;
  flex-shrink: 0;
  width: 24px;
}

.cs-learning__text {
  font-size: 17px;
  line-height: 1.65;
  color: var(--clr-ink);
}

.cs-learning__text strong {
  font-weight: 500;
  display: block;
  margin-bottom: 4px;
}


/* ══ 13. Next Project ══ */

.cs-next {
  padding: var(--sp-8) var(--gutter);
  text-align: center;
  border-top: 1px solid var(--clr-border);
}

.cs-next__label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--clr-ink-3);
  margin-bottom: var(--sp-2);
}

.cs-next__link {
  display: inline-block;
  font-size: clamp(28px, 4vw, 52px);
  font-weight: 600;
  letter-spacing: -0.025em;
  color: var(--clr-ink);
  transition: opacity var(--t-base) var(--ease-out);
}

.cs-next__link:hover {
  opacity: 0.45;
}


/* ══ 14. Sitemap Chart ══ */

.sitemap-chart {
  overflow: hidden;
  position: relative;
  background: var(--clr-surface);
  border-radius: var(--r-lg);
  padding: 32px;
  margin: var(--sp-4) 0;
}

.sm-outer {
  display: inline-flex;
  flex-direction: row;
  align-items: center;
  gap: 32px;
  min-width: max-content;
  vertical-align: top; /* prevent inline-flex baseline shift */
}

/* ── Left panel: Key + Next Steps ── */
.sm-left {
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex-shrink: 0;
  align-self: center;
}

.sm-panel-box {
  border: 1px solid var(--clr-border);
  border-radius: 12px;
  padding: 16px 18px;
  background: #fff;
  width: 178px;
  box-shadow: var(--shadow-sm);
}

.sm-panel-title {
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--clr-ink-3);
  margin-bottom: 12px;
}

.sm-legend-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 500;
  color: var(--clr-ink-2);
  margin-bottom: 6px;
}
.sm-legend-item:last-child { margin-bottom: 0; }

.sm-legend-swatch {
  width: 12px;
  height: 12px;
  border-radius: 3px;
  flex-shrink: 0;
}
.sm-legend-swatch--fe { background: #E8C84A; }
.sm-legend-swatch--be { background: #6AAEDE; }

.sm-next-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.sm-next-list li {
  font-size: 12px;
  line-height: 1.4;
  color: var(--clr-ink-2);
  padding-left: 14px;
  position: relative;
}
.sm-next-list li::before {
  content: '→';
  position: absolute;
  left: 0;
  font-size: 10px;
  color: var(--clr-ink-3);
  top: 2px;
}

/* Panel-to-tree arrow */
.sm-panel-arrow {
  font-size: 20px;
  color: var(--clr-border);
  flex-shrink: 0;
  user-select: none;
  line-height: 1;
}

/* ── Branch: node + optional children ── */
.sm-b {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  flex-shrink: 0;
}

/* Base node — 32px fixed height keeps connector math consistent */
.sm-n {
  height: 32px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border-radius: 7px;
  font-size: 12px;
  font-weight: 400;
  white-space: nowrap;
  flex-shrink: 0;
  border: 1px solid var(--clr-border);
  background: #fff;
  color: var(--clr-ink-2);
}

/* Root: dark filled anchor */
.sm-n--root {
  padding: 0 14px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: -0.02em;
  background: var(--clr-ink);
  border-color: var(--clr-ink);
  color: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(29, 29, 31, 0.18);
}

/* Front-end screens: barely-warm white, amber border */
.sm-n--fe {
  background: #FFFEF8;
  border-color: #E8C84A;
  color: var(--clr-ink);
  font-weight: 500;
}

/* Back-end operations: barely-cool white, steel-blue border */
.sm-n--be {
  background: #F8FBFF;
  border-color: #6AAEDE;
  color: var(--clr-ink);
  font-weight: 500;
}

/* Detail / leaf items: white with dark text so they stand out against the grey chart bg */
.sm-n--neutral {
  background: #fff;
  border-color: var(--clr-border);
  color: var(--clr-ink);
  font-size: 11.5px;
}

/* Reference pointer */
.sm-n--ref {
  border: 1px dashed var(--clr-border);
  background: transparent;
  color: var(--clr-ink-3);
  font-size: 11.5px;
  font-style: italic;
}

/* Horizontal connector — 1 px, light so it recedes behind nodes */
.sm-conn {
  width: 24px;
  height: 1px;
  background: #B8B8C0;
  margin-top: 15px;
  flex-shrink: 0;
}

/* Children container — vertical rail trimmed to first↔last child centers via JS */
.sm-kids {
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: relative;
  padding-left: 24px;
  align-self: flex-start;
}

.sm-kids::before {
  content: '';
  position: absolute;
  left: 0;
  top: var(--rail-top, 15px);
  bottom: var(--rail-bottom, 15px);
  width: 1px;
  background: #B8B8C0;
  pointer-events: none;
}

/* Horizontal branches from rail to each child */
.sm-kids > .sm-b {
  position: relative;
}

.sm-kids > .sm-b::before {
  content: '';
  position: absolute;
  left: -24px;
  top: 15px;
  width: 24px;
  height: 1px;
  background: #B8B8C0;
}

/* Arrowhead: right-pointing triangle at each branch end */
.sm-kids > .sm-b::after {
  content: '';
  position: absolute;
  left: -5px;
  top: 11px;
  width: 5px;
  height: 8px;
  background: #B8B8C0;
  clip-path: polygon(0 0, 100% 50%, 0 100%);
}


/* ── Magnifying lens ── */
.sm-lens {
  position: fixed;
  width: 340px;
  height: 260px;
  overflow: hidden;
  border-radius: 14px;
  border: 1px solid var(--clr-border);
  box-shadow: var(--shadow-xl);
  background: #fff;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.12s var(--ease-out);
  z-index: 9999;
}

.sm-lens::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 14px;
  background:
    linear-gradient(to right,  rgba(255,255,255,0.65) 0%, transparent 18%, transparent 82%, rgba(255,255,255,0.65) 100%),
    linear-gradient(to bottom, rgba(255,255,255,0.65) 0%, transparent 18%, transparent 82%, rgba(255,255,255,0.65) 100%);
  pointer-events: none;
}

.sm-lens-inner {
  position: absolute;
  pointer-events: none;
  user-select: none;
}

/* ══ 15. Research Timeline Cards (.week-cards) ══ */
/* Shared across stage / parentpal / lets-find-art case studies.
   Per-page badge text color via --week-badge-ink (defaults to #fff). */

.week-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--sp-3);
  margin: var(--sp-5) 0 0;
}
.week-card {
  background: var(--clr-surface);
  border-radius: var(--r-lg);
  padding: var(--sp-4);
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
}
.week-card__badge {
  align-self: flex-start;
  background: var(--clr-accent-warm);
  color: var(--week-badge-ink, #fff);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 4px 14px;
  border-radius: 99px;
}
.week-card__icon {
  width: 36px;
  height: 36px;
  color: var(--clr-accent-warm);
}
.week-card__icon svg { width: 100%; height: 100%; }
.week-card__phase {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--clr-ink-3);
}
.week-card__divider {
  height: 1px;
  background: var(--clr-border);
}
.week-card__items {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.week-card__items li {
  font-size: 15px;
  line-height: 1.4;
  color: var(--clr-ink);
  padding-left: 16px;
  position: relative;
}
.week-card__items li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 7px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--clr-accent-warm);
}
@media (max-width: 680px) {
  .week-cards { grid-template-columns: 1fr; }
}


/* ══ 16. Demographics Band (.demo-grid) ══ */
/* Shared across stage / parentpal / lets-find-art. Sits on a dark
   audience band; text colors are white-alpha by design. */

.demo-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--sp-3);
  margin-top: var(--sp-5);
  margin-bottom: var(--sp-2);
}
.demo-section {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: var(--r-lg);
  padding: var(--sp-4);
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
}
.demo-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--clr-accent-warm);
}
.demo-sublabel {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.4);
  padding-top: var(--sp-2);
  border-top: 1px solid rgba(255,255,255,0.08);
}
.demo-rows { display: flex; flex-direction: column; }
.demo-row {
  display: flex;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px solid rgba(255,255,255,0.07);
}
.demo-row:last-child { border-bottom: none; }
.demo-row__key {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.38);
  flex-shrink: 0;
  width: 76px;
  padding-top: 2px;
}
.demo-row__val {
  font-size: 14px;
  line-height: 1.5;
  color: rgba(255,255,255,0.85);
}
.demo-lines { display: flex; flex-direction: column; }
.demo-line {
  font-size: 14px;
  line-height: 1.55;
  color: rgba(255,255,255,0.82);
  padding: 8px 0;
  border-bottom: 1px solid rgba(255,255,255,0.07);
}
.demo-line:last-child { border-bottom: none; }
@media (max-width: 680px) { .demo-grid { grid-template-columns: 1fr; } }


/* ══ 17. Overview Cards (.ov-cards) ══ */
/* Shared across parentpal / pnc. Card surface is a solid brand color,
   set per page via --ov-card-bg; text on it is white-alpha. */

.ov-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--sp-3);
  margin: var(--sp-5) 0 0;
}
.ov-card {
  background: var(--ov-card-bg, var(--clr-accent-warm));
  border-radius: var(--r-lg);
  padding: var(--sp-4);
  display: flex;
  flex-direction: column;
  gap: var(--sp-4);
}
.ov-section { display: flex; flex-direction: column; }
.ov-icon {
  width: 38px;
  height: 38px;
  color: #fff;
  opacity: 0.85;
  margin-bottom: var(--sp-2);
  flex-shrink: 0;
}
.ov-icon svg { width: 100%; height: 100%; }
.ov-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.65);
  margin-bottom: var(--sp-2);
}
.ov-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.ov-list li {
  font-size: 15px;
  line-height: 1.4;
  color: #fff;
}
.ov-divider {
  height: 1px;
  background: rgba(255,255,255,0.25);
}
.ov-sub-label {
  font-size: 12px;
  font-weight: 600;
  color: rgba(255,255,255,0.65);
  margin-bottom: 6px;
}
.ov-value {
  font-size: 15px;
  line-height: 1.4;
  color: #fff;
}
@media (max-width: 680px) {
  .ov-cards { grid-template-columns: 1fr; }
}


/* ══ 18. Callout Row Modifiers ══ */
/* Width variants for .cs-callout-row (body text + supporting media).
   Shared by stage / lets-find-art; collapse to one column on mobile. */

.cs-callout-row--compact { grid-template-columns: 1fr 0.4fr; }
.cs-callout-row--medium  { grid-template-columns: 1fr 0.6fr; }
@media (max-width: 640px) {
  .cs-callout-row--compact,
  .cs-callout-row--medium { grid-template-columns: 1fr; }
}


/* ══ 19. Image Block Utilities ══ */
/* Modifiers for .cs-image wrappers — transparent-background spot art (GIFs)
   and padding variants. Shared by parentpal / stage / lets-find-art. */

.cs-image--no-bg    { background: none; }
.cs-image--pad-v5h4 { padding: var(--sp-5) var(--sp-4); }
.cs-image--pad-v4h5 { padding: var(--sp-4) var(--sp-5); }


/* ══ 20. Prototype Button (.proto-btn) ══ */
/* Shared by parentpal / lets-find-art. Accent fill comes from
   --clr-accent-warm; text color via --proto-ink (defaults to white).
   Pages that need spacing around a standalone button set their own margin. */

.proto-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--clr-accent-warm);
  color: var(--proto-ink, #fff);
  font-size: 14px;
  font-weight: 600;
  padding: 11px 22px;
  border-radius: 99px;
  text-decoration: none;
  transition: opacity var(--t-fast);
}
.proto-btn:hover { opacity: 0.82; }
.proto-btn svg { width: 15px; height: 15px; flex-shrink: 0; }


/* ══ 21. Responsive ══ */

@media (max-width: 640px) {
  .cs-callout-row,
  .cs-two-col,
  .cs-grid,
  .pipeline {
    grid-template-columns: 1fr;
  }

  .ut-stats,
  .ut-stats--2col {
    grid-template-columns: 1fr;
  }

  .pipeline__arrow {
    padding: 4px 0;
    transform: rotate(90deg);
  }

  .cs-hero__meta {
    gap: var(--sp-3);
  }

  .cs-section-nav__inner {
    gap: var(--sp-3);
  }
}
