.ypp-wrap{
  width:100%;
  max-width:600px;
  margin:0 auto;
}

.ypp-player{
  --ypp-brand:#8B6CFF;
  --ypp-brand-soft:#B9A7FF;
  --ypp-brand-pink:#FF73D2;

  position:relative;
  width:100%;
  aspect-ratio:9 / 13.2;
  overflow:hidden;
  border-radius:18px;
  background:#07090f;

  border:1px solid rgba(255,255,255,.16);

  box-shadow:
    0 24px 70px rgba(0,0,0,.58),
    0 0 0 1px rgba(255,255,255,.04) inset,
    0 0 36px rgba(139,108,255,.10);

  isolation:isolate;
}

.ypp-frame{
  position:relative;
  width:100%;
  height:100%;
  overflow:hidden;
  border-radius:inherit;
  background:#07090f;
  isolation:isolate;
}

.ypp-frame::before{
  content:"";
  position:absolute;
  inset:0;
  z-index:3;
  pointer-events:none;
  border-radius:inherit;
  box-shadow:
    inset 0 0 0 1px rgba(255,255,255,.10),
    inset 0 0 32px rgba(0,0,0,.28);
}

.ypp-frame::after{
  content:"";
  position:absolute;
  left:0;
  right:0;
  bottom:0;
  height:34%;
  z-index:2;
  pointer-events:none;
  background:linear-gradient(
    to top,
    rgba(0,0,0,.82) 0%,
    rgba(0,0,0,.55) 38%,
    rgba(0,0,0,.18) 72%,
    transparent 100%
  );
}

.ypp-video{
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
  object-fit:cover;
  object-position:center;
  display:block;
  background:#07090f;
}

.ypp-player .ypp-big-play{
  position:absolute;
  left:50%;
  top:50%;
  z-index:5;
  width:82px;
  height:82px;
  border-radius:50%;
  transform:translate(-50%,-50%);
  display:flex;
  align-items:center;
  justify-content:center;
  padding:0;
  min-width:0;
  margin:0;
  box-sizing:border-box;
  appearance:none;
  color:#fff;
  cursor:pointer;

  background:
    linear-gradient(180deg, rgba(255,255,255,.10), rgba(255,255,255,.03)),
    rgba(5,7,12,.78);

  border:1px solid rgba(255,255,255,.12);
  outline:none;

  backdrop-filter:blur(14px);
  -webkit-backdrop-filter:blur(14px);

  box-shadow:
    inset .8px .8px 0 rgba(255,255,255,.16),
    inset -.8px -.8px 0 rgba(255,255,255,.05),
    0 14px 34px rgba(0,0,0,.48),
    0 0 26px rgba(139,108,255,.18);

  transition:
    transform .22s ease,
    opacity .22s ease,
    box-shadow .22s ease,
    background .22s ease;
}

.ypp-big-play svg{
  width:39px;
  height:39px;
  margin-left:5px;
  fill:#ffffff;
  filter:drop-shadow(0 2px 4px rgba(0,0,0,.32));
}

.ypp-player:hover .ypp-big-play{
  background:
    linear-gradient(180deg, rgba(185,167,255,.16), rgba(139,108,255,.08)),
    rgba(5,7,12,.82);

  box-shadow:
    inset .8px .8px 0 rgba(185,167,255,.22),
    inset -.8px -.8px 0 rgba(255,115,210,.08),
    0 16px 40px rgba(0,0,0,.52),
    0 0 30px rgba(139,108,255,.34),
    0 0 54px rgba(255,115,210,.12);
}

.ypp-player.is-playing .ypp-big-play{
  opacity:0;
  pointer-events:none;
  transform:translate(-50%,-50%) scale(.92);
}

.ypp-bottom{
  position:absolute;
  left:22px;
  right:22px;
  bottom:17px;
  z-index:6;

  display:grid;
  grid-template-columns:26px auto 1fr auto 26px;
  align-items:center;
  gap:12px;
}

/* Strong reset for Elementor/theme button styles */
.ypp-player .ypp-play-btn,
.ypp-player .ypp-fullscreen{
  width:26px;
  height:26px;
  min-width:26px;
  min-height:26px;

  border:0;
  border-radius:8px;
  padding:0;
  margin:0;

  background:transparent;
  background-color:transparent;
  background-image:none;

  color:#ffffff;

  display:flex;
  align-items:center;
  justify-content:center;

  cursor:pointer;
  opacity:.96;

  box-shadow:none;
  outline:none;

  appearance:none;
  -webkit-appearance:none;

  transition:
    opacity .18s ease,
    transform .18s ease,
    filter .18s ease,
    background .18s ease,
    box-shadow .18s ease;
}

