/* =====================================================================
   CoralDream - Design system (tema marino)
   Palette turchese/deep-sea ripresa dall'identità attuale.
   ===================================================================== */

:root {
    --cd-primary: #16a3ac;
    --cd-primary-600: #0e8791;
    --cd-primary-700: #0a6b73;
    --cd-deep: #0a4f59;
    --cd-abyss: #063139;
    --cd-foam: #eaf7f8;
    --cd-sand: #f6f3ec;
    --cd-ink: #14282d;
    --cd-muted: #6b7b7f;
    --cd-line: #e2e8e9;
    --cd-coral: #ff6b5e;
    --cd-gold: #f4c20d;
    --cd-white: #ffffff;

    --radius: 14px;
    --radius-sm: 9px;
    --shadow-sm: 0 2px 10px rgba(10, 79, 89, .07);
    --shadow: 0 12px 34px rgba(10, 79, 89, .12);
    --container: 1200px;
    --font: 'Manrope', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    font-family: var(--font);
    color: var(--cd-ink);
    background: var(--cd-white);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    /* Sticky footer: il footer resta in fondo anche con poco contenuto */
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

#main { flex: 1 0 auto; }

img { max-width: 100%; height: auto; display: block; }
a { color: var(--cd-primary-600); text-decoration: none; }
a:hover { color: var(--cd-primary-700); }

h1, h2, h3 { line-height: 1.15; margin: 0 0 .5em; font-weight: 800; letter-spacing: -.01em; }
h1 { font-size: clamp(1.7rem, 3.5vw, 2.6rem); }
h2 { font-size: clamp(1.4rem, 2.6vw, 2rem); }

.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: 20px; }

:focus-visible { outline: 3px solid var(--cd-primary); outline-offset: 2px; }

