/*
Theme Name:   Enoteca Rizzi
Theme URI:    https://enotecarizzi.originiagency.com
Description:  Child theme di bootstrap-origini per enotecarizzi.it
Author:       Origini Digital Agency
Author URI:   https://www.originiagency.it
Template:     bootstrap-origini
Version:      0.3.0
Text Domain:  enotecarizzi
*/

/* ============================================================
   @font-face + DESIGN TOKENS
   ============================================================ */
@font-face {
    font-family: 'Stardom';
    src: url('fonts/Stardom-Regular.otf') format('opentype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

:root {
    /* Palette */
    --er-primary:       #3f151f;
    --er-accent:        #f06526;
    --er-accent-dark:   #c44d18;
    --er-surface:       #e5dece;
    --er-surface-light: #f1efea;
    --er-title-light:   #923148;
    --er-text:          #131313;
    --er-text-muted:    #706e6b;
    --er-white:         #ffffff;

    /* Font */
    --er-f-disp: 'Stardom', Georgia, serif;
    --er-f-body: 'DM Sans', system-ui, sans-serif;

    /* Radius */
    --er-radius:    50px;
    --er-radius-lg: 10px;

    /* Hero carousel */
    --er-slide-height: 65vh;
    --er-slide-min-height: 360px;
}

/* ============================================================
   BASE
   ============================================================ */
body {
    font-family: var(--er-f-body);
    color: var(--er-text);
    background: var(--er-white);
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
}
.form-select:focus,
.form-control:focus {
    border-color: var(--er-primary);
    box-shadow: none;
}
.select2-container .select2-selection--single,
.select2-container .select2-selection--multiple {
    border-radius: var(--er-radius) !important;
    border-color: #ccc;
}
.select2-container .select2-selection--single .select2-selection__rendered {
    padding: .7em .5em .7em 1.1em;
}
.select2-container .select2-selection--single .select2-selection__clear {
    margin-right: 1.5em;
}
a {
    color: var(--er-primary);
    text-decoration: none;
}
.accordion-button:not(.collapsed) {
    color: var(--er-white);
    background-color: var(--er-title-light);
}
.accordion-button:focus {
    box-shadow: none;
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn-primary,
.btn-secondary,
.btn-outline-primary,
.btn-outline-light,
.btn-outline-dark {
    border-radius: var(--er-radius);
    font-family: var(--er-f-body);
    font-size: 15px;
    padding: 10px 24px;
    transition: all 0.2s;
    text-decoration: none;
}

.btn-primary {
    background: var(--er-accent-dark);
    border-color: var(--er-accent-dark);
    color: var(--er-white);
    font-weight: 600;
}
.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
    background: var(--er-primary);
    border-color: var(--er-primary);
    color: var(--er-white);
}

.btn-secondary {
    background: var(--er-primary);
    border-color: var(--er-primary);
    color: var(--er-white);
    font-weight: 600;
}
.btn-secondary:hover,
.btn-secondary:focus,
.btn-secondary:active {
    background: var(--er-accent);
    border-color: var(--er-accent);
    color: var(--er-white);
}

.btn-outline-primary {
    background: transparent;
    border-color: var(--er-accent-dark);
    color: var(--er-accent-dark);
    font-weight: 600;
}
.btn-outline-primary:hover,
.btn-outline-primary:focus,
.btn-outline-primary:active {
    background: var(--er-accent-dark);
    border-color: var(--er-accent-dark);
    color: var(--er-white);
}

.btn-outline-light {
    background: transparent;
    border: 1px solid var(--er-white);
    color: var(--er-white);
    font-weight: 500;
}
.btn-outline-light:hover,
.btn-outline-light:focus,
.btn-outline-light:active {
    background: var(--er-white);
    color: var(--er-primary);
    border-color: var(--er-white);
}

.btn-outline-dark {
    background: transparent;
    border: 1px solid var(--er-primary);
    color: var(--er-primary);
    font-weight: 500;
}
.btn-outline-dark:hover,
.btn-outline-dark:focus,
.btn-outline-dark:active {
    background: var(--er-primary);
    color: var(--er-white);
    border-color: var(--er-primary);
}

.btn.btn-sm {
    padding: 8px 20px;
    font-size: 15px;
}

.btn-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 15px;
    font-weight: 600;
    color: var(--er-accent-dark);
    text-decoration: none;
    transition: gap 0.2s;
    padding: 0;
    border: none;
}
.btn-link:hover,
.btn-link:focus {
    gap: 10px;
    color: #d9561e;
    text-decoration: none;
}
@media (max-width: 991.98px) {
    .btn-primary,
    .btn-secondary,
    .btn-outline-primary,
    .btn-outline-light,
    .btn-outline-dark {
        padding: 10px 20px;
        font-size: 14px;
    }
    .btn.btn-sm {
        padding: 6px 14px;
        font-size: 13px;
    }
}

/* ============================================================
   SECTION TITLES
   ============================================================ */
.er-section-title {
    font-family: var(--er-f-disp);
    font-size: 30px;
    color: var(--er-title-light);
    margin-bottom: 0.35rem;
}
.er-section-title--dark {
    color: var(--er-primary);
}
.er-section-title--white {
    color: var(--er-white);
}
.er-section-sub {
    font-size: 15px;
    color: var(--er-text);
    font-weight: 400;
    margin-bottom: 0.5rem;
}
.er-section-sub--white {
    color: rgba(255,255,255,0.6);
}
.er-section-title-dm h2 {
    font-weight: 900;
    color: var(--er-title-light);
}

/* ============================================================
   TOPBAR
   ============================================================ */
.er-topbar {
    background: var(--er-text);
    color: var(--er-white);
    font-size: 12px;
    padding: 8px 0;
}
.er-topbar i {
    opacity: 0.5;
    margin-right: 4px;
}
.er-topbar .sep {
    display: inline-block;
    width: 1px;
    height: 12px;
    background: rgba(255,255,255,0.15);
    margin: 0 16px;
    vertical-align: middle;
}
.er-topbar .btn-accedi {
    background: var(--er-accent);
    color: #fff;
    border: none;
    border-radius: var(--er-radius);
    font-family: var(--er-f-body);
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    padding: 5px 18px;
    text-decoration: none;
    transition: background 0.2s;
}
.er-topbar .btn-accedi:hover {
    background: #d9561e;
}

/* ============================================================
   HEADER
   ============================================================ */
.er-header {
    position: sticky;
    top: 0;
    z-index: 1000;
}
.er-header-top {
    background: var(--er-white);
    border-bottom: 1px solid rgba(0,0,0,0.08);
    padding: 0.75rem 0;
}
.er-logo {
    font-family: var(--er-f-disp);
    font-size: 18px;
    color: var(--er-accent);
    text-decoration: none;
    line-height: 1;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 8px;
}
.er-logo:hover {
    color: var(--er-accent);
}
img.er-logo-img {
    height: 60px;
    width: auto;
    flex-shrink: 0;
}
.er-search-bar {
    background: var(--er-white);
    border: 1px solid rgba(0,0,0,0.08);
    border-radius: 24px;
    padding: 8px 16px;
    font-size: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.er-search-bar input {
    border: none;
    background: transparent;
    outline: none;
    font-family: var(--er-f-body);
    font-size: 13px;
    color: var(--er-text);
    width: 100%;
}
.er-search-bar input::placeholder {
    color: rgba(19,19,19,0.4);
}
.er-search-wrap {
    flex: 1;
    max-width: 800px;
}
.er-header-icons {
    display: flex;
    align-items: center;
    gap: 10px;
}
.er-cart-icon-wrap {
    position: relative;
    display: inline-flex;
}
.er-cart-badge {
    position: absolute;
    top: -8px;
    right: -10px;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 50%;
    background: var(--er-accent);
    color: var(--er-white);
    font-size: 11px;
    font-weight: 700;
    line-height: 18px;
    text-align: center;
}
/* Header nav */
.er-header-nav {
    background: var(--er-white);
}
.er-nav-main .nav-link {
    font-family: var(--er-f-body);
    font-size: 15px;
    font-weight: 500;
    color: var(--er-primary);
    padding: 0.9rem 1.2rem;
    text-transform: uppercase;
    transition: color 0.2s;
    white-space: nowrap;
}
.er-nav-main .nav-link:hover,
.er-nav-main .nav-link.active {
    color: var(--er-accent);
}

/* Voce PROMO — gradient animato */
@keyframes er-promo-shift {
    0%   {
        background-position: 0% 50%;
    }
    50%  {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}
.er-header-shipping {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 15px;
    font-weight: 500;
    color: var(--er-primary);
    white-space: nowrap;
}
.er-header-shipping i {
    color: var(--er-accent);
    font-size: 18px;
}

/* Page header (er-header-custom) */
.er-header-custom {
    position: relative;
    overflow: hidden;
    margin-bottom: 2rem;
}
.er-header-bg {
    position: absolute;
    top: -40%;
    left: 0;
    right: 0;
    bottom: -40%;
    background-size: cover;
    background-position: center;
    will-change: transform;
}
.er-header-content {
    position: relative;
    z-index: 1;
}

.er-header-title {
    color: var(--er-white);
    font-family: var(--er-f-disp);
    padding-top: 4rem;
    padding-bottom: 4rem;
}
@media (max-width: 991.98px) {
    .er-header-top {
        padding: 0.5rem 0;
    }
    .er-header-top-flex {
        flex-wrap: wrap;
        gap: 0.5rem !important;
    }
    .er-logo {
        order: 1;
    }
    img.er-logo-img {
        height: 40px;
    }
    .er-header-top .er-hamburger {
        order: 2;
        margin-left: auto;
    }
    .er-search-wrap {
        order: 3;
        flex: 1 1 70%;
        min-width: 0;
        max-width: none;
    }
    .er-header-icons {
        order: 4;
        flex-shrink: 0;
    }
    .er-header-icons .btn.btn-sm {
        padding: 6px 10px;
    }
    .er-nav-main {
        display: none !important;
    }
}

/* ============================================================
   MEGA MENU — DESKTOP
   ============================================================ */
.er-header-nav {
    position: relative;
}
.er-mega-item {
    position: static;
}
.er-mega-item > .nav-link {
    cursor: pointer;
}
.er-nav-promo > .nav-link {
    color: var(--er-white);
    font-weight: 600;
    background: linear-gradient(135deg, var(--er-accent), var(--er-title-light), var(--er-accent), var(--er-title-light));
    background-size: 400% 400%;
    animation: er-promo-shift 8s ease infinite;
    border-radius: var(--er-radius);
    padding: 8px 20px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    will-change: background-position;
}
.er-nav-promo > .nav-link:hover {
    color: var(--er-white);
}

/* Pannello — posizionato rispetto a .er-header-nav (full-width) */
.er-mega-panel {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--er-white);
    border-top: 2px solid var(--er-primary);
    box-shadow: 0 12px 40px rgba(63,21,31,0.1);
    padding: 2rem 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 200ms ease-out, transform 200ms ease-out, visibility 200ms;
    z-index: 999;
}
.er-mega-item.open > .er-mega-panel {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* Colonne dentro il pannello */
.er-mega-columns {
    display: flex;
    gap: 2.5rem;
}
.er-mega-col {
    flex: 1;
    min-width: 0;
}
.er-mega-col-title {
    font-family: var(--er-f-body);
    font-size: 16px;
    font-weight: 900;
    color: var(--er-primary);
    text-transform: uppercase;
    margin-bottom: 0.75rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(0,0,0,0.06);
}
.er-mega-col-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.15s;
}
.er-mega-col-title a:hover {
    color: var(--er-accent);
}
.er-mega-links {
    list-style: none;
    padding: 0;
    margin: 0;
}
.er-mega-links li {
    margin-bottom: 0.3rem;
}
.er-mega-link {
    font-size: 15px;
    color: var(--er-text);
    text-decoration: none;
    transition: color 0.15s;
    display: block;
    padding: 3px 0;
}
.er-mega-link:hover {
    color: var(--er-accent);
}
.er-mega-view-all {
    font-size: 15px;
    font-weight: 600;
    color: var(--er-accent);
    margin-top: 0.5rem;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.er-mega-view-all:hover {
    gap: 8px;
    color: #d9561e;
}

/* Gruppi (per ALTRO — 3 livelli) */
.er-mega-group {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
}
.er-mega-group-title {
    font-family: var(--er-f-disp);
    font-size: 16px;
    margin-bottom: 0.75rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(0,0,0,0.08);
}
.er-mega-group-title a {
    color: var(--er-title-light);
    text-decoration: none;
    transition: color 0.15s;
}
.er-mega-group-title a:hover {
    color: var(--er-accent);
}
.er-mega-group-cols {
    display: flex;
    gap: 2rem;
}
.er-mega-group-cols .er-mega-col {
    flex: 1;
    min-width: 0;
}

/* Immagine mega menu (colonna extra 1/3) */
.er-mega-img {
    flex: 0 0 calc(33.333% - 1.25rem);
    min-width: 0;
    border-radius: var(--er-radius-lg);
    overflow: hidden;
}
.er-mega-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Overlay */
.er-mega-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.15);
    z-index: 998;
    opacity: 0;
    visibility: hidden;
    transition: opacity 200ms;
    pointer-events: none;
}
.er-mega-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* ============================================================
   MEGA MENU — HAMBURGER + DRAWER MOBILE
   ============================================================ */
.er-hamburger {
    background: none;
    border: none;
    font-size: 22px;
    color: var(--er-primary);
    padding: 0.4rem;
    cursor: pointer;
    line-height: 1;
}

/* Drawer */
.er-drawer-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.4);
    z-index: 1100;
    opacity: 0;
    visibility: hidden;
    transition: opacity 250ms;
}
.er-drawer-overlay.active {
    opacity: 1;
    visibility: visible;
}
.er-drawer {
    position: fixed;
    top: 0;
    left: 0;
    width: 85vw;
    max-width: 360px;
    height: 100%;
    background: var(--er-white);
    z-index: 1101;
    transform: translateX(-100%);
    transition: transform 300ms ease-out;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
.er-drawer.open {
    transform: translateX(0);
}
.er-drawer-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid rgba(0,0,0,0.08);
}
.er-drawer-title {
    font-family: var(--er-f-disp);
    font-size: 18px;
    color: var(--er-primary);
}
.er-drawer-close {
    background: none;
    border: none;
    font-size: 18px;
    color: var(--er-text);
    cursor: pointer;
    padding: 0.3rem;
}
.er-drawer-body {
    flex: 1;
    overflow-y: auto;
    padding: 0.5rem 0;
    -webkit-overflow-scrolling: touch;
}

