
/* NUJIZ ROTATION STUDIO V2 */

html body #nrvStudio{
  --nrv-text:#182337;
  --nrv-muted:#526078;
  --nrv-card:#f5f7fc;
  --nrv-border:#d6ddea;
  display:grid;
  gap:14px;
  margin:0 0 18px;
  color:var(--nrv-text)!important;
}

html[data-theme="dark"] body #nrvStudio{
  --nrv-text:#f5f6ff;
  --nrv-muted:#bfc9dd;
  --nrv-card:#202838;
  --nrv-border:#414c60;
}

html body #nrvStudio *{
  box-sizing:border-box;
}

html body #nrvStudio .nrv-header{
  display:flex;
  align-items:center;
  gap:13px;
  padding:18px;
  border-radius:15px;
  background:linear-gradient(135deg,#41277e,#7545d9);
}

html body #nrvStudio .nrv-header strong{
  display:block;
  font-size:19px!important;
  font-weight:800;
  color:#fff!important;
  -webkit-text-fill-color:#fff!important;
}

html body #nrvStudio .nrv-header small{
  display:block;
  font-size:13px!important;
  margin-top:5px;
  color:#e9dfff!important;
  -webkit-text-fill-color:#e9dfff!important;
}

html body #nrvStudio .nrv-logo{
  display:grid;
  place-items:center;
  width:48px;
  height:48px;
  border-radius:13px;
  background:#ffffff20;
  color:white!important;
  -webkit-text-fill-color:white!important;
  font-size:32px;
}

html body #nrvStudio h4{
  margin:5px 0 0;
  font-size:16px!important;
  font-weight:800;
  color:var(--nrv-text)!important;
  -webkit-text-fill-color:var(--nrv-text)!important;
}

html body #nrvStudio .nrv-grid{
  display:grid;
  gap:9px;
}

html body #nrvStudio .nrv-four{
  grid-template-columns:repeat(4,minmax(0,1fr));
}

html body #nrvStudio .nrv-two{
  grid-template-columns:repeat(2,minmax(0,1fr));
}

html body #nrvStudio .nrv-grid button{
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:8px;
  min-height:100px;
  padding:10px 4px;
  background:var(--nrv-card)!important;
  border:1px solid var(--nrv-border)!important;
  border-radius:12px;
  cursor:pointer;
  transition:background .2s,border-color .2s;
}

html body #nrvStudio .nrv-grid button b{
  font-size:13px!important;
  color:var(--nrv-text)!important;
  -webkit-text-fill-color:var(--nrv-text)!important;
}

html body #nrvStudio .nrv-grid button i{
  font-style:normal;
  font-size:30px!important;
  line-height:1;
  color:#9673ff!important;
  -webkit-text-fill-color:#9673ff!important;
}

html body #nrvStudio .nrv-grid button.active{
  background:linear-gradient(135deg,#7950eb,#5731bd)!important;
  border-color:#a48aff!important;
  box-shadow:0 3px 14px #7545d933;
}

html body #nrvStudio .nrv-grid button.active *{
  color:white!important;
  -webkit-text-fill-color:white!important;
}

html body #nrvStudio .nrv-state{
  font-size:12px!important;
  color:var(--nrv-muted)!important;
  -webkit-text-fill-color:var(--nrv-muted)!important;
}

html body #nrvStudio .nrv-info{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:9px;
}

html body #nrvStudio .nrv-info>div{
  padding:14px 6px;
  border:1px solid var(--nrv-border);
  border-radius:12px;
  background:var(--nrv-card);
  text-align:center;
}

html body #nrvStudio .nrv-info small{
  display:block;
  font-size:13px!important;
  color:var(--nrv-muted)!important;
  -webkit-text-fill-color:var(--nrv-muted)!important;
}

html body #nrvStudio .nrv-info strong{
  display:block;
  direction:ltr;
  margin-top:7px;
  font-size:17px!important;
  color:var(--nrv-text)!important;
  -webkit-text-fill-color:var(--nrv-text)!important;
}

html body #nrvStudio .nrv-live{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  padding:10px;
  background:#16a34a18;
  border:1px solid #16a34a55;
  border-radius:10px;
  color:#15803d!important;
  -webkit-text-fill-color:#15803d!important;
  font-size:14px!important;
  font-weight:700;
}

