/* SignalContext case stories and case library. Loaded after signal.css. */
.story-case,
.case-library {
  --story-charcoal: #111015;
  --story-sand: #eee7dc;
  --story-coral: #e8583e;
  --story-surface: #18171f;
  --story-ink-soft: #514840;
  --story-sand-muted: #665d55;
  --story-line: rgba(240, 237, 230, 0.14);
  --story-sand-line: rgba(36, 29, 25, 0.18);
  min-width: 0;
}

.story-case :is(main, section, nav, figure, article, dl, ol, ul),
.case-library :is(section, nav, figure, article, dl, ol, ul) {
  min-width: 0;
}

.story-case :is(p),
.case-library :is(p) {
  overflow-wrap: break-word;
  text-wrap: pretty;
}

.story-case :is(h1, h2, h3),
.case-library :is(h1, h2, h3) {
  overflow-wrap: normal;
  text-wrap: pretty;
}

.story-case .section-label,
.case-library .section-label {
  color: #b8957d;
}

.story-nobr {
  white-space: nowrap;
}

.story-case h1,
.story-case h2,
.story-case h3,
.case-library > .container > :is(h1, h2),
.case-library__grid h2 {
  text-wrap: balance;
}

/* Individual case header */
.story-hero {
  padding: clamp(6.75rem, 10vw, 9rem) 0 clamp(3.5rem, 6vw, 5.5rem);
}

.story-hero .breadcrumbs {
  margin-bottom: clamp(1.75rem, 3.5vw, 3rem);
}

.story-hero__grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: clamp(1.25rem, 2.5vw, 2.25rem);
  align-items: center;
}

.story-hero__copy {
  grid-column: span 6;
  min-width: 0;
  padding-right: clamp(0rem, 2vw, 2rem);
}

.story-hero__copy h1 {
  max-width: none;
  font-family: var(--f-display);
  font-size: clamp(2.25rem, 4vw, 3.625rem);
  font-weight: 400;
  line-height: 1.02;
  letter-spacing: -0.025em;
  word-spacing: 0.04em;
}

.story-lead {
  max-width: 39rem;
  margin-top: clamp(1.25rem, 2.4vw, 2rem);
  color: var(--c-text-muted);
  font-size: clamp(1rem, 1.35vw, 1.1875rem);
  line-height: 1.7;
}

.story-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.625rem;
  margin-top: 1.5rem;
}

.story-tags span {
  display: inline-flex;
  align-items: center;
  min-height: 2rem;
  padding: 0.375rem 0.75rem;
  border: 1px solid var(--c-border-hover);
  border-radius: var(--r-full);
  color: var(--c-text-muted);
  font-size: 0.8125rem;
  line-height: 1.35;
}

.story-hero__media {
  grid-column: span 6;
  min-width: 0;
  margin: 0;
}

.story-browser {
  overflow: hidden;
  border: 1px solid var(--c-border-hover);
  border-radius: var(--r-lg);
  background: var(--story-surface);
  box-shadow: 0 1.5rem 4rem rgba(0, 0, 0, 0.25);
}

.story-browser > span {
  display: flex;
  align-items: center;
  min-height: 2.75rem;
  padding: 0.5rem 1rem;
  border-bottom: 1px solid var(--c-border);
  color: var(--c-text-muted);
}

.story-browser label {
  font-size: 0.8125rem;
  font-weight: 500;
  line-height: 1.4;
}

.story-browser img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 10;
  object-fit: contain;
  background: #131216;
}

.story-hero__media figcaption,
.story-video figcaption {
  max-width: 44rem;
  margin-top: 0.75rem;
  color: var(--c-text-muted);
  font-size: 0.8125rem;
  line-height: 1.6;
}