/* Nav dentro il drawer */
.er-drawer-nav {
    list-style: none;
    padding: 0;
    margin: 0;
}
.er-drawer-nav > li {
    border-bottom: 1px solid rgba(0,0,0,0.06);
}
.er-drawer-nav > li > a {
    display: block;
    padding: 0.85rem 1.25rem;
    font-size: 14px;
    font-weight: 500;
    color: var(--er-primary);
    text-decoration: none;
    text-transform: uppercase;
}
.er-drawer-nav > li > a:hover {
    color: var(--er-accent);
}

/* Accordion sub-menu */
.er-drawer-nav .sub-menu {
    list-style: none;
    padding: 0;
    margin: 0;
    display: none;
    background: rgba(0,0,0,0.02);
}
.er-drawer-nav .sub-menu.open {
    display: block;
}
.er-drawer-nav .sub-menu li a {
    display: block;
    padding: 0.6rem 1.25rem 0.6rem 2rem;
    font-size: 13px;
    color: var(--er-text);
    text-decoration: none;
}
.er-drawer-nav .sub-menu li a:hover {
    color: var(--er-accent);
}

/* Toggle accordion */
.er-drawer-nav li.menu-item-has-children {
    position: relative;
}
.er-drawer-toggle {
    position: absolute;
    top: 0;
    right: 0;
    width: 48px;
    height: 48px;
    background: none;
    border: none;
    border-left: 1px solid rgba(0,0,0,0.06);
    font-size: 14px;
    color: var(--er-text);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s;
}
.er-drawer-toggle.open {
    transform: rotate(45deg);
}
.er-drawer-nav .sub-menu .er-drawer-toggle {
    height: 38px;
    width: 40px;
    font-size: 12px;
}

/* ============================================================
   HERO & CAROUSEL
   ============================================================ */
.er-hero {
    position: relative;
    min-height: 82vh;
    display: flex;
    align-items: center;
    overflow: hidden;
    background: var(--er-primary);
}
.er-hero-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center 35%;
}
.er-hero-content {
    position: relative;
    z-index: 1;
    padding: 5rem 0;
    max-width: 620px;
}
.er-hero-kicker {
    font-size: 14px;
    font-weight: 900;
    text-transform: uppercase;
    color: var(--er-accent);
    display: block;
    margin-bottom: 1.25rem;
}
.er-hero-title {
    font-family: var(--er-f-disp);
    font-size: clamp(2.6rem, 5vw, 4rem);
    color: var(--er-white);
    line-height: 1.08;
    margin-bottom: 1.5rem;
}
.er-hero-sub {
    font-size: 18px;
    font-weight: 900;
    line-height: 1.75;
    color: var(--er-white);
    max-width: 48ch;
    margin-bottom: 2.5rem;
}

/* Animazioni hero */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(24px);
    }
    to   {
        opacity: 1;
        transform: translateY(0);
    }
}
.er-hero-content > * {
    animation: fadeUp 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.er-hero-content > *:nth-child(1) {
    animation-delay: 0.1s;
}
.er-hero-content > *:nth-child(2) {
    animation-delay: 0.25s;
}
.er-hero-content > *:nth-child(3) {
    animation-delay: 0.4s;
}
.er-hero-content > *:nth-child(4) {
    animation-delay: 0.55s;
}

.er-hero-carousel {
    position: relative;
    overflow: hidden;
    touch-action: pan-y;
}

.er-hero-carousel .carousel-inner,
.er-hero-carousel .carousel-item {
    height: var(--er-slide-height);
    min-height: var(--er-slide-min-height);
}

.er-slide {
    position: relative;
    display: flex;
    align-items: center;
    height: 100%;
    color: #fff;
}

.er-slide--light {
    color: var(--er-text, #131313);
}

.er-slide__bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    z-index: 0;
}

.er-slide__overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
}

.er-slide--dark .er-slide__overlay {
    background: linear-gradient(90deg, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0.2) 70%, rgba(0,0,0,0) 100%);
}

.er-slide--light .er-slide__overlay {
    background: linear-gradient(90deg, rgba(255,255,255,0.75) 0%, rgba(255,255,255,0.3) 70%, rgba(255,255,255,0) 100%);
}

.er-slide .container {
    position: relative;
    z-index: 2;
}

.er-slide__content {
    max-width: 640px;
    padding: 3rem 0;
}

.er-slide__kicker {
    display: inline-block;
    font-family: var(--er-f-body);
    text-transform: uppercase;
    font-size: 1.5rem;
    font-weight: 900;
    margin-bottom: 1rem;
    color: var(--er-accent);
}

.er-slide--light .er-slide__title {
    color: var(--er-title-light);
}

.er-slide--dark .er-slide__title {
    color: var(--er-surface);
}

.er-slide__title {
    font-family: var(--er-f-disp);
    font-size: clamp(2.6rem, 5vw, 6rem);
    line-height: 1.08;
    margin: 0 0 1rem;
}

