/* Homepage "See how it all works" video: the v3 home (includes/site/v3/pages/home.php) and the
   v2 opt-out home (includes/site/pages/home.php). Added 2026-10-24.
   The player is a poster link. Nothing is downloaded until someone presses play: the <video> waits in a
   <template> and home-video.js swaps it in on click. Without JS the link opens the MP4 itself.
   Sizes inside the poster use container units, so the play button scales with the frame. */

/* 1. The player (both versions) ================================================ */
.cvm-vid { position: relative; z-index: 1; }
.cvm-vid__frame { position: relative; display: block; aspect-ratio: 16 / 9; overflow: hidden; container-type: inline-size; background: #FFF6E0; border-radius: 22px; box-shadow: 0 26px 56px rgba(8, 14, 40, .38); }
.cvm-vid__poster { position: absolute; inset: 0; display: block; color: #1E2A5A; text-decoration: none; cursor: pointer; }
.cvm-vid__poster picture, .cvm-vid__poster img { display: block; width: 100%; height: 100%; object-fit: cover; }
.cvm-vid__poster:focus-visible { outline: 4px solid #FFC93C; outline-offset: -8px; border-radius: 22px; }
.cvm-vid__cta { position: absolute; left: 7.8%; bottom: 10%; display: flex; align-items: center; gap: 14px; gap: 1.6cqw; }
.cvm-vid__play { position: relative; isolation: isolate; display: grid; place-items: center; width: 64px; width: max(42px, 9.4cqw); aspect-ratio: 1; flex: none; color: #1E2A5A; filter: drop-shadow(0 8px 16px rgba(30, 42, 90, .28)); transition: transform .25s cubic-bezier(.3, 1.6, .5, 1); }
.cvm-vid__play::before { content: ''; position: absolute; inset: 0; z-index: -1; background: #FFC93C; border-radius: 50%; }
.cvm-vid__play svg { width: 40%; height: 40%; margin-left: 9%; fill: currentColor; }
.cvm-vid__label { display: flex; flex-direction: column; font-size: 24px; font-size: max(15px, 3.3cqw); font-weight: 800; line-height: 1; text-transform: uppercase; color: #1E2A5A; }
.cvm-vid__label small { margin-top: 5px; margin-top: .5cqw; font-size: 12px; font-size: max(10px, 1.25cqw); font-weight: 800; letter-spacing: .06em; color: #5D5869; }
.cvm-vid__poster:hover .cvm-vid__play, .cvm-vid__poster:focus-visible .cvm-vid__play { transform: rotate(-8deg) scale(1.07); }
.cvm-vid video { position: absolute; inset: 0; display: block; width: 100%; height: 100%; background: #1E2A5A; }
.cvm-vid video:focus-visible { outline: 4px solid #FFC93C; outline-offset: -4px; }
@media (prefers-reduced-motion: reduce) { .cvm-vid__play { transition: none; } }

/* 2. v3: a navy band right after "Check it. Fix it. Apply." ===================== */
.v3 .cvm-vid__play::before { border-radius: 0; background: var(--sun); -webkit-mask: var(--v-blob-e) center / 100% 100% no-repeat; mask: var(--v-blob-e) center / 100% 100% no-repeat; }
.v3 .cvm-vid__label { font-family: var(--display); font-weight: 400; letter-spacing: .03em; -webkit-text-stroke: .02em currentColor; }
.v3 .cvm-vid__label small { font-family: var(--body); -webkit-text-stroke: 0; }
.v-vid { padding-top: clamp(72px, 8vw, 116px); }
.v-vid__grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: clamp(36px, 4.4vw, 64px); align-items: center; margin-top: clamp(44px, 5vw, 64px); }
.v-vid__art { position: relative; }
.v-vid__splat { position: absolute; z-index: 0; left: -4%; bottom: -14%; width: 30%; aspect-ratio: 1; transform: rotate(-12deg); }
.v-vid__splat2 { position: absolute; z-index: 0; right: -3%; top: -10%; width: 16%; aspect-ratio: 1; }
.v-vid__steps { display: grid; gap: 13px; margin: 0; padding: 0; list-style: none; counter-reset: vstep; }
.v-vid__steps li { position: relative; min-height: 38px; padding-left: 54px; font-size: 16.5px; line-height: 1.45; color: var(--on-navy); counter-increment: vstep; }
.v-vid__steps li::before { content: counter(vstep); position: absolute; left: 0; top: 0; display: grid; place-items: center; width: 38px; height: 38px; padding-top: 4px; font-family: var(--display); font-size: 24px; line-height: 1; color: var(--navy); background: var(--sun); border-radius: 50%; transform: rotate(-6deg); }
.v-vid__steps li:nth-child(6)::before { background: var(--mint); }
.v-vid__steps li:nth-child(7)::before { background: var(--tang); }
.v-vid__steps b { display: block; margin-bottom: 2px; font-family: var(--display); font-size: 26px; font-weight: 400; line-height: 1; letter-spacing: .02em; text-transform: uppercase; color: var(--cream); -webkit-text-stroke: .02em currentColor; }
@media (max-width: 980px) {
  .v-vid__grid { grid-template-columns: minmax(0, 1fr); max-width: 720px; margin-left: auto; margin-right: auto; }
}
@media (max-width: 640px) {
  .cvm-vid__frame { border-radius: 16px; }
  .v-vid__splat { bottom: -10%; width: 34%; }
  .v-vid__steps li { padding-left: 50px; font-size: 16px; }
  .v-vid__steps b { font-size: 25px; }
}

/* 3. v2 (the ?v3=0 opt-out): the same player in a plain section ================== */
.vid2-grid .cvm-vid__frame { box-shadow: 0 18px 40px rgba(30, 42, 90, .18); }
.vid2-grid { display: grid; grid-template-columns: minmax(0, 1.72fr) minmax(0, 1fr); gap: 40px; align-items: center; margin-top: 32px; }
.vid2-steps { display: grid; gap: 12px; margin: 0; padding-left: 1.4em; }
.vid2-steps b { display: block; }
@media (max-width: 900px) { .vid2-grid { grid-template-columns: minmax(0, 1fr); } }

/* Make it obviously a video (owner, 2026-10-25): big centred play button with a gentle pulse, a "Video 0:58"
   badge, and a player bar along the bottom. All decorative (the link carries the accessible label). */
.cvm-vid__cta { display: none; }
.cvm-vid__big { position: absolute; left: 50%; top: 46%; display: grid; justify-items: center; gap: 10px; gap: 1.2cqw; transform: translate(-50%, -50%); }
.cvm-vid__play--big { width: 104px; width: clamp(64px, 15cqw, 132px); }
.cvm-vid__play--big::after { content: ''; position: absolute; inset: -10%; z-index: -2; border: 4px solid #FFC93C; border-radius: 50%; opacity: 0; animation: cvm-vid-pulse 2.2s ease-out infinite; }
@keyframes cvm-vid-pulse { 0% { transform: scale(.85); opacity: .7; } 100% { transform: scale(1.35); opacity: 0; } }
.cvm-vid__hint { padding: 6px 14px; padding: .7cqw 1.7cqw; font-size: 15px; font-size: max(12px, 2cqw); font-weight: 900; letter-spacing: .04em; text-transform: uppercase; white-space: nowrap; color: #FFF6E0; background: #1E2A5A; border-radius: 999px; box-shadow: 0 6px 16px rgba(8, 12, 40, .25); }
.cvm-vid__badge { position: absolute; top: 4.5%; right: 3.5%; display: inline-flex; align-items: center; gap: 6px; gap: .8cqw; padding: 6px 12px; padding: .7cqw 1.5cqw; font-size: 13px; font-size: max(11px, 1.7cqw); font-weight: 900; letter-spacing: .06em; text-transform: uppercase; color: #FFF6E0; background: rgba(30, 42, 90, .92); border-radius: 999px; }
.cvm-vid__badge svg { width: 1.3em; height: 1.3em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linejoin: round; }
.cvm-vid__bar { position: absolute; left: 0; right: 0; bottom: 0; display: flex; align-items: center; gap: 12px; gap: 1.6cqw; padding: 26px 20px 14px; padding: 4cqw 2.8cqw 2cqw; color: #FFF6E0; background: linear-gradient(to top, rgba(20, 26, 58, .82), rgba(20, 26, 58, 0)); }
.cvm-vid__bar svg { flex: none; width: 18px; width: max(14px, 2.4cqw); height: auto; aspect-ratio: 1; }
.cvm-vid__bar-play { fill: currentColor; }
.cvm-vid__sound { fill: currentColor; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
.cvm-vid__sound path + path { fill: none; }
.cvm-vid__track { position: relative; flex: 1; height: 4px; height: max(3px, .55cqw); background: rgba(255, 246, 224, .35); border-radius: 999px; }
.cvm-vid__track i { position: absolute; left: 0; top: 50%; width: 12px; width: max(9px, 1.5cqw); aspect-ratio: 1; background: #FFC93C; border-radius: 50%; transform: translate(-30%, -50%); }
.cvm-vid__time { font-size: 13px; font-size: max(10px, 1.6cqw); font-weight: 800; font-variant-numeric: tabular-nums; }
.cvm-vid__poster:hover .cvm-vid__play--big, .cvm-vid__poster:focus-visible .cvm-vid__play--big { transform: rotate(-8deg) scale(1.08); }
.cvm-vid__play--big { transition: transform .2s cubic-bezier(.3, 1.4, .5, 1); }
.v3 .cvm-vid__hint { font-family: var(--display); font-weight: 400; font-size: max(16px, 2.6cqw); letter-spacing: .04em; }
@media (prefers-reduced-motion: reduce) { .cvm-vid__play--big::after { animation: none; opacity: .5; } .cvm-vid__play--big { transition: none; } }