.story-hero__media figcaption a,
.story-video figcaption a,
.story-copy a,
.story-source a,
.story-proof-note a {
  color: var(--story-coral);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

.story-hero__media figcaption a:hover,
.story-video figcaption a:hover,
.story-copy a:hover,
.story-source a:hover,
.story-proof-note a:hover {
  text-decoration-thickness: 2px;
}

/* Key measures and in-page navigation */
.story-facts {
  margin-top: clamp(2.75rem, 5vw, 4.5rem);
}

.story-facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1rem, 2.5vw, 2.25rem);
  padding-top: clamp(1.375rem, 2.5vw, 2rem);
  border-top: 1px solid var(--story-line);
}

.story-facts > div {
  min-width: 0;
}

.story-facts dt {
  color: var(--story-coral);
  font-family: var(--f-mono);
  font-size: clamp(1.75rem, 3.6vw, 3rem);
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: -0.055em;
  font-variant-numeric: tabular-nums;
}

.story-facts dd {
  max-width: 24rem;
  margin-top: 0.625rem;
  color: var(--c-text-muted);
  font-size: 0.9375rem;
  line-height: 1.6;
}

.story-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem 1.5rem;
  padding: 1rem 0;
  border-block: 1px solid var(--story-line);
}

.story-nav a,
.story-related a {
  color: var(--c-text-muted);
  font-size: 0.875rem;
  line-height: 1.5;
  text-decoration: underline;
  text-decoration-color: transparent;
  text-underline-offset: 0.2em;
  transition: color var(--transition), text-decoration-color var(--transition);
}

.story-nav a:hover,
.story-related a:hover {
  color: var(--c-text);
  text-decoration-color: currentColor;
}

.story-nav a:focus-visible,
.story-related a:focus-visible,
.story-hero__media a:focus-visible,
.story-copy a:focus-visible,
.story-source a:focus-visible,
.story-proof-note a:focus-visible,
.case-story-card a:focus-visible {
  outline: 2px solid var(--story-coral);
  outline-offset: 4px;
  border-radius: 3px;
}

/* Reusable case sections */
.story-section {
  padding-block: clamp(4rem, 7vw, 7rem);
}

.story-section--soft {
  background: var(--story-surface);
}

.story-section--sand {
  background: var(--story-sand);
  color: var(--story-charcoal);
}

.story-section--sand .section-label,
.story-section--sand .story-kicker {
  color: var(--story-sand-muted);
}

.story-section--sand .story-heading > p:not(.section-label),
.story-section--sand .story-copy > p,
.story-section--sand .story-copy li,
.story-section--sand .story-figure figcaption,
.story-section--sand .story-proof-note,
.story-section--sand .story-results dd,
.story-section--sand .story-callout p {
  color: var(--story-sand-muted);
}

.story-section--sand .story-results dt {
  color: #b83f2b;
}

.story-section--sand .story-nav,
.story-section--sand .story-facts,
.story-section--sand .story-results > div {
  border-color: var(--story-sand-line);
}

.story-section--sand .story-nav a,
.story-section--sand .story-related a {
  color: var(--story-ink-soft);
}

.story-section--sand .story-nav a:hover,
.story-section--sand .story-related a:hover {
  color: var(--story-charcoal);
}

.story-section--sand .story-callout {
  border-color: var(--story-coral);
  background: rgba(255, 255, 255, 0.36);
}

.story-section--sand .story-figure img,
.story-section--sand .story-pair img,
.story-section--sand .story-gallery img {
  border-color: var(--story-sand-line);
  background: #e5dccf;
}

.story-heading {
  max-width: 58rem;
  margin-bottom: clamp(2rem, 4vw, 3.5rem);
}

.story-heading .section-label {
  margin-bottom: 0.875rem;
}

.story-heading h2,
.story-copy h2 {
  font-family: var(--f-display);
  font-size: clamp(2rem, 3.8vw, 3.5rem);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -0.025em;
  word-spacing: 0.04em;
}

.story-heading h2 {
  max-width: 30ch;
}

.story-copy h2 {
  width: 100%;
  max-width: none;
}

