/*
 * The case study story layout (site/snippets/casestudy/story.php and
 * story-hero.php, the blocks chapter, stickyscreen, wall, feature, phonerow,
 * designboard, dials and beforeafterslider; docs/design/components.md, "Case
 * study story layout"). Linked only where its markup is on the page
 * (peanut_scoped_css(), prefix cst-), so a study without the Story layout
 * switch loads nothing new.
 *
 * Every class here is cst-*. The device frames are the case study page's own
 * (.cs-frame, casestudy.css, which comes later in the same layer: a rule that
 * changes a frame names two classes). Colors, type, spacing and radii come
 * from tokens.css; the one exception is content: a design board swatch takes
 * its color from the Panel as an inline style.
 *
 * Rule for every capture: never shrunk to fit a box. It takes its frame's
 * width, keeps its height, and the frame crops it from the top.
 *
 * Motion: none in CSS beyond the sticky frame's fade. Everything is visible
 * and readable as printed (no JavaScript, ?fx=off, reduced motion, print):
 * the windows scroll by hand. public/assets/js/cs-story.js adds .is-live
 * where motion is allowed and moves the captures with transforms only.
 */

@layer templates {
  /* ---------- Hero composition: title, promise, chips, then the browser window with the phone on its corner ---------- */

  .cst-hero__inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-5);
  }

  .cst-hero__head {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-3);
  }

  .cst-hero__lead > *,
  .cst-hero__side > * {
    margin: 0;
  }

  .cst-hero__lead > * + * {
    margin-top: var(--space-3);
  }

  .cst-hero .cst-hero__title {
    font-size: clamp(2.75rem, 1.2rem + 6.6vw, 6.5rem);
    line-height: 1;
  }

  .cst-hero__side {
    display: grid;
    gap: var(--space-3);
  }

  .cst-hero__line {
    max-width: 32ch;
    font-family: var(--font-heading);
    font-size: var(--step-2);
    font-weight: var(--weight-heading-sm);
    line-height: 1.35;
  }

  .cst-hero__actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--space-2) var(--space-4);
  }

  .cst-hero__actions > * {
    margin: 0;
  }

  /* Three number chips: a hairline over the row and between the cells */
  .cst-chips {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    padding: 0;
    border-top: 1px solid var(--color-on-ink-line);
    list-style: none;
  }

  .cst-chips__item {
    display: grid;
    align-content: start;
    gap: 0.35rem;
    padding: var(--space-2) var(--space-2) 0 0;
  }

  .cst-chips__item + .cst-chips__item {
    padding-inline-start: var(--space-2);
    border-inline-start: 1px solid var(--color-on-ink-line);
  }

  .cst-chips__figure {
    font-family: var(--font-heading);
    font-size: clamp(2rem, 1.4rem + 2.6vw, 3.25rem);
    font-weight: var(--weight-display);
    line-height: 1;
  }

  .cst-chips__label {
    color: var(--color-on-ink-text-strong);
    font-size: 0.6875rem;
    font-weight: 500;
    letter-spacing: var(--tracking-caps);
    line-height: 1.4;
    text-transform: uppercase;
  }

  .cst-hero .cst-hero__media {
    position: relative;
    justify-self: center;
    max-width: min(100%, var(--shot-max));
  }

  /* room for the phone, which hangs below the browser window */
  .cst-hero__media--phone {
    padding-bottom: var(--space-4);
  }

  .cst-hero .cst-hero__browser.cs-frame--browser .cs-frame__screen {
    aspect-ratio: 16 / 9;
  }

  .cst-hero .cst-hero__phone {
    position: absolute;
    right: 4%;
    bottom: 0;
    width: clamp(6.5rem, 15vw, 12rem);
    padding: 0.3rem;
    border-radius: 1.4rem;
  }

  .cst-hero .cst-hero__phone .cs-frame__screen {
    border-radius: 1.1rem;
  }

  @media (min-width: 64rem) {
    .cst-hero__head {
      grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
      gap: var(--space-6);
      align-items: end;
    }

    .cst-hero__media--phone {
      padding-bottom: var(--space-6);
    }

    .cst-hero .cst-hero__phone {
      padding: 0.5rem;
      border-radius: 2.1rem;
    }

    .cst-hero .cst-hero__phone .cs-frame__screen {
      border-radius: 1.65rem;
    }
  }

  /* ---------- Sections of the story ---------- */

  .cst-section__inner > * + * {
    margin-top: var(--space-6);
  }

  /* the shared blocks (text, quote, timeline, data strip, diagram, exchange) in the story column */
  .cst-run {
    max-width: 52rem;
    margin-inline: auto;
  }

  /* The foot line: one small line of dates and sources under the story */
  .cst-footline {
    padding-block: var(--space-3);
    border-top: 1px solid var(--color-ink-line-faint);
    background: var(--color-paper);
  }

  .cst-footline__text {
    max-width: 60rem;
    margin: 0;
    font-size: var(--step--1);
    line-height: 1.6;
  }

  /* ---------- Chapter: the head on one side, the text on the other ---------- */

  .cst-chapter {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-4);
  }

  .cst-chapter__head > * {
    margin: 0;
  }

  .cst-chapter__head > * + * {
    margin-top: var(--space-3);
  }

  .cst-chapter__title {
    font-size: var(--step-6);
    font-weight: var(--weight-display);
    line-height: var(--leading-tight);
  }

  .cst-chapter__text {
    max-width: var(--measure);
  }

  /* the first paragraph reads as the chapter's lede */
  .cst-chapter__text > p:first-child {
    font-family: var(--font-heading);
    font-size: var(--step-2);
    font-weight: var(--weight-heading-sm);
    line-height: 1.4;
  }

  @media (min-width: 64rem) {
    .cst-chapter {
      grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
      gap: var(--space-6);
      align-items: start;
    }

    .cst-chapter--solo {
      grid-template-columns: minmax(0, 1fr);
    }

    .cst-chapter--solo .cst-chapter__head {
      max-width: 48rem;
    }
  }

  /* ---------- Captures and their windows ---------- */

  .cst-cap__img {
    display: block;
    width: 100%;
    height: auto;
  }

  .cst-frame {
    margin-inline: auto;
  }

  /* A window onto the page: it scrolls by hand as printed; a driven window
     (.is-live, cs-story.js) is moved by a transform and holds no scroll */
  .cst-screen {
    overflow-x: hidden;
    overflow-y: auto;
    scrollbar-color: var(--color-ink-track) transparent;
    scrollbar-width: thin;
  }

  .cst-screen:focus-visible {
    outline: 3px solid var(--focus-ring);
    outline-offset: -3px;
  }

  .cst-screen.is-live {
    overflow: hidden;
  }

  .cst-screen.is-live .cst-cap {
    will-change: transform;
  }

  .cst-caption {
    margin-top: var(--space-2);
    font-size: var(--step--1);
    line-height: 1.5;
    text-align: center;
  }

  .cst-source {
    margin: 0;
    font-size: var(--step--1);
    line-height: 1.5;
  }

  /* ---------- Sticky screen ---------- */

  .cst-sticky {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-6);
  }

  .cst-sticky__item {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-4);
  }

  .cst-sticky__figure {
    min-width: 0;
    margin: 0;
  }

  .cst-sticky__text {
    max-width: var(--measure);
  }

  .cst-sticky__text > * {
    margin: 0;
  }

  .cst-sticky__text > * + * {
    margin-top: var(--space-2);
  }

  .cst-sticky__step {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-family: var(--font-heading);
    font-size: var(--step-1);
    font-style: italic;
    font-weight: var(--weight-display);
  }

  .cst-sticky__step::after {
    content: "";
    width: 3rem;
    height: 1px;
    background: currentColor;
  }

  .cst-sticky__title {
    font-size: var(--step-4);
    font-weight: var(--weight-display);
    line-height: var(--leading-heading);
  }

  @media (min-width: 64rem) {
    /* as printed: each frame beside its own text, sticking while the text passes */
    .cst-sticky__item {
      grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
      gap: var(--space-6);
      align-items: start;
    }

    .cst-sticky__item--text {
      grid-template-columns: minmax(0, 1fr);
    }

    .cst-sticky__text {
      grid-column: 1;
      grid-row: 1;
    }

    .cst-sticky__figure {
      position: sticky;
      top: calc(var(--header-height) + var(--space-3));
      grid-column: 2;
      grid-row: 1;
    }

    /* live: one frame for the whole block. The items dissolve into one grid:
       the texts run down the first column, every frame takes the same sticky
       place in the second, and only the current part's frame shows */
    .cst-sticky.is-live {
      grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
      gap: 0 var(--space-6);
    }

    .cst-sticky.is-live .cst-sticky__item {
      display: contents;
    }

    .cst-sticky.is-live .cst-sticky__text {
      display: flex;
      flex-direction: column;
      justify-content: center;
      grid-row: var(--cst-i);
      min-height: 72vh;
    }

    .cst-sticky.is-live .cst-sticky__figure {
      top: max(calc(var(--header-height) + var(--space-3)), calc(50vh - 17rem));
      grid-row: 1 / span var(--cst-n);
      align-self: start;
      visibility: hidden;
      opacity: 0;
      transition: opacity var(--duration) var(--ease), visibility 0s linear var(--duration);
    }

    .cst-sticky.is-live .cst-sticky__figure.is-current {
      visibility: visible;
      opacity: 1;
      transition-delay: 0s;
    }
  }

  /* ---------- Wall of pages: columns of captures fading into the ink band, one number over the fade ---------- */

  .cst-wall.section {
    padding-block: var(--space-5) var(--section-pad);
    overflow: hidden;
  }

  .cst-wall__cols {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: var(--space-2);
    height: clamp(26rem, 80vh, 46rem);
    overflow: hidden;
    mask-image:
      linear-gradient(to bottom, var(--color-mask-opaque) 0, var(--color-mask-opaque) 40%, transparent 88%),
      linear-gradient(to right, transparent 0, var(--color-mask-opaque) 7%, var(--color-mask-opaque) 93%, transparent 100%);
    mask-composite: intersect;
  }

  .cst-wall__col {
    flex: none;
    width: clamp(11rem, 23vw, 22rem);
    overflow: hidden;
    border: 1px solid var(--color-on-ink-line);
    border-radius: var(--radius-sm);
    background: var(--color-white);
  }

  .cst-wall__col:nth-child(even) {
    margin-top: var(--space-5);
  }

  .cst-wall__col:nth-child(3n) {
    margin-top: var(--space-3);
  }

  .cst-wall__over {
    position: relative;
    margin-top: -7rem;
    text-align: center;
  }

  .cst-wall__claim {
    display: grid;
    justify-items: center;
    gap: var(--space-2);
    margin: 0;
  }

  .cst-wall__number {
    font-family: var(--font-heading);
    font-size: clamp(6rem, 3rem + 14vw, 13rem);
    font-weight: var(--weight-display);
    line-height: 0.85;
  }

  .cst-wall__label {
    max-width: 24ch;
    font-family: var(--font-heading);
    font-size: var(--step-3);
    font-weight: var(--weight-heading-sm);
    line-height: 1.3;
  }

  /* ---------- Page feature: one page on a color band, callouts at their heights ---------- */

  .cst-feature {
    position: relative;
    color: var(--color-ink);
  }

  .cst-feature--mint {
    background: var(--color-brand);
  }

  .cst-feature--coral {
    background: var(--color-accent-2);
  }

  /* Satin Gold with its grain, like printed paper */
  .cst-feature--gold {
    background: var(--gradient-satin-gold);
  }

  .cst-feature--gold::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: var(--grain);
    opacity: var(--grain-opacity);
    mix-blend-mode: multiply;
    pointer-events: none;
  }

  @media (prefers-reduced-transparency: reduce) {
    .cst-feature--gold::before {
      content: none;
    }
  }

  .cst-feature__inner {
    position: relative;
  }

  .cst-feature__title {
    max-width: 24ch;
    margin: 0 0 var(--space-4);
    font-size: var(--step-5);
    font-weight: var(--weight-display);
    line-height: var(--leading-tight);
  }

  .cst-feature__stage {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-4);
  }

  .cst-feature__figure {
    min-width: 0;
    margin: 0;
  }

  .cst-feature .cst-frame--browser .cs-frame__screen {
    aspect-ratio: 16 / 10;
  }

  .cst-feature__callouts {
    display: grid;
    gap: var(--space-3);
    margin: 0;
    padding: 0;
    list-style: none;
  }

  .cst-feature__callout {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: start;
    gap: var(--space-2);
  }

  .cst-feature__n {
    display: grid;
    place-items: center;
    width: 2rem;
    height: 2rem;
    border: var(--border);
    border-radius: 50%;
    background: var(--color-white);
    font-size: var(--step--1);
    font-weight: 600;
    line-height: 1;
  }

  .cst-feature__note {
    font-family: var(--font-heading);
    font-size: var(--step-1);
    font-weight: var(--weight-heading-sm);
    line-height: 1.4;
  }

  @media (min-width: 64rem) {
    .cst-feature__stage {
      grid-template-columns: minmax(0, 8fr) minmax(0, 4fr);
      gap: var(--space-5);
    }

    .cst-feature--flip .cst-feature__stage {
      grid-template-columns: minmax(0, 4fr) minmax(0, 8fr);
    }

    .cst-feature--flip .cst-feature__figure {
      order: 2;
    }

    .cst-feature .cst-feature__stage--solo {
      grid-template-columns: minmax(0, 1fr);
    }

    .cst-feature__stage--solo .cst-feature__figure {
      width: min(100%, 60rem);
      margin-inline: auto;
    }

    /* each callout at its height beside the window, a 1px line reaching the frame */
    .cst-feature__callouts {
      display: block;
      position: relative;
    }

    .cst-feature__callout {
      position: absolute;
      top: var(--cst-top);
      right: 0;
      left: 0;
      transform: translateY(-50%);
    }

    .cst-feature__callout::before {
      content: "";
      position: absolute;
      top: 1rem;
      right: 100%;
      width: var(--space-5);
      height: 1px;
      background: var(--color-ink);
    }

    .cst-feature--flip .cst-feature__callout::before {
      right: auto;
      left: 100%;
    }
  }

  /* ---------- Phone row: three phones at staggered heights; a swipe row on phones ---------- */

  .cst-phones {
    display: flex;
    gap: var(--space-3);
    margin-inline: calc(var(--gutter) * -1);
    padding: var(--space-1) var(--gutter) var(--space-2);
    overflow-x: auto;
    scroll-snap-type: x proximity;
    scrollbar-color: var(--color-ink-track) transparent;
    scrollbar-width: thin;
  }

  .cst-phones:focus-visible {
    outline: 3px solid var(--focus-ring);
    outline-offset: -3px;
  }

  .cst-phones__item {
    flex: none;
    width: 14rem;
    margin: 0;
    scroll-snap-align: center;
  }

  .cst-phones .cst-frame--phone {
    width: 100%;
  }

  @media (min-width: 48rem) {
    .cst-phones {
      justify-content: center;
      gap: var(--space-4);
      margin-inline: 0;
      padding-inline: 0;
      overflow: visible;
    }

    .cst-phones__item {
      width: min(14rem, 26vw);
    }

    .cst-phones__item:nth-child(2) {
      margin-top: var(--space-6);
    }

    .cst-phones__item:nth-child(3) {
      margin-top: var(--space-4);
    }
  }

  @media (min-width: 64rem) {
    .cst-phones {
      gap: var(--space-6);
    }
  }

  /* ---------- Design board: palette, type, parts on one panel ---------- */

  .cst-board {
    overflow: hidden;
    border: var(--border);
    border-radius: var(--radius-sm);
    background: var(--color-white);
  }

  .cst-board__row {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-3);
    padding: var(--space-3);
  }

  .cst-board__row + .cst-board__row {
    border-top: 1px solid var(--color-ink-line-faint);
  }

  .cst-board__label {
    margin: 0;
  }

  .cst-board__swatches,
  .cst-board__type,
  .cst-board__parts {
    display: grid;
    gap: var(--space-3);
    margin: 0;
    padding: 0;
    list-style: none;
  }

  .cst-board__swatches {
    grid-template-columns: repeat(auto-fill, minmax(6.5rem, 1fr));
    gap: var(--space-2);
  }

  .cst-board__swatch {
    display: grid;
    gap: 0.3rem;
  }

  /* the client's color: an inline background from the Panel */
  .cst-board__chip {
    display: block;
    aspect-ratio: 4 / 3;
    border: var(--border);
    border-radius: var(--radius-sm);
  }

  .cst-board__name {
    font-size: var(--step--1);
    font-weight: 500;
    line-height: 1.3;
  }

  .cst-board__hex {
    font-size: var(--step--1);
    font-variant-numeric: tabular-nums;
    letter-spacing: 0.04em;
    line-height: 1.3;
  }

  .cst-board__face {
    display: grid;
    align-content: start;
    gap: var(--space-2);
  }

  .cst-board__family {
    display: grid;
    gap: 0.25rem;
    margin: 0;
  }

  .cst-board__familyname {
    font-family: var(--font-heading);
    font-size: var(--step-3);
    font-weight: var(--weight-heading);
    line-height: var(--leading-heading);
  }

  /* the client's typeface, set live in the client's own words (family and weight inline, from the block) */
  .cst-board__specimen {
    margin: 0;
    padding: var(--space-3);
    border: var(--border);
    border-radius: var(--radius-sm);
    background: var(--color-white);
    overflow-wrap: break-word;
  }

  .cst-board__specimen--heading {
    font-size: clamp(1.75rem, 1.2rem + 2vw, 2.75rem);
    line-height: 1.1;
  }

  .cst-board__specimen--body {
    font-size: 1.125rem;
    line-height: 1.55;
  }

  .cst-board__meta {
    margin: 0;
    font-size: var(--step--1);
    line-height: 1.3;
  }

  .cst-board__shot {
    overflow: hidden;
    border: var(--border);
    border-radius: var(--radius-sm);
  }

  .cst-board__parts {
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 20rem), 1fr));
    align-items: start;
  }

  .cst-board__part--wide {
    grid-column: 1 / -1;
  }

  /* never wider than half the part's pixels (inline max-width), so it is always served at 2x */
  .cst-board__figure {
    margin: 0;
  }

  @media (min-width: 48rem) {
    .cst-board__type {
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: var(--space-4);
    }
  }

  @media (min-width: 64rem) {
    .cst-board__row {
      grid-template-columns: 9rem minmax(0, 1fr);
      gap: var(--space-5);
      padding: var(--space-4);
    }
  }

  /* ---------- Performance dials: phone and desktop side by side ---------- */

  .cst-dials {
    display: grid;
    gap: var(--space-4);
  }

  .cst-dials__panels {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-3);
  }

  .cst-dials__panel {
    display: grid;
    align-content: start;
    gap: var(--space-3);
    padding: var(--space-3);
    border: var(--border);
    border-radius: var(--radius-sm);
    background: var(--color-white);
  }

  .cst-dials__device {
    margin: 0;
  }

  /* centred rows: a card with fewer rings than its neighbour shows no empty slot */
  .cst-dials__list {
    --dial-gap: var(--space-2);
    --dial-cols: 2;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--space-3) var(--dial-gap);
    margin: 0;
    padding: 0;
    list-style: none;
  }

  .cst-dial {
    flex: 0 0 calc((100% - (var(--dial-cols) - 1) * var(--dial-gap)) / var(--dial-cols));
    display: grid;
    justify-items: center;
    align-content: start;
    gap: var(--space-1);
    text-align: center;
  }

  .cst-dial__ring {
    position: relative;
    display: block;
    width: min(100%, 7rem);
    aspect-ratio: 1;
  }

  .cst-dial__svg {
    display: block;
    width: 100%;
    height: 100%;
  }

  .cst-dial__disc {
    fill: var(--color-brand);
  }

  .cst-dial__track {
    fill: none;
    stroke: var(--color-ink-track);
    stroke-width: 4;
  }

  .cst-dial__arc {
    fill: none;
    stroke: var(--color-ink);
    stroke-linecap: round;
    stroke-width: 4;
  }

  .cst-dial__value {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    font-family: var(--font-heading);
    font-size: var(--step-4);
    font-weight: var(--weight-display);
    line-height: 1;
  }

  .cst-dial__label {
    font-size: var(--step--1);
    font-weight: 500;
    line-height: 1.3;
  }

  .cst-dial__range {
    display: block;
    font-weight: 400;
  }

  .cst-dials__facts {
    display: grid;
    gap: 0.5rem;
    margin: 0;
    padding-top: var(--space-2);
    border-top: 1px solid var(--color-ink-line-faint);
  }

  .cst-dials__fact {
    display: flex;
    justify-content: space-between;
    gap: var(--space-2);
    font-size: var(--step--1);
    line-height: 1.4;
  }

  .cst-dials__fact dt {
    font-weight: 500;
  }

  .cst-dials__fact dd {
    margin: 0;
    text-align: right;
  }

  .cst-dials__foot {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-3);
  }

  .cst-dials__note {
    margin: 0;
  }

  .cst-dials__quote {
    margin: 0 0 var(--space-2);
    font-family: var(--font-heading);
    font-size: var(--step-2);
    font-weight: var(--weight-heading-sm);
    line-height: 1.4;
  }

  .cst-dials__quote p {
    margin: 0;
  }

  @media (min-width: 48rem) {
    .cst-dials__panels {
      grid-template-columns: repeat(2, minmax(0, 1fr));
    }
  }

  @media (min-width: 64rem) {
    .cst-dials__panel {
      padding: var(--space-4);
    }

    .cst-dials__list {
      --dial-cols: 4;
    }

    .cst-dials__foot {
      grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
      gap: var(--space-6);
      align-items: end;
    }

    .cst-dials__foot .cst-source {
      text-align: right;
    }
  }

  /* ---------- Before and after slider: --split is set by cs-story.js ---------- */

  .cst-slider {
    --split: 50%;
    max-width: 60rem;
    margin: 0 auto;
  }

  .cst-slider__frame {
    position: relative;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    border: var(--border);
    border-radius: var(--radius-sm);
    background: var(--color-paper);
  }

  .cst-slider__side {
    position: absolute;
    inset: 0;
    overflow: hidden;
    background: var(--color-white);
  }

  .cst-slider__side--before {
    clip-path: inset(0 calc(100% - var(--split)) 0 0);
  }

  .cst-slider__handle {
    position: absolute;
    top: 0;
    bottom: 0;
    left: var(--split);
    width: 2px;
    margin-inline-start: -1px;
    background: var(--color-ink);
    pointer-events: none;
  }

  .cst-slider__handle::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 2.75rem;
    height: 2.75rem;
    margin: -1.375rem 0 0 -1.375rem;
    border: var(--border);
    border-radius: 50%;
    background: var(--color-white);
  }

  .cst-slider__range {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    opacity: 0;
    cursor: ew-resize;
  }

  .cst-slider__frame:has(.cst-slider__range:focus-visible) {
    outline: 3px solid var(--focus-ring);
    outline-offset: 3px;
  }

  .cst-slider__labels {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--space-3);
    margin-top: var(--space-2);
    font-size: var(--step--1);
    font-weight: 500;
    line-height: 1.4;
  }

  .cst-slider__label--after {
    text-align: right;
  }
}
