/**
 * LFDP — fix specifici WordPress/WooCommerce (caricato per ultimo).
 */

/* Immagini sempre responsive */
img { max-width: 100%; height: auto; }

/* Avvisi WooCommerce dentro #notifications: stile alert Bootstrap */
#notifications .woocommerce-message,
#notifications .woocommerce-info,
#notifications .woocommerce-error {
  padding: .75rem 1.25rem;
  margin-bottom: 1rem;
  border: 1px solid transparent;
  border-radius: .4375rem;
  background-color: #d4edda;
  border-color: #c3e6cb;
  color: #155724;
  font-size: .875rem;
}
#notifications .woocommerce-info { background-color: #d1ecf1; border-color: #bee5eb; color: #0c5460; }
#notifications .woocommerce-error { background-color: #f8d7da; border-color: #f5c6cb; color: #721c24; }
#notifications .woocommerce-message a,
#notifications .woocommerce-info a { color: inherit; font-weight: 700; text-decoration: underline; }

/* Prezzi nel carrello header e pagine WC: sempre in stile mirror */
.woocommerce-Price-amount { font-weight: inherit; }

/* Widget area sidebar: liste WC dentro la shell filtri del mirror */
#shop-sidebar ul.product-categories,
#shop-sidebar ul.widget-list,
#shop-sidebar .widget ul { list-style: none; padding-left: 0; margin: 0; }
#shop-sidebar .widget ul li { padding: .25rem 0; }
#shop-sidebar .widget ul li a { color: #373f50; font-size: .875rem; }
#shop-sidebar .widget ul li a:hover { color: #E31E24; }
#shop-sidebar .widget select,
#shop-sidebar .widget input[type="text"],
#shop-sidebar .widget input[type="number"] { max-width: 100%; }

/* Widget filtro prezzo WC (se aggiunto) */
#shop-sidebar .price_slider_wrapper .price_slider { margin-bottom: 1rem; }
#shop-sidebar .price_slider_amount .button { font-size: .8rem; }

/* Form add-to-cart: niente margini strani ereditati */
form.cart { margin: 0; }

/* Pagine carrello/checkout/account: contenitore in stile mirror */
.woocommerce { width: 100%; }
.woocommerce table.shop_table { width: 100%; margin-bottom: 1.5rem; border-collapse: collapse; }
.woocommerce table.shop_table th,
.woocommerce table.shop_table td { padding: .75rem; border: 1px solid #e9ecef; text-align: left; }
.woocommerce .button,
.woocommerce button.button,
.woocommerce input.button,
.woocommerce a.button {
  display: inline-block; font-weight: 500; text-align: center; vertical-align: middle;
  padding: .625rem 1.375rem; font-size: .875rem; line-height: 1.5; border-radius: .4375rem;
  color: #fff; background-color: #CF3A2F; border-color: #CF3A2F; cursor: pointer;
  transition: background-color .2s, border-color .2s;
}
.woocommerce .button:hover,
.woocommerce a.button:hover { background-color: #a92f26; border-color: #a92f26; color: #fff; text-decoration: none; }
.woocommerce input.input-text,
.woocommerce select,
.woocommerce textarea {
  display: block; width: 100%; padding: .625rem 1rem; font-size: .875rem; line-height: 1.5;
  color: #4b566b; background-color: #fff; border: 1px solid #dae1e7; border-radius: .4375rem;
}
.woocommerce label { font-weight: 500; margin-bottom: .375rem; display: inline-block; }
.woocommerce form .form-row { margin-bottom: 1rem; }
.woocommerce-breadcrumb { margin-bottom: 0; }

/* Pagination WC (quando attiva fuori dai nostri template) */
.woocommerce-pagination ul { list-style: none; display: flex; padding-left: 0; }
.woocommerce-pagination ul li { margin: 0 .15rem; }

/* Admin bar: il nostro header sticky resta sotto la barra WP */
@media (min-width: 783px) {
  body.admin-bar .navbar-sticky, body.admin-bar .tb--sticky { margin-top: 0; }
}

/* La select ordinamento custom: freccia nativa del tema */
#select-sort-order { max-width: 220px; }

/* Card prodotto dentro carousel tiny-slider */
.tns-carousel > div { box-sizing: border-box; }
.tns-outer { position: relative; }
.tns-controls [data-controls] { z-index: 5; }

/* Le miniature orizzontali della galleria prodotto scrollano */
.cz-thumblist { flex-wrap: nowrap; overflow-x: auto; }
.cz-thumblist::-webkit-scrollbar { height: 4px; }

/* Badge ribbon prodotto sopra l'immagine */
.product-flags { position: absolute; top: .75rem; left: .75rem; z-index: 3; }
.mplfdp-gallery { position: relative; }
article.product-miniature { position: relative; }

/* Stampa prezzo card: allineamento come nel mirror */
.mp-price-content .lfdp-price { margin-right: .5rem; }

/* L'immagine banner meilleur prix nella short description */
.product-description-short img { max-width: 100%; height: auto; }

/* Evita che i contenuti importati rompano il layout */
.product-description iframe,
.product-description video { max-width: 100%; }
.product-description table { display: block; overflow-x: auto; max-width: 100%; }

/* Home: il primo blocco hero è a filo con l'header */
#index #wrapper { padding-top: 0; }
