body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  background-color: #f9f9f9;
}

header {
  background-color: #181f39;
  padding: 15px;
  text-align: center;
}

header img {
  height: 60px;
}

main {
  padding: 40px 20px;
  text-align: center;
}

main h1 {
  color: #181f39;
  font-size: 2rem;
  margin-bottom: 10px;
  font-weight: bold;
}

.subtitulo {
  margin-bottom: 30px;
  color: #555;
  font-size: 18px;
}

.productos {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 30px;
}

.tarjeta {
  background-color: white;
  border: 1px solid #ddd;
  border-radius: 12px;
  width: 220px;
  padding: 15px;
  text-align: center;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  transition: transform 0.2s, box-shadow 0.2s;
}

.tarjeta img {
  width: 100%;
  max-height: 120px;
  object-fit: contain;
  margin-bottom: 10px;
}

.tarjeta h3 {
  font-size: 1.1rem;
  color: #181f39;
  margin: 10px 0 5px;
}

.tarjeta p {
  font-size: 1rem;
  color: #ed8015;
  margin-bottom: 10px;
  font-weight: bold;
}

.tarjeta a {
  display: inline-block;
  padding: 8px 12px;
  background-color: #181f39;
  color: white;
  text-decoration: none;
  border-radius: 6px;
  font-weight: bold;
  transition: background-color 0.2s;
}

.tarjeta a:hover {
  background-color: #ed8015;
}

/* Responsive para móviles */
@media (max-width: 600px) {
  .productos {
    flex-direction: column;
    align-items: center;
  }

  .tarjeta {
    width: 90%;
  }
}


/* ===== CARRITO MINIMIZABLE (MÓVIL FRIENDLY) ===== */
#carrito.carrito-panel{
  position: fixed;
  right: 16px;
  bottom: 76px; /* deja espacio para el botón flotante */
  width: 320px;
  max-width: calc(100vw - 32px);
  background: #fff;
  border: 2px solid #181f39;
  border-radius: 14px;
  padding: 12px;
  z-index: 9999;
  box-shadow: 0 10px 30px rgba(0,0,0,.25);
}

#carrito.carrito-panel.carrito-cerrado{
  display: none;
}

#carrito .carrito-top{
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

#carrito .carrito-min{
  border: none;
  background: #181f39;
  color: #fff;
  font-weight: 800;
  border-radius: 10px;
  padding: 6px 10px;
  cursor: pointer;
}

#lista-carrito{
  max-height: 220px;
  overflow: auto;
}

/* Botón flotante */
#carrito-fab{
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 10000;
  border: none;
  cursor: pointer;
  background: #181f39;
  color: #fff;
  font-weight: 800;
  border-radius: 999px;
  padding: 10px 12px;
  display: none; /* se muestra cuando hay productos */
  box-shadow: 0 10px 25px rgba(0,0,0,.25);
}

#carrito-fab .count{
  display: inline-flex;
  min-width: 22px;
  height: 22px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #ed8015;
  margin-left: 8px;
  padding: 0 6px;
  font-size: 12px;
}



/* Botón carrito móvil */
#btn-carrito-movil{
  display:none;
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 10000;
  border: none;
  background: #181f39;
  color: #fff;
  font-weight: 800;
  border-radius: 999px;
  padding: 10px 14px;
  cursor: pointer;
  box-shadow: 0 10px 25px rgba(0,0,0,.25);
}

#contador-carrito{
  background:#ed8015;
  border-radius:999px;
  padding:2px 8px;
  margin-left:8px;
  font-size:12px;
}

/* ===== Carrito: acciones (Vaciar / WhatsApp) ===== */
#carrito .acciones{
  display:flex;
  gap:8px;
  margin-top:10px;
}
#carrito .acciones button,
#carrito .acciones a{
  flex:1;
  text-align:center;
  padding:8px;
  border-radius:6px;
  font-weight:bold;
  border:none;
  cursor:pointer;
  text-decoration:none;
  display:block;
}
#vaciar{ background:#181f39; color:#fff; }
#vaciar:hover{ background:#ed8015; }
#whatsapp{ background:#25d366; color:#fff; }