.er-slide__discount {
    display: block;
    font-family: var(--er-f-body);
    font-size: clamp(3rem, 8vw, 5.5rem);
    font-weight: 900;
    line-height: 1;
    color: var(--er-accent, #f06526);
    margin: 0 0 1rem;
}

.er-slide__subtitle {
    font-size: 1.1rem;
    line-height: 1.5;
    margin: 0 0 1.5rem;
    opacity: 0.92;
}

.er-slide__coupon-code {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 1rem;
    margin: 0 0 1.5rem;
    border: 2px dashed currentColor;
    border-radius: 6px;
    font-size: 1rem;
}

.er-slide__coupon-label {
    text-transform: uppercase;
    font-size: 0.8rem;
    opacity: 0.85;
}

.er-slide__coupon-value {
    font-family: monospace;
    font-size: 1.3rem;
    font-weight: bold;
}

.er-slide__btn[aria-disabled="true"] {
    pointer-events: none;
    opacity: 0.5;
}

/* Varianti altezza */
.er-hero-carousel--tall {
    --er-slide-height: 92vh;
}

.er-hero-carousel--short {
    --er-slide-height: 50vh;
    --er-slide-min-height: 360px;
}

@media (max-width: 991.98px) {
    .er-hero {
        min-height: 65vh;
    }
    .er-hero-title {
        font-size: 2.4rem;
    }
    .er-hero-carousel .carousel-inner,
    .er-hero-carousel .carousel-item {
        --er-slide-height: 65vh;
    }
    .er-slide__title {
        font-size: 2.4rem;
    }
}
@media (max-width: 767.98px) {
    .er-hero {
        min-height: 55vh;
        overflow: visible;
    }
    .er-hero-content {
        padding: 2.5rem 0;
    }
    .er-hero-title {
        font-size: 2rem;
    }
    .er-hero-sub {
        margin-bottom: 1.5rem;
        font-size: 15px;
        line-height: 1.6;
    }
    .er-hero-carousel .carousel-inner,
    .er-hero-carousel .carousel-item {
        --er-slide-height: 55vh;
        --er-slide-min-height: 380px;
    }
    .er-hero-carousel .carousel-control-prev,
    .er-hero-carousel .carousel-control-next {
        display: none;
    }
    .er-slide__content {
        padding: 2rem 0;
    }
    .er-slide__title {
        font-size: 2.5rem;
    }
    .er-slide__kicker {
        font-size: 1rem;
    }
}

/* ============================================================
   SHIPPING BAND
   ============================================================ */
.er-shipping-band {
    background: var(--er-primary);
    border-top: 1px solid rgba(0,0,0,0.06);
    border-bottom: 1px solid rgba(0,0,0,0.06);
    padding: 1.25rem 0;
}
.er-ship-item {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 8px;
    font-size: 15px;
    font-weight: 500;
    color: var(--er-accent);
}
.er-ship-item i {
    font-size: 18px;
    color: var(--er-white);
}
@media (max-width: 991.98px) {
    .er-ship-item {
        justify-content: normal;
        text-align: start;
    }
}

/* ============================================================
   CATALOGO — GRIGLIA & CARD
   ============================================================ */
.er-cat-block {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    aspect-ratio: 1;
    border-radius: 20px;
    font-family: var(--er-f-body);
    background-color: var(--er-primary);
    text-decoration: none;
    text-align: center;
    transition: all 0.2s;
    padding: 0.5rem;
}
.er-cat-block-name {
    font-size: 30px;
    font-weight: 300;
    font-family: var(--er-f-disp);
    color: var(--er-accent);
}
.er-cat-block-count {
    font-size: 15px;
    font-weight: 400;
    color: var(--er-white);
}
.er-cat-block:hover {
    transform: translateY(-2px);
    background-color: var(--er-accent);
}
.er-cat-block:hover .er-cat-block-name {
    color: var(--er-primary);
}
.er-float-up {
    position: relative;
    z-index: 2;
    margin-top: -120px;
}
.er-catalogo {
    font-family: var(--er-f-disp);
    color: var(--er-accent);
}
.er-catalogo h2 {
    font-size: 100px;
}

/* Product card */
.er-product-card {
    background: var(--er-white);
    border: 1px solid rgba(0,0,0,0.07);
    border-radius: var(--er-radius-lg);
    overflow: hidden;
    transition: box-shadow 0.3s, transform 0.2s;
    height: 100%;
    display: flex;
    flex-direction: column;
}
.er-product-card:hover {
    box-shadow: 0 12px 40px rgba(63,21,31,0.1);
    transform: translateY(-3px);
}
.er-product-img {
    aspect-ratio: 3/4;
    background: var(--er-white);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}
.er-product-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 0.75rem;
}
.er-product-badges {
    position: absolute;
    top: 10px;
    left: 10px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    z-index: 2;
}
.er-badge {
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    padding: 4px 10px;
    border-radius: var(--er-radius);
    font-family: var(--er-f-body);
    display: inline-block;
}
.er-badge-promo {
    background: var(--er-accent-dark);
    color: #fff;
}
/* Le etichette Bio/Vegan/Cantina sostenibile sono icone PNG trasparenti
   (label-bio/vegan/cantina.png) e non hanno sfondo. */
.er-product-img .er-badge-icon,
.er-single-badges .er-badge-icon {
    height: auto;
    display: block;
    padding: 0;
}
.er-product-img .er-badge-icon {
    width: 40px;
}
.er-single-badges .er-badge-icon {
    width: 50px;
}

/* Prezzo minimo ultimi 30 giorni (Direttiva Omnibus). */
.er-omnibus-note {
    font-size: 12px;
    color: rgba(19,19,19,.65);
    margin-top: 4px;
    font-style: italic;
    line-height: 1.3;
}

.er-product-body {
    padding: 1rem 1.1rem 1.15rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    background-color: var(--er-surface-light);
}
.er-product-meta-top {
    font-size: 13px;
    font-weight: 600;
    color: var(--er-text);
    text-transform: uppercase;
    margin-bottom: 4px;
}
.er-product-name {
    font-size: 18px;
    font-weight: 800;
    color: var(--er-title-light);
    line-height: 1.25;
    margin-bottom: 0.5rem;
}
.er-product-name a {
    color: inherit;
    text-decoration: none;
}
.er-product-name a:hover {
    color: var(--er-accent);
}
.er-product-meta-bottom {
    font-size: 15px;
    color: var(--er-text);
    margin-bottom: auto;
    padding-bottom: 0.75rem;
}
.er-product-price-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding-top: 0.75rem;
    border-top: 1px solid rgba(0,0,0,0.06);
}
.er-product-price {
    font-size: 20px;
    font-weight: 800;
    color: var(--er-text);
    line-height: 1;
}
.er-product-price-tax {
    font-size: 12px;
    font-weight: 400;
    color: var(--er-text-muted);
    margin-left: 2px;
}
.er-product-price-old {
    font-size: 16px;
    font-weight: 800;
    text-decoration: line-through;
}
.er-product-price-liter {
    font-size: 11px;
    color: var(--er-text-muted);
    margin-top: 2px;
}
.btn-add-cart {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    background: var(--er-title-light);
    color: #fff;
    border: none;
    border-radius: var(--er-radius);
    font-family: var(--er-f-body);
    font-size: 15px;
    font-weight: 600;
    padding: 10px 16px;
    cursor: pointer;
    transition: background 0.2s;
    margin-top: 0.75rem;
    text-align: center;
    text-decoration: none;
}
.btn-add-cart.loading {
    opacity: 0.6;
    pointer-events: none;
}
.btn-add-cart--disabled {
    background: #646361;
    cursor: not-allowed;
    pointer-events: none;
}
/* Nasconde il link "Visualizza carrello" aggiunto da WC dopo add-to-cart AJAX */
.er-product-card .added_to_cart,
.er-product-card .wc-forward {
    display: none !important;
}
.btn-add-cart.added::after {
    content: "\f26b";
    font-family: bootstrap-icons;
    margin-left: 0.5rem;
}
.btn-add-cart:hover {
    background: #d9561e;
    color: #fff;
}

/* ============================================================
   PRODUCTS CAROUSEL (Swiper homepage)
   ============================================================ */
.er-products-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 1.25rem;
}
.er-products-nav {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}
.er-swiper-prev,
.er-swiper-next {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid rgba(0,0,0,0.15);
    background: var(--er-white);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s;
    font-size: 18px;
    color: var(--er-text);
}
.er-swiper-prev:hover,
.er-swiper-next:hover {
    background: var(--er-title-light);
    border-color: var(--er-title-light);
    color: #fff;
}
.er-swiper-prev.swiper-button-disabled,
.er-swiper-next.swiper-button-disabled {
    opacity: 0.3;
    pointer-events: none;
}
.er-products-swiper {
    overflow: hidden;
}
.er-products-swiper .swiper-slide {
    height: auto;
}
.er-products-swiper .er-product-card {
    height: 100%;
}

/* ============================================================
   SCHEDA SINGOLO PRODOTTO
   ============================================================ */
/* Badge overlay su scheda singola prodotto. */
.er-single-product {
    position: relative;
}
.er-sp-header {
    flex: 0 0 100%;
    padding: 0 var(--bs-gutter-x, 0.75rem);
    margin-bottom: 1rem;
}

/* --- Galleria --- */
.er-sp-main-image {
    border-radius: var(--er-radius);
    overflow: hidden;
    text-align: center;
}
.er-sp-main-image img {
    width: 100%;
    height: auto;
    object-fit: contain;
    max-height: 560px;
}
.er-sp-thumbs {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.75rem;
    flex-wrap: wrap;
}
.er-sp-thumb {
    width: 72px;
    height: 72px;
    border: 2px solid transparent;
    border-radius: var(--er-radius);
    overflow: hidden;
    cursor: pointer;
    background: #f8f7f5;
    padding: 0;
    transition: border-color 0.2s;
}
.er-sp-thumb.is-active,
.er-sp-thumb:hover {
    border-color: var(--er-primary);
}
.er-sp-thumb img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}
.er-single-badges {
    position: absolute;
    top: 16px;
    left: 16px;
    z-index: 2;
}

/* --- Dettagli (colonna dx) --- */
.er-sp-title {
    font-family: var(--er-f-disp);
    color: var(--er-title-light);
    font-size: 2rem;
    line-height: 1.15;
    margin: 0 0 1.5rem;
}
.er-sp-producer {
    font-family: var(--er-f-body);
    font-size: 1.15rem;
    font-weight: 600;
    margin: 0 0 1rem 0;
}
.er-sp-producer a {
    color: var(--er-primary);
    text-decoration: none;
}
.er-sp-producer a:hover {
    text-decoration: underline;
}
.er-sp-icon,
.er-sp-regione-icon {
    width: 22px;
    height: auto;
}
.er-sp-meta-line {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 18px;
    color: var(--er-text-muted);
    margin-bottom: 0.5rem;
}
.er-sp-meta-line a {
    color: inherit;
    text-decoration: none;
}
.er-sp-meta-line a:hover {
    color: var(--er-primary);
}
.er-sp-meta-line .bi-geo-alt {
    font-size: 0.9em;
    margin-right: 0.15rem;
}
.er-sp-specs-inline {
    color: var(--er-text-muted);
}
.er-sp-sep {
    margin: 0 0.4rem;
    opacity: 0.4;
}