.story-heading > p:not(.section-label) {
  max-width: 44rem;
  margin-top: 1.125rem;
  color: var(--c-text-muted);
  font-size: 1rem;
  line-height: 1.75;
}

.story-split {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: clamp(1.5rem, 3vw, 3rem);
  align-items: start;
}

.story-copy {
  grid-column: span 5;
  min-width: 0;
}

.story-copy h2 {
  margin-bottom: 1.375rem;
}

.story-copy h3 {
  margin-top: 1.75rem;
  margin-bottom: 0.625rem;
  font-size: clamp(1.125rem, 1.7vw, 1.375rem);
  font-weight: 600;
  line-height: 1.3;
}

.story-copy p,
.story-copy li {
  color: var(--c-text-muted);
  font-size: 1rem;
  line-height: 1.75;
}

.story-copy p + p {
  margin-top: 1rem;
}

.story-copy ul,
.story-copy ol,
.story-list {
  display: grid;
  gap: 0.625rem;
  margin-top: 1.125rem;
  padding: 0;
}

.story-copy li,
.story-list li {
  position: relative;
  padding-left: 1.25rem;
}

.story-copy li::before,
.story-list li::before {
  position: absolute;
  top: 0.78em;
  left: 0;
  width: 0.375rem;
  height: 0.375rem;
  border-radius: 50%;
  background: var(--story-coral);
  content: '';
}

.story-visual,
.story-gallery {
  grid-column: span 7;
  min-width: 0;
}

.story-visual {
  display: grid;
  align-content: start;
  gap: clamp(1.25rem, 2.5vw, 2rem);
}

.story-visual > *,
.story-gallery > *,
.story-pair > * {
  min-width: 0;
}

.story-pair,
.story-gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(1rem, 2vw, 1.5rem);
  align-items: start;
}

.story-figure {
  min-width: 0;
  margin: 0;
}

.story-kicker {
  display: block;
  margin-bottom: 0.625rem;
  color: var(--c-text-muted);
  font-family: var(--f-mono);
  font-size: 0.8125rem;
  font-weight: 500;
  line-height: 1.45;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.story-pair .story-figure > a {
  display: grid;
  min-height: 15rem;
  aspect-ratio: 4 / 3;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--story-line);
  border-radius: var(--r-md);
  background: var(--story-surface);
}

.story-figure img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--story-line);
  border-radius: var(--r-md);
  background: var(--story-surface);
  object-fit: contain;
}

.story-pair .story-figure img {
  width: 100%;
  height: 100%;
  border: 0;
  border-radius: 0;
}

.story-figure figcaption {
  margin-top: 0.75rem;
  color: var(--c-text-muted);
  font-size: 0.8125rem;
  line-height: 1.6;
}

.story-gallery .story-figure > a {
  display: block;
  overflow: hidden;
  border-radius: var(--r-md);
  background: var(--story-surface);
}

.story-gallery .story-figure > a img {
  border-radius: var(--r-md);
}

.story-phone-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1rem, 2.4vw, 2rem);
  align-items: start;
}

.story-phone-grid .story-figure {
  width: min(100%, 13.75rem);
  justify-self: center;
}

.story-phone-grid img {
  width: 100%;
  aspect-ratio: 9 / 19;
  object-fit: contain;
}

.story-path {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1rem, 2vw, 1.5rem);
  padding: 0;
  margin: clamp(2rem, 3vw, 2.5rem) 0;
}

