/* ==========================================================================
   Hardness — capa de rediseño (design system)
   Se carga globalmente en toda la tienda desde cabecera().
   No afecta al panel de administración (td-admin no la enlaza).
   ========================================================================== */

/* --------------------------------------------------------------------------
   0. Tokens de diseño
   -------------------------------------------------------------------------- */
:root {
  --hard-primary: #ffc107;      /* amarillo de marca (CTA) */
  --hard-primary-600: #e0a800;  /* hover del amarillo */
  --hard-dark: #1a1a1a;
  --hard-ink: #1d1d1f;          /* texto principal */
  --hard-muted: #6b7280;
  --hard-line: #e7e7ea;         /* bordes suaves */
  --hard-radius: 14px;
  --hard-radius-sm: 10px;
  --hard-shadow: 0 6px 24px rgba(0, 0, 0, 0.08);
  --hard-shadow-hover: 0 14px 34px rgba(0, 0, 0, 0.14);
  --hard-transition: 0.22s cubic-bezier(0.2, 0.7, 0.3, 1);
}

/* --------------------------------------------------------------------------
   1. Base tipográfica y de render
   -------------------------------------------------------------------------- */
body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  color: var(--hard-ink);
}

h1, h2, h3 { letter-spacing: -0.015em; }
h1 { line-height: 1.1; }
h2 { line-height: 1.15; }

/* Aprovechar mejor el ancho en pantallas grandes (más específico que el
   .container en línea de algunas páginas, para poder ensancharlo). */
@media (min-width: 1200px) {
  html body .container { max-width: 1320px; }
}
@media (min-width: 1500px) {
  html body .container { max-width: 1400px; }
}

/* Front-end a ancho completo (container-fluid) con un pequeño margen lateral
   en pantallas grandes para que el contenido no quede pegado al borde. */
@media (min-width: 992px) {
  .container-fluid { padding-left: 2.5rem; padding-right: 2.5rem; }
}

/* --------------------------------------------------------------------------
   2. Botones
   -------------------------------------------------------------------------- */