html[data-theme="dark"] body #nrvStudio .nrv-live{
  color:#86efac!important;
  -webkit-text-fill-color:#86efac!important;
}

#nrvStudio .nrv-live span{
  width:9px;
  height:9px;
  border-radius:50%;
  background:#22c55e;
}

html body #nrvReset{
  padding:12px;
  border-radius:10px;
  border:1px solid var(--nrv-border);
  background:var(--nrv-card)!important;
  color:var(--nrv-text)!important;
  -webkit-text-fill-color:var(--nrv-text)!important;
  font-size:14px!important;
  font-weight:700;
  cursor:pointer;
}

html body #videoPlayerStage:has(#nrvLivePreview){
  position:relative;
}

html body #nrvLivePreview{
  position:absolute;
  z-index:5;
  pointer-events:none;
  display:block;
  background:#000;
  max-width:none;
  max-height:none;
}



html body #nrvLivePreview[hidden],
html body #videoPlayerStage.result-visible #nrvLivePreview{
  display:none!important;
}

html body #videoPlayerStage.result-visible #videoPreview{
  opacity:1;
}

html body #nrvStudio button:disabled{
  opacity:.55;
  cursor:not-allowed;
}

@media(max-width:480px){
  html body #nrvStudio .nrv-four{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }

  html body #nrvStudio .nrv-grid button{
    min-height:88px;
  }
}


/* NUJIZ ROTATE PREVIEW V21 */

html body #videoPlayerStage #videoPreview{
  opacity:1!important;
  visibility:visible!important;
}

html body #videoPlayerStage #nrvLivePreview{
  z-index:5;
  pointer-events:none!important;
  clip-path:inset(0 0 42px 0);
}

html body #videoPlayerStage:has(
  #nrvLivePreview:not([hidden])
) #videoPreview{
  opacity:1!important;
}

html body #nrvLivePreview[hidden],
html body #videoPlayerStage.result-visible #nrvLivePreview{
  display:none!important;
}

html body #videoPlayerStage.result-visible #videoPreview{
  visibility:hidden!important;
}

html body #nrvStudio .nrv-header small{
  color:#f1eaff!important;
  -webkit-text-fill-color:#f1eaff!important;
  font-size:14px!important;
  font-weight:600!important;
}



/* NUJIZ ROTATE PREVIEW V22 */

html body #videoPlayerStage{
    background:#000!important;
    isolation:isolate;
}

html body #videoPlayerStage #videoPreview{
    background:#000!important;
    opacity:1!important;
}

/* Hide original picture only when rotated preview is ready */

html body #videoPlayerStage:has(
    #nrvLivePreview:not([hidden])
) #videoPreview{
    filter:brightness(0)!important;
}

/* Preserve native playback controls */

html body #videoPlayerStage #videoPreview::-webkit-media-controls{
    filter:none!important;
}

html body #videoPlayerStage:has(
    #nrvLivePreview:not([hidden])
) #videoPreview{
    filter:none!important;
    object-position:200vw 200vh!important;
}

html body #videoPlayerStage #nrvLivePreview{
    position:absolute!important;
    background:#000!important;
    z-index:5!important;
    pointer-events:none!important;
    clip-path:none!important;
}

html body #videoPlayerStage #nrvLivePreview[hidden]{
    display:none!important;
}

html body #videoPlayerStage.result-visible #nrvLivePreview{
    display:none!important;
}

html body #videoPlayerStage #videoPreview:not(
    :fullscreen
){
    object-fit:contain!important;
}



/* NUJIZ ROTATE CONTROLS SAFE AREA V23 */

html body #videoPlayerStage #nrvLivePreview{
    pointer-events:none!important;
    clip-path:none!important;
    border-radius:0!important;
}

html body #videoPlayerStage
#videoPreview::-webkit-media-controls-panel{
    background:linear-gradient(
      transparent,rgba(0,0,0,.85)
    )!important;
}

html body #videoPlayerStage
#videoPreview::-webkit-media-controls-current-time-display,
html body #videoPlayerStage
#videoPreview::-webkit-media-controls-time-remaining-display{
    color:#ffffff!important;
    -webkit-text-fill-color:#ffffff!important;
}

