@import url('https://fonts.googleapis.com/css2?family=Audiowide&family=Black+Ops+One&family=Changa+One:ital@0;1&family=Patua+One&family=Permanent+Marker&family=Righteous&family=Rowdies:wght@300;400;700&family=Special+Elite&family=Unbounded:wght@200..900&display=swap');
/* === Estilos Globales === */
:root {
  --bg-color: #f8fafc;
  --text-main: #1e293b;
  --text-muted: #64748b;
  --border-color: #e2e8f0;
  --primary-btn: #ffffff;
  --winner-bg: #a5f3fc;
  --delete-btn: #0066ff;
}

body {
  margin: 0;
  padding: 10px;
  font-family: "Segoe UI", sans-serif;
  background-color: var(--bg-color);
  color: var(--text-main);
  display: flex;
  flex-direction: column;
  align-items: center;
  min-height: 90vh;
}

/* header */
ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
a {
  text-decoration: none;
  color: inherit;
}

/* --- ESTILOS DEL HEADER Y MENÚ --- */
.header {
  display: flex;
  justify-content: center;
  align-items: center;
  position: fixed;
  top: 20px;
  z-index: 100;
  height: 60px;
  width: 50%;
}

.menu {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  max-width: 1152px; /* Equivalente aproximado a w-xl */
  height: 60px;
  padding: 6px 20px;
  border-radius: 50px;

  /* Efecto de cristal (Glassmorphism) */
  backdrop-filter: blur(25px) saturate(100%);
  -webkit-backdrop-filter: blur(25px) saturate(100%);
  background-color: rgba(255, 255, 255, 0.177);
  box-shadow: 0 1px 3px 0 rgba(31, 38, 135, 0.37);
}

