.sfp-shorts {
  --shorts-ink: #101820;
  --shorts-paper: #f8f5ef;
  --shorts-orange: #ff8f44;
  position: relative;
  padding: clamp(66px, 8vw, 104px) 0 clamp(58px, 7vw, 86px);
  overflow: hidden;
  background:
    radial-gradient(circle at 92% 5%, rgba(255, 143, 68, .17), transparent 30%),
    linear-gradient(145deg, #101820 0%, #172a35 58%, #0d171e 100%);
  color: #fff;
}

.sfp-shorts__inner {
  width: min(calc(100% - 44px), 1180px);
  margin-inline: auto;
}

.sfp-shorts__head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 34px;
  margin-bottom: 32px;
}

.sfp-shorts__copy {
  max-width: 670px;
}

.sfp-shorts__eyebrow {
  margin: 0 0 10px;
  color: var(--shorts-orange);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .2em;
  line-height: 1.5;
  text-transform: uppercase;
}

.sfp-page .sfp-shorts__title {
  margin: 0;
  color: #fff;
  font-size: clamp(30px, 4vw, 48px);
  font-weight: 400;
  letter-spacing: .035em;
  line-height: 1.1;
  text-transform: uppercase;
}

.sfp-shorts__lead {
  max-width: 600px;
  margin: 16px 0 0;
  color: rgba(255, 255, 255, .76);
  font-size: 16px;
  line-height: 1.65;
}

.sfp-shorts__controls {
  flex: 0 0 auto;
  display: flex;
  gap: 8px;
}

body .sfp-shorts .sfp-shorts__arrow {
  width: 46px;
  height: 46px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, .32);
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  color: #fff;
  cursor: pointer;
  transition: background-color .2s ease, border-color .2s ease, color .2s ease;
}

body .sfp-shorts .sfp-shorts__arrow:hover,
body .sfp-shorts .sfp-shorts__arrow:focus-visible {
  border-color: var(--shorts-orange);
  background: var(--shorts-orange);
  color: #101820;
}

.sfp-shorts__arrow svg {
  width: 18px;
  height: 18px;
}

.sfp-shorts__rail {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 300px;
  gap: 18px;
  padding: 0 0 14px;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scroll-behavior: smooth;
  scroll-snap-type: inline mandatory;
  scrollbar-color: rgba(255, 143, 68, .8) rgba(255, 255, 255, .1);
  scrollbar-width: thin;
}

.sfp-shorts__rail::-webkit-scrollbar {
  height: 7px;
}

.sfp-shorts__rail::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, .1);
}

.sfp-shorts__rail::-webkit-scrollbar-thumb {
  background: rgba(255, 143, 68, .8);
}

.sfp-short {
  position: relative;
  min-width: 0;
  aspect-ratio: 9 / 16;
  margin: 0;
  overflow: hidden;
  scroll-snap-align: start;
  border: 1px solid rgba(255, 255, 255, .16);
  border-radius: 18px;
  background: #1b2932;
  box-shadow: 0 18px 38px rgba(0, 0, 0, .2);
  isolation: isolate;
}

.sfp-short__media,
.sfp-short__media img,
.sfp-short__media video {
  width: 100%;
  height: 100%;
}

.sfp-short__media {
  position: absolute;
  inset: 0;
  z-index: -2;
}

.sfp-short__media img,
.sfp-short__media video {
  display: block;
  object-fit: cover;
  object-position: var(--sfp-short-position, center center);
}

.sfp-short::after {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(180deg, rgba(5, 17, 24, .08) 20%, rgba(5, 17, 24, .08) 46%, rgba(5, 17, 24, .92) 100%),
    linear-gradient(110deg, rgba(5, 17, 24, .3), transparent 45%);
  content: "";
  pointer-events: none;
}

