/* ============================================================
   Container — shared responsive layout constraint
   Provides 1024px max content width with responsive side padding.
   Import this in any component that uses the .container class.
   ============================================================ */

.container {
  position:   relative;
  width:      100%;
  max-width:  calc(1024px + 160px); /* 1024px content + 80px × 2 */
  padding:    0 80px;
  margin:     0 auto;
  box-sizing: border-box;
}

/* Tablet (≤991px): 60px sides */
@media (max-width: 991px) {
  .container {
    padding: 0 60px;
  }
}

/* Landscape mobile (≤767px): 2rem sides */
@media (max-width: 767px) {
  .container {
    padding: 0 2rem;
  }
}



/* ============================================================
   Wide container — 1360px content + 48px side padding
   Used for full-bleed section content blocks (slider, big cards)
   that need to be wider than the standard 1024px text container.
   ============================================================ */

.container-wide {
  width:      100%;
  max-width:  calc(1384px + 96px);   /* 1384px content + 48px × 2 */
  padding:    0 3rem;                /* 48px sides */
  margin:     0 auto;
  box-sizing: border-box;
}

/* Tablet (≤991px): 16px less than .container (60px → 44px) */
@media (max-width: 991px) {
  .container-wide {
    padding: 0 44px;
  }
}

/* Landscape mobile (≤767px): 16px less than .container (2rem → 1rem) */
@media (max-width: 767px) {
  .container-wide {
    padding: 0 1rem;
  }
}


/* ============================================================
   Button — Component Styles
   Scheme-aware: inherits data-scheme from a parent element.
   All color tokens flip automatically in dark context.
   ============================================================ */

.btn {
  /* Layout */
  align-items:      center;
  border:           1px solid transparent;
  box-sizing:       border-box;
  cursor:           pointer;
  display:          inline-flex;
  flex-shrink:      0;
  justify-content:  center;
  overflow:         hidden;
  text-decoration:  none;
  user-select:      none;
  white-space:      nowrap;
  background-clip:  padding-box;

  /* Typography */
  font-family: var(--font-family-default);
  font-weight: var(--font-weight-medium);

  /* Transition */
  transition: background-color 120ms ease, border-color 120ms ease, color 120ms ease, opacity 120ms ease;
}


/* ============================================================
   Sizes
   Heights: xs=26px  sm=32px  md=36px  lg=40px
   All use font-size-sm (14px) except xs which uses font-size-xs (12px).
   ============================================================ */

.btn[data-size="xs"] {
  font-size:   var(--font-size-xs);      /* 12px */
  line-height: var(--line-height-xs);    /* 16px */
  gap:         0.25rem;                  /* 4px  */
  padding:     0.3125rem 0.75rem;        /* 5px 12px → height 26px */
  --btn-gap:   0.25rem;
}

.btn[data-size="sm"] {
  font-size:   var(--font-size-sm);      /* 14px */
  line-height: var(--line-height-sm);    /* 20px */
  gap:         0.375rem;                 /* 6px  */
  padding:     0.375rem 1rem;            /* 6px 16px → height 32px */
  --btn-gap:   0.375rem;
}

.btn[data-size="md"] {
  font-size:   var(--font-size-sm);      /* 14px */
  line-height: var(--line-height-sm);    /* 20px */
  gap:         0.375rem;                 /* 6px  */
  padding:     0.5rem 1rem;              /* 8px 16px → height 36px */
  --btn-gap:   0.375rem;
}

.btn[data-size="lg"] {
  font-size:   var(--font-size-sm);      /* 14px */
  line-height: var(--line-height-sm);    /* 20px */
  gap:         0.5rem;                   /* 8px  */
  padding:     0.625rem 1.5rem;          /* 10px 24px → height 40px */
  --btn-gap:   0.5rem;
}

.btn[data-icon-only="true"] {
  padding: 0;
}

.btn[data-size="xs"][data-icon-only="true"] {
  width:  1.625rem; /* 26px */
  height: 1.625rem;
}

.btn[data-size="sm"][data-icon-only="true"] {
  width:  2rem; /* 32px */
  height: 2rem;
}

.btn[data-size="md"][data-icon-only="true"] {
  width:  2.25rem; /* 36px */
  height: 2.25rem;
}

.btn[data-size="lg"][data-icon-only="true"] {
  width:  2.5rem; /* 40px */
  height: 2.5rem;
}


