html, body {
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  /* position: fixed; */
  /* top: 0; */
  /* left: 0; */
}
body {
  /* El fondo se moverá al pseudo-elemento */
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-family: 'Segoe UI', Verdana, Geneva, Tahoma, sans-serif;
  margin: 0;
}
body::before {
  content: "";
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  z-index: -1;
  background: linear-gradient(135deg, #74ebd5 0%, #ACB6E5 100%);
  background-image: url('fondo.png'), linear-gradient(135deg, #74ebd5 0%, #ACB6E5 100%);
  background-size: cover, cover;
  background-position: center, center;
  background-repeat: no-repeat, no-repeat;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  opacity: 1;
}
h1 {
  color: #1a237e;
  margin-bottom: 18px;
  text-shadow: 1px 1px 8px #fff8;
  font-size: 1.5em;
}
.ruleta-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  width: 100vw;
  max-width: 100vw;
  padding: 0;
}
.ruleta-wrapper {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  width: 100vw;
  max-width: 100vw;
  padding: 0;
}
.flecha-lateral {
  position: absolute;
  left: -18px;
  right: auto;
  top: 50%;
  transform: translateY(-50%) rotate(180deg);
  width: 0; height: 0;
  border-top: 28px solid transparent;
  border-bottom: 28px solid transparent;
  border-right: 44px solid #1a237e;
  border-left: none;
  margin: 0;
  z-index: 5;
  filter: drop-shadow(0 0 6px #fff8);
}
.ruleta {
  width: 98vw;
  height: 98vw;
  max-width: 540px;
  max-height: 540px;
  border-radius: 50%;
  border: 4px solid #1565c0;
  box-shadow: 0 4px 32px #0003;
  position: relative;
  overflow: hidden;
  background: #e3f2fd;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
}
.ruleta canvas {
  width: 96vw !important;
  height: 96vw !important;
  max-width: 520px !important;
  max-height: 520px !important;
  display: block;
  margin: 0 auto;
}
.girar-btn {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  background: linear-gradient(90deg, #2193b0 0%, #6dd5ed 100%);
  color: #1a237e;
  border: none;
  border-radius: 50%;
  width: 90px;
  height: 90px;
  font-size: 1.1em;
  font-weight: bold;
  cursor: pointer;
  box-shadow: 0 2px 12px #0002;
  transition: background 0.2s, transform 0.1s;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
}
.girar-btn:active {
  background: #1565c0;
  color: #fff;
  transform: translate(-50%, -50%) scale(0.97);
}
.premio {
  margin-top: 18px;
  font-size: 1.2em;
  color: #1a237e;
  min-height: 1.5em;
  text-align: center;
  font-weight: bold;
  text-shadow: 1px 1px 8px #fff, 0 0 4px #1976d2;
}
.fondo-fijo {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  width: 100vw;
  height: 100vh;
  z-index: 0;
  background: linear-gradient(135deg, #74ebd5 0%, #ACB6E5 100%);
  background-image: url('fondo.png'), linear-gradient(135deg, #74ebd5 0%, #ACB6E5 100%);
  background-size: cover, cover;
  background-position: center, center;
  background-repeat: no-repeat, no-repeat;
  opacity: 1;
  pointer-events: none;
}
.watermark {
  position: fixed;
  bottom: 8px;
  right: 10px;
  font-size: 0.78em;
  color: #1a237e;
  opacity: 0.18;
  pointer-events: none;
  z-index: 100;
  font-family: 'Segoe UI', Verdana, Geneva, Tahoma, sans-serif;
  user-select: none;
}
.watermark-izq {
  left: 10px;
  right: auto;
}
@media (max-width: 600px) {
  .ruleta {
    width: 99vw;
    height: 99vw;
    max-width: 370px;
    max-height: 370px;
    border-width: 3px;
  }
  .ruleta canvas {
    width: 97vw !important;
    height: 97vw !important;
    max-width: 350px !important;
    max-height: 350px !important;
  }
  .flecha-lateral {
    border-top: 16px solid transparent;
    border-bottom: 16px solid transparent;
    border-right: 28px solid #1a237e;
    border-left: none;
    left: -10px;
    right: auto;
    top: 50%;
    transform: translateY(-50%) rotate(180deg);
  }
  .girar-btn {
    width: 60px;
    height: 60px;
    font-size: 0.95em;
  }
  .watermark {
    left: 10px;
    right: auto;
    font-size: 0.39em;
  }
}
