/* ==========================================================================
   MOBCASH - VIDEO BLOCK, FULLSCREEN POPUP & VIDEO PAGES
   ========================================================================== */

:root {
  --v-bg: #0a111a;
  --v-card: #16263b;
  --v-border: rgba(43, 114, 186, 0.22);
  --v-text: #f3f6fa;
  --v-muted: #94a9c4;
  --v-primary: #20aaff;
  --v-gold: #ffb703;
}

/* ---------- Home: video block ---------- */
.video-section {
  padding: 30px 0 10px;
}

.video-grid {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-bottom: 8px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}

.video-card {
  flex: 0 0 62vw;
  max-width: 240px;
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  background: var(--v-card);
  border: 1px solid var(--v-border);
  border-radius: 14px;
  overflow: hidden;
  color: var(--v-text);
  text-decoration: none;
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.video-card:hover,
.video-card:focus-visible {
  transform: translateY(-4px);
  border-color: var(--v-primary);
  box-shadow: 0 6px 20px rgba(0, 0, 0, .45);
}

.video-card-media {
  position: relative;
  display: block;
  aspect-ratio: 9 / 13;
  background: #0e1824;
}

.video-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.video-card-play {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(to top, rgba(10, 17, 26, .55), rgba(10, 17, 26, 0) 55%);
}

.video-card-play .material-symbols-outlined {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 34px;
  color: #fff;
  background: rgba(0, 136, 204, .92);
  border-radius: 50%;
  box-shadow: 0 0 22px rgba(0, 168, 255, .45);
  font-variation-settings: 'FILL' 1;
}

.video-card-dur {
  position: absolute;
  right: 8px;
  bottom: 8px;
  padding: 2px 7px;
  font-size: .72rem;
  font-weight: 700;
  color: #fff;
  background: rgba(0, 0, 0, .7);
  border-radius: 6px;
}

.video-card-title {
  padding: 10px 12px 2px;
  font-size: .9rem;
  font-weight: 700;
  line-height: 1.3;
}

.video-card-desc {
  padding: 0 12px 12px;
  font-size: .76rem;
  line-height: 1.4;
  color: var(--v-muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

@media (min-width: 768px) {
  .video-grid {
    overflow: visible;
    gap: 20px;
  }

  .video-card {
    flex: 1 1 0;
    max-width: 250px;
  }
}

/* ---------- Fullscreen vertical popup ---------- */
.vpop[hidden] {
  display: none;
}

.vpop {
  position: fixed;
  inset: 0;
  z-index: 3000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.vpop-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(3, 7, 12, .94);
}

.vpop-stage {
  position: relative;
  height: 100vh;
  height: 100dvh;
  aspect-ratio: 9 / 16;
  max-width: 100vw;
  background: #000;
}

.vpop-video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
  display: block;
}

.vpop-close,
.vpop-nav {
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 50%;
  color: #fff;
  background: rgba(10, 17, 26, .7);
  cursor: pointer;
  z-index: 2;
}

.vpop-close {
  top: max(12px, env(safe-area-inset-top));
  right: 12px;
}

.vpop-nav {
  top: 50%;
  transform: translateY(-50%);
}

.vpop-prev { left: -60px; }
.vpop-next { right: -60px; }

@media (max-width: 700px) {
  .vpop-prev { left: 8px; }
  .vpop-next { right: 8px; }
  .vpop-nav { top: 38%; }
}

.vpop-bar {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  padding: max(14px, env(safe-area-inset-top)) 68px 28px 14px;
  background: linear-gradient(to bottom, rgba(0, 0, 0, .75), rgba(0, 0, 0, 0));
  pointer-events: none;
  z-index: 1;
}

.vpop-title {
  font-size: .95rem;
  font-weight: 700;
  line-height: 1.3;
  color: #fff;
  text-shadow: 0 1px 4px rgba(0, 0, 0, .8);
}

.vpop-cta {
  position: fixed;
  pointer-events: auto;
  visibility: hidden;
}

/* CTA sits at the bottom of the stage, above the native video controls */
.vpop-stage .vpop-cta {
  position: absolute;
  visibility: visible;
  left: 14px;
  right: 14px;
  bottom: calc(64px + env(safe-area-inset-bottom));
  padding: 13px 16px;
  font-size: .95rem;
  font-weight: 800;
  color: #1a1200;
  background: var(--v-gold);
  border: 0;
  border-radius: 12px;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(255, 183, 3, .35);
  z-index: 2;
}

body.vpop-open {
  overflow: hidden;
}

/* ---------- Video landing pages ---------- */
.vp-body {
  margin: 0;
  background: var(--v-bg);
  color: var(--v-text);
  font-family: system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.55;
}

.vp-body *, .vp-body *::before, .vp-body *::after { box-sizing: border-box; }
.vp-body a { color: var(--v-primary); }

.vp-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  background: #0e1824;
  border-bottom: 1px solid var(--v-border);
}

.vp-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  color: #fff !important;
  text-decoration: none;
}

