/*
 * HURIK PRODUCT V5
 * - Vendedor junto a Probador.
 * - Ficha replegada: imagen completa arriba, datos debajo.
 * - Detalles nativos cerrados por defecto.
 * - Móvil: swipe sin flechas; barra flotante solo en vista normal.
 */

/* =========================================================
   VENDEDOR
   ========================================================= */
body#product .hurik-btn-seller {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  grid-column: auto !important;
  justify-self: stretch !important;
  width: 100% !important;
  min-width: 0;
  min-height: 44px;
  padding: 9px 15px;
  border: 1px solid #d8d0c5;
  border-radius: 999px;
  background: #f3efe8;
  color: var(--hurik-product-ink, #171512);
  box-shadow: none;
  font-family: inherit;
  font-size: .8rem;
  font-weight: 780;
  line-height: 1.15;
  text-align: center;
  cursor: pointer;
  transition: background .18s ease, border-color .18s ease, transform .14s ease;
}

body#product .hurik-btn-seller svg {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
}

/* Primera fila: Probador | Vendedor. Segunda: Comprar | Carrito. */
body#product .hurik-btn-tryon,
body#product .hurik-btn-seller {
  grid-column: auto !important;
  justify-self: stretch !important;
  width: 100% !important;
}

@media (hover:hover) and (pointer:fine) {
  body#product .hurik-btn-seller:hover {
    background: #ece5db;
    border-color: #bfb5a7;
  }
}

body#product .hurik-btn-seller:active {
  transform: scale(.985);
}

/* =========================================================
   DESCRIPCIÓN / DETALLES: ACORDEONES NATIVOS
   ========================================================= */
body#product details.hurik-product-detail-accordion {
  width: 100%;
  padding: 0 !important;
  border-bottom: 1px solid var(--hurik-product-line, #ded8cf);
}

body#product details.hurik-product-detail-accordion > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  width: 100%;
  min-height: 68px;
  padding: 18px 0;
  color: var(--hurik-product-ink, #171512);
  font-size: clamp(1.02rem, 1.35vw, 1.22rem);
  line-height: 1.2;
  font-weight: 820;
  cursor: pointer;
  list-style: none;
  user-select: none;
}

body#product details.hurik-product-detail-accordion > summary::-webkit-details-marker {
  display: none;
}

body#product details.hurik-product-detail-accordion > summary::after {
  content: "+";
  display: inline-grid;
  place-items: center;
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  border: 1px solid var(--hurik-product-line, #ded8cf);
  border-radius: 50%;
  background: #fff;
  color: var(--hurik-product-ink, #171512);
  font-size: 1.15rem;
  font-weight: 520;
  line-height: 1;
}

body#product details.hurik-product-detail-accordion[open] > summary::after {
  content: "−";
}

body#product details.hurik-product-detail-accordion > summary:focus-visible {
  outline: 2px solid var(--hurik-product-ink, #171512);
  outline-offset: 4px;
  border-radius: 4px;
}

body#product details.hurik-product-detail-accordion .hurik-product-detail-content,
body#product details.hurik-product-detail-accordion .hurik-product-spec-table {
  max-width: 980px;
  margin-bottom: clamp(20px, 3vw, 34px);
}

/* =========================================================
   CUANDO HAY PANEL A LA DERECHA:
   imagen arriba, datos/precio debajo. Nunca encoger la foto.
   ========================================================= */
