/**
 * Estilos personalizados para WooCommerce - Magna Jewelry
 * Estos estilos personalizan la galería de imágenes y etiquetas en las páginas de producto
 */

/* Personalización de la etiqueta de oferta */
.woocommerce span.onsale {
  background-color: #e5b85c; /* Dorado elegante */
  color: #ffffff;
  font-weight: 600;
  font-size: 0.85em;
  padding: 0.5em 1em;
  border-radius: 50px;
  min-height: auto;
  min-width: auto;
  line-height: normal;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  z-index: 10;
  left: 1em;
  top: 1em;
}

/* Contenedor principal de la galería */
.woocommerce-product-gallery {
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  background-color: #ffffff;
  padding: 10px;
  transition: all 0.3s ease !important;
  width: 100% !important;
}

/* Añadir un ligero efecto hover al contenedor */
.woocommerce-product-gallery:hover {
  box-shadow: 0 6px 25px rgba(0, 0, 0, 0.12);
}

/* Wrapper interno de la galería */
.woocommerce-product-gallery__wrapper {
  margin: 0;
  padding: 0;
}

/* Imagen principal */
.woocommerce-product-gallery__image {
  border-radius: 6px;
  overflow: hidden;
}

.woocommerce-product-gallery__image a {
  display: block;
  position: relative;
}

.woocommerce-product-gallery__image a:hover::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.2);
  z-index: 1;
}

/* Zoom icon */
.woocommerce-product-gallery__image a::before {
  content: "+";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 50px;
  height: 50px;
  background: rgba(229, 184, 92, 0.85); /* Dorado con transparencia */
  color: white;
  border-radius: 50%;
  font-size: 28px;
  line-height: 50px;
  text-align: center;
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 5;
}

.woocommerce-product-gallery__image a:hover::before {
  opacity: 1;
}

/* Imágenes en miniatura */
.woocommerce-product-gallery__image--thumbnail {
  border-radius: 4px;
  overflow: hidden;
  margin: 5px;
  border: 2px solid transparent;
  transition: all 0.2s ease;
}

.woocommerce-product-gallery__image--thumbnail:hover {
  border-color: #e5b85c;
  transform: translateY(-2px);
}

/* Imágenes de miniaturas en la parte inferior */
.woocommerce-product-gallery ol.flex-control-nav {
  display: flex;
  justify-content: center;
  margin-top: 10px;
  padding: 0;
  list-style: none;
}

.woocommerce-product-gallery ol.flex-control-nav li {
  margin: 0 5px;
}

.woocommerce-product-gallery ol.flex-control-nav li img {
  border: 2px solid transparent;
  border-radius: 4px;
  transition: all 0.2s ease;
  max-width: 60px;
  height: auto;
}

.woocommerce-product-gallery ol.flex-control-nav li img.flex-active,
.woocommerce-product-gallery ol.flex-control-nav li img:hover {
  border-color: #e5b85c;
}

/* Mejoras responsivas */
@media (max-width: 768px) {
  .woocommerce-product-gallery {
    padding: 5px;
  }

  .woocommerce-product-gallery ol.flex-control-nav li img {
    max-width: 50px;
  }
}

/* Placeholder de imagen */
.woocommerce-product-gallery__image--placeholder img {
  border: 1px dashed #ddd;
  padding: 20px;
}

/* Personalización de las notificaciones de WooCommerce */
.woocommerce-notices-wrapper {
  max-width: 100%;
  margin: 20px auto;
  font-family: inherit;
}

/* Mensaje básico de WooCommerce (incluye "producto agregado al carrito") */
.woocommerce-message {
  position: relative;
  display: flex;
  flex-direction: row-reverse;
  align-items: center;
  justify-content: space-between;
  background-color: #f8f9fa;
  border-left: 4px solid #e5b85c;
  color: #4a4a4a;
  font-weight: 500;
  padding: 15px 20px;
  margin-bottom: 20px;
  border-radius: 6px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.07);
  transition: all 0.3s ease;
  animation: wooMessageSlideIn 0.4s ease forwards;
}

@keyframes wooMessageSlideIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Estilos para el botón "Ver carrito" */
.woocommerce-message .button.wc-forward {
  margin-left: 15px;
  padding: 10px 18px;
  background-color: #e5b85c;
  color: white;
  border-radius: 4px;
  font-weight: 600;
  font-size: 0.9em;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  text-decoration: none;
  transition: all 0.2s ease;
  white-space: nowrap;
  box-shadow: 0 2px 5px rgba(229, 184, 92, 0.3);
}

.woocommerce-message .button.wc-forward:hover {
  background-color: #d4a84b;
  box-shadow: 0 4px 8px rgba(229, 184, 92, 0.4);
  transform: translateY(-2px);
}

/* Icono de confirmación */
.woocommerce-message::before {
  content: "";
  display: inline-block;
  width: 22px;
  height: 22px;
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%23e5b85c"><path d="M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"/></svg>');
  background-size: contain;
  background-repeat: no-repeat;
  margin-right: 12px;
}

/* Mensajes de error */
.woocommerce-error {
  background-color: #fff8f8;
  border-left: 4px solid #e53e3e;
  color: #4a4a4a;
  font-weight: 500;
  padding: 15px 20px;
  margin-bottom: 20px;
  border-radius: 6px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.07);
  list-style: none;
  animation: wooMessageSlideIn 0.4s ease forwards;
}

.woocommerce-error::before {
  content: "";
  display: inline-block;
  width: 22px;
  height: 22px;
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%23e53e3e"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-2h2v2zm0-4h-2V7h2v6z"/></svg>');
  background-size: contain;
  background-repeat: no-repeat;
  margin-right: 12px;
}

/* Mensajes de información */
.woocommerce-info {
  background-color: #f8faff;
  border-left: 4px solid #4299e1;
  color: #4a4a4a;
  font-weight: 500;
  padding: 15px 20px;
  margin-bottom: 20px;
  border-radius: 6px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.07);
  animation: wooMessageSlideIn 0.4s ease forwards;
}

.woocommerce-info::before {
  content: "";
  display: inline-block;
  width: 22px;
  height: 22px;
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%234299e1"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-2h2v2zm0-4h-2V7h2v6z"/></svg>');
  background-size: contain;
  background-repeat: no-repeat;
  margin-right: 12px;
}

.woocommerce ul.products li.product,
.woocommerce-page ul.products li.product {
  width: 30% !important; /* Dos productos por fila */
  margin: 0 !important; /* Espacio entre productos */
  margin-left: 10px !important; /* Espacio entre productos */
}

/* Adaptaciones móviles */
@media (max-width: 768px) {
  .woocommerce-message,
  .woocommerce-error,
  .woocommerce-info {
    padding: 12px 15px;
    flex-wrap: wrap;
  }

  .woocommerce-message .button.wc-forward {
    margin: 10px 0 0 0;
    width: 100%;
    text-align: center;
  }

  /* Estilos responsive para tarjetas de producto en smartphone */
  .woocommerce ul.products li.product, 
  .woocommerce-page ul.products li.product {
    width: 100% !important;
    margin: 0 !important;
    margin-bottom: 10px !important; /* Espacio entre productos */
  }
}

/* Estilos para tablets */
@media (min-width: 769px) and (max-width: 1024px) {
  .woocommerce ul.products li.product,
  .woocommerce-page ul.products li.product {
    width: 100% !important;
  }
}

/* Timestamp para forzar actualización: 1754343689 */
