.pos-section {
  padding: 80px 6%;
  background: #f8fafc;
}

*{
    color: rgb(255, 255, 255);

}
.pos-title {
  text-align: center;
  font-size: 2.3rem;
  margin-bottom: 40px;
  color: rgb(255, 0, 0);
}
.cart-item span{
  color: black;
}
.catalog-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 30px;
}

/* FILTROS */
.pos-card h3{
  color: #111;
}
.filters h4 {
  margin: 20px 0 10px;
  color: #111;
}

.check {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  cursor: pointer;
  color: black;
}

.check input {
  display: none;
}

.check span {
  width: 18px;
  height: 18px;
  border-radius: 5px;
  border: 2px solid #cbd5f5;
}

.check input:checked + span {
  background: #eb2525;
  border-color: #eb2525;
}

/* GRID */
.pos-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 24px;
}

.pos-card {
  background: rgb(255, 255, 255);
  border-radius: 18px;
  padding: 18px;
  box-shadow: 0 12px 30px rgba(0,0,0,.08);
  display: flex;
  flex-direction: column;
}

.img-box {
  height: 190px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.img-box img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.desc {
  font-size: .9rem;
  color: rgb(0, 0, 0);
  margin-bottom: 4px; /* más compacto */
}

.price {
  font-weight: 700;
  margin-bottom: 4px; /* más compacto */
}

.actions {
  margin-top: 8px; /* antes era auto, ahora pequeño margen */
  display: flex;
  gap: 10px;
}

/* BOTONES */
.btn-primary {
  flex: 1;
  background: #ff0000;
  color: white;
  border: none;
  border-radius: 10px;
  padding: 10px;
  cursor: pointer;
}

.btn-outline {
  flex: 1;
  border: 1px solid #ff0000;
  background: transparent;
  color: #ff0000;
  border-radius: 10px;
  padding: 10px;
  cursor: pointer;
}

/* CARRITO */
.cart-float {
  position: fixed;
  top: 200px;
  right: 24px;
  background: #ff0000;
  color: #ff0000;
  padding: 14px 22px;
  border-radius: 999px;
  font-weight: 700;
  box-shadow: 0 12px 30px rgba(0,0,0,.3);
  z-index: 900;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

.cart-float.active {
  animation: pulse .4s ease;
}

@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.15); }
  100% { transform: scale(1); }
}

/* MODAL */
.modal-bg {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.55);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 2000;
}

/*FONDO DE LA TARJETA DEL DETALLE*/
.modal-card {
  background: rgb(0, 0, 0);
  padding: 30px;
  border-radius: 20px;
  max-width: 420px;
  width: 90%;
  position: relative;
}

.modal-card img {
  width: 100%;
  height: 220px;
  object-fit: contain;
}

.modal-close {
  position: absolute;
  top: 15px;
  right: 15px;
  background: #111;
  color: white;
  border: none;
  border-radius: 50%;
  width: 34px;
  height: 34px;
  cursor: pointer;
}

/* MODAL CARRITO */
.cart-items {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 10px;
}

.cart-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #f1f5f9;
  padding: 8px 12px;
  border-radius: 8px;
}

.remove-btn {
  background: #ef4444;
  color: white;
  border: none;
  border-radius: 6px;
  width: 28px;
  height: 28px;
  cursor: pointer;
  font-weight: bold;
}

.cart-total {
  font-weight: 700;
  margin-top: 10px;
  text-align: right;
}

/* RESPONSIVE */
@media (max-width: 900px) {
  .catalog-layout {
    grid-template-columns: 1fr;
  }

  .actions {
    margin-top: auto; /* en mobile vuelve a alinear abajo si se quiere */
  }
}

@media (max-width: 768px) {
  .cart-float {
    top: 240px;
    right: 16px;
  }
}