.story-path:has(> li:nth-child(4)):not(:has(> li:nth-child(5))) {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.story-path:has(> li:nth-child(5)) {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

.story-path:has(> li:nth-child(5)) > li {
  grid-column: span 2;
}

.story-path:has(> li:nth-child(5)) > li:nth-child(4) {
  grid-column-start: 2;
}

.story-path:has(> li:nth-child(5)) > li:nth-child(5) {
  grid-column-start: 4;
}

.story-path + :is(.story-split, .story-gallery) {
  margin-top: clamp(2rem, 3vw, 2.5rem);
}

.story-pair + .story-split,
.story-split + .story-proof {
  margin-top: clamp(2.5rem, 4vw, 3.5rem);
}

.story-path li {
  min-width: 0;
  padding: 1.25rem 1.125rem 1.5rem;
  border-top: 1px solid var(--story-line);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.035), transparent 70%);
}

.story-step {
  display: inline-block;
  margin-bottom: 1.125rem;
  color: var(--story-coral);
  font-family: var(--f-mono);
  font-size: 0.875rem;
  font-variant-numeric: tabular-nums;
}

.story-path h3 {
  margin-bottom: 0.625rem;
  font-size: clamp(1.0625rem, 1.45vw, 1.25rem);
  font-weight: 600;
  line-height: 1.3;
}

.story-path li p {
  color: var(--c-text-muted);
  font-size: 0.9375rem;
  line-height: 1.7;
}

.story-callout {
  padding: clamp(1.25rem, 2.5vw, 2rem);
  border-left: 3px solid var(--story-coral);
  border-radius: 0 var(--r-md) var(--r-md) 0;
  background: rgba(255, 255, 255, 0.035);
}

.story-callout h3 {
  margin-bottom: 0.5rem;
  font-size: 1.125rem;
  line-height: 1.35;
}

.story-callout p {
  color: var(--c-text-muted);
  font-size: 0.9375rem;
  line-height: 1.7;
}

.story-chart {
  display: grid;
  gap: 1.25rem;
  padding: clamp(1.25rem, 2.5vw, 2rem);
  border: 1px solid var(--story-line);
  border-radius: var(--r-lg);
  background: var(--story-surface);
}

.story-chart__row {
  display: grid;
  grid-template-columns: minmax(7rem, 1fr) auto minmax(5rem, 1.25fr);
  gap: 0.875rem;
  align-items: center;
}

.story-chart__row > span {
  color: var(--c-text-muted);
  font-size: 0.875rem;
  line-height: 1.4;
}

.story-chart__row strong {
  color: var(--c-text);
  font-family: var(--f-mono);
  font-size: 1rem;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.story-chart__row i {
  display: block;
  height: 0.625rem;
  overflow: hidden;
  border-radius: var(--r-full);
  background: rgba(240, 237, 230, 0.1);
  font-style: normal;
}

.story-chart__row i::before {
  display: block;
  width: clamp(0%, var(--bar, 0%), 100%);
  height: 100%;
  border-radius: inherit;
  background: var(--story-coral);
  content: '';
}

.story-proof {
  margin: 0;
}

.story-proof img {
  display: block;
  width: 100%;
  height: auto;
  max-width: none;
  border: 1px solid var(--story-line);
  border-radius: var(--r-md);
  background: var(--story-surface);
  object-fit: contain;
}

.story-proof figcaption {
  margin-top: 0.75rem;
  color: var(--c-text-muted);
  font-size: 0.8125rem;
  line-height: 1.6;
}

.story-proof-note {
  max-width: 54rem;
  margin-top: 1rem;
  color: var(--c-text-muted);
  font-size: 0.875rem;
  line-height: 1.7;
}

.story-video {
  min-width: 0;
  margin: 0;
}

.story-video iframe {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  border: 0;
  border-radius: 12px;
  background: #131216;
}

.story-ledger {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(10rem, 13.9375rem);
  gap: clamp(1.25rem, 3vw, 2.5rem);
  align-items: center;
  padding: clamp(1.5rem, 4vw, 3rem);
  border-radius: var(--r-lg);
  background: var(--story-sand);
  color: var(--story-charcoal);
}

.story-ledger strong {
  display: block;
  color: var(--story-charcoal);
  font-family: var(--f-mono);
  font-size: clamp(2.75rem, 6vw, 5rem);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.06em;
  font-variant-numeric: tabular-nums;
}

.story-ledger p,
.story-ledger figcaption {
  margin-top: 0.75rem;
  color: var(--story-sand-muted);
  font-size: 0.9375rem;
  line-height: 1.65;
}

.story-ledger figure {
  width: min(100%, 13.9375rem);
  justify-self: end;
  margin: 0;
}

.story-ledger figure img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--r-sm);
  background: #e5dccf;
  object-fit: contain;
}