/* Uvaggio */
.er-sp-uvaggio {
    margin-bottom: 1rem;
    padding: 0.75rem 0;
    border-top: 1px solid rgba(0,0,0,0.06);
}
.er-sp-uvaggio-label {
    display: block;
    font-size: 0.8rem;
    text-transform: uppercase;
    color: var(--er-text-muted);
    margin-bottom: 0.35rem;
}
.er-sp-uvaggio-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}
.er-sp-uvaggio-item {
    background: #f3f1ee;
    padding: 0.25rem 0.6rem;
    border-radius: var(--er-radius);
    font-size: 0.9rem;
}
.er-sp-uvaggio-item small {
    color: var(--er-text-muted);
    margin-left: 0.25rem;
}

/* Prezzo */
.er-sp-price-block {
    padding: 1rem 0;
    border-top: 1px solid rgba(0,0,0,0.06);
    margin-bottom: 0.5rem;
}
.er-sp-price {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--er-title-light);
    line-height: 1.2;
}
.er-sp-price del {
    font-size: 1.1rem;
    color: var(--er-text-muted);
    font-weight: 400;
}
.er-sp-price ins {
    text-decoration: none;
}
.er-sp-price .er-product-price-tax {
    font-size: 0.85rem;
}
.er-sp-price-per-litre {
    font-size: 0.85rem;
    color: var(--er-text-muted);
    margin-top: 0.15rem;
}
.er-sp-omnibus {
    font-size: 0.8rem;
    color: var(--er-text-muted);
    margin-top: 0.25rem;
}
.er-sp-stock {
    margin-top: 0.5rem;
    font-size: 0.9rem;
}
.er-sp-stock-ok {
    color: #2e7d32;
}
.er-sp-stock-no {
    color: #c62828;
}

.er-single-product .stock {
    display: none;
}
/* Form add to cart */
.er-single-product .cart {
    display: flex;
    align-items: stretch;
    gap: 0;
    margin-top: 0.5rem;
}
.er-single-product .cart .quantity {
    display: flex;
    align-items: stretch;
    width: auto;
}
.er-single-product .cart .quantity .er-qty-btn {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border: 1px solid #ccc;
    font-size: 20px;
    font-weight: 400;
    color: var(--er-text);
    cursor: pointer;
    transition: background 0.15s;
    padding: 0;
    line-height: 1;
}
.er-single-product .cart .quantity .er-qty-btn:hover {
    background: #f5f5f5;
}
.er-single-product .cart .quantity .er-qty-minus {
    border-radius: var(--er-radius) 0 0 var(--er-radius);
    border-right: none;
}
.er-single-product .cart .quantity .er-qty-plus {
    border-radius: 0 var(--er-radius) var(--er-radius) 0;
    border-left: none;
}
.er-single-product .cart .qty {
    width: 48px;
    height: 48px;
    text-align: center;
    border: 1px solid #ccc;
    border-radius: 0;
    padding: 0;
    font-size: 16px;
    font-weight: 600;
    -moz-appearance: textfield;
    appearance: textfield;
}
.er-single-product .cart .qty::-webkit-inner-spin-button,
.er-single-product .cart .qty::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}
.single-product .single_add_to_cart_button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 1;
    background: var(--er-title-light);
    color: #fff;
    border: none;
    border-radius: var(--er-radius);
    font-family: var(--er-f-body);
    font-size: 16px;
    font-weight: 600;
    height: 48px;
    padding: 0 28px;
    margin-left: 0.75rem;
    cursor: pointer;
    transition: background 0.2s;
    text-decoration: none;
}
.single-product .single_add_to_cart_button::before {
    content: "\f244";
    font-family: bootstrap-icons;
    margin-right: 0.5rem;
}
.single-product .single_add_to_cart_button:hover {
    background: var(--er-primary);
    color: #fff;
}
.er-secure-payment {
    display: flex;
    align-items: center;
    justify-content: end;
    gap: 0.35rem;
    margin-top: 0.6rem;
    font-size: 14px;
    color: var(--er-text-muted);
}
.er-secure-payment i {
    font-size: 16px;
}

/* Note di regola prodotto (esclusione promo, limite per cliente). */
.er-product-rule {
    margin: 0.75rem 0;
    font-size: 14px;
    line-height: 1.4;
}
.er-rule-no-promo {
    color: var(--er-text);
    display: flex;
    align-items: center;
    gap: 8px;
}
.er-rule-no-promo .bi-star-fill {
    color: #d4a017;
    font-size: 18px;
}
.er-rule-limit {
    color: #b21e2a;
    font-weight: 600;
}
/* Accordion singolo prodotto */
.er-sp-accordions {
    margin-top: 1.5rem;
    border-top: 1px solid rgba(0,0,0,0.08);
}
.er-sp-acc-item {
    border-bottom: 1px solid rgba(0,0,0,0.08);
}
.er-sp-acc-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 1rem 0;
    background: none;
    border: none;
    font-family: var(--er-f-body);
    font-size: 16px;
    font-weight: 600;
    color: var(--er-text);
    cursor: pointer;
}
.er-sp-acc-toggle i {
    font-size: 14px;
    transition: transform 0.25s;
}
.er-sp-acc-toggle[aria-expanded="true"] i {
    transform: rotate(180deg);
}
.er-sp-acc-body {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}
.er-sp-acc-body.is-open {
    max-height: 2000px;
}
.er-sp-acc-content {
    padding: 0 0 1rem;
    font-size: 15px;
    line-height: 1.65;
    color: var(--er-text-muted);
}
.er-sp-acc-content p:last-child {
    margin-bottom: 0;
}

/* Spacing prodotti correlati */
.er-related-products {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(0,0,0,0.06);
}

@media (min-width: 992px) {
    .er-sp-row {
        display: grid !important;
        grid-template-columns: 1fr 1fr;
        column-gap: var(--bs-gutter-x, 1.5rem);
        margin: 0;
    }
    .er-sp-row > * {
        padding-left: 0;
        padding-right: 0;
        width: auto;
        max-width: none;
        flex: unset;
    }
    .er-sp-header {
        grid-column: 2;
        grid-row: 1;
        margin-bottom: 0;
    }
    .er-single-product .col-img {
        grid-column: 1;
        grid-row: 1 / 3;
        position: sticky;
        top: calc(var(--er-sticky-header-h, 120px) + 20px);
        align-self: start;
    }
    .er-sp-row > .col-lg-6:not(.col-img) {
        grid-column: 2;
        grid-row: 2;
    }
}
@media (max-width: 767.98px) {
    .single-product .single_add_to_cart_button {
        font-size: 0;
    }
    .single-product .single_add_to_cart_button::before {
        font-size: 16px;
    }
    .single-product .single_add_to_cart_button::after {
        content: 'Aggiungi';
        font-size: 16px;
    }
}

/* ============================================================
   CARRELLO E PAGAMENTO
   ============================================================ */
/* Notice WooCommerce — stile unificato */
.woocommerce-message,
.woocommerce-error,
.woocommerce-info {
    background: var(--er-surface);
    color: var(--er-primary);
    border: none;
    border-radius: var(--er-radius-lg);
    padding: 1rem 1.25rem;
    font-size: 14px;
    line-height: 1.5;
    margin: 2rem 0;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem 1rem;
}
.woocommerce-message::before,
.woocommerce-error::before,
.woocommerce-info::before {
    display: none;
}
.woocommerce-message a.wc-forward,
.woocommerce-info a.wc-forward,
.woocommerce-error a.wc-forward {
    order: 2;
    margin-left: auto;
    margin-top: 0;
    padding: 5px 16px !important;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    transition: background 0.2s;
    float: none;
    color: var(--er-accent);
}

.woocommerce-message a.wc-forward:hover,
.woocommerce-info a.wc-forward:hover,
.woocommerce-error a.wc-forward:hover {
    background: rgba(255,255,255,0.15) !important;
}
.woocommerce-error li,
.woocommerce-info li,
.woocommerce-message li {
    display: flex;
    align-items: center;
}
.woocommerce-message:focus,
.woocommerce-error:focus,
.woocommerce-info:focus {
    outline: none;
    box-shadow: none;
}

.woocommerce-cart .entry-title,
.woocommerce-checkout .entry-title {
    font-family: var(--er-f-disp);
    color: var(--er-title-light);
    font-size: 3rem;
    margin-bottom: 1rem;
}

/* --- Tabella carrello --- */
.woocommerce-cart table.shop_table {
    border-collapse: collapse;
    width: 100%;
    border: none;
    border-radius: var(--er-radius-lg);
}
.woocommerce-cart table.shop_table thead th {
    font-weight: 900;
    text-transform: uppercase;
    color: var(--er-title-light);
    border-bottom: 2px solid rgba(0,0,0,0.08);
    padding: 12px 8px;
}
.woocommerce-cart table.shop_table td {
    padding: 16px 8px;
    vertical-align: middle;
    border-bottom: 1px solid rgba(0,0,0,0.06);
}
.woocommerce-cart table.shop_table .product-name a {
    text-decoration: none;
    color: var(--er-title-light);
    font-size: 16px;
    font-weight: 500;
}
.woocommerce-cart table.shop_table .product-name a:hover {
    color: var(--er-accent);
}
.woocommerce-cart table.shop_table .product-thumbnail img {
    width: 80px;
    height: auto;
    border-radius: var(--er-radius-lg);
}
.woocommerce-cart table.shop_table .product-price,
.woocommerce-cart table.shop_table .product-subtotal {
    font-size: 16px;
}
.woocommerce-cart table.shop_table .product-remove a.remove {
    color: #999 !important;
    font-size: 0 !important;
    text-decoration: none;
    display: inline-flex !important;
    align-items: center;
    gap: 4px;
    width: auto !important;
    height: auto !important;
    transition: color 0.2s;
}
.woocommerce-cart table.shop_table .product-remove a.remove::before {
    content: "\F5DE";
    font-family: "bootstrap-icons";
    font-size: 14px;
}
.woocommerce-cart table.shop_table .product-remove a.remove::after {
    content: "Rimuovi";
    font-family: var(--er-f-body);
    font-size: 13px;
    font-weight: 500;
}
.woocommerce-cart table.shop_table .product-remove a.remove:hover {
    color: var(--er-accent) !important;
    background: transparent !important;
}

