/* Kore4n: header y paneles propios; sin reglas globales para botones. */
.k4-header{position:relative;z-index:100;background:#fff;border-bottom:1px solid #eee;color:#171717;font-family:var(--e-global-typography-text-font-family,'Segment',sans-serif)}
.k4-header__inner{width:90%;max-width:none;margin:auto;min-height:78px;display:grid;grid-template-columns:1fr auto 1fr;align-items:center;gap:28px}
.k4-header__logo{display:inline-flex;align-items:center;max-width:245px;min-width:0;color:#171717;font-size:22px;font-weight:600;text-decoration:none}.k4-header__logo img{height:auto;max-height:48px;width:auto}
.k4-header__nav{justify-self:center}.k4-main-menu,.k4-mobile-links{list-style:none;margin:0;padding:0}.k4-main-menu{display:flex;gap:40px;align-items:center}.k4-main-menu li{position:relative}.k4-main-menu a,.k4-mobile-links a{color:#111;text-decoration:none;font-weight:500}.k4-main-menu a:hover,.k4-mobile-links a:hover{text-decoration:underline;text-underline-offset:3px}.k4-main-menu .sub-menu{display:none;position:absolute;top:100%;left:0;background:white;min-width:190px;padding:12px;box-shadow:0 8px 24px #0002;list-style:none}.k4-main-menu li:hover>.sub-menu,.k4-main-menu li:focus-within>.sub-menu{display:block}
.k4-header__actions{display:flex;justify-content:flex-end;align-items:center;gap:20px}.k4-header__icon{position:relative;display:inline-flex;align-items:center;justify-content:center;min-width:24px;min-height:32px;flex-shrink:0;background:transparent;border:0;border-radius:0;box-shadow:none;padding:0;color:#111;cursor:pointer;line-height:1;text-transform:none}.k4-header__icon:hover{color:#555;background:transparent}.k4-header__mobile-menu{display:none}.k4-cart-count{position:absolute;top:-5px;right:-8px;border-radius:50%;background:#ef4e55;color:#fff;min-width:17px;height:17px;padding:2px;font:600 10px/13px Arial;text-align:center}.k4-cart-count[hidden]{display:none}
.k4-header__overlay{position:fixed;inset:0;background:#0009;z-index:1001}.k4-header__overlay[hidden]{display:none}
.k4-search,.k4-drawer{position:fixed;z-index:1002;background:#fff;color:#171717;font-family:var(--e-global-typography-text-font-family,'Segment',sans-serif);visibility:hidden;pointer-events:none}.k4-search.is-open,.k4-drawer.is-open{visibility:visible;pointer-events:auto}
.k4-search{left:0;right:0;top:0;min-height:145px;padding:24px max(6vw,48px);display:flex;flex-direction:column;align-items:center;gap:14px;transform:translateY(-100%);transition:transform .22s ease}.k4-search.is-open{transform:translateY(0)}.k4-search__form{display:flex;width:min(1060px,90%);min-height:56px;border:1px solid #111;border-radius:7px;overflow:hidden;margin:0}.k4-search__form input{flex:1;min-width:0;border:0;border-radius:0;padding:0 18px;color:#333;font:inherit;background:#fff;box-shadow:none}.k4-search__form button{display:grid;place-items:center;width:60px;padding:0;background:#fff;color:#111;border:0;border-left:1px solid #111;border-radius:0;min-height:0}.k4-search__suggestions{font-size:14px;display:flex;gap:9px;flex-wrap:wrap;justify-content:center}.k4-search__suggestions a{color:#111;text-decoration:underline;text-underline-offset:3px}.k4-search__desktop-close{position:absolute;right:24px;top:20px}.k4-search__mobile-head{display:none!important}
.k4-drawer{right:0;top:0;bottom:0;width:min(480px,100%);display:flex;flex-direction:column;transform:translateX(100%);transition:transform .22s ease}.k4-drawer.is-open{transform:translateX(0)}.k4-panel-head{display:flex;justify-content:space-between;align-items:center;padding:22px 24px;border-bottom:1px solid #e5e5e5;min-height:70px}.k4-panel-head strong{font-size:17px;font-weight:600}.k4-cart-content{flex:1;overflow:auto;display:flex;flex-direction:column;min-height:0}.k4-cart-content>.widget_shopping_cart_content,.k4-cart-content>.woocommerce-mini-cart{flex:1}.k4-cart-content .woocommerce-mini-cart{padding:20px;list-style:none;margin:0;overflow-y:auto}.k4-cart-content .woocommerce-mini-cart-item{display:grid;grid-template-columns:74px 1fr;gap:12px;padding:14px 0;border-bottom:1px solid #e5e5e5;position:relative}.k4-cart-content .woocommerce-mini-cart-item>a:not(.remove){grid-column:1/-1;display:block;padding-left:88px;min-height:76px;text-decoration:none;color:#333;font-weight:600}.k4-cart-content .woocommerce-mini-cart-item img{position:absolute;left:0;top:14px;width:74px;height:74px;object-fit:cover}.k4-cart-content .woocommerce-mini-cart-item .quantity{grid-column:2;color:#333}.k4-cart-content .woocommerce-mini-cart-item .remove{position:absolute;right:0;top:10px;font-size:20px;color:#666}.k4-cart-content .woocommerce-mini-cart__total{display:flex;justify-content:space-between;padding:16px 22px;margin:auto 0 0;border-top:1px solid #ddd}.k4-cart-content .woocommerce-mini-cart__buttons{display:flex;flex-direction:column;gap:8px;padding:0 20px 20px;margin:0}.k4-cart-content .woocommerce-mini-cart__buttons a{display:block;text-align:center;background:#111;border-radius:999px;color:#fff;text-decoration:none;padding:14px 20px;font-weight:600}.k4-cart-content .woocommerce-mini-cart__buttons a:first-child{background:#fff;color:#111;border:1px solid #111}.k4-cart-content .woocommerce-mini-cart__empty-message{margin:auto;text-align:center;padding:25px;color:#333}.k4-drawer--menu{left:0;right:auto;transform:translateX(-100%);padding-bottom:20px}.k4-drawer--menu .k4-mobile-links{padding:24px;display:grid;gap:18px}.k4-drawer--menu>a{margin:0 24px}
body.k4-panel-open{overflow:hidden}
/* My Account uses native WooCommerce authentication and account endpoints. */
body.woocommerce-account .woocommerce:not(.widget_shopping_cart_content) .woocommerce-form-login,body.woocommerce-account .woocommerce:not(.widget_shopping_cart_content) .woocommerce-form-register,body.woocommerce-account .woocommerce-ResetPassword{max-width:560px;margin:30px auto 60px;border:0;background:transparent;padding:0;box-shadow:none;color:#333}
body.woocommerce-account .woocommerce-form input.input-text,body.woocommerce-account .woocommerce-ResetPassword input.input-text{width:100%;border:1px solid #ccc;border-radius:10px;min-height:50px;padding:12px;background:#fff;color:#333}
body.woocommerce-account .woocommerce-form button.button,body.woocommerce-account .woocommerce-ResetPassword button.button{display:block;width:100%;padding:15px;border-radius:999px;background:#111;color:#fff;text-transform:none;min-height:52px}
@media(max-width:767px){.k4-header__inner{width:100%;padding:0 16px;min-height:58px;grid-template-columns:auto 1fr auto;gap:16px}.k4-header__mobile-menu{display:inline-flex}.k4-header__logo{font-size:19px}.k4-header__logo img{max-height:38px}.k4-header__nav,.k4-header__account{display:none}.k4-header__actions{gap:18px}.k4-search{left:auto;right:0;top:0;bottom:0;width:min(400px,100%);min-height:0;padding:0 16px;gap:15px;align-items:stretch;transform:translateX(100%)}.k4-search.is-open{transform:translateX(0)}.k4-search__desktop-close{display:none}.k4-search__mobile-head{display:flex!important;border:0;padding:18px 0;min-height:68px}.k4-search__form{width:100%;min-height:48px}.k4-search__suggestions{justify-content:flex-start}.k4-search__suggestions span{flex-basis:100%}.k4-panel-head{padding:18px 20px}.k4-drawer{width:min(390px,100%)}body.woocommerce-account .woocommerce-form-login,body.woocommerce-account .woocommerce-form-register{padding:0 16px}}
@media(prefers-reduced-motion:reduce){.k4-search,.k4-drawer{transition:none}}

/* v1.5.2: encabezado Kore4n; no depende del Header Builder.
   Usamos flex y selectores del componente para evitar estilos genéricos de WoodMart. */
#k4-header {width:100%;background:#fff;border-bottom:1px solid #eee;}
#k4-header .k4-header__inner {
  display:flex;flex-direction:row;flex-wrap:nowrap;align-items:center;
  justify-content:space-between;width:90%;max-width:none;min-height:78px;
  margin-inline:auto;padding:0;gap:24px;box-sizing:border-box;
}
#k4-header .k4-header__logo {
  display:inline-flex;flex:0 1 245px;justify-content:flex-start;align-items:center;
  min-width:0;margin:0;padding:0;line-height:1.2;white-space:nowrap;
}
#k4-header .k4-header__nav {
  display:block;flex:1 1 auto;min-width:0;margin:0;padding:0;
}
#k4-header .k4-main-menu {
  display:flex;flex-flow:row nowrap;justify-content:center;align-items:center;
  gap:clamp(16px,3vw,40px);margin:0;padding:0;list-style:none;
}
#k4-header .k4-main-menu > li {margin:0;padding:0;flex:0 0 auto;}
#k4-header .k4-main-menu > li > a {display:inline-block;padding:0;line-height:1.5;white-space:nowrap;}
#k4-header .k4-header__actions {
  display:flex;flex:0 0 auto;justify-content:flex-end;align-items:center;
  flex-wrap:nowrap;gap:20px;margin:0;padding:0;
}
#k4-header .k4-header__icon {
  position:relative;display:inline-flex;align-items:center;justify-content:center;
  width:26px;height:32px;min-width:26px;min-height:0;padding:0;margin:0;
  border:0;border-radius:0;background:transparent;box-shadow:none;
  color:#111;line-height:1;text-transform:none;vertical-align:middle;
}
#k4-header .k4-header__icon:hover {background:transparent;color:#333;}
#k4-header .k4-header__mobile-menu {display:none;}
#k4-header .k4-header__logo img {display:block;width:auto;height:auto;max-height:48px;}
@media (max-width: 767px) {
  #k4-header .k4-header__inner {
    width:100%;min-height:58px;padding-inline:16px;gap:14px;
  }
  #k4-header .k4-header__mobile-menu {display:inline-flex;flex:0 0 26px;}
  #k4-header .k4-header__logo {flex:1 1 auto;max-width:none;font-size:19px;}
  #k4-header .k4-header__logo img {max-height:38px;}
  #k4-header .k4-header__nav {display:none;}
  #k4-header .k4-header__account {display:none;}
  #k4-header .k4-header__actions {gap:18px;}
}
@media (min-width: 768px) and (max-width: 1024px) {
  #k4-header .k4-header__inner {width:94%;gap:14px;}
  #k4-header .k4-header__logo {flex-basis:165px;}
  #k4-header .k4-header__actions {gap:14px;}
}

/* v1.5.4: dimensiones del logo Kore4n sin distorsionar su proporción. */
#k4-header .k4-header__logo {flex:0 1 175px;max-width:175px;}
#k4-header .k4-header__logo img {display:block;width:auto;max-width:100%;height:auto;max-height:33px;object-fit:contain;}
@media (max-width:767px) {
  #k4-header .k4-header__logo {flex:1 1 auto;max-width:145px;}
  #k4-header .k4-header__logo img {max-height:27px;}
}
@media (min-width:768px) and (max-width:1024px) {
  #k4-header .k4-header__logo {flex:0 1 150px;max-width:150px;}
}

/* v1.5.5: independent Kore4n cart layout (does not use WoodMart mini-cart markup). */
.k4-drawer .k4-cart-content{display:flex;flex:1;min-height:0;flex-direction:column;overflow:hidden;width:100%;}
.k4-drawer .k4-cart-items{list-style:none;margin:0;padding:12px 20px;overflow-y:auto;flex:1;min-height:0;}
.k4-drawer .k4-cart-item{display:grid;grid-template-columns:80px minmax(0,1fr);gap:14px;padding:18px 0;border-bottom:1px solid #e8e8e8;min-width:0;}

.k4-drawer .k4-cart-item__info{display:flex;min-width:0;flex-direction:column;align-items:flex-start;gap:7px;}
.k4-drawer .k4-cart-item__name{display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden;overflow-wrap:anywhere;line-height:1.4;font-weight:600;color:#111;text-decoration:none;}
.k4-drawer .k4-cart-item__price{font-size:14px;color:#333;line-height:1.3;}
.k4-drawer .k4-cart-item__controls{display:flex;align-items:center;gap:9px;flex-wrap:wrap;}
.k4-drawer .k4-cart-item__controls button:not(.k4-cart-item__remove){width:29px;height:29px;min-height:0;padding:0;border:1px solid #ddd;border-radius:50%;background:#fff;color:#111;display:inline-grid;place-items:center;font:inherit;}
.k4-drawer .k4-cart-item__qty{min-width:10px;text-align:center;color:#111;}
.k4-drawer .k4-cart-item__remove{min-height:0;background:none;border:0;padding:0;color:#777;text-decoration:underline;font:inherit;font-size:13px;text-transform:none;}
.k4-drawer .k4-cart-bottom{flex:none;border-top:1px solid #e9e9e9;padding:18px 20px 25px;background:#fff;}
.k4-drawer .k4-cart-bottom__subtotal{display:flex;align-items:center;justify-content:space-between;margin-bottom:18px;color:#111;}
.k4-drawer .k4-cart-bottom__subtotal strong{font-weight:600;}
.k4-drawer .k4-cart-cta{display:block;width:100%;background:#111;color:#fff;text-align:center;text-decoration:none;border-radius:999px;padding:14px 20px;font-weight:600;line-height:1.4;}
.k4-drawer .k4-cart-empty{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;gap:12px;padding:32px 28px;color:#111;}
.k4-drawer .k4-cart-empty p{margin:0 0 10px;color:#777;line-height:1.5;}
.k4-drawer .k4-cart-empty .k4-cart-cta{max-width:225px;}

/* v1.5.7 — Mini-carrito: imágenes completas y sin recorte.
   .k4-drawer está fuera de #k4-header: las reglas no deben depender de ese ancestro. */
.k4-drawer .k4-cart-item__image {
  display:flex;
  align-items:center;
  justify-content:center;
  width:80px;
  height:80px;
  min-width:0;
  padding:4px;
  box-sizing:border-box;
  overflow:hidden;
  background:#f8f8f8;
  border-radius:7px;
}
.k4-drawer .k4-cart-item__image img {
  position:static;
  display:block;
  width:100%;
  height:100%;
  max-width:100%;
  max-height:100%;
  min-width:0;
  margin:0;
  padding:0;
  object-fit:contain;
  object-position:center;
  border:0;
  border-radius:0;
  box-shadow:none;
}
.k4-drawer .k4-cart-item__price{display:flex;align-items:baseline;gap:7px;flex-wrap:wrap}
.k4-drawer .k4-cart-item__regular{color:#999;text-decoration:line-through;font-weight:400}
.k4-drawer .k4-cart-item__current{text-decoration:none;color:#ff5173;font-weight:500}
.k4-drawer .k4-cart-item__current .amount{color:inherit}

/* Precio anterior visible incluso con estilos de precios WooCommerce. */
.k4-drawer .k4-cart-item__price del.k4-cart-item__regular,
.k4-drawer .k4-cart-item__price del.k4-cart-item__regular .amount {color:#999;text-decoration:line-through;opacity:1}

/* Resumen de ahorros en ofertas del catálogo, no incluye cupones. */
.k4-drawer .k4-cart-bottom__regular,
.k4-drawer .k4-cart-bottom__savings{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:10px;font-size:14px;line-height:1.5;}
.k4-drawer .k4-cart-bottom__regular del,
.k4-drawer .k4-cart-bottom__regular del .woocommerce-Price-amount,
.k4-drawer .k4-cart-bottom__regular del .amount{color:#999999;text-decoration:line-through;font-weight:400;}
.k4-drawer .k4-cart-bottom__savings strong,
.k4-drawer .k4-cart-bottom__savings strong .woocommerce-Price-amount,
.k4-drawer .k4-cart-bottom__savings strong .amount{color:#218653;font-weight:500;}
.k4-drawer .k4-cart-bottom__subtotal>span{color:#333333;font-weight:600;}
.k4-drawer .k4-cart-bottom__subtotal strong,
.k4-drawer .k4-cart-bottom__subtotal strong .woocommerce-Price-amount,
.k4-drawer .k4-cart-bottom__subtotal strong .amount{color:#ff5173;font-weight:600;}

/* Kore4n: header exclusivo de finalizar compra, referencia minimalista. */
body.k4-checkout header#k4-header.k4-checkout-header{background-color:#ff5173!important;border:0;color:#fff;position:relative;z-index:100}
body.k4-checkout .k4-checkout-header__inner{position:relative;display:flex;align-items:center;justify-content:space-between;width:100%;max-width:1172px;min-height:62px;padding:10px 16px;margin:0 auto}
body.k4-checkout .k4-checkout-header__logo{display:inline-flex;align-items:center;justify-content:center;max-width:min(220px,65vw);color:#fff;font-size:22px;font-weight:700;text-align:center;text-decoration:none;line-height:1.2}
body.k4-checkout .k4-checkout-header__logo img{display:block;max-width:100%;max-height:38px;width:auto;height:auto;object-fit:contain;filter:brightness(0) invert(1)}
body.k4-checkout .k4-checkout-header__cart{position:static;transform:none;margin-left:auto;display:inline-flex;justify-content:center;align-items:center;width:36px;height:36px;color:#fff;background:transparent;border:0;text-decoration:none;box-shadow:none}
body.k4-checkout .k4-checkout-header__cart svg{width:22px;height:22px;stroke:currentColor}
body.k4-checkout .k4-checkout-header__cart:hover,body.k4-checkout .k4-checkout-header__cart:focus-visible{color:#fff;opacity:.7;background:transparent}
@media(max-width:767px){body.k4-checkout .k4-checkout-header__inner{min-height:60px;padding:9px 16px}body.k4-checkout .k4-checkout-header__logo img{max-height:32px}body.k4-checkout .k4-checkout-header__cart{margin-left:auto}}
