.yfc {
  --film-main: #cc5c00;
  --film-dark: #1d1207;
  --frame-gap: 8px;
  --frame-width: 250px;
  --frame-height: 140px;
  width: 100%;
  margin: 0 auto;
  background: #000;
}

.yfc-player-stage {
  position: relative;
  background: #000;
  min-height: 320px;
  height: var(--yfc-player-height, 70vh);
  max-height: 84vh;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0.5rem 0;
  box-sizing: border-box;
}

.yfc-player {
  border: 0;
  display: block;
  height: 100%;
  aspect-ratio: 16 / 9;
  width: auto;
  max-width: 100%;
  background: #000;
}

.yfc-film-viewport {
  position: relative;
  display: flex;
  gap: var(--frame-gap);
  overflow-x: auto;
  overflow-y: hidden;
  padding: 32px 14px;
  background:
    repeating-linear-gradient(
      to right,
      transparent 0 14px,
      #efe8de 14px 24px,
      transparent 24px 38px
    ) top / auto 18px repeat-x,
    repeating-linear-gradient(
      to right,
      transparent 0 14px,
      #efe8de 14px 24px,
      transparent 24px 38px
    ) bottom / auto 18px repeat-x,
    linear-gradient(to bottom, transparent 0 12px, rgba(0, 0, 0, 0.35) 12px 13px, transparent 13px 100%),
    linear-gradient(to top, transparent 0 12px, rgba(0, 0, 0, 0.35) 12px 13px, transparent 13px 100%),
    var(--film-main);
  scrollbar-width: thin;
  scrollbar-color: #734100 rgba(0, 0, 0, 0.18);
  scroll-snap-type: x proximity;
  scroll-behavior: smooth;
  overscroll-behavior-x: contain;
  -webkit-overflow-scrolling: touch;
  touch-action: pan-x;
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
}

.yfc-film-viewport.is-dragging {
  cursor: grabbing;
}

.yfc-frame {
  flex: 0 0 var(--frame-width);
  width: var(--frame-width);
  height: var(--frame-height);
  border: 6px solid var(--film-main);
  border-radius: 2px;
  padding: 0;
  background: #111;
  cursor: pointer;
  overflow: hidden;
  transition: transform 0.16s ease, filter 0.16s ease, border-color 0.16s ease;
  scroll-snap-align: start;
}

.yfc-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.yfc-frame:hover,
.yfc-frame:focus-visible {
  transform: translateY(-2px);
  filter: brightness(1.03);
  border-color: #ff7d12;
  outline: none;
}

.yfc-frame.is-active {
  border-color: #fff2c6;
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.35) inset;
}

@media (max-width: 900px) {
  .yfc {
    --frame-width: 200px;
    --frame-height: 112px;
  }
}

@media (max-width: 600px) {
  .yfc-player-stage {
    min-height: 220px;
  }
}
