.client-stories {
  color: var(--navy);
  background: #fffdf8;
  padding-block: clamp(52px, 6vw, 90px);
  font: 500 16px/1.5 "DM Sans", Arial, sans-serif;
}
.stories-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.48fr) minmax(0, .83fr);
  gap: clamp(24px, 2.6vw, 42px);
  align-items: center;
}
.stories-voices h2, .stories-next h3, .stories-viewer h3 {
  margin: 0;
  font-weight: 500;
  letter-spacing: -.055em;
  line-height: 1.03;
  text-wrap: balance;
}
.stories-voices h2 { font-size: clamp(32px, 3vw, 47px); }
.stories-reader { min-width: 0; margin: 18px 0 0; padding: 0; border: 0; }
.stories-quotes { display: grid; }
.stories-quote { grid-area: 1 / 1; margin: 0; }
.stories-quote blockquote { position: relative; margin: 0 0 17px; padding-left: 26px; color: #314755; }
.stories-quote blockquote > span {
  position: absolute; left: -1px; top: -.12em;
  font: 600 45px/1 Georgia, serif; color: var(--maple);
}
.stories-quote figcaption {
  display: grid; grid-template-columns: 38px minmax(0, 1fr); align-content: center;
  padding-left: 26px; gap: 0 10px;
}
.stories-quote figcaption img { grid-row: span 2; align-self: center; border-radius: 50%; object-fit: cover; }
.stories-quote figcaption strong { font-weight: 600; font-size: 14px; }
.stories-quote figcaption small { color: #5b6266; font-size: 12px; }
#seller-perspective, .stories-reader:has(input[value="seller"]:checked) #buyer-perspective { visibility: hidden; }
.stories-reader:has(input[value="seller"]:checked) #seller-perspective { visibility: visible; }
.stories-switch { display: flex; flex-wrap: wrap; gap: 20px; margin: 9px 0 0 26px; }
.stories-sr-only, .stories-switch input {
  position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden;
  clip-path: inset(50%); white-space: nowrap;
}
.stories-switch label { position: relative; cursor: pointer; }
.stories-switch span {
  display: flex; align-items: center; min-height: 37px; padding-top: 2px;
  border-bottom: 2px solid transparent; color: #50616b; font-size: 13px;
}
.stories-switch input:checked + span { border-color: var(--maple); color: var(--navy); }
.stories-switch input:focus-visible + span { outline: 2px solid var(--navy); outline-offset: 3px; }
.stories-switch label:hover span { color: var(--navy); text-decoration: underline; text-underline-offset: 4px; }
.stories-film {
  position: relative; isolation: isolate; display: grid; place-items: center;
  min-width: 0; width: 100%; height: clamp(260px, 23.75vw, 345px);
  overflow: hidden; background: var(--navy); color: #fff;
  text-decoration: none; border-radius: 4px;
}
.stories-film > img {
  position: absolute; inset: 0; z-index: -2; display: block;
  width: 100%; height: 100%; object-fit: cover; object-position: center 52%;
}
.stories-film::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(0deg, rgb(5 25 40 / 77%), transparent 60%);
}
.stories-play {
  display: grid; place-items: center; width: 54px; height: 54px; border-radius: 50%;
  background: rgb(7 43 73 / 82%); border: 1.5px solid #fff; color: #fff;
}
.stories-play::before {
  content: ""; width: 0; height: 0; margin-left: 3px;
  border: solid transparent; border-width: 7px 0 7px 11px; border-left-color: currentColor;
}
.stories-film:is(:hover,:focus-visible) .stories-play { background: #fff; color: var(--navy); }
.stories-film:focus-visible { outline-color: var(--navy); }
.stories-film-title {
  position: absolute; left: clamp(18px, 1.8vw, 28px); bottom: clamp(18px, 1.8vw, 28px);
  display: grid; gap: 3px; font-size: clamp(22px, 2vw, 32px);
  line-height: 1.15; letter-spacing: -.045em;
}
.stories-film-title small { font-size: 11px; text-transform: uppercase; letter-spacing: .12em; }
.stories-next h3 { font-size: clamp(26px, 2.2vw, 35px); }
.stories-next p { margin-top: 12px; max-width: 32ch; color: #405562; }
.stories-next .button { min-width: 0; min-height: 44px; margin-top: 20px; padding-inline: 18px; font-size: 12px; }
.stories-area { display: block; width: fit-content; margin-top: 12px; font-size: 13px; text-underline-offset: 3px; }
.stories-area:hover { color: #972a25; }
.stories-viewer {
  width: min(850px, calc(100% - 28px)); max-height: 92dvh; padding: 0;
  overflow: auto; overscroll-behavior: contain; border: 0; background: #fcf9f3; color: var(--navy);
}
.stories-viewer::backdrop { background: rgb(2 17 30 / 78%); }
.stories-viewer-head { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding: 10px 20px; }
.stories-viewer h3 { font-size: 24px; }
.stories-viewer-head button {
  min-height: 44px; padding: 3px; background: transparent; border: 0; color: var(--navy);
  text-decoration: underline; text-underline-offset: .25em; font-size: 14px;
}
.stories-viewer video { display: block; width: 100%; aspect-ratio: 16 / 9; max-height: 67dvh; background: #081c2b; }
.stories-viewer p { padding: 14px 20px; margin: 0; color: #405562; font-size: 14px; }
html:has(.stories-viewer[open]) { overflow: hidden; }
html:has(.stories-viewer[open][data-scrollbar]) { scrollbar-gutter: stable; }
@media (min-width: 681px) and (max-width: 1050px) {
  .stories-layout { grid-template-columns: minmax(0, 1fr) minmax(0, 1.18fr); gap: 26px 34px; }
  .stories-next {
    grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 1fr) auto;
    align-items: center; column-gap: 35px; border-top: 1px solid #d4d6cf; padding-top: 22px;
  }
  .stories-next h3 { grid-column: 1; }
  .stories-next p { grid-column: 1; max-width: 58ch; margin-top: 7px; }
  .stories-next .button { grid-area: 1 / 2 / 3; margin-top: 0; }
  .stories-area { grid-column: 1 / -1; margin-top: 8px; }
}
@media (max-width: 680px) {
  .stories-layout { grid-template-columns: minmax(0, 1fr); gap: 27px; }
  .stories-voices h2 { font-size: clamp(32px, 7.4vw, 43px); }
  .stories-film { height: auto; aspect-ratio: 1.65; }
  .stories-next p { max-width: 44ch; }
  .stories-switch span { min-height: 44px; }
}
@media (prefers-reduced-motion: no-preference) {
  .stories-play { transition: background-color 180ms, color 180ms; }
}
