/* ============================================================
   MSP — Mi Sitio Privado | Frontend Styles
   ============================================================ */

/* Variables */
:root {
  --psb-accent:   #1a1a2e;
  --psb-accent2:  #0f3460;
  --psb-cta:      #e94560;
  --psb-cta-h:    #c73652;
  --psb-bg:       #ffffff;
  --psb-surface:  #f8f9fc;
  --psb-border:   #e2e6ed;
  --psb-text:     #1a1a2e;
  --psb-muted:    #6b7280;
  --psb-radius:   14px;
  --psb-shadow:   0 24px 64px rgba(0,0,0,.18), 0 4px 16px rgba(0,0,0,.10);
  --psb-trans:    .22s cubic-bezier(.4,0,.2,1);
}

/* ---- OVERLAY ---- */
.psb-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 10, 25, .72);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999999;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--psb-trans);
  padding: 16px;
}
.psb-overlay.psb-open {
  opacity: 1;
  pointer-events: all;
}

/* ---- POPUP BOX ---- */
.psb-popup {
  background: var(--psb-bg);
  border-radius: var(--psb-radius);
  box-shadow: var(--psb-shadow);
  width: 100%;
  max-width: 440px;
  padding: 36px 36px 32px;
  position: relative;
  transform: translateY(24px) scale(.97);
  transition: transform var(--psb-trans);
  max-height: 90vh;
  overflow-y: auto;
}
.psb-overlay.psb-open .psb-popup {
  transform: translateY(0) scale(1);
}

/* ---- CERRAR ---- */
.psb-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: var(--psb-surface);
  border: none;
  border-radius: 50%;
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--psb-muted);
  transition: background var(--psb-trans), color var(--psb-trans);
}
.psb-close:hover { background: var(--psb-border); color: var(--psb-text); }

/* ---- BRAND ---- */
.psb-brand {
  text-align: center;
  margin-bottom: 20px;
}
.psb-brand img { max-height: 48px; width: auto; }
.psb-site-name {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--psb-accent);
  letter-spacing: -.3px;
}

/* ---- TABS ---- */
.psb-tabs {
  display: flex;
  background: var(--psb-surface);
  border-radius: 8px;
  padding: 4px;
  gap: 4px;
  margin-bottom: 24px;
}
.psb-tab {
  flex: 1;
  padding: 9px 0;
  border: none;
  background: transparent;
  border-radius: 6px;
  font-size: .875rem;
  font-weight: 600;
  color: var(--psb-muted);
  cursor: pointer;
  transition: background var(--psb-trans), color var(--psb-trans), box-shadow var(--psb-trans);
}
.psb-tab.active {
  background: var(--psb-bg);
  color: var(--psb-accent);
  box-shadow: 0 1px 6px rgba(0,0,0,.10);
}

/* ---- FIELDS ---- */
.psb-field {
  margin-bottom: 16px;
}
.psb-field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.psb-field label {
  display: block;
  font-size: .8rem;
  font-weight: 600;
  color: var(--psb-text);
  margin-bottom: 6px;
  letter-spacing: .2px;
}
.psb-field label .req { color: var(--psb-cta); }
.psb-field input {
  width: 100%;
  padding: 10px 13px;
  border: 1.5px solid var(--psb-border);
  border-radius: 8px;
  font-size: .9rem;
  color: var(--psb-text);
  background: var(--psb-bg);
  transition: border-color var(--psb-trans), box-shadow var(--psb-trans);
  outline: none;
  box-sizing: border-box;
}
.psb-field input:focus {
  border-color: var(--psb-accent2);
  box-shadow: 0 0 0 3px rgba(15, 52, 96, .12);
}
.psb-field input::placeholder { color: #b0b8c4; }

/* Password wrap */
.psb-pass-wrap { position: relative; }
.psb-pass-wrap input { padding-right: 40px; }
.psb-toggle-pass {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  color: var(--psb-muted);
  padding: 4px;
  display: flex;
  align-items: center;
}
.psb-toggle-pass:hover { color: var(--psb-text); }

/* Strength bar */
.psb-strength-bar {
  height: 3px;
  background: var(--psb-border);
  border-radius: 99px;
  margin-top: 6px;
  overflow: hidden;
}
#psb-strength-fill {
  display: block;
  height: 100%;
  width: 0;
  border-radius: 99px;
  transition: width .3s, background .3s;
}

