/*
 * CMS-Z - foglio di stile base.
 * Tutti i colori/raggi passano da variabili CSS con un valore di default
 * qui su :root; ogni tema in /themes/*.css si limita a sovrascrivere
 * queste variabili su body.theme-<nome> (come i temi Bootswatch), quindi
 * lo stesso markup cambia aspetto senza bisogno di CSS per-tema separato.
 */

/* Font predefinito: Roboto self-hosted (font variabile, un solo file per i pesi 100-900). */
@font-face {
    font-family: 'Roboto';
    font-style: normal;
    font-weight: 100 900;
    font-display: swap;
    src: url('/assets/fonts/roboto/roboto-latin.woff2') format('woff2');
}

:root {
    --brand: #2563eb;
    --brand-dark: #1d4ed8;
    --brand-ink: #ffffff;
    --ink: #12161c;
    --ink-mid: #262f3a;
    --paper: #f4f6f8;
    --surface: #ffffff;
    --text: #1f2430;
    --muted: #55636b;
    --text-light: #f4f7f9;
    --muted-light: rgba(244,247,249,.75);
    --radius: 10px;
    --font: 'Roboto', -apple-system, "Segoe UI", Arial, sans-serif;
}

* { box-sizing: border-box; }
body {
    margin: 0;
    font-family: var(--font);
    color: var(--text);
    background: var(--paper);
    line-height: 1.55;
}
img { max-width: 100%; display: block; }
button, input, select, textarea { font-family: inherit; }

/* Contenuto solo per screen-reader / SEO (es. H1 nascosto sulle pagine senza hero) */
.visually-hidden {
    position: absolute !important;
    width: 1px; height: 1px;
    margin: -1px; padding: 0; border: 0;
    clip: rect(0 0 0 0); clip-path: inset(50%);
    overflow: hidden; white-space: nowrap;
}

/* Canvas dello sfondo animato a macchie colorate (assets/blobs.js) */
#bg-canvas { position: fixed; inset: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; }
a { color: inherit; }
.container { max-width: 1160px; margin: 0 auto; padding: 64px 24px; position: relative; }

h1, h2, h3, h4 { margin: 0 0 16px; font-weight: 700; }
h2 { font-size: 2rem; color: var(--text); }
h3 { font-size: 1.15rem; color: var(--text); }
.body p { margin: 0 0 16px; }

