/* ===== pagos.css — Estilos exclusivos de Métodos de Pago ===== */

/* Sección de Pagos */
.pagos-section {
  min-height: 100vh;
  align-items: flex-start;
  padding-top: 7rem;
  background-color: var(--bg-main); /* #fafafa */
}

/* Grid de Tarjetas */
.pagos-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 2rem;
  justify-items: center;
  max-width: 1000px;
  margin: 0 auto;
  padding: 1rem;
}

/* ===== Tarjeta Estilo Animada (Adaptada a Morado) ===== */
.card-pago {
  width: 220px;
  height: 300px;
  background:  #5d04ecfc; /* #5a21b6 */
  border-radius: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: white;
  transition: 0.2s ease-in-out;
  position: relative; /* Necesario para posicionar el icono absolute */
  overflow: hidden; /* Para que el blur no se salga */
  cursor: pointer;
  box-shadow: 0 10px 20px rgba(90, 33, 182, 0.2);
}

/* Icono SVG */
.card-pago-icon {
  height: 35%;
  width: auto; /* Para imágenes */
  position: absolute;
  transition: 0.2s ease-in-out;
  z-index: 1;
  object-fit: contain;
}

/* Caja de Texto (oculta por defecto) */
.textBox {
  opacity: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: 0.2s ease-in-out;
  z-index: 2;
  padding: 0 1rem;
  text-align: center;
}

.textBox > .head {
  font-size: 1.1rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #ffffff;
  margin: 0;
}

.textBox > span {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.7);
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 600;
}

.textBox > .description {
  font-size: 0.8rem;
  color: #e2e8f0;
  line-height: 1.4;
  margin: 0;
}

/* ===== Animaciones Hover ===== */
.card-pago:hover > .textBox {
  opacity: 1;
}

.card-pago:hover > .card-pago-icon {
  height: 70%; /* El icono crece */
  filter: blur(6px); /* Se difumina */
  opacity: 0.4; /* Se vuelve semitransparente */
  animation: anim 3s infinite;
}

.card-pago:hover {
  transform: scale(1.04) rotate(-1deg);
  box-shadow: 0 15px 30px rgba(90, 33, 182, 0.4);
}

@keyframes anim {
  0% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-20px);
  }
  100% {
    transform: translateY(0);
  }
}

/* Responsive */
@media (max-width: 640px) {
  .pagos-grid {
    gap: 1.5rem;
  }
  
  .card-pago {
    width: 100%;
    max-width: 300px;
  }
}

/* Ajuste para imágenes (img) dentro de las tarjetas */
img.card-pago-icon {
  width: auto;
  max-width: 50%; /* Para que no se salgan si el SVG es muy ancho */
  height: 35%;
  object-fit: contain;
}

/* Hover para imágenes */
.card-pago:hover > img.card-pago-icon {
  height: 70%;
  max-width: 80%;
  filter: blur(6px);
  opacity: 0.4;
  animation: anim 3s infinite;
}