body {
  margin: 0;
  background: #f8f2e7;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

#canvas-container {
  position: relative;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

canvas {
  display: block;
  width: 100vw !important;
  max-width: 100vw;
  height: auto !important;
  max-height: 100vh;
  object-fit: contain;
}

.video-overlay-wrapper {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  z-index: 20;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px;
}

.video-overlay {
  position: relative;
  display: block;
  width: auto;
  max-width: 95vw;
  max-height: 95vh;
  height: auto;
  object-fit: contain;
  border-radius: 12px;
  background: #000;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.35);
}

.video-close-btn {
  position: absolute;
  top: -10px;
  right: -10px;
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.82);
  color: #fff;
  font-size: 18px;
  cursor: pointer;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 30;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.35);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s ease;
}

.video-close-btn:hover {
  background: rgba(0, 0, 0, 0.95);
  opacity: 1;
}

.video-overlay-wrapper:hover .video-close-btn,
.video-overlay-wrapper:focus-within .video-close-btn,
.video-close-btn:focus-visible {
  opacity: 1;
  pointer-events: auto;
}

.video-loading {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.5);
  color: #fff;
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-size: 14px;
  border-radius: 12px;
}
