/* Jump Up – character video viewer (charvideo.js) */
.cv{position:fixed;top:0;right:0;bottom:0;left:0;z-index:40;background:rgba(20,14,48,.78);display:flex;align-items:center;justify-content:center;
  padding:max(16px,env(safe-area-inset-top)) 16px max(16px,env(safe-area-inset-bottom));-webkit-tap-highlight-color:transparent}
.cv[hidden]{display:none}
html.cv-open,html.cv-open body{overflow:hidden;overscroll-behavior:none}
.cv-card{position:relative;width:100%;max-width:420px;background:linear-gradient(160deg,#fff7c2,#ffe0f0);border-radius:30px;
  padding:18px 18px 18px;box-shadow:0 10px 0 rgba(43,35,80,.3);text-align:center;animation:cvIn .35s cubic-bezier(.2,1.4,.4,1) both}
@keyframes cvIn{from{transform:scale(.85);opacity:0}to{transform:none;opacity:1}}
.cv-stage{position:relative;width:100%;aspect-ratio:1/1;border-radius:22px;overflow:hidden;background:#fde7f1}
/* short windows (a laptop browser, a phone on its side): the square clip shrinks so the title and the button stay on screen */
.cv-stage{width:min(100%,calc(100vh - 230px));margin:0 auto}
@supports (height:100dvh){.cv-stage{width:min(100%,calc(100dvh - 230px))}}
.cv-card{max-height:calc(100% - 8px)}
.cv-still,.cv-video{position:absolute;top:0;right:0;bottom:0;left:0;width:100%;height:100%;object-fit:cover;display:block}
.cv-video{opacity:0;transition:opacity .25s ease}
.cv[data-state="playing"] .cv-video{opacity:1}
.cv-spin{position:absolute;inset-block-end:12px;inset-inline-start:12px;width:28px;height:28px;border-radius:50%;
  border:4px solid rgba(255,255,255,.7);border-top-color:#6d28d9;animation:cvSpin .9s linear infinite;display:none}
.cv[data-state="loading"] .cv-spin{display:block}
@keyframes cvSpin{to{transform:rotate(360deg)}}
.cv-title{color:#6d28d9;margin:12px 0 10px;font-size:26px;min-height:1px}
.cv-title:empty{margin:6px 0}
.cv-back{width:100%}
/* the ✕: 56px round, white on deep purple, sits on the card's top corner and stays above everything */
.cv-x{position:absolute;top:-14px;inset-inline-end:-10px;z-index:2;width:56px;height:56px;border-radius:50%;
  background:#2b2350;color:#fff;font-size:30px;font-weight:800;line-height:1;border:4px solid #fff;
  box-shadow:0 4px 0 rgba(0,0,0,.25);display:flex;align-items:center;justify-content:center;cursor:pointer}
.cv-x:active{transform:scale(.94)}
.cv-x:focus-visible,.cv-back:focus-visible{outline:4px solid var(--accent,#ffcc33);outline-offset:3px}
.cv-auto{height:6px;border-radius:99px;background:rgba(109,40,217,.15);margin-top:10px;overflow:hidden;display:none}
.cv-auto.run{display:block}
.cv-auto i{display:block;height:100%;width:100%;background:#6d28d9;transform-origin:right center}
.cv-auto.run i{animation:cvAuto var(--cv-auto,9s) linear both}
@keyframes cvAuto{from{transform:scaleX(1)}to{transform:scaleX(0)}}
/* big desktop screens: a bigger clip */
@media (min-width:1200px) and (min-height:800px){.cv-card{max-width:560px}}
/* a phone on its side (short and wide): the clip beside the title and the button, as big as the height allows */
@media (orientation:landscape) and (max-height:500px) and (min-width:560px){
  .cv-card{max-width:720px;width:auto;display:grid;grid-template-columns:auto minmax(220px,1fr);grid-template-rows:1fr auto auto 1fr;column-gap:18px;align-items:center;padding:14px}
  .cv-stage{grid-column:1;grid-row:1/5;width:calc(100vh - 76px);margin:0}
  @supports (height:100dvh){.cv-stage{width:calc(100dvh - 76px)}}
  .cv-title{grid-column:2;grid-row:2;margin:0 0 12px}
  .cv-title:empty{margin:0}
  .cv-back{grid-column:2;grid-row:3}
  .cv-auto{grid-column:2;grid-row:4;align-self:start}
}
@media (prefers-reduced-motion:reduce){.cv-card{animation:none}.cv-spin{animation:none}}
