/* =========================
   OVERLAY
   ========================= */
.nxh-sidecart-overlay{
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.45);
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s ease;
  z-index: 9998;
}
.nxh-sidecart-overlay.is-open{
  opacity: 1;
  pointer-events: auto;
}

/* =========================
   DRAWER
   ========================= */
.nxh-sidecart{
  position: fixed;
  top: 0;
  right: 0;
  width: min(420px, 92vw);
  background: #fff;
  transform: translateX(102%);
  transition: transform .25s ease;
  z-index: 9999;
  display: flex;

  /* ✅ base fallback */
  height: 100vh;

  /* ✅ iOS Safari fallback */
  height: -webkit-fill-available;
}
@supports (height: 100dvh){
  .nxh-sidecart{ height: 100dvh; }
}

.nxh-sidecart.is-open{ transform: translateX(0); }

.nxh-sidecart-inner{
  width: 100%;
  display: flex;
  flex-direction: column;
  height: 100%;
}

/* =========================
   HEADER
   ========================= */
.nxh-sidecart-header{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  padding:8px;
  border-bottom:1px solid rgba(0,0,0,0);
  background: white;
}
.nxh-sidecart-title{ font-size:18px; font-weight:400 !important; color: black;}
.nxh-sidecart-subtitle{ font-size:12px; opacity:.7; margin-top:2px; }
.nxh-sidecart-close{
  border:0;
  background:transparent;
  font-size:18px;
  cursor:pointer;
  color: black;
}

/* =========================
   BODY
   ========================= */
.nxh-sidecart-body{
  padding:16px;
  overflow:auto;
  flex: 1 1 auto;

  /* ✅ evita que el scroll “choque” con el home bar */
  padding-bottom: calc(16px + env(safe-area-inset-bottom));
}
.nxh-cart-item{
  display:flex;
  gap:12px;
  padding:12px 0;
  border-bottom:1px solid rgba(0,0,0,.06);
}
.nxh-cart-item-thumb img{
  width:64px;
  height:64px;
  object-fit:cover;
  border-radius:10px;
}
.nxh-cart-item-name a{
  text-decoration:none;
  color:inherit;
  font-weight:600;
}
.nxh-cart-item-line{
  display:flex;
  justify-content:space-between;
  margin-top:6px;
  font-size:13px;
  opacity:.85;
}
.nxh-cart-item-remove{
  margin-top:8px;
  border:0;
  background:transparent;
  cursor:pointer;
  text-decoration: underline;
  font-size:12px;
  opacity:.85;
}

/* =========================
   FOOTER
   ========================= */