/* ---- CHECKBOX ---- */
.psb-check {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .82rem;
  color: var(--psb-muted);
  margin-bottom: 18px;
  cursor: pointer;
}
.psb-check input { width: 15px; height: 15px; accent-color: var(--psb-accent2); cursor: pointer; }

/* ---- BUTTON ---- */
.psb-btn {
  width: 100%;
  padding: 12px;
  background: var(--psb-cta);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: .95rem;
  font-weight: 700;
  cursor: pointer;
  letter-spacing: .2px;
  transition: background var(--psb-trans), transform .12s;
  position: relative;
  overflow: hidden;
}
.psb-btn:hover  { background: var(--psb-cta-h); }
.psb-btn:active { transform: scale(.98); }
.psb-btn:disabled {
  opacity: .65;
  cursor: not-allowed;
}
/* Spinner inside button */
.psb-btn.loading::after {
  content: '';
  display: inline-block;
  width: 14px;
  height: 14px;
  border: 2px solid rgba(255,255,255,.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: psb-spin .7s linear infinite;
  margin-left: 10px;
  vertical-align: middle;
}
@keyframes psb-spin { to { transform: rotate(360deg); } }

/* ---- MESSAGES ---- */
.psb-message {
  padding: 11px 14px;
  border-radius: 8px;
  font-size: .85rem;
  margin-bottom: 16px;
  line-height: 1.5;
}
.psb-message.success { background: #e8f5e9; color: #2e7d32; border: 1px solid #c8e6c9; }
.psb-message.error   { background: #fdecea; color: #c62828; border: 1px solid #ffcdd2; }

/* ---- FOOTER LINK ---- */
.psb-footer-link {
  text-align: center;
  margin-top: 14px;
  font-size: .82rem;
}
.psb-footer-link a {
  color: var(--psb-accent2);
  text-decoration: none;
}
.psb-footer-link a:hover { text-decoration: underline; }

/* ---- NOTICE TEXT ---- */
.psb-notice-text {
  font-size: .8rem;
  color: var(--psb-muted);
  background: var(--psb-surface);
  border-left: 3px solid var(--psb-accent2);
  padding: 8px 12px;
  border-radius: 0 6px 6px 0;
  margin-bottom: 16px;
  line-height: 1.4;
}

/* ---- PANTALLA DE ÉXITO POST-REGISTRO ---- */
.psb-success-icon {
  margin: 0 auto 14px;
  width: 72px;
  height: 72px;
  background: #e8f5e9;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: psb-pop .4s cubic-bezier(.175,.885,.32,1.275) both;
}
@keyframes psb-pop {
  from { transform: scale(.5); opacity: 0; }
  to   { transform: scale(1);  opacity: 1; }
}
.psb-success-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: #1a1a2e;
  margin: 0 0 10px;
  letter-spacing: -.3px;
}
.psb-success-text {
  font-size: .9rem;
  color: #444;
  line-height: 1.65;
  margin: 0 0 16px;
}
.psb-success-note {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: .78rem;
  color: var(--psb-muted);
  background: var(--psb-surface);
  border-radius: 6px;
  padding: 7px 12px;
  margin-bottom: 22px;
}
.psb-btn-outline {
  background: transparent !important;
  color: var(--psb-accent) !important;
  border: 2px solid var(--psb-border) !important;
  font-weight: 600 !important;
}
.psb-btn-outline:hover {
  background: var(--psb-surface) !important;
  border-color: var(--psb-accent2) !important;
}

/* ---- RESPONSIVE ---- */
@media (max-width: 480px) {
  .psb-popup { padding: 28px 20px 24px; }
  .psb-field-row { grid-template-columns: 1fr; }
}

/* ============================================================
   MSP ORDER SIDEBAR
   ============================================================ */

/* FAB flotante */
.psb-cart-fab {
  position: fixed;
  bottom: 28px;
  right: 28px;
  z-index: 9990;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #25d366;
  color: #fff;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(37,211,102,.45);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform .2s, box-shadow .2s;
  overflow: visible !important;
}
.psb-cart-fab:hover { transform: scale(1.08); box-shadow: 0 6px 24px rgba(37,211,102,.55); }
.psb-cart-fab svg {
  width: 30px !important;
  height: 30px !important;
  min-width: 30px !important;
  flex-shrink: 0 !important;
}
.psb-cart-count {
  position: absolute;
  top: -8px;
  right: -8px;
  background: #e94560;
  color: #fff;
  font-size: .7rem;
  font-weight: 800;
  min-width: 22px;
  height: 22px;
  border-radius: 99px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 5px;
  border: 2.5px solid #fff;
  z-index: 9999 !important;
  box-shadow: 0 2px 6px rgba(0,0,0,.25);
  pointer-events: none;
}

/* Sidebar */
.psb-order-sidebar {
  position: fixed;
  top: 0;
  right: -420px;
  width: 100%;
  max-width: 400px;
  height: 100vh;
  background: #fff;
  z-index: 99991;
  box-shadow: -4px 0 32px rgba(0,0,0,.15);
  display: flex;
  flex-direction: column;
  transition: right .32s cubic-bezier(.4,0,.2,1);
}
.psb-order-sidebar.open { right: 0; }

.psb-sidebar-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.45);
  z-index: 99990;
  opacity: 0;
  pointer-events: none;
  transition: opacity .32s;
}
.psb-sidebar-overlay.open { opacity: 1; pointer-events: all; }