dl.story-results {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1rem, 2vw, 1.5rem);
}

dl.story-results:not(:has(> div:nth-child(3))) {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

dl.story-results > div {
  min-width: 0;
  padding-top: 1.25rem;
  border-top: 1px solid var(--story-line);
}

.story-results dt {
  color: var(--story-coral);
  font-family: var(--f-mono);
  font-size: clamp(1.75rem, 3vw, 2.75rem);
  line-height: 1.2;
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
}

.story-results dd {
  margin-top: 0.5rem;
  color: var(--c-text-muted);
  font-size: 0.9375rem;
  line-height: 1.6;
}

.story-source {
  max-width: 56rem;
  color: var(--c-text-muted);
}

.story-facts + .story-source {
  margin-top: 1.25rem;
}

.story-source p {
  font-size: 0.875rem;
  line-height: 1.75;
}

.story-source p + p {
  margin-top: 0.75rem;
}

.story-related {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
}

.story-cta {
  padding-block: clamp(4.5rem, 8vw, 7.5rem);
  text-align: center;
}

.story-cta > .container > * {
  margin-inline: auto;
}

.story-cta h2 {
  max-width: 18ch;
  font-family: var(--f-display);
  font-size: clamp(2.25rem, 4.5vw, 4rem);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -0.035em;
}

.story-cta > .container > p:not(.section-label) {
  max-width: 42rem;
  margin-top: 1rem;
  color: var(--c-text-muted);
  font-size: 1rem;
  line-height: 1.7;
}

.story-cta__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0.75rem 1.25rem;
  margin-top: 1.75rem;
}

.story-section--sand .btn-ghost,
.story-cta--sand .btn-ghost {
  color: var(--story-ink-soft);
}

.story-section--sand .btn-ghost:hover,
.story-cta--sand .btn-ghost:hover {
  color: var(--story-charcoal);
}

/* Case index */
.case-library {
  padding: clamp(7rem, 10vw, 9rem) 0 clamp(4rem, 7vw, 7rem);
}

.case-library > .container > :is(h1, h2) {
  max-width: 17ch;
  font-family: var(--f-display);
  font-size: clamp(2.5rem, 5.5vw, 5rem);
  font-weight: 400;
  line-height: 1.04;
  letter-spacing: -0.035em;
}

.case-library > .container > .section-label {
  margin-bottom: 1rem;
}

.case-library > .container > p:not(.section-label) {
  max-width: 45rem;
  margin-top: 1.25rem;
  color: var(--c-text-muted);
  font-size: 1rem;
  line-height: 1.75;
}

.case-library__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1rem, 2vw, 1.5rem);
  align-items: stretch;
  margin-top: clamp(2.25rem, 4vw, 3.5rem);
}

.case-story-card {
  display: grid;
  grid-template-rows: auto 1fr;
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  background: linear-gradient(155deg, #201e25, #17161c 72%);
  transition: border-color var(--transition), transform var(--transition);
}

.case-story-card:hover {
  border-color: var(--c-border-hover);
  transform: translateY(-3px);
}

.case-story-card__image {
  display: grid;
  min-width: 0;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  place-items: center;
  background: var(--story-sand);
}

.case-story-card__image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
}

.case-story-card__body {
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr) auto auto;
  align-content: start;
  padding: clamp(1.25rem, 2.2vw, 1.75rem);
}

.case-story-card__body .section-label {
  margin-bottom: 0.75rem;
  font-size: 0.8125rem;
}