.nxh-sidecart-footer{
  padding:16px;
  border-top:1px solid rgba(0,0,0,.08);
  background: #fafafa;

  /* ✅ safe-area para que no lo tape la barra inferior */
  padding-bottom: calc(16px + env(safe-area-inset-bottom));
}
.nxh-sidecart-subtotal{
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin-bottom:12px;
}
.nxh-sidecart-actions{
  display:flex;
  gap:10px;
}
.nxh-btn{
  display:inline-flex;
  justify-content:center;
  align-items:center;
  width:100%;
  padding:12px 14px;
  border-radius:12px;
  text-decoration:none;
  font-weight:700;
}
.nxh-btn-primary{ background:#111; color:#fff; }
.nxh-btn-secondary{ border:1px solid rgba(0,0,0,.2); color:#111; }
.nxh-sidecart-note{ margin-top:10px; font-size:12px; opacity:.7; }

/* =========================
   CART ICON + NOTIFICATION BADGE (DOT)
   ========================= */
.nxh-cart-trigger{
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px;          /* área clic */
  line-height: 1;
  overflow: visible;     /* por si el wrapper deja */
}

/* Icon */
.nxh-cart-icon{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;       /* desktop base */
  line-height: 1;
}

/* Badge: bolita arriba-derecha */
.nxh-cart-badge{
  position: absolute;
  top: 2px;
  right: 2px;

  /* círculo */
  width: 16px;
  height: 16px;
  min-width: 16px;
  padding: 0;

  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;

  font-size: 10px;
  font-weight: 700;

  background: #ff2d55;   /* rojo/pink tipo iOS (puedes cambiarlo) */
  color: #fff;

  /* borde blanco para que “flote” sobre el header */
  box-shadow: 0 0 0 2px #fff;
}

/* Si llega a 2 dígitos, ajusta sutil */
.nxh-cart-badge[data-count="10"],
.nxh-cart-badge[data-count="11"],
.nxh-cart-badge[data-count="12"]{
  width: 18px;
  min-width: 18px;
}

/* Tablet */
@media (max-width: 980px){
  .nxh-cart-icon{ font-size: 24px; }
  .nxh-cart-badge{
    width: 15px;
    height: 15px;
    min-width: 15px;
    font-size: 9px;
    top: 1px;
    right: 1px;
  }
}

/* Mobile */
@media (max-width: 768px){
  .nxh-cart-trigger{ padding: 10px; }
  .nxh-cart-icon{ font-size: 26px; }
  .nxh-cart-badge{
    width: 15px;
    height: 15px;
    min-width: 15px;
    font-size: 9px;
    top: 1px;
    right: 1px;
  }
}

/* =========================
   REMOVE CART ICON BACKGROUND
   ========================= */
.nxh-cart-trigger{
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  outline: none !important;
}

/* =========================
   CART ICON HOVER FEEDBACK
   ========================= */

/* Cursor de acción */
.nxh-cart-trigger{
  cursor: pointer;
}

/* Micro feedback visual (desktop / laptop) */
@media (hover: hover){
  .nxh-cart-trigger:hover{
    transform: scale(1.06);
  }

  .nxh-cart-trigger:active{
    transform: scale(0.96);
  }
}

/* Suavidad */
.nxh-cart-trigger{
  transition: transform .15s ease;
}

/* =========================
   BADGE BOUNCE ANIMATION
   ========================= */
@keyframes nxh-badge-bounce {
  0%   { transform: scale(1); }
  30%  { transform: scale(1.25); }
  55%  { transform: scale(0.92); }
  75%  { transform: scale(1.08); }
  100% { transform: scale(1); }
}

/* clase que dispara el bounce */
.nxh-cart-badge.is-bouncing{
  animation: nxh-badge-bounce .45s ease-out;
}

/* =========================
   STICKY FOOTER LAYOUT
   (Header fijo + Body scroll + Footer fijo)
   ========================= */

/* Asegura layout de columna */
.nxh-sidecart-inner{
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0; /* clave para que el scroll funcione dentro */
}

/* Header no se encoge */
.nxh-sidecart-header{
  flex: 0 0 auto;
}

/* El body es el que scrollea */
.nxh-sidecart-body{
  flex: 1 1 auto;
  min-height: 0;             /* clave */
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

/* Footer siempre visible */
.nxh-sidecart-footer{
  flex: 0 0 auto;
  position: sticky;
  bottom: 0;
  z-index: 2;
  background: #fafafa;
  box-shadow: 0 -10px 30px rgba(0,0,0,.06);
  padding-bottom: calc(16px + env(safe-area-inset-bottom));
}

/* Mobile: un poco más compacto */
@media (max-width: 768px){
  .nxh-sidecart-footer{
    padding-bottom: calc(12px + env(safe-area-inset-bottom));
  }
}

/* =========================
   MOBILE FIX: QTY + PRICE LINE
   ========================= */

/* La línea qty + precio siempre en una sola fila */
.nxh-cart-item-line{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 12px;
}

/* Evita que el control se rompa a 2 líneas */
.nxh-qty{
  display:inline-flex;
  align-items:center;
  flex-wrap: nowrap;
  gap: 8px;
  min-width: 140px; /* asegura espacio para - input + */
}

/* Botones redondos y consistentes */
.nxh-qty-btn{
  width: 32px;
  height: 32px;
  border-radius: 999px;
  border: 0;
  background: rgba(0,0,0,.08);
  color: #111;
  font-weight: 800;
  display:flex;
  align-items:center;
  justify-content:center;
  line-height: 1;
}

/* Input compacto fijo */
.nxh-qty-input{
  width: 44px;
  height: 32px;
  border-radius: 10px;
  border: 1px solid rgba(0,0,0,.12);
  background: #fff;
  text-align:center;
  font-weight: 700;
  padding: 0;
}

/* Precio nunca se pega ni se parte */
.nxh-cart-item-price{
  white-space: nowrap;
  min-width: 72px;
  text-align: right;
  font-weight: 700;
}

/* En pantallas chicas, más compacto aún */
@media (max-width: 420px){
  .nxh-qty{ min-width: 128px; gap: 6px; }
  .nxh-qty-btn{ width: 30px; height: 30px; }
  .nxh-qty-input{ width: 40px; height: 30px; }
  .nxh-cart-item-price{ min-width: 68px; }
}

/* =========================
   FREE SHIPPING PROGRESS
   ========================= */
.nxh-free-ship{
  margin-bottom: 12px;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(0,0,0,.04);
}

.nxh-free-ship-text{
  font-size: 12px;
  font-weight: 600;
  opacity: .9;
  margin-bottom: 8px;
}

.nxh-free-ship-bar{
  height: 10px;
  background: rgba(0,0,0,0);
  overflow: hidden;
}

.nxh-free-ship-fill{
  display:block;
  height: 100%;
  width: 0%;
  background: #111;
  transition: width .25s ease;
}

@media (max-width: 768px){
  .nxh-free-ship{
    padding: 10px 12px;
    margin-bottom: 10px;
  }
}

/* =========================
   UPSELL (SIDE CART) - MATCH con sidecart.php
   ========================= */
.nxh-sidecart-upsell{
  margin: 12px 0;
  padding: 14px;
  border-top: 1px solid rgba(0,0,0,.08);
  background: #fafafa;
}

.nxh-sidecart-upsell-head{
  margin-bottom: 10px;
}

.nxh-sidecart-upsell-title{
  font-size: 14px;
  font-weight: 700;
  color: #111;
}

.nxh-sidecart-upsell-subtitle{
  font-size: 12px;
  color: #666;
  margin-top: 2px;
}

.nxh-sidecart-upsell-card{
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(0,0,0,.04);
}

/* ✅ CLAVE: Contener thumbnail para que NO se haga gigante */
.nxh-sidecart-upsell-thumb{
  flex: 0 0 46px;
  width: 46px;
  min-width: 46px;
}

.nxh-sidecart-upsell-thumb img{
  width: 46px;
  height: 46px;
  object-fit: cover;
  border-radius: 10px;
  display: block;
}

.nxh-sidecart-upsell-meta{
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.nxh-sidecart-upsell-name{
  font-size: 12px;
  font-weight: 700;
  line-height: 1.2;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.nxh-sidecart-upsell-name a{
  color: inherit;
  text-decoration: none;
}

.nxh-sidecart-upsell-name a:hover{
  text-decoration: underline;
}

.nxh-sidecart-upsell-price{
  font-size: 12px;
  font-weight: 600;
  opacity: .7;
}

/* Botón: respetamos nxh-btn/nxh-btn-primary; aquí solo micro-ajustes */
.nxh-sidecart-upsell-add{
  align-self: flex-start;
  padding: 8px 12px;
  font-size: 12px;
  line-height: 1;
  white-space: nowrap;
}

.nxh-sidecart-upsell-add:disabled{
  opacity: .6;
  cursor: not-allowed;
}

.nxh-sidecart-upsell-add:not(:disabled):active{
  transform: scale(.98);
}

/* Header variant */
.nxh-free-ship--header{
  margin: 0px 0 0;
  padding: 10px 12px;
  background: rgba(0,0,0,0);
}

/* Si quieres que quede “pegado” al header cuando haya scroll en el body */
.nxh-sidecart-header{
  position: sticky;
  top: 0;
  z-index: 2;
  background: #fff; /* ajusta si tu header tiene otro color */
}

.nxh-free-ship--header{
  position: sticky;
  top: 56px; /* AJUSTA: altura real del header */
  z-index: 1;
  backdrop-filter: blur(6px);
}

/* =========================
   PAYMENT METHODS (Sidecart)
   ========================= */
.nxh-sidecart-payments{
  margin-top: 0px;
  padding-top: 0px;
  border-top: 1px solid rgba(0,0,0,.06);
}

.nxh-payment-icons{
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  align-items: center;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nxh-payment-icons li{
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  border-radius: 6px;
  padding: 4px 6px;
  box-shadow: 0 1px 2px rgba(0,0,0,.08);
}

.nxh-payment-icons img{
  height: 20px;
  width: auto;
  display: block;
}

.nxh-payment-note{
  text-align: center;
  font-size: 12px;
  opacity: .7;
  margin-bottom: 6px;
}

/* =========================
   FREE SHIPPING - Header block
   ========================= */
.nxh-free-ship--header{
  margin: 0px 0 0;
  padding: 12px;
  border-radius: 12px;
  background: rgba(0,0,0,0);
}

.nxh-free-ship-title{
  font-size: 14px;
  line-height: 1.2;
  display:block;
}

.nxh-free-ship-sub{
  font-size: 12px;
  opacity: .8;
}

.nxh-free-ship-top{
  display:flex;
  flex-direction:column;
  gap:4px;
  margin-bottom:10px;
}

/* bar */
.nxh-free-ship-bar{
  position: relative;
  height: 10px;
  border-radius: 999px;
  background: rgba(0,0,0,.10);
  overflow: hidden;
}

.nxh-free-ship-fill{
  position:absolute;
  top:0; left:0;
  height:100%;
  border-radius: 999px;
  background: rgba(0,0,0,.55);
  transition: width .25s ease;
}

/* meta */
.nxh-free-ship-meta{
  display:flex;
  justify-content:space-between;
  font-size: 11px;
  opacity: .75;
  margin-top: 8px;
}

/* =========================
   UNLOCKED: animated stripes
   ========================= */
.nxh-free-ship.is-unlocked .nxh-free-ship-fill{
  width: 100% !important;

  background-image: repeating-linear-gradient(
    135deg,
    rgba(0,0,0,.55) 0px,
    rgba(0,0,0,.55) 10px,
    rgba(0,0,0,.20) 10px,
    rgba(0,0,0,.20) 20px
  );
  background-size: 40px 40px;
  animation: nxhStripesMove 1.2s linear infinite;
}

@keyframes nxhStripesMove{
  from { background-position: 0 0; }
  to   { background-position: 40px 0; }
}

/* Cap icon (circle) */
.nxh-free-ship-cap{
  position: absolute;
  right: -10px;
  top: 50%;
  transform: translateY(-50%);
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: #fff;
  display: grid;
  place-items: center;
  box-shadow: 0 2px 8px rgba(0,0,0,.12);
  font-size: 14px;
}

@media (min-width: 768px){
  .nxh-free-ship.is-unlocked .nxh-free-ship-title{
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
}

/* =========================
   FIX MINIMO: fuerza estilos consistentes en header
   (evita que el bloque viejo "FREE SHIPPING PROGRESS" pise la barra)
   ========================= */
.nxh-free-ship--header .nxh-free-ship-bar{
  position: relative;
  height: 10px;
  background: rgba(0,0,0,0);
  overflow: hidden;
}

.nxh-free-ship--header .nxh-free-ship-fill{
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  background: rgba(0,0,0,.55);
  transition: width .25s ease;
  display: block;
}

.nxh-sidecart-head-left{
  display:flex;
  align-items: baseline;
  gap: 10px;
}

.nxh-sidecart-subtitle{
  margin-top: 0; /* mata el margin-top anterior */
}

.nxh-free-ship-row{
  display:flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}

.nxh-free-ship-row .nxh-free-ship-sub{
  white-space: nowrap;
}

@media (max-width: 380px){
  .nxh-free-ship-row{
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }
}

/* =========================
   PAYMENT METHODS (COMPACT)
   ========================= */
.nxh-sidecart-payments{
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid rgba(0,0,0,.06);
}

.nxh-payment-icons{
  display: flex;
  flex-wrap: nowrap;          /* ❌ no más saltos de línea */
  gap: 6px;
  justify-content: center;
  align-items: center;
  overflow-x: hidden;         /* seguridad */
}

.nxh-payment-icons img{
  height: 16px;               /* antes 20px */
  width: auto;
  display: block;
}

.nxh-payment-note{
  font-size: 11px;
  margin-bottom: 4px;
  opacity: .6;
}


@media (max-width: 360px){
  .nxh-payment-icons img{ height: 14px; }
}

.nxh-sidecart-header{
  border-bottom: none;
}

.nxh-free-ship--header{
  border-top: 0px solid rgba(0,0,0,.08);
}

/* HEADER: title + count inline */
.nxh-sidecart-header{
  display:flex;
  align-items:center;              /* antes align-items:flex-start */
  justify-content:space-between;
  padding:10px 12px;               /* un poquito más premium */
  border-bottom:1px solid rgba(0,0,0,.1);
  background:#fafafa;
}

.nxh-sidecart-title-row{
  display:flex;
  align-items:baseline;
  gap:10px;
}

.nxh-sidecart-title{
  font-size:18px;
  font-weight:800;
  line-height:1;
}

.nxh-sidecart-count{
  font-size:12px;
  opacity:.65;
  font-weight:600;
  line-height:1;
}

.nxh-sidecart-close{
  width:36px;
  height:36px;
  border:0;
  background:transparent;
  font-size:22px;
  cursor:pointer;
  display:grid;
  place-items:center;
}

.nxh-cart-icon{
  width: 26px;
  height: 26px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  color: black; /* o tu fucsia */
}
.nxh-cart-icon svg{ width:100%; height:100%; display:block; }

/* ====== CONTENEDOR DEL FULLSCREEN ====== */
body .ov-menu-movil-fullscreen .opened .et_mobile_menu,
.et-db #et-boc .et-l .ov-menu-movil-fullscreen .opened .et_mobile_menu{
  background: #fff !important;
  justify-content: flex-start !important;
  align-items: stretch !important;
  padding: 90px 26px 30px !important; /* espacio para la X */
}

/* ====== ITEMS ====== */
body .ov-menu-movil-fullscreen .et_mobile_menu li a,
.et-db #et-boc .et-l .ov-menu-movil-fullscreen .et_mobile_menu li a{
  display: flex !important;
  justify-content: space-between !important;
  align-items: center !important;

  font-size: 16px !important;
  font-weight: 500 !important;
  letter-spacing: .08em !important;
  text-transform: uppercase !important;

  color: #111 !important;
  padding: 16px 2px !important;
  line-height: 1.2 !important;

  border-bottom: 1px solid rgba(0,0,0,.06) !important;
}

/* Hover / active */
body .ov-menu-movil-fullscreen .et_mobile_menu li a:hover,
.et-db #et-boc .et-l .ov-menu-movil-fullscreen .et_mobile_menu li a:hover{
  opacity: 1 !important;
  background: rgba(0,0,0,.03) !important;
  padding-left: 10px !important;
  transition: all .18s ease-in-out;
}

/* ====== FLECHA PARA LOS QUE TIENEN SUBMENU ====== */
body .ov-menu-movil-fullscreen .et_mobile_menu .menu-item-has-children > a:after,
.et-db #et-boc .et-l .ov-menu-movil-fullscreen .et_mobile_menu .menu-item-has-children > a:after{
  content: "›" !important;
  font-size: 22px !important;
  opacity: .6 !important;
  transform: translateY(-1px);
}

/* ====== ESPACIADO ENTRE BLOQUES ====== */
body .ov-menu-movil-fullscreen .et_mobile_menu li,
.et-db #et-boc .et-l .ov-menu-movil-fullscreen .et_mobile_menu li{
  margin: 0 !important;
  padding: 0 !important;
}

/* ====== BOTÓN X (más “pro”) ====== */
body .ov-menu-movil-fullscreen .opened .mobile_menu_bar,
.et-db #et-boc .et-l .ov-menu-movil-fullscreen .opened .mobile_menu_bar{
  top: 22px !important;
  right: 22px !important;
  width: 44px !important;
  height: 44px !important;
  display: grid !important;
  place-items: center !important;
  border-radius: 999px !important;
  background: rgba(0,0,0,.05) !important;
}

/* Tamaño del ícono X */
body .ov-menu-movil-fullscreen .et_pb_menu__wrap .opened .mobile_menu_bar:before,
.et-db #et-boc .et-l .ov-menu-movil-fullscreen .et_pb_menu__wrap .opened .mobile_menu_bar:before{
  font-size: 28px !important;
}