/* Header */
.psb-sidebar-header {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  padding: 18px 20px !important;
  border-bottom: 1px solid #e2e8f0 !important;
  gap: 12px !important;
}
.psb-sidebar-header h3 { margin: 0 !important; font-size: 1.05rem !important; color: #1a1a2e !important; flex: 1 !important; }
.psb-sidebar-close {
  background: #e2e8f0 !important;
  border: 2px solid #94a3b8 !important;
  border-radius: 50% !important;
  width: 34px !important;
  height: 34px !important;
  min-width: 34px !important;
  min-height: 34px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  cursor: pointer !important;
  color: #1a1a2e !important;
  transition: background .15s, border-color .15s !important;
  padding: 0 !important;
  margin: 0 !important;
  flex-shrink: 0 !important;
  line-height: 1 !important;
  font-size: 20px !important;
  font-weight: 700 !important;
  overflow: visible !important;
  visibility: visible !important;
  opacity: 1 !important;
  z-index: 10 !important;
  position: relative !important;
}
.psb-sidebar-close:hover { background: #cbd5e1 !important; border-color: #64748b !important; }
.psb-sidebar-close svg {
  display: block !important;
  width: 16px !important;
  height: 16px !important;
  stroke: #1a1a2e !important;
  stroke-width: 2.5 !important;
  pointer-events: none !important;
}

/* Body */
.psb-sidebar-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
}
.psb-order-empty { color: #9ca3af; text-align: center; padding: 32px 0; font-size: .9rem; }

/* Item de pedido */
.psb-order-item {
  display: grid;
  grid-template-columns: 48px 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid #f1f5f9;
}
.psb-order-item-img {
  width: 48px;
  height: 48px;
  border-radius: 6px;
  object-fit: cover;
  background: #f1f5f9;
}
.psb-order-item-img-placeholder {
  width: 48px;
  height: 48px;
  border-radius: 6px;
  background: #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #b0b8c4;
  font-size: 1.2rem;
}
.psb-order-item-info { min-width: 0; }
.psb-order-item-name { font-size: .88rem; font-weight: 600; color: #1a1a2e; margin-bottom: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.psb-order-item-price { font-size: .82rem; color: #6b7280; }
.psb-order-item-controls { display: flex; align-items: center; gap: 6px; }
.psb-qty-btn {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 1.5px solid #e2e8f0;
  background: #fff;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #374151;
  transition: background .15s, border-color .15s;
  line-height: 1;
}
.psb-qty-btn:hover { background: #f1f5f9; border-color: #94a3b8; }
.psb-qty-val { font-size: .9rem; font-weight: 700; min-width: 20px; text-align: center; }
.psb-item-remove {
  background: none;
  border: none;
  cursor: pointer;
  color: #e94560;
  font-size: 1rem;
  padding: 2px 4px;
  margin-left: 2px;
  line-height: 1;
}

/* Footer */
.psb-sidebar-footer { padding: 16px; border-top: 1px solid #e2e8f0; }
.psb-order-totals { margin-bottom: 14px; }
.psb-totals-row { display: flex; justify-content: space-between; font-size: .9rem; padding: 3px 0; color: #374151; }
.psb-total-final { font-size: 1.05rem; font-weight: 800; color: #1a1a2e; border-top: 1px solid #e2e8f0; padding-top: 8px; margin-top: 4px; }

.psb-btn-whatsapp {
  width: 100%;
  padding: 13px;
  background: #25d366;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: .95rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 8px;
  transition: background .15s;
}
.psb-btn-whatsapp:hover { background: #1ebe5d; }
.psb-btn-whatsapp:disabled { opacity: .6; cursor: not-allowed; }

.psb-btn-clear {
  width: 100%;
  background: none;
  border: 1.5px solid #e2e8f0;
  border-radius: 8px;
  padding: 9px;
  font-size: .85rem;
  color: #6b7280;
  cursor: pointer;
  transition: border-color .15s, color .15s;
}
.psb-btn-clear:hover { border-color: #e94560; color: #e94560; }

/* Toast de confirmación */
.psb-toast {
  position: fixed;
  bottom: 100px;
  right: 28px;
  background: #1a1a2e;
  color: #fff;
  padding: 12px 18px;
  border-radius: 8px;
  font-size: .875rem;
  font-weight: 600;
  z-index: 99999;
  box-shadow: 0 4px 16px rgba(0,0,0,.2);
  transform: translateY(12px);
  opacity: 0;
  transition: all .3s;
  pointer-events: none;
}
.psb-toast.show { transform: translateY(0); opacity: 1; }
.psb-toast.success { background: #2e7d32; }
.psb-toast.error   { background: #c62828; }

@media(max-width:480px){
  .psb-order-sidebar { max-width: 100%; }
  .psb-cart-fab { bottom: 20px; right: 16px; }
}

/* ============================================================
   SHOP — Botón Agregar al Pedido centrado + ocultar Quick View
   ============================================================ */

/* Ocultar Quick View de cualquier tema/plugin */
.quick-view,
.quick-view-button,
.button.quick-view,
a.quick-view,
[class*="quick-view"],
[class*="quickview"],
[class*="quick_view"],
.yith-wcqv-button,
.woosq-btn,
.xstore-quick-view,
.ti-quickview-btn {
  display: none !important;
}

/* Ocultar overlay / botón nativo "Agregar al carrito" de WooCommerce y temas
   que aparece sobre la imagen del producto al hacer hover */
ul.products li.product .add_to_cart_button,
ul.products li.product a.add_to_cart_button,
ul.products li.product button.add_to_cart_button,
ul.products li.product .woocommerce-loop-product__btn--cart,
ul.products li.product .wc-block-components-product-button,
ul.products li.product .wc-block-components-product-button__button,
ul.products li.product .wp-block-button__link,
.wc-block-grid__product .wc-block-components-product-button,
.wc-block-grid__product .wc-block-components-product-button__button,
.wc-block-grid__product .wp-block-button__link,
/* Overlay de imagen "Añadir al carrito" que generan muchos temas */
ul.products li.product figure .add_to_cart_button,
ul.products li.product figure .woocommerce-loop-product__btn--cart,
ul.products li.product .product-loop-action,
ul.products li.product .loop-action,
ul.products li.product .woo-loop-btn,
ul.products li.product .shop-loop-thumbnail__buttons,
ul.products li.product .product-button-group,
ul.products li.product .loop-add-to-cart,
ul.products li.product [class*="add-to-cart"],
ul.products li.product [class*="add_to_cart"],
ul.products li.product [class*="loop-btn"],
ul.products li.product [class*="loop_btn"],
ul.products li.product .product-item-actions,
ul.products li.product .aheto-woo-product-image__btn,
ul.products li.product .product_loop_add_to_cart {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

/* Botón Agregar al Pedido — centrado, ancho completo, bien visible */
ul.products li.product .psb-add-to-order,
.wc-block-grid__product .psb-add-to-order,
.products .psb-add-to-order,
li.product .psb-add-to-order {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 6px !important;
  width: 100% !important;
  margin: 10px 0 0 0 !important;
  padding: 9px 14px !important;
  background: #1a1a2e !important;
  color: #ffffff !important;
  border: none !important;
  border-radius: 6px !important;
  font-size: .88rem !important;
  font-weight: 700 !important;
  cursor: pointer !important;
  transition: background .18s !important;
  letter-spacing: .02em !important;
  line-height: 1.2 !important;
  box-sizing: border-box !important;
  white-space: nowrap !important;
}
ul.products li.product .psb-add-to-order svg,
.wc-block-grid__product .psb-add-to-order svg,
li.product .psb-add-to-order svg {
  flex-shrink: 0 !important;
  width: 14px !important;
  height: 14px !important;
}
ul.products li.product .psb-add-to-order:hover,
.wc-block-grid__product .psb-add-to-order:hover,
li.product .psb-add-to-order:hover {
  background: #0f3460 !important;
  color: #ffffff !important;
}

/* ============================================================
   QUICK VIEW
   ============================================================ */

.psb-qv-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10,10,25,.72);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 999998;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .22s cubic-bezier(.4,0,.2,1);
}
.psb-qv-overlay.open {
  opacity: 1;
  pointer-events: all;
}

.psb-qv-modal {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 24px 64px rgba(0,0,0,.22), 0 4px 16px rgba(0,0,0,.10);
  width: 100%;
  max-width: 860px;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  transform: translateY(18px) scale(.97);
  transition: transform .25s cubic-bezier(.4,0,.2,1);
}
.psb-qv-overlay.open .psb-qv-modal {
  transform: translateY(0) scale(1);
}

/* Botón cerrar */
.psb-qv-close {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 10;
  background: #f1f5f9;
  border: 1.5px solid #cbd5e1;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #374151;
  transition: background .15s, border-color .15s;
  padding: 0;
}
.psb-qv-close:hover { background: #e2e8f0; border-color: #94a3b8; }

/* Loader */
.psb-qv-loader {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 320px;
}
.psb-qv-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid #e2e8f0;
  border-top-color: #0f3460;
  border-radius: 50%;
  animation: psb-spin .7s linear infinite;
}
@keyframes psb-spin { to { transform: rotate(360deg); } }

/* Contenido — dos columnas */
.psb-qv-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
}

/* Galería */
.psb-qv-gallery {
  padding: 28px 20px 28px 28px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.psb-qv-main-img-wrap {
  background: #f8f9fc;
  border-radius: 10px;
  overflow: hidden;
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}
.psb-qv-main-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: opacity .2s;
}
.psb-qv-thumbs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.psb-qv-thumb {
  width: 58px;
  height: 58px;
  border-radius: 6px;
  border: 2px solid #e2e8f0;
  overflow: hidden;
  cursor: pointer;
  transition: border-color .15s;
  flex-shrink: 0;
  background: #f8f9fc;
}
.psb-qv-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.psb-qv-thumb:hover,
.psb-qv-thumb.active { border-color: #0f3460; }

/* Info */
.psb-qv-info {
  padding: 28px 28px 28px 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  border-left: 1px solid #f1f5f9;
}
.psb-qv-cats {
  font-size: .75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: #0f3460;
}
.psb-qv-name {
  font-size: 1.2rem !important;
  font-weight: 800 !important;
  color: #1a1a2e !important;
  line-height: 1.3 !important;
  margin: 0 !important;
}
.psb-qv-sku {
  font-size: .78rem;
  color: #94a3b8;
}
.psb-qv-price {
  font-size: 1.6rem;
  font-weight: 800;
  color: #0f3460;
  line-height: 1;
}
.psb-qv-desc {
  font-size: .88rem;
  color: #4b5563;
  line-height: 1.6;
  max-height: 120px;
  overflow-y: auto;
  border-top: 1px solid #f1f5f9;
  padding-top: 12px;
}
.psb-qv-desc:empty { display: none; }

/* Acciones */
.psb-qv-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-top: auto;
  flex-wrap: wrap;
}
.psb-qv-qty-wrap {
  display: flex;
  align-items: center;
  border: 1.5px solid #e2e8f0;
  border-radius: 8px;
  overflow: hidden;
  height: 46px;
}
.psb-qv-qty-btn {
  width: 40px;
  height: 100%;
  background: #f8f9fc;
  border: none;
  font-size: 1.1rem;
  font-weight: 700;
  color: #374151;
  cursor: pointer;
  transition: background .15s;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.psb-qv-qty-btn:hover { background: #e2e8f0; }
.psb-qv-qty-input {
  width: 44px !important;
  height: 100%;
  border: none !important;
  border-left: 1.5px solid #e2e8f0 !important;
  border-right: 1.5px solid #e2e8f0 !important;
  text-align: center !important;
  font-size: .95rem !important;
  font-weight: 700 !important;
  color: #1a1a2e !important;
  padding: 0 !important;
  -moz-appearance: textfield;
  box-shadow: none !important;
  outline: none !important;
}
.psb-qv-qty-input::-webkit-outer-spin-button,
.psb-qv-qty-input::-webkit-inner-spin-button { -webkit-appearance: none; }

.psb-qv-add-btn {
  flex: 1;
  min-width: 160px;
  height: 46px;
  background: #0f3460;
  color: #fff !important;
  border: none;
  border-radius: 8px;
  font-size: .9rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: background .18s;
}
.psb-qv-add-btn:hover { background: #1a1a2e; }
.psb-qv-add-btn.added {
  background: #25d366 !important;
}

/* Interceptar links de producto en el shop */
.psb-qv-trigger { cursor: pointer; }

/* Responsive */
@media (max-width: 640px) {
  .psb-qv-content { grid-template-columns: 1fr; }
  .psb-qv-gallery { padding: 20px 20px 0; }
  .psb-qv-info { padding: 16px 20px 20px; border-left: none; border-top: 1px solid #f1f5f9; }
  .psb-qv-modal { max-height: 95vh; border-radius: 12px; }
}

/* ============================================================
   PSB v1.1 — Precios ocultos / Botón login para comprar
   ============================================================ */

/* Contenedor del precio oculto — fila centrada con los dos botones */
.psb-price-hidden {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 6px !important;
  flex-wrap: nowrap !important;
  width: 100% !important;
  box-sizing: border-box !important;
}



/* Texto "Iniciá sesión para ver el precio" — oculto */
.psb-price-hidden-text {
  display: none;
}

/* Base compartida para botones de acción en el loop de productos
   — neutraliza los estilos del tema WooCommerce (.button, .alt) */
.psb-login-to-buy,
.psb-price-login-btn {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 5px !important;
  flex: 1 1 0 !important;
  min-width: 0 !important;
  max-width: 50% !important;
  width: auto !important;
  height: auto !important;
  min-height: unset !important;
  padding: 8px 10px !important;
  margin: 0 !important;
  border-radius: 6px !important;
  font-size: 0.82rem !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  white-space: nowrap !important;
  cursor: pointer !important;
  transition: background 0.18s, color 0.18s, border-color 0.18s !important;
  text-decoration: none !important;
  box-sizing: border-box !important;
  vertical-align: middle !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}
/* Asegurar que el SVG dentro del botón no crezca */
.psb-login-to-buy svg,
.psb-price-login-btn svg {
  flex-shrink: 0 !important;
  width: 13px !important;
  height: 13px !important;
  vertical-align: middle !important;
  margin: 0 !important;
}

/* Botón "Comprar" — relleno oscuro */
.psb-login-to-buy {
  background: #1a1a2e !important;
  color: #ffffff !important;
  border: 1.5px solid #1a1a2e !important;
}
.psb-login-to-buy:hover {
  background: #0f3460 !important;
  border-color: #0f3460 !important;
  color: #fff !important;
}

/* Botón "Ver precio" — outline */
.psb-price-login-btn {
  background: #ffffff !important;
  color: #0f3460 !important;
  border: 1.5px solid #0f3460 !important;
}
.psb-price-login-btn:hover {
  background: #0f3460 !important;
  color: #fff !important;
}

/* Estado "cuenta pendiente" en el loop */
.psb-btn-pending {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 100% !important;
  padding: 8px 12px !important;
  font-size: 0.82rem !important;
  line-height: 1.2 !important;
  opacity: 0.6;
  cursor: not-allowed;
}

/* Quick View — precio oculto */
.psb-qv-price-hidden {
  font-size: 0.85rem;
  color: #6b7280;
  font-style: italic;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.psb-qv-price-login-btn {
  background: #0f3460;
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 8px 20px;
  font-size: 0.88rem;
  font-weight: 700;
  cursor: pointer;
  width: 100%;
  transition: background 0.18s;
}
.psb-qv-price-login-btn:hover { background: #1a1a2e; }

/* Quick View — botón de login (reemplaza al de agregar al pedido) */
.psb-qv-add-btn.psb-qv-login-btn {
  background: #f0f4ff;
  color: #0f3460;
  border: 1.5px solid #0f3460;
}
.psb-qv-add-btn.psb-qv-login-btn:hover {
  background: #0f3460;
  color: #fff;
}

/* ============================================================
   QUICK VIEW — Acciones para usuarios no logueados (guest)
   Replica el estilo "Comprar / Ver precio" del catálogo
   ============================================================ */

.psb-qv-actions-guest {
  display: flex;
  gap: 10px;
  margin-top: 18px;
  flex-wrap: wrap;
}

/* Botón base compartido */
.psb-qv-guest-btn {
  flex: 1;
  min-width: 120px;
  padding: 11px 16px;
  border-radius: 6px;
  font-size: .9rem;
  font-weight: 700;
  cursor: pointer;
  transition: background .18s, color .18s, border-color .18s;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  letter-spacing: .02em;
}

/* "Comprar" — fondo oscuro, igual que el botón del catálogo */
.psb-qv-buy-btn {
  background: #1a1a2e;
  color: #ffffff;
  border: 2px solid #1a1a2e;
}
.psb-qv-buy-btn:hover {
  background: #0f3460;
  border-color: #0f3460;
  color: #fff;
}

/* "Ver precio" — outline, igual que el botón del catálogo */
.psb-qv-price-btn {
  background: #ffffff;
  color: #1a1a2e;
  border: 2px solid #1a1a2e;
}
.psb-qv-price-btn:hover {
  background: #1a1a2e;
  color: #ffffff;
}

/* Mensaje cuenta pendiente */
.psb-qv-pending-msg {
  display: block;
  margin-top: 18px;
  padding: 12px 16px;
  background: #fffbeb;
  border: 1.5px solid #f59e0b;
  border-radius: 6px;
  color: #92400e;
  font-size: .88rem;
  font-weight: 600;
  text-align: center;
}


/* ── Mobile: botones Comprar / Ver precio apilados y legibles ── */
@media screen and (max-width: 782px) {

  /* Contenedor: columna, ancho completo, dentro del card */
  ul.products li.product .psb-price-hidden,
  li.product .psb-price-hidden,
  .wc-block-grid__product .psb-price-hidden {
    flex-direction: column !important;
    flex-wrap: nowrap !important;
    gap: 5px !important;
    width: 100% !important;
    align-items: stretch !important;
  }

  /* Cada botón: ancho completo, texto visible */
  ul.products li.product .psb-login-to-buy,
  ul.products li.product .psb-price-login-btn,
  li.product .psb-login-to-buy,
  li.product .psb-price-login-btn,
  .wc-block-grid__product .psb-login-to-buy,
  .wc-block-grid__product .psb-price-login-btn {
    max-width: 100% !important;
    width: 100% !important;
    flex: 0 0 auto !important;
    white-space: normal !important;
    overflow: visible !important;
    text-overflow: unset !important;
    font-size: 0.82rem !important;
    padding: 8px 10px !important;
    text-align: center !important;
  }
}

/* ============================================================
   BRAND FILTER — Filtro por marca con AJAX en /shop/
   ============================================================ */

.psb-bf-wrap {
  --psb-bf-cols: 6;
  --psb-bf-gap: 12px;
  --psb-bf-radius: 12px;
  --psb-bf-border: #e2e8f0;
  --psb-bf-bg: #ffffff;
  --psb-bf-accent: #0f3460;
  --psb-bf-shadow: 0 2px 8px rgba(0,0,0,.06);
  --psb-bf-shadow-hover: 0 6px 20px rgba(15,52,96,.15);
  --psb-bf-trans: 0.28s cubic-bezier(.4,0,.2,1);
  margin: 0 0 32px 0;
  font-family: inherit;
}

.psb-bf-title {
  font-size: 1rem;
  font-weight: 700;
  color: #1a1a2e;
  margin: 0 0 14px 0;
  letter-spacing: .03em;
  text-transform: uppercase;
}

/* ── Grid ── */
.psb-bf-grid {
  display: grid;
  grid-template-columns: repeat(var(--psb-bf-cols), 1fr);
  gap: var(--psb-bf-gap);
}

/* ── Cada ítem ── */
.psb-bf-item {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px 12px;
  background: var(--psb-bf-bg);
  border: 1.5px solid var(--psb-bf-border);
  border-radius: var(--psb-bf-radius);
  text-decoration: none !important;
  cursor: pointer;
  transition:
    border-color var(--psb-bf-trans),
    box-shadow var(--psb-bf-trans),
    transform var(--psb-bf-trans);
  box-shadow: var(--psb-bf-shadow);
}

.psb-bf-item:hover {
  border-color: var(--psb-bf-accent);
  box-shadow: var(--psb-bf-shadow-hover);
  transform: translateY(-3px);
  text-decoration: none !important;
}

/* Activo: solo borde + sombra de color, fondo blanco */
.psb-bf-item.psb-bf-active {
  background: #ffffff;
  border-color: var(--psb-bf-accent);
  border-width: 2.5px;
  box-shadow: 0 0 0 3px rgba(15,52,96,.12), var(--psb-bf-shadow-hover);
  transform: translateY(-2px);
}

/* ── Imagen ── */
.psb-bf-logo {
  width: 100%;
  height: 54px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.psb-bf-logo img {
  max-width: 90%;
  max-height: 50px;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
  /* Base: gris */
  filter: grayscale(100%) opacity(50%);
  transform: scale(1);
  transition:
    filter var(--psb-bf-trans),
    transform var(--psb-bf-trans);
}

/* Hover: color + zoom */
.psb-bf-item:hover .psb-bf-logo img {
  filter: grayscale(0%) opacity(100%);
  transform: scale(1.08);
}

/* Activo: color completo, sin zoom */
.psb-bf-item.psb-bf-active .psb-bf-logo img {
  filter: grayscale(0%) opacity(100%);
  transform: scale(1);
}

/* Sin logo: texto */
.psb-bf-logo-text {
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: #94a3b8;
  text-align: center;
  transition: color var(--psb-bf-trans);
}
.psb-bf-item:hover .psb-bf-logo-text,
.psb-bf-item.psb-bf-active .psb-bf-logo-text {
  color: var(--psb-bf-accent);
}

/* ── Botón Restablecer ── */
.psb-bf-reset-wrap {
  display: flex;
  justify-content: flex-end;
  margin-top: 12px;
  min-height: 32px;
}

.psb-bf-reset {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: #f1f5f9;
  border: 1.5px solid #e2e8f0;
  border-radius: 999px;
  font-size: .75rem;
  font-weight: 600;
  color: #475569;
  text-decoration: none !important;
  transition:
    background var(--psb-bf-trans),
    border-color var(--psb-bf-trans),
    color var(--psb-bf-trans),
    opacity var(--psb-bf-trans),
    transform var(--psb-bf-trans);
}

.psb-bf-reset svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  transition: transform 0.4s cubic-bezier(.4,0,.2,1);
}

.psb-bf-reset:hover {
  background: var(--psb-bf-accent);
  border-color: var(--psb-bf-accent);
  color: #ffffff;
  text-decoration: none !important;
}

.psb-bf-reset:hover svg {
  transform: rotate(-180deg);
}

.psb-bf-reset--hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateY(4px);
}

/* ── Responsive ── */
@media (max-width: 960px) {
  .psb-bf-grid { grid-template-columns: repeat(4, 1fr); }
}
@media (max-width: 640px) {
  .psb-bf-grid { grid-template-columns: repeat(3, 1fr); }
  .psb-bf-logo { height: 42px; }
}
@media (max-width: 400px) {
  .psb-bf-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
}

/* ── Precio en catálogo (rojo destacado) ── */
.woocommerce ul.products li.product .price,
.woocommerce ul.products li.product .price .amount,
.woocommerce ul.products li.product .price bdi {
  font-size: 1.4rem !important;
  font-weight: 800 !important;
  color: #e51b20 !important;
}

/* ── Precio en Quick View (rojo destacado) ── */
.psb-qv-price,
.psb-qv-price .amount,
.psb-qv-price bdi {
  font-size: 1.4rem !important;
  font-weight: 800 !important;
  color: #e51b20 !important;
}