/* ============================================================
   Shapes
   ============================================================ */

.btn[data-shape="rounded"] { border-radius: var(--radius-sm);   } /* 8px  */
.btn[data-shape="round"]   { border-radius: var(--radius-full); } /* pill */


/* ============================================================
   Variants
   ============================================================ */

.btn[data-variant="primary"][data-tone="default"] {
  background-color: var(--primary);
  border-color:     var(--primary);
  color:            var(--primary-foreground);
}

.btn[data-variant="secondary"][data-tone="default"] {
  background-color: transparent;
  border-color:     var(--primary);
  color:            var(--primary);
}

.btn[data-variant="primary"][data-tone="accent"] {
  background-color: var(--accent);
  border-color:     var(--accent);
  color:            var(--foreground);
}

.btn[data-variant="secondary"][data-tone="accent"] {
  background-color: transparent;
  border-color:     var(--accent);
  color:            var(--accent);
}


.btn[data-variant="info"] {
  background-color: var(--info);
  border-color:     var(--info);
  color:            var(--info-foreground);
}

.btn[data-variant="success"] {
  background-color: var(--success);
  border-color:     var(--success);
  color:            var(--success-foreground);
}

.btn[data-variant="warning"] {
  background-color: var(--warning);
  border-color:     var(--warning);
  color:            var(--warning-foreground);
}

.btn[data-variant="destructive"] {
  background-color: var(--destructive);
  border-color:     var(--destructive);
  color:            var(--destructive-foreground);
}


/* ============================================================
   States
   ============================================================ */

