/* ====== Layout general ====== */
.scrpc-product-page{max-width:1200px;margin:0 auto;padding:20px;position:relative;z-index:1}

/* ====== Filtros ====== */
.scrpc-filters{display:flex;flex-wrap:wrap;gap:20px;margin-bottom:20px;background:#f9f9f9;padding:15px;border-radius:12px;box-shadow:0 2px 4px rgba(0,0,0,.06);
text-align:center;align-items:center;align-content:center}
.scrpc-filters .form-field{flex:1;min-width:220px}
.scrpc-filters label{display:block;margin-bottom:6px;font-weight:600;color:#333}
.scrpc-filters select,.scrpc-filters input{width:100%;padding:8px;border:1px solid #ddd;border-radius:8px;font-size:14px;background:#fff}

/* ====== Grid de productos ====== */
.scrpc-product-list{display:grid;gap:16px;grid-template-columns:repeat(4,minmax(0,1fr))}
@media (max-width:1024px){.scrpc-product-list{grid-template-columns:repeat(3,1fr)}}
@media (max-width:768px){.scrpc-product-list{grid-template-columns:repeat(2,1fr)}}
@media (max-width:520px){.scrpc-product-list{grid-template-columns:1fr}}

/* ====== Card de producto ====== */
.scrpc-product-item{background:#fff;border:1px solid #eee;border-radius:14px;padding:12px;text-align:center;transition:box-shadow .2s,transform .12s}
.scrpc-product-item:hover{box-shadow:0 8px 20px rgba(0,0,0,.08);transform:translateY(-1px)}
.scrpc-product-item img{width:100%;height:190px;object-fit:contain;border:1px solid #eee;border-radius:12px;background:#fff;padding:6px}
.scrpc-product-item h3{font-size:15px;line-height:1.35;margin:8px 0 4px;color:#222;height:42px;overflow:hidden}
.scrpc-card-price,.scrpc-product-item .scrpc-price{font-weight:800;color:#ad0000;margin-bottom:8px}

/* ====== Barra de iconos ====== */
.scrpc-iconbar{display:flex;gap:10px;align-items:center;justify-content:center;flex-wrap:wrap}
.scrpc-icbtn{position:relative;display:inline-flex;align-items:center;justify-content:center;width:38px;height:38px;border:1px solid #ddd;background:#fff;border-radius:10px;cursor:pointer;color:#222;transition:transform .12s,box-shadow .12s,border-color .12s,color .12s;text-decoration:none}
.scrpc-icbtn .scrpc-ico{width:18px;height:18px}
.scrpc-icbtn:hover{box-shadow:0 2px 8px rgba(0,0,0,.1);transform:translateY(-1px);border-color:#ad0000;color:#ad0000}
.scrpc-icbtn[data-variant="primary"]{background:#ad0000;border-color:#ad0000;color:#fff}
.scrpc-icbtn .scrpc-tip{position:absolute;bottom:calc(100% + 8px);left:50%;transform:translateX(-50%);background:#222;color:#fff;font-size:12px;padding:6px 8px;border-radius:8px;white-space:nowrap;box-shadow:0 2px 8px rgba(0,0,0,.12);opacity:0;pointer-events:none;transition:opacity .12s}
.scrpc-icbtn:hover .scrpc-tip{opacity:1}

/* ====== Modales ====== */
.crud-modal{position:fixed;inset:0;background:rgba(0,0,0,.35);display:none;z-index:9990}
.crud-modal .modal-content{background:#fff;border-radius:14px;max-width:980px;margin:40px auto;display:grid;grid-template-rows:auto 1fr auto;max-height:88vh;overflow:hidden;box-shadow:0 10px 30px rgba(0,0,0,.15)}
.crud-modal .modal-header{display:flex;justify-content:space-between;align-items:center;border-bottom:1px solid #eee;padding:12px 16px}
.crud-modal .modal-header h2{margin:0;font-size:18px}
.crud-modal .modal-header .close{cursor:pointer;font-size:22px;line-height:1}
.crud-modal .modal-body{padding:12px 16px;overflow:auto}
.crud-modal .modal-footer{display:flex;gap:8px;justify-content:flex-end;border-top:1px solid #eee;padding:10px 16px;background:#fff}

/* ====== Modal de producto ====== */
.scrpc-modal-grid{display:grid;grid-template-columns:1.1fr .9fr;gap:18px;align-items:start}
@media (max-width:900px){.scrpc-modal-grid{grid-template-columns:1fr}}
.modal-tabs{display:flex;gap:8px;align-items:center;margin:10px 0}
.modal-tab{padding:8px 12px;border:1px solid #ddd;border-radius:999px;background:#fff;cursor:pointer;font-size:13px}
.modal-tab.active{background:#ad0000;border-color:#ad0000;color:#fff}
.modal-tab-content{display:none}
.modal-tab-content.active{display:block}
.quantity-input{width:90px;padding:6px;border:1px solid #ddd;border-radius:8px}

/* ====== Galería ====== */
.scrpc-gallery .scrpc-hero{position:relative;border:1px solid #eee;border-radius:14px;background:#fff;padding:10px;z-index:1}
.scrpc-gallery .scrpc-hero .scrpc-hero-inner{width:100%;height:auto;aspect-ratio:4/3;display:flex;align-items:center;justify-content:center}
.scrpc-gallery .scrpc-hero img{width:100%;height:100%;object-fit:contain;border-radius:8px}
.scrpc-gallery .nav{position:absolute;top:50%;transform:translateY(-50%);background:#fff;border:1px solid #ddd;border-radius:10px;padding:6px 10px;cursor:pointer;box-shadow:0 2px 6px rgba(0,0,0,.08);z-index:3}
.scrpc-gallery .nav.prev{left:8px}
.scrpc-gallery .nav.next{right:8px}
.scrpc-thumbs{position:relative;z-index:2;display:flex;gap:10px;overflow-x:auto;margin-top:10px;padding:2px 0 8px}
.scrpc-thumbs img{width:86px;height:86px;object-fit:contain;border:1px solid #eee;border-radius:10px;padding:4px;background:#fff;cursor:pointer;opacity:.85;transition:opacity .12s,border-color .12s}
.scrpc-thumbs img.active,.scrpc-thumbs img:hover{opacity:1;border-color:#ad0000}

/* ====== Lightbox ====== */
.scrpc-lightbox{position:fixed;inset:0;background:rgba(0,0,0,.85);display:none;align-items:center;justify-content:center;z-index:10000}
.scrpc-lightbox.open{display:flex}
.scrpc-lightbox img{max-width:92vw;max-height:82vh;object-fit:contain;border-radius:10px;background:#fff;padding:6px}
.scrpc-lightbox .lb-prev,.scrpc-lightbox .lb-next,.scrpc-lightbox .lb-close{position:absolute;background:#fff;border:1px solid #ddd;border-radius:10px;cursor:pointer;padding:8px 12px;box-shadow:0 2px 8px rgba(0,0,0,.2)}
.scrpc-lightbox .lb-prev{left:20px;top:50%;transform:translateY(-50%)}
.scrpc-lightbox .lb-next{right:20px;top:50%;transform:translateY(-50%)}
.scrpc-lightbox .lb-close{right:16px;top:14px}

/* ====== Single ====== */
.scrpc-single{max-width:1120px;margin:10px auto 30px}
.scrpc-grid{display:grid;grid-template-columns:520px 1fr;gap:28px;align-items:start}
@media (max-width:1080px){.scrpc-grid{grid-template-columns:1fr}}
.scrpc-btn{display:inline-flex;gap:8px;align-items:center;border:1px solid #ddd;background:#fff;border-radius:10px;padding:10px 14px;text-decoration:none;color:#222}
.scrpc-btn:hover{border-color:#ad0000;color:#ad0000}
.scrpc-btn svg{width:18px;height:18px}

/* ====== Relacionados ====== */
.scrpc-related-wrap{max-width:1120px;margin:30px auto 10px}
.scrpc-related-slider{overflow:hidden}
.scrpc-rel-track{display:flex;gap:14px;transition:transform .25s ease}
.scrpc-rel-card{min-width:220px;background:#fff;border:1px solid #eee;border-radius:12px;overflow:hidden}
.scrpc-rel-link{display:block;text-decoration:none;color:inherit;padding:10px}
.scrpc-rel-card img{width:100%;height:150px;object-fit:contain;background:#fff;border:1px solid #eee;border-radius:10px;padding:6px}
.scrpc-rel-title{font-size:14px;margin:8px 2px 4px;height:40px;overflow:hidden}
.scrpc-related-head .scrpc-rel-btn{border:1px solid #ddd;background:#fff;border-radius:10px;padding:6px 10px;cursor:pointer}
.scrpc-rel-card .scrpc-icbtn{width:auto;height:36px;padding:0 10px;margin:10px;border-radius:8px}

/* ====== Cotizador flotante + notificaciones ====== */
.scrpc-quote-button{position:fixed;right:16px;bottom:18px;background:#ad0000;color:#fff;border-radius:999px;padding:10px 16px;box-shadow:0 8px 20px rgba(0,0,0,.2);cursor:pointer;z-index:9991}
.scrpc-notification{position:fixed;left:50%;transform:translateX(-50%);bottom:24px;background:#1a1a1a;color:#fff;padding:10px 14px;border-radius:10px;z-index:99999;display:none}
.scrpc-notification.success{background:#1a7f37}
.scrpc-notification.error{background:#b00020}

/* ====== Lista del carrito (modal) ====== */
.scrpc-quote-list .scrpc-quote-item{display:flex;align-items:center;gap:14px;border:1px solid #eee;border-radius:10px;padding:10px;margin-bottom:10px}
.scrpc-quote-item .quote-item-image img{width:64px;height:64px;object-fit:contain;border:1px solid #eee;border-radius:8px;background:#fff;padding:4px}
.scrpc-quote-item .quote-item-details{flex:1}
.scrpc-quote-item .quote-row-1{display:flex;justify-content:space-between;align-items:center;margin-bottom:6px}
.scrpc-quote-item .quote-row-2{display:flex;gap:14px;align-items:center;flex-wrap:wrap}
.scrpc-quote-item .quote-item-description{font-weight:600}
.scrpc-quote-item .quote-item-quantity{width:70px;padding:5px;border:1px solid #ddd;border-radius:6px}

/* ====== Breadcrumbs ====== */
.scrpc-bc a{color:#ad0000;text-decoration:none}
.scrpc-bc a:hover{text-decoration:underline}

/* ====== Botón Carrito en MENÚ ====== */
.scrpc-menu-quote{display:inline-flex;align-items:center;gap:8px;color:#111;text-decoration:none;position:relative}
.scrpc-menu-quote-icon{width:22px;height:22px;display:inline-block;position:relative}
.scrpc-menu-quote-icon::before{
  content:"";position:absolute;inset:0;background:#111;
  -webkit-mask:url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" stroke="black" fill="none" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" viewBox="0 0 24 24"><circle cx="9" cy="21" r="1"/><circle cx="20" cy="21" r="1"/><path d="M1 1h4l2.68 13.39a2 2 0 0 0 2 1.61h9.72a2 2 0 0 0 2-1.61L23 6"/></svg>') no-repeat center / contain;
          mask:url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" stroke="black" fill="none" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" viewBox="0 0 24 24"><circle cx="9" cy="21" r="1"/><circle cx="20" cy="21" r="1"/><path d="M1 1h4l2.68 13.39a2 2 0 0 0 2 1.61h9.72a2 2 0 0 0 2-1.61L23 6"/></svg>') no-repeat center / contain;
}
.scrpc-menu-quote-total{font-weight:800}
.scrpc-menu-quote-badge{
  position:absolute;top:-6px;right:-10px;background:#ad0000;color:#fff;font-size:11px;
  line-height:1;border-radius:999px;padding:2px 6px;min-width:18px;text-align:center
}
