:root {
    --mp-primary: #5C2E26;
    --mp-primary-light: #D18282;
    --mp-accent: #9A4F3F;
    --mp-bg: #E3D4C6;
    --mp-dark: #12110F;
    --mp-white: #fff;
    --mp-gray: #999;
    --mp-radius: 12px;
}

/* ============================================================
   CATALOGO
   ============================================================ */
.mprod-catalogo { max-width: 1200px; margin: 0 auto; padding: 20px 0; }
.mprod-catalogo-header { margin-bottom: 24px; }
.mprod-cat-label { font-size: 12px; letter-spacing: 2px; text-transform: uppercase; color: var(--mp-gray); display: block; }
.mprod-cat-title { font-size: 28px; font-weight: 600; color: var(--mp-dark); margin: 4px 0 0; }

.mprod-filters { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.mprod-filters-label { font-weight: 600; font-size: 14px; color: var(--mp-dark); }
.mprod-filter-dropdown { position: relative; }
.mprod-filter-btn { display: inline-flex; align-items: center; gap: 6px; padding: 8px 16px; border-radius: 20px; border: 1px solid #ccc; background: var(--mp-white); font-size: 14px; cursor: pointer; color: var(--mp-dark); transition: .2s; }
.mprod-filter-btn.active { background: var(--mp-primary); color: var(--mp-white); border-color: var(--mp-primary); }
.mprod-filter-count { background: var(--mp-white); color: var(--mp-primary); border-radius: 50%; width: 20px; height: 20px; display: inline-flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 700; }
.mprod-filter-menu { display: none; position: absolute; top: 100%; left: 0; z-index: 100; background: var(--mp-white); border: 1px solid #ddd; border-radius: 8px; box-shadow: 0 4px 16px rgba(0,0,0,.1); min-width: 180px; margin-top: 4px; }
.mprod-filter-dropdown:hover .mprod-filter-menu { display: block; }
.mprod-filter-option { display: block; padding: 8px 16px; font-size: 14px; color: var(--mp-dark); text-decoration: none; }
.mprod-filter-option:hover { background: #f5f5f5; }
.mprod-filter-option.selected { font-weight: 600; color: var(--mp-primary); }

.mprod-active-filters { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 20px; font-size: 13px; color: var(--mp-gray); }
.mprod-clear-filters { color: var(--mp-dark); text-decoration: underline; font-size: 13px; }
.mprod-filter-tag { display: inline-flex; align-items: center; gap: 4px; padding: 4px 12px; background: #f0ebe5; border-radius: 16px; font-size: 13px; color: var(--mp-dark); text-decoration: none; }

/* ============================================================
   GRIGLIA 4 colonne
   ============================================================ */
.mprod-grid, .mprod-dash-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.mprod-empty { grid-column: 1/-1; text-align: center; color: var(--mp-gray); padding: 40px 0; }

/* ============================================================
   CARD PRODOTTO — Figma style
   ============================================================ */
.mprod-card { background: var(--mp-white); border-radius: var(--mp-radius); overflow: hidden; position: relative; transition: box-shadow .2s; display: flex; flex-direction: column; }
.mprod-card:hover { box-shadow: 0 4px 20px rgba(0,0,0,.08); }
.mprod-card-link { text-decoration: none; color: inherit; display: block; }
.mprod-card-link-text { text-decoration: none; color: inherit; }
.mprod-card-img { width: 100%; aspect-ratio: 1 / 1; background: center/cover no-repeat; background-color: #f0ebe5; position: relative; border-radius: var(--mp-radius) var(--mp-radius) 0 0; }
.mprod-card-noimg { background: linear-gradient(135deg, #f0ebe5 0%, #e3d4c6 100%); }
.mprod-card-noimg::after {
	content: 'Quarto Fuoco';
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	font-family: 'Inter', 'Helvetica Neue', sans-serif;
	font-weight: 700;
	font-size: clamp(14px, 2vw, 22px);
	letter-spacing: 2px;
	text-transform: uppercase;
	color: rgba(92, 46, 38, 0.35);
	text-align: center;
	pointer-events: none;
}
.mprod-badge-sale { position: absolute; top: 12px; left: 12px; background: #c0392b; color: var(--mp-white); font-size: 11px; font-weight: 700; padding: 4px 10px; border-radius: 4px; text-transform: uppercase; letter-spacing: .5px; }
.mprod-badge-draft { position: absolute; top: 12px; right: 12px; background: var(--mp-gray); color: var(--mp-white); font-size: 11px; font-weight: 700; padding: 4px 10px; border-radius: 4px; }

.mprod-card-body { padding: 14px 16px 14px; flex: 1; display: flex; flex-direction: column; }
.mprod-card-name { font-size: 15px; font-weight: 600; margin: 0 0 4px; color: var(--mp-dark); line-height: 1.3; }
.mprod-card-meta { font-size: 12px; color: var(--mp-gray); margin: 0 0 auto; line-height: 1.4; }
.mprod-card-negozio { font-weight: 600; color: var(--mp-accent); }
.mprod-card-bottom { display: flex; align-items: center; justify-content: space-between; margin-top: 12px; padding-top: 10px; border-top: 1px solid #f0ebe5; }
.mprod-card-price { display: flex; align-items: baseline; gap: 6px; }
.mprod-price-old { font-size: 12px; color: var(--mp-gray); text-decoration: line-through; }
.mprod-price { font-size: 16px; font-weight: 700; color: var(--mp-dark); }
.mprod-card-cart { display: inline-flex; align-items: center; gap: 5px; padding: 6px 12px; border-radius: 8px; border: 1px solid var(--mp-primary); background: var(--mp-white); color: var(--mp-primary); font-size: 12px; font-weight: 600; cursor: pointer; transition: .2s; white-space: nowrap; text-decoration: none; }
.mprod-card-cart:hover { background: var(--mp-primary); color: var(--mp-white); }

/* ============================================================
   PAGINAZIONE
   ============================================================ */
.mprod-pagination, .mprod-dash-pagination { display: flex; justify-content: center; gap: 6px; margin-top: 30px; }
.mprod-page-btn { width: 36px; height: 36px; border-radius: 50%; border: 1px solid #ddd; background: var(--mp-white); display: flex; align-items: center; justify-content: center; font-size: 14px; color: var(--mp-dark); text-decoration: none; cursor: pointer; }
.mprod-page-btn.active { background: var(--mp-primary); color: var(--mp-white); border-color: var(--mp-primary); }

/* ============================================================
   PAGINA SINGOLA — Figma 192-883
   ============================================================ */
.mprod-page {
    --qf-brand: var(--qf-bottega-color, #22286A);
    --qf-brand-soft: rgba(34,40,106,.08);
    --qf-text: #12110F;
    --qf-text-2: #494949;
    --qf-text-3: #616161;
    --qf-border: rgba(0,0,0,.08);
    max-width: 1440px; margin: 0 auto; padding: 24px 20px 80px;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    color: var(--qf-text);
    background: #fff;
}

/* Breadcrumb */
.mprod-breadcrumb { font-size: 14px; color: var(--qf-text-3); margin: 0 0 24px; display: flex; align-items: center; flex-wrap: wrap; gap: 6px; line-height: 1.4; }
.mprod-breadcrumb a { color: var(--qf-text-3); text-decoration: none; transition: color .15s; }
.mprod-breadcrumb a:hover { color: var(--qf-brand); }
.mprod-bc-sep { color: var(--qf-text-3); }
.mprod-bc-current { color: var(--qf-text); font-weight: 500; }

/* Seller bar */
.mprod-seller-bar { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 14px 20px; background: var(--qf-brand-soft); border-radius: 100px; margin-bottom: 28px; }
.mprod-seller-info { display: flex; align-items: center; gap: 12px; font-size: 16px; color: var(--qf-text-2); }
.mprod-seller-avatar { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; flex-shrink: 0; background: #fff; }
.mprod-seller-avatar--placeholder { background: linear-gradient(135deg, #e3d4c6, #c8b9a8); }
.mprod-seller-text strong { color: var(--qf-text); font-weight: 700; }
.mprod-btn-pill { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 12px 28px; border-radius: 100px; font-size: 15px; font-weight: 600; text-decoration: none; cursor: pointer; transition: all .2s; border: 1.5px solid var(--qf-brand); background: var(--qf-brand); color: #fff; line-height: 1; white-space: nowrap; }
.mprod-btn-pill:hover { background: #fff; color: var(--qf-brand); }
.mprod-btn-pill--outline { background: #fff; color: var(--qf-brand); }
.mprod-btn-pill--outline:hover { background: var(--qf-brand); color: #fff; }

/* 2-col layout */
.mprod-single-main { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 42px; align-items: start; }

/* Gallery */
.mprod-gallery { display: flex; flex-direction: column; gap: 14px; }
.mprod-gallery-big { position: relative; border-radius: 14px; overflow: hidden; background: #f0ebe5; aspect-ratio: 1 / 1.22; max-height: 882px; }
.mprod-gallery-big img { width: 100%; height: 100%; object-fit: cover; display: block; }
.mprod-gallery-arrow { position: absolute; top: 50%; transform: translateY(-50%); width: 44px; height: 44px; border-radius: 50%; border: none; background: rgba(255,255,255,.92); cursor: pointer; color: var(--qf-text); z-index: 2; display: flex; align-items: center; justify-content: center; box-shadow: 0 2px 8px rgba(0,0,0,.08); transition: background .2s; }
.mprod-gallery-arrow:hover { background: #fff; }
.mprod-arrow-prev { left: 16px; }
.mprod-arrow-next { right: 16px; }
.mprod-gallery-add-overlay { position: absolute; bottom: 16px; right: 16px; width: 44px; height: 44px; border-radius: 50%; background: rgba(0,0,0,.55); display: flex; align-items: center; justify-content: center; cursor: pointer; z-index: 3; transition: background .2s; }
.mprod-gallery-add-overlay:hover { background: rgba(0,0,0,.75); }
.mprod-gallery-thumbs { display: flex; gap: 10px; flex-wrap: wrap; }
.mprod-thumb-wrap { position: relative; width: 88px; height: 88px; border-radius: 10px; overflow: hidden; cursor: pointer; border: 2px solid transparent; opacity: .55; transition: opacity .2s, border-color .2s; flex-shrink: 0; }
.mprod-thumb-wrap.active { border-color: var(--qf-brand); opacity: 1; }
.mprod-thumb-wrap:hover { opacity: 1; }
.mprod-thumb { width: 100%; height: 100%; object-fit: cover; display: block; }
.mprod-thumb-remove { position: absolute; top: 3px; right: 3px; width: 20px; height: 20px; background: rgba(0,0,0,.65); color: #fff; border: none; border-radius: 50%; font-size: 12px; line-height: 1; cursor: pointer; display: flex; align-items: center; justify-content: center; opacity: 0; transition: .2s; padding: 0; }
.mprod-thumb-wrap:hover .mprod-thumb-remove { opacity: 1; }
.mprod-no-img { display: flex; align-items: center; justify-content: center; height: 100%; min-height: 400px; color: var(--qf-text-3); font-size: 15px; }

/* Details column */
.mprod-details { display: flex; flex-direction: column; gap: 18px; padding-top: 4px; }
.mprod-detail-cat { display: inline-block; padding: 6px 14px; border: 1px solid var(--qf-border); border-radius: 100px; font-size: 13px; font-weight: 500; color: var(--qf-text-2); text-transform: uppercase; letter-spacing: .6px; align-self: flex-start; margin: 0; }
.mprod-detail-name { font-family: 'Epilogue', 'Inter', sans-serif; font-size: 48px; font-weight: 700; line-height: 1.1; letter-spacing: -.02em; margin: 0; color: var(--qf-text); }

.mprod-detail-price { display: flex; align-items: baseline; gap: 14px; margin: 0; }
.mprod-price-big { font-family: 'Epilogue', 'Inter', sans-serif; font-size: 34px; font-weight: 700; color: var(--qf-brand); letter-spacing: -.01em; }
.mprod-detail-price .mprod-price-old { font-size: 20px; color: var(--qf-text-3); text-decoration: line-through; font-weight: 500; }

.mprod-detail-desc { font-size: 16px; line-height: 1.65; color: var(--qf-text-2); margin: 0; min-height: 24px; }
.mprod-empty-hint { color: var(--qf-text-3); font-style: italic; font-size: 14px; }

/* Detail card (Dettagli prodotto) */
.mprod-detail-card { background: #fff; border: 1px solid var(--qf-border); border-radius: 14px; padding: 22px 24px; margin: 4px 0 0; }
.mprod-detail-card h3 { font-family: 'Epilogue', 'Inter', sans-serif; font-size: 20px; font-weight: 700; margin: 0 0 14px; color: var(--qf-text); letter-spacing: -.01em; }
.mprod-detail-card ul { list-style: none; padding: 0; margin: 0; }
.mprod-detail-card li { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 10px 0; border-bottom: 1px solid var(--qf-border); font-size: 15px; color: var(--qf-text-2); }
.mprod-detail-card li:last-child { border-bottom: none; padding-bottom: 0; }
.mprod-detail-card li:first-child { padding-top: 0; }
.mprod-detail-card li span { color: var(--qf-text-3); }
.mprod-detail-card li strong { color: var(--qf-text); font-weight: 600; text-align: right; max-width: 60%; }
.mprod-attr-link { color: var(--qf-brand); font-weight: 600; text-decoration: none; border-bottom: 1px solid transparent; transition: border-color .15s, opacity .15s; }
.mprod-attr-link:hover { border-bottom-color: var(--qf-brand); opacity: .8; }

/* Inline-edit dei valori card (owner) */
.mprod-detail-attr-val.mprod-editable { outline: none; cursor: text; border-bottom: 1px dashed transparent; padding: 2px 4px; margin: -2px -4px; border-radius: 4px; transition: border-color .2s, background .2s; }
.mprod-detail-attr-val.mprod-editable:hover { border-bottom-color: var(--qf-brand); background: var(--qf-brand-soft); }
.mprod-detail-attr-val.mprod-editable:focus { border-bottom-color: var(--qf-brand); background: #fff; box-shadow: 0 0 0 2px var(--qf-brand-soft); }
.mprod-detail-attr-val.mprod-placeholder { color: var(--qf-text-3); font-weight: 400; font-style: italic; }
.mprod-card-hint { font-size: 13px; color: var(--qf-text-3); margin: 12px 0 0; padding-top: 12px; border-top: 1px dashed var(--qf-border); }
.mprod-card-hint em { font-style: normal; font-weight: 600; color: var(--qf-text-2); }

/* Collezione card */
.mprod-detail-collezione { display: flex; align-items: center; gap: 14px; padding: 16px 20px; background: var(--qf-brand-soft); border-radius: 12px; margin: 0; font-size: 15px; }
.mprod-coll-label { color: var(--qf-text-3); }
.mprod-detail-collezione strong { color: var(--qf-brand); font-weight: 700; }

/* Variant selectors */
.mprod-variant-selectors { display: flex; flex-direction: column; gap: 12px; margin: 0; }
.mprod-variant-group label { display: block; font-size: 14px; font-weight: 600; color: var(--qf-text); margin-bottom: 6px; }
.mprod-variant-select { border: 1px solid #ddd; width: 100%; padding: 12px 16px; border-radius: 10px; font-size: 15px; background: #fff; color: var(--qf-text); cursor: pointer; transition: border-color .2s; }
.mprod-variant-select:focus { outline: none; border-color: var(--qf-brand); }

/* Disponibilità */
.mprod-detail-avail { display: flex; align-items: center; gap: 12px; margin: 0; font-size: 15px; }
.mprod-avail-label { font-weight: 600; color: var(--qf-text); }
.mprod-avail-status { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 100px; font-size: 14px; font-weight: 500; }
.mprod-avail-status.available { color: #1b7a3e; background: rgba(39,174,96,.1); }
.mprod-avail-status.unavailable { color: #b53a2b; background: rgba(192,57,43,.08); }
.mprod-avail-dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; }

/* CTA — quantity + add to cart */
.mprod-detail-cart { display: flex; align-items: stretch; gap: 14px; margin: 6px 0 0; }
.mprod-qty-wrap { display: flex; align-items: center; border: 1.5px solid var(--qf-border); border-radius: 100px; overflow: hidden; background: #fff; }
.mprod-qty-btn { width: 44px; height: 52px; border: none; background: transparent; font-size: 20px; font-weight: 500; cursor: pointer; color: var(--qf-text); transition: background .15s; }
.mprod-qty-btn:hover { background: var(--qf-brand-soft); }
.mprod-qty-input { width: 48px; height: 52px; text-align: center; border: none; font-size: 16px; font-weight: 600; color: var(--qf-text); background: transparent; -moz-appearance: textfield; }
.mprod-qty-input::-webkit-outer-spin-button, .mprod-qty-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
/* .mprod-add-cart è usata solo come hook JS — gli stili vengono dalla classe .qf-product-info__add (prodotto.css) */
.mprod-add-cart:disabled { opacity: .5; cursor: not-allowed; }

/* Info block (spedizione + garanzia) */
.mprod-info-block { display: flex; flex-direction: column; gap: 10px; margin: 8px 0 0; padding: 16px 0 0; border-top: 1px solid var(--qf-border); }
.mprod-info-line { display: flex; align-items: center; gap: 12px; font-size: 14px; color: var(--qf-text-2); margin: 0; }
.mprod-info-line svg { color: var(--qf-brand); flex-shrink: 0; }

/* ============================================================
   PANNELLO OWNER — compatto
   ============================================================ */
/* ============================================================
   PANNELLO OWNER — tutti i controlli stessa grafica
   Variabili locali per ribadire la palette anche se la card sopra
   non monta (es. prodotto vuoto)
   ============================================================ */
/* Empty state pagina prodotto (404) */
.qf-product--empty { padding: 80px 24px 120px; max-width: 1440px; margin: 0 auto; font-family: 'Inter', system-ui, -apple-system, sans-serif; }
.qf-product-empty__inner { max-width: 540px; margin: 0 auto; text-align: center; }
.qf-product-empty__icon { display: inline-flex; align-items: center; justify-content: center; width: 96px; height: 96px; border-radius: 50%; background: rgba(34,40,106,0.08); color: var(--qf-bottega-color, #22286A); margin-bottom: 24px; }
.qf-product-empty__title { font-family: 'Epilogue', 'Inter', sans-serif; font-size: 32px; font-weight: 700; line-height: 1.2; letter-spacing: -.01em; color: #12110F; margin: 0 0 12px; }
.qf-product-empty__text { font-size: 16px; line-height: 1.55; color: #494949; margin: 0 0 28px; }
.qf-product-empty__btn { display: inline-flex; align-items: center; gap: 10px; padding: 14px 28px; border-radius: 100px; background: var(--qf-bottega-color, #22286A); color: #fff; font-size: 15px; font-weight: 600; text-decoration: none; border: 1.5px solid var(--qf-bottega-color, #22286A); transition: all .2s; }
.qf-product-empty__btn:hover { background: #fff; color: var(--qf-bottega-color, #22286A); }
@media (max-width: 804px) {
    .qf-product--empty { padding: 60px 20px 80px; }
    .qf-product-empty__title { font-size: 26px; }
    .qf-product-empty__icon { width: 80px; height: 80px; }
}

/* Quando il pannello è dentro .qf-product-body__inner (grid 2-col), span full width */
.qf-product .qf-product-body__inner > .mprod-owner-panel {
    grid-column: 1 / -1 !important;
    width: 100% !important;
    max-width: 100% !important;
}
.mprod-owner-panel {
    --qf-brand: var(--qf-bottega-color, #22286A);
    --qf-brand-soft: rgba(34,40,106,.08);
    --qf-text: #12110F;
    --qf-text-2: #494949;
    --qf-text-3: #616161;
    --qf-border: rgba(0,0,0,.12);
    --qf-input-h: 44px;
    margin-top: 36px;
    border: 1px solid var(--qf-border);
    border-radius: 14px;
    overflow: hidden;
    background: #fff;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
}
.mprod-panel-toggle { display: flex; align-items: center; gap: 10px; padding: 16px 22px; background: var(--qf-brand-soft); cursor: pointer; font-weight: 600; font-size: 15px; color: var(--qf-brand); user-select: none; transition: background .2s; }
.mprod-panel-toggle:hover { background: rgba(34,40,106,.14); }
.mprod-panel-toggle.open { border-bottom: 1px solid var(--qf-border); }
.mprod-panel-body { padding: 24px; }

/* Row uniforme */
.mprod-panel-row { margin-bottom: 16px; }
.mprod-panel-row > label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 6px; color: var(--qf-text); }

/* TUTTI i form control del pannello = stessa grafica */
.mprod-owner-panel input[type="text"],
.mprod-owner-panel input[type="number"],
.mprod-owner-panel input[type="email"],
.mprod-owner-panel input[type="date"],
.mprod-owner-panel input[type="datetime-local"],
.mprod-owner-panel input[type="time"],
.mprod-owner-panel input[type="url"],
.mprod-owner-panel input[type="search"],
.mprod-owner-panel input[type="tel"],
.mprod-owner-panel select,
.mprod-owner-panel textarea {
    width: 100%;
    height: var(--qf-input-h);
    padding: 0 14px;
    border: 1px solid var(--qf-border);
    border-radius: 10px;
    font-size: 15px;
    font-family: inherit;
    color: var(--qf-text);
    background: #fff;
    box-sizing: border-box;
    transition: border-color .15s, box-shadow .15s;
    line-height: calc(var(--qf-input-h) - 2px);
    appearance: none;
    -webkit-appearance: none;
}
.mprod-owner-panel select { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23494949' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 38px; cursor: pointer; }
.mprod-owner-panel textarea { height: auto; min-height: 110px; padding: 12px 14px; line-height: 1.55; resize: vertical; }
.mprod-owner-panel input:focus,
.mprod-owner-panel select:focus,
.mprod-owner-panel textarea:focus { outline: none; border-color: var(--qf-brand); box-shadow: 0 0 0 3px var(--qf-brand-soft); }
.mprod-owner-panel input::placeholder,
.mprod-owner-panel textarea::placeholder { color: var(--qf-text-3); }

/* Sale dates: layout 2 colonne, controlli sempre uniformi */
.mprod-sale-dates { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 10px; }
.mprod-sale-dates label { font-size: 13px; color: var(--qf-text-3); display: block; margin-bottom: 4px; font-weight: 500; }

/* Autocomplete categoria */
.mprod-cat-autocomplete { position: relative; }
.mprod-cat-dropdown { display: none; position: absolute; top: calc(100% + 4px); left: 0; right: 0; z-index: 100; background: #fff; border: 1px solid var(--qf-border); border-radius: 10px; box-shadow: 0 6px 20px rgba(0,0,0,.08); max-height: 220px; overflow-y: auto; }
.mprod-cat-dropdown.open { display: block; }
.mprod-cat-option { padding: 10px 14px; cursor: pointer; font-size: 14px; color: var(--qf-text); }
.mprod-cat-option:hover { background: var(--qf-brand-soft); }
.mprod-cat-option.create { color: var(--qf-brand); font-weight: 600; }

/* Caratteristiche prodotto: griglia 3 col, stessa altezza dei singoli */
.mprod-simple-attrs { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; margin-top: 8px; }
.mprod-simple-attr label { display: block; font-size: 13px; color: var(--qf-text-3); margin-bottom: 4px; font-weight: 500; }

/* Attributi varianti builder */
.mprod-attr-builder { display: flex; flex-direction: column; gap: 12px; padding: 16px; background: var(--qf-brand-soft); border-radius: 10px; margin-bottom: 16px; }
.mprod-attr-group label { font-size: 13px; font-weight: 600; display: block; margin-bottom: 4px; color: var(--qf-text); }
.mprod-attr-group small { font-weight: 400; color: var(--qf-text-3); }
.mprod-btn-small { height: 40px; padding: 0 18px; background: var(--qf-brand); color: #fff; border: 1.5px solid var(--qf-brand); border-radius: 100px; font-size: 14px; cursor: pointer; font-weight: 600; align-self: flex-start; transition: all .2s; }
.mprod-btn-small:hover { background: #fff; color: var(--qf-brand); }

/* Varianti table — più compatta perché è una griglia, ma stessa palette */
.mprod-variants-table { overflow-x: auto; margin-top: 10px; }
.mprod-variants-table table { width: 100%; border-collapse: collapse; font-size: 13px; }
.mprod-variants-table th { text-align: left; padding: 10px 8px; border-bottom: 1px solid var(--qf-border); font-size: 12px; color: var(--qf-text-3); font-weight: 600; white-space: nowrap; }
.mprod-variants-table td { padding: 6px 4px; border-bottom: 1px solid var(--qf-border); }
.mprod-variants-table input,
.mprod-variants-table select { height: 36px !important; padding: 0 8px !important; border: 1px solid var(--qf-border) !important; border-radius: 6px !important; font-size: 13px !important; min-width: 70px; }
.mprod-variants-table input:focus,
.mprod-variants-table select:focus { box-shadow: 0 0 0 2px var(--qf-brand-soft) !important; }
.mprod-variant-remove { background: none; border: none; color: #b53a2b; font-size: 18px; cursor: pointer; padding: 4px 8px; line-height: 1; }
.mprod-variant-remove:hover { color: #8e2a1f; }

/* Pulsanti azione */
.mprod-panel-actions { display: flex; gap: 12px; margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--qf-border); }
button.mprod-btn-save { height: 48px !important; padding: 0 32px !important; background: var(--qf-brand) !important; color: #fff !important; border: 1.5px solid var(--qf-brand) !important; border-radius: 100px !important; font-size: 15px !important; font-weight: 600 !important; cursor: pointer; transition: all .2s; font-family: inherit !important; text-transform: none !important; letter-spacing: 0 !important; box-shadow: none !important; }
button.mprod-btn-save:hover, button.mprod-btn-save:focus { background: #fff !important; color: var(--qf-brand) !important; outline: none !important; }
button.mprod-btn-delete { height: 48px !important; padding: 0 28px !important; background: transparent !important; color: #b53a2b !important; border: 1.5px solid #b53a2b !important; border-radius: 100px !important; font-size: 15px !important; font-weight: 600 !important; cursor: pointer; transition: all .2s; font-family: inherit !important; text-transform: none !important; letter-spacing: 0 !important; box-shadow: none !important; }
button.mprod-btn-delete:hover, button.mprod-btn-delete:focus { background: #b53a2b !important; color: #fff !important; outline: none !important; }

/* Responsive panel */
@media (max-width: 600px) {
    .mprod-simple-attrs { grid-template-columns: 1fr; }
    .mprod-sale-dates { grid-template-columns: 1fr; }
    .mprod-panel-actions { flex-direction: column; }
    .mprod-panel-actions button { width: 100%; }
}

/* Dashboard */
.mprod-dash-container { padding: 0; }
.mprod-dash-header { display: flex; justify-content: flex-end; margin-bottom: 16px; }
.mprod-btn-new { padding: 10px 20px; background: var(--mp-primary); color: var(--mp-white); border: none; border-radius: 8px; font-size: 14px; font-weight: 600; cursor: pointer; }

/* Toast */
.mprod-toast { position: fixed; bottom: 30px; left: 50%; transform: translateX(-50%) translateY(20px); background: var(--mp-dark); color: var(--mp-white); padding: 12px 28px; border-radius: 8px; font-size: 14px; font-weight: 600; z-index: 9999; opacity: 0; transition: .3s; pointer-events: none; }
.mprod-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ============================================================
   OWNER MODE — breadcrumb compatto su tutti i viewport
   ============================================================ */
.mprod-page[data-owner="1"] .mprod-breadcrumb { padding: 10px 0 20px; gap: 0; font-size: 16px; font-weight: 600; flex-wrap: nowrap; }
.mprod-page[data-owner="1"] .mprod-breadcrumb a { color: var(--qf-brand); display: none; }
.mprod-page[data-owner="1"] .mprod-breadcrumb a:nth-of-type(3) { display: inline-flex; align-items: center; gap: 8px; }
.mprod-page[data-owner="1"] .mprod-breadcrumb a:nth-of-type(3)::before {
    content: '';
    width: 16px; height: 16px; flex-shrink: 0;
    background: currentColor;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='15 18 9 12 15 6'/%3E%3C/svg%3E") center/contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='15 18 9 12 15 6'/%3E%3C/svg%3E") center/contain no-repeat;
}
.mprod-page[data-owner="1"] .mprod-breadcrumb .mprod-bc-sep,
.mprod-page[data-owner="1"] .mprod-breadcrumb .mprod-bc-current { display: none; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 992px) {
    .mprod-grid, .mprod-dash-grid { grid-template-columns: repeat(3, 1fr); }
    .mprod-single-main { grid-template-columns: 1fr; gap: 30px; }
    .mprod-page { padding: 10px 0 0; }
    .mprod-page > .mprod-breadcrumb,
    .mprod-page > .mprod-seller-bar,
    .mprod-page > .mprod-owner-panel { margin-left: 20px; margin-right: 20px; }

    /* Breadcrumb mobile (Torna indietro): mostro solo l'ultimo link <a>, prepend arrow */
    .mprod-breadcrumb { padding: 10px 0 20px; gap: 0; font-size: 16px; font-weight: 600; flex-wrap: nowrap; }
    .mprod-breadcrumb a { color: var(--qf-brand); display: none; }
    .mprod-breadcrumb a:nth-of-type(3) { display: inline-flex; align-items: center; gap: 8px; }
    .mprod-breadcrumb a:nth-of-type(3)::before {
        content: '';
        width: 16px; height: 16px; flex-shrink: 0;
        background: currentColor;
        -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='15 18 9 12 15 6'/%3E%3C/svg%3E") center/contain no-repeat;
        mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='15 18 9 12 15 6'/%3E%3C/svg%3E") center/contain no-repeat;
    }
    .mprod-breadcrumb .mprod-bc-sep,
    .mprod-breadcrumb .mprod-bc-current { display: none; }

    /* Seller bar */
    .mprod-seller-bar { padding: 15px 10px; border-radius: 20px; background: rgba(34,40,106,0.07); margin-bottom: 24px; }
    .mprod-seller-info { gap: 15px; }
    .mprod-seller-avatar { width: 36px; height: 36px; background: var(--qf-brand); }
    .mprod-seller-avatar--placeholder { background: var(--qf-brand); }
    .mprod-seller-text { display: flex; flex-direction: column; gap: 4px; font-size: 14px; line-height: 1.4; color: var(--qf-text); }
    .mprod-seller-text strong { font-size: 16px; text-transform: uppercase; letter-spacing: 0.6px; color: var(--qf-text); }
    .mprod-btn-pill {
        padding: 8px 12px; font-size: 16px; font-weight: 600;
        background: transparent; border: 0; color: var(--qf-text);
    }
    .mprod-btn-pill:hover { background: transparent; color: var(--qf-brand); }

    /* Gallery: edge-to-edge container, immagine square radius 20 */
    .mprod-gallery { padding: 0 20px; gap: 12px; }
    .mprod-gallery-big { aspect-ratio: 1 / 1; max-height: none; border-radius: 20px; }
    .mprod-gallery-thumbs { gap: 8px; padding-top: 4px; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
    .mprod-gallery-thumbs::-webkit-scrollbar { display: none; }
    .mprod-thumb-wrap { width: 64px; height: 64px; border-radius: 10px; border-width: 2px; border-color: #E3D4C6; opacity: 1; flex-shrink: 0; }
    .mprod-thumb-wrap.active { border-color: var(--qf-brand); }

    /* Details column */
    .mprod-details { padding: 0 20px; gap: 24px; }
    .mprod-detail-cat { padding: 4px 10px; height: auto; border-radius: 10px; border-color: var(--qf-brand); color: var(--qf-brand); font-size: 16px; font-weight: 500; text-transform: none; letter-spacing: 0.12px; }
    .mprod-detail-name { font-size: 28px; line-height: 1.3; letter-spacing: 0; color: var(--qf-brand); }
    .mprod-detail-price { gap: 10px; }
    .mprod-price-big { font-size: 28px; color: var(--qf-text); }
    .mprod-detail-price .mprod-price-old { font-size: 18px; }
    .mprod-detail-desc { font-size: 18px; line-height: 1.55; color: var(--qf-text); }

    /* Detail card mobile: layout paragrafo "Label: valore" */
    .mprod-detail-card { padding: 0; border: 0; background: transparent; border-radius: 0; }
    .mprod-detail-card h3 { font-family: 'Inter', sans-serif; font-size: 18px; font-weight: 700; color: var(--qf-brand); margin-bottom: 12px; letter-spacing: 0.12px; }
    .mprod-detail-card ul { display: block; }
    .mprod-detail-card li { display: list-item; padding: 4px 0; border: 0; font-size: 16px; line-height: 1.55; color: var(--qf-text); list-style: none; }
    .mprod-detail-card li span { display: inline; color: var(--qf-text); font-weight: 600; }
    .mprod-detail-card li span::after { content: ': '; }
    .mprod-detail-card li strong { display: inline; max-width: 100%; text-align: left; font-weight: 400; color: var(--qf-text); }

    /* Collezione card */
    .mprod-detail-collezione { padding: 12px 16px; border-radius: 10px; background: rgba(34,40,106,0.05); border: 1px solid rgba(34,40,106,0.1); gap: 14px; }

    /* Disponibilità: pill verde stile Figma */
    .mprod-detail-avail { gap: 16px; font-size: 18px; }
    .mprod-avail-label { color: var(--qf-brand); font-weight: 700; }
    .mprod-avail-status { padding: 4px 10px; border-radius: 4px; font-size: 18px; font-weight: 700; gap: 8px; }
    .mprod-avail-status.available { color: #33793B; background: rgba(51,121,59,0.05); border: 1px solid #33793B; }
    .mprod-avail-status.unavailable { color: #b53a2b; background: rgba(180,58,43,0.05); border: 1px solid #b53a2b; }

    /* CTA: riga "Quantità: stepper" + add-to-cart full-width sotto */
    .mprod-detail-cart {
        display: grid;
        grid-template-columns: 1fr auto;
        gap: 14px;
        align-items: center;
    }
    .mprod-detail-cart::before {
        content: 'Quantità:';
        grid-column: 1; grid-row: 1;
        font-weight: 700; font-size: 18px; color: var(--qf-brand);
        align-self: center;
    }
    .mprod-qty-wrap { grid-column: 2; grid-row: 1; padding: 8px 14px; border: 2px solid rgba(34,40,106,0.2); }
    .mprod-qty-btn { width: 32px; height: 40px; font-size: 22px; color: var(--qf-brand); }
    .mprod-qty-input { width: 28px; height: 40px; color: var(--qf-brand); font-weight: 700; }
    .mprod-add-cart {
        grid-column: 1 / -1; grid-row: 2;
        width: 100%; padding: 16px 24px; height: auto;
        gap: 10px; border-radius: 100px; font-size: 16px; font-weight: 500;
    }

    /* Info block */
    .mprod-info-block { padding-top: 24px; border-top: 1px solid #E3D4C6; gap: 12px; }
    .mprod-info-line { font-size: 14px; color: var(--qf-brand); gap: 12px; }
    .mprod-info-line svg { width: 24px; height: 24px; }
}

@media (max-width: 804px) {
    .mprod-grid, .mprod-dash-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 480px) {
    .mprod-grid, .mprod-dash-grid { grid-template-columns: 1fr; }
}

/* ============================================================
   CARRELLO
   ============================================================ */
.mprod-cart { max-width: 900px; margin: 0 auto; padding: 20px 0; }
.mprod-cart-title { font-size: 24px; font-weight: 600; color: var(--mp-dark); margin: 0 0 24px; }
.mprod-cart-login { text-align: center; padding: 60px 20px; }
.mprod-cart-empty { text-align: center; padding: 60px 20px; color: var(--mp-gray); }
.mprod-btn-primary { display: inline-block; padding: 12px 28px; background: var(--mp-primary); color: var(--mp-white); border: none; border-radius: 8px; font-size: 14px; font-weight: 600; cursor: pointer; text-decoration: none; transition: .2s; }
.mprod-btn-primary:hover { background: var(--mp-accent); }

/* Gruppo per negozio */
.mprod-cart-group { background: var(--mp-white); border-radius: var(--mp-radius); border: 1px solid #eee; margin-bottom: 24px; overflow: hidden; }
.mprod-cart-group-header { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; background: #faf8f5; border-bottom: 1px solid #eee; }
.mprod-cart-negozio-info { display: flex; align-items: center; gap: 8px; font-size: 15px; color: var(--mp-dark); }
.mprod-cart-negozio-info svg { color: var(--mp-primary); }
.mprod-cart-visit { font-size: 13px; color: var(--mp-primary); text-decoration: none; font-weight: 600; }

/* Item carrello */
.mprod-cart-items { padding: 0 20px; }
.mprod-cart-item { display: flex; align-items: center; gap: 16px; padding: 16px 0; border-bottom: 1px solid #f5f5f5; }
.mprod-cart-item:last-child { border-bottom: none; }
.mprod-cart-item-img { width: 72px; height: 72px; border-radius: 8px; background: center/cover no-repeat; background-color: #f0ebe5; flex-shrink: 0; display: block; }
.mprod-cart-item-info { flex: 1; min-width: 0; }
.mprod-cart-item-name { display: block; font-size: 14px; font-weight: 600; color: var(--mp-dark); text-decoration: none; margin-bottom: 2px; }
.mprod-cart-item-name:hover { color: var(--mp-primary); }
.mprod-cart-item-variant { display: block; font-size: 12px; color: var(--mp-gray); margin-bottom: 2px; }
.mprod-cart-item-unit { font-size: 12px; color: var(--mp-gray); }

.mprod-cart-item-qty { display: flex; align-items: center; border: 1px solid #ddd; border-radius: 6px; overflow: hidden; }
.mprod-cart-qty-btn { width: 30px; height: 32px; border: none; background: transparent; font-size: 16px; cursor: pointer; color: var(--mp-dark); }
.mprod-cart-qty-input { width: 36px; text-align: center; border: none; font-size: 13px; -moz-appearance: textfield; }
.mprod-cart-qty-input::-webkit-outer-spin-button, .mprod-cart-qty-input::-webkit-inner-spin-button { -webkit-appearance: none; }

.mprod-cart-item-total { font-size: 15px; font-weight: 700; color: var(--mp-dark); min-width: 80px; text-align: right; }

.mprod-cart-item-remove { background: none; border: none; cursor: pointer; color: var(--mp-gray); padding: 4px; transition: .2s; }
.mprod-cart-item-remove:hover { color: #c0392b; }

/* Footer gruppo */
.mprod-cart-group-footer { padding: 16px 20px; background: #faf8f5; border-top: 1px solid #eee; }
.mprod-cart-subtotal { display: flex; justify-content: space-between; align-items: center; font-size: 16px; margin-bottom: 12px; }
.mprod-cart-subtotal-val { font-size: 20px; color: var(--mp-dark); }
.mprod-checkout-toggle { text-align: right; }

/* Form checkout */
.mprod-checkout-form { margin-top: 16px; padding-top: 16px; border-top: 1px solid #e0d8ce; }
.mprod-checkout-form h3 { font-size: 16px; font-weight: 600; color: var(--mp-dark); margin: 0 0 16px; }
.mprod-checkout-fields { display: flex; flex-direction: column; gap: 12px; }
.mprod-checkout-row { display: flex; gap: 12px; }
.mprod-checkout-row > * { flex: 1; }
.mprod-checkout-field label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 4px; color: var(--mp-dark); }
.mprod-checkout-field input, .mprod-checkout-field textarea { width: 100%; padding: 10px 12px; border: 1px solid #ccc; border-radius: 8px; font-size: 14px; box-sizing: border-box; }
.mprod-checkout-field textarea { resize: vertical; }
.mprod-checkout-summary { margin-top: 16px; padding-top: 16px; border-top: 1px solid #e0d8ce; display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.mprod-checkout-total { font-size: 18px; flex: 1; }
.mprod-checkout-total strong { font-size: 22px; color: var(--mp-dark); }
.mprod-checkout-note { width: 100%; font-size: 12px; color: var(--mp-gray); margin-top: 8px; font-style: italic; }

@media (max-width: 804px) {
    .mprod-cart-item { flex-wrap: wrap; }
    .mprod-cart-item-info { width: calc(100% - 88px); }
    .mprod-cart-item-qty { margin-left: 88px; }
    .mprod-checkout-row { flex-direction: column; }
    .mprod-checkout-summary { flex-direction: column; align-items: flex-start; }
}

/* ============================================================
   PAGAMENTI — STEP 2
   ============================================================ */

.mprod-to-payment-btn { margin-top: 16px; }

.mprod-pay-options {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
}
.mprod-pay-option {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 16px;
    border: 2px solid #ddd;
    border-radius: 8px;
    background: #fff;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    color: var(--mp-text);
    transition: border-color .2s, background .2s;
}
.mprod-pay-option:hover { border-color: #bbb; }
.mprod-pay-option.active {
    border-color: var(--mp-primary);
    background: #fdf8f7;
}
.mprod-pay-option svg { flex-shrink: 0; }

.mprod-stripe-card {
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 6px;
    background: #F7F7F7;
    margin-bottom: 16px;
}

.mprod-stripe-pay { width: 100%; }

.mprod-pay-error {
    display: block;
    color: #c0392b;
    font-size: 13px;
    margin-top: 8px;
    min-height: 18px;
}

.mprod-payment-area { margin-top: 16px; }

/* ============================================================
   ORDINI — DASHBOARD
   ============================================================ */

.mprod-orders-filters {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}
.mprod-order-filter {
    padding: 8px 16px;
    border: 1px solid #ddd;
    border-radius: 20px;
    background: #fff;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    color: #666;
    transition: all .2s;
}
.mprod-order-filter:hover { border-color: #bbb; }
.mprod-order-filter.active {
    background: var(--mp-primary);
    color: #fff;
    border-color: var(--mp-primary);
}

.mprod-order-card {
    border: 1px solid #eee;
    border-radius: 10px;
    margin-bottom: 12px;
    overflow: hidden;
    transition: box-shadow .2s;
}
.mprod-order-card:hover { box-shadow: 0 2px 8px rgba(0,0,0,.06); }

.mprod-order-header {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 14px 18px;
    cursor: pointer;
    flex-wrap: wrap;
}
.mprod-order-id {
    font-weight: 700;
    font-size: 14px;
    color: var(--mp-text);
    min-width: 50px;
}
.mprod-order-date {
    font-size: 13px;
    color: #888;
}
.mprod-order-total {
    font-weight: 700;
    font-size: 15px;
    color: var(--mp-text);
    margin-left: auto;
}
.mprod-order-badge {
    font-size: 11px;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 12px;
    text-transform: uppercase;
    letter-spacing: .3px;
}
.mprod-status-pending { background: #ffeaa7; color: #856404; }
.mprod-status-paid { background: #dfe6e9; color: #2d3436; }
.mprod-status-shipped { background: #74b9ff; color: #fff; }
.mprod-status-completed { background: #00b894; color: #fff; }
.mprod-status-cancelled { background: #fab1a0; color: #d63031; }

.mprod-order-pay-method {
    font-size: 11px;
    color: #999;
    text-transform: capitalize;
}

.mprod-btn-sm {
    padding: 6px 14px;
    font-size: 12px;
    font-weight: 600;
    border: none;
    border-radius: 6px;
    background: var(--mp-primary);
    color: #fff;
    cursor: pointer;
    transition: opacity .2s;
}
.mprod-btn-sm:hover { opacity: .85; }
.mprod-btn-sm:disabled { opacity: .5; cursor: not-allowed; }

.mprod-order-details {
    padding: 0 18px 18px;
    border-top: 1px solid #f0f0f0;
}
.mprod-order-shipping {
    font-size: 13px;
    line-height: 1.6;
    color: #555;
    margin-bottom: 14px;
    padding-top: 14px;
}
.mprod-order-items-list { }
.mprod-order-item-row {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    font-size: 13px;
    border-bottom: 1px solid #f5f5f5;
}
.mprod-order-item-row:last-child { border-bottom: none; }

@media (max-width: 600px) {
    .mprod-order-header { gap: 8px; }
    .mprod-order-total { margin-left: 0; }
    .mprod-pay-options { flex-direction: column; }
}

/* ============================================================
   CHECKOUT PAGE — LAYOUT SINGOLA COLONNA
   ============================================================ */

.mprod-checkout { max-width: 1100px; margin: 0 auto; }

/* --- LAYOUT 2 COLONNE: summary sx fisso, form dx --- */
.mprod-ck-layout {
    display: grid;
    grid-template-columns: 1fr 360px;
    gap: 40px;
    align-items: start;
}
.mprod-ck-sidebar {
    position: sticky;
    top: 24px;
}
.mprod-ck-main { min-width: 0; }

/* --- BANNER NEGOZIO --- */
.mprod-ck-banner {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 20px;
    background: #faf8f6;
    border: 1px solid #eee;
    border-radius: 12px;
    margin-bottom: 24px;
}
.mprod-ck-banner-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #ccc center/cover no-repeat;
    flex-shrink: 0;
}
.mprod-ck-banner-info { display: flex; flex-direction: column; }
.mprod-ck-banner-label { font-size: 12px; color: #999; }
.mprod-ck-banner-info strong { font-size: 16px; color: var(--mp-text); }

/* --- SUMMARY BOX --- */
.mprod-ck-summary-box {
    background: #faf8f6;
    border: 1px solid #eee;
    border-radius: 12px;
    padding: 20px 24px;
    margin-bottom: 28px;
}
.mprod-ck-summary-box h3 {
    font-size: 15px;
    font-weight: 700;
    margin: 0 0 14px;
    color: var(--mp-text);
}

.mprod-ck-section {
    margin-bottom: 32px;
    padding-bottom: 24px;
    border-bottom: 1px solid #eee;
}
.mprod-ck-section:last-child { border-bottom: none; }
.mprod-ck-section h3 {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 17px;
    font-weight: 700;
    margin: 0 0 20px;
    color: var(--mp-text);
}
.mprod-ck-num {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--mp-primary);
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    flex-shrink: 0;
}

.mprod-checkout-field {
    margin-bottom: 14px;
}
.mprod-checkout-field label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 5px;
    color: #555;
}
.mprod-checkout-field input,
.mprod-checkout-field textarea,
.mprod-checkout-field select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 14px;
    color: var(--mp-text);
    background: #F7F7F7;
    box-sizing: border-box;
    font-family: inherit;
}
.mprod-checkout-field input:focus,
.mprod-checkout-field textarea:focus {
    outline: none;
    border-color: var(--mp-primary);
}
.mprod-checkout-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}
.mprod-checkout-row-3 {
    grid-template-columns: 120px 1fr 100px;
}

/* --- RIEPILOGO (inline) --- */

.mprod-ck-items { margin-bottom: 16px; }
.mprod-ck-item {
    display: flex;
    gap: 10px;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid #f0f0f0;
}
.mprod-ck-item:last-child { border-bottom: none; }
.mprod-ck-item-img {
    width: 50px;
    height: 50px;
    border-radius: 6px;
    background: #eee center/cover no-repeat;
    flex-shrink: 0;
}
.mprod-ck-item-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.mprod-ck-item-name { font-size: 13px; font-weight: 600; color: var(--mp-text); }
.mprod-ck-item-variant { font-size: 11px; color: #888; }
.mprod-ck-item-qty { font-size: 11px; color: #999; }
.mprod-ck-item-price { font-size: 14px; font-weight: 600; white-space: nowrap; }

.mprod-ck-totals {
    border-top: 1px solid #eee;
    padding-top: 14px;
}
.mprod-ck-row {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    color: #666;
    padding: 4px 0;
}
.mprod-ck-total {
    font-size: 16px;
    color: var(--mp-text);
    font-weight: 700;
    padding-top: 10px;
    margin-top: 6px;
    border-top: 1px solid #ddd;
}

/* --- CART ACTIONS --- */
.mprod-cart-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}
.mprod-btn-secondary {
    display: inline-block;
    padding: 10px 20px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    color: var(--mp-text);
    background: #fff;
    text-decoration: none;
    text-align: center;
    transition: border-color .2s;
}
.mprod-btn-secondary:hover { border-color: var(--mp-primary); color: var(--mp-primary); }

.mprod-cart-subtitle {
    font-size: 14px;
    color: #888;
    margin: -8px 0 24px;
}

/* --- CHECKOUT ERROR FOR GUEST EMAIL --- */
.mprod-ck-email-exists {
    background: #fff3cd;
    border: 1px solid #ffc107;
    border-radius: 8px;
    padding: 14px 18px;
    margin-top: 10px;
    font-size: 13px;
}
.mprod-ck-email-exists a { color: var(--mp-primary); font-weight: 600; }

@media (max-width: 804px) {
    .mprod-checkout-row-3 { grid-template-columns: 1fr 1fr; }
    .mprod-ck-layout { grid-template-columns: 1fr; }
    .mprod-ck-sidebar { position: static; order: -1; }
}

/* ============================================================
   CHECKOUT — PROGRESS BAR
   ============================================================ */

.mprod-ck-progress {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin-bottom: 32px;
    padding: 0 40px;
}
.mprod-ck-step-dot {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
    color: #bbb;
    transition: color .3s;
}
.mprod-ck-step-dot span {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #eee;
    color: #999;
    font-size: 13px;
    font-weight: 700;
    transition: background .3s, color .3s;
}
.mprod-ck-step-dot.active { color: var(--mp-text); }
.mprod-ck-step-dot.active span { background: var(--mp-primary); color: #fff; }
.mprod-ck-step-line {
    flex: 1;
    height: 2px;
    background: #eee;
    margin: 0 16px;
    max-width: 120px;
}

/* ============================================================
   CHECKOUT — STEPS
   ============================================================ */

.mprod-ck-step { animation: mprodFadeIn .3s ease; }
@keyframes mprodFadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

.mprod-step1-next { width: 100%; margin-top: 8px; }

.mprod-btn-back {
    display: inline-block;
    margin-top: 16px;
    background: none;
    border: none;
    color: #888;
    font-size: 13px;
    cursor: pointer;
    padding: 8px 0;
    transition: color .2s;
}
.mprod-btn-back:hover { color: var(--mp-primary); }

/* ============================================================
   CHECKOUT — PRIVACY CHECKBOX
   ============================================================ */

.mprod-ck-privacy {
    margin: 20px 0 8px;
}
.mprod-ck-checkbox {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    cursor: pointer;
    font-size: 13px;
    line-height: 1.5;
    color: #555;
}
.mprod-ck-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    flex-shrink: 0;
    accent-color: var(--mp-primary);
}
.mprod-ck-checkbox a {
    color: var(--mp-primary);
    text-decoration: underline;
}

/* ============================================================
   CHECKOUT — FIELD ERRORS
   ============================================================ */

.mprod-ck-field-err {
    display: block;
    font-size: 12px;
    color: #c0392b;
    min-height: 16px;
    margin-top: 3px;
}
.mprod-ck-global-err {
    display: block;
    margin-bottom: 12px;
    font-size: 13px;
}

/* ============================================================
   BILLING FORM (Stripe step 2)
   ============================================================ */

.mprod-billing-section {
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}
.mprod-billing-notice {
    font-size: 13px;
    line-height: 1.6;
    color: #666;
    margin: 0 0 18px;
    padding: 14px 16px;
    background: #f9f7f5;
    border-radius: 8px;
    border-left: 3px solid var(--mp-primary);
}
.mprod-billing-field {
    margin-bottom: 14px;
}
.mprod-billing-field label,
.mprod-billing-label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 5px;
    color: #555;
}
.mprod-billing-field input {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 14px;
    color: var(--mp-text);
    background: #fff;
    box-sizing: border-box;
    font-family: inherit;
    transition: border-color .2s;
}
.mprod-billing-field input:focus {
    outline: none;
    border-color: var(--mp-primary);
}
.mprod-billing-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}
.mprod-billing-row-3 {
    grid-template-columns: 110px 1fr 90px;
}

.mprod-stripe-card-wrap {
    margin-bottom: 16px;
}
.mprod-stripe-card {
    padding: 14px;
    border: 1px solid #ccc;
    border-radius: 6px;
    background: #fff;
    transition: border-color .2s;
}
.mprod-stripe-card.StripeElement--focus {
    border-color: var(--mp-primary);
}

.mprod-stripe-pay { width: 100%; }

/* ============================================================
   ORDER DETAILS — INFO GRID (spedizione + fatturazione)
   ============================================================ */

.mprod-order-info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    padding-top: 16px;
    margin-bottom: 16px;
}
.mprod-order-info-col {
    font-size: 13px;
    line-height: 1.7;
    color: #555;
}
.mprod-order-info-col strong {
    display: block;
    margin-bottom: 6px;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .5px;
    color: var(--mp-text);
}

@media (max-width: 600px) {
    .mprod-order-info-grid { grid-template-columns: 1fr; }
    .mprod-billing-row-3 { grid-template-columns: 1fr 1fr; }
}

/* ============================================================
   LIGHTBOX OVERLAY
   ============================================================ */

.mprod-lightbox {
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: rgba(0,0,0,.88);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity .25s ease;
    cursor: zoom-out;
}
.mprod-lightbox.show { opacity: 1; }
.mprod-lightbox img {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 6px;
    box-shadow: 0 8px 40px rgba(0,0,0,.5);
    cursor: default;
    user-select: none;
}
.mprod-lb-close {
    position: absolute;
    top: 16px;
    right: 20px;
    width: 40px;
    height: 40px;
    border: none;
    background: rgba(255,255,255,.15);
    border-radius: 50%;
    color: #fff;
    font-size: 22px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .2s;
}
.mprod-lb-close:hover { background: rgba(255,255,255,.3); }
.mprod-lb-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    border: none;
    background: rgba(255,255,255,.15);
    border-radius: 50%;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .2s;
}
.mprod-lb-nav:hover { background: rgba(255,255,255,.3); }
.mprod-lb-prev { left: 16px; }
.mprod-lb-next { right: 16px; }
.mprod-lb-counter {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255,255,255,.7);
    font-size: 13px;
}

/* Clickable images */
.mprod-gallery-big img { cursor: zoom-in; }
.mprod-gallery-thumbs .mprod-thumb-wrap { cursor: pointer; }

/* --- DELIVERY ROW --- */
.mprod-ck-delivery {
    color: #5C2E26;
    font-weight: 500;
}

/* ============================================================
   CHECKOUT — STEP COLLASSATO
   ============================================================ */

.mprod-ck-step-done {
    background: #faf8f6;
    border: 1px solid #eee;
    border-radius: 12px;
    padding: 16px 20px;
    margin-bottom: 24px;
}
.mprod-ck-done-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.mprod-ck-done-header > div {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 15px;
    color: var(--mp-text);
}
.mprod-ck-done-header .mprod-ck-num {
    background: #27ae60;
}
.mprod-ck-edit-btn {
    background: none;
    border: 1px solid #ccc;
    border-radius: 6px;
    padding: 6px 14px;
    font-size: 12px;
    font-weight: 600;
    color: #666;
    cursor: pointer;
    transition: border-color .2s, color .2s;
}
.mprod-ck-edit-btn:hover {
    border-color: var(--mp-primary);
    color: var(--mp-primary);
}
.mprod-ck-done-body {
    margin-top: 10px;
    font-size: 13px;
    line-height: 1.6;
    color: #666;
}
.mprod-ck-done-body p { margin: 0; }

/* ============================================================
   FOTO VARIANTE — cella picker + modal libreria foto negozio
   ============================================================ */
.mpv-img-pick {
    width: 46px; height: 46px;
    border: none !important; border-radius: 5px !important;
    background: #F7F2E9 center / cover no-repeat; /* posizionamento per la thumb inline */
    background-color: #22286A !important;          /* sfondo blu sullo stato vuoto */
    color: #fff !important;
    cursor: pointer; padding: 0;
    display: inline-flex; align-items: center; justify-content: center;
}
.mpv-img-pick__plus { font-size: 20px; line-height: 1; font-weight: 600; }

.mpe-img-picker { position: fixed; inset: 0; z-index: 100000; display: flex; align-items: center; justify-content: center; padding: 20px; }
.mpe-img-picker[hidden] { display: none; }
.mpe-img-picker__backdrop { position: absolute; inset: 0; background: rgba(18,17,15,.55); }
.mpe-img-picker__panel { position: relative; background: #fff; border-radius: 12px; max-width: 680px; width: 100%; max-height: 80vh; display: flex; flex-direction: column; box-shadow: 0 16px 48px rgba(0,0,0,.25); overflow: hidden; }
.mpe-img-picker__close { position: absolute; top: 8px; right: 12px; border: 0; background: transparent; font-size: 26px; line-height: 1; cursor: pointer; color: #6F6F6F; padding: 0; }
.mpe-img-picker__close:hover { color: #5C2E26; }
.mpe-img-picker__title { margin: 0; padding: 18px 22px 12px; font-size: 18px; font-weight: 700; color: #12110F; }
.mpe-img-picker__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; padding: 0 22px 16px; overflow-y: auto; }
.mpe-img-picker__item { aspect-ratio: 1 / 1; border: 2px solid transparent; border-radius: 8px; background: #F7F2E9 center / cover no-repeat; cursor: pointer; padding: 0; }
.mpe-img-picker__item:hover { border-color: #9A4F3F; }
.mpe-img-picker__item.is-active { border-color: #5C2E26; box-shadow: 0 0 0 2px rgba(92,46,38,.25); }
.mpe-img-picker__loading { grid-column: 1 / -1; text-align: center; color: #9A9A9A; padding: 30px 12px; }
.mpe-img-picker__foot { padding: 12px 22px; border-top: 1px solid #eee; display: flex; justify-content: flex-end; align-items: center; gap: 10px; }
/* "Carica dal PC" visibile solo quando il popup è in modalità galleria prodotto */
.mpe-img-picker__upload { display: none; }
.mpe-img-picker--gallery .mpe-img-picker__upload { display: inline-flex; }
.mpe-img-picker--gallery .mpe-img-picker__clear { display: none; }
body.mpe-img-picker-open { overflow: hidden; }

/* Bordi richiesti su quantità e box bundle (scheda prodotto).
   Specificità alta: il tema (prodotto.css) imposta .qf-product-info__qty{border:0 !important},
   quindi serve un selettore più specifico per vincere a parità di !important. */
.qf-product .qf-product-info__qty-row .qf-product-info__qty { border: 1px solid #22286A !important; }
.qf-product .qf-product-info__bundle { border: 1px solid #22286A !important; }

/* Rifiniture richieste */
.mpv-img-pick.has-img { border: none !important; }
.mpe-img-picker__item { border: none !important; }
button.mpe-img-picker__close { background: #22286A !important; color: #fff !important; border: none !important; border-radius: 5px !important; }
.mpe-img-picker__upload,
.mpe-img-picker__upload:hover,
.mpe-img-picker__upload:focus {
    background: #22286A !important;
    color: #fff !important;
    border: none !important;
    border-radius: 5px !important;
    margin-top: 6px !important;
}
.mpv-img-pick { height: 36px; }
#mpe-gallery-open { border-radius: 50px; width: 45px; text-align: center; background: rgba(0,0,0,0.6); border: none; }
#mpe-gallery-open svg { margin-top: 2px; margin-left: -4px; }