/* ====== SUBMENU (si lo usas) ====== */
body .ov-menu-movil-fullscreen .et_mobile_menu .sub-menu,
.et-db #et-boc .et-l .ov-menu-movil-fullscreen .et_mobile_menu .sub-menu{
  padding: 6px 0 10px 14px !important;
}

body .ov-menu-movil-fullscreen .et_mobile_menu .sub-menu li a,
.et-db #et-boc .et-l .ov-menu-movil-fullscreen .et_mobile_menu .sub-menu li a{
  font-size: 14px !important;
  font-weight: 500 !important;
  letter-spacing: .06em !important;
  text-transform: none !important;
  border-bottom: 0 !important;
  padding: 12px 2px !important;
  opacity: .9 !important;
}

/* Quitar bullets del menú */
body .ov-menu-movil-fullscreen .et_mobile_menu,
body .ov-menu-movil-fullscreen .et_mobile_menu li,
body .ov-menu-movil-fullscreen .et_mobile_menu .sub-menu,
body .ov-menu-movil-fullscreen .et_mobile_menu .sub-menu li{
  list-style: none !important;
}

body .ov-menu-movil-fullscreen .et_mobile_menu{
  padding-left: 0 !important;
  margin-left: 0 !important;
}


body .ov-menu-movil-fullscreen .opened .mobile_menu_bar{
  top: 14px !important;
  right: 50px !important;
}