/* Primary hover — 20% dark overlay on background, full opacity */
.btn[data-variant="primary"][data-tone="default"]:hover:not(:disabled):not([aria-disabled="true"]) {
  background-color: color-mix(in srgb, var(--primary) 80%, #282825 20%);
  border-color:     color-mix(in srgb, var(--primary) 80%, #282825 20%);
  opacity:          1;
}

.btn[data-variant="primary"][data-tone="accent"]:hover:not(:disabled):not([aria-disabled="true"]) {
  background-color: color-mix(in srgb, var(--accent) 80%, transparent);
  border-color:     color-mix(in srgb, var(--accent) 80%, transparent);
  opacity:          1;
}

/* Secondary hover — darker primary border + text, no fill */
.btn[data-variant="secondary"][data-tone="default"]:hover:not(:disabled):not([aria-disabled="true"]) {
  border-color: color-mix(in srgb, var(--primary) 80%, #282825 20%);
  color:        color-mix(in srgb, var(--primary) 80%, #282825 20%);
  opacity:      1;
}

.btn[data-variant="secondary"][data-tone="accent"]:hover:not(:disabled):not([aria-disabled="true"]) {
  border-color: color-mix(in srgb, var(--accent) 80%, transparent);
  color:        color-mix(in srgb, var(--accent) 80%, transparent);
  opacity:      1;
}

.btn[data-variant="info"]:hover:not(:disabled):not([aria-disabled="true"]) {
  background-color: color-mix(in srgb, var(--info) 80%, #282825 20%);
  border-color:     color-mix(in srgb, var(--info) 80%, #282825 20%);
  color:            var(--info-foreground);
  opacity:          1;
}

.btn[data-variant="success"]:hover:not(:disabled):not([aria-disabled="true"]) {
  background-color: color-mix(in srgb, var(--success) 80%, #282825 20%);
  border-color:     color-mix(in srgb, var(--success) 80%, #282825 20%);
  color:            var(--success-foreground);
  opacity:          1;
}

.btn[data-variant="warning"]:hover:not(:disabled):not([aria-disabled="true"]) {
  background-color: color-mix(in srgb, var(--warning) 80%, #282825 20%);
  border-color:     color-mix(in srgb, var(--warning) 80%, #282825 20%);
  color:            var(--warning-foreground);
  opacity:          1;
}

.btn[data-variant="destructive"]:hover:not(:disabled):not([aria-disabled="true"]) {
  background-color: color-mix(in srgb, var(--destructive) 80%, #282825 20%);
  border-color:     color-mix(in srgb, var(--destructive) 80%, #282825 20%);
  color:            var(--destructive-foreground);
  opacity:          1;
}

/* Active / pressed */
.btn:active:not(:disabled):not([aria-disabled="true"]) {
  opacity: 0.76;
}

/* Focus */
.btn:focus-visible {
  outline:        2px solid var(--ring);
  outline-offset: 2px;
}

/* Disabled */
.btn:disabled,
.btn[aria-disabled="true"] {
  cursor:         not-allowed;
  opacity:        0.4;
  pointer-events: none;
}


/* ============================================================
   Icon slot
   ============================================================ */

.btn__icon {
  align-items:     center;
  display:         inline-flex;
  flex-shrink:     0;
  justify-content: center;
}

.btn[data-size="xs"] .btn__icon:not(.btn__icon--hover-only) { height: 0.75rem; width: 0.75rem; } /* 12px */
.btn[data-size="sm"] .btn__icon:not(.btn__icon--hover-only),
.btn[data-size="md"] .btn__icon:not(.btn__icon--hover-only),
.btn[data-size="lg"] .btn__icon:not(.btn__icon--hover-only) { height: 1rem;    width: 1rem;    } /* 16px */

.btn__icon svg {
  display: block;
  height:  100%;
  width:   100%;
}


/* ============================================================
   Hover-only icon — hidden by default, slides/fades in on :hover.
   Negative margin-right cancels the flex gap when collapsed so
   the label stays flush with the padding edge.
   ============================================================ */

/* Must come after the .btn[data-size] .btn__icon rules to win specificity tie */
.btn .btn__icon--hover-only {
  min-width:    0;        /* override flex min-width: auto so item can truly collapse */
  width:        0;
  overflow:     hidden;
  opacity:      0;
  margin-right: calc(-1 * var(--btn-gap, 0.5rem));
  transition:   width 0.2s ease, opacity 0.15s ease, margin-right 0.2s ease;
}

.btn:hover:not(:disabled):not([aria-disabled="true"]) .btn__icon--hover-only {
  width:        1rem; /* sm / md / lg */
  height:       1rem;
  opacity:      1;
  margin-right: 0;
}

.btn[data-size="xs"]:hover:not(:disabled):not([aria-disabled="true"]) .btn__icon--hover-only {
  width:  0.75rem;
  height: 0.75rem;
}


/* ============================================================
   Badge slot — optional count pill inside the button
   ============================================================ */

.btn__badge {
  align-items:      center;
  background-color: var(--primary);
  border-radius:    var(--radius-full);
  color:            var(--primary-foreground);
  display:          inline-flex;
  font-size:        var(--font-size-xs);   /* 12px */
  font-weight:      var(--font-weight-medium);
  justify-content:  center;
  line-height:      var(--line-height-xs); /* 16px */
  min-width:        1.25rem;               /* 20px */
  padding:          0.125rem 0.375rem;     /* 2px 6px */
}

/* ============================================================
   G2BadgeRow — Horizontal row of G2 badge images.
   Desktop: static flex row.
   Mobile (≤520px): infinite auto-scroll strip with touch drag,
   driven by JS in G2BadgeRow.tsx.
   ============================================================ */

.g2-badge-row {
  display:        flex;
  flex-direction: column;
  gap:            2rem;   /* divider → badges */
  /* Count-derived cap (set inline in G2BadgeRow.tsx) so no badge exceeds 115px. */
  max-width:      var(--g2-row-max-width, none);
}

.g2-badge-row__divider {
  width:      100%;
  border-top: 1px solid var(--divider);
}

.g2-badge-row__strip {
  mix-blend-mode: multiply;
}

.g2-badge-row__track {
  display:     flex;
  gap:         var(--spacing-3);   /* 12px */
  align-items: center;
  flex-wrap:   nowrap;
}

.g2-badge-row__clone {
  display: none;
}

.g2-badge-row__badge {
  flex:      1 1 60px;
  min-width: 0;
  height:    auto;
}


/* ============================================================
   Mobile scroll strip (≤520px)
   STANDARD: when the row becomes a scroll strip it MUST run full-bleed
   (edge-to-edge, full viewport width) — same as HomepageHero. The primitive
   can't know the caller's padding, so every consumer is responsible for the
   bleed: add negative margins equal to the container's horizontal padding on
   the wrapper around <G2BadgeRow> at ≤520px (e.g. HomepageHero & AirHeroSection
   use `margin: 0 -2rem`). See docs/conventions.md.
   ============================================================ */

@media (max-width: 520px) {
  /* Drop the badge-width cap so the marquee strip stays full-bleed. */
  .g2-badge-row {
    max-width: none;
  }

  .g2-badge-row__strip {
    overflow: hidden;
  }

  .g2-badge-row__track {
    gap:         0;
    will-change: transform;
  }

  /* Each badge owns its trailing gap — both halves equal width → seamless loop */
  .g2-badge-row__badge {
    flex:         none;
    width:        60px;
    margin-right: var(--spacing-3);   /* 12px — must match SET_WIDTH calc in G2BadgeRow.tsx */
  }

  .g2-badge-row__clone {
    display: contents;
  }
}

/* ============================================================
   ArrowLink — see ArrowLink.tsx. Colour, hover and focus come from
   the shared `.text-link` (section.css); type size from the consumer.
   ============================================================ */

/* Plain inline text, so a long label wraps like any sentence. */
.arrow-link {
  display: inline;
}

/* The last word + the arrow never break apart. */
.arrow-link__tail {
  white-space: nowrap;
}

.arrow-link__icon {
  display:        inline-block;
  margin-left:    var(--spacing-2);             /* 8px, the shared arrow gap */
  vertical-align: -0.125em;
}

.arrow-link__sr-only {
  position:    absolute;
  width:       1px;
  height:      1px;
  margin:      -1px;
  padding:     0;
  overflow:    hidden;
  clip:        rect(0 0 0 0);
  white-space: nowrap;
  border:      0;
}

/* ============================================================
   VideoPlayer — 24px frame with a floating pill control bar.

   Contrast choices, measured on the light scheme:
     - The start label sits on a white pill, not on --primary: cream on
       --primary is 4.45:1, just short of AA for 16px text.
     - Focus rings use --primary, not the usual --ring: --ring on white is
       2.3:1, under the 3:1 a focus indicator needs.
     - The time readout uses --foreground: --muted-foreground is 3.7:1 on white.
   ============================================================ */

.video-player {
  position:         relative;
  container-type:   inline-size;
  width:            100%;
  /* `aspectRatio` prop; 16:9 when unset. */
  aspect-ratio:     var(--video-player-aspect, 16 / 9);
  overflow:         hidden;
  border-radius:    var(--radius-lg);
  background-color: var(--muted);
  box-shadow:       var(--shadow-lg);
  font-family:      var(--font-family-default);
  isolation:        isolate;
  -webkit-user-select: none;
  user-select:         none;
  --video-player-thumb: 0.875rem;
}

.video-player[data-controls="hidden"] {
  cursor: none;
}

.video-player:fullscreen {
  width:            100%;
  height:           100%;
  aspect-ratio:     auto;
  border-radius:    0;
  background-color: var(--video-player-backdrop, var(--color-brand-neutral-950));
}

.video-player__media,
.video-player__poster {
  position:   absolute;
  inset:      0;
  display:    block;
  width:      100%;
  height:     100%;
  object-fit: contain;
}

.video-player__media {
  /* No double-tap zoom, which would swallow double-tap-to-skip. Panning stays,
     so a swipe that starts on the video still scrolls the page. */
  touch-action:          manipulation;
  -webkit-touch-callout: none;
}

.video-player__poster {
  object-fit:     cover;
  pointer-events: none;
}


/* ----------------------------------------------------------
   Start — the whole frame is the button, the pill is its face.
   ---------------------------------------------------------- */

.video-player__start {
  position:        absolute;
  inset:           0;
  display:         flex;
  align-items:     flex-end;
  justify-content: center;
  /* Below the poster's tagline, which ends at about 66% of the frame's height. */
  padding:         0 0 clamp(1rem, 7cqi, 5rem);
  border:          0;
  background:      none;
  color:           inherit;
  font:            inherit;
  cursor:          pointer;
}

/* Inert and unchanged until hydrated — no spinner, no dimming, nothing that
   suggests it can be pressed. DemoPlayer.audio-notes.md §5. */
.video-player__start:disabled {
  pointer-events: none;
  cursor:         default;
}

.video-player__start-pill {
  display:          inline-flex;
  align-items:      center;
  gap:              var(--spacing-3);
  padding:          var(--spacing-2) var(--spacing-5) var(--spacing-2) var(--spacing-2);
  border-radius:    var(--radius-full);
  background-color: var(--card);
  color:            var(--card-foreground);
  box-shadow:       var(--shadow-xl);
  transition:       transform 0.15s ease;
}

/* Hover: the pill grows a touch and stays white. A cream (#FAF6F0) fill was
   tried on 2026-11-19 and taken out the same day (owner). */
.video-player__start:not(:disabled):hover .video-player__start-pill {
  transform: scale(1.03);
}

.video-player__start:not(:disabled):active .video-player__start-pill {
  transform: scale(0.98);
}

.video-player__start:focus-visible {
  outline: none;
}

.video-player__start:focus-visible .video-player__start-pill {
  outline:        2px solid var(--primary);
  outline-offset: 3px;
}

.video-player__start-icon {
  display:          inline-flex;
  align-items:      center;
  justify-content:  center;
  width:            2.75rem;
  height:           2.75rem;
  border-radius:    var(--radius-full);
  background-color: var(--primary);
  color:            var(--primary-foreground);
}

.video-player__start-label {
  font-size:   var(--font-size-base);
  line-height: var(--line-height-base);
  font-weight: 600;
  white-space: nowrap;
}

/* `startPosition="center"` — the pill in the middle of the poster, scaled with
   the frame. Figma (Legal Hub hero video, 627:7221) draws it on a 504px panel
   and scales the whole visual to 591, so every size here is its 504px value in
   `cqi` (value / 504 × 100), floored at that same value: it grows with a wider
   frame and never shrinks below the design on a phone.
   504px values: 8 / 24 / 8 / 8 inset, 10 gap, 44 circle, 20 glyph, 18/28 bold. */
.video-player[data-start="center"] .video-player__start {
  align-items: center;
  padding:     0;
}

.video-player[data-start="center"] .video-player__start-pill {
  gap:        max(0.625rem, 1.984cqi);
  padding:    max(0.5rem, 1.587cqi) max(1.5rem, 4.762cqi) max(0.5rem, 1.587cqi) max(0.5rem, 1.587cqi);
  box-shadow: var(--shadow-lg);
}

.video-player[data-start="center"] .video-player__start-icon {
  width:  max(2.75rem, 8.73cqi);
  height: max(2.75rem, 8.73cqi);
}

.video-player[data-start="center"] .video-player__start-icon .video-player__glyph {
  width:  max(1.25rem, 3.968cqi);
  height: max(1.25rem, 3.968cqi);
}

.video-player[data-start="center"] .video-player__start-label {
  font-size:   max(1.125rem, 3.571cqi);
  line-height: max(1.75rem, 5.556cqi);
  font-weight: var(--font-weight-bold);
}


/* ----------------------------------------------------------
   Control bar
   ---------------------------------------------------------- */

.video-player__bar {
  position:         absolute;
  right:            var(--spacing-3);
  bottom:           var(--spacing-3);
  left:             var(--spacing-3);
  display:          flex;
  align-items:      center;
  gap:              var(--spacing-2);
  padding:          var(--spacing-1);
  border-radius:    var(--radius-full);
  background-color: var(--card);
  color:            var(--card-foreground);
  box-shadow:       var(--shadow-xl);
  transition:       opacity 0.2s ease, transform 0.2s ease;
}

/* Hidden by opacity, never `visibility`: the controls must stay in the tab
   order or a keyboard user could not reach them while the video plays. Focus
   doesn't hold the bar up, or one press of K would pin it for good: any key, or
   focus arriving from outside, wakes it instead. `:active` covers a thumb held
   still mid-drag. */
.video-player[data-controls="hidden"] .video-player__bar:not(:active) {
  opacity:        0;
  transform:      translateY(0.5rem);
  pointer-events: none;
}

/* Gated, because a tap leaves :hover stuck on touch screens. */
@media (hover: hover) {
  .video-player[data-controls="hidden"] .video-player__bar:hover {
    opacity:        1;
    transform:      none;
    pointer-events: auto;
  }
}

.video-player__btn {
  flex:             none;
  display:          inline-flex;
  align-items:      center;
  justify-content:  center;
  width:            2.5rem;
  height:           2.5rem;
  padding:          0;
  border:           0;
  border-radius:    var(--radius-full);
  background-color: transparent;
  color:            inherit;
  cursor:           pointer;
  transition:       background-color 0.15s ease;
}

.video-player__btn:hover {
  background-color: var(--accent);
}

.video-player__btn--toggle,
.video-player__btn--toggle:hover {
  background-color: var(--primary);
  color:            var(--primary-foreground);
}

.video-player__btn[aria-pressed="true"] {
  color: var(--primary);
}

.video-player__btn:focus-visible,
.video-player__range:focus-visible,
.video-player__error-retry:focus-visible {
  outline:        2px solid var(--primary);
  outline-offset: 2px;
}

.video-player__glyph {
  display: block;
  width:   1.5rem;
  height:  1.5rem;
}

.video-player__time {
  flex:                 none;
  padding-inline:       var(--spacing-1);
  font-size:            var(--font-size-sm);
  line-height:          var(--line-height-sm);
  font-variant-numeric: tabular-nums;
  white-space:          nowrap;
}

/* A fixed slot: the brand font has no tabular figures, so tabular-nums does
   nothing and each tick would resize the readout and shove the seek bar sideways. */
.video-player__time-current {
  display:    inline-block;
  min-width:  2.5em;
  text-align: end;
}


/* ----------------------------------------------------------
   Sliders — native range inputs, so keyboard, touch and screen
   reader support comes from the browser. The fill is painted on
   the input itself, which styles every engine at once; the track
   pseudo-elements stay transparent.

   Seek draws its own fill and thumb under a see-through input.
   Both follow --video-player-progress (0 to 1), so they move
   together, and as transforms they move in fractions of a pixel;
   a native thumb snaps to whole ones. The input overhangs by half
   a thumb, which puts its invisible thumb exactly under the drawn
   one, so a click lands where it looks like it should.
   ---------------------------------------------------------- */

.video-player__seek {
  position:      relative;
  flex:          1 1 auto;
  min-width:     0;
  height:        1.5rem;
  margin-inline: calc(var(--video-player-thumb) / 2);
}

.video-player__seek-track {
  position:         absolute;
  top:              50%;
  right:            0;
  left:             0;
  height:           0.375rem;
  overflow:         hidden;
  border-radius:    var(--radius-full);
  background-color: var(--border);
  transform:        translateY(-50%);
}

.video-player__seek-fill {
  display:          block;
  height:           100%;
  background-color: var(--primary);
  transform:        scaleX(var(--video-player-progress, 0));
  transform-origin: left;
  will-change:      transform;
}

.video-player__seek-thumb {
  position:       absolute;
  inset:          0;
  pointer-events: none;
  transform:      translateX(calc(var(--video-player-progress, 0) * 100%));
  will-change:    transform;
}

.video-player__seek-thumb::after {
  content:          "";
  position:         absolute;
  top:              50%;
  left:             calc(var(--video-player-thumb) / -2);
  width:            var(--video-player-thumb);
  height:           var(--video-player-thumb);
  border-radius:    var(--radius-full);
  background-color: var(--primary);
  transform:        translateY(-50%);
}

.video-player__range {
  flex:               1 1 auto;
  min-width:          0;
  height:             1.5rem;
  margin:             0;
  border-radius:      var(--radius-full);
  background:
    linear-gradient(
      to right,
      var(--primary) 0 calc(
        var(--video-player-thumb) / 2 + (100% - var(--video-player-thumb)) * var(--video-player-level, 0)
      ),
      var(--border)  0 100%
    ) center / 100% 0.375rem no-repeat;
  -webkit-appearance: none;
  appearance:         none;
  cursor:             pointer;
}

.video-player__range--volume {
  flex:  none;
  width: 4.5rem;
}

.video-player__range--seek {
  position:   absolute;
  top:        0;
  left:       calc(var(--video-player-thumb) / -2);
  width:      calc(100% + var(--video-player-thumb));
  background: none;
}

.video-player__range::-webkit-slider-runnable-track {
  height:     100%;
  background: none;
}

.video-player__range::-moz-range-track {
  height:     100%;
  background: none;
}

.video-player__range::-webkit-slider-thumb {
  width:              var(--video-player-thumb);
  height:             var(--video-player-thumb);
  margin-top:         0.3125rem;
  border:             0;
  border-radius:      var(--radius-full);
  background-color:   var(--primary);
  -webkit-appearance: none;
  appearance:         none;
}

.video-player__range::-moz-range-thumb {
  width:            var(--video-player-thumb);
  height:           var(--video-player-thumb);
  border:           0;
  border-radius:    var(--radius-full);
  background-color: var(--primary);
}

.video-player__range--seek::-webkit-slider-thumb {
  background: none;
}

.video-player__range--seek::-moz-range-thumb {
  background: none;
}


/* ----------------------------------------------------------
   Overlays
   ---------------------------------------------------------- */

.video-player__buffering {
  position:         absolute;
  top:              50%;
  left:             50%;
  display:          flex;
  padding:          var(--spacing-2);
  border-radius:    var(--radius-full);
  background-color: var(--card);
  color:            var(--primary);
  box-shadow:       var(--shadow-xl);
  transform:        translate(-50%, -50%);
  pointer-events:   none;
}

.video-player__spinner {
  display:   block;
  width:     2rem;
  height:    2rem;
  animation: video-player-spin 0.8s linear infinite;
}

@keyframes video-player-spin {
  to { transform: rotate(360deg); }
}

.video-player__skip {
  position:         absolute;
  top:              0;
  bottom:           0;
  display:          flex;
  align-items:      center;
  justify-content:  center;
  width:            45%;
  background-color: color-mix(in srgb, var(--card-foreground) 14%, transparent);
  pointer-events:   none;
  animation:        video-player-fade-in 0.15s ease-out;
}

.video-player__skip[data-side="back"] {
  left:          0;
  border-radius: 0 40% 40% 0 / 0 50% 50% 0;
}

.video-player__skip[data-side="forward"] {
  right:         0;
  border-radius: 40% 0 0 40% / 50% 0 0 50%;
}

.video-player__skip[data-side="back"] .video-player__skip-chevrons {
  transform: scaleX(-1);
}

.video-player__speed {
  position:        absolute;
  top:             var(--spacing-3);
  right:           0;
  left:            0;
  display:         flex;
  justify-content: center;
  pointer-events:  none;
  animation:       video-player-fade-in 0.15s ease-out;
}

.video-player__badge {
  display:          inline-flex;
  align-items:      center;
  gap:              var(--spacing-2);
  padding:          var(--spacing-1) var(--spacing-3);
  border-radius:    var(--radius-full);
  background-color: var(--card);
  color:            var(--card-foreground);
  box-shadow:       var(--shadow-xl);
  font-size:        var(--font-size-sm);
  font-weight:      600;
  line-height:      var(--line-height-sm);
  white-space:      nowrap;
}

.video-player__skip-chevrons {
  display: inline-flex;
  color:   var(--primary);
}

.video-player__skip-chevrons svg {
  display:   block;
  width:     0.75rem;
  height:    0.75rem;
  opacity:   0.25;
  animation: video-player-chevron 0.6s linear infinite;
}

.video-player__skip-chevrons svg:nth-child(2) { animation-delay: 0.15s; }
.video-player__skip-chevrons svg:nth-child(3) { animation-delay: 0.3s; }

@keyframes video-player-fade-in {
  from { opacity: 0; }
}

@keyframes video-player-chevron {
  30% { opacity: 1; }
  60% { opacity: 0.25; }
}

.video-player__caption {
  position:       absolute;
  right:          var(--spacing-4);
  bottom:         var(--spacing-4);
  left:           var(--spacing-4);
  margin:         0;
  text-align:     center;
  pointer-events: none;
  transition:     bottom 0.2s ease;
}

/* Clear of the bar whenever it is up. */
.video-player[data-controls="visible"] .video-player__caption,
.video-player:has(.video-player__bar:hover) .video-player__caption {
  bottom: 4.5rem;
}

.video-player__caption span {
  display:          inline-block;
  max-width:        100%;
  padding:          var(--spacing-1) var(--spacing-3);
  border-radius:    var(--radius-sm);
  background-color: var(--inv-popover);
  color:            var(--inv-popover-foreground);
  font-size:        var(--font-size-lg);
  line-height:      var(--line-height-lg);
  white-space:      pre-line;
}

.video-player__error {
  position:         absolute;
  top:              50%;
  left:             50%;
  display:          flex;
  flex-direction:   column;
  align-items:      center;
  gap:              var(--spacing-3);
  width:            max-content;
  max-width:        calc(100% - 2rem);
  padding:          var(--spacing-4) var(--spacing-5);
  border-radius:    var(--radius-md);
  background-color: var(--card);
  color:            var(--card-foreground);
  box-shadow:       var(--shadow-xl);
  transform:        translate(-50%, -50%);
}

.video-player__error-text {
  margin:      0;
  font-size:   var(--font-size-base);
  line-height: var(--line-height-base);
}

.video-player__error-retry {
  padding:          var(--spacing-2) var(--spacing-4);
  border:           0;
  border-radius:    var(--radius-full);
  background-color: var(--card-foreground);
  color:            var(--card);
  font:             inherit;
  font-size:        var(--font-size-sm);
  font-weight:      600;
  line-height:      var(--line-height-sm);
  cursor:           pointer;
}


/* ----------------------------------------------------------
   Narrow players and touch — sized off the player, not the
   viewport, so it holds up in any column.
   ---------------------------------------------------------- */

@container (max-width: 560px) {
  .video-player__range--volume {
    display: none;
  }

  .video-player__start-pill {
    gap:     var(--spacing-2);
    padding: var(--spacing-1) var(--spacing-4) var(--spacing-1) var(--spacing-1);
  }

  .video-player__start-icon {
    width:  2.25rem;
    height: 2.25rem;
  }

  .video-player__start-label {
    font-size:   var(--font-size-sm);
    line-height: var(--line-height-sm);
  }

  .video-player__caption span {
    font-size:   var(--font-size-sm);
    line-height: var(--line-height-sm);
  }
}

@container (max-width: 420px) {
  .video-player__start {
    padding-bottom: var(--spacing-2);
  }

  .video-player__bar {
    right:  var(--spacing-2);
    bottom: var(--spacing-2);
    left:   var(--spacing-2);
    gap:    0;
  }

  .video-player__time-total {
    display: none;
  }
}

/* Touch devices set volume in hardware, and iOS ignores `video.volume`. */
@media (hover: none) {
  .video-player__range--volume {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .video-player__bar,
  .video-player__caption,
  .video-player__start-pill {
    transition: none;
  }

  .video-player__spinner {
    animation-duration: 2.4s;
  }

  .video-player__skip,
  .video-player__speed {
    animation: none;
  }

  .video-player__skip-chevrons svg {
    opacity:   1;
    animation: none;
  }
}

/* ============================================================
   HeroVideo — see HeroVideo.tsx. Figma 627:7103.
   The panel, then the live-demo line 16px under it, both centred in the
   column. Placement and the phone inset belong to the consuming section.
   ============================================================ */

.hero-video {
  display:        flex;
  flex-direction: column;
  align-items:    center;
  /* 16px, not Figma's 8: under a ~600px panel 8 read as cramped, and the line
     is a second action rather than a caption (owner, 2026-11-19). Same 16 as
     between the prompt and the link inside the line. */
  gap:            var(--spacing-4);   /* 16px */
  min-width:      0;
  /* For the panel's radius below. */
  container-type: inline-size;
  /* What the line under the panel takes: the 16 gap + one 20px line. Used to
     fit the panel to the fold. */
  --hero-video-cta-block: 2.25rem;
}

.hero-video[data-cta="none"] {
  --hero-video-cta-block: 0px;
}

/* Figma: 24px corners on the 504px design, scaled with the panel (28 at 591),
   and no shadow — the poster's own cyan is the edge.

   `max-width`: the room the section leaves above the fold (useFoldFit
   `roomVar`) less the line under the panel, so on a short laptop the panel
   shrinks and "Try the live demo" stays on screen. Never under 360px. With no
   room set (stacked layouts, stories without the hook) the 10000px fallback
   never binds and the panel is its column's width. */
.hero-video .video-player {
  max-width:     max(22.5rem, calc(var(--hero-fold-room, 10000px) - var(--hero-video-cta-block)));
  border-radius: max(var(--radius-lg), 4.762cqi);
  box-shadow:    none;
}

/* Full screen keeps the primitive's own square-cornered frame. */
.hero-video .video-player[data-fullscreen] {
  max-width:     none;
  border-radius: 0;
}

/* "Want to hear how our AI handles your real call?  Try the live demo →" —
   14/20, muted prompt + medium orange link, 16px apart. Wraps as two whole
   phrases (the link's last word and arrow are one unit inside ArrowLink). */
.hero-video__cta {
  display:         flex;
  flex-wrap:       wrap;
  justify-content: center;
  column-gap:      var(--spacing-4);   /* 16px */
  margin:          0;
  text-align:      center;
  font-size:       var(--font-size-sm);     /* 14px */
  line-height:     var(--line-height-sm);   /* 20px */
  color:           var(--muted-foreground);
}

.hero-video__cta .arrow-link {
  font-weight: var(--font-weight-medium);
}