.case-story-card__body h2 {
  min-height: 2.32em;
  margin-bottom: 0.75rem;
  font-family: var(--f-display);
  font-size: 1.5625rem;
  font-weight: 400;
  line-height: 1.16;
  letter-spacing: -0.02em;
}

.case-story-card__body > p:not(.section-label) {
  margin-bottom: 1.25rem;
  color: var(--c-text-muted);
  font-size: 0.9375rem;
  line-height: 1.65;
}

dl.case-story-card__metric {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  padding-block: 1rem;
  border-block: 1px solid var(--story-line);
}

dl.case-story-card__metric:not(:has(> div:nth-child(2))) {
  grid-template-columns: minmax(0, 1fr);
}

dl.case-story-card__metric > div {
  min-width: 0;
}

dl.case-story-card__metric dt {
  color: var(--story-coral);
  font-family: var(--f-mono);
  font-size: clamp(1.125rem, 1.7vw, 1.5rem);
  line-height: 1.25;
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
}

dl.case-story-card__metric dd {
  margin-top: 0.375rem;
  color: var(--c-text-muted);
  font-size: 0.8125rem;
  line-height: 1.5;
}

.case-story-card__link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  width: fit-content;
  max-width: 100%;
  margin-top: 1.25rem;
  color: var(--c-text);
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.5;
  text-decoration: underline;
  text-decoration-color: transparent;
  text-underline-offset: 0.2em;
  transition: color var(--transition), text-decoration-color var(--transition);
}

.case-story-card__link:hover {
  color: var(--story-coral);
  text-decoration-color: currentColor;
}