.menu-list {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

/* --- ESTILOS DE LOS ENLACES Y ELEMENTOS --- */
.menu-links {
  display: flex;
  align-items: center;
  gap: 20px;
  font-weight: 600;
}

.logo-img {
  width: 52px;
}

.btn-contacto {
  background-color: #000c75;
  color: #ffffff;
  border-radius: 9999px;
  padding: 6px 10px;
  display: inline-block;
  transition: transform 0.2s ease;
}

.btn-contacto:hover {
  transform: scale(1.1);
}

/* --- RESPONSIVE (MÓVILES) --- */
@media (max-width: 720px) {
  .header {
    width: 100%;
  }
  .menu {
    width: 80%;
  }
}

.main-container {
  background-color: #ffffff;
  border-radius: 16px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
  padding: 40px;
  margin-top: 90px;
  display: flex;
  flex-wrap: wrap;
  gap: 50px;
  max-width: 1100px;
  width: 90%;
}

h1 {
  margin: 0;
  font-size: clamp(40px, 7vw, 50px);
  color: #3e94e6;
  font-family: changa one, cursive;
  font-weight: 400;
  text-align: center;
  width: 100%;

  /* font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif; */
}

h1 span {
  color:#000c75;

  /* font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif; */
}

/* === 1. Sección de la Ruleta === */
.wheel-section {
  position: relative;
  width: 500px;
  height: 500px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.wheel-container {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  overflow: hidden;
  position: relative;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

canvas {
  width: 100%;
  height: 100%;
  transition: transform 4s cubic-bezier(0.25, 0.1, 0.25, 1);
}

/* Velo inicial */
.wheel-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(255, 255, 255, 0.65);
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  z-index: 10;
  pointer-events: none;
  transition: opacity 0.4s ease;
}
.wheel-section.is-active .wheel-overlay {
  opacity: 0;
}
.overlay-text {
  margin-top: 80px;
  font-size: 20px;
  font-weight: 800;
  color: #0f172a;
  text-shadow: 0px 2px 4px rgba(255, 255, 255, 0.8);
}

/* Botón y Puntero Central */
.center-spin-btn {
  position: absolute;
  width: 60px;
  height: 60px;
  background-color: white;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
  cursor: pointer;
  z-index: 15;
  border: none;
  transition: transform 0.2s;
}
.center-spin-btn:hover {
  transform: scale(1.05);
}
.center-spin-btn:active {
  transform: scale(0.95);
}
.pointer-triangle {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 10px solid transparent;
  border-right: 10px solid transparent;
  border-bottom: 16px solid white;
  z-index: 14;
}
.play-icon {
  width: 0;
  height: 0;
  border-top: 10px solid transparent;
  border-bottom: 10px solid transparent;
  border-left: 16px solid #1e293b;
  margin-left: 4px; /* Centrado óptico */
}

/* === 2. Panel de Opciones === */
.options-section {
  flex: 1;
  display: flex;
  flex-direction: column;
}
h2 {
  margin: 0 0 8px 0;
  font-size: 24px;
  color: #0f172a;
}
.instruction {
  margin: 0 0 20px 0;
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.5;
  text-align: center;
}
textarea {
  flex: 1;
  width: 100%;
  resize: none;
  padding: 16px;
  border: 1px solid var(--border-color);
  border-radius: 12px;
  font-family: inherit;
  font-size: 15px;
  outline: none;
  box-sizing: border-box;
}
textarea:focus {
  border-color: #94a3b8;
}

/* === 3. Modal y Controles === */
/* ... (El CSS del Modal y Controles se mantiene intacto al anterior) ... */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.4);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 100;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.modal-overlay.show {
  opacity: 1;
  pointer-events: auto;
}
.modal-content {
  background: white;
  padding: 40px;
  border-radius: 16px;
  text-align: center;
  position: relative;
  min-width: 300px;
  transform: translateY(20px);
  transition: transform 0.3s ease;
}
.modal-overlay.show .modal-content {
  transform: translateY(0);
}
.close-btn {
  position: absolute;
  top: 16px;
  right: 16px;
  background: none;
  border: none;
  font-size: 20px;
  cursor: pointer;
  color: #64748b;
}
.modal-title {
  font-size: 22px;
  font-weight: 800;
  margin: 0 0 20px 0;
}
.winner-box {
  background-color: var(--winner-bg);
  font-size: 28px;
  font-weight: 800;
  padding: 15px 30px;
  border-radius: 12px;
  display: inline-block;
  margin-bottom: 25px;
}
.delete-option-btn {
  background-color: var(--delete-btn);
  color: white;
  border: none;
  padding: 12px 24px;
  border-radius: 24px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.delete-option-btn:hover {
  background-color: #0056d6;
}
.trash-icon {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.bottom-controls {
  margin-top: 30px;
  display: flex;
  gap: 20px;
  justify-content: space-around;
  width: 100%;
  max-width: 1100px;
}
.reset-btn {
  background-color: var(--primary-btn);
  border: 1px solid var(--border-color);
  padding: 10px 24px;
  border-radius: 24px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
}
.reset-btn:hover {
  background-color: #f1f5f9;
}
.reload-icon {
  display: inline-block;
  width: 14px;
  height: 14px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  position: relative;
}
.reload-icon::before {
  content: "";
  position: absolute;
  top: -2px;
  right: -2px;
  border: 4px solid transparent;
  border-top-color: currentColor;
  transform: rotate(45deg);
}

/* === 4. Diseño Responsivo === */
@media (max-width: 900px) {
  .main-container {
    flex-direction: column;
    align-items: center;
    padding: 30px 20px;
    gap: 40px;
    margin-top: 100px;
    margin-bottom: 20px;
  }

  .wheel-section {
    width: 100%;
    max-width: 450px;
    height: auto;
    aspect-ratio: 1 / 1; /* Mantiene la ruleta perfectamente cuadrada */
  }

  .options-section {
    width: 100%;
    max-width: 450px; /* Para que alinee visualmente con la ruleta */
  }

  textarea {
    min-height: 180px;
  }
  h2{
    text-align: center;
  }
}

@media (max-width: 480px) {
  .main-container {
    padding: 20px 15px;
    gap: 30px;
  }
  

  .overlay-text {
    font-size: 16px;
    margin-top: 50px;
  }

  .center-spin-btn {
    width: 50px;
    height: 50px;
  }

  .pointer-triangle {
    top: -10px;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 14px solid white;
  }

  .play-icon {
    border-top: 8px solid transparent;
    border-bottom: 8px solid transparent;
    border-left: 14px solid #1e293b;
  }

  .modal-content {
    padding: 30px 20px;
  }
}
