/*
Theme Name: Botiga Child
Theme URI: http://athemes.com/theme/botiga
Author: aThemes
Author URI: http://athemes.com
Template: botiga
Version: 1.0.1
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: botiga
*/

/* Switcher Griglia/Lista accessibile */
.botiga-grid-list-view {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.botiga-grid-list-view button {
    background: transparent;
    border: none;
    padding: 0;
    margin: 0;
    cursor: pointer;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.botiga-grid-list-view button svg {
    display: block;
    width: 20px;
    height: 20px;
    fill: #212121;
}

.botiga-grid-list-view button:not(.active) svg {
    opacity: 0.35;
}

/* Allineamento card prodotto e sicurezza anti-duplicato */
ul.products li.product {
    display: flex !important;
    flex-direction: column !important;
    justify-content: flex-start !important;
    height: 100% !important;
}

/* Se compare ancora un H2 duplicato, viene nascosto all'istante */
ul.products li.product h2.woocommerce-loop-product__title + h2.woocommerce-loop-product__title,
ul.products li.product h3.woocommerce-loop-product__title ~ h2.woocommerce-loop-product__title {
    display: none !important;
}

/* Uniforma l'altezza del titolo e allinea le card */
ul.products li.product .woocommerce-loop-product__title {
    font-size: 15px !important;
    line-height: 1.4 !important;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    margin-bottom: 6px !important;
}

/* Gestione spazio recensioni */
ul.products li.product .star-rating {
    margin: 0 auto 6px auto !important;
}

/* Spinge prezzo e pulsanti sempre allineati sul fondo della card */
ul.products li.product .price {
    margin-top: auto !important;
    margin-bottom: 10px !important;
    text-align: center;
}

ul.products li.product .loop-button-wrap {
    margin-top: 0 !important;
}