.vp-crumbs {
  font-size: .8rem;
  color: var(--v-muted);
  display: flex;
  gap: 6px;
}

.vp-crumbs a { color: var(--v-muted); text-decoration: none; }

.vp-main {
  max-width: 1000px;
  margin: 0 auto;
  padding: 16px;
}

.vp-article {
  display: grid;
  gap: 24px;
  grid-template-columns: 1fr;
}

.vp-player {
  width: 100%;
  max-width: 420px;
  margin: 0 auto;
  background: #000;
  border-radius: 16px;
  overflow: hidden;
  aspect-ratio: 9 / 16;
  max-height: 82vh;
  max-height: 82dvh;
}

.vp-player video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  background: #000;
}

@media (min-width: 860px) {
  .vp-article {
    grid-template-columns: minmax(300px, 380px) 1fr;
    align-items: start;
  }

  .vp-player {
    position: sticky;
    top: 16px;
  }
}

.vp-kicker {
  margin: 0 0 6px;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--v-gold);
}

.vp-info h1 {
  margin: 0 0 10px;
  font-size: clamp(1.4rem, 4vw, 2rem);
  line-height: 1.2;
}

.vp-info h2 {
  margin: 28px 0 10px;
  font-size: 1.1rem;
}

.vp-desc {
  margin: 0 0 18px;
  color: var(--v-muted);
}

.vp-cta {
  display: inline-block;
  margin: 0 8px 8px 0;
  padding: 12px 20px;
  font-weight: 800;
  text-decoration: none;
  color: #1a1200 !important;
  background: var(--v-gold);
  border-radius: 12px;
}

.vp-cta-ghost {
  color: #fff !important;
  background: transparent;
  border: 1px solid var(--v-border);
}

.vp-points {
  margin: 0;
  padding-left: 20px;
  color: var(--v-muted);
}

.vp-transcript {
  padding: 14px 16px;
  background: var(--v-card);
  border: 1px solid var(--v-border);
  border-radius: 12px;
  color: var(--v-muted);
  font-size: .92rem;
}

.vp-transcript p { margin: 0 0 10px; }
.vp-transcript p:last-child { margin: 0; }

.vp-related {
  display: grid;
  gap: 12px;
}

.vp-rel {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 8px;
  color: var(--v-text) !important;
  text-decoration: none;
  background: var(--v-card);
  border: 1px solid var(--v-border);
  border-radius: 12px;
}

.vp-rel img {
  width: 56px;
  height: 100px;
  object-fit: cover;
  border-radius: 8px;
  flex: none;
}

.vp-rel span { display: flex; flex-direction: column; gap: 2px; }
.vp-rel small { color: var(--v-muted); }

.vp-footer {
  max-width: 1000px;
  margin: 20px auto 0;
  padding: 20px 16px 32px;
  font-size: .8rem;
  color: var(--v-muted);
  border-top: 1px solid var(--v-border);
}

.vp-footer p { margin: 0 0 6px; }