.btn {
    display: inline-block;
    padding: 13px 30px;
    border-radius: var(--radius);
    text-decoration: none;
    font-weight: 700;
    font-size: .95rem;
    transition: transform .15s ease, box-shadow .15s ease;
    border: 2px solid transparent;
}
.btn:hover { transform: translateY(-2px); }
.btn-cta { background: var(--brand); color: var(--brand-ink); }
.btn-cta:hover { background: var(--brand-dark); }
.btn-outline { background: transparent; color: var(--text-light); border-color: rgba(255,255,255,.6); }
.btn-outline:hover { border-color: #fff; }
.btn-outline-light { background: transparent; color: var(--text-light); border-color: rgba(255,255,255,.6); }
.btn-outline-light:hover { border-color: #fff; }

.two-col { display: flex; gap: 48px; align-items: center; flex-wrap: wrap; }
.two-col .col-text, .two-col .col-image { flex: 1 1 380px; }
.grid { display: grid; }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 28px; }

/* ---- Hero ---- */
.section-hero { background: var(--paper); text-align: center; }
.section-hero h1 { font-size: 2.5rem; margin-bottom: 12px; }
.section-hero .subtitle { font-size: 1.2rem; color: var(--muted); margin-bottom: 24px; }
.section-hero .hero-image { max-width: 100%; border-radius: var(--radius); margin-bottom: 24px; }

/* ---- Text + image ---- */
.section-text-image { background: var(--paper); }
.section-text-image .col-image img { border-radius: var(--radius); }

/* ---- Grid 3 col (base) ---- */
.section-grid-3col { background: var(--paper); }
.section-grid-3col .grid-title { text-align: center; margin-bottom: 40px; }
.section-grid-3col .grid-image { display: block; max-width: 100%; margin: 0 auto 40px; border-radius: var(--radius); }
.section-grid-3col .grid-item { text-align: center; padding: 24px; }
.section-grid-3col .grid-item i { font-size: 2rem; color: var(--brand); margin-bottom: 12px; }

/* ---- Footer (base) ---- */
.section-footer { background: var(--ink); color: var(--text-light); text-align: center; }
.section-footer .container { padding: 24px; }
.footer-utility-links { display: flex; justify-content: center; gap: 20px; flex-wrap: wrap; margin-bottom: 10px; }
.footer-utility-links a { color: var(--text-light); opacity: .8; text-decoration: none; font-size: .8rem; }
.footer-utility-links a:hover { opacity: 1; text-decoration: underline; }

/* ---- Nav ---- */
.site-nav { background: var(--ink); position: static; z-index: 50; }
.site-nav .nav-inner { display: flex; align-items: center; gap: 24px; padding: 16px 24px; max-width: 1160px; margin: 0 auto; }
.site-nav .brand img { height: 32px; }
.site-nav .brand span { color: #fff; font-weight: 800; font-size: 1.4rem; letter-spacing: .5px; }
.site-nav .nav-links { display: flex; gap: 20px; flex: 1; flex-wrap: wrap; justify-content: flex-end; }
.site-nav .nav-links a { color: var(--text-light); text-decoration: none; font-size: .95rem; opacity: .9; }
.site-nav .nav-links a:hover { opacity: 1; text-decoration: underline; }
.site-nav .nav-ctas { display: flex; gap: 12px; }
.site-nav .nav-ctas .btn { padding: 9px 20px; font-size: .85rem; }
.site-nav .nav-toggle { display: none; background: none; border: none; color: #fff; font-size: 1.3rem; cursor: pointer; }

/* ---- Hero dark ---- */
.section-hero-dark {
    background: linear-gradient(135deg, var(--ink), var(--ink-mid));
    color: var(--text-light);
    text-align: center;
    position: relative;
    overflow: hidden;
}
.section-hero-dark h1 { color: #fff; font-size: 2.6rem; max-width: 720px; margin: 0 auto 20px; }
.section-hero-dark .subtitle { font-size: 1.2rem; opacity: .9; max-width: 640px; margin: 0 auto 28px; }
.hero-ctas { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; margin-top: 12px; }

/* ---- Intro CTA ---- */
.section-intro-cta { background: var(--ink-mid); color: var(--text-light); text-align: center; position: relative; }
.section-intro-cta h2 { color: #fff; max-width: 760px; margin-left: auto; margin-right: auto; }
.section-intro-cta .body { max-width: 760px; margin: 0 auto 24px; opacity: .92; }

/* Pagina privacy/legale: testo lungo giustificato e allineato a sinistra */
.page-privacy .section-intro-cta .body,
.page-legal .section-intro-cta .body { text-align: justify; }
.page-privacy .section-intro-cta .body h3,
.page-legal .section-intro-cta .body h3 { text-align: left; }

/* ---- Ops grid ---- */
.section-ops-grid { background: var(--paper); }
.section-ops-grid h2 { text-align: center; margin-bottom: 40px; }
.ops-card { background: var(--surface); border-radius: var(--radius); overflow: hidden; box-shadow: 0 6px 20px rgba(18,22,28,.08); }
.ops-card img { width: 100%; height: 180px; object-fit: cover; }
.ops-card-body { padding: 20px; }
.ops-card-body p { margin: 0; color: var(--muted); font-size: .93rem; }

/* ---- Image CTA ---- */
.section-image-cta { position: relative; color: var(--text-light); overflow: hidden; min-height: 380px; display: flex; align-items: center; }
.image-cta-bg { position: absolute; inset: 0; background-size: cover; background-position: center; }
.image-cta-overlay { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(18,22,28,.92) 40%, rgba(18,22,28,.35)); }
.image-cta-content { position: relative; padding: 64px 24px; max-width: 560px; margin: 0; }
.image-cta-content h2 { color: #fff; }
.image-cta-content .body { opacity: .92; margin-bottom: 24px; }

/* ---- Value list ---- */
.section-value-list { background: var(--ink); color: var(--text-light); }
.section-value-list h2 { color: #fff; }
.section-value-list .body { opacity: .9; }
.value-card { flex: 1 1 420px; background: var(--surface); border-radius: var(--radius); padding: 32px; display: grid; gap: 24px; }
.value-item { display: flex; gap: 16px; align-items: flex-start; }
.value-item i { color: var(--brand); font-size: 1.6rem; width: 34px; flex-shrink: 0; }
.value-item h3 { margin: 0 0 4px; color: var(--text); font-size: 1rem; }
.value-item p { margin: 0; color: var(--muted); font-size: .88rem; }

/* ---- Works split ---- */
.section-works-split { background: var(--paper); }
.section-works-split .col-image img { border-radius: var(--radius); box-shadow: 0 10px 30px rgba(18,22,28,.15); }
.section-works-split .caption { text-align: center; color: var(--muted); font-size: .85rem; margin-top: 8px; }

/* ---- News hub ---- */
.section-news-hub { background: var(--ink-mid); color: var(--text-light); }
.section-news-hub h2 { color: #fff; text-align: center; margin-bottom: 40px; }
.section-news-hub .two-col { align-items: stretch; }
.news-list { flex: 1 1 460px; display: grid; gap: 4px; }
.news-item { display: flex; gap: 16px; align-items: flex-start; text-decoration: none; color: inherit; padding: 16px; border-radius: 8px; transition: background .15s ease; }
.news-item:hover { background: rgba(255,255,255,.06); }
.news-item i { color: var(--brand); font-size: 1.3rem; width: 28px; margin-top: 4px; flex-shrink: 0; }
.news-item h3 { color: #fff; margin: 0 0 4px; font-size: 1rem; }
.news-item p { margin: 0; opacity: .85; font-size: .88rem; }
.news-feature { flex: 1 1 340px; background: var(--surface); color: var(--text); border-radius: var(--radius); padding: 24px; }
.news-feature img { border-radius: 8px; margin-bottom: 16px; height: 160px; object-fit: cover; width: 100%; }
.news-feature h3 { font-size: 1.1rem; }
.news-feature p { color: var(--muted); font-size: .9rem; }

/* ---- Contact ---- */
.section-contact { background: var(--paper); }
.contact-info p { display: flex; gap: 10px; align-items: flex-start; margin: 0 0 12px; color: var(--text); }
.contact-info i { color: var(--brand); width: 18px; margin-top: 3px; }
.contact-company { font-weight: 700; color: var(--text); font-size: 1.1rem; }
.contact-form-wrap { flex: 1 1 380px; background: var(--ink-mid); border-radius: var(--radius); padding: 28px; }
.contact-form { display: grid; gap: 14px; }
.contact-form input, .contact-form textarea {
    padding: 12px 14px;
    border-radius: 6px;
    border: none;
    font-family: inherit;
    font-size: .95rem;
    resize: vertical;
}
.privacy-check { color: var(--text-light); font-size: .82rem; display: flex; gap: 8px; align-items: flex-start; }
.privacy-check a { color: var(--brand); }
.form-success { color: #fff; background: rgba(255,255,255,.08); padding: 20px; border-radius: 8px; text-align: center; }
.form-success i { color: #6ede8a; margin-right: 8px; }
.form-error { color: #fff; background: rgba(220,38,38,.25); padding: 14px 16px; border-radius: 8px; margin-bottom: 14px; font-size: .88rem; }
.form-error i { color: #fca5a5; margin-right: 8px; }

/* ---- Footer full ---- */
.section-footer-full { background: var(--ink); color: var(--text-light); }
.footer-columns { display: flex; gap: 40px; flex-wrap: wrap; padding-bottom: 24px; }
.footer-col { flex: 1 1 160px; display: flex; flex-direction: column; gap: 8px; }
.footer-col h4 { color: #fff; font-size: .95rem; margin-bottom: 8px; }
.footer-col a { color: var(--muted-light); text-decoration: none; font-size: .88rem; }
.footer-col a:hover { color: #fff; }
.footer-social { flex-direction: row; align-items: flex-start; gap: 14px; margin-left: auto; }
.footer-social a { width: 36px; height: 36px; border-radius: 50%; background: rgba(255,255,255,.1); display: flex; align-items: center; justify-content: center; }
.footer-social a:hover { background: var(--brand); color: var(--ink); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); padding: 18px 24px; text-align: center; font-size: .8rem; opacity: .7; }

/* ---- Negozio / catalogo ---- */
.section-shop-grid, .section-catalog-grid { background: var(--paper); }
.shop-intro { max-width: 720px; color: var(--muted); margin-bottom: 24px; }
.shop-search { display: flex; gap: 8px; margin-bottom: 16px; max-width: 420px; }
.shop-search input { flex: 1; padding: 10px 14px; border-radius: var(--radius); border: 1px solid var(--muted); background: var(--surface); color: var(--text); }
.shop-search button { border: none; border-radius: var(--radius); padding: 0 18px; background: var(--brand); color: var(--brand-ink); cursor: pointer; }
.shop-cats { display: flex; flex-wrap: wrap; gap: 8px 14px; margin-bottom: 24px; }
.shop-cats a { font-size: .82rem; text-decoration: none; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.shop-cats a.is-active, .shop-cats a:hover { color: var(--brand); }
.shop-result { color: var(--muted); margin-bottom: 16px; }
.shop-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 28px; }
.shop-card { background: transparent; border: 1px solid rgba(128,128,128,.28); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; }
.shop-card-img { aspect-ratio: 1/1; background: transparent; display: flex; align-items: center; justify-content: center; }
.shop-card-img img { width: 100%; height: 100%; object-fit: cover; }
.shop-card-body { padding: 18px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.shop-card-body h3 { margin: 0; font-size: 1rem; color: var(--text); }
.shop-card a { text-decoration: none; }
.shop-card-body h3 a { color: var(--text); }
.shop-card-body h3 a:hover { color: var(--brand); }
.shop-card-desc { font-size: .86rem; color: var(--muted); margin: 0; flex: 1; }
.shop-more { color: var(--brand); text-decoration: none; white-space: nowrap; }
.shop-more:hover { text-decoration: underline; }
.shop-card-cat { margin: 0; }
.shop-card-cat a {
    display: inline-block;
    font-size: .72rem; font-weight: 700;
    text-transform: uppercase; letter-spacing: .08em;
    color: var(--brand);
    border: 2px solid var(--brand);
    border-radius: 14px;
    padding: 3px 12px;
    transition: background .15s ease, color .15s ease;
}
.shop-card-cat a:hover { background: var(--brand); color: var(--brand-ink); }
.shop-card-buy { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 8px; }
.shop-price { font-weight: 700; color: var(--text); }
.shop-card-buy .btn { padding: 8px 16px; font-size: .8rem; }
.shop-empty { color: var(--muted); }
[data-shop-results] { transition: opacity .18s ease; }
[data-shop-results].is-loading { pointer-events: none; }
[data-shop-results].is-fading { opacity: 0; }
/*
 * Dissolvenza a cascata riga per riga (primo render E dopo ogni ricerca AJAX):
 * le card partono invisibili e il JS (assets/shop-grid.js) aggiunge .is-visible
 * con un transition-delay scaglionato per riga, dopo un doppio
 * requestAnimationFrame — necessario perché con una CSS *transition* (a
 * differenza di una @keyframes animation) il cambio di stato deve avvenire
 * DOPO che il browser ha disegnato lo stato iniziale opacity:0, altrimenti
 * non parte mai; con una animation invece rischia di partire subito, prima
 * che il JS faccia in tempo a impostare il ritardo (bug visto su blackwidow:
 * il primo render non aveva la cascata). noscript: le card restano visibili
 * se il JS non gira.
 */
.shop-card { opacity: 0; transition: opacity .32s ease, transform .32s ease; transform: translateY(8px); }
.shop-card.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
    [data-shop-results] { transition: none; }
    .shop-card { transition: none; opacity: 1; transform: none; }
}
.shop-add.is-added { background: #16a34a; }
.shop-cats { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.shop-pagination { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 32px; }
.shop-pagination a { padding: 6px 12px; border-radius: 8px; text-decoration: none; color: var(--text); background: var(--surface); font-size: .85rem; }
.shop-pagination a.is-active { background: var(--brand); color: var(--brand-ink); }

/* ---- Menu incorporato nell'hero (solo pagine con hero_cover) ---- */
body.has-hero-cover header.site-nav {
    position: absolute;
    inset: 0 0 auto 0;
    z-index: 30;
    background: transparent;
    backdrop-filter: none;
    border-bottom: none;
}
body.has-hero-cover .section-hero-cover { padding-top: 104px; }
/* Sulla home il logo grande è nell'hero: nasconde il logo nella nav. */
body.has-hero-cover .site-nav .brand { display: none; }

/* ---- Hero a tutto schermo ---- */
.section-hero-cover {
    position: relative;
    min-height: 88vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background-size: cover;
    background-position: center;
    background-color: #000;
    padding: 80px 24px;
    overflow: hidden;
}
.hero-cover-overlay { position: absolute; inset: 0; background: radial-gradient(ellipse at center, rgba(0,0,0,.08), rgba(0,0,0,.4)); }
.hero-cover-content { position: relative; z-index: 1; max-width: 900px; }
.hero-cover-title { margin: 0 0 8px; font-size: 2.8rem; color: #fff; line-height: 1.1; }
.hero-cover-title .hero-cover-logo { width: min(620px, 82vw); height: auto; margin: 0 auto; display: block; filter: drop-shadow(0 3px 18px rgba(0,0,0,.6)); }
.hero-cover-subtitle { color: #f1f1f1; font-size: 1.5rem; margin: 0 0 36px; text-shadow: 0 2px 10px rgba(0,0,0,.5); }
.hero-cover-cta { font-size: 1rem; padding: 14px 40px; }
.hero-cover-scroll {
    position: absolute; left: 50%; bottom: 22px; transform: translateX(-50%);
    z-index: 1; color: rgba(255,255,255,.85); font-size: 1.3rem;
    animation: hero-cover-bob 2s ease-in-out infinite;
}
@keyframes hero-cover-bob { 0%,100% { transform: translate(-50%, 0); } 50% { transform: translate(-50%, 8px); } }
@media (max-width: 600px) {
    .section-hero-cover { min-height: 70vh; }
    .hero-cover-subtitle { font-size: 1.15rem; }
}

/* ---- Icona carrello nella nav ---- */
.nav-cart { position: relative; display: inline-flex; align-items: center; color: var(--text-light); text-decoration: none; font-size: 1.15rem; padding: 4px 6px; }
.nav-cart:hover { color: var(--brand); }
.nav-cart-count {
    position: absolute; top: -4px; right: -6px;
    min-width: 17px; height: 17px; padding: 0 4px;
    border-radius: 9px; background: var(--brand); color: var(--brand-ink);
    font-size: .68rem; font-weight: 700; line-height: 17px; text-align: center;
}
.nav-cart-count:empty, .nav-cart-count[data-zero] { display: none; }

/* ---- Switch lingua IT/EN ---- */
.lang-switch { display: inline-flex; gap: 2px; align-items: center; font-size: .8rem; font-weight: 700; }
.lang-switch a { color: var(--muted); text-decoration: none; padding: 4px 7px; border-radius: 6px; letter-spacing: .04em; }
.lang-switch a.is-active { color: var(--brand-ink); background: var(--brand); }
.lang-switch a:not(.is-active):hover { color: var(--text); }
.product-topbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 8px; }

/* ---- Dettaglio prodotto: testo che contorna la foto ---- */
.product-detail::after { content: ""; display: block; clear: both; }
.product-detail .product-photo {
    float: left;
    width: 340px;
    max-width: 42%;
    margin: 6px 32px 16px 0;
}
.product-detail .product-photo img { border-radius: var(--radius); width: 100%; }
.product-detail h1 { margin-top: 0; font-size: 2rem; }
.product-detail .body { text-align: justify; }
.product-detail .product-cat { clear: both; padding-top: 8px; }
@media (max-width: 600px) {
    .product-detail .product-photo { float: none; width: 100%; max-width: 100%; margin: 0 0 20px; }
}

.section-cart-bar { background: var(--paper); }
.cart-toolbar { display: flex; flex-wrap: wrap; gap: 24px; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.cart-toolbar label { display: flex; flex-direction: column; gap: 6px; font-size: .85rem; color: var(--muted); }
.cart-toolbar select { padding: 10px 14px; border-radius: 8px; border: 1px solid var(--muted); background: var(--surface); color: var(--text); }
.cart-summary { color: var(--text); }
.cart-items { display: none; background: var(--surface); border-radius: var(--radius); padding: 20px; }
.cart-items table { width: 100%; border-collapse: collapse; }
.cart-items th, .cart-items td { padding: 8px; border-bottom: 1px solid rgba(255,255,255,.08); font-size: .88rem; text-align: left; }
.cart-totals { margin: 16px 0; color: var(--text); }
.cart-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* ---- Torna in cima ---- */
.back-to-top {
    position: fixed;
    right: 24px;
    bottom: 24px;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    border: none;
    background: #e5e7eb;
    color: #4b5563;
    font-size: 1.05rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(0,0,0,.18);
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: opacity .2s ease, transform .2s ease, visibility .2s, background .15s ease;
    z-index: 60;
}
.back-to-top:hover { background: #d1d5db; }
.back-to-top.is-visible { opacity: 1; visibility: visible; transform: translateY(0); }

@media (max-width: 900px) {
    .site-nav .nav-inner { flex-wrap: wrap; }
    .site-nav .nav-links, .site-nav .nav-ctas { display: none; width: 100%; flex-basis: 100%; }
    .site-nav .nav-toggle {
        display: block; margin-left: auto; position: relative; z-index: 210;
        width: 40px; height: 40px; font-size: 1.3rem;
    }
    .site-nav .nav-toggle .fa-xmark { display: none; }
    .site-nav.nav-open .nav-toggle { position: fixed; top: 16px; right: 20px; color: #fff; }
    .site-nav.nav-open .nav-toggle .fa-bars { display: none; }
    .site-nav.nav-open .nav-toggle .fa-xmark { display: inline; }
    .site-nav.nav-open .nav-inner {
        position: fixed; inset: 0; z-index: 200;
        background: var(--ink); overflow-y: auto;
        flex-direction: column; align-items: center; justify-content: flex-start;
        padding: 110px 24px 48px;
    }
    .site-nav.nav-open .brand { display: none; }
    .site-nav.nav-open .nav-links,
    .site-nav.nav-open .nav-ctas {
        display: flex; flex-direction: column; align-items: center; justify-content: flex-start; width: 100%; gap: 0;
    }
    .site-nav.nav-open .nav-links > a {
        color: var(--text-light); width: 100%; text-align: center; padding: 10px 0; font-size: 1.6rem;
    }
    .site-nav.nav-open .nav-ctas { margin-top: 28px; gap: 14px; }
    .site-nav.nav-open .nav-links > *,
    .site-nav.nav-open .nav-ctas > * {
        animation: x0NavCascade .5s ease-out both;
    }
    .site-nav.nav-open .nav-links > *:nth-child(1)  { animation-delay: 0s; }
    .site-nav.nav-open .nav-links > *:nth-child(2)  { animation-delay: .12s; }
    .site-nav.nav-open .nav-links > *:nth-child(3)  { animation-delay: .24s; }
    .site-nav.nav-open .nav-links > *:nth-child(4)  { animation-delay: .36s; }
    .site-nav.nav-open .nav-links > *:nth-child(5)  { animation-delay: .48s; }
    .site-nav.nav-open .nav-links > *:nth-child(6)  { animation-delay: .60s; }
    .site-nav.nav-open .nav-links > *:nth-child(7)  { animation-delay: .72s; }
    .site-nav.nav-open .nav-links > *:nth-child(8)  { animation-delay: .84s; }
    .site-nav.nav-open .nav-ctas > *:nth-child(1) { animation-delay: .48s; }
    .site-nav.nav-open .nav-ctas > *:nth-child(2) { animation-delay: .60s; }
    .two-col { flex-direction: column; }
}
@keyframes x0NavCascade {
    from { opacity: 0; transform: translateY(-18px); }
    to   { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
    .site-nav.nav-open .nav-links > *,
    .site-nav.nav-open .nav-ctas > * { animation: none; opacity: 1; transform: none; }
}

/* ---- Parallax (striscia con immagine di sfondo fissa, testo opzionale) ---- */
.section-parallax {
    min-height: 420px; position: relative;
    background-attachment: fixed; background-position: center; background-repeat: no-repeat; background-size: cover;
}
.section-parallax.has-content { display: flex; align-items: center; color: var(--text-light); }
.parallax-overlay { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(18,22,28,.5), rgba(18,22,28,.72)); }
.parallax-content { position: relative; z-index: 1; text-align: center; max-width: 720px; }
.parallax-content h2 { color: #fff; }
.parallax-content .body { opacity: .92; margin-bottom: 24px; }
@media (max-width: 900px) { .section-parallax { background-attachment: scroll; min-height: 300px; } }
@media (prefers-reduced-motion: reduce) { .section-parallax { background-attachment: scroll; } }

/* ---- Modulo Carbon footprint (includes/carbon.php) ---- */
.x0-carbon-link { display: inline-flex; align-items: center; gap: 10px; padding: 8px 16px; border: 1px solid currentColor; border-radius: var(--radius); color: inherit; font-size: .9rem; text-decoration: none; }
.x0-carbon-link:hover, .x0-carbon-link:focus-visible { background: rgba(127,127,127,.15); }
.x0-carbon-link .carbon-leaf, .carbon-leaf { flex: none; color: #2fb52f; }
.x0-carbon-link sub, .section-carbon sub { font-size: .7em; vertical-align: baseline; position: relative; top: .25em; }
.section-carbon { background: var(--surface); color: var(--text); padding: 56px 0 0; font-size: 1.1rem; line-height: 1.55; }
.section-carbon h2 { font-size: 1.25rem; margin: 0 0 6px; color: var(--brand); }
.section-carbon p, .carbon-body p { margin: 0 0 1.2em; }
.section-carbon a { color: var(--brand); text-decoration: underline; text-underline-offset: 3px; }
.carbon-badge { margin: 32px 0 40px; font-size: 15px; line-height: 1.15; }
.carbon-badge .carbon-badge-link { display: inline-flex; text-decoration: none; }
.carbon-badge-g, .carbon-badge-a { padding: .45em .7em; border: 2px solid #00ffbc; }
.carbon-badge-g { background: #fff; color: #0e11a8; border-right: 0; min-width: 9em; text-align: center; }
.carbon-badge-a { background: #0e11a8; border-color: #0e11a8; color: #fff; font-weight: 700; }
.carbon-badge .carbon-badge-link:hover .carbon-badge-a, .carbon-badge .carbon-badge-link:focus-visible .carbon-badge-a { background: #00ffbc; border-color: #00ffbc; color: #0e11a8; }
.carbon-badge-p { margin: .5em 0 0; font-size: .9em; color: #0e11a8; }
.carbon-grass { height: 96px; background: linear-gradient(#32b83a, #32b83a) left bottom / 100% 6px no-repeat, url("img/erba.svg?v=11") repeat-x left bottom / 1200px 96px; }
