/* =========================================================
   OLD ZOMBIE — видеоблок (карусель на главной) и управление в админке
   ========================================================= */
.vd-section { margin: 8px 0 34px; }
.vd-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; flex-wrap: wrap; margin-bottom: 18px; }
.vd-kicker { display: inline-flex; align-items: center; gap: 8px; color: var(--lilac); font-size: 11px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.vd-head h2 { margin: 6px 0 6px; font-size: 28px; font-weight: 900; letter-spacing: -.02em; line-height: 1.15; }
.vd-head h2 span { background: linear-gradient(90deg, #b24dff, #ff6fb5 55%, #ffc94a); -webkit-background-clip: text; background-clip: text; color: transparent; }
.vd-head p { margin: 0; color: var(--muted); max-width: 560px; }
.vd-nav { display: flex; gap: 8px; }
.vd-arrow { width: 46px; height: 46px; display: grid; place-items: center; border-radius: 14px; border: 1px solid var(--line-2); background: var(--panel); color: #d8dcea; font-size: 14px; cursor: pointer; transition: .18s; }
.vd-arrow:hover:not(:disabled) { border-color: var(--violet-2); background: rgba(139, 61, 255, .2); color: #fff; box-shadow: var(--shadow-violet); transform: translateY(-2px); }
.vd-arrow:disabled { opacity: .35; cursor: default; }
.vd-section.vd-static .vd-nav, .vd-section.vd-static .vd-foot { display: none; }

.vd-carousel { position: relative; }
.vd-carousel::before, .vd-carousel::after { content: ''; position: absolute; top: 0; bottom: 14px; width: 54px; z-index: 3; pointer-events: none; transition: opacity .25s; }
.vd-carousel::before { left: -1px; background: linear-gradient(90deg, var(--bg), transparent); }
.vd-carousel::after { right: -1px; background: linear-gradient(270deg, var(--bg), transparent); }
.vd-carousel.at-start::before, .vd-carousel.at-end::after { opacity: 0; }
.vd-track { display: flex; gap: 16px; overflow-x: auto; overflow-y: hidden; scroll-snap-type: x mandatory; scroll-behavior: smooth; scrollbar-width: none; padding: 16px 4px 26px; cursor: grab; outline: none; -webkit-overflow-scrolling: touch; overscroll-behavior-x: contain; }
.vd-track::-webkit-scrollbar { display: none; }
.vd-track.dragging { scroll-snap-type: none; scroll-behavior: auto; cursor: grabbing; user-select: none; }
.vd-track.dragging .vd-card { pointer-events: none; }
.vd-track:focus-visible { box-shadow: 0 0 0 2px rgba(168, 85, 255, .5); border-radius: 16px; }

.vd-card { --ty: 0px; --sc: 1; --rx: 0deg; --ry: 0deg; position: relative; flex: 0 0 calc((100% - 32px) / 3); min-width: 0; display: flex; flex-direction: column; border-radius: 18px; border: 1px solid var(--line-2); background: linear-gradient(180deg, var(--panel-2), var(--panel)); color: var(--text); text-decoration: none; overflow: hidden; scroll-snap-align: start; transform: perspective(900px) translateY(var(--ty)) rotateX(var(--rx)) rotateY(var(--ry)) scale(var(--sc)); transition: transform .5s cubic-bezier(.16, 1, .3, 1), border-color .4s ease, box-shadow .6s cubic-bezier(.16, 1, .3, 1); -webkit-user-drag: none; }
.vd-card:hover, .vd-card:focus-visible { --ty: -9px; --sc: 1.018; border-color: color-mix(in srgb, var(--vd-c) 65%, transparent); box-shadow: 0 24px 50px rgba(0, 0, 0, .5), 0 0 40px color-mix(in srgb, var(--vd-c) 30%, transparent); color: var(--text); }
.vd-card:active { --sc: .99; --ty: -3px; transition-duration: .15s; }
.vd-card::after { content: ''; position: absolute; inset: 0; z-index: 3; border-radius: inherit; background: radial-gradient(280px circle at var(--mx, 50%) var(--my, 30%), color-mix(in srgb, var(--vd-c) 24%, transparent), transparent 65%); opacity: 0; transition: opacity .5s ease; pointer-events: none; }
.vd-card:hover::after { opacity: 1; }
.vd-thumb { position: relative; display: block; aspect-ratio: 16 / 9; overflow: hidden; background: #0a0f18; }
.vd-thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 1.1s cubic-bezier(.16, 1, .3, 1), filter .6s ease; -webkit-user-drag: none; user-select: none; }
.vd-card:hover .vd-thumb img { transform: scale(1.1); filter: saturate(1.18) brightness(1.06); }
.vd-ph { position: absolute; inset: 0; display: grid; place-items: center; font-size: 54px; color: color-mix(in srgb, var(--vd-c) 80%, #fff); background: radial-gradient(circle at 30% 20%, color-mix(in srgb, var(--vd-c) 38%, transparent), transparent 60%), linear-gradient(135deg, #171126, #0d1420); }
.vd-shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(7, 11, 18, .35) 0%, transparent 35%, rgba(7, 11, 18, .7) 100%); pointer-events: none; transition: opacity .6s ease; }
.vd-card:hover .vd-shade { opacity: .55; }
.vd-plat { position: absolute; top: 10px; left: 10px; display: inline-flex; align-items: center; gap: 7px; padding: 5px 11px 5px 9px; border-radius: 20px; font-size: 11px; font-weight: 800; color: #fff; background: rgba(8, 12, 20, .72); border: 1px solid color-mix(in srgb, var(--vd-c) 55%, transparent); backdrop-filter: blur(8px); }
.vd-plat i { color: var(--vd-c); font-size: 13px; }
.vd-play { position: absolute; left: 50%; top: 50%; width: 62px; height: 62px; margin: -31px 0 0 -31px; display: grid; place-items: center; border-radius: 50%; background: color-mix(in srgb, var(--vd-c) 88%, #000); color: #fff; font-size: 20px; padding-left: 4px; box-shadow: 0 8px 26px rgba(0, 0, 0, .5); transition: transform .55s cubic-bezier(.16, 1, .3, 1), box-shadow .5s ease; }
.vd-play::before, .vd-play::after { content: ''; position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--vd-c); opacity: 0; animation: vdRing 2.4s ease-out infinite; }
.vd-play::after { animation-delay: 1.2s; }
.vd-play { transform: scale(.92); }
.vd-card:hover .vd-play { transform: scale(1.14); box-shadow: 0 10px 34px rgba(0, 0, 0, .55), 0 0 30px color-mix(in srgb, var(--vd-c) 60%, transparent); }
.vd-plat { transition: transform .5s cubic-bezier(.16, 1, .3, 1); }
.vd-card:hover .vd-plat { transform: translateY(-2px); }
@keyframes vdRing { 0% { transform: scale(1); opacity: .65; } 100% { transform: scale(1.9); opacity: 0; } }
.vd-info { display: flex; flex-direction: column; gap: 5px; padding: 14px 16px 16px; min-width: 0; flex: 1; }
.vd-info b { transition: color .4s ease; font-size: 15px; font-weight: 800; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.vd-info small { color: var(--muted); font-size: 12px; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.vd-info em { margin-top: auto; padding-top: 4px; font-style: normal; font-size: 12px; font-weight: 700; color: var(--vd-c); display: inline-flex; align-items: center; gap: 7px; }
.vd-info em { transition: gap .4s cubic-bezier(.16, 1, .3, 1); }
.vd-card:hover .vd-info em { gap: 11px; }
.vd-info em i { font-size: 10px; transition: transform .45s cubic-bezier(.16, 1, .3, 1); }
.vd-card:hover .vd-info em i { transform: translate(3px, -3px); }

/* вход карточек */
html.vd-js .vd-section:not(.in) .vd-card { opacity: 0; transform: translateY(26px); }
html.vd-js .vd-section.in .vd-card { animation: vdIn .7s cubic-bezier(.2, .8, .2, 1) backwards; animation-delay: calc(var(--i, 0) * 90ms); }
@keyframes vdIn { from { opacity: 0; transform: translateY(26px) scale(.96); } to { opacity: 1; transform: none; } }

/* полоса прогресса и точки */
.vd-foot { display: flex; align-items: center; gap: 16px; margin-top: 2px; }
.vd-progress { position: relative; flex: 1; height: 4px; border-radius: 4px; background: rgba(255, 255, 255, .07); overflow: hidden; }
.vd-progress i { position: absolute; top: 0; bottom: 0; left: 0; width: 30%; border-radius: 4px; background: var(--grad-violet); box-shadow: 0 0 12px rgba(168, 85, 255, .7); transition: left .15s linear, width .2s; }
.vd-dots { display: flex; gap: 6px; }
.vd-dots button { width: 8px; height: 8px; padding: 0; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .18); cursor: pointer; transition: .2s; }
.vd-dots button.on { width: 22px; border-radius: 8px; background: var(--violet-2); }

@media (max-width: 991px) {
  .vd-card { flex-basis: calc((100% - 16px) / 2); }
  .vd-head h2 { font-size: 24px; }
}
@media (max-width: 575px) {
  .vd-card { flex-basis: 84%; }
  .vd-head h2 { font-size: 21px; }
  .vd-nav { display: none; }
  .vd-carousel::before, .vd-carousel::after { width: 22px; }
  .vd-dots { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .vd-play::before, .vd-play::after { animation: none; }
  .vd-track { scroll-behavior: auto; }
  html.vd-js .vd-section .vd-card { animation: none !important; opacity: 1 !important; transform: none !important; }
}

/* ---------- Админка: список видео ---------- */
.vda-list { display: flex; flex-direction: column; gap: 12px; }
.vda-item { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 14px; padding: 12px; border-radius: 16px; border: 1px solid var(--line-2); background: rgba(255, 255, 255, .025); }
.vda-item.off { opacity: .6; }
.vda-thumb { position: relative; aspect-ratio: 16 / 9; border-radius: 11px; overflow: hidden; background: #0a0f18; }
.vda-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.vda-thumb .vd-ph { font-size: 34px; }
.vda-thumb .vd-plat { top: 6px; left: 6px; font-size: 10px; padding: 3px 8px 3px 7px; }
.vda-main { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.vda-main h4 { margin: 0; font-size: 15px; font-weight: 800; }
.vda-url { color: var(--lilac); font-size: 12px; word-break: break-all; }
.vda-meta { color: var(--muted); font-size: 12px; display: flex; gap: 12px; flex-wrap: wrap; }
.vda-actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.vda-actions form { margin: 0; }
.vda-edit { margin-top: 8px; padding: 12px; border-radius: 12px; border: 1px dashed var(--line-2); }
.vda-edit summary { cursor: pointer; font-weight: 700; color: var(--lilac); list-style: none; }
.vda-edit summary::-webkit-details-marker { display: none; }
.vda-edit[open] summary { margin-bottom: 10px; }
@media (max-width: 700px) { .vda-item { grid-template-columns: 1fr; } }
