/* ==========================================================================
   COLORES DISPONIBLES · ficha de producto
   Fila HORIZONTAL dentro de los textos del producto (antes del botón de compra).
   ========================================================================== */

/* ---------- Tarjeta de colores ---------- */
.hv-colors-col {
  margin: 18px 0;
  padding: 16px 0;
  border-top: 1px solid var(--hvm-line, #e6eaf2);
  border-bottom: 1px solid var(--hvm-line, #e6eaf2);
}
.hv-colors-title {
  margin: 0 0 10px;
  padding: 0;
  color: var(--hv-primary, #092143);
  font:
    800 12px/1.3 Manrope,
    sans-serif;
  letter-spacing: 0.9px;
  text-transform: uppercase;
}
.hv-colors-current {
  min-height: 18px;
  margin: -4px 0 10px;
  padding: 0;
  color: var(--hvm-muted, #5d6b85);
  font-size: 13px;
  line-height: 1.4;
}
.hv-colors-col.has-selection .hv-colors-current {
  color: var(--hv-primary, #092143);
  font-weight: 700;
}
.hv-colors-col[data-mode="info"] .hv-colors-title {
  margin-bottom: 10px;
}

/* ---------- Lista vertical ---------- */
.hv-colors-list {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.hv-colors-list li {
  margin: 0;
  padding: 0;
}

.hv-swatch {
  display: flex;
  align-items: center;
  gap: 10px;
  width: auto;
  margin: 0;
  padding: 5px 14px 5px 5px;
  border: 2px solid var(--hvm-line, #e6eaf2);
  border-radius: 999px;
  background: #fff;
  color: var(--hvm-ink, #14253a);
  font:
    600 14px/1.25 "DM Sans",
    Lato,
    sans-serif;
  text-align: left;
  text-transform: none;
  letter-spacing: 0;
  box-shadow: none;
  cursor: pointer;
  transition:
    background 0.15s,
    border-color 0.15s;
}
button.hv-swatch:hover {
  background: var(--hvm-soft, #f3f6fb);
}
button.hv-swatch:focus-visible {
  outline: 3px solid rgba(20, 48, 77, 0.35);
  outline-offset: 1px;
}
.hv-swatch.is-static {
  cursor: default;
}

.hv-swatch-dot {
  position: relative;
  flex: 0 0 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--hv-sw, #e9edf3);
  box-shadow:
    inset 0 0 0 1px rgba(0, 0, 0, 0.18),
    0 1px 3px rgba(0, 0, 0, 0.18);
  color: var(--hvm-muted, #5d6b85);
  font:
    800 14px/1 Manrope,
    sans-serif;
  transition:
    box-shadow 0.15s,
    transform 0.15s;
}
.hv-swatch-dot.is-unknown {
  background: repeating-linear-gradient(45deg, #eef1f6 0 5px, #dfe5ee 5px 10px);
}
.hv-swatch-name {
  flex: 0 1 auto;
  min-width: 0;
  white-space: nowrap;
}

/* Seleccionado */
.hv-swatch[aria-checked="true"] {
  border-color: var(--hv-primary, #092143);
  background: var(--hvm-soft, #f3f6fb);
  font-weight: 800;
}
.hv-swatch[aria-checked="true"] .hv-swatch-dot {
  box-shadow:
    inset 0 0 0 1px rgba(0, 0, 0, 0.18),
    0 0 0 2px #fff,
    0 0 0 4px var(--hv-primary, #092143);
}

/* No disponible con la selección actual */
.hv-swatch.is-unavailable {
  opacity: 0.45;
  cursor: not-allowed;
}
.hv-swatch.is-unavailable:hover {
  background: transparent;
}
.hv-swatch.is-unavailable .hv-swatch-name {
  text-decoration: line-through;
}
.hv-swatch.is-unavailable .hv-swatch-dot::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 120%;
  height: 2px;
  background: #b42318;
  transform: translate(-50%, -50%) rotate(-45deg);
}

/* Quitar selección */
.hv-colors-clear {
  display: block;
  margin: 10px 6px 0;
  padding: 0;
  border: 0;
  background: none;
  color: var(--hvm-muted, #5d6b85);
  font:
    600 12px/1.4 "DM Sans",
    Lato,
    sans-serif;
  text-decoration: underline;
  text-transform: none;
  letter-spacing: 0;
  box-shadow: none;
  cursor: pointer;
}
.hv-colors-clear[hidden] {
  display: none;
}
.hv-colors-clear:hover {
  color: var(--hv-primary, #092143);
}

/* ---------- El desplegable original de Color se oculta (sigue funcionando por debajo) ---------- */
.hv-color-select-hidden {
  display: none !important;
}
.hv-color-row-hidden {
  display: none !important;
}
.single-product .summary table.variations.hv-variations-empty {
  display: none;
}

/* ---------- Formulario de variaciones: una columna ordenada (antes se mezclaba con el botón) ---------- */
.single-product .summary form.variations_form table.variations {
  flex: 0 0 100%;
  width: 100%;
  margin: 0;
  border: 0;
}
.single-product .summary form.variations_form table.variations th,
.single-product .summary form.variations_form table.variations td {
  padding: 4px 0;
  border: 0;
  background: transparent;
}
.single-product .summary form.variations_form .single_variation_wrap {
  flex: 1 1 100%;
}
.single-product
  .summary
  form.variations_form
  .woocommerce-variation-add-to-cart {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.single-product
  .summary
  form.variations_form
  .woocommerce-variation-price
  .price {
  font-size: 22px;
}

/* ---------- Celular: pastillas un poco más compactas ---------- */
@media (max-width: 600px) {
  .hv-colors-list {
    gap: 8px;
  }
  .hv-swatch {
    padding: 4px 12px 4px 4px;
    font-size: 13px;
  }
  .hv-swatch-dot {
    flex-basis: 28px;
    width: 28px;
    height: 28px;
  }
}

/* ==========================================================================
   COLORES EN TARJETAS DE PRODUCTO
   ========================================================================== */
.hv-card-colors {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: 8px;
  min-height: 44px;
}
.hv-card-colors-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.hv-card-colors-list li {
  margin: 0;
  padding: 0;
  list-style: none;
}
.hv-card-swatch,
.hv-card-more {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border: 2px solid transparent;
  border-radius: 50%;
  background: #fff;
  color: var(--hv-primary, #092143);
  text-decoration: none;
  transition:
    border-color 0.18s,
    transform 0.18s;
}
.hv-card-swatch:hover,
.hv-card-swatch:focus-visible,
.hv-card-swatch.is-active {
  border-color: var(--hv-primary, #092143);
  transform: scale(1.08);
  outline: none;
}
.hv-card-dot {
  display: grid;
  place-items: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--hv-sw, #e9edf3);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.18);
  font:
    800 9px/1 Manrope,
    sans-serif;
  color: #5d6b85;
}
.hv-card-more {
  width: auto;
  min-width: 26px;
  padding: 0 4px;
  font:
    800 12px/1 Manrope,
    sans-serif;
}
.hv-card-more:hover {
  text-decoration: underline;
}
.hv-card-color-name {
  color: var(--hvm-muted, #5d6b85);
  font-size: 12px;
  line-height: 1.3;
}
@media (max-width: 767px) {
  .hv-card-swatch,
  .hv-card-more {
    width: 30px;
    height: 30px;
  }
  .hv-card-dot {
    width: 20px;
    height: 20px;
  }
}

a.hv-swatch {
  text-decoration: none;
  color: inherit;
}
.hv-swatch.is-current .hv-swatch-dot {
  box-shadow:
    0 0 0 2px #fff,
    0 0 0 4px var(--hv-primary, #092143);
}
.hv-card-swatch.is-current {
  border-color: var(--hv-primary, #092143);
}

a.hv-swatch:hover {
  background: var(--hvm-soft, #f3f6fb);
}
a.hv-swatch.is-current {
  border-color: var(--hv-primary, #092143);
  background: var(--hvm-soft, #f3f6fb);
  font-weight: 800;
}

/* "Color: Satín" visible bajo el título (productos agrupados por color) */
.hv-colors-current.is-group-current {
  margin: -4px 0 12px;
  color: var(--hv-primary, #092143);
  font-size: 14px;
}
.hv-colors-current.is-group-current strong {
  font-weight: 800;
}

/* ==========================================================================
   BOTÓN "AGREGAR AL CARRITO": ocupa todo el espacio que deja la cantidad
   (cantidad a la izquierda con su ancho, botón estirado hasta el borde derecho del recuadro)
   ========================================================================== */
.single-product .summary form.cart:not(.variations_form),
.single-product .summary form.variations_form .woocommerce-variation-add-to-cart {
  display: flex !important;
  flex-wrap: nowrap;
  align-items: stretch;
  gap: 12px;
  width: 100%;
}
.single-product .summary form.cart .quantity {
  flex: 0 0 auto;
  display: flex;
  margin: 0 !important;
}
.single-product .summary form.cart .quantity .qty {
  width: 76px;
  height: auto;
  min-height: 50px;
  box-sizing: border-box;
}
.single-product .summary form.cart .single_add_to_cart_button {
  flex: 1 1 0;
  width: auto;
  min-width: 0;
  white-space: nowrap;
}
@media (max-width: 400px) {
  .single-product .summary form.cart .single_add_to_cart_button {
    padding: 0 14px !important;
    font-size: 13px !important;
  }
}