.sfp-short__topline {
  position: absolute;
  top: 16px;
  right: 16px;
  left: 16px;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.sfp-short__tag,
.sfp-short__duration {
  min-height: 25px;
  padding: 5px 9px;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: rgba(7, 19, 25, .68);
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .13em;
  line-height: 1;
  text-transform: uppercase;
  backdrop-filter: blur(8px);
}

.sfp-short__duration {
  letter-spacing: .06em;
}

body .sfp-shorts .sfp-short__play {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 3;
  width: 64px;
  height: 64px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, .66);
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(8, 22, 30, .62);
  color: #fff;
  cursor: pointer;
  box-shadow: 0 10px 28px rgba(0, 0, 0, .26);
  transform: translate(-50%, -50%);
  transition: transform .2s ease, background-color .2s ease, color .2s ease;
  backdrop-filter: blur(8px);
}

body .sfp-shorts .sfp-short__play:hover,
body .sfp-shorts .sfp-short__play:focus-visible,
body .sfp-shorts .sfp-short.is-playing .sfp-short__play {
  background: var(--shorts-orange);
  color: #101820;
  transform: translate(-50%, -50%) scale(1.06);
}

.sfp-short__play svg {
  width: 24px;
  height: 24px;
}

.sfp-short__play .sfp-short__pause,
.sfp-short.is-playing .sfp-short__play .sfp-short__play-icon {
  display: none;
}

.sfp-short.is-playing .sfp-short__play .sfp-short__pause {
  display: block;
}

.sfp-short__content {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 2;
  padding: 44px 20px 20px;
}

.sfp-short__content h3 {
  margin: 0;
  color: #fff;
  font-size: 24px;
  font-weight: 700;
  letter-spacing: .015em;
  line-height: 1.15;
}

.sfp-short__content p {
  margin: 9px 0 0;
  color: rgba(255, 255, 255, .76);
  font-size: 13px;
  line-height: 1.55;
}

@media (max-width: 760px), (pointer: coarse) {
  .sfp-short {
    cursor: pointer;
  }

  .sfp-short__media video {
    cursor: pointer;
    touch-action: manipulation;
  }
}

.sfp-player[hidden] {
  display: none;
}

body.sfp-player-open {
  overflow: hidden;
}

.sfp-player {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: block;
  isolation: isolate;
  color: #fff;
}

body .sfp-player .sfp-player__backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0 !important;
  border-radius: 0;
  background: rgba(5, 12, 17, .96) !important;
  cursor: default;
}

.sfp-player__dialog {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100dvh;
  max-height: none;
  padding: 0;
  overflow: hidden;
  background: #000;
}

.sfp-player__bar {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  z-index: 6;
  min-height: 44px;
  padding:
    max(14px, env(safe-area-inset-top))
    max(16px, env(safe-area-inset-right))
    18px
    max(18px, env(safe-area-inset-left));
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(180deg, rgba(3, 9, 13, .74), transparent);
}

.sfp-player__count {
  color: rgba(255, 255, 255, .76);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .13em;
  line-height: 1.4;
  text-transform: uppercase;
}

body .sfp-player .sfp-player__close {
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, .3) !important;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, .08) !important;
  color: #fff;
  cursor: pointer;
}

.sfp-player__close svg {
  width: 22px;
  height: 22px;
}

.sfp-player__viewport {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sfp-player__stage {
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  aspect-ratio: auto;
  overflow: hidden;
  border: 0;
  border-radius: 0;
  background: #0a141a;
}

.sfp-player__stage video,
.sfp-player__stage img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center center;
}

.sfp-player__stage video {
  background: #000;
}

body .sfp-player .sfp-player__arrow {
  position: absolute;
  right: 0;
  z-index: 3;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, .32) !important;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(7, 19, 25, .76) !important;
  color: #fff;
  cursor: pointer;
  transform: none;
  backdrop-filter: blur(8px);
}

body .sfp-player .sfp-player__arrow:hover,
body .sfp-player .sfp-player__arrow:focus-visible {
  border-color: var(--shorts-orange) !important;
  background: var(--shorts-orange) !important;
  color: #101820;
}

.sfp-player__arrow svg {
  width: 20px;
  height: 20px;
}

.sfp-player__arrow--prev {
  top: calc(50% - 58px);
}