.btn {
  border-radius: var(--hard-radius-sm);
  font-weight: 600;
  letter-spacing: 0.005em;
  transition: transform var(--hard-transition),
              box-shadow var(--hard-transition),
              background-color var(--hard-transition),
              color var(--hard-transition);
  will-change: transform;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

.btn-warning {
  background-color: var(--hard-primary);
  border-color: var(--hard-primary);
  box-shadow: 0 4px 14px rgba(255, 193, 7, 0.28);
}
.btn-warning:hover {
  background-color: var(--hard-primary-600);
  border-color: var(--hard-primary-600);
  box-shadow: 0 8px 22px rgba(255, 193, 7, 0.38);
}
.btn-dark:hover { background-color: #000; border-color: #000; box-shadow: var(--hard-shadow); }

/* Accesibilidad: foco visible claro y consistente */
a:focus-visible,
.btn:focus-visible,
button:focus-visible {
  outline: 3px solid rgba(255, 193, 7, 0.55);
  outline-offset: 2px;
}

/* --------------------------------------------------------------------------
   3. Tarjetas de producto (home y listados de categoría)
   Patrón común: .col-md-3 > .bg-white.rounded.border
   -------------------------------------------------------------------------- */
.col-md-3 > .bg-white.rounded.border,
.hc-item > .bg-white.rounded.border {
  border-color: var(--hard-line) !important;
  border-radius: var(--hard-radius) !important;
  overflow: hidden;
  transition: transform var(--hard-transition),
              box-shadow var(--hard-transition),
              border-color var(--hard-transition);
  height: 100%;
}
.col-md-3 > .bg-white.rounded.border:hover,
.hc-item > .bg-white.rounded.border:hover {
  transform: translateY(-4px);
  box-shadow: var(--hard-shadow-hover);
  border-color: #d8d8dc !important;
}
/* Zoom sutil de la imagen al pasar el ratón */
.col-md-3 > .bg-white.rounded.border a img.img-fluid,
.hc-item > .bg-white.rounded.border a img.img-fluid {
  transition: transform var(--hard-transition);
}
.col-md-3 > .bg-white.rounded.border:hover a img.img-fluid,
.hc-item > .bg-white.rounded.border:hover a img.img-fluid {
  transform: scale(1.04);
}

/* --------------------------------------------------------------------------
   3b. Ficha de producto: badge de ahorro y señales de confianza
   -------------------------------------------------------------------------- */
.badge-ahorro {
  display: inline-block;
  font-size: 0.82rem;
  font-weight: 700;
  color: #b42318;
  background: #fde8e6;
  border: 1px solid #f7c9c4;
  padding: 0.18rem 0.55rem;
  border-radius: 999px;
  letter-spacing: 0.01em;
}

.product-main-img {
  width: 100%;
  background: #fff;
  border: 1px solid var(--hard-line);
  border-radius: var(--hard-radius);
  padding: 1.25rem;
  box-shadow: var(--hard-shadow);
}

/* Ficha de producto: galería en rejilla (principal + galería, mismo tamaño) */
.pdp-galeria { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.pdp-galeria.is-single { grid-template-columns: 1fr; } /* una sola foto: 100% */
.pdp-cell { position: relative; background: #fff; border: 1px solid var(--hard-line); border-radius: 16px; overflow: hidden; }
.pdp-cell img { display: block; width: 100%; height: auto; aspect-ratio: 1 / 1; object-fit: cover; }
.pdp-badge { position: absolute; top: 1.25rem; right: 1.25rem; z-index: 5; display: flex; gap: 0.3rem; }
.pdp-movil { display: none; }
@media (max-width: 991.98px) {
  .pdp-galeria { display: none; }
  .pdp-movil { display: block; }
}

.product-trust {
  list-style: none;
  padding: 0 0.5rem;
  margin: 0 0 0.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}
.product-trust li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1rem;
  color: inherit;
  font-weight: 400;
}
.product-trust i { color: #18B284; width: 1.1em; text-align: center; }

/* --------------------------------------------------------------------------
   3c. Cabecera: hamburguesa, iconos y menú offcanvas (PC y móvil)
   -------------------------------------------------------------------------- */
.hard-burger {
  background: transparent;
  border: 0;
  color: #fff;
  font-size: 1.4rem;
  line-height: 1;
  padding: 0.35rem 0.5rem;
  cursor: pointer;
  border-radius: 8px;
  transition: background var(--hard-transition);
}
.hard-burger:hover { background: rgba(255, 255, 255, 0.14); }

.hard-icons { gap: 0.35rem; align-items: center; margin: 0; }
.hard-icons .nav-link {
  color: #fff !important;
  font-size: 1.15rem;
  padding: 0.35rem 0.6rem;
  position: relative;
}
.hard-cart-badge {
  font-size: 0.72rem;
  font-weight: 700;
  background: var(--hard-primary);
  color: #1a1a1a;
  border-radius: 999px;
  padding: 0.05rem 0.4rem;
  vertical-align: top;
  margin-left: -0.2rem;
}

/* Panel offcanvas */
.hard-offcanvas {
  width: 340px !important;
  max-width: 85vw;
}
.hard-offcanvas .offcanvas-header {
  border-bottom: 1px solid var(--hard-line);
  padding: 1rem 1.25rem;
}
.hard-offcanvas .offcanvas-body { padding: 0.5rem 0; }

.hard-menu { width: 100%; }
.hard-menu .nav-link {
  color: var(--hard-ink) !important;
  font-size: 1.05rem;
  font-weight: 600;
  padding: 0.85rem 1.25rem;
  border-bottom: 1px solid #f1f1f3;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: background var(--hard-transition), color var(--hard-transition), padding-left var(--hard-transition);
}
.hard-menu .nav-link:hover {
  background: #faf7ea;
  color: #000 !important;
  padding-left: 1.55rem;
}

/* Caret de los submenús + rotación al abrir */
.hard-sub-caret { font-size: 0.75rem; transition: transform var(--hard-transition); color: var(--hard-muted); }
.hard-sub-toggle[aria-expanded="true"] .hard-sub-caret { transform: rotate(180deg); }
.hard-sub-toggle[aria-expanded="true"] { background: #faf7ea; }

/* Submenú desplegable */
.hard-submenu { list-style: none; margin: 0; padding: 0; background: #fafafa; }
.hard-submenu li a {
  display: block;
  padding: 0.7rem 1.25rem 0.7rem 2rem;
  color: #444;
  text-decoration: none;
  font-size: 0.98rem;
  border-bottom: 1px solid #f1f1f3;
  transition: color var(--hard-transition), padding-left var(--hard-transition);
}
.hard-submenu li a:hover { color: var(--hard-primary-600); padding-left: 2.3rem; }

.hard-menu-sep {
  height: 1px;
  background: var(--hard-line);
  margin: 0.75rem 1.25rem;
}

/* --------------------------------------------------------------------------
   3d. Footer
   -------------------------------------------------------------------------- */
.hard-footer .hard-foot-title {
  font-size: 0.9rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--hard-ink);
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  position: relative;
}
.hard-footer .hard-foot-title::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 32px;
  height: 3px;
  border-radius: 999px;
  background: var(--hard-primary);
}
.hard-foot-list { padding-left: 0; margin: 0; }
.hard-foot-list li { margin-bottom: 0.55rem; }
.hard-foot-list a {
  color: #555;
  text-decoration: none;
  font-size: 0.96rem;
  transition: color var(--hard-transition), padding-left var(--hard-transition);
}
.hard-foot-list a:hover { color: var(--hard-primary-600); padding-left: 4px; }

.hard-foot-bottom { border-top: 1px solid var(--hard-line); }
.hard-foot-bottom,
.hard-foot-bottom a { color: var(--hard-muted) !important; font-size: 0.9rem; }
.hard-foot-bottom a:hover { color: var(--hard-ink) !important; }

/* --------------------------------------------------------------------------
   3e. Tarjeta de producto unificada (home, categorías, relacionados, AJAX)
   -------------------------------------------------------------------------- */
.hard-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  text-align: left;
}
.hard-card-imglink { display: block; position: relative; }
.hard-card-imglink img { width: 100%; display: block; }

.hard-card-badges {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 5;
  display: flex;
  gap: 0.25rem;
}
.hard-card-nuevo {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 5;
  background: #e4002b;
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.hard-card-body {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  padding: 0.75rem 0.85rem 0.9rem;
  margin-top: auto;
}
.hard-card-info { min-width: 0; flex: 1 1 auto; }
.hard-card-title-link { text-decoration: none; display: block; }
.hard-card-title {
  font-size: 0.85rem;
  font-weight: 500;
  color: #6b7280;
  margin: 0 0 0.3rem;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  line-height: 1.25;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color var(--hard-transition);
}
.hard-card-title-link:hover .hard-card-title { color: #1d1d1f; }
.hard-card-price {
  margin: 0 !important;
  font-weight: 700;
  font-size: 1.05rem;
  color: #111;
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.4rem;
  line-height: 1.2;
}
.hard-card-price s { color: #9aa0a6; font-weight: 400; }
.hard-card-price .price-discount { color: #e4002b; font-weight: 800; }

.hard-card-action { flex: 0 0 auto; }
.hard-add {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  border-radius: 12px;
  border: 1.5px solid #d8d8dc;
  background: #fff;
  color: #111;
  font-size: 1.2rem;
  cursor: pointer;
  text-decoration: none;
  transition: background var(--hard-transition), border-color var(--hard-transition),
              color var(--hard-transition), transform var(--hard-transition);
}
.hard-add:hover { border-color: #111; background: #111; color: #fff; transform: translateY(-1px); }
.hard-add.is-disabled { opacity: 0.4; cursor: not-allowed; }
.hard-add.is-disabled:hover { background: #fff; color: #111; border-color: #d8d8dc; transform: none; }
.hard-add.added { background: var(--hard-primary); border-color: var(--hard-primary); color: #1a1a1a; }

/* Estados de icono del botón (independientes del CSS en línea de cada página) */
.hard-add .fa-spinner,
.hard-add .fa-check { display: none; }
.hard-add.loading .fa-cart-plus,
.hard-add.loading .fa-check { display: none; }
.hard-add.loading .fa-spinner { display: inline-block; }
.hard-add.added .fa-cart-plus { display: none; }
.hard-add.added .fa-check { display: inline-block; }

@media (max-width: 767.98px) {
  .hard-card-body { padding: 0.6rem 0.6rem 0.75rem; gap: 0.4rem; }
  .hard-add { width: 44px; height: 44px; font-size: 1.05rem; border-radius: 10px; }
  .hard-card-title { font-size: 0.8rem; }
  .hard-card-price { font-size: 0.98rem; }
}

/* --------------------------------------------------------------------------
   3f. Opiniones estilo "Google Reviews" (sin logo de Google)
   -------------------------------------------------------------------------- */
.review-card {
  background: #fff;
  border: 1px solid var(--hard-line);
  border-radius: 16px;
  padding: 1.25rem 1.35rem;
  height: 100%;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.05);
  display: flex;
  flex-direction: column;
  transition: box-shadow var(--hard-transition), transform var(--hard-transition);
}
.review-card:hover { box-shadow: 0 10px 26px rgba(0, 0, 0, 0.10); transform: translateY(-2px); }

.review-head { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 0.8rem; }
.review-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  color: #fff;
  font-weight: 700;
  font-size: 1.15rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  text-transform: uppercase;
}
.review-meta { min-width: 0; }
.review-name {
  font-weight: 600;
  color: #202124;
  font-size: 0.98rem;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  line-height: 1.2;
}
.review-verified { color: #1a73e8; font-size: 0.82rem; }
.review-date { color: #70757a; font-size: 0.82rem; margin-top: 2px; }

.review-stars { color: #fbbc04; font-size: 0.95rem; letter-spacing: 1px; margin-bottom: 0.65rem; }
.review-stars .fa-regular { color: #dadce0; }

.review-text { color: #3c4043; font-size: 0.95rem; line-height: 1.55; margin: 0; }

/* --------------------------------------------------------------------------
   3h. Carrito y checkout estilo Shopify
   -------------------------------------------------------------------------- */
.checkout-page .container,
.checkout-page { max-width: 1080px; }
.checkout-page h2.h4,
.checkout-forms h2 { font-weight: 800; letter-spacing: -0.02em; font-size: 1.35rem; }
#pageCarrito h1, .checkout-page h1 { font-weight: 800; letter-spacing: -0.02em; }

/* Paneles de resumen (carrito y checkout): gris claro, sin borde, tipo Shopify */
.checkout-summary-card,
.cart-summary-card {
  background: #f4f5f7 !important;
  border: 0 !important;
  border-radius: 18px !important;
  padding: 1.65rem 1.5rem !important;
}
@media (min-width: 992px) {
  .checkout-summary,
  .cart-summary-sticky { position: sticky; top: 1.5rem; align-self: flex-start; }
}

/* Líneas de producto del resumen */
.checkout-summary-card .d-flex.mb-3 { align-items: center; gap: 0.9rem; }
.checkout-summary-card .d-flex.mb-3 img {
  width: 66px !important; height: 66px; object-fit: cover;
  border-radius: 12px; border: 1px solid #e2e3e7; background: #fff; margin: 0 !important;
}

/* Totales */
.checkout-summary-card .fs-4,
.cart-summary-card .fs-4 { font-weight: 800 !important; font-size: 1.7rem !important; letter-spacing: -0.02em; }
.checkout-summary-card hr,
.cart-summary-card hr { border-color: #dcdee3; opacity: 1; }

/* Botones de acción grandes (Shopify) */
.checkout-forms .btn.p-3,
.cart-summary-card .btn.p-3,
.cart-summary-card .btn.w-100 {
  border-radius: 14px !important;
  font-weight: 700 !important;
  padding: 0.95rem 1rem !important;
  font-size: 1.05rem !important;
}

/* Acordeón de métodos de pago (tarjetas limpias) */
.checkout-forms .accordion { --bs-accordion-border-color: transparent; }
.checkout-forms .accordion-item {
  border: 1.5px solid var(--hard-line) !important;
  border-radius: 14px !important;
  margin-bottom: 0.65rem;
  overflow: hidden;
  background: #fff;
}
.checkout-forms .accordion-button { font-weight: 600; border-radius: 14px !important; }
.checkout-forms .accordion-button:not(.collapsed) {
  background: #fffdf5;
  color: var(--hard-ink);
  box-shadow: none;
}
.checkout-forms .accordion-button:focus { box-shadow: 0 0 0 3px rgba(255,193,7,0.25); }

/* Formularios del checkout: inputs más altos y limpios */
.checkout-forms .form-control,
.checkout-forms .form-select {
  border-radius: 12px;
  padding: 0.85rem 0.9rem;
  border-color: #d8dade;
}
.checkout-forms .form-control:focus,
.checkout-forms .form-select:focus {
  border-color: var(--hard-primary);
  box-shadow: 0 0 0 3px rgba(255,193,7,0.22);
}

/* Carrito: fila de producto tipo Shopify */
.carrito-linea {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  background: #fff !important;
  border: 1px solid var(--hard-line) !important;
  border-radius: 16px !important;
}
.carrito-linea img {
  width: 90px !important; height: 90px; object-fit: cover;
  border-radius: 12px; border: 1px solid var(--hard-line); background: #fff; margin: 0 !important;
}

/* ---- Carrito estilo Hawkers ---- */
.hk-item {
  display: flex; gap: 1rem;
  background: #fff; border: 1px solid var(--hard-line); border-radius: 16px;
  padding: 1rem; margin-bottom: 1rem;
}
.hk-item-img { position: relative; flex: 0 0 auto; display: block; }
.hk-item-img img { width: 120px; height: 120px; object-fit: cover; border-radius: 12px; background: #f4f4f6; }
.hk-item-badge { position: absolute; top: 8px; left: 8px; background: #e4002b; color: #fff; font-weight: 700; font-size: 0.72rem; padding: 2px 7px; border-radius: 6px; }
.hk-item-body { flex: 1 1 auto; display: flex; flex-direction: column; min-width: 0; }
.hk-item-head { display: flex; justify-content: space-between; gap: 0.5rem; }
.hk-item-title { font-weight: 700; text-transform: uppercase; color: #1d1d1f; text-decoration: none; font-size: 0.98rem; letter-spacing: 0.01em; line-height: 1.25; }
.hk-item-title:hover { color: #000; }
.hk-item-remove { background: transparent; border: 0; color: #9aa0a6; cursor: pointer; font-size: 1rem; height: fit-content; }
.hk-item-remove:hover { color: #e4002b; }
.hk-item-extras { color: #6b7280; font-size: 0.88rem; margin: 0.25rem 0 0; }
.hk-item-foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-top: 0.85rem; }
.hk-qty { display: inline-flex; align-items: center; border: 1px solid var(--hard-line); border-radius: 10px; overflow: hidden; }
.hk-qty button { width: 38px; height: 38px; border: 0; background: #fff; font-size: 1.1rem; cursor: pointer; color: #1d1d1f; }
.hk-qty button:hover { background: #f4f4f6; }
.hk-qty .item-quantity { min-width: 34px; text-align: center; font-weight: 700; }
.hk-item-price { font-weight: 800; font-size: 1.05rem; text-align: right; white-space: nowrap; }
.hk-item-price s { color: #9aa0a6; font-weight: 400; font-size: 0.9rem; margin-right: 0.35rem; }
.hk-item-price .price-discount { color: #e4002b; }
.hk-continue-shopping { text-decoration: none; color: #1d1d1f; font-weight: 600; }
.hk-continue-shopping:hover { color: var(--hard-primary-600); }

.hk-total-box { background: #fff; border: 1px solid var(--hard-line); border-radius: 16px; padding: 1.35rem; }
.hk-total-row { display: flex; justify-content: space-between; align-items: baseline; }
.hk-total-label { font-weight: 800; font-size: 1.15rem; letter-spacing: 0.02em; }
.hk-total-value { font-weight: 800; font-size: 1.5rem; }
.hk-total-value s { color: #9aa0a6; font-weight: 400; font-size: 1rem; margin-right: 0.4rem; }
.hk-red { color: #e4002b !important; }
.hk-total-sub { display: flex; justify-content: space-between; color: #6b7280; font-size: 0.92rem; margin-top: 0.4rem; gap: 1rem; }
.hk-total-sub a { color: #9aa0a6; }
.hk-freeship { display: flex; align-items: center; gap: 0.5rem; color: #16a34a; font-weight: 700; font-size: 0.9rem; border-top: 1px solid var(--hard-line); margin-top: 0.9rem; padding-top: 0.9rem; }
.hk-legal { font-size: 0.78rem; color: #8b90a0; margin: 0.9rem 0; }
.hk-legal a { color: #6b7280; }
.hk-continue-btn { display: flex; align-items: center; justify-content: center; width: 100%; background: #2e9e5b; color: #fff; font-weight: 800; letter-spacing: 0.03em; padding: 1rem; border-radius: 12px; text-decoration: none; font-size: 1.05rem; transition: background 0.2s; }
.hk-continue-btn:hover { background: #268150; color: #fff; }
.hk-pay-badges { display: block; max-width: 100%; margin: 1rem auto 0; }

.hk-info-box { background: #f4f5f7; border-radius: 16px; padding: 1.1rem 1.25rem; margin-top: 1rem; }
.hk-info-box p { display: flex; align-items: center; gap: 0.6rem; margin-bottom: 0.6rem; color: #3c4043; font-size: 0.92rem; }
.hk-info-box i { color: var(--hard-primary-600); width: 1.1em; text-align: center; }

.hk-promo-box { margin-top: 1rem; }
.hk-promo-box form { display: flex; gap: 0.5rem; }
.hk-promo-box input { flex: 1 1 auto; min-width: 0; border: 1px solid var(--hard-line); border-radius: 10px; padding: 0.7rem 0.85rem; }
.hk-promo-box button { border: 0; background: var(--hard-primary); color: #1a1a1a; font-weight: 700; padding: 0.7rem 1rem; border-radius: 10px; cursor: pointer; white-space: nowrap; }
.hk-promo-box button:hover { background: var(--hard-primary-600); }

@media (max-width: 991.98px) {
  .hk-item-img img { width: 92px; height: 92px; }
}

/* ---- Checkout one-page (Shopify) ---- */
.checkout-box { background: #fff; border: 1px solid var(--hard-line); border-radius: 14px; padding: 1.1rem; }
.checkout-forms .form-floating > label { color: #8a8f9a; }

.chk-line { display: flex; align-items: center; gap: 0.85rem; margin-bottom: 0.95rem; }
.chk-line-thumb { position: relative; flex: 0 0 auto; }
.chk-line-thumb img { width: 60px; height: 60px; object-fit: cover; border-radius: 10px; border: 1px solid var(--hard-line); background: #fff; }
.chk-line-qty { position: absolute; top: -8px; right: -8px; background: #6b7280; color: #fff; font-size: 0.72rem; font-weight: 700; min-width: 20px; height: 20px; border-radius: 50%; display: flex; align-items: center; justify-content: center; padding: 0 4px; }
.chk-line-info { flex: 1 1 auto; min-width: 0; }
.chk-line-name { font-weight: 600; font-size: 0.92rem; display: block; line-height: 1.25; }
.chk-line-extras { color: #6b7280; font-size: 0.82rem; }
.chk-line-price { font-weight: 700; white-space: nowrap; }

.chk-totals { border-top: 1px solid var(--hard-line); margin-top: 0.4rem; padding-top: 1rem; }
.chk-total-line { display: flex; justify-content: space-between; margin-bottom: 0.55rem; color: #3c4043; gap: 1rem; }
.chk-total-grand { font-size: 1.45rem; font-weight: 800; margin-top: 0.6rem; padding-top: 0.75rem; border-top: 1px solid var(--hard-line); color: #111; letter-spacing: -0.02em; }
.chk-total-grand small { font-size: 0.72rem; font-weight: 600; }
.chk-taxes { color: #70757a; font-size: 0.82rem; margin: 0; }

.chk-summary-toggle { display: none; width: 100%; align-items: center; justify-content: space-between; background: #f4f5f7; border: 1px solid var(--hard-line); border-radius: 12px; padding: 0.9rem 1.1rem; font-weight: 600; cursor: pointer; margin-bottom: 1rem; }
.chk-summary-toggle-total { font-weight: 800; }
.chk-caret { transition: transform 0.2s; font-size: 0.8rem; }
.checkout-summary.is-open .chk-caret { transform: rotate(180deg); }

@media (max-width: 991.98px) {
  .chk-summary-toggle { display: flex; }
  .chk-summary-body { display: none; }
  .checkout-summary.is-open .chk-summary-body { display: block; }
}

/* --------------------------------------------------------------------------
   3g. Selección de transportista en checkout (estilo Shopify)
   -------------------------------------------------------------------------- */
.envio-opciones { display: flex; flex-direction: column; gap: 0.6rem; }
.envio-opcion {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.9rem 1.05rem;
  border: 1.5px solid var(--hard-line);
  border-radius: 12px;
  background: #fff;
  text-decoration: none;
  color: var(--hard-ink);
  transition: border-color var(--hard-transition), box-shadow var(--hard-transition), background var(--hard-transition);
}
.envio-opcion:hover { border-color: #c7c9cf; }
.envio-opcion.is-active {
  border-color: var(--hard-primary);
  box-shadow: 0 0 0 3px rgba(255, 193, 7, 0.22);
  background: #fffdf5;
}
.envio-radio {
  flex: 0 0 auto;
  width: 20px; height: 20px;
  border-radius: 50%;
  border: 2px solid #c7c9cf;
  position: relative;
  transition: border-color var(--hard-transition);
}
.envio-opcion.is-active .envio-radio { border-color: var(--hard-primary-600); }
.envio-opcion.is-active .envio-radio::after {
  content: "";
  position: absolute; inset: 3px;
  border-radius: 50%;
  background: var(--hard-primary-600);
}
.envio-info { flex: 1 1 auto; display: flex; flex-direction: column; min-width: 0; }
.envio-nombre { font-weight: 700; }
.envio-desc { font-size: 0.85rem; color: var(--hard-muted); }
.envio-precio { flex: 0 0 auto; font-weight: 700; font-size: 1.02rem; }
.envio-precio.es-gratis { color: #16a34a; text-transform: uppercase; font-size: 0.9rem; letter-spacing: 0.03em; }

/* --------------------------------------------------------------------------
   3i. Página auto-generada: Información de envíos y pagos
   -------------------------------------------------------------------------- */
.ep-envios { display: grid; gap: 1.5rem; margin-top: 1.5rem; }
.ep-zona { border: 1px solid var(--hard-line); border-radius: 16px; overflow: hidden; background: #fff; }
.ep-zona-cab { background: #1a1a1a; color: #fff; font-weight: 700; font-size: 1.05rem; padding: 0.9rem 1.25rem; display: flex; align-items: center; gap: 0.5rem; }
.ep-zona-cab i { color: var(--hard-primary); }
.ep-carrier { padding: 1.1rem 1.25rem; }
.ep-carrier + .ep-carrier { border-top: 1px solid var(--hard-line); }
.ep-carrier-head { display: flex; align-items: baseline; gap: 0.6rem; flex-wrap: wrap; margin-bottom: 0.5rem; }
.ep-carrier-nombre { font-weight: 700; font-size: 1.05rem; }
.ep-plazo { color: var(--hard-muted); font-size: 0.9rem; }
.ep-gratis { color: #16a34a; font-weight: 700; font-size: 0.92rem; margin: 0 0 0.7rem; display: flex; align-items: center; gap: 0.4rem; }
.ep-tabla { width: 100%; border-collapse: collapse; margin: 0; }
.ep-tabla th { text-align: left; font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.04em; color: var(--hard-muted); padding: 0.45rem 0.25rem; border-bottom: 2px solid var(--hard-line); }
.ep-tabla td { padding: 0.65rem 0.25rem; border-bottom: 1px solid #f1f1f3; }
.ep-tabla tr:last-child td { border-bottom: 0; }
.ep-badge-gratis { background: #dcfce7; color: #16a34a; font-weight: 800; font-size: 0.76rem; padding: 2px 9px; border-radius: 999px; letter-spacing: 0.03em; }
.ep-nota { color: var(--hard-muted); font-size: 0.88rem; margin-top: 1.25rem; }
.ep-titulo-pagos { font-weight: 800; margin-top: 2.2rem; margin-bottom: 1.1rem; padding-bottom: 0.5rem; }
.ep-titulo-pagos::after { content: ""; display: block; width: 48px; height: 4px; border-radius: 999px; background: var(--hard-primary); margin-top: 0.5rem; }
.ep-pagos { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 0.75rem; }
.ep-pago { display: flex; align-items: center; gap: 0.7rem; border: 1px solid var(--hard-line); border-radius: 12px; padding: 0.85rem 1rem; font-weight: 600; background: #fff; }
.ep-pago i { color: var(--hard-primary-600); font-size: 1.2rem; width: 1.4em; text-align: center; }
.ep-recargo { color: var(--hard-muted); font-weight: 400; font-size: 0.85rem; }

/* --------------------------------------------------------------------------
   3j. Sección "Información de interés" (franja de confianza)
   -------------------------------------------------------------------------- */
.info-interes h2 { font-weight: 800; letter-spacing: -0.02em; }
.info-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}
@media (max-width: 991.98px) { .info-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 575.98px) { .info-grid { grid-template-columns: 1fr; } }

.info-item {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  background: #fff;
  border: 1px solid var(--hard-line);
  border-radius: 18px;
  padding: 1.35rem 1.25rem;
  transition: box-shadow var(--hard-transition), transform var(--hard-transition), border-color var(--hard-transition);
}
.info-item:hover { transform: translateY(-4px); box-shadow: var(--hard-shadow-hover); border-color: #e2e2e6; }
.info-icon {
  flex: 0 0 auto;
  width: 54px; height: 54px;
  border-radius: 15px;
  background: linear-gradient(155deg, #ffe390 0%, #fff7da 100%);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.45rem; color: #1a1a1a;
}
.info-icon-wa { background: linear-gradient(155deg, #bff0cf 0%, #e6faee 100%); color: #16a34a; }
.info-text { min-width: 0; }
.info-text h3 { font-weight: 700; font-size: 1.05rem; margin: 0 0 0.2rem; color: var(--hard-ink); }
.info-text p { color: var(--hard-muted); font-size: 0.9rem; margin: 0 0 0.6rem; line-height: 1.35; }
.info-link {
  font-weight: 600; font-size: 0.88rem; color: #1d1d1f; text-decoration: none;
  display: inline-flex; align-items: center; gap: 0.4rem;
}
.info-link i { font-size: 0.82em; transition: transform var(--hard-transition); }
.info-link:hover { color: var(--hard-primary-600); }
.info-link:hover i { transform: translateX(3px); }
.info-link-wa { color: #16a34a; }
.info-link-wa:hover { color: #128a3e; }

/* --------------------------------------------------------------------------
   4. Encabezados de sección con acento
   -------------------------------------------------------------------------- */
/* Títulos de sección (no los <h2 class="btn"> que la home usa como botones) */
section > h2.text-center:not(.btn)::after,
section.text-center > h2:not(.btn)::after,
section > .container > h2.text-center:not(.btn)::after {
  content: "";
  display: block;
  width: 56px;
  height: 4px;
  margin: 0.7rem auto 0;
  border-radius: 999px;
  background: var(--hard-primary);
}

/* --------------------------------------------------------------------------
   5. Carrusel horizontal reutilizable (.hc)
   -------------------------------------------------------------------------- */
.hc { position: relative; }

.hc-track {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  scroll-behavior: smooth;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding: 4px 2px 1.25rem;
  scrollbar-width: none;          /* Firefox */
  -ms-overflow-style: none;       /* IE/Edge */
}
.hc-track::-webkit-scrollbar { display: none; } /* Chrome/Safari */
.hc-track.hc-center { justify-content: center; }

.hc-item {
  scroll-snap-align: start;
  flex: 0 0 auto;
  width: var(--hc-w, 280px);
}

@media (max-width: 767.98px) {
  .hc-item { width: var(--hc-w-mobile, 72%); }
  .hc-track { gap: 0.75rem; }
}

/* Flechas de navegación */
.hc-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 5;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: none;
  background: #fff;
  color: #111;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.18);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  transition: opacity 0.2s ease, transform 0.15s ease, background 0.2s ease;
}
.hc-arrow:hover { background: #111; color: #fff; transform: translateY(-50%) scale(1.06); }
.hc-arrow.hc-prev { left: -6px; }
.hc-arrow.hc-next { right: -6px; }

.hc-arrow[hidden],
.hc-arrow.is-hidden {
  opacity: 0;
  pointer-events: none;
}

@media (max-width: 767.98px) {
  .hc-arrow { width: 38px; height: 38px; }
  .hc-arrow.hc-prev { left: 2px; }
  .hc-arrow.hc-next { right: 2px; }
}

/* Opiniones dentro del carrusel: neutraliza el masonry antiguo (width:100%) */
.hc-item.valoracion-item {
  width: var(--hc-w, 320px);
  display: flex;
  margin-bottom: 0;
}
@media (max-width: 767.98px) {
  .hc-item.valoracion-item { width: var(--hc-w-mobile, 82%); }
}
.hc-item.valoracion-item .card {
  width: 100%;
  height: 100%;
  border-color: var(--hard-line);
  border-radius: var(--hard-radius);
}

/* --------------------------------------------------------------------------
   6. Respeto por usuarios con "reduce motion"
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  .btn, .col-md-3 > .bg-white.rounded.border,
  .col-md-3 > .bg-white.rounded.border a img.img-fluid,
  .hc-track { transition: none; scroll-behavior: auto; }
}

/* ============================================================
   3k. Banner principal de categoría (hero) — PC + móvil
   A todo el ancho y pegado a la cabecera fija (30px barra + navbar).
   ============================================================ */
.cat-hero {
  width: 100%;
  padding-top: 83px; /* despeja la cabecera fija (barra 30px + navbar) */
  background: #000;
  line-height: 0;
}
.cat-hero-img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
}
/* Con hero, la sección de contenido no necesita el gran hueco superior
   que despejaba la cabecera (ya lo hace el propio hero). */
.cat-has-hero {
  margin-top: 1.25rem !important;
  padding-top: 0 !important;
}

/* ============================================================
   Página de Valoraciones (estilo reseñas, sin mencionar Google)
   ============================================================ */
.review-producto { display:inline-flex; align-items:center; gap:.5rem; margin-top:.5rem; font-size:.82rem; font-weight:700; color:#1a73e8; text-decoration:none; }
.review-producto:hover span { text-decoration:underline; }

/* Tarjeta de reseña horizontal: foto del producto a la izquierda, info a la derecha */
.review-card-h { display:flex; flex-direction:row; gap:1rem; align-items:stretch; }
.review-card-h .review-media { flex:0 0 40%; max-width:40%; align-self:stretch; display:block; border-radius:12px; overflow:hidden; background:#f4f5f7; border:1px solid var(--hard-line); }
.review-card-h .review-media img { width:100%; height:100%; min-height:130px; object-fit:cover; display:block; }
.review-card-h .review-body { flex:1 1 auto; min-width:0; }
@media (max-width: 400px){
  .review-card-h .review-media { flex-basis:38%; max-width:38%; }
}
.val-resumen { display:flex; flex-wrap:wrap; gap:1.5rem 2.5rem; align-items:center; justify-content:center; background:#fff; border:1px solid var(--hard-line); border-radius:18px; padding:1.5rem 1.75rem; }
.val-resumen-media { text-align:center; min-width:160px; }
.val-media-num { font-size:3.4rem; font-weight:800; line-height:1; color:#111; letter-spacing:-.02em; }
.val-media-stars { font-size:1.15rem; margin:.35rem 0; }
.val-media-total { color:var(--hard-muted); font-size:.9rem; }
.val-resumen-barras { flex:1 1 320px; max-width:460px; display:flex; flex-direction:column; gap:.3rem; }
.val-barra-row { display:flex; align-items:center; gap:.6rem; background:none; border:0; padding:.15rem .25rem; border-radius:8px; cursor:pointer; width:100%; }
.val-barra-row:hover { background:#f4f5f7; }
.val-barra-label { width:38px; font-size:.85rem; color:#5f6368; white-space:nowrap; text-align:right; }
.val-barra-label .fa-star { color:#fbbc04; font-size:.75rem; }
.val-barra-track { flex:1; height:10px; background:#e8eaed; border-radius:999px; overflow:hidden; }
.val-barra-fill { display:block; height:100%; background:#fbbc04; border-radius:999px; }
.val-barra-num { width:52px; text-align:right; font-size:.8rem; color:#70757a; }
.val-filtros { display:flex; flex-wrap:wrap; gap:.5rem; justify-content:center; }
.val-chip { border:1.5px solid var(--hard-line); background:#fff; border-radius:999px; padding:.4rem .95rem; font-weight:700; font-size:.85rem; color:#3c4043; cursor:pointer; transition:all .15s; }
.val-chip .fa-star { color:#fbbc04; font-size:.78rem; }
.val-chip:hover { border-color:#c9ccd1; }
.val-chip.active { background:#111; color:#fff; border-color:#111; }
.val-chip.active .fa-star { color:#ffd24d; }
@media (max-width: 575.98px){
  .val-media-num { font-size:2.8rem; }
  .val-resumen { padding:1.1rem; }
}

/* Prueba social en la home (años, clientes, media) */
.social-proof { display:flex; flex-wrap:wrap; align-items:center; justify-content:center; gap:1rem 2.5rem; background:linear-gradient(135deg,#111 0%,#2a2a2a 100%); color:#fff; border-radius:20px; padding:1.6rem 2rem; }
.social-proof .sp-item { display:flex; flex-direction:column; align-items:center; text-align:center; }
.social-proof .sp-num { font-size:2.1rem; font-weight:800; line-height:1; letter-spacing:-.02em; }
.social-proof .sp-star { color:#fbbc04; font-size:1.4rem; }
.social-proof .sp-label { font-size:.85rem; color:#c8c8cc; margin-top:.3rem; }
.social-proof .sp-sep { width:1px; height:44px; background:rgba(255,255,255,.18); }
@media (max-width:575.98px){ .social-proof .sp-sep{ display:none; } .social-proof{ gap:1.2rem; } .social-proof .sp-num{ font-size:1.7rem; } }

/* Super-destacadas del hero: botón "Ver categoría" superpuesto sobre la foto */
.category-section .cat-super-link { position: relative; display: block; }
.category-section .cat-super-btn {
  position: absolute; left: 50%; bottom: 1.4rem; transform: translateX(-50%);
  margin: 0 !important; z-index: 2; white-space: nowrap;
  box-shadow: 0 8px 22px rgba(0,0,0,0.28);
}
.category-section .cat-super-link picture img { border-radius: var(--hard-radius); }

/* Checkout: precio de línea con descuento (base tachado + rebaja) */
.chk-line-price { text-align: right; white-space: nowrap; }
.chk-line-old { display: block; font-size: 0.8rem; color: #9aa0a6; font-weight: 400; }
.hk-red { color: #d13b3b; }
/* Envío con descuento (tachado) */
.chk-envio-old, .hk-envio-old { color: #9aa0a6; text-decoration: line-through; font-weight: 400; margin-right: .35rem; font-size: .9em; }

/* ============================================================
   Checkout: métodos de pago con radios + barra fija de finalizar
   ============================================================ */
.pago-opciones { display: flex; flex-direction: column; gap: 0.6rem; }
.pago-opcion {
  display: flex; align-items: flex-start; gap: 0.85rem;
  padding: 0.9rem 1.05rem; border: 1.5px solid var(--hard-line);
  border-radius: 12px; background: #fff; cursor: pointer;
  transition: border-color var(--hard-transition), box-shadow var(--hard-transition), background var(--hard-transition);
}
.pago-opcion:hover { border-color: #c7c9cf; }
.pago-opcion.is-active { border-color: var(--hard-primary); box-shadow: 0 0 0 3px rgba(255,193,7,0.22); background: #fffdf5; }
.pago-opcion.is-disabled { opacity: 0.55; cursor: not-allowed; background: #f7f7f8; }
.pago-radio { flex: 0 0 auto; width: 20px; height: 20px; margin-top: 2px; border-radius: 50%; border: 2px solid #c7c9cf; position: relative; }
.pago-opcion.is-active .pago-radio { border-color: var(--hard-primary-600); }
.pago-opcion.is-active .pago-radio::after { content: ""; position: absolute; inset: 3px; border-radius: 50%; background: var(--hard-primary-600); }
.pago-info { flex: 1 1 auto; display: flex; flex-direction: column; min-width: 0; }
.pago-nombre { font-weight: 700; }
.pago-recargo { color: #d13b3b; font-weight: 700; font-size: 0.85rem; }
.pago-desc { font-size: 0.82rem; color: var(--hard-muted); margin-top: 2px; }
.pago-aviso { font-size: 0.82rem; color: #b45309; font-weight: 600; margin-top: 3px; }
.pago-precio { flex: 0 0 auto; font-weight: 800; font-size: 1.02rem; }
.pago-form { background: #f7f7f8; border: 1px solid var(--hard-line); border-radius: 12px; padding: 1rem; margin: -0.2rem 0 0.3rem; }

/* Barra fija inferior con el botón de finalizar */
.chk-fixed-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 1030; background: #fff; border-top: 1px solid var(--hard-line); box-shadow: 0 -6px 20px rgba(0,0,0,0.08); padding: 0.7rem 1rem; }
.chk-fixed-inner { max-width: 1320px; margin: 0 auto; display: flex; align-items: center; gap: 1rem; }
.chk-fixed-total { display: flex; flex-direction: column; line-height: 1.1; }
.chk-fixed-total-label { font-size: 0.75rem; color: var(--hard-muted); }
.chk-fixed-total-value { font-weight: 800; font-size: 1.25rem; }
.chk-fixed-btn { flex: 1 1 auto; padding: 0.9rem 1rem; font-size: 1.1rem; font-weight: 700; border-radius: 10px; }
.chk-fixed-error { max-width: 1320px; margin: 0.4rem auto 0; color: #d13b3b; font-weight: 600; font-size: 0.9rem; text-align: center; }
body.checkout-has-bar { padding-bottom: 90px; }

/* Card "Ver más" al final de un carrusel horizontal (.hc) */
.hc-more-card {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: .9rem; height: 100%; min-height: 180px; text-align: center;
  background: #fff; border: 2px dashed var(--hard-line); border-radius: 16px;
  padding: 1.5rem; text-decoration: none; color: var(--hard-ink);
  transition: border-color var(--hard-transition), box-shadow var(--hard-transition), transform var(--hard-transition);
}
.hc-more-card:hover { border-color: var(--hard-primary); box-shadow: var(--hard-shadow-hover); transform: translateY(-3px); color: var(--hard-ink); }
.hc-more-icon {
  width: 54px; height: 54px; border-radius: 50%; background: var(--hard-primary); color: #1a1a1a;
  display: flex; align-items: center; justify-content: center; font-size: 1.25rem;
  transition: transform var(--hard-transition);
}
.hc-more-card:hover .hc-more-icon { transform: translateX(4px); }
.hc-more-text { font-weight: 800; font-size: 1.02rem; letter-spacing: -.01em; }

/* Badge de descuento (ahorro en euros) de las cards: fondo rojo */
.hard-badge-ahorro { background: #d13b3b !important; border-color: #d13b3b !important; color: #fff !important; }

/* Sección SEO de categoría: contenedor centrado, línea arriba/abajo, sin fondo */
.cat-seo {
  max-width: 900px;
  margin: 1rem auto 0;
  padding: 2.25rem 0;
  border-top: 1px solid var(--hard-line);
  border-bottom: 1px solid var(--hard-line);
  color: #3c4043;
}
.cat-seo h1, .cat-seo h2, .cat-seo h3 { letter-spacing: -0.01em; }
.cat-seo img { max-width: 100%; height: auto; }

/* Card de producto: cambio de imagen al pasar el ratón (primera foto de galería) */
.hard-card-imglink { position: relative; display: block; }
.hard-card-img-hover {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; opacity: 0; transition: opacity .35s ease; z-index: 1;
  pointer-events: none;
}
/* Producto agotado: la imagen principal se muestra atenuada */
.hard-card-imglink.is-agotado .hard-card-img-main { opacity: 0.5; }
/* Sólo al pasar el ratón se muestra la imagen de galería (nunca superpuesta antes) */
.hard-card:hover .hard-card-imglink.has-hover .hard-card-img-hover { opacity: 1; }
/* Agotado: al hover se oculta la principal y sólo se ve la de galería (atenuada),
   evitando que se vean las dos imágenes superpuestas. */
.hard-card:hover .hard-card-imglink.has-hover.is-agotado .hard-card-img-main { opacity: 0; }
.hard-card:hover .hard-card-imglink.has-hover.is-agotado .hard-card-img-hover { opacity: 0.5; }

/* Línea pequeña de valoraciones bajo el H2 "Lo que opinan nuestros clientes" */
.review-substats {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center;
  gap: .5rem; font-size: .92rem; color: var(--hard-muted);
}
.review-substats .review-stars { color: #fbbc04; font-size: .95rem; letter-spacing: 1px; }
.review-substats strong { color: #111; }
.review-substats-sep { color: #c9ccd1; }