@media (max-width: 1024px) {
  .story-facts {
    gap: 1.25rem;
  }

  .story-path {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .story-path:has(> li:nth-child(5)) {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .story-path:has(> li:nth-child(4)):not(:has(> li:nth-child(5))) {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .story-path:has(> li:nth-child(5)) > li {
    grid-column: auto;
  }

  .story-path:has(> li:nth-child(5)) > li:nth-child(5) {
    grid-column: 1 / -1;
    width: calc(50% - 0.625rem);
    justify-self: center;
  }

  .story-phone-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .case-library__grid {
    grid-template-columns: 1fr;
  }

  .case-story-card {
    grid-template-columns: minmax(14rem, 0.85fr) minmax(0, 1.15fr);
    grid-template-rows: minmax(0, 1fr);
  }

  .case-story-card__image {
    min-height: 100%;
    aspect-ratio: auto;
  }

  .case-story-card__body {
    padding: clamp(1.5rem, 3vw, 2.25rem);
  }
}

@media (max-width: 760px) {
  .story-hero {
    padding-top: 7rem;
    padding-bottom: 3.5rem;
  }

  .story-hero__grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 2rem;
  }

  .story-hero__copy,
  .story-hero__media {
    grid-column: 1 / -1;
    padding-right: 0;
  }

  .story-hero__copy h1 {
    max-width: none;
    font-size: clamp(2.375rem, 8.6vw, 3.5rem);
  }

  .story-facts {
    margin-top: 2.5rem;
  }

  .story-facts {
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
    padding-top: 0.5rem;
  }

  .story-facts > div {
    display: grid;
    grid-template-columns: minmax(7rem, 0.85fr) minmax(0, 1.15fr);
    gap: 0.875rem;
    align-items: center;
    padding: 1rem 0;
    border-bottom: 1px solid var(--story-line);
  }

  .story-facts dt {
    font-size: clamp(1.75rem, 7vw, 2.5rem);
  }

  .story-facts dd {
    margin: 0;
    font-size: 0.875rem;
  }

  .story-section {
    padding-block: 4.25rem;
  }

  .story-heading {
    margin-bottom: 2rem;
  }

  .story-split {
    grid-template-columns: minmax(0, 1fr);
    gap: 2rem;
  }

  .story-copy,
  .story-visual,
  .story-gallery {
    grid-column: 1 / -1;
  }

  .story-pair,
  .story-gallery {
    grid-template-columns: minmax(0, 1fr);
  }

  .story-pair .story-figure > a {
    min-height: 0;
  }

  .story-pair .story-figure img {
    max-height: 34rem;
  }

  .story-phone-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .story-path {
    grid-template-columns: minmax(0, 1fr);
    gap: 0.5rem;
  }

  .story-path:has(> li:nth-child(4)):not(:has(> li:nth-child(5))) {
    grid-template-columns: minmax(0, 1fr);
  }

  .story-path:has(> li:nth-child(5)) > li:nth-child(4),
  .story-path:has(> li:nth-child(5)) > li:nth-child(5) {
    grid-column: auto;
    width: auto;
    justify-self: stretch;
  }

  .story-path li {
    padding: 1.125rem 0.75rem 1.25rem;
  }

  .story-step {
    margin-bottom: 0.75rem;
  }

  dl.story-results {
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
  }

  dl.story-results:not(:has(> div:nth-child(3))) {
    grid-template-columns: minmax(0, 1fr);
  }

  dl.story-results > div {
    padding: 1.125rem 0;
    border-bottom: 1px solid var(--story-line);
  }

  .story-chart__row {
    grid-template-columns: minmax(6rem, 1fr) auto;
  }

  .story-chart__row i {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .story-ledger {
    grid-template-columns: minmax(0, 1fr);
  }

  .story-ledger figure {
    justify-self: start;
  }

  .story-cta {
    padding-block: 4.5rem;
  }

  .story-cta__actions {
    gap: 0.5rem 1rem;
  }

  .case-library {
    padding-top: 7rem;
  }

  .case-story-card {
    grid-template-columns: minmax(12rem, 0.8fr) minmax(0, 1.2fr);
  }
}

@media (max-width: 600px) {
  .story-hero .breadcrumbs {
    margin-bottom: 1.5rem;
  }

  .story-hero__copy h1 {
    font-size: clamp(2.25rem, 9vw, 2.75rem);
  }

  .story-tags {
    gap: 0.5rem;
  }

  .story-tags span {
    min-height: 1.875rem;
    padding-inline: 0.625rem;
  }

  .story-nav {
    justify-content: flex-start;
    gap: 0.5rem 1rem;
  }

  .story-facts > div {
    grid-template-columns: minmax(0, 1fr);
    gap: 0.375rem;
    align-items: start;
  }

  .story-facts dd {
    font-size: 1rem;
  }

  .story-heading h2,
  .story-copy h2 {
    font-size: clamp(1.875rem, 8vw, 2.5rem);
  }

  .story-phone-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .story-chart {
    padding: 1.125rem;
  }

  .story-chart__row {
    gap: 0.625rem;
  }

  .story-chart__row > span {
    font-size: 0.8125rem;
  }

  .story-chart__row strong {
    font-size: 0.9375rem;
  }

  .story-cta__actions {
    flex-direction: column;
    align-items: center;
  }

  .case-story-card {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto 1fr;
  }

  .case-story-card__image {
    min-height: 0;
    aspect-ratio: 16 / 10;
  }

  .case-story-card__body {
    padding: 1.25rem;
  }

  .case-story-card__body h2 {
    min-height: 0;
    font-size: 1.5625rem;
  }
}

@media (max-width: 360px) {
  .story-facts > div {
    gap: 0.375rem;
  }

  .story-facts dt {
    font-size: 1.625rem;
  }

  .story-facts dd {
    font-size: 0.8125rem;
  }

  .story-chart__row {
    grid-template-columns: minmax(0, 1fr) auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  .story-nav a,
  .story-related a,
  .case-story-card,
  .case-story-card__link {
    transition: none;
  }

  .case-story-card:hover {
    transform: none;
  }
}