/* Selettore quantità */
.woocommerce .quantity .qty {
    border: 1px solid #ccc;
    border-radius: 0;
    padding: 6px 10px;
    width: 60px;
    text-align: center;
    font-size: 14px;
    font-family: var(--er-f-body);
}
.woocommerce .quantity .qty:focus {
    border-color: var(--er-title-light);
    outline: none;
    box-shadow: 0 0 0 2px rgba(146, 49, 72, 0.15);
}

/* Nascondi la variazione nel carrello */
.woocommerce-cart table.shop_table .product-name .variation {
    display: none;
}

/* Coupon */
.woocommerce-cart .coupon {
    display: flex;
    flex-wrap: wrap;
    gap: 0;
}
.woocommerce-cart .coupon #coupon_code {
    border: 1px solid #ccc;
    border-radius: var(--er-radius) 0 0 var(--er-radius);
    padding: 12px 24px;
    font-size: 15px;
    font-family: var(--er-f-body);
    min-width: 220px;
    flex: 1;
}
.woocommerce-cart .coupon #coupon_code:focus {
    border-color: var(--er-primary);
    outline: none;
    box-shadow: none;
}
.woocommerce-cart .coupon .button {
    background: var(--er-accent-dark);
    color: var(--er-white);
    border: none;
    border-radius: 0 var(--er-radius) var(--er-radius) 0;
    padding: 12px 28px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}
.woocommerce-cart .coupon .button:hover {
    background: var(--er-primary);
}

/* Errore coupon: sotto il blocco input, non in linea */
.woocommerce-cart .woocommerce-error,
.woocommerce-cart .woocommerce-message {
    width: 100%;
    flex-basis: 100%;
    order: 10;
}

/* Link rimuovi coupon */
.woocommerce-cart .woocommerce-remove-coupon {
    color: var(--er-accent);
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    transition: color 0.2s;
}
.woocommerce-cart .woocommerce-remove-coupon:hover {
    color: var(--er-primary);
}

/* Aggiorna carrello */
.woocommerce-cart button[name="update_cart"] {
    background: var(--er-title-light);
    color: var(--er-white);
    border: none;
    border-radius: var(--er-radius);
    padding: 10px 24px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, opacity 0.2s;
}
.woocommerce-cart button[name="update_cart"]:hover {
    background: var(--er-primary);
}
.woocommerce-cart button[name="update_cart"]:disabled {
    opacity: 0.4;
    cursor: default;
}

/* Totali carrello */
.woocommerce-cart .cart_totals {
    border-radius: var(--er-radius-lg);
}
.woocommerce-cart .cart_totals h2 {
    font-weight: 900;
    text-transform: uppercase;
    color: var(--er-title-light);
    font-size: 1rem;
    margin-bottom: 1rem;
}
.woocommerce-cart .cart_totals table.shop_table th {
    font-weight: 600;
    color: var(--er-title-light);
}

/* Calcolatore spedizione — icona truck */
.woocommerce-cart .cart-collaterals .shipping-calculator-button::after {
    content: none;
}
.woocommerce-cart .cart-collaterals .shipping-calculator-button::before {
    font-family: "bootstrap-icons";
    content: "\f5ea";
    margin-right: 0.4em;
}

/* Calcolatore spedizione — input e bottone */
.woocommerce form .shipping-calculator-form .form-row .input-text {
    border: 1px solid #ccc;
    border-radius: var(--er-radius);
    padding: 10px 16px;
    font-size: 14px;
    font-family: var(--er-f-body);
    transition: border-color 0.2s;
    width: 100%;
    height: 42px;
    box-sizing: border-box;
}
.woocommerce form .shipping-calculator-form .form-row .input-text:focus {
    border-color: var(--er-title-light);
    outline: none;
    box-shadow: 0 0 0 2px rgba(146, 49, 72, 0.15);
}
.shipping-calculator-form button[name="calc_shipping"] {
    background: var(--er-title-light);
    color: #fff;
    border: none;
    border-radius: var(--er-radius);
    padding: 10px 28px;
    font-size: 14px;
    font-family: var(--er-f-body);
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    margin-top: 0.5rem;
}
.shipping-calculator-form button[name="calc_shipping"]:hover {
    background: var(--er-accent-dark);
}

/* Procedi al pagamento */
.woocommerce-cart .wc-proceed-to-checkout .checkout-button {
    background: var(--er-accent-dark);
    color: var(--er-white) !important;
    border: none;
    border-radius: var(--er-radius);
    padding: 14px 32px;
    font-size: 15px;
    font-weight: 600;
    transition: background 0.2s;
    text-decoration: none;
    display: block;
    text-align: center;
}
.woocommerce-cart .wc-proceed-to-checkout .checkout-button:hover {
    background: var(--er-primary);
}

/* Carrello vuoto */
.er-cart-empty-text {
    font-size: 16px;
    color: var(--er-title-light);
    margin-bottom: 2rem;
}

/* Cross-sells e prodotti suggeriti */
.woocommerce-cart .er-cross-sells,
.woocommerce-cart .er-products {
    margin-top: 2rem;
}

/* --- Checkout --- */
.woocommerce-checkout h3 {
    color: var(--er-title-light);
    font-size: 2rem;
    font-weight: 900;
    margin-bottom: 1.25rem;
}
.woocommerce-checkout .woocommerce-billing-fields,
.woocommerce-checkout .woocommerce-shipping-fields,
.woocommerce-checkout .woocommerce-additional-fields {
    margin-bottom: 2.5rem;
}
.woocommerce-checkout .woocommerce-checkout-review-order {
    background: var(--er-surface-light);
    border-radius: var(--er-radius-lg);
    padding: 2rem;
}
.woocommerce-checkout #ship-to-different-address {
    font-weight: 600;
    color: var(--er-text);
    font-size: 16px;
}
.woocommerce-checkout #ship-to-different-address-checkbox {
    display: inline;
    margin: -2px 8px 0 0;
    text-align: center;
    vertical-align: middle;
}
.woocommerce form .form-row {
    margin-bottom: 20px;
}
.woocommerce form .form-row label {
    font-weight: 600;
}
.woocommerce form.woocommerce-checkout .form-row .input-text,
.woocommerce form.woocommerce-checkout .form-row select,
.woocommerce form.woocommerce-checkout .form-row textarea,
.woocommerce form.woocommerce-checkout .select2-container--default .select2-selection--single {
    border: 1px solid #ccc;
    border-radius: var(--er-radius);
    padding: 10px 16px;
    font-size: 14px;
    font-family: var(--er-f-body);
    transition: border-color 0.2s;
    width: 100%;
    height: 42px;
    box-sizing: border-box;
}
.woocommerce form.woocommerce-checkout .form-row .input-text:focus,
.woocommerce form.woocommerce-checkout .form-row select:focus,
.woocommerce form.woocommerce-checkout .form-row textarea:focus {
    border-color: var(--er-title-light);
    outline: none;
    box-shadow: 0 0 0 2px rgba(146, 49, 72, 0.15);
}
.woocommerce-checkout .select2-container--default .select2-selection--single {
    display: flex;
    align-items: center;
}
.woocommerce-checkout .select2-container--default .select2-selection--single .select2-selection__rendered {
    line-height: 40px;
    padding-left: 16px;
}
.woocommerce-checkout .select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 100%;
}
.woocommerce-checkout #place_order {
    background: var(--er-accent-dark);
    color: var(--er-white);
    border: none;
    border-radius: var(--er-radius);
    padding: 14px 32px;
    font-size: 15px;
    font-weight: 600;
    transition: background 0.2s;
    width: 100%;
    cursor: pointer;
}
.woocommerce-checkout #place_order:hover {
    background: var(--er-primary);
}
.woocommerce-checkout .wc_payment_methods {
    border-radius: var(--er-radius-lg) !important;
}
.woocommerce-checkout .wc_payment_method {
    border-radius: var(--er-radius-lg);
}
.woocommerce-checkout .wc_payment_method label {
    font-weight: 500;
    cursor: pointer;
}
#add_payment_method #payment div.payment_box,
.woocommerce-cart #payment,
.woocommerce-checkout #payment {
    background: var(--er-surface);
}
#add_payment_method #payment,
.woocommerce-cart #payment div.payment_box,
.woocommerce-checkout #payment div.payment_box {
    background: var(--er-surface-light);
}
.woocommerce-checkout .payment_box {
    border-radius: var(--er-radius-lg);
}
.woocommerce-cart #payment div.payment_box::before,
.woocommerce-checkout #payment div.payment_box::before {
    border-color: var(--er-surface-light);
    border-right-color: transparent;
    border-left-color: transparent;
    border-top-color: transparent;
}
#add_payment_method #payment div.payment_box::before {
    border-color: var(--er-surface);
    border-right-color: transparent;
    border-left-color: transparent;
    border-top-color: transparent;
}
/* Checkout: coupon */
.woocommerce-checkout .checkout_coupon {
    border-radius: var(--er-radius-lg);
}
.woocommerce-checkout .checkout_coupon #coupon_code {
    border: 1px solid #ccc;
    border-radius: var(--er-radius) 0 0 var(--er-radius);
    padding: 10px 24px;
    font-size: 14px;
}
.woocommerce-checkout .checkout_coupon .button {
    background: var(--er-accent-dark);
    color: var(--er-white);
    border: none;
    border-radius: 0 var(--er-radius) var(--er-radius) 0;
    padding: 10px 24px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}
.woocommerce-checkout .checkout_coupon .button:hover {
    background: var(--er-primary);
}

/* Checkout: tabella riepilogo */
.woocommerce-checkout .woocommerce-notice {
    font-size: 2rem;
    font-weight: 900;
    color: var(--er-title-light);
    margin-bottom: 0.35rem;
}
.woocommerce-checkout table.shop_table {
    border: none;
    border-radius: var(--er-radius-lg);
}
.woocommerce-checkout table.shop_table thead th {
    font-weight: 900;
    text-transform: uppercase;
    color: var(--er-title-light);
}