/* ---------- Bottoni ---------- */
.btn {
    --btn-bg: var(--cd-primary);
    display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
    padding: .7rem 1.4rem; border-radius: 999px; border: 2px solid transparent;
    font: inherit; font-weight: 700; cursor: pointer; transition: .18s ease;
    text-align: center;
}
.btn--primary { background: var(--btn-bg); color: #fff; }
.btn--primary:hover { background: var(--cd-primary-600); color: #fff; transform: translateY(-1px); }
.btn--ghost { background: transparent; border-color: currentColor; color: var(--cd-primary-600); }
.btn--ghost:hover { background: var(--cd-foam); }
.btn--lg { padding: .95rem 1.9rem; font-size: 1.05rem; }
.btn--sm { padding: .5rem 1rem; font-size: .9rem; }
.btn--block { display: flex; width: 100%; }

/* ---------- Topbar ---------- */
.topbar { background: linear-gradient(90deg, var(--cd-foam), #dff2f3); font-size: .85rem; color: var(--cd-deep); }
.topbar__inner { display: flex; justify-content: space-between; gap: 1rem; padding: .4rem 20px; flex-wrap: wrap; }
.topbar a { color: var(--cd-deep); margin-right: 1rem; }
.topbar__account a { margin-left: 1rem; margin-right: 0; }

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: #fff; box-shadow: var(--shadow-sm); }
.site-header__inner { display: flex; align-items: center; gap: 1.2rem; padding: .7rem 20px; }
.brand { display: flex; align-items: center; gap: .5rem; font-weight: 800; font-size: 1.35rem; color: var(--cd-deep); letter-spacing: .04em; }
.brand__mark { font-size: 1.5rem; }
.brand__name strong { color: var(--cd-primary); }

.main-nav ul { display: flex; gap: .3rem; list-style: none; margin: 0; padding: 0; flex-wrap: wrap; }
.main-nav a { padding: .5rem .8rem; border-radius: 8px; color: var(--cd-ink); font-weight: 600; font-size: .95rem; }
.main-nav a:hover { background: var(--cd-foam); color: var(--cd-primary-700); }

.header-actions { margin-left: auto; display: flex; align-items: center; gap: .6rem; }
.search { position: relative; display: flex; align-items: center; background: var(--cd-foam); border-radius: 999px; padding: .25rem .25rem .25rem .9rem; }
.search input { border: 0; background: transparent; padding: .35rem; font: inherit; width: 170px; outline: none; }
.search button { border: 0; background: var(--cd-primary); color: #fff; width: 34px; height: 34px; border-radius: 50%; cursor: pointer; }
.search__suggest { position: absolute; top: calc(100% + 8px); left: 0; right: 0; background: #fff; border-radius: var(--radius-sm); box-shadow: var(--shadow); overflow: hidden; z-index: 60; }
.search__suggest a { display: flex; gap: .6rem; align-items: center; padding: .5rem .8rem; color: var(--cd-ink); }
.search__suggest a:hover { background: var(--cd-foam); }
.search__suggest img { width: 40px; height: 40px; object-fit: cover; border-radius: 6px; }

.icon-btn { position: relative; font-size: 1.2rem; padding: .4rem; color: var(--cd-deep); }
.icon-btn--cart .cart-count { position: absolute; top: -4px; right: -6px; background: var(--cd-coral); color: #fff; font-size: .7rem; font-weight: 700; min-width: 18px; height: 18px; border-radius: 999px; display: grid; place-items: center; padding: 0 4px; }

.nav-toggle { display: none; flex-direction: column; gap: 5px; background: none; border: 0; cursor: pointer; padding: .4rem; }
.nav-toggle span { width: 24px; height: 2px; background: var(--cd-deep); border-radius: 2px; }

/* ---------- Flash ---------- */
.flash-wrap { position: fixed; top: 80px; right: 20px; z-index: 100; display: grid; gap: .5rem; }
.flash { padding: .8rem 1.2rem; border-radius: var(--radius-sm); color: #fff; box-shadow: var(--shadow); font-weight: 600; animation: slideIn .3s ease; }
.flash--success { background: var(--cd-primary-600); }
.flash--error { background: var(--cd-coral); }
@keyframes slideIn { from { transform: translateX(20px); opacity: 0; } to { transform: none; opacity: 1; } }

/* ---------- Hero ---------- */
.hero { position: relative; min-height: 560px; display: flex; align-items: center; overflow: hidden; background: var(--cd-deep); }
.hero__bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero__overlay { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(6,49,57,.78), rgba(22,163,172,.35)); }
.hero__content { position: relative; color: #fff; max-width: 640px; padding-block: 3rem; }
.hero__content h1 { color: #fff; text-shadow: 0 2px 20px rgba(0,0,0,.3); }
.hero__content p { font-size: 1.15rem; opacity: .95; margin-bottom: 1.6rem; }
.hero__cta { display: flex; gap: .8rem; flex-wrap: wrap; }
.hero .btn--ghost { color: #fff; }
.hero .btn--ghost:hover { background: rgba(255,255,255,.15); }

.wave-divider { position: absolute; bottom: -1px; left: 0; right: 0; height: 60px;
    background: var(--cd-white);
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 60'%3E%3Cpath d='M0 30 C 200 60 400 0 600 30 C 800 60 1000 0 1200 30 L1200 60 L0 60 Z'/%3E%3C/svg%3E") bottom / 100% 100% no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 60'%3E%3Cpath d='M0 30 C 200 60 400 0 600 30 C 800 60 1000 0 1200 30 L1200 60 L0 60 Z'/%3E%3C/svg%3E") bottom / 100% 100% no-repeat;
}

/* ---------- Sezioni ---------- */
.section { padding: 3.4rem 0; }
.section--tint { background: var(--cd-sand); }
.section__head { text-align: center; margin-bottom: 2rem; }
.eyebrow { display: inline-block; text-transform: uppercase; letter-spacing: .12em; font-size: .75rem; font-weight: 700; color: var(--cd-primary); margin-bottom: .4rem; }

/* ---------- Categorie (carosello su una riga) ---------- */
.category-carousel { position: relative; }
.category-track {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding: .3rem .2rem;               /* spazio per l'ombra delle card */
    scrollbar-width: none;              /* Firefox: nasconde la scrollbar */
}
.category-track::-webkit-scrollbar { display: none; } /* Chrome/Safari */
.category-card {
    position: relative;
    flex: 0 0 240px;                    /* larghezza fissa: resta tutto su una riga */
    aspect-ratio: 16/10;
    scroll-snap-align: start;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}
.category-card img { width: 100%; height: 100%; object-fit: cover; transition: .4s; }
.category-card:hover img { transform: scale(1.06); }
.category-card__name { position: absolute; inset: auto 0 0 0; padding: .8rem; color: #fff; font-weight: 700; font-size: 1.05rem; background: linear-gradient(transparent, rgba(6,49,57,.85)); }

/* Frecce di navigazione */
.category-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 3;
    width: 46px; height: 46px;
    display: flex; align-items: center; justify-content: center;
    border: none; border-radius: 50%;
    background: var(--cd-primary); color: #fff;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(6,49,57,.28);
    transition: opacity .2s, background .2s, transform .1s;
}
.category-nav:hover { background: var(--cd-primary-700, #0a6b73); }
.category-nav:active { transform: translateY(-50%) scale(.94); }
.category-nav--prev { left: -10px; }
.category-nav--next { right: -10px; }
.category-nav[disabled] { opacity: 0; pointer-events: none; }

/* ---------- Griglia prodotti ---------- */
.product-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1.2rem; }
.product-card { background: #fff; border: 1px solid var(--cd-line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; transition: .2s; }
.product-card:hover { box-shadow: var(--shadow); transform: translateY(-3px); }
.product-card__media { position: relative; aspect-ratio: 1; background: var(--cd-foam); display: block; overflow: hidden; }
.product-card__media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.product-card__body { padding: .9rem; display: flex; flex-direction: column; gap: .4rem; flex: 1; }
.product-card__brand { font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; color: var(--cd-muted); }
.product-card__title { font-size: 1rem; margin: 0; }
.product-card__title a { color: var(--cd-ink); }
.product-card__price { margin-top: auto; display: flex; align-items: baseline; gap: .5rem; }
.price-now { font-weight: 800; font-size: 1.15rem; color: var(--cd-deep); }
.price-old { text-decoration: line-through; color: var(--cd-muted); font-size: .9rem; }

.badge { position: absolute; top: .6rem; padding: .2rem .55rem; border-radius: 999px; font-size: .72rem; font-weight: 700; color: #fff; z-index: 2; }
.badge--sale { left: .6rem; background: var(--cd-coral); }
.badge--new { right: .6rem; background: var(--cd-primary); }

/* ---------- Servizi ---------- */
.services { background: var(--cd-deep); color: #fff; padding: 2.2rem 0; }
.services__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1.4rem; }
.service { display: flex; gap: .8rem; align-items: flex-start; }
.service span { font-size: 1.6rem; }
.service strong { display: block; }
.service p { margin: .2rem 0 0; font-size: .9rem; opacity: .85; }

/* ---------- Marchi ---------- */
.brand-strip { display: flex; flex-wrap: wrap; gap: .7rem; justify-content: center; }
.brand-chip { padding: .5rem 1.2rem; border: 1px solid var(--cd-line); border-radius: 999px; color: var(--cd-deep); font-weight: 600; background: #fff; }
.brand-chip:hover { border-color: var(--cd-primary); }

/* ---------- Blog card ---------- */
.post-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 1.2rem; }
.post-card { background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); color: var(--cd-ink); }
.post-card:hover { box-shadow: var(--shadow); }
.post-card img { aspect-ratio: 16/10; object-fit: cover; width: 100%; }
.post-card__body { padding: 1rem; }
.post-card__body h3 { font-size: 1.05rem; }
.post-card__body p { font-size: .9rem; color: var(--cd-muted); margin: 0; }

/* ---------- Breadcrumb ---------- */
.breadcrumb { padding-block: 1rem; font-size: .88rem; color: var(--cd-muted); display: flex; gap: .4rem; flex-wrap: wrap; }
.breadcrumb span[aria-current] { color: var(--cd-ink); font-weight: 600; }

/* ---------- Catalogo ---------- */
.catalog-head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; }
.catalog-count { color: var(--cd-muted); }
.catalog-layout { display: grid; grid-template-columns: 260px 1fr; gap: 2rem; padding-bottom: 3rem; }
.filters { position: sticky; top: 90px; align-self: start; background: var(--cd-sand); border-radius: var(--radius); padding: 1.2rem; }
.filter-group { margin-bottom: 1.3rem; }
.filter-group h3 { font-size: .95rem; margin-bottom: .6rem; }
.price-range { display: flex; gap: .5rem; }
.price-range input, .filters select { width: 100%; padding: .55rem .7rem; border: 1px solid var(--cd-line); border-radius: 8px; font: inherit; }
.check { display: flex; align-items: center; gap: .5rem; }
.catalog-toolbar { display: flex; justify-content: flex-end; margin-bottom: 1.2rem; }
.catalog-toolbar select { padding: .5rem .7rem; border: 1px solid var(--cd-line); border-radius: 8px; font: inherit; margin-left: .4rem; }

.pagination { display: flex; gap: .4rem; justify-content: center; margin-top: 2rem; }
.pagination__item { padding: .5rem .9rem; border: 1px solid var(--cd-line); border-radius: 8px; color: var(--cd-ink); }
.pagination__item.is-active { background: var(--cd-primary); color: #fff; border-color: var(--cd-primary); }

.empty-state { text-align: center; padding: 3rem 1rem; color: var(--cd-muted); display: grid; gap: 1rem; place-items: center; }

/* ---------- Prodotto ---------- */
.product-detail { display: grid; grid-template-columns: 1fr 1fr; gap: 2.5rem; padding-block: 1rem 2.5rem; }
.product-gallery__main { border-radius: var(--radius); overflow: hidden; background: var(--cd-foam); aspect-ratio: 1; cursor: zoom-in; }
.product-gallery__main img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.product-gallery__thumbs { display: flex; gap: .6rem; margin-top: .7rem; flex-wrap: wrap; }
.thumb { border: 2px solid transparent; border-radius: 8px; overflow: hidden; padding: 0; cursor: pointer; background: none; width: 70px; height: 70px; }
.thumb.is-active { border-color: var(--cd-primary); }
.thumb img { width: 100%; height: 100%; object-fit: cover; }

.product-info__brand { text-transform: uppercase; letter-spacing: .08em; font-size: .8rem; color: var(--cd-muted); font-weight: 700; }
.product-info__price { display: flex; align-items: baseline; gap: .7rem; margin: .8rem 0; }
.product-info__price .price-now { font-size: 1.9rem; }
.product-info__short { color: var(--cd-muted); }
.availability { font-weight: 700; }
.availability.in-stock { color: var(--cd-primary-600); }
.availability.out-stock { color: var(--cd-coral); }
.rating { color: var(--cd-gold); font-size: 1rem; }
.rating span { color: var(--cd-muted); font-size: .85rem; }

.add-form { display: flex; gap: .8rem; align-items: center; margin-top: 1.4rem; flex-wrap: wrap; }
.qty { display: inline-flex; align-items: center; border: 1px solid var(--cd-line); border-radius: 999px; overflow: hidden; }
.qty__btn { width: 38px; height: 40px; border: 0; background: var(--cd-foam); font-size: 1.2rem; cursor: pointer; color: var(--cd-deep); }
.qty input { width: 48px; text-align: center; border: 0; font: inherit; -moz-appearance: textfield; }
.qty input::-webkit-outer-spin-button, .qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

.product-tabs { padding-bottom: 3rem; }
.tabs { display: flex; gap: .3rem; border-bottom: 2px solid var(--cd-line); margin-bottom: 1.4rem; flex-wrap: wrap; }
.tab { border: 0; background: none; padding: .8rem 1.2rem; font: inherit; font-weight: 700; color: var(--cd-muted); cursor: pointer; border-bottom: 3px solid transparent; margin-bottom: -2px; }
.tab.is-active { color: var(--cd-primary-700); border-color: var(--cd-primary); }
.tab-panel { display: none; }
.tab-panel.is-active { display: block; }
.spec-table { border-collapse: collapse; width: 100%; max-width: 500px; }
.spec-table th, .spec-table td { text-align: left; padding: .6rem .8rem; border-bottom: 1px solid var(--cd-line); }
.spec-table th { background: var(--cd-sand); width: 40%; }
.review { padding: 1rem 0; border-bottom: 1px solid var(--cd-line); }
.review__head { display: flex; gap: .8rem; align-items: center; }

/* ---------- Carrello ---------- */
.cart-page { padding-block: 1.5rem 3.5rem; }
.cart-layout { display: grid; grid-template-columns: 1fr 340px; gap: 2rem; }
.cart-item { display: grid; grid-template-columns: 80px 1fr auto auto auto; gap: 1rem; align-items: center; padding: 1rem 0; border-bottom: 1px solid var(--cd-line); }
.cart-item img { border-radius: 8px; object-fit: cover; }
.cart-item__info a { color: var(--cd-ink); font-weight: 700; }
.cart-item__price { display: block; color: var(--cd-muted); font-size: .9rem; }
.cart-item__total { font-weight: 800; color: var(--cd-deep); }
.cart-item__remove { border: 0; background: none; color: var(--cd-muted); cursor: pointer; font-size: 1.1rem; }
.cart-summary { background: var(--cd-sand); border-radius: var(--radius); padding: 1.4rem; align-self: start; position: sticky; top: 90px; }
.cart-summary__row, .cart-summary__total { display: flex; justify-content: space-between; padding: .5rem 0; }
.cart-summary__total { border-top: 2px solid var(--cd-line); margin-top: .5rem; padding-top: 1rem; font-size: 1.2rem; }
.cart-summary__hint { font-size: .82rem; color: var(--cd-muted); }
.cart-summary .btn { margin-top: .6rem; }

/* ---------- Contenuti / prose ---------- */
.page-content { padding-block: 1rem 3.5rem; max-width: 1100px; }
.prose { line-height: 1.75; }
.prose img { border-radius: var(--radius); margin: 1rem 0; }
.post-cover { border-radius: var(--radius); margin: 1rem 0 1.5rem; width: 100%; object-fit: cover; }

.error-page { text-align: center; padding: 5rem 1rem; }
.error-page h1 { font-size: 4rem; color: var(--cd-primary); }

/* ---------- Newsletter (footer) ---------- */
.newsletter-form { display: flex; gap: .5rem; margin-top: .6rem; }
.newsletter-form input { flex: 1; padding: .6rem .8rem; border: 0; border-radius: 8px; font: inherit; }
.newsletter-form button { border: 0; background: var(--cd-primary); color: #fff; padding: 0 1.1rem; border-radius: 8px; font-weight: 700; cursor: pointer; }

/* ---------- Footer ---------- */
.site-footer { background: var(--cd-deep); color: #cfe7e9; margin-top: auto; flex-shrink: 0; }
.footer-strip { height: 90px; background: linear-gradient(var(--cd-primary), var(--cd-deep)); opacity: .35; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 1.8rem; padding: 2.6rem 20px; }
.footer-col h3 { color: #fff; font-size: 1rem; margin-bottom: .8rem; }
.footer-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .4rem; }
.footer-col a { color: #cfe7e9; font-size: .92rem; }
.footer-col a:hover { color: #fff; }
.footer-social-title { margin-top: 1.2rem; }
.footer-social { display: flex; gap: .5rem; }
.footer-social a { width: 34px; height: 34px; display: grid; place-items: center; background: rgba(255,255,255,.1); border-radius: 8px; color: #fff; font-weight: 700; }
.footer-bottom { background: var(--cd-abyss); font-size: .85rem; }
.footer-bottom__inner { display: flex; justify-content: space-between; gap: 1rem; padding: 1rem 20px; flex-wrap: wrap; color: #9fc3c6; }
.footer-bottom__nav a { color: #9fc3c6; margin-left: 1rem; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
    .catalog-layout, .cart-layout { grid-template-columns: 1fr; }
    .product-detail { grid-template-columns: 1fr; }
    .filters { position: static; }
    .cart-summary { position: static; }
}

@media (max-width: 820px) {
    .search input { width: 120px; }
}

@media (prefers-reduced-motion: reduce) {
    * { animation: none !important; transition: none !important; scroll-behavior: auto; }
}

/* =====================================================================
   FASE 2 - Autenticazione & Area cliente
   ===================================================================== */

/* ---------- Form generici ---------- */
.form-field { margin-bottom: 1rem; display: flex; flex-direction: column; gap: .35rem; }
.form-field label { font-weight: 600; font-size: .92rem; }
.form-field input, .form-field select, .form-field textarea {
    padding: .7rem .85rem; border: 1px solid var(--cd-line); border-radius: 10px; font: inherit; background: #fff;
}
.form-field input:focus, .form-field select:focus { border-color: var(--cd-primary); outline: none; box-shadow: 0 0 0 3px rgba(22,163,172,.15); }
.form-field input:disabled { background: var(--cd-sand); color: var(--cd-muted); }
.form-field .hint, .form-field .opt { color: var(--cd-muted); font-size: .8rem; font-weight: 400; }
.form-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 1rem; }
.form-grid-3 { display: grid; grid-template-columns: 1fr 1.4fr 1fr; gap: 0 1rem; }
.form--panel { background: #fff; border: 1px solid var(--cd-line); border-radius: var(--radius); padding: 1.4rem; margin-bottom: 1.6rem; }
.form-row-between { display: flex; justify-content: flex-end; margin-bottom: 1rem; }
.link-muted { color: var(--cd-muted); font-size: .9rem; }
.link-muted:hover { color: var(--cd-primary-700); }
.link-danger { border: 0; background: none; color: var(--cd-coral); cursor: pointer; font: inherit; padding: 0; }
.link-danger:hover { text-decoration: underline; }

/* ---------- Auth (login/registrazione/reset) ---------- */
.auth-wrap { max-width: var(--container); margin-inline: auto; padding: 3rem 20px 4rem; display: flex; justify-content: center; }
.auth-card { background: #fff; border: 1px solid var(--cd-line); border-radius: var(--radius); box-shadow: var(--shadow-sm); padding: 2.2rem; width: 100%; max-width: 440px; }
.auth-card--wide { max-width: 620px; }
.auth-card h1 { margin-bottom: .3rem; }
.auth-sub { color: var(--cd-muted); margin-bottom: 1.6rem; }
.auth-alt { text-align: center; margin-top: 1.4rem; color: var(--cd-muted); }
.auth-card .btn--block { margin-top: .5rem; }

/* ---------- Layout area cliente ---------- */
.account-page { padding-block: 1.5rem 3.5rem; }
.account-title { margin-bottom: 1.4rem; }
.account-layout { display: grid; grid-template-columns: 260px 1fr; gap: 2rem; align-items: start; }

.account-nav { background: #fff; border: 1px solid var(--cd-line); border-radius: var(--radius); padding: 1.2rem; position: sticky; top: 90px; }
.account-nav__user { display: flex; gap: .7rem; align-items: center; padding-bottom: 1rem; margin-bottom: 1rem; border-bottom: 1px solid var(--cd-line); }
.account-nav__avatar { width: 42px; height: 42px; border-radius: 50%; background: var(--cd-foam); display: grid; place-items: center; font-size: 1.2rem; }
.account-nav__user strong { display: block; font-size: .95rem; }
.account-nav__user span { font-size: .8rem; color: var(--cd-muted); word-break: break-all; }
.account-nav nav { display: grid; gap: .2rem; }
.account-nav nav a { padding: .6rem .8rem; border-radius: 8px; color: var(--cd-ink); font-weight: 600; font-size: .95rem; }
.account-nav nav a:hover { background: var(--cd-foam); }
.account-nav nav a.is-active { background: var(--cd-primary); color: #fff; }
.account-nav__logout { margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--cd-line); }
.account-nav__logout button { width: 100%; border: 1px solid var(--cd-line); background: #fff; padding: .6rem; border-radius: 8px; cursor: pointer; font: inherit; font-weight: 600; color: var(--cd-muted); }
.account-nav__logout button:hover { border-color: var(--cd-coral); color: var(--cd-coral); }

.account-main { min-width: 0; }
.account-greeting { color: var(--cd-muted); margin-bottom: 1.4rem; }
.account-h2 { font-size: 1.25rem; margin: 1.8rem 0 1rem; }
.account-h2:first-child { margin-top: 0; }
.account-head-row { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 1rem; }

.account-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 1rem; margin-bottom: 1rem; }
.account-stat { background: #fff; border: 1px solid var(--cd-line); border-radius: var(--radius); padding: 1.2rem; text-align: center; color: var(--cd-ink); transition: .2s; }
.account-stat:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.account-stat__num { display: block; font-size: 2rem; font-weight: 800; color: var(--cd-deep); }
.account-stat__label { color: var(--cd-muted); font-size: .9rem; }

/* ---------- Tabelle dati ---------- */
.data-table { width: 100%; border-collapse: collapse; background: #fff; border: 1px solid var(--cd-line); border-radius: var(--radius); overflow: hidden; }
.data-table th, .data-table td { padding: .8rem 1rem; text-align: left; border-bottom: 1px solid var(--cd-line); font-size: .92rem; }
.data-table thead th { background: var(--cd-sand); font-size: .82rem; text-transform: uppercase; letter-spacing: .04em; color: var(--cd-muted); }
.data-table tbody tr:last-child td { border-bottom: 0; }

/* ---------- Stati ordine ---------- */
.status { display: inline-block; padding: .2rem .6rem; border-radius: 999px; font-size: .78rem; font-weight: 700; }
.status--pending { background: #fff4d6; color: #9a6b00; }
.status--paid, .status--processing { background: #d9f2f4; color: var(--cd-primary-700); }
.status--shipped { background: #e0e7ff; color: #3a45a0; }
.status--delivered { background: #d7f5e3; color: #1a7f4b; }
.status--cancelled, .status--refunded { background: #ffe0dd; color: #b23b30; }

/* ---------- Indirizzi ---------- */
.address-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 1rem; }
.address-card { position: relative; background: #fff; border: 1px solid var(--cd-line); border-radius: var(--radius); padding: 1.2rem; display: flex; flex-direction: column; gap: .25rem; font-size: .92rem; }
.address-card strong { font-size: 1rem; }
.address-card span { color: var(--cd-muted); }
.address-card .badge--new { position: static; align-self: flex-start; margin-bottom: .4rem; }
.address-card__actions { display: flex; gap: 1rem; align-items: center; margin-top: .8rem; padding-top: .8rem; border-top: 1px solid var(--cd-line); }
.address-card__actions form { margin: 0; }

/* ---------- Dettaglio ordine ---------- */
.order-meta { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 1rem; background: var(--cd-sand); border-radius: var(--radius); padding: 1.2rem; margin-bottom: 1.4rem; }
.order-meta div { display: flex; flex-direction: column; gap: .2rem; }
.order-meta span { font-size: .8rem; color: var(--cd-muted); }
.order-totals { margin-top: 1.2rem; margin-left: auto; max-width: 320px; }
.order-totals div { display: flex; justify-content: space-between; padding: .35rem 0; }
.order-totals__grand { border-top: 2px solid var(--cd-line); margin-top: .4rem; padding-top: .8rem !important; font-size: 1.15rem; font-weight: 700; }
.order-address { margin-top: 1.6rem; background: #fff; border: 1px solid var(--cd-line); border-radius: var(--radius); padding: 1.2rem; }
.order-address h3 { margin-bottom: .5rem; }

/* ---------- Wishlist ---------- */
.wishlist-actions { display: flex; align-items: center; justify-content: space-between; gap: .5rem; margin-top: auto; }
.wishlist-toggle { gap: .5rem; }
.wishlist-toggle.is-active { background: var(--cd-coral); border-color: var(--cd-coral); color: #fff; }
.wishlist-toggle.is-active .wishlist-toggle__heart { color: #fff; }
.wishlist-toggle.is-active:hover { background: #e85a4e; }

/* ---------- Logout inline nella topbar ---------- */
.inline-logout { display: inline; margin-left: 1rem; }
.inline-logout button { border: 0; background: none; color: var(--cd-deep); font: inherit; cursor: pointer; padding: 0; }
.inline-logout button:hover { text-decoration: underline; }

/* ---------- Responsive Fase 2 ---------- */
@media (max-width: 900px) {
    .account-layout { grid-template-columns: 1fr; }
    .account-nav { position: static; }
}
@media (max-width: 560px) {
    .form-grid-2, .form-grid-3 { grid-template-columns: 1fr; }
    .auth-card { padding: 1.6rem; }
}

/* =====================================================================
   FASE 3 - Checkout & Ordini
   ===================================================================== */
.checkout-page { padding-block: 1rem 3.5rem; }
.checkout-page > h1 { margin-bottom: 1.4rem; }
.checkout-layout { display: grid; grid-template-columns: 1fr 380px; gap: 2rem; align-items: start; }
.checkout-main { min-width: 0; }
.checkout-login-hint { background: var(--cd-foam); border-radius: var(--radius-sm); padding: .8rem 1rem; margin-bottom: 1.2rem; font-size: .92rem; }

.checkout-block { background: #fff; border: 1px solid var(--cd-line); border-radius: var(--radius); padding: 1.3rem; margin-bottom: 1.2rem; }
.checkout-block h2 { font-size: 1.1rem; margin-bottom: 1rem; }

.option-list { display: grid; gap: .6rem; }
.option { display: flex; align-items: center; gap: .8rem; border: 1px solid var(--cd-line); border-radius: 10px; padding: .8rem 1rem; cursor: pointer; transition: .15s; }
.option:hover { border-color: var(--cd-primary); }
.option:has(input:checked) { border-color: var(--cd-primary); background: var(--cd-foam); }
.option input { accent-color: var(--cd-primary); width: 18px; height: 18px; }
.option__body { display: flex; flex-direction: column; }
.option__body small { color: var(--cd-muted); font-size: .82rem; }
.option__price { margin-left: auto; font-weight: 700; color: var(--cd-deep); white-space: nowrap; }

.checkout-terms { margin: 1rem 0 1.4rem; }

/* Riepilogo */
.checkout-summary { background: var(--cd-sand); border-radius: var(--radius); padding: 1.4rem; position: sticky; top: 90px; }
.checkout-summary > h2 { font-size: 1.15rem; margin-bottom: 1rem; }
.checkout-items { display: grid; gap: .7rem; margin-bottom: 1rem; }
.checkout-item { display: grid; grid-template-columns: 48px 1fr auto; gap: .6rem; align-items: center; font-size: .9rem; }
.checkout-item img { border-radius: 8px; object-fit: cover; }
.checkout-item__name em { color: var(--cd-muted); font-style: normal; }
.checkout-item__price { font-weight: 700; white-space: nowrap; }

.checkout-coupon { border-top: 1px solid var(--cd-line); padding-top: 1rem; margin-bottom: 1rem; }
.coupon-input { display: flex; gap: .5rem; }
.coupon-input input { flex: 1; padding: .55rem .7rem; border: 1px solid var(--cd-line); border-radius: 8px; font: inherit; background: #fff; }
.coupon-applied { display: flex; justify-content: space-between; align-items: center; background: #fff; border: 1px dashed var(--cd-primary); border-radius: 8px; padding: .5rem .8rem; font-size: .9rem; }

.checkout-totals { border-top: 1px solid var(--cd-line); padding-top: 1rem; }
.checkout-totals .row { display: flex; justify-content: space-between; padding: .35rem 0; }
.checkout-totals .row--grand { border-top: 2px solid var(--cd-line); margin-top: .4rem; padding-top: .8rem; font-size: 1.2rem; font-weight: 800; color: var(--cd-deep); }

/* Conferma ordine */
.confirm-page { padding-block: 2rem 3.5rem; max-width: 820px; }
.confirm-hero { text-align: center; margin-bottom: 2rem; }
.confirm-check { width: 72px; height: 72px; border-radius: 50%; background: var(--cd-primary); color: #fff; font-size: 2.4rem; display: grid; place-items: center; margin: 0 auto 1rem; box-shadow: var(--shadow); }
.confirm-hero h1 { margin-bottom: .5rem; }
.confirm-panel { background: #fff; border: 1px solid var(--cd-line); border-radius: var(--radius); padding: 1.4rem; margin-bottom: 1.2rem; }
.confirm-panel h2 { font-size: 1.15rem; margin-bottom: .8rem; }
.confirm-panel--pay { border-color: var(--cd-primary); background: var(--cd-foam); }
.bank-details { list-style: none; margin: .8rem 0; padding: 0; display: grid; gap: .5rem; }
.bank-details li { display: flex; justify-content: space-between; gap: 1rem; padding: .5rem .8rem; background: #fff; border-radius: 8px; }
.bank-details span { color: var(--cd-muted); }
.confirm-actions { display: flex; gap: .8rem; justify-content: center; flex-wrap: wrap; }

@media (max-width: 900px) {
    .checkout-layout { grid-template-columns: 1fr; }
    .checkout-summary { position: static; order: -1; }
}

/* =====================================================================
   Menu dropdown "Categorie" + Hero stile mockup
   ===================================================================== */
.main-nav .has-dropdown{position:relative}
.dropdown-toggle{display:inline-flex;align-items:center;gap:.3rem}
.dropdown-toggle .caret{font-size:.7em;transition:transform .2s}
.has-dropdown .dropdown{
    position:absolute;top:calc(100% + 8px);left:0;margin:0;padding:.5rem;list-style:none;
    background:#fff;border:1px solid var(--cd-line);border-radius:12px;box-shadow:var(--shadow);
    display:grid;grid-template-columns:repeat(2,minmax(155px,1fr));gap:.1rem;min-width:330px;
    opacity:0;visibility:hidden;transform:translateY(6px);transition:.16s;z-index:60;
}
.has-dropdown:hover .dropdown,
.has-dropdown:focus-within .dropdown,
.has-dropdown.is-open .dropdown{opacity:1;visibility:visible;transform:none}
.has-dropdown:hover .caret,.has-dropdown.is-open .caret{transform:rotate(180deg)}
.dropdown li a{display:block;padding:.55rem .8rem;border-radius:8px;color:var(--cd-ink);font-weight:600;font-size:.92rem;white-space:nowrap}
.dropdown li a:hover{background:var(--cd-foam);color:var(--cd-primary-700)}

/* Hero ridisegnato (testo a sinistra, feature, bottone) */
.hero{min-height:600px}
.hero__overlay{background:linear-gradient(90deg,rgba(4,28,33,.95) 0%,rgba(5,38,45,.82) 34%,rgba(6,49,57,.4) 68%,rgba(6,49,57,.12) 100%)}
.hero__inner{position:relative;width:100%}
.hero__content{max-width:560px;color:#fff;padding-block:3.5rem}
.hero__eyebrow{display:block;text-transform:uppercase;letter-spacing:.18em;font-size:.8rem;font-weight:700;color:#7fd4dc;margin-bottom:1rem}
.hero__title{font-size:clamp(2.1rem,5vw,3.5rem);line-height:1.03;font-weight:800;color:#fff;margin:0 0 1.1rem;text-transform:uppercase;letter-spacing:-.01em;text-shadow:0 2px 24px rgba(0,0,0,.35)}
.hero__title-accent{display:block;color:#5cc0e6}
.hero__sub{font-size:1.1rem;line-height:1.6;color:rgba(255,255,255,.9);max-width:470px;margin-bottom:1.8rem}
.hero__features{list-style:none;display:flex;flex-wrap:wrap;gap:1.3rem 1.9rem;margin:0 0 2rem;padding:0}
.hero__features li{display:flex;align-items:center;gap:.6rem}
.hero__feat-icon{width:40px;height:40px;flex:none;display:grid;place-items:center;color:#7fd4dc}
.hero__feat-icon svg{width:30px;height:30px}
.hero__feat-txt{font-size:.86rem;font-weight:600;line-height:1.2;color:rgba(255,255,255,.92)}
.hero__btn{display:inline-flex;align-items:center;gap:.6rem;background:#bfe6f5;color:#08323a;font-weight:800;padding:.9rem 1.9rem;border-radius:999px;text-transform:uppercase;letter-spacing:.04em;font-size:.9rem;transition:.18s}
.hero__btn svg{width:22px;height:22px}
.hero__btn:hover{background:#fff;color:#08323a;transform:translateY(-1px)}

@media (max-width:820px){
    .has-dropdown .dropdown{position:static;opacity:1;visibility:visible;transform:none;display:none;box-shadow:none;border:0;padding:.2rem 0 .2rem 1rem;min-width:0;grid-template-columns:1fr;background:transparent}
    .has-dropdown.is-open .dropdown{display:block}
    .dropdown li a{color:var(--cd-ink)}
}
@media (max-width:600px){
    .hero__content{padding-block:2.5rem}
    .hero__features{gap:1rem 1.3rem}
    .hero__feat-txt{font-size:.8rem}
    .hero__sub{font-size:1rem}
}

/* =====================================================================
   Rifiniture: logo, allineamento menu, feature una riga, bollicine
   ===================================================================== */
.brand__logo{height:46px;width:auto;display:block}

/* Allineamento verticale delle voci di menu (Categorie era disallineata) */
.main-nav > ul > li{display:flex}
.main-nav > ul > li > a{display:flex;align-items:center}

/* Feature hero: tutte e 4 sulla stessa riga */
.hero__content{max-width:640px}
.hero__features{flex-wrap:nowrap;gap:1rem}
.hero__features li{align-items:flex-start}
.hero__feat-icon{width:32px;height:32px}
.hero__feat-icon svg{width:26px;height:26px}
.hero__feat-txt{font-size:.78rem}
@media (max-width:680px){
    .hero__features{flex-wrap:wrap;gap:1rem 1.4rem}
    .hero__features li{flex:0 0 42%}
}

/* Bollicine animate sull'hero */
.hero__inner{z-index:2}
.hero__overlay{z-index:0}
.hero__bubbles{position:absolute;inset:0;overflow:hidden;pointer-events:none;z-index:1}
.hero__bubbles span{position:absolute;bottom:-30px;display:block;border-radius:50%;opacity:0;
    background:radial-gradient(circle at 30% 30%,rgba(255,255,255,.55),rgba(190,230,245,.12));
    box-shadow:0 0 6px rgba(255,255,255,.25);animation:heroBubble linear infinite}
@keyframes heroBubble{
    0%{transform:translateY(0) scale(.6);opacity:0}
    12%{opacity:.7}
    90%{opacity:.35}
    100%{transform:translateY(-660px) scale(1.1);opacity:0}
}
.hero__bubbles span:nth-child(1){left:42%;width:9px;height:9px;animation-duration:9s;animation-delay:0s}
.hero__bubbles span:nth-child(2){left:52%;width:6px;height:6px;animation-duration:7s;animation-delay:1.5s}
.hero__bubbles span:nth-child(3){left:60%;width:12px;height:12px;animation-duration:11s;animation-delay:.6s}
.hero__bubbles span:nth-child(4){left:66%;width:5px;height:5px;animation-duration:6.5s;animation-delay:2.2s}
.hero__bubbles span:nth-child(5){left:72%;width:10px;height:10px;animation-duration:10s;animation-delay:.3s}
.hero__bubbles span:nth-child(6){left:78%;width:7px;height:7px;animation-duration:8s;animation-delay:1.1s}
.hero__bubbles span:nth-child(7){left:83%;width:13px;height:13px;animation-duration:12s;animation-delay:2.6s}
.hero__bubbles span:nth-child(8){left:88%;width:6px;height:6px;animation-duration:7.5s;animation-delay:.9s}
.hero__bubbles span:nth-child(9){left:92%;width:9px;height:9px;animation-duration:9.5s;animation-delay:1.8s}
.hero__bubbles span:nth-child(10){left:48%;width:5px;height:5px;animation-duration:8.5s;animation-delay:3s}
.hero__bubbles span:nth-child(11){left:57%;width:8px;height:8px;animation-duration:10.5s;animation-delay:2s}
.hero__bubbles span:nth-child(12){left:96%;width:7px;height:7px;animation-duration:8s;animation-delay:.4s}
@media (prefers-reduced-motion:reduce){.hero__bubbles{display:none}}

/* Categorie: card piu' strette su schermi piccoli, il carosello resta su una riga */
@media (max-width: 720px) {
    .category-card { flex-basis: 200px; }
    .category-nav { width: 40px; height: 40px; }
    .category-nav--prev { left: -6px; }
    .category-nav--next { right: -6px; }
}
@media (max-width: 480px) {
    .category-card { flex-basis: 160px; }
}

/* =====================================================================
   Pagina contatti
   ===================================================================== */
.contact-layout { display: grid; grid-template-columns: 1.4fr 1fr; gap: 2.5rem; margin-top: 2rem; align-items: start; }
.contact-form-wrap h2, .contact-info h2 { font-size: 1.25rem; margin-bottom: 1rem; }
.contact-form .form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 1rem; }
.contact-form .form-field { display: flex; flex-direction: column; gap: .35rem; margin-bottom: 1rem; }
.contact-form label { font-weight: 600; font-size: .9rem; }
.contact-form input, .contact-form textarea {
    padding: .7rem .85rem; border: 1px solid var(--cd-line); border-radius: 10px; font: inherit; background: #fff; width: 100%;
}
.contact-form input:focus, .contact-form textarea:focus {
    outline: none; border-color: var(--cd-primary); box-shadow: 0 0 0 3px rgba(22,163,172,.14);
}
.contact-form .form-note { font-size: .85rem; color: var(--cd-muted); margin: .2rem 0 1rem; }
/* Campo trappola anti-spam: nascosto agli utenti, visibile ai bot */
.hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.contact-info { background: var(--cd-foam); border-radius: var(--radius); padding: 1.6rem; }
.contact-list { list-style: none; padding: 0; margin: 0 0 1.5rem; display: grid; gap: .9rem; }
.contact-list li { display: flex; flex-direction: column; }
.contact-list__label { font-size: .75rem; text-transform: uppercase; letter-spacing: .1em; color: var(--cd-muted); font-weight: 700; }
.contact-list a { color: var(--cd-primary-700); font-weight: 600; word-break: break-word; }
.contact-help { border-top: 1px solid var(--cd-line); padding-top: 1.2rem; }
.contact-help h3 { font-size: 1rem; margin-bottom: .5rem; }
.contact-help p { font-size: .92rem; color: var(--cd-muted); }

@media (max-width: 860px) {
    .contact-layout { grid-template-columns: 1fr; gap: 1.8rem; }
    .contact-form .form-row { grid-template-columns: 1fr; }
}

/* =====================================================================
   Pagina "Chi Siamo" (blocchi riutilizzabili nelle pagine CMS)
   ===================================================================== */
.about-intro { font-size: 1.08rem; line-height: 1.8; }
.about-intro p:first-child { font-size: 1.2rem; color: var(--cd-deep); font-weight: 600; }

.about-divider { border: 0; border-top: 1px solid var(--cd-line); margin: 2.8rem 0; }

/* Blocco immagine + elenco vantaggi */
.about-offer { display: grid; grid-template-columns: 1fr 1fr; gap: 2.5rem; align-items: center; }
.about-offer__media img { width: 100%; border-radius: var(--radius); box-shadow: var(--shadow); }
.about-offer h2 { font-size: 1.6rem; margin-bottom: 1.2rem; }
.about-checks { list-style: none; padding: 0; margin: 0; }
.about-checks li {
    display: flex; align-items: flex-start; gap: .7rem;
    padding: .7rem 0; border-bottom: 1px solid var(--cd-line); font-weight: 500;
}
.about-checks li:last-child { border-bottom: 0; }
.about-checks li::before {
    content: ""; flex: none; width: 20px; height: 20px; margin-top: 2px; border-radius: 50%;
    background: var(--cd-primary) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E") center/12px no-repeat;
}

/* Griglia servizi con icone */
.about-services { text-align: center; }
.about-services > h2 { font-size: 1.6rem; margin-bottom: 2rem; }
.services-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2.2rem 1.8rem; }
.service-item__icon {
    width: 58px; height: 58px; margin: 0 auto .9rem; border-radius: 50%;
    background: var(--cd-primary); color: #fff; display: grid; place-items: center;
    box-shadow: 0 6px 18px rgba(22,163,172,.28);
}
.service-item__icon svg { width: 28px; height: 28px; }
.service-item h3 {
    font-size: .95rem; text-transform: uppercase; letter-spacing: .06em;
    color: var(--cd-deep); margin-bottom: .5rem;
}
.service-item p { color: var(--cd-muted); font-size: .95rem; margin: 0; }

/* Riquadro invito finale */
.about-cta {
    position: relative; text-align: center; border: 1px solid var(--cd-line);
    border-radius: var(--radius); padding: 3rem 1.5rem 2.2rem; margin-top: 3.5rem;
}
.about-cta__badge {
    position: absolute; top: -28px; left: 50%; transform: translateX(-50%);
    width: 56px; height: 56px; border-radius: 50%; background: var(--cd-primary); color: #fff;
    display: grid; place-items: center; box-shadow: 0 6px 18px rgba(22,163,172,.3);
}
.about-cta__badge svg { width: 26px; height: 26px; }
.about-cta p { font-size: 1.15rem; color: var(--cd-deep); margin: 0 0 1.3rem; }

@media (max-width: 860px) {
    .about-offer { grid-template-columns: 1fr; gap: 1.5rem; }
    .services-grid { grid-template-columns: repeat(2, 1fr); gap: 1.8rem 1.2rem; }
}
@media (max-width: 520px) {
    .services-grid { grid-template-columns: 1fr; }
}

/* =====================================================================
   Banner cookie GDPR
   ===================================================================== */
.cookie-banner {
    position: fixed; left: 1rem; right: 1rem; bottom: 1rem; z-index: 900;
    background: var(--cd-deep); color: #dff0f2; border-radius: 16px;
    box-shadow: 0 18px 50px rgba(0,0,0,.35); padding: 1.3rem 1.5rem;
    max-width: 1100px; margin: 0 auto;
    animation: cookieUp .35s ease-out;
}
@keyframes cookieUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: none; } }
.cookie-banner[hidden] { display: none; }
.cookie-banner__inner { display: flex; align-items: center; gap: 1.6rem; flex-wrap: wrap; }
.cookie-banner__text { flex: 1 1 380px; }
.cookie-banner__text strong { display: block; font-size: 1.05rem; color: #fff; margin-bottom: .3rem; }
.cookie-banner__text p { margin: 0; font-size: .92rem; line-height: 1.55; }
.cookie-banner__text a { color: #7fd4dc; text-decoration: underline; }
.cookie-banner__actions { display: flex; gap: .6rem; flex-wrap: wrap; }
.btn--ghost-light {
    background: transparent; color: #dff0f2; border: 1px solid rgba(255,255,255,.35);
}
.btn--ghost-light:hover { background: rgba(255,255,255,.12); color: #fff; }

/* Pannello preferenze */
.cookie-prefs { margin-top: 1.2rem; border-top: 1px solid rgba(255,255,255,.18); padding-top: 1rem; }
.cookie-prefs[hidden] { display: none; }
.cookie-prefs__row {
    display: flex; align-items: center; justify-content: space-between; gap: 1.5rem;
    padding: .8rem 0; border-bottom: 1px solid rgba(255,255,255,.12);
}
.cookie-prefs__row strong { color: #fff; font-size: .95rem; }
.cookie-prefs__row p { margin: .15rem 0 0; font-size: .85rem; opacity: .8; }
.cookie-prefs__always { font-size: .8rem; opacity: .7; white-space: nowrap; }
.cookie-prefs__actions { padding-top: 1rem; }

/* Interruttore */
.cookie-switch { position: relative; display: inline-block; width: 46px; height: 26px; flex: none; }
.cookie-switch input { opacity: 0; width: 0; height: 0; }
.cookie-switch span {
    position: absolute; inset: 0; cursor: pointer; border-radius: 999px;
    background: rgba(255,255,255,.25); transition: .2s;
}
.cookie-switch span::before {
    content: ""; position: absolute; width: 20px; height: 20px; left: 3px; top: 3px;
    background: #fff; border-radius: 50%; transition: .2s;
}
.cookie-switch input:checked + span { background: var(--cd-primary); }
.cookie-switch input:checked + span::before { transform: translateX(20px); }
.cookie-switch input:focus-visible + span { outline: 2px solid #7fd4dc; outline-offset: 2px; }

/* Pulsante per riaprire le preferenze */
.cookie-reopen {
    position: fixed; left: 1rem; bottom: 1rem; z-index: 880;
    width: 44px; height: 44px; border-radius: 50%; border: 0; cursor: pointer;
    background: var(--cd-deep); color: #bfe6f5; display: grid; place-items: center;
    box-shadow: 0 6px 20px rgba(0,0,0,.25); opacity: .75; transition: .2s;
}
.cookie-reopen:hover { opacity: 1; transform: translateY(-2px); }
.cookie-reopen svg { width: 22px; height: 22px; }
.cookie-reopen[hidden] { display: none; }

@media (max-width: 720px) {
    .cookie-banner { left: .6rem; right: .6rem; bottom: .6rem; padding: 1.1rem; }
    .cookie-banner__actions { width: 100%; }
    .cookie-banner__actions .btn { flex: 1 1 auto; justify-content: center; }
    .cookie-prefs__row { flex-direction: row; align-items: flex-start; }
}

/* =====================================================================
   Footer riorganizzato
   ===================================================================== */
.footer-grid { grid-template-columns: 1fr 1fr 1fr 1.4fr; gap: 2rem; }
.footer-col h3 { font-size: .82rem; text-transform: uppercase; letter-spacing: .1em; opacity: .95; }
.footer-col ul { gap: .55rem; }
.footer-col a { transition: color .15s; }
.footer-col--news p { font-size: .9rem; margin: 0 0 .3rem; opacity: .85; }
.footer-social a { transition: background .15s; }
.footer-social a:hover { background: var(--cd-primary); }
.footer-social svg { width: 18px; height: 18px; }

/* Barra inferiore */
.footer-bottom__inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.footer-bottom__nav { display: flex; align-items: center; gap: 0; flex-wrap: wrap; }
.footer-bottom__nav a, .footer-link-btn { color: #9fc3c6; margin-left: 1.2rem; font-size: .88rem; }
.footer-bottom__nav a:hover, .footer-link-btn:hover { color: #fff; }
.footer-link-btn {
    background: none; border: 0; padding: 0; cursor: pointer; font: inherit; font-size: .88rem;
    text-decoration: underline; text-underline-offset: 2px;
}

@media (max-width: 900px) {
    .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
    .footer-grid { grid-template-columns: 1fr; gap: 1.6rem; }
    .footer-bottom__inner { flex-direction: column; align-items: flex-start; }
    .footer-bottom__nav a:first-child, .footer-bottom__nav .footer-link-btn:first-child { margin-left: 0; }
}

/* =====================================================================
   Mobile header: pulito — logo + WhatsApp + hamburger
   ===================================================================== */
/* Pulsante WhatsApp (visibile solo su mobile) */
.wa-btn { display: none; }
.header-mobile-actions { display: contents; }

@media (max-width: 820px) {
    /* Nascondi la topbar su mobile */
    .topbar { display: none; }

    /* Header compatto: logo sx — whatsapp + hamburger dx */
    .site-header__inner {
        display: flex; flex-wrap: wrap; align-items: center;
        padding: .5rem 16px; gap: .6rem;
    }
    .brand { order: 1; flex: 0 0 auto; }
    .brand__logo { height: 38px; }
    .header-mobile-actions {
        display: flex; align-items: center; gap: .5rem;
        order: 2; margin-left: auto;
    }

    /* WhatsApp visible */
    .wa-btn {
        display: grid; place-items: center;
        width: 40px; height: 40px; border-radius: 50%;
        background: #25D366; color: #fff;
        box-shadow: 0 3px 10px rgba(37,211,102,.35);
    }
    .wa-btn svg { width: 22px; height: 22px; }
    .wa-btn:hover { background: #20bd5a; }

    /* Hamburger */
    .nav-toggle { display: flex; margin-left: 0; }

    /* Nascondi ricerca e icone dall'header */
    .header-actions { display: none; }

    /* Menu mobile: scende sotto come blocco pieno */
    .main-nav { order: 10; flex-basis: 100%; display: none; }
    .main-nav.is-open {
        display: flex; flex-direction: column; gap: 0;
        width: 100%; padding: .5rem 0;
        border-top: 1px solid var(--cd-line);
    }
    .main-nav ul { flex-direction: column; gap: 0; }
    .main-nav > ul > li { display: block; }
    .main-nav > ul > li > a { display: block; padding: .7rem 0; font-size: 1.05rem; }
    .main-nav .mobile-extras { border-top: 1px solid var(--cd-line); margin-top: .4rem; padding-top: .6rem; }
    .main-nav .mobile-extras a { display: block; padding: .55rem 0; font-size: 1rem; }
}

/* Su mobile, aggiungi link utili in fondo al menu hamburger */
@media (max-width: 820px) {
    .main-nav .mobile-extras { display: flex; flex-direction: column; gap: .3rem; padding-top: .3rem; }
    .main-nav .mobile-extras a { color: var(--cd-deep); font-weight: 600; font-size: .95rem; padding: .5rem 0; }
}
@media (min-width: 821px) {
    .main-nav .mobile-extras { display: none; }
}