/* Purple only on hover/focus/click */
.ypp-player .ypp-play-btn:hover,
.ypp-player .ypp-play-btn:focus-visible,
.ypp-player .ypp-fullscreen:hover,
.ypp-player .ypp-fullscreen:focus-visible{
  background:rgba(139,108,255,.18);
  background-color:rgba(139,108,255,.18);

  opacity:1;
  transform:scale(1.08);

  box-shadow:
    0 0 0 1px rgba(185,167,255,.22) inset,
    0 0 12px rgba(139,108,255,.45),
    0 0 22px rgba(255,115,210,.12);

  filter:drop-shadow(0 0 7px rgba(139,108,255,.55));
}

.ypp-player .ypp-play-btn:active,
.ypp-player .ypp-fullscreen:active{
  background:rgba(139,108,255,.32);
  background-color:rgba(139,108,255,.32);

  transform:scale(.96);

  box-shadow:
    0 0 0 1px rgba(185,167,255,.35) inset,
    0 0 16px rgba(139,108,255,.58),
    0 0 28px rgba(255,115,210,.18);
}

.ypp-play-btn svg{
  width:25px;
  height:25px;
  fill:currentColor;
  pointer-events:none;
}

.ypp-fullscreen svg{
  width:23px;
  height:23px;
  fill:none;
  stroke:currentColor;
  stroke-width:2;
  stroke-linecap:round;
  stroke-linejoin:round;
  pointer-events:none;
}

.ypp-icon-pause{
  display:none;
}

.ypp-player.is-playing .ypp-icon-play{
  display:none;
}

.ypp-player.is-playing .ypp-icon-pause{
  display:block;
}

.ypp-time{
  color:rgba(255,255,255,.88);
  font-size:13px;
  font-weight:600;
  line-height:1;
  letter-spacing:.01em;
  font-family:inherit;
  white-space:nowrap;
  text-shadow:0 2px 8px rgba(0,0,0,.55);
}

.ypp-progress{
  width:100%;
  height:18px;
  margin:0;
  padding:0;
  cursor:pointer;
  appearance:none;
  -webkit-appearance:none;
  background:transparent;
  outline:none;

  --ypp-progress-value:0%;
}

.ypp-progress::-webkit-slider-runnable-track{
  height:4px;
  border-radius:999px;
  background:
    linear-gradient(
      to right,
      var(--ypp-brand) 0%,
      var(--ypp-brand-soft) var(--ypp-progress-value),
      rgba(255,255,255,.22) var(--ypp-progress-value),
      rgba(255,255,255,.22) 100%
    );
  box-shadow:
    0 0 10px rgba(139,108,255,.32),
    inset 0 0 0 1px rgba(255,255,255,.05);
}

.ypp-progress::-moz-range-track{
  height:4px;
  border-radius:999px;
  background:rgba(255,255,255,.22);
}

.ypp-progress::-moz-range-progress{
  height:4px;
  border-radius:999px;
  background:linear-gradient(90deg, var(--ypp-brand), var(--ypp-brand-soft));
  box-shadow:0 0 10px rgba(139,108,255,.32);
}

.ypp-progress::-webkit-slider-thumb{
  -webkit-appearance:none;
  appearance:none;
  width:13px;
  height:13px;
  border-radius:50%;
  margin-top:-4.5px;
  background:var(--ypp-brand);
  border:2px solid rgba(255,255,255,.82);
  box-shadow:
    0 0 0 4px rgba(139,108,255,.18),
    0 0 14px rgba(139,108,255,.82),
    0 2px 8px rgba(0,0,0,.38);
}

.ypp-progress::-moz-range-thumb{
  width:13px;
  height:13px;
  border-radius:50%;
  background:var(--ypp-brand);
  border:2px solid rgba(255,255,255,.82);
  box-shadow:
    0 0 0 4px rgba(139,108,255,.18),
    0 0 14px rgba(139,108,255,.82),
    0 2px 8px rgba(0,0,0,.38);
}

/* Fullscreen fix: keep the video frame vertical */
.ypp-player:fullscreen{
  width:100vw;
  height:100vh;
  max-width:none;
  aspect-ratio:auto;
  border-radius:0;
  border:0;
  box-shadow:none;
  background:#05070f;
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
}

.ypp-player:-webkit-full-screen{
  width:100vw;
  height:100vh;
  max-width:none;
  aspect-ratio:auto;
  border-radius:0;
  border:0;
  box-shadow:none;
  background:#05070f;
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
}

.ypp-player:fullscreen .ypp-frame{
  width:min(100vw, calc(100vh * 9 / 13.2));
  height:min(100vh, calc(100vw * 13.2 / 9));
  border-radius:18px;
  border:1px solid rgba(255,255,255,.16);
  box-shadow:
    0 24px 70px rgba(0,0,0,.58),
    0 0 0 1px rgba(255,255,255,.04) inset,
    0 0 36px rgba(139,108,255,.16);
}

