.detail-gallery-wrapper {
  position: relative;
  width: 100%;
  margin: 0 0 25px;
  overflow: hidden;
  padding: 0;
}

.detail-gallery {
  display: flex;
  flex-direction: row;
  gap: 24px;
  width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-behavior: smooth;
  scroll-padding: 16px;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.detail-gallery::-webkit-scrollbar {
  display: none;
}

.detail-gallery-item {
  position: relative;
  flex: 0 0 100%;
  border: 0;
  border-radius: 12px;
  overflow: hidden;
  padding: 0;
  background: transparent;
  cursor: pointer;
  scroll-snap-align: start;
}

.detail-gallery-item > span {
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 12px;
  background: #f7f8fa;
}

.detail-gallery-item img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.detail-gallery-play {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 2;
  transform: translate(-50%, -50%);
}

.detail-gallery-nav {
  position: absolute;
  top: calc((100% - 32px) / 2);
  z-index: 10;
  width: 44px;
  height: 45px;
  border: 0;
  border-radius: 999px;
  padding: 0;
  color: #344054;
  background: transparent;
  box-shadow: 0 8px 22px rgba(33, 41, 60, 0.14);
  cursor: pointer;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.detail-gallery-nav svg {
  display: block;
  width: 44px;
  height: 45px;
}

.detail-gallery-nav.prev {
  left: 24px;
  transform: translateY(-50%);
}

.detail-gallery-nav.next {
  right: 24px;
  transform: translateY(-50%);
}

.detail-gallery-nav.is-hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateY(-50%) scale(0.92);
}

.detail-gallery-dots {
  display: flex;
  justify-content: center;
  gap: 16px;
  min-height: 8px;
  margin-top: 24px;
}

.detail-gallery-dots button {
  width: 8px;
  height: 8px;
  border: 0;
  border-radius: 999px;
  padding: 0;
  background: #d1d5db;
  cursor: pointer;
  transition: background 0.2s ease;
}

.detail-gallery-dots button.is-active {
  background: #ff5a52;
}

.detail-lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 22px;
  background: rgba(15, 23, 42, 0.82);
}

.detail-lightbox img {
  max-width: 100%;
  max-height: 84vh;
  border-radius: 12px;
  background: #fff;
}

.detail-lightbox button {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 999px;
  color: #111827;
  background: #fff;
  font-size: 26px;
  line-height: 1;
}

.detail-media-frame,
.detail-media-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 300px;
  margin: 0 0 25px;
  overflow: hidden;
  border-radius: 9px;
  background: #ddd;
  box-shadow: 0 12px 26px rgba(36, 51, 80, 0.16);
}

.detail-media-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.detail-media-placeholder {
  flex-direction: column;
  color: #555;
}

.detail-media-placeholder span {
  position: relative;
  width: 48px;
  height: 58px;
  border: 5px solid currentColor;
}

.detail-media-placeholder span::before {
  position: absolute;
  right: -5px;
  top: -5px;
  width: 18px;
  height: 18px;
  border-left: 5px solid currentColor;
  border-bottom: 5px solid currentColor;
  background: #ddd;
  content: "";
}

.detail-media-placeholder em {
  margin-top: 10px;
  font-style: normal;
  font-weight: 700;
}