/* Riepilogo ordine */
.woocommerce-checkout .woocommerce ul.order_details {
    background-color: var(--er-surface-light);
    border-radius: 10px;
    padding: 1em;
    margin-bottom: 2em;
}
.woocommerce-checkout .woocommerce ul.order_details li {
    font-size: 0.9em;
    border-right: 1px dashed var(--er-title-light);
}
.woocommerce-checkout h2 {
    font-size: 1.6em;
    color: var(--er-accent);
    font-weight: 900;
}
#add_payment_method .cart-collaterals .shipping-calculator-button,
.woocommerce-cart .cart-collaterals .shipping-calculator-button,
.woocommerce-checkout .cart-collaterals .shipping-calculator-button {
    display: flex;
}
/* Link prodotti nella tabella ordine */
.woocommerce-table__product-name.product-name a {
    color: var(--er-title-light);
    text-decoration: none;
    font-weight: 500;
}
.woocommerce-table__product-name.product-name a:hover {
    color: var(--er-accent);
}

/* --- Il mio account --- */
.woocommerce-MyAccount-navigation {
    margin-bottom: 2rem;
}
.woocommerce-MyAccount-navigation ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}
.woocommerce-MyAccount-navigation ul li a {
    display: block;
    padding: 10px 16px;
    border-radius: var(--er-radius-lg);
    color: var(--er-title-light);
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    transition: background 0.2s, color 0.2s;
}
.woocommerce-MyAccount-navigation ul li a:hover {
    background: var(--er-surface-light);
}
.woocommerce-MyAccount-navigation ul li.is-active a {
    background: var(--er-title-light);
    color: var(--er-white);
}
.woocommerce-MyAccount-navigation ul li.woocommerce-MyAccount-navigation-link--downloads,
.woocommerce-MyAccount-navigation ul li.woocommerce-MyAccount-navigation-link--dashboard {
    display: none;
}
.woocommerce-MyAccount-navigation-link--customer-logout a::before {
    font-family: "bootstrap-icons";
    content: "\f1c5";
    margin-right: 0.35em;
}
.woocommerce-MyAccount-content {
    font-size: 15px;
}
.woocommerce-MyAccount-content h2,
.woocommerce-MyAccount-content h3 {
    font-family: var(--er-f-body);
    font-size: 26px;
    font-weight: 900;
    color: var(--er-title-light);
    margin-bottom: 0.35rem;
}
.woocommerce-MyAccount-content .woocommerce-Address-title a,
.woocommerce-MyAccount-content a.edit {
    color: var(--er-accent);
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    transition: color 0.2s;
}
.woocommerce-MyAccount-content .woocommerce-Address-title a::before {
    font-family: "bootstrap-icons";
    content: "\f4c9";
    margin-right: 0.35em;
}
.woocommerce-MyAccount-content .woocommerce-Address-title a:hover,
.woocommerce-MyAccount-content a.edit:hover {
    color: var(--er-primary);
}
.woocommerce-MyAccount-content table.shop_table {
    border: none;
    border-radius: var(--er-radius-lg);
    font-size: 1em;
}
.woocommerce-MyAccount-content table.shop_table td,
.woocommerce-MyAccount-content table.shop_table th {
    padding: 14px 16px;
}
.woocommerce-MyAccount-content table.shop_table .button {
    padding: 6px 16px;
    font-size: 13px;
}
.woocommerce-MyAccount-content .button,
.woocommerce-MyAccount-content .woocommerce-Button {
    background: var(--er-accent-dark);
    color: var(--er-white) !important;
    border: none;
    border-radius: var(--er-radius);
    padding: 10px 24px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    text-decoration: none;
}
.woocommerce-MyAccount-content .button:hover,
.woocommerce-MyAccount-content .woocommerce-Button:hover {
    background: var(--er-primary);
    color: var(--er-white);
}
.woocommerce-MyAccount-content .form-row .input-text.form-control,
.woocommerce-MyAccount-content .form-row select.form-control,
.woocommerce-MyAccount-content .form-row textarea.form-control,
.woocommerce-MyAccount-content .woocommerce-Input.form-control,
.woocommerce-MyAccount-content .woocommerce-Input {
    border: 1px solid #ccc;
    border-radius: var(--er-radius);
    padding: 10px 16px;
    font-size: 14px;
    font-family: var(--er-f-body);
    width: 100%;
    height: 42px;
    box-sizing: border-box;
}
.woocommerce-MyAccount-content .form-row .input-text.form-control:focus,
.woocommerce-MyAccount-content .form-row select.form-control:focus,
.woocommerce-MyAccount-content .form-row textarea.form-control:focus,
.woocommerce-MyAccount-content .woocommerce-Input:focus {
    border-color: var(--er-title-light);
    outline: none;
    box-shadow: 0 0 0 2px rgba(146, 49, 72, 0.15);
}
.woocommerce-MyAccount-content legend {
    font-size: 1rem;
    font-weight: bold;
    margin-top: 15px;
}
.woocommerce .woocommerce-MyAccount-content address,
.woocommerce .woocommerce-MyAccount-content .woocommerce-customer-details address,
.woocommerce .woocommerce-customer-details address {
    border: 3px solid var(--er-surface-light);
    border-radius: var(--er-radius-lg);
    padding: 20px;
}
.woocommerce-MyAccount-content em {
    display: block;
    font-size: 0.85em;
}
/* Login / Register form */
.woocommerce form.login,
.woocommerce form.register {
    border: 3px solid var(--er-surface-light);
    border-radius: var(--er-radius-lg);
}
.woocommerce-account .u-columns.col2-set > .u-column1 > h2,
.woocommerce-account .u-columns.col2-set > .u-column2 > h2 {
    font-weight: 900;
    color: var(--er-title-light);
}
.woocommerce form.login input.form-control,
.woocommerce form.login input.input-text,
.woocommerce form.register input.form-control,
.woocommerce form.register input.input-text,
.woocommerce form.lost_reset_password input.form-control,
.woocommerce form.lost_reset_password input.input-text {
    border: 1px solid #ccc;
    border-radius: var(--er-radius);
    padding: 10px 16px;
    font-size: 14px;
    font-family: var(--er-f-body);
}
.woocommerce form.login input.form-control:focus,
.woocommerce form.login input.input-text:focus,
.woocommerce form.register input.form-control:focus,
.woocommerce form.register input.input-text:focus,
.woocommerce form.lost_reset_password input.form-control:focus,
.woocommerce form.lost_reset_password input.input-text:focus {
    border-color: var(--er-title-light);
    outline: none;
    box-shadow: 0 0 0 2px rgba(146, 49, 72, 0.15);
}
.woocommerce form.login .form-row:has(.woocommerce-form-login__submit) {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
}
.woocommerce form.login .woocommerce-form-login__submit {
    order: -1;
    background: var(--er-accent-dark);
    color: var(--er-white);
    border: none;
    border-radius: var(--er-radius);
    padding: 10px 24px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}
.woocommerce form.login .woocommerce-form-login__submit:hover {
    background: var(--er-primary);
    color: var(--er-white);
}

@media (max-width: 767.98px) {
    .woocommerce-cart .coupon {
        gap: 8px;
    }
    .woocommerce-cart .coupon #coupon_code {
        min-width: 0;
        width: 100%;
        border-radius: var(--er-radius);
    }
    .woocommerce-cart .coupon .button {
        width: 100%;
        border-radius: var(--er-radius);
        text-align: center;
    }
}

/* ============================================================
   GRAVITY FORMS
   ============================================================ */
.gform_wrapper {
    --gf-radius: var(--er-radius);
    --gf-color-primary: var(--er-title-light);
    --gf-ctrl-border-color: #ccc;
    --gf-ctrl-bg-color: #fff;
}
.gform_wrapper input:not([type="submit"]):not([type="hidden"]):not([type="checkbox"]):not([type="radio"]),
.gform_wrapper select,
.gform_wrapper textarea {
    border: 1px solid #ccc !important;
    border-radius: var(--er-radius) !important;
    padding: 10px 16px !important;
    font-size: 14px;
    font-family: var(--er-f-body);
    height: 42px !important;
    transition: border-color 0.2s;
}
.gform_wrapper textarea {
    height: auto !important;
    min-height: 140px;
    border-radius: var(--er-radius-lg) !important;
    padding: 12px 16px !important;
}
.gform_wrapper input:not([type="submit"]):focus,
.gform_wrapper select:focus,
.gform_wrapper textarea:focus {
    border-color: var(--er-title-light) !important;
    outline: none;
    box-shadow: 0 0 0 2px rgba(146, 49, 72, 0.15) !important;
}
.gform_wrapper .gfield_label {
    font-weight: 600;
    color: var(--er-text);
}
.gform_wrapper .gfield .gfield_description,
.gform_wrapper .ginput_complex label {
    font-size: 12px;
    color: var(--er-text-muted);
}
.gform_wrapper .gfield_required {
    color: var(--er-accent) !important;
}
.gform_wrapper .gform-footer {
    display: flex;
    align-items: center;
}
.gform_wrapper .gform-footer > br,
.gform_wrapper .gform-footer > p:empty {
    display: none;
}
.gform_wrapper .gform_footer input[type="submit"],
.gform_wrapper .gform_button {
    background: var(--er-accent-dark) !important;
    color: var(--er-white) !important;
    border: none !important;
    border-radius: var(--er-radius) !important;
    padding: 10px 24px !important;
    font-size: 15px;
    font-weight: 600;
    font-family: var(--er-f-body);
    cursor: pointer;
    transition: background 0.2s;
    height: auto !important;
    align-self: center;
}
.gform_wrapper .gform_footer input[type="submit"]:hover,
.gform_wrapper .gform_button:hover {
    background: var(--er-primary) !important;
}
.gform_wrapper .ginput_container_name > p {
    flex: 1 1 0%;
    padding: 0 6px;
}
.gform_wrapper .ginput_container_name > p > .gform-grid-col {
    padding-left: 0;
    padding-right: 0;
}
.gform_wrapper .gfield_validation_message,
.gform_wrapper .gform_validation_errors {
    border-radius: var(--er-radius-lg);
}
.gform_required_legend {
    display: none;
}

/* ============================================================
   ABOUT
   ============================================================ */
