* {
  box-sizing: border-box;
}

:root {
  --yp-bg: #02030a;
  --yp-panel: rgba(10, 14, 26, 0.78);
  --yp-panel-2: rgba(18, 24, 42, 0.72);
  --yp-line: rgba(125, 245, 255, 0.18);
  --yp-line-red: rgba(255, 56, 119, 0.18);
  --yp-text: #f7fbff;
  --yp-muted: #9fb2c8;
  --yp-red-power: 0.30;
  --yp-cyan-power: 0.28;
  --yp-depth: 8px;
  --yp-focal: 45;
  --yp-pixel-lens: 9px;
  --yp-relief: 38;
  --yp-fit: contain;
}

html,
body {
  margin: 0;
  min-height: 100%;
  color: var(--yp-text);
  font-family: Inter, Arial, Helvetica, sans-serif;
  background:
    radial-gradient(circle at 15% 0%, rgba(0, 234, 255, 0.22), transparent 28%),
    radial-gradient(circle at 85% 18%, rgba(255, 0, 98, 0.20), transparent 26%),
    radial-gradient(circle at 50% 100%, rgba(92, 76, 255, 0.16), transparent 34%),
    #02030a;
}

.yp-app {
  min-height: 100vh;
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.yp-player {
  width: min(1220px, 100%);
  position: relative;
  overflow: hidden;
  border: 1px solid var(--yp-line);
  border-radius: 34px;
  background:
    linear-gradient(145deg, rgba(9, 14, 28, 0.96), rgba(5, 7, 16, 0.94)),
    rgba(10, 12, 24, 0.96);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.04) inset,
    0 0 60px rgba(0, 234, 255, 0.12),
    0 0 90px rgba(255, 0, 98, 0.10),
    0 34px 110px rgba(0, 0, 0, 0.68);
  backdrop-filter: blur(18px);
}

.yp-player::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, transparent 0 49%, rgba(0, 234, 255, 0.045) 50%, transparent 51%),
    linear-gradient(0deg, transparent 0 49%, rgba(255, 255, 255, 0.028) 50%, transparent 51%);
  background-size: 42px 42px;
  pointer-events: none;
  opacity: 0.5;
}

.yp-topbar,
.yp-content {
  position: relative;
  z-index: 1;
}

