/*Color*/
     .color-grid {
      display: flex;
      overflow-x: auto;
      padding-bottom: 10px;
      gap: 12px;
      scroll-snap-type: x mandatory;
      -webkit-overflow-scrolling: touch;
    }
    
    .color-option {
      scroll-snap-align: start;
      flex: 0 0 auto;
      width: 34px;
      height: 34px;
      border-radius: 50%;
      border: 2px solid #ccc; /* gris claro */
      cursor: pointer;
      transition: transform 0.2s, border-color 0.2s;
      display: flex;
      align-items: center;
      justify-content: center;
      position: relative;
    }
    
    .color-option:hover {
      transform: scale(1.2);
    }
    
    .color-option input {
      display: none;
    }
    
    .color-option:has(input:checked) {
      border-color: #000; /* negro al seleccionar */
    }
    
    .color-circle {
      width: 30px;
      height: 30px;
      border-radius: 50%;
      display: block;
    }
    /*Color*/

body {
      font-family: 'Segoe UI', sans-serif;
      background: #fff8f0;
      padding: 20px;
    }

    .container {
      max-width: 500px;
      margin: auto;
      background: white;
      padding: 30px;
      border-radius: 12px;
      box-shadow: 0 0 15px rgba(0,0,0,0.1);
    }

    .producto-titulo {
      font-size: 18px;
      font-weight: bold;
      margin-bottom: 10px;
      text-align: center;
    }

    label {
      display: block;
      margin-top: 15px;
      font-weight: bold;
    }

    select,
    input[type="number"] {
      width: 100%;
      padding: 10px;
      border-radius: 8px;
      border: 1px solid #ccc;
      margin-top: 5px;
      font-size: 1rem;
    }

    .cantidad-control {
      display: flex;
      align-items: center;
      gap: 10px;
    }

    .cantidad-control button {
      padding: 5px 10px;
      font-size: 1.2rem;
      cursor: pointer;
    }

    .submit-button {
      width: 100%;
      margin-top: 25px;
      padding: 12px;
      background-color: #222;
      color: white;
      font-size: 1rem;
      border: none;
      border-radius: 8px;
      cursor: pointer;
    }

    .submit-button:hover {
      background-color: #444;
    }

    #precioUnidad, #precioTotal {
      margin-top: 20px;
      font-size: 1.1rem;
      font-weight: bold;
      text-align: center;
      color: #000;
    }

    
     .cuadro-imagen {
      width: 280px;
      height: 280px;
      overflow: hidden;
      margin: 0 auto 20px;
      display: flex;
      justify-content: center;
      align-items: center;
      border-radius: 8px;
    }

    .cuadro-imagen img {
      width: 100%;
      height: 100%;
      object-fit: cover;
      object-position: center;
    }
    
    #toast {
      visibility: hidden;
      min-width: 250px;
      background-color: #323232;
      color: #fff;
      text-align: center;
      border-radius: 6px;
      padding: 12px;
      position: fixed;
      z-index: 1000;
      left: 50%;
      bottom: 30px;
      font-size: 16px;
      transform: translateX(-50%);
      opacity: 0;
      transition: opacity 0.5s ease, visibility 0.5s;
    }

    #toast.show {
      visibility: visible;
      opacity: 1;
    }

/* ===== EMPAQUES ESTILO TIENDA ===== */

.empaques-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 15px;
  margin-top: 15px;
}

.empaque-card {
  border: 2px solid #eee;
  border-radius: 12px;
  padding: 10px;
  text-align: center;
  cursor: pointer;
  transition: all 0.25s ease;
  background: #fff;
}

.empaque-card:hover {
  transform: scale(1.03);
  box-shadow: 0 6px 15px rgba(0,0,0,0.12);
}

.empaque-card input {
  display: none;
}

.empaque-card img {
  width: 100%;
  max-width: 90px;   /* 👈 controla el tamaño */
  height: auto;
  object-fit: contain;
  margin: 0 auto 6px;
  display: block;
}

.empaque-card span {
  font-size: 0.85rem;
  line-height: 1.2;
  display: block;
}

.empaque-card input:checked + img,
.empaque-card input:checked ~ span {
  border-color: #e28aa8;
}

.empaque-card input:checked ~ span {
  font-weight: 600;
  color: #e28aa8;
}

/* ===== AJUSTES GENERALES DEL CONTENEDOR ===== */

.container {
  max-width: 420px;
  margin: auto;
  padding: 15px;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.cuadro-imagen img {
  width: 100%;
  max-width: 260px;
  display: block;
  margin: auto;
  border-radius: 12px;
}

.producto-titulo {
  font-weight: 600;
  text-align: center;
  margin-bottom: 10px;
}
    