/* Overlay da applicare via el_class sul bs_container */
.er-overlay-about {
    position: relative;
    min-height: 460px;
    display: flex;
    align-items: center;
    overflow: hidden;
    background-position: center 40% !important;
}
.er-overlay-about > .container {
    position: relative;
    z-index: 1;
}
.er-about-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 700px;
    margin: 0 auto;
    padding: 4rem 1rem;
}
.er-about-title {
    font-family: var(--er-f-disp);
    font-size: clamp(2rem, 4vw, 3rem);
    color: var(--er-white);
    line-height: 1.1;
    margin-bottom: 1.25rem;
}
.er-about-text {
    font-size: 15px;
    line-height: 1.75;
    color: rgba(255,255,255,0.6);
    margin-bottom: 2rem;
}
@media (max-width: 767.98px) {
    .er-overlay-about {
        min-height: 340px;
    }
    .er-about-title {
        font-size: 1.8rem;
    }
}

/* ============================================================
   NEWSLETTER
   ============================================================ */
.er-newsletter {
    background: var(--er-primary);
    padding: 3rem 0;
    position: relative;
    overflow: hidden;
}
.er-newsletter::before {
    content: '';
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(-45deg,
        transparent, transparent 4px,
        rgba(255,255,255,0.015) 4px, rgba(255,255,255,0.015) 8px);
    pointer-events: none;
}
.er-newsletter-title {
    font-family: var(--er-f-disp);
    font-size: 24px;
    color: var(--er-white);
    margin-bottom: 0.3rem;
}
.er-newsletter-sub {
    font-size: 13px;
    color: rgba(255,255,255,0.5);
}
.er-newsletter input[type="email"] {
    flex: 1;
    padding: 12px 16px;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: var(--er-radius);
    background: rgba(255,255,255,0.08);
    color: #fff;
    font-size: 14px;
    font-family: var(--er-f-body);
    outline: none;
    transition: border-color 0.2s;
}
.er-newsletter input[type="email"]::placeholder {
    color: rgba(255,255,255,0.35);
}
.er-newsletter input[type="email"]:focus {
    border-color: var(--er-accent);
}
.er-newsletter .btn-subscribe {
    background: var(--er-accent);
    color: #fff;
    border: none;
    border-radius: var(--er-radius);
    font-family: var(--er-f-body);
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    padding: 12px 24px;
    cursor: pointer;
    white-space: nowrap;
    flex-shrink: 0;
    transition: background 0.2s;
}
.er-newsletter .btn-subscribe:hover {
    background: #d9561e;
}
.er-newsletter-consent {
    display: flex;
    align-items: baseline;
    gap: 6px;
    font-size: 11px;
    color: rgba(255,255,255,0.3);
    margin-top: 0.5rem;
    cursor: pointer;
}
.er-newsletter-consent a {
    color: rgba(255,255,255,0.45);
    text-decoration: underline;
}
.er-newsletter-consent input[type="checkbox"] {
    accent-color: var(--er-accent);
    flex-shrink: 0;
}

/* ============================================================
   FOOTER
   ============================================================ */
.er-footer {
    background: var(--er-primary);
    color: var(--er-white);
    padding: 3.5rem 0 1.5rem;
}
.er-footer-logo {
    font-family: var(--er-f-disp);
    font-size: 20px;
    color: var(--er-accent);
    margin-bottom: 0.75rem;
}
.er-footer h6 {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--er-accent);
    margin-bottom: 1rem;
}
.er-footer ul {
    list-style: none;
    padding: 0;
    margin: 0;
}
.er-footer ul li {
    margin-bottom: 0.4rem;
}
.er-footer ul li a {
    color: var(--er-white);
    text-decoration: none;
    font-size: 15px;
    transition: color 0.2s;
    padding: 0;
}
.er-footer ul li a:hover,
.er-footer ul li a:focus {
    color: var(--er-accent);
}
.er-footer-bottom-area {
    border-top: 1px solid rgba(255,255,255,0.06);
    margin-top: 2.5rem;
    padding-top: 1.5rem;
    font-size: 12px;
    color: var(--er-white);
}
.er-footer-bottom-area .widget + .widget {
    margin-top: 1.25rem;
}
.er-footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.08);
    margin-top: 2.5rem;
    padding-top: 1.25rem;
    font-size: 12px;
    color: var(--er-white);
}
.er-footer-bottom a,
.er-footer-info a {
    text-decoration: none;
    color: var(--er-white);
}
.er-footer-social a {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 1px solid rgba(255,255,255,0.2);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--er-white);
    text-decoration: none;
    font-size: 14px;
    transition: all 0.2s;
}
.er-footer-social a:hover {
    color: var(--er-accent);
    border-color: var(--er-accent);
}
.er-footer-info {
    margin-bottom: 10px;
}
.er-footer-info-single {
    margin-bottom: 4px;
}
.er-pay-badge {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 4px;
    padding: 3px 10px;
    font-size: 10px;
    font-weight: 700;
    color: var(--er-white);
}
.er-guarantee-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
    font-size: 10px;
    line-height: 1.3;
}

/* ============================================================
   CUSTOM
   ============================================================ */
#siamo-enoteca-container {
    padding: 200px 0;
}
#siamo-enoteca {
    font-family: var(--er-f-disp);
    font-size: clamp(2rem, 4vw, 3rem);
    color: var(--er-white);
    line-height: 1.1;
    text-align: center;
    max-width: 700px;
    margin: 0 auto;
    padding: 4rem 1rem 0 1rem;
}
#siamo-enoteca-testo {
    max-width: 700px;
    margin: 0 auto 0 auto;
    padding: 1rem 1rem 3rem 1rem;
    color: var(--er-white);
    text-align: center;
    font-weight: 900;
    font-size: 18px;
}

/* ============================================================
   CATALOGO — FILTRI & SIDEBAR
   ============================================================ */
.er-catalog {
}
.er-catalog-page-title {
    font-family: var(--er-f-disp);
    color: var(--er-title-light);
    font-size: 3rem;
    margin-bottom: 1rem;
}
.er-catalog-sidebar .er-filters {
    font-family: 'DM Sans', sans-serif;
}
.er-filter-group {
    border-bottom: 1px solid rgba(19,19,19,0.08);
    padding: 0.75rem 0;
}
.er-filter-toggle {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding: 0.25rem 0;
    background: none;
    border: 0;
    font-weight: 900;
    text-transform: uppercase;
    color: var(--er-title-light);
    cursor: pointer;
}
.er-filter-toggle i {
    transition: transform 0.2s;
    font-size: 0.875rem;
}
.er-filter-group.is-collapsed .er-filter-toggle i {
    transform: rotate(-90deg);
}
.er-filter-body {
    padding-top: 0.5rem;
}
.er-filter-group.is-collapsed .er-filter-body {
    display: none;
}
.er-filter-search {
    position: relative;
    margin-bottom: 0.5rem;
}
.er-filter-search i {
    position: absolute;
    top: 50%;
    left: 0.5rem;
    transform: translateY(-50%);
    color: rgba(19,19,19,0.4);
    font-size: 0.8rem;
}
.er-filter-search-input {
    width: 100%;
    padding: 0.35rem 0.5rem 0.35rem 1.75rem;
    border: 1px solid rgba(19,19,19,0.15);
    border-radius: var(--er-radius);
    background: #fff;
    outline: none;
}
.er-filter-search-input:focus {
    border-color: var(--er-primary);
}
.er-filter-list {
    list-style: none;
    margin: 0;
    padding: 0;
    max-height: 260px;
    overflow-y: auto;
}
/* Item nascosti dal collapse "Mostra tutti": nascondi solo quando la lista
   e' collassata. Se la ricerca interna nasconde item, forza con .is-filtered. */
.er-filter-list.is-collapsed .er-filter-item.is-hidden {
    display: none;
}
.er-filter-list.is-filtered .er-filter-item.is-hidden {
    display: none;
}
.er-filter-item label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.2rem 0;
    color: #131313;
    cursor: pointer;
}
.er-filter-item input[type="checkbox"] {
    accent-color: #f06526;
    width: 0.9rem;
    height: 0.9rem;
    margin: 0;
}
.er-filter-name {
    flex: 1;
}
.er-filter-count {
    color: var(--er-text-muted);
    font-size: 0.75rem;
}
.er-filter-more {
    background: none;
    border: 0;
    padding: 0.35rem 0;
    font-size: 0.75rem;
    color: #f06526;
    text-decoration: underline;
    cursor: pointer;
}
.er-price-range {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}
.er-price-range span {
    color: rgba(19,19,19,0.4);
}
.er-price-range input {
    flex: 1;
    border-radius: var(--er-radius);
}

/* Griglia prodotti */
.er-catalog-grid {
    margin: 0;
}

/* Stato AJAX */
.er-filters.is-loading {
    opacity: 0.6;
    pointer-events: none;
    transition: opacity 0.15s;
}
.er-filter-item.is-empty {
    display: none !important;
}
.er-filter-item.is-oos {
    opacity: 0.5;
    order: 99;
}

/* Breadcrumb */
.er-breadcrumb {
    font-size: 0.75rem;
    color: rgba(19,19,19,0.55);
    margin-bottom: 1rem;
}
.er-breadcrumb a {
    color: rgba(19,19,19,0.55);
    text-decoration: none;
}
.er-breadcrumb a:hover {
    color: #f06526;
}
.er-breadcrumb-sep {
    margin: 0 0.35rem;
    color: rgba(19,19,19,0.3);
}

/* Toolbar ordinamento */
.er-catalog-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0 0.75rem;
    margin-bottom: 0.75rem;
    border-bottom: 1px solid rgba(19,19,19,0.08);
}
.er-catalog-results {
    font-size: 0.85rem;
    color: rgba(19,19,19,0.75);
    font-family: 'DM Sans', sans-serif;
}
.er-catalog-orderby {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.er-orderby-label {
    color: rgba(19,19,19,0.55);
    margin: 0;
}
.er-catalog-toolbar-controls {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}
.er-show-oos-label {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--er-text-muted);
    cursor: pointer;
    white-space: nowrap;
    margin: 0;
}
.er-show-oos-label input[type="checkbox"] {
    -webkit-appearance: none;
    appearance: none;
    width: 1em;
    height: 1em;
    border: 1px solid var(--er-text-muted);
    border-radius: 3px;
    cursor: pointer;
    vertical-align: middle;
}
.er-show-oos-label input[type="checkbox"]:checked {
    background-color: var(--er-accent);
    border-color: var(--er-accent);
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3e%3cpath fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='3' d='m6 10 3 3 6-6'/%3e%3c/svg%3e");
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;
}
.er-catalog-orderby select {
    min-width: 180px;
    border-radius: var(--er-radius);
}