@media (min-width: 992px) {
  body#product.hurik-product-kiruh-open .hurik-product-main,
  body#product.hurik-right-dock-active .hurik-product-main,
  body#product.hurik-external-flow-open .hurik-product-main,
  body#product.hurik-product-tryon-open .hurik-product-main {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 18px !important;
    align-items: start !important;
    width: 100% !important;
    min-width: 0 !important;
  }

  body#product.hurik-product-kiruh-open .hurik-product-column-a,
  body#product.hurik-right-dock-active .hurik-product-column-a,
  body#product.hurik-external-flow-open .hurik-product-column-a,
  body#product.hurik-product-tryon-open .hurik-product-column-a {
    order: 1 !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
  }

  body#product.hurik-product-kiruh-open .hurik-product-info,
  body#product.hurik-right-dock-active .hurik-product-info,
  body#product.hurik-external-flow-open .hurik-product-info,
  body#product.hurik-product-tryon-open .hurik-product-info {
    order: 2 !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    padding-top: 0 !important;
  }

  body#product.hurik-product-kiruh-open .hurik-main-image-wrap,
  body#product.hurik-right-dock-active .hurik-main-image-wrap,
  body#product.hurik-external-flow-open .hurik-main-image-wrap,
  body#product.hurik-product-tryon-open .hurik-main-image-wrap {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    aspect-ratio: 4 / 3 !important;
    background: #ebe7e0 !important;
  }

  body#product.hurik-product-kiruh-open .hurik-gallery-image,
  body#product.hurik-right-dock-active .hurik-gallery-image,
  body#product.hurik-external-flow-open .hurik-gallery-image,
  body#product.hurik-product-tryon-open .hurik-gallery-image {
    object-fit: contain !important;
    object-position: center !important;
  }
}

/* =========================================================
   TABLET / MÓVIL
   ========================================================= */
@media (max-width: 991px) {
  body#product .hurik-product-main {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 16px !important;
  }

  body#product .hurik-product-column-a {
    order: 1 !important;
    width: 100% !important;
    min-width: 0 !important;
  }

  body#product .hurik-product-info {
    order: 2 !important;
    width: 100% !important;
    min-width: 0 !important;
  }

  body#product .hurik-gallery-image {
    object-fit: contain !important;
    object-position: center !important;
  }
}

@media (max-width: 768px) {
  /* En celular la imagen se navega por swipe, no mediante flechas. */
  body#product .hurik-gallery-nav,
  body#product .hurik-edge-product-nav {
    display: none !important;
  }

  body#product {
    --hurik-mobile-action-height: 132px;
  }

  body#product .hurik-action-buttons {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  body#product .hurik-btn-tryon,
  body#product .hurik-btn-seller,
  body#product .hurik-btn-buy,
  body#product .hurik-btn-cart {
    grid-column: auto !important;
    justify-self: stretch !important;
    width: 100% !important;
    min-width: 0 !important;
    min-height: 52px !important;
    padding: 6px 7px !important;
    border-radius: 12px !important;
    font-size: clamp(.67rem, 2.9vw, .78rem) !important;
    line-height: 1.05 !important;
    white-space: normal !important;
  }

  /*
   * La barra flotante SOLO existe mirando la ficha normal.
   * Se retira ante carrito, vendedor, pago/QR, delivery o probador.
   */
  body#product.hurik-cart-open .hurik-action-buttons,
  body#product.hurik-product-kiruh-open .hurik-action-buttons,
  body#product.hurik-product-tryon-open .hurik-action-buttons,
  body#product.hurik-delivery-choice-open .hurik-action-buttons,
  body#product.hurik-external-flow-open .hurik-action-buttons,

  body#product.hurik-cart-open #kiruh-v5-avatar,
  body#product.hurik-product-kiruh-open #kiruh-v5-avatar,
  body#product.hurik-product-tryon-open #kiruh-v5-avatar,
  body#product.hurik-delivery-choice-open #kiruh-v5-avatar,
  body#product.hurik-external-flow-open #kiruh-v5-avatar,

  body#product.hurik-cart-open .hurik-back-to-top,
  body#product.hurik-product-kiruh-open .hurik-back-to-top,
  body#product.hurik-product-tryon-open .hurik-back-to-top,
  body#product.hurik-delivery-choice-open .hurik-back-to-top,
  body#product.hurik-external-flow-open .hurik-back-to-top,

  body#product.hurik-cart-open .hurik-mobile-scroll-down,
  body#product.hurik-product-kiruh-open .hurik-mobile-scroll-down,
  body#product.hurik-product-tryon-open .hurik-mobile-scroll-down,
  body#product.hurik-delivery-choice-open .hurik-mobile-scroll-down,
  body#product.hurik-external-flow-open .hurik-mobile-scroll-down {
    display: none !important;
  }
}