.yp-topbar {
  padding: 20px;
  border-bottom: 1px solid var(--yp-line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.yp-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.yp-logo {
  width: 54px;
  height: 54px;
  flex: 0 0 auto;
  border-radius: 19px;
  display: grid;
  place-items: center;
  color: #001014;
  background:
    radial-gradient(circle at 32% 26%, #ffffff, #7df5ff 38%, #ff2d78 100%);
  box-shadow:
    0 0 24px rgba(0, 234, 255, 0.42),
    0 0 30px rgba(255, 45, 120, 0.20);
}

.yp-logo span {
  font-size: 1.45rem;
  font-weight: 950;
}

.yp-brand h1 {
  margin: 0;
  font-size: clamp(1.5rem, 4vw, 2.3rem);
  letter-spacing: -0.055em;
  text-shadow: -2px 0 rgba(255, 0, 98, 0.45), 2px 0 rgba(0, 234, 255, 0.45);
}

.yp-brand p {
  margin: 6px 0 0;
  color: var(--yp-muted);
  font-size: 0.92rem;
}

.yp-top-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.yp-btn,
.yp-mini {
  border: 1px solid rgba(125, 245, 255, 0.18);
  cursor: pointer;
  color: #eafcff;
  background:
    linear-gradient(180deg, rgba(31, 44, 74, 0.92), rgba(16, 22, 39, 0.92));
  border-radius: 16px;
  padding: 11px 15px;
  font-weight: 850;
  letter-spacing: -0.01em;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.035) inset,
    0 10px 28px rgba(0, 0, 0, 0.24);
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.yp-btn:hover,
.yp-mini:hover {
  transform: translateY(-1px);
  border-color: rgba(125, 245, 255, 0.55);
  box-shadow: 0 0 24px rgba(0, 234, 255, 0.18);
}

.yp-btn-light,
.yp-active {
  color: #001014;
  background: linear-gradient(135deg, #ffffff, #7df5ff);
  border-color: rgba(255, 255, 255, 0.65);
}

.yp-btn-wide {
  width: 100%;
  margin-top: 10px;
}

.yp-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
}

.yp-stage-wrap {
  padding: 20px;
}

.yp-stage {
  width: 100%;
  aspect-ratio: 16 / 9;
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(125, 245, 255, 0.22);
  border-radius: 28px;
  background:
    radial-gradient(circle at center, rgba(125, 245, 255, 0.10), transparent 48%),
    #000;
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.04) inset,
    0 0 42px rgba(0, 234, 255, 0.14);
}

.yp-hologrid::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 2;
  background:
    linear-gradient(90deg, rgba(125,245,255,0.055) 1px, transparent 1px),
    linear-gradient(0deg, rgba(125,245,255,0.04) 1px, transparent 1px);
  background-size: 24px 24px;
  opacity: 0.34;
}

.yp-placeholder {
  height: 100%;
  padding: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  flex-direction: column;
  color: var(--yp-muted);
  position: relative;
  z-index: 4;
}

.yp-placeholder h2 {
  color: #ffffff;
  margin: 14px 0 8px;
  font-size: clamp(1.18rem, 4vw, 1.75rem);
  letter-spacing: -0.035em;
}

.yp-placeholder p {
  margin: 0;
  max-width: 450px;
  line-height: 1.5;
}

.yp-3d-icon {
  width: 72px;
  height: 72px;
  border: 1px solid rgba(125, 245, 255, 0.32);
  border-radius: 24px;
  display: grid;
  place-items: center;
  font-weight: 950;
  letter-spacing: -0.08em;
  color: #ffffff;
  background: rgba(255,255,255,0.04);
  text-shadow: -5px 0 red, 5px 0 cyan;
  box-shadow: 0 0 34px rgba(0, 234, 255, 0.16);
}

.yp-media,
.yp-frame,
.yp-projector-canvas {
  display: none;
  width: 100%;
  height: 100%;
  border: 0;
  position: relative;
  z-index: 1;
  object-fit: var(--yp-fit);
  background: #000000;
}

.yp-frame {
  background: #ffffff;
}

.yp-projector-canvas {
  position: absolute;
  inset: 0;
  z-index: 5;
  pointer-events: none;
}

.yp-anaglyph::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  mix-blend-mode: screen;
  background:
    linear-gradient(90deg,
      rgba(255, 0, 88, var(--yp-red-power)),
      transparent 48%,
      rgba(0, 234, 255, var(--yp-cyan-power))
    );
  transform:
    translateX(calc(var(--yp-depth) * 0.25))
    skewX(calc(var(--yp-depth) * 0.06deg));
}

.yp-anaglyph .yp-media,
.yp-anaglyph .yp-frame {
  filter:
    drop-shadow(calc(var(--yp-depth) * -1) 0 0 rgba(255, 0, 70, var(--yp-red-power)))
    drop-shadow(var(--yp-depth) 0 0 rgba(0, 235, 255, var(--yp-cyan-power)))
    saturate(1.18)
    contrast(1.08);
}

.yp-projector {
  filter: contrast(1.18) brightness(1.08) saturate(1.24);
}

.yp-projector::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  mix-blend-mode: screen;
  opacity: calc(0.25 + var(--yp-relief) * 0.004);
  background:
    radial-gradient(circle at center, rgba(255, 255, 255, 0.18), transparent 22%),
    repeating-radial-gradient(circle at center,
      rgba(125, 245, 255, 0.12) 0,
      rgba(125, 245, 255, 0.12) 1px,
      transparent 2px,
      transparent var(--yp-pixel-lens)
    ),
    linear-gradient(90deg, rgba(255, 0, 90, 0.18), transparent, rgba(0, 234, 255, 0.18));
  transform:
    perspective(900px)
    translateZ(calc(var(--yp-focal) * 0.4px))
    scale(calc(1 + var(--yp-focal) * 0.0009));
}