/* Paginazione catalogo */
.er-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    margin-top: 2rem;
}
.er-pagination a,
.er-pagination span {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid rgba(0,0,0,0.15);
    background: var(--er-white);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 500;
    color: var(--er-text);
    text-decoration: none;
    transition: background 0.2s, border-color 0.2s, color 0.2s;
}
.er-pagination a:hover {
    background: var(--er-title-light);
    border-color: var(--er-title-light);
    color: #fff;
}
.er-pagination span.current {
    background: var(--er-primary);
    border-color: var(--er-primary);
    color: var(--er-white);
}
.er-pagination .dots {
    border: none;
    background: none;
    font-size: 14px;
    color: var(--er-text-muted);
    width: auto;
    pointer-events: none;
}

/* Filtri attivi come tag */
.er-active-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}
.er-active-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.25rem 0.6rem;
    background: var(--er-surface);
    color: var(--er-primary);
    border: 0;
    border-radius: var(--er-radius);
    cursor: pointer;
}
.er-active-tag:hover {
    background: #f06526;
    color: #fff;
}
.er-active-clear {
    background: none;
    border: 0;
    padding: 0.25rem 0.6rem;
    text-decoration: underline;
    cursor: pointer;
}

/* Infinite scroll sentinel */
.er-scroll-sentinel {
    display: flex;
    justify-content: center;
    padding: 2rem 0;
    min-height: 1px;
}
.er-scroll-sentinel.is-loading::after {
    content: '';
    width: 32px;
    height: 32px;
    border: 3px solid var(--er-border, #ddd);
    border-top-color: var(--er-primary);
    border-radius: 50%;
    animation: er-spin 0.6s linear infinite;
}
@keyframes er-spin { to { transform: rotate(360deg); } }
.er-scroll-sentinel.is-done { display: none; }

/* Risultato vuoto */
.er-catalog-empty {
    text-align: center;
    padding: 2rem;
    font-size: 0.9rem;
}

/* Mobile drawer filtri */
.er-mobile-filters-trigger {
    position: sticky;
    bottom: 1rem;
    z-index: 10;
    margin: 0 auto 1rem;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.6rem 1.2rem;
    background: #3f151f;
    color: #fff;
    border: 0;
    border-radius: 24px;
    font-family: 'DM Sans', sans-serif;
    font-size: 0.85rem;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
.er-sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid rgba(19,19,19,0.08);
}
.er-sidebar-title {
    font-family: 'Stardom', serif;
    font-size: 1.25rem;
    color: #3f151f;
}
.er-sidebar-close {
    background: none;
    border: 0;
    font-size: 1.1rem;
    cursor: pointer;
    color: #131313;
}
.er-sidebar-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.4);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s;
    z-index: 1040;
}
.er-sidebar-overlay.is-open {
    opacity: 1;
    pointer-events: auto;
}

@media (max-width: 991.98px) {
    .er-catalogo h2 {
        font-size: 70px;
    }
    .er-catalog-toolbar {
        flex-wrap: wrap;
        gap: 0.25rem 0;
    }
    .er-catalog-toolbar-controls {
        display: contents;
    }
    .er-show-oos-label {
        order: 1;
        margin-left: auto;
    }
    .er-catalog-orderby {
        order: 2;
        width: 100%;
        margin-top: 0.25rem;
    }
    .er-catalog-orderby select {
        min-width: 140px;
    }
    .er-catalog-sidebar {
        position: fixed;
        top: 0;
        left: 0;
        bottom: 0;
        width: 85vw;
        max-width: 360px;
        background: #fff;
        z-index: 1050;
        overflow-y: auto;
        transform: translateX(-100%);
        transition: transform 0.25s ease-out;
        padding: 0 1rem 1rem;
    }
    .er-catalog-sidebar.is-open {
        transform: translateX(0);
    }
    body.er-sidebar-open {
        overflow: hidden;
    }
    .er-sidebar-footer {
        position: sticky;
        bottom: 0;
        background: #fff;
        padding: 0.75rem 0;
        border-top: 1px solid #e5dece;
        margin-top: auto;
    }
    .er-sidebar-apply {
        display: block;
        width: 100%;
        padding: 0.75rem;
        background: #3f151f;
        color: #fff;
        border: none;
        border-radius: 6px;
        font-size: 0.95rem;
        font-weight: 600;
        cursor: pointer;
    }
}
@media (min-width: 992px) {
    .er-mobile-filters-trigger {
        display: none;
    }
    .er-sidebar-header {
        display: none;
    }
    .er-sidebar-overlay {
        display: none;
    }
}

/* ============================================================
   PRODUTTORI
   ============================================================ */
.er-produttori {
    padding: 1rem 0 3rem;
}
.er-produttori-toolbar {
    margin-bottom: 1.5rem;
    max-width: 420px;
}
.er-produttori-search {
    border-radius: 0;
    border: 1px solid var(--er-primary, #3f151f);
}

.er-produttori-index {
    position: sticky;
    top: var(--er-sticky-header-h, 120px);
    z-index: 5;
    background: var(--er-surface, #e5dece);
    padding: .75rem 0;
    margin-bottom: 2rem;
    border-top: 1px solid rgba(63,21,31,.15);
    border-bottom: 1px solid rgba(63,21,31,.15);
}
.er-produttori-index-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: .25rem .5rem;
    justify-content: center;
}
.er-produttori-index-item a,
.er-produttori-index-item span {
    display: inline-block;
    min-width: 2rem;
    padding: .25rem .4rem;
    text-align: center;
    font-weight: 600;
    text-decoration: none;
    color: var(--er-primary, #3f151f);
    border-radius: 2px;
    transition: background-color .15s ease;
}
.er-produttori-index-item a:hover {
    background: var(--er-accent, #f06526);
    color: #fff;
}
.er-produttori-index-item.is-disabled span {
    color: rgba(63,21,31,.25);
    cursor: default;
}

.er-produttori-group {
    margin-bottom: 2.5rem;
    scroll-margin-top: calc(var(--er-sticky-header-h, 120px) + 60px);
}
.er-produttori-letter {
    font-family: Stardom, serif;
    font-size: 2.5rem;
    color: var(--er-title-on-light, #923148);
    border-bottom: 2px solid var(--er-accent, #f06526);
    padding-bottom: .25rem;
    margin-bottom: 1rem;
}
.er-produttori-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: .25rem 1.5rem;
}
.er-produttori-item a {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: .5rem;
    padding: .4rem 0;
    color: var(--er-text, #131313);
    text-decoration: none;
    border-bottom: 1px dotted rgba(63,21,31,.15);
}
.er-produttori-item a:hover .er-produttori-name {
    color: var(--er-accent, #f06526);
}
.er-produttori-name {
    flex: 1;
}
.er-produttori-count {
    color: rgba(19,19,19,.55);
    font-size: .85rem;
}
.er-produttori-item.is-hidden {
    display: none;
}
.er-produttori-group.is-hidden {
    display: none;
}
.er-produttori-noresults {
    margin-top: 2rem;
    color: rgba(19,19,19,.6);
    font-style: italic;
}

@media (max-width: 767.98px) {
    .er-produttori-group {
        scroll-margin-top: calc(var(--er-sticky-header-h, 120px) + 140px);
    }
}

/* ============================================================
   HORECA
   ============================================================ */
body.is-horeca .er-hide-horeca {
    display: none !important;
}

/* ============================================================
   LANGUAGE SWITCHER (TranslatePress)
   ============================================================ */
.trp-shortcode-switcher__wrapper {
    --bg: transparent !important;
    --bg-hover: transparent !important;
    --text: #fff !important;
    --text-hover: rgba(255,255,255,.7) !important;
    --border: none !important;
    --border-width: 0 !important;
    --border-radius: 0 !important;
    --font-size: 13px !important;
    --transition-duration: 0s !important;
}
.trp-shortcode-switcher {
    padding-top: 0 !important;
    padding-bottom: 0 !important;
}
.trp-ls-dropdown .trp-ls-trigger,
.er-topbar .trp-ls-dropdown .trp-ls-dropdown__list a {
    padding: 0 !important;
    background: transparent !important;
    color: #fff !important;
    font-size: 13px !important;
    line-height: inherit !important;
    min-height: auto !important;
    gap: 6px !important;
}
.trp-ls-dropdown .trp-ls-trigger:hover,
.er-topbar .trp-ls-dropdown .trp-ls-dropdown__list a:hover {
    color: rgba(255,255,255,.7) !important;
}
.trp-ls-dropdown .trp-ls-dropdown__list {
    background: var(--er-primary, #3f151f) !important;
    border: none !important;
    min-width: auto !important;
    box-shadow: 0 4px 12px rgba(0,0,0,.3) !important;
    border-radius: 4px !important;
}
.trp-ls-dropdown .trp-ls-dropdown__list a {
    color: rgba(255,255,255,.8) !important;
    padding: 6px 12px !important;
}
.trp-ls-dropdown .trp-ls-dropdown__list a:hover {
    color: #fff !important;
}
.trp-ls-dropdown img.trp-ls-flag {
    display: none !important;
}
html[lang="en-US"] .er-nav-main .nav > li > a {
    padding-left: 15px !important;
    padding-right: 15px !important;
    font-size: 15px !important;
}
.er-drawer-lang .trp-ls-dropdown .trp-ls-trigger,
.er-drawer-lang .trp-ls-dropdown .trp-ls-dropdown__list a {
    color: var(--er-primary, #3f151f) !important;
}
.er-drawer-lang .trp-ls-dropdown .trp-ls-trigger:hover,
.er-drawer-lang .trp-ls-dropdown .trp-ls-dropdown__list a:hover {
    color: var(--er-accent, #f06526) !important;
}