.ypp-player:-webkit-full-screen .ypp-frame{
  width:min(100vw, calc(100vh * 9 / 13.2));
  height:min(100vh, calc(100vw * 13.2 / 9));
  border-radius:18px;
  border:1px solid rgba(255,255,255,.16);
  box-shadow:
    0 24px 70px rgba(0,0,0,.58),
    0 0 0 1px rgba(255,255,255,.04) inset,
    0 0 36px rgba(139,108,255,.16);
}

.ypp-player:fullscreen .ypp-video,
.ypp-player:-webkit-full-screen .ypp-video{
  width:100%;
  height:100%;
  object-fit:cover;
  object-position:center;
}

@media(max-width:767px){
  .ypp-wrap{
    max-width:100%;
  }

  .ypp-player{
    border-radius:16px;
  }

  .ypp-player .ypp-big-play{
    width:70px;
    height:70px;
  }

  .ypp-big-play svg{
    width:34px;
    height:34px;
  }

  .ypp-bottom{
    left:16px;
    right:16px;
    bottom:14px;
    grid-template-columns:24px auto 1fr auto 24px;
    gap:9px;
  }

  .ypp-time{
    font-size:12px;
  }

  .ypp-player .ypp-play-btn,
  .ypp-player .ypp-fullscreen{
    width:24px;
    height:24px;
    min-width:24px;
    min-height:24px;
    border-radius:7px;
  }

  .ypp-play-btn svg{
    width:23px;
    height:23px;
  }

  .ypp-fullscreen svg{
    width:21px;
    height:21px;
  }

  .ypp-player:fullscreen .ypp-frame,
  .ypp-player:-webkit-full-screen .ypp-frame{
    border-radius:16px;
  }
}




.ypp-player{--ypp-brand:#8B8BE4;--ypp-brand-soft:#B9B9F1;--ypp-brand-pink:#8B8BE4}
.ypp-wrap{max-width:none;margin:0;width:100%}
.ypp-player:not(.custom-ready) .ypp-big-play,.ypp-player:not(.custom-ready) .ypp-bottom,
.ypp-player.native-fallback .ypp-big-play,.ypp-player.native-fallback .ypp-bottom{display:none}
.ypp-player .ypp-progress{padding:0;border:0}

.ypp-player{aspect-ratio:16/9}.ypp-video{object-fit:contain}.ypp-progress{min-width:0}
.ypp-player:fullscreen .ypp-frame,.ypp-player:-webkit-full-screen .ypp-frame{width:min(100vw,calc(100vh*16/9));height:min(100vh,calc(100vw*9/16));border-radius:0}
.ypp-player:fullscreen .ypp-video,.ypp-player:-webkit-full-screen .ypp-video{object-fit:contain}
.ypp-player button:focus-visible,.ypp-player input:focus-visible{outline:2px solid #c7c7ff;outline-offset:4px}
@media(max-width:767px){.ypp-player{border-radius:12px}.ypp-player .ypp-big-play{width:54px;height:54px}.ypp-big-play svg{width:29px;height:29px}.ypp-bottom{left:8px;right:8px;bottom:2px;gap:6px;grid-template-columns:44px auto minmax(0,1fr) auto 44px}.ypp-player .ypp-play-btn,.ypp-player .ypp-fullscreen{width:44px;height:44px;min-width:44px;min-height:44px}.ypp-progress{height:44px}.ypp-time{font-size:10px}}
@media(prefers-reduced-motion:reduce){.ypp-player *{transition:none}}

/* Pillar uses the existing editable Elementor media container. */
.yp-page .yp-video .ypp-player{--ypp-skin-ready:1;width:100%;height:100%;max-width:none;aspect-ratio:auto;border:0;border-radius:inherit;box-shadow:none}
.yp-page .yp-video .ypp-frame{height:100%;border-radius:inherit}
.yp-page .yp-video .ypp-video{object-fit:contain}
.yp-page .yp-video .ypp-player:fullscreen{width:100vw;height:100vh;border-radius:0}
.yp-page .yp-video .ypp-player:fullscreen .ypp-frame{width:100%;height:100%;border-radius:0}
.yp-page .yp-video .ypp-player:-webkit-full-screen .ypp-frame{width:100%;height:100%;border-radius:0}

/* A real film owns its intrinsic frame; native width and aspect controls remain editable. */
:where(.yp-page) .yp-film:has(.yp-video video){--yp-film-height:0px;--yp-film-ratio:var(--ypp-source-ratio,16 / 9);align-self:start}
/* Outrank Elementor's hosted-video cover rule regardless of stylesheet load order. */
.yp-video.elementor-widget-video .ypp-frame video.ypp-video{object-fit:contain;object-position:center;width:100%;height:100%;max-width:100%;max-height:100%}