.sfp-player__arrow--next {
  top: calc(50% + 14px);
}

body .sfp-player .sfp-player__sound {
  position: absolute;
  right: max(16px, env(safe-area-inset-right));
  bottom: calc(max(18px, env(safe-area-inset-bottom)) + 12px);
  z-index: 6;
  width: 46px;
  height: 46px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, .38) !important;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(7, 19, 25, .8) !important;
  color: #fff;
  cursor: pointer;
  backdrop-filter: blur(8px);
}

body .sfp-player .sfp-player__sound[hidden] {
  display: none;
}

body .sfp-player .sfp-player__sound:hover,
body .sfp-player .sfp-player__sound:focus-visible {
  border-color: var(--shorts-orange) !important;
  background: var(--shorts-orange) !important;
  color: #101820;
}

.sfp-player__sound svg {
  width: 23px;
  height: 23px;
}

.sfp-player__sound .sfp-player__sound-on,
.sfp-player__sound[aria-pressed="true"] .sfp-player__sound-off {
  display: none;
}

.sfp-player__sound[aria-pressed="true"] .sfp-player__sound-on {
  display: block;
}

.sfp-player__meta {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 5;
  padding:
    92px
    max(88px, calc(env(safe-area-inset-right) + 74px))
    calc(max(22px, env(safe-area-inset-bottom)) + 10px)
    max(18px, env(safe-area-inset-left));
  background: linear-gradient(0deg, rgba(3, 9, 13, .9) 0%, rgba(3, 9, 13, .72) 48%, transparent 100%);
  text-align: left;
}

.sfp-player__tag {
  color: var(--shorts-orange);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.sfp-page .sfp-player__title {
  margin: 5px 0 0;
  color: #fff;
  font-size: clamp(24px, 7vw, 32px);
  font-weight: 700;
  line-height: 1.2;
}

.sfp-player__text {
  margin: 7px 0 0;
  color: rgba(255, 255, 255, .72);
  max-width: 620px;
  font-size: 14px;
  line-height: 1.5;
}

.sfp-player__dots {
  margin-top: 13px;
  display: flex;
  justify-content: flex-start;
  gap: 7px;
}

body .sfp-player .sfp-player__dot {
  width: 8px;
  height: 8px;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 50%;
  background: rgba(255, 255, 255, .3) !important;
  cursor: pointer;
}

body .sfp-player .sfp-player__dot.is-active {
  width: 24px;
  border-radius: 99px;
  background: var(--shorts-orange) !important;
}

@media (max-width: 760px) {
  .sfp-shorts {
    padding: 54px 0 58px;
  }

  .sfp-shorts__inner {
    width: min(calc(100% - 28px), 1180px);
  }

  .sfp-shorts__head {
    display: block;
    margin-bottom: 24px;
  }

  .sfp-shorts__lead {
    margin-top: 12px;
    font-size: 14px;
  }

  .sfp-shorts__controls {
    display: none;
  }

  .sfp-shorts__rail {
    grid-auto-columns: min(78vw, 310px);
    gap: 12px;
    margin-right: -14px;
    padding-right: 14px;
  }

  .sfp-short {
    border-radius: 14px;
  }

  .sfp-short__content {
    padding: 42px 16px 17px;
  }

  .sfp-short__content h3 {
    font-size: 21px;
  }

  .sfp-short__content p {
    font-size: 12px;
  }

  .sfp-player__dialog {
    padding-inline: 0;
  }

  .sfp-player__stage {
    max-width: none;
    max-height: none;
    border-radius: 0;
  }

  .sfp-player__meta {
    padding:
      82px
      max(82px, calc(env(safe-area-inset-right) + 70px))
      calc(max(20px, env(safe-area-inset-bottom)) + 8px)
      max(18px, env(safe-area-inset-left));
  }

  .sfp-page .sfp-player__title {
    font-size: 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .sfp-shorts__rail {
    scroll-behavior: auto;
  }

  .sfp-short__play,
  .sfp-shorts__arrow {
    transition: none;
  }
}
