/* ══════════════════════════════════════════════════════════
   Видео-слайдер — mys_website
   ══════════════════════════════════════════════════════════ */

/* ── Секция ─────────────────────────────────────────────── */

#videos-section {
  padding: 64px 0;
  background: var(--black);
  color: var(--white);
}

#videos-section .section-label {
  color: var(--gold);
}

#videos-section h2 {
  color: var(--white);
  margin-top: 8px;
  margin-bottom: 40px;
}

/* ── Враппер со стрелками ───────────────────────────────── */

.videos-slider {
  position: relative;
}

.videos-arrow {
  display: none; /* скрыты на мобиле */
  position: absolute;
  top: 50%;
  transform: translateY(-60%); /* чуть выше — компенсация подписи */
  z-index: 2;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,0.12);
  color: var(--white);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.videos-arrow:hover { background: rgba(255,255,255,0.22); }
.videos-arrow--prev { left: -20px; }
.videos-arrow--next { right: -20px; }

/* ── Трек ────────────────────────────────────────────────── */

.videos-track {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;        /* Firefox */
  padding-bottom: 8px;          /* чтобы тень карточки не обрезалась */
}
.videos-track::-webkit-scrollbar { display: none; }

/* Заглушка когда нет обложки (FB без thumbnail) */
.video-card__no-thumb {
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #2a2a2a 0%, #1a1a1a 100%);
  display: flex;
  align-items: center;
  justify-content: center;
}
.video-card__no-thumb::after {
  content: '▶';
  font-size: 32px;
  color: rgba(255,255,255,0.2);
}

/* ── Карточка ────────────────────────────────────────────── */

.video-card {
  flex: 0 0 85vw;               /* мобиль — почти полный экран */
  scroll-snap-align: start;
  border-radius: var(--radius-md);
  background: #1e1e1e;
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: transform 0.22s;
}
.video-card:active { transform: scale(0.98); }

/* thumbnail + iframe контейнер */
.video-card__thumb {
  position: relative;
  aspect-ratio: 16 / 9;  /* дефолт для YouTube */
  overflow: hidden;
  background: #111;
  cursor: pointer;
}
/* FB вертикальный ролик — aspect-ratio ставится инлайн из JS */
[data-type="facebook"] .video-card__thumb {
  aspect-ratio: unset;
}
.video-card__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s;
}
.video-card:hover .video-card__thumb img { transform: scale(1.03); }

/* кнопка Play */
.video-card__play {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.25);
  border: none;
  cursor: pointer;
  transition: background 0.2s;
  color: var(--white);
}
.video-card__play:hover { background: rgba(0,0,0,0.45); }
.video-card__play svg {
  filter: drop-shadow(0 2px 8px rgba(0,0,0,0.5));
  width: 48px;
  height: 48px;
}

/* подпись */
.video-card__info {
  padding: 12px 14px 14px;
}
.video-card__title {
  font-size: 15px;
  font-weight: 600;
  color: var(--white);
  margin: 0;
  line-height: 1.3;
}
.video-card__desc {
  font-size: 13px;
  color: var(--grey-light);
  margin: 4px 0 0;
  line-height: 1.4;
}

/* ── Десктоп ─────────────────────────────────────────────── */

@media (min-width: 640px) {
  .video-card { flex: 0 0 300px; }
}

@media (min-width: 768px) {
  #videos-section { padding: 96px 0; }
  .video-card { flex: 0 0 320px; }
  .videos-arrow { display: flex; align-items: center; justify-content: center; }
}

@media (min-width: 1024px) {
  .video-card { flex: 0 0 360px; }
  .videos-arrow--prev { left: -28px; }
  .videos-arrow--next { right: -28px; }
}
