body {
  font-family: 'Segoe UI', sans-serif;
  background: radial-gradient(circle at center, #fdf6f0, #f5d6ba);
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  margin: 0;
}

.contenedor {
  background: white;
  padding: 30px 25px;
  border-radius: 16px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
  width: 90%;
  max-width: 440px;
  text-align: center;
  position: relative;
}

h1 {
  color: #b91c1c;
  margin-bottom: 20px;
  font-size: 1.8em;
}

.campo {
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
}

label {
  font-weight: 600;
  color: #333;
}

input[type="text"], input[type="number"] {
  width: 100%;
  padding: 8px 10px;
  border: 2px solid #ddd;
  border-radius: 8px;
  font-size: 15px;
}

.btn-principal, .btn-secundario {
  padding: 10px 20px;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  font-size: 16px;
  color: white;
  transition: 0.3s;
}

.btn-principal {
  background-color: #b91c1c;
  width: 100%;
}

.btn-secundario {
  background-color: #991b1b;
  margin-top: 10px;
}

.btn-principal:hover, .btn-secundario:hover {
  opacity: 0.9;
}

/* === CAJA DE REGALO 3D === */
.caja3d {
  position: relative;
  width: 140px;
  height: 140px;
  margin: 30px auto;
  transform-style: preserve-3d;
  transform: rotateX(-15deg) rotateY(0deg);
  animation: girarCaja 3s ease-in-out infinite;
  animation-play-state: paused;
  perspective: 800px;
}

.cara {
  position: absolute;
  width: 140px;
  height: 140px;
  background: linear-gradient(145deg, #ffcccc, #b91c1c);
  border: 3px solid #991b1b;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 50px;
  color: white;
  box-shadow: inset 0 0 15px rgba(255,255,255,0.3), 0 5px 15px rgba(0,0,0,0.3);
}

.frente   { transform: translateZ(70px); }
.atras    { transform: rotateY(180deg) translateZ(70px); }
.derecha  { transform: rotateY(90deg) translateZ(70px); }
.izquierda{ transform: rotateY(-90deg) translateZ(70px); }
.arriba   { transform: rotateX(90deg) translateZ(70px); background: linear-gradient(145deg, #ffb3b3, #b91c1c); }
.abajo    { transform: rotateX(-90deg) translateZ(70px); background: #991b1b; }

@keyframes girarCaja {
  0% { transform: rotateX(-15deg) rotateY(0deg); }
  100% { transform: rotateX(-15deg) rotateY(360deg); }
}

.caja3d::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 6px;
  box-shadow: 0 0 25px rgba(255,255,255,0.5) inset;
  animation: brilloCaja 2s ease-in-out infinite alternate;
}

@keyframes brilloCaja {
  from { opacity: 0.6; }
  to { opacity: 1; }
}

/* === MODAL ELEGANTE === */
.modal {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.5);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.modal-contenido {
  background: white;
  padding: 30px;
  border-radius: 15px;
  text-align: center;
  box-shadow: 0 4px 25px rgba(0,0,0,0.4);
  animation: aparecer 0.4s ease;
}

.modal-contenido h2 {
  color: #b91c1c;
  margin-bottom: 10px;
}

.modal-contenido p {
  color: #333;
  margin-bottom: 15px;
}

.modal-contenido button {
  background: #b91c1c;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 16px;
  cursor: pointer;
}

@keyframes aparecer {
  from { opacity: 0; transform: scale(0.8); }
  to { opacity: 1; transform: scale(1); }
}


/* === BOTÓN PROBAR SUERTE (estilo rojo elegante) === */
#btnSuerte {
  background: #b91c1c;
  color: white;
  border: none;
  border-radius: 10px;
  padding: 10px 20px;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 3px 6px rgba(0,0,0,0.2);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

#btnSuerte:hover {
  background: #991b1b;
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

/* === BOTÓN GUARDAR GANADOR (solo disquete) === */
#btnGuardarGanador {
  background: #b91c1c;
  color: white;
  border: none;
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 22px;
  cursor: pointer;
  box-shadow: 0 3px 6px rgba(0,0,0,0.2);
  transition: all 0.2s ease-in-out;
}

#btnGuardarGanador:hover {
  background: #991b1b;
  transform: translateY(-2px);
}

/* === BOTONES DE ACCIONES INFERIORES (solo iconos rojos) === */
.acciones {
  margin-top: 25px;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
}

.acciones button {
  background: #b91c1c;
  color: white;
  border: none;
  border-radius: 12px;
  padding: 10px 16px;
  font-size: 20px;
  cursor: pointer;
  box-shadow: 0 3px 6px rgba(0,0,0,0.2);
  transition: all 0.25s ease;
}

.acciones button:hover {
  background: #991b1b;
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

.acciones button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}
