/* Videos: list with in-page player, and the video page. */
.videos-page { --v-navy: #123957; --v-red: #c32c35; --v-ink: #172d40; --v-muted: #647587; --v-line: #e1e8ef; padding-block: 8px 64px; }

/* Toolbar */
.videos-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin-bottom: 28px; }
.videos-cats { display: flex; flex-wrap: wrap; gap: 8px; flex: 1 1 auto; }
.videos-cats a { display: inline-flex; align-items: center; gap: 6px; padding: 8px 16px; border-radius: 999px; background: #f1f5f9; color: var(--v-ink); text-decoration: none; font-size: .88rem; font-weight: 600; border: 1px solid transparent; transition: background .2s, color .2s, border-color .2s; }
.videos-cats a small { font-size: .72rem; color: var(--v-muted); background: #fff; border-radius: 999px; padding: 0 7px; }
.videos-cats a:hover { border-color: var(--v-navy); }
.videos-cats a.is-active { background: var(--v-navy); color: #fff; }
.videos-cats a.is-active small { color: var(--v-navy); }
.videos-search { display: flex; align-items: center; background: #fff; border: 1px solid var(--v-line); border-radius: 14px; padding: 4px; min-width: 260px; box-shadow: 0 6px 18px rgba(18, 57, 87, .06); }
.videos-search input { border: 0; outline: 0; background: transparent; padding: 8px 12px; flex: 1; font-size: .9rem; min-width: 0; }
.videos-search button { border: 0; background: var(--v-navy); color: #fff; width: 40px; height: 40px; border-radius: 10px; }
.videos-result { color: var(--v-muted); margin-bottom: 20px; }
.videos-result a { margin-inline-start: 10px; color: var(--v-red); }
.videos-heading { font-size: 1.3rem; color: var(--v-navy); margin: 44px 0 20px; font-weight: 800; }

/* Cards */
.vgrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.vcard { background: #fff; border: 1px solid var(--v-line); border-radius: 20px; overflow: hidden; display: flex; flex-direction: column; transition: transform .25s ease, box-shadow .25s ease, border-color .25s; }
.vcard:hover { transform: translateY(-4px); box-shadow: 0 20px 40px rgba(18, 57, 87, .12); border-color: #cfdbe6; }
.vcard-media { position: relative; display: block; aspect-ratio: 16 / 9; background: linear-gradient(135deg, #0d2c45, #134a72); overflow: hidden; }
.vcard-media img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .5s ease; }
.vcard:hover .vcard-media img { transform: scale(1.05); }
.vcard-media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 45%, rgba(8, 22, 36, .55)); pointer-events: none; }
.vcard-placeholder { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: rgba(255, 255, 255, .5); font-size: 2.6rem; }
.vcard-play { position: absolute; z-index: 2; top: 50%; left: 50%; width: 64px; height: 64px; margin: -32px 0 0 -32px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: rgba(255, 255, 255, .92); color: var(--v-red); font-size: 1.35rem; box-shadow: 0 10px 30px rgba(0, 0, 0, .25); transition: transform .25s ease, background .25s; }
.vcard-play i { margin-left: 4px; }
.vcard-media:hover .vcard-play, .vcard-media:focus-visible .vcard-play { transform: scale(1.12); background: var(--v-red); color: #fff; }
.vcard-duration { position: absolute; z-index: 2; bottom: 10px; left: 10px; background: rgba(8, 18, 30, .8); color: #fff; font-size: .75rem; font-weight: 700; padding: 2px 8px; border-radius: 6px; }
.vcard-source { position: absolute; z-index: 2; top: 10px; right: 10px; color: #fff; font-size: .7rem; font-weight: 700; padding: 3px 10px; border-radius: 999px; }
.vcard-source--youtube { background: #e00; }
.vcard-source--aparat { background: #ea1d5d; }
.vcard-body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.vcard-category { align-self: flex-start; font-size: .75rem; font-weight: 700; color: var(--v-red, #c32c35); background: #fdeeee; padding: 3px 10px; border-radius: 999px; text-decoration: none; }
.vcard-title { font-size: 1rem; line-height: 1.9; margin: 0; font-weight: 800; }
.vcard-title a { color: var(--v-ink, #172d40); text-decoration: none; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.vcard-title a:hover { color: var(--v-red, #c32c35); }
.vcard-meta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: auto; color: var(--v-muted, #647587); font-size: .78rem; }
.vcard-meta i { margin-inline-end: 4px; }

/* Featured */
.vcard--featured { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); border-radius: 26px; box-shadow: 0 24px 60px rgba(18, 57, 87, .12); }
.vcard--featured .vcard-media { aspect-ratio: auto; min-height: 340px; }
.vcard--featured .vcard-play { width: 84px; height: 84px; margin: -42px 0 0 -42px; font-size: 1.8rem; }
.vcard--featured .vcard-body { padding: 34px 32px; justify-content: center; gap: 12px; }
.vcard-eyebrow { font-size: .78rem; font-weight: 800; color: var(--v-muted, #647587); letter-spacing: .02em; }
.vcard--featured .vcard-title { font-size: clamp(1.25rem, 2.2vw, 1.7rem); line-height: 1.7; }
.vcard-summary { color: #4c5d6e; line-height: 2; margin: 0; display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.vcard--featured .vcard-meta { margin-top: 4px; }
.vcard-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin-top: 10px; }
.vcard-button { border: 0; display: inline-flex; align-items: center; gap: 8px; padding: 12px 24px; border-radius: 14px; background: linear-gradient(135deg, #dc3945, #bd232e); color: #fff; font-weight: 800; box-shadow: 0 12px 26px rgba(195, 44, 53, .28); transition: transform .2s; }
.vcard-button:hover { transform: translateY(-2px); }
.vcard-link { color: var(--v-navy, #123957); font-weight: 700; text-decoration: none; }
.vcard-link:hover { color: var(--v-red, #c32c35); }

.videos-empty { text-align: center; padding: 60px 20px; color: var(--v-muted); background: #f7f9fb; border-radius: 20px; }
.videos-empty i { font-size: 2.6rem; margin-bottom: 12px; color: #b3c1ce; }

/* Player dialog */
.video-modal { width: min(1100px, calc(100vw - 24px)); max-width: none; padding: 0; border: 0; border-radius: 22px; background: #0b1624; color: #e9f0f6; overflow: visible; }
.video-modal::backdrop { background: rgba(4, 10, 18, .82); backdrop-filter: blur(4px); }
.video-modal__panel { position: relative; }
.video-modal__stage { aspect-ratio: 16 / 9; background: #000; border-radius: 22px 22px 0 0; overflow: hidden; }
.video-modal__stage iframe, .video-modal__stage video { width: 100%; height: 100%; border: 0; display: block; background: #000; }
.video-modal__info { display: flex; align-items: flex-start; gap: 20px; padding: 18px 24px 22px; }
.video-modal__text { flex: 1; min-width: 0; }
.video-modal__text h2 { font-size: 1.1rem; margin: 0 0 4px; color: #fff; line-height: 1.8; }
.video-modal__meta { color: #9fb2c4; font-size: .8rem; margin: 0 0 6px; }
.video-modal__summary { color: #c9d6e2; font-size: .88rem; line-height: 1.9; margin: 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.video-modal__actions { display: flex; align-items: center; gap: 8px; flex: none; }
.video-modal__nav { width: 42px; height: 42px; border-radius: 12px; border: 1px solid rgba(255, 255, 255, .18); background: rgba(255, 255, 255, .06); color: #fff; }
.video-modal__nav:disabled { opacity: .3; }
.video-modal__link { padding: 10px 16px; border-radius: 12px; background: #fff; color: #0b1624; font-weight: 800; text-decoration: none; font-size: .85rem; }
.video-modal__close { position: absolute; top: -16px; left: -16px; width: 44px; height: 44px; border-radius: 50%; border: 0; background: #fff; color: #0b1624; font-size: 1.2rem; box-shadow: 0 8px 20px rgba(0, 0, 0, .35); }

/* Video page */
.video-page { --v-navy: #123957; --v-red: #c32c35; --v-ink: #172d40; --v-muted: #647587; --v-line: #e1e8ef; padding-block: 12px 64px; }
.video-page__grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 32px; align-items: start; }
.video-page__player { aspect-ratio: 16 / 9; background: #000; border-radius: 22px; overflow: hidden; box-shadow: 0 24px 60px rgba(8, 30, 50, .22); }
.video-page__player iframe, .video-page__player video { width: 100%; height: 100%; border: 0; display: block; }
.video-page__missing { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; color: #9fb2c4; }
.video-page__header { padding: 22px 4px 8px; display: flex; flex-direction: column; gap: 10px; }
.video-page__header h1 { font-size: clamp(1.35rem, 2.6vw, 1.9rem); line-height: 1.7; color: var(--v-ink); font-weight: 900; margin: 0; }
.video-page__meta { display: flex; flex-wrap: wrap; gap: 18px; color: var(--v-muted); font-size: .85rem; }
.video-page__meta i { margin-inline-end: 5px; }
.video-page__share { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding-top: 6px; color: var(--v-muted); font-size: .85rem; }
.video-page__share a, .video-page__share button { width: 38px; height: 38px; border-radius: 12px; display: inline-flex; align-items: center; justify-content: center; background: #f1f5f9; color: var(--v-navy); border: 0; text-decoration: none; transition: background .2s, color .2s; }
.video-page__share a:hover, .video-page__share button:hover, .video-page__share button.is-copied { background: var(--v-navy); color: #fff; }
.video-page__description { margin: 18px 0 0; padding: 24px 26px; background: #f8fafc; border: 1px solid var(--v-line); border-radius: 20px; max-width: none; }
.video-page__cta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; margin-top: 24px; padding: 22px 26px; border-radius: 20px; background: linear-gradient(125deg, #0a2c47, #0d4167 60%, #0b5483); color: #fff; }
.video-page__cta strong { display: block; font-size: 1.05rem; }
.video-page__cta span { color: rgba(232, 241, 247, .85); font-size: .9rem; }
.video-page__cta a { display: inline-flex; align-items: center; gap: 10px; padding: 12px 22px; border-radius: 14px; background: #fff; color: #0b1624; text-decoration: none; font-weight: 800; }
.video-page__side { position: sticky; top: 100px; background: #fff; border: 1px solid var(--v-line); border-radius: 22px; padding: 20px; }
.video-page__side h2 { font-size: 1.05rem; color: var(--v-navy); font-weight: 800; margin: 0 0 14px; }
.related-videos { list-style: none; padding: 0; margin: 0 0 14px; display: flex; flex-direction: column; gap: 12px; }
.related-videos a { display: flex; gap: 12px; text-decoration: none; color: var(--v-ink); border-radius: 14px; padding: 4px; transition: background .2s; }
.related-videos a:hover { background: #f4f7fa; }
.related-videos__thumb { position: relative; flex: 0 0 132px; aspect-ratio: 16 / 9; border-radius: 10px; overflow: hidden; background: #0d2c45; display: flex; align-items: center; justify-content: center; color: rgba(255, 255, 255, .5); }
.related-videos__thumb img { width: 100%; height: 100%; object-fit: cover; }
.related-videos__thumb .vcard-duration { bottom: 5px; left: 5px; font-size: .66rem; }
.related-videos__text { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.related-videos__text strong { font-size: .86rem; line-height: 1.8; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.related-videos__text small { color: var(--v-muted); font-size: .74rem; }

@media (max-width: 1199px) { .vgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .video-page__grid { grid-template-columns: minmax(0, 1fr) 300px; } }
@media (max-width: 991px) {
    .vcard--featured { grid-template-columns: 1fr; }
    .vcard--featured .vcard-media { min-height: 0; aspect-ratio: 16 / 9; }
    .video-page__grid { grid-template-columns: 1fr; }
    .video-page__side { position: static; }
}
@media (max-width: 575px) {
    .vgrid { grid-template-columns: 1fr; gap: 18px; }
    .videos-search { min-width: 0; width: 100%; }
    .vcard--featured .vcard-body { padding: 22px 20px; }
    .video-modal { border-radius: 16px; }
    .video-modal__stage { border-radius: 16px 16px 0 0; }
    .video-modal__info { flex-direction: column; padding: 14px 16px 18px; }
    .video-modal__close { top: -12px; left: -6px; width: 38px; height: 38px; }
    .video-page__player { border-radius: 16px; margin-inline: -4px; }
}
@media (prefers-reduced-motion: reduce) { .vcard, .vcard-media img, .vcard-play { transition: none; } }