.yp-projector .yp-media,
.yp-projector .yp-frame {
  filter:
    drop-shadow(calc(var(--yp-focal) * -0.09px) 0 calc(var(--yp-focal) * 0.03px) rgba(255, 0, 76, 0.55))
    drop-shadow(calc(var(--yp-focal) * 0.09px) 0 calc(var(--yp-focal) * 0.03px) rgba(0, 234, 255, 0.55))
    contrast(1.16)
    brightness(1.05);
}

.yp-video-controls {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding-top: 16px;
}

.yp-control,
.yp-play {
  border: 1px solid rgba(125, 245, 255, 0.25);
  cursor: pointer;
  border-radius: 999px;
  font-weight: 950;
  box-shadow: 0 0 26px rgba(0, 234, 255, 0.10);
}

.yp-control {
  width: 66px;
  height: 52px;
  background: rgba(18, 24, 42, 0.90);
  color: #ffffff;
}

.yp-play {
  width: 72px;
  height: 72px;
  background: linear-gradient(135deg, #ffffff, #7df5ff);
  color: #001014;
  font-size: 1.25rem;
}

.yp-sidebar {
  border-left: 1px solid var(--yp-line);
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.yp-card {
  padding: 17px;
  border: 1px solid var(--yp-line);
  border-radius: 24px;
  background:
    linear-gradient(145deg, rgba(24, 31, 54, 0.76), rgba(10, 14, 26, 0.76));
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.22);
}

.yp-card-glow {
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.025) inset,
    0 0 32px rgba(0, 234, 255, 0.07);
}

.yp-card h2 {
  margin: 0 0 14px;
  font-size: 1.08rem;
  letter-spacing: -0.03em;
}

.yp-card label {
  color: #ddecff;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.9rem;
  margin: 14px 0 8px;
}

input[type="range"] {
  width: 100%;
  accent-color: #7df5ff;
}

.yp-projector-box {
  display: none;
  margin-top: 12px;
}

.yp-projector-box p,
.yp-small {
  color: var(--yp-muted);
  font-size: 0.82rem;
  line-height: 1.45;
  margin: 12px 0 0;
}

.yp-url-line {
  display: flex;
  gap: 8px;
}

.yp-url-line input {
  flex: 1;
  min-width: 0;
  color: #ffffff;
  background: rgba(5, 8, 18, 0.88);
  border: 1px solid var(--yp-line);
  border-radius: 15px;
  padding: 11px;
  outline: none;
}

.yp-url-line input:focus {
  border-color: rgba(125, 245, 255, 0.85);
  box-shadow: 0 0 18px rgba(0, 234, 255, 0.14);
}

.yp-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.yp-mini {
  padding: 12px 10px;
  font-size: 0.86rem;
}

body.yp-embed {
  background: transparent;
}

body.yp-embed .yp-app {
  min-height: auto;
  padding: 0;
  background: transparent;
}

body.yp-embed .yp-player {
  border-radius: 22px;
}

@media (max-width: 960px) {
  .yp-topbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .yp-top-actions {
    justify-content: flex-start;
  }

  .yp-content {
    grid-template-columns: 1fr;
  }

  .yp-sidebar {
    border-left: 0;
    border-top: 1px solid var(--yp-line);
  }
}

@media (max-width: 600px) {
  .yp-app {
    padding: 10px;
  }

  .yp-player {
    border-radius: 22px;
  }

  .yp-topbar,
  .yp-stage-wrap,
  .yp-sidebar {
    padding: 12px;
  }

  .yp-top-actions,
  .yp-btn,
  .yp-url-line {
    width: 100%;
  }

  .yp-url-line {
    flex-direction: column;
  }

  .yp-stage {
    border-radius: 20px;
  }

  .yp-grid {
    grid-template-columns: 1fr;
  }
}
