/* ============================================================
   PASTIFICIO PAONE — style.css
   Colori: #9c081c (rosso Paone), bianco crema, oro grano, ambra pasta
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Libre+Baskerville:ital,wght@0,400;0,700;1,400&family=Lora:ital,wght@0,400;0,500;0,600;1,400;1,500;1,600&family=DM+Sans:wght@300;400;500;600&display=swap');

/* ── Variables ─────────────────────────────────────────────── */
:root {
  --rosso:       #9c081c;
  --rosso-dark:  #6e0513;
  --rosso-light: #c4102a;
  --crema:       #fdf6ec;
  --crema-warm:  #f5e8d0;
  --oro:         #c8922a;
  --oro-light:   #e6b96a;
  --grano:       #d4a853;
  --ambra:       #b87333;
  --marrone:     #5c3317;
  --bianco:      #ffffff;
  --testo:       #2a1a0e;
  --testo-medio: #5a3e2b;
  --testo-light: #8b6b4a;

  --font-display: 'Lora', Georgia, serif;
  --font-body:    'Libre Baskerville', Georgia, serif;
  --font-ui:      'DM Sans', sans-serif;

  --transizione: 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --ombra-card: 0 8px 40px rgba(92, 51, 23, 0.18);
  --ombra-hover: 0 16px 64px rgba(92, 51, 23, 0.28);
}

/* ── Reset & Base ───────────────────────────────────────────── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden; /* blocca scroll orizzontale anche su html */
}

body {
  background-color: var(--crema);
  color: var(--testo);
  font-family: var(--font-body);
  font-size: 1.125rem;
  line-height: 1.7;
  overflow-x: hidden;
  max-width: 100vw; /* impedisce che elementi interni allarghino il body */
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transizione);
}

ul, ol {
  list-style: none;
}

/* ── Typography Scale ───────────────────────────────────────── */
h1, h2, h3, h4, h5 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.2;
  color: var(--testo);
}

h1 { font-size: clamp(2.8rem, 7vw, 6rem); }
h2 { font-size: clamp(2rem, 4.5vw, 3.5rem); }
h3 { font-size: clamp(1.5rem, 3vw, 2.2rem); }
h4 { font-size: clamp(1.1rem, 2vw, 1.5rem); font-family: var(--font-ui); font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; }
h5 { font-size: 1rem; font-family: var(--font-ui); font-weight: 500; }

p { margin-bottom: 1.2em; }
p:last-child { margin-bottom: 0; }

.testo-corpo {
  font-family: var(--font-body);
  font-size: clamp(1rem, 1.5vw, 1.2rem);
  line-height: 1.8;
  color: var(--testo-medio);
}

.etichetta {
  font-family: var(--font-ui);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--oro);
}

/* ── Layout Utilities ───────────────────────────────────────── */
.contenitore {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 clamp(1.5rem, 5vw, 4rem);
}

.contenitore--stretto {
  max-width: 860px;
  margin: 0 auto;
  padding: 0 clamp(1.5rem, 5vw, 4rem);
}

.sezione {
  padding: clamp(4rem, 10vw, 9rem) 0;
}

.sezione--chiara { background-color: var(--crema); }
.sezione--calda  { background-color: var(--crema-warm); }
.sezione--scura  { background-color: var(--testo); color: var(--crema); }
.sezione--rosso  { background-color: var(--rosso); color: var(--crema); }

/* ── Decorative Lines ───────────────────────────────────────── */
.linea-oro {
  display: inline-block;
  width: 60px;
  height: 2px;
  background: linear-gradient(90deg, var(--oro), var(--grano));
  margin-bottom: 1.5rem;
}

.linea-oro--centrata { display: block; margin: 0 auto 1.5rem; }

/* ── Buttons ────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-ui);
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  padding: 0.9rem 2.2rem;
  border: none;
  cursor: pointer;
  transition: all var(--transizione);
  position: relative;
  overflow: hidden;
}

.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.12);
  transform: translateX(-100%);
  transition: transform 0.35s ease;
}

.btn:hover::before { transform: translateX(0); }

.btn--primario {
  background-color: var(--rosso);
  color: var(--bianco);
}
.btn--primario:hover {
  background-color: var(--rosso-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(156, 8, 28, 0.35);
}

.btn--bordo {
  background: transparent;
  color: var(--crema);
  border: 1.5px solid rgba(255,255,255,0.6);
}
.btn--bordo:hover {
  background: rgba(255,255,255,0.1);
  border-color: var(--bianco);
  transform: translateY(-2px);
}

.btn--oro {
  background: transparent;
  color: var(--oro-light);
  border: 1.5px solid var(--oro);
}
.btn--oro:hover {
  background: var(--oro);
  color: var(--bianco);
  transform: translateY(-2px);
}

/* Nav glass effect sempre attivo — più morbido all'avvio, più pieno dopo scroll */
.nav-principale {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  max-width: 100vw; /* evita sforamento su Android */
  z-index: 1000;
  transition: background 0.5s ease, backdrop-filter 0.5s ease,
              border-color 0.5s ease, box-shadow 0.5s ease;
  padding: 1.1rem 0;
  background: rgba(20, 8, 3, 0.18);
  backdrop-filter: blur(8px) saturate(1.2);
  -webkit-backdrop-filter: blur(8px) saturate(1.2);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  box-sizing: border-box;
  overflow: hidden; /* taglia qualsiasi figlio che sfori */
}

.nav-principale.scrolled {
  background: rgba(253, 246, 236, 0.96);
  backdrop-filter: blur(16px) saturate(1.5);
  -webkit-backdrop-filter: blur(16px) saturate(1.5);
  border-bottom: 1px solid rgba(200, 146, 42, 0.15);
  box-shadow: 0 2px 24px rgba(92, 51, 23, 0.1);
}

.nav-principale.scrolled .nav-link { color: var(--testo); }
.nav-principale.scrolled .nav-link:hover { color: var(--rosso); }

.nav-interna {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-width: 0; /* permette ai figli flex di restringersi */
}

.nav-logo img {
  height: 54px;
  width: auto;
  transition: height 0.4s ease;
  filter: drop-shadow(0 0 18px rgba(255, 255, 255, 0.22)) drop-shadow(0 0 6px rgba(255, 255, 255, 0.12));
}

.nav-lista {
  display: flex;
  align-items: center;
  gap: clamp(0.6rem, 1.6vw, 2.2rem);
}

.nav-link {
  font-family: var(--font-ui);
  font-size: clamp(0.62rem, 0.75vw, 0.82rem);
  font-weight: 500;
  letter-spacing: clamp(0.04em, 0.06vw, 0.12em);
  text-transform: uppercase;
  color: rgba(255,255,255,0.9);
  transition: all var(--transizione);
  position: relative;
  padding-bottom: 3px;
  white-space: nowrap;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--oro-light);
  transition: width var(--transizione);
}

.nav-link:hover::after,
.nav-link.attivo::after { width: 100%; }

.nav-link:hover { color: var(--oro-light); }

.nav-lingua {
  display: flex;
  gap: 0.4rem;
  align-items: center;
  margin-left: 1.5rem;
}

.nav-lingua a {
  font-family: var(--font-ui);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: rgba(255,255,255,0.6);
  transition: color var(--transizione);
  padding: 0.2rem 0.4rem;
}

.nav-lingua a:hover,
.nav-lingua a.attivo { color: var(--oro-light); }

.nav-lingua span { color: rgba(255,255,255,0.25); font-size: 0.7rem; }

/* nav scrolled lingua */
.nav-principale.scrolled .nav-lingua a { color: var(--testo-light); }
.nav-principale.scrolled .nav-lingua a:hover,
.nav-principale.scrolled .nav-lingua a.attivo { color: var(--rosso); }
.nav-principale.scrolled .nav-lingua span { color: var(--crema-warm); }

/* Menu hamburger mobile */
.nav-hamburger {
  display: none;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1.5px solid rgba(255,255,255,0.45);
  background: rgba(255,255,255,0.08);
  cursor: pointer;
  padding: 0;
  transition: all 0.35s ease;
  position: relative;
  flex-shrink: 0;
}

.nav-hamburger:hover {
  border-color: var(--oro-light);
  background: rgba(200, 146, 42, 0.12);
}

.nav-hamburger::before,
.nav-hamburger::after {
  content: '';
  position: absolute;
  background: var(--bianco);
  border-radius: 2px;
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-hamburger::before {
  width: 16px;
  height: 1.5px;
}

.nav-hamburger::after {
  width: 1.5px;
  height: 16px;
}

.nav-hamburger.aperto {
  border-color: rgba(255,255,255,0.5);
  background: rgba(255,255,255,0.1);
}

.nav-hamburger.aperto::before {
  transform: rotate(45deg);
  width: 18px;
}

.nav-hamburger.aperto::after {
  transform: rotate(45deg);
  height: 18px;
}

.nav-principale.scrolled .nav-hamburger {
  border-color: rgba(42, 26, 14, 0.35);
  background: rgba(42, 26, 14, 0.06);
}

.nav-principale.scrolled .nav-hamburger::before,
.nav-principale.scrolled .nav-hamburger::after {
  background: var(--testo);
}

.nav-principale.scrolled .nav-hamburger:hover {
  border-color: var(--rosso);
  background: rgba(156, 8, 28, 0.07);
}

.nav-hamburger span { display: none; }

/* Menu mobile overlay */
.nav-mobile {
  display: none;
  position: fixed;
  inset: 0;
  background: var(--testo);
  z-index: 999;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
  overflow: hidden;           /* niente scroll orizzontale nel menu mobile */
  overscroll-behavior: contain; /* blocca il bounce che trascina la pagina */
  width: 100%;
  max-width: 100vw;
}

.nav-mobile.aperto {
  display: flex;
  opacity: 1;
  pointer-events: all;
}

.nav-mobile .nav-link {
  font-size: 1.6rem;
  font-family: var(--font-display);
  letter-spacing: 0.04em;
  text-transform: none;
  color: var(--crema);
}

.nav-mobile .nav-link::after { background: var(--oro); }

/* ── Hero ───────────────────────────────────────────────────── */
.hero {
  position: sticky;
  top: 0;
  height: 100vh;
  min-height: 600px;
  max-height: 1100px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1;
}

.hero-slider {
  position: absolute;
  inset: 0;
}

.hero-slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 1.6s cubic-bezier(0.4, 0, 0.2, 1),
              transform 8s ease;
  transform: scale(1.07);
}

.hero-slide.attivo {
  opacity: 1;
  transform: scale(1.0);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    160deg,
    rgba(30, 10, 5, 0.25) 0%,
    rgba(92, 51, 23, 0.3) 40%,
    rgba(20, 8, 3, 0.72) 100%
  );
}

.hero-overlay-bottom {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 45%;
  background: linear-gradient(to top, rgba(15, 5, 2, 0.85) 0%, transparent 100%);
}

.hero-contenuto {
  position: relative;
  z-index: 10;
  width: 100%;
  text-align: center;
  overflow: visible;
}

.hero-contenuto .contenitore {
  display: flex;
  flex-direction: column;
  align-items: center;
  overflow: visible;
}

.hero-testo {
  max-width: 740px;
  display: flex;
  flex-direction: column;
  align-items: center;
  overflow: visible;
}

.hero-logo {
  margin-bottom: 1.8rem;
  opacity: 0;
  animation: fadeUp 0.9s 0.1s forwards;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: visible;
}

.hero-logo::before {
  content: '';
  position: absolute;
  inset: -52px;
  border-radius: 50%;
  background: radial-gradient(ellipse at center,
    rgba(255, 255, 255, 0.38) 0%,
    rgba(255, 245, 210, 0.16) 42%,
    transparent 72%
  );
  pointer-events: none;
  z-index: 0;
}

.hero-logo img {
  height: clamp(52px, 7vw, 80px);
  width: auto;
  opacity: 0.97;
  position: relative;
  z-index: 1;
  animation: logoPulse 3.6s ease-in-out infinite;
  transform-origin: center;
  will-change: transform;
}

.hero-etichetta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.8rem;
  margin-bottom: 1.6rem;
  opacity: 0;
  animation: fadeUp 0.8s 0.4s forwards;
}

.hero-etichetta .linea { width: 36px; height: 1px; background: var(--oro-light); }

.hero-etichetta span {
  font-family: var(--font-ui);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--oro-light);
  text-shadow: 0 1px 8px rgba(10, 3, 1, 0.7);
}

/* ─────────────────────────────────────────────────────────────
   HERO TITOLO — FIX SLIDER
   ───────────────────────────────────────────────────────────── */
.hero-titolo {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5.5vw, 4.6rem);
  font-weight: 400;
  font-style: italic;
  color: var(--bianco);
  line-height: 1.15;
  margin-bottom: 1.4rem;
  text-align: center;
  letter-spacing: -0.01em;
  text-shadow:
    0 1px 3px rgba(8, 2, 0, 0.75),
    0 4px 18px rgba(8, 2, 0, 0.55),
    0 10px 40px rgba(8, 2, 0, 0.35);
  opacity: 0;
  transform: translateY(28px);
}

.hero-titolo span {
  display: block;
}

.hero-titolo em {
  display: block;
  font-style: normal;
  color: var(--oro-light);
  font-weight: 400;
  text-shadow:
    0 1px 4px rgba(8, 2, 0, 0.7),
    0 4px 20px rgba(8, 2, 0, 0.45);
}

.hero-sottotitolo {
  font-family: var(--font-body);
  font-size: clamp(0.95rem, 1.6vw, 1.15rem);
  font-weight: 400;
  font-style: italic;
  color: rgba(253, 246, 236, 0.9);
  line-height: 1.7;
  margin-bottom: 2.6rem;
  max-width: 500px;
  text-align: center;
  text-shadow:
    0 1px 3px rgba(8, 2, 0, 0.7),
    0 3px 14px rgba(8, 2, 0, 0.45);
  opacity: 0;
  animation: fadeUp 0.9s 1s forwards;
}

.hero-azioni {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  justify-content: center;
  opacity: 0;
  animation: fadeUp 0.8s 1.3s forwards;
}

/* Hero — indicatori slide */
.hero-indicatori {
  position: absolute;
  bottom: clamp(1.8rem, 3.5vw, 3rem);
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  display: flex;
  flex-direction: row;
  gap: 0.7rem;
  align-items: center;
}

.hero-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.22);
  border: 1.5px solid rgba(255, 255, 255, 0.45);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  cursor: pointer;
  transition: all 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
  padding: 0;
  box-shadow: 0 2px 8px rgba(0,0,0,0.18);
  position: relative;
  overflow: hidden;
}

.hero-dot::after { display: none; }

.hero-dot:hover {
  background: rgba(255, 255, 255, 0.42);
  border-color: rgba(255, 255, 255, 0.75);
  transform: scale(1.2);
}

.hero-dot.attivo {
  width: 10px;
  height: 10px;
  background: rgba(255, 255, 255, 0.85);
  border-color: rgba(255, 255, 255, 0.9);
  box-shadow:
    0 0 0 3px rgba(255, 255, 255, 0.2),
    0 2px 12px rgba(0, 0, 0, 0.25);
  transform: scale(1.25);
}

.hero-scroll {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  position: absolute;
  bottom: clamp(2.5rem, 5vw, 4rem);
  right: clamp(1.5rem, 4vw, 3.5rem);
  left: auto;
  transform: none;
  z-index: 10;
  animation: bobbing 2.4s ease-in-out infinite;
}

.hero-scroll span {
  font-family: var(--font-ui);
  font-size: 0.65rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.45);
}

.hero-scroll-freccia {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, var(--oro-light), transparent);
}

/* ── Animazioni ─────────────────────────────────────────────── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(28px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes logoPulse {
  0%, 100% { transform: scale(1);    opacity: 0.97; }
  50%       { transform: scale(1.07); opacity: 1;    }
}

@keyframes bobbing {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(10px); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* ── Footer ─────────────────────────────────────────────────── */
.footer {
  background-color: var(--testo);
  color: var(--crema);
  position: relative;
  overflow: hidden;
}

.footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--rosso), var(--oro), var(--rosso));
}

.footer-firma {
  display: block;
  height: clamp(40px, 6vw, 64px);
  width: auto;
  margin-top: 1.4rem;
  opacity: 0.55;
  pointer-events: none;
  user-select: none;
}

.footer-top {
  padding: clamp(2rem, 4vw, 3.5rem) 0 clamp(2.5rem, 5vw, 4rem);
}

.footer-griglia {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: clamp(2rem, 4vw, 4rem);
}

.footer-logo img {
  height: 52px;
  width: auto;
  opacity: 0.9;
  margin-bottom: 1.4rem;
}

.footer-payoff {
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-style: italic;
  color: rgba(253, 246, 236, 0.45);
  line-height: 1.6;
  margin-bottom: 1.6rem;
}

.footer-social {
  display: flex;
  gap: 0.7rem;
}

.footer-social a {
  width: 32px;
  height: 32px;
  border: 1px solid rgba(255,255,255,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transizione);
  color: rgba(255,255,255,0.4);
}

.footer-social a:hover {
  border-color: var(--oro);
  color: var(--oro-light);
  background: rgba(200, 146, 42, 0.08);
  transform: translateY(-2px);
}

.footer-titolo-col {
  font-family: var(--font-ui);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(200, 146, 42, 0.7);
  margin-bottom: 1.2rem;
  position: relative;
  padding-bottom: 0.7rem;
}

.footer-titolo-col::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 20px;
  height: 1px;
  background: rgba(200, 146, 42, 0.4);
}

.footer-lista li { margin-bottom: 0.5rem; }

.footer-lista a {
  font-family: var(--font-ui);
  font-size: 0.85rem;
  color: rgba(253, 246, 236, 0.5);
  transition: color var(--transizione);
}

.footer-lista a:hover { color: rgba(253, 246, 236, 0.9); }

.footer-info-riga {
  font-family: var(--font-ui);
  font-size: 0.85rem;
  color: rgba(253, 246, 236, 0.5);
  line-height: 1.7;
  margin-bottom: 0.3rem;
}

.footer-info-riga a {
  color: rgba(253, 246, 236, 0.5);
  transition: color var(--transizione);
}
.footer-info-riga a:hover { color: var(--oro-light); }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.06);
  padding: 1.2rem 0;
}

.footer-bottom-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.footer-copyright {
  font-family: var(--font-ui);
  font-size: 0.72rem;
  color: rgba(253, 246, 236, 0.25);
  letter-spacing: 0.04em;
}

.footer-bottom-links {
  display: flex;
  gap: 1.5rem;
}

.footer-bottom-links a {
  font-family: var(--font-ui);
  font-size: 0.72rem;
  color: rgba(253, 246, 236, 0.25);
  transition: color var(--transizione);
}

.footer-bottom-links a:hover { color: rgba(253, 246, 236, 0.6); }

.footer-dev {
  font-family: var(--font-ui);
  font-size: 0.72rem;
  color: rgba(253, 246, 236, 0.2);
  letter-spacing: 0.03em;
}

.footer-dev a {
  color: rgba(253, 246, 236, 0.35);
  transition: color var(--transizione);
}

.footer-dev a:hover { color: rgba(253, 246, 236, 0.65); }

/* ── Responsive ─────────────────────────────────────────────── */

/* Spagnolo: hamburger sotto 1024px (voci più lunghe) */
@media (max-width: 1024px) {
  .lang-es .nav-lista    { display: none; }
  .lang-es .nav-hamburger { display: flex; }
}

@media (max-width: 1024px) {
  .footer-griglia {
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
  }

  .nav-lista { gap: clamp(0.5rem, 1.2vw, 1.4rem); }
  .nav-link  {
    font-size: clamp(0.68rem, 0.9vw, 0.82rem);
    letter-spacing: clamp(0.04em, 0.06vw, 0.12em);
  }

  /* Impedisce che la nav-lista sfori il viewport su tablet */
  .nav-interna {
    overflow: hidden;
  }
}


@media (max-width: 768px) {
  .nav-lista { display: none; }
  .nav-hamburger { display: flex; }

  .hero {
    padding-top: 72px;
    align-items: center;
  }

  .hero-contenuto {
    padding-left: max(1.4rem, env(safe-area-inset-left));
    padding-right: max(1.4rem, env(safe-area-inset-right));
    padding-bottom: max(1.5rem, env(safe-area-inset-bottom));
  }

  .hero-testo {
    max-width: 100%;
    width: 100%;
  }

  .hero-titolo {
    font-size: clamp(1.7rem, 6.5vw, 2.4rem);
    margin-bottom: 1rem;
  }

  .hero-sottotitolo {
    font-size: 0.9rem;
    margin-bottom: 1.8rem;
  }

  .hero-logo img {
    height: clamp(68px, 16vw, 96px);
  }

  .hero-indicatori {
    bottom: 1.4rem;
  }

  .hero-dot { width: 9px; height: 9px; }
  .hero-dot.attivo { width: 9px; height: 9px; }

  .hero-azioni {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    width: 100%;
    gap: 0.6rem;
  }

  .hero-azioni .btn {
    flex: 1 1 auto;
    min-width: 130px;
    max-width: 180px;
    justify-content: center;
    font-size: 0.72rem;
    padding: 0.75rem 1rem;
    letter-spacing: 0.08em;
  }

  .hero {
    position: relative;
    top: auto;
  }

  #sezione-intro {
    box-shadow: none;
  }

  .hero-scroll { display: none; }

  .footer-griglia {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .footer-bottom-inner {
    flex-direction: column;
    text-align: center;
    gap: 0.5rem;
  }

  .footer-bottom-links { justify-content: center; }
}

@media (max-width: 480px) {
  .hero-titolo    { font-size: 1.55rem; line-height: 1.2; }
  .hero-logo img  { height: clamp(52px, 12vw, 72px); }
  .nav-logo img   { height: 38px; }

  .hero-azioni .btn {
    font-size: 0.68rem;
    padding: 0.7rem 0.9rem;
    min-width: 120px;
  }
}

/* ── Parallax wrap ───────────────────────────────────────────── */
.parallax-wrap {
  position: relative;
}

/* ── Home Sections ───────────────────────────────────────────── */
.home-riga {
  position: relative;
  z-index: 2;
  padding: 0;
}

#sezione-intro {
  margin-top: 0;
  box-shadow: 0 -24px 60px rgba(20, 8, 3, 0.22);
}

.home-riga--chiara { background-color: var(--crema); }
.home-riga--calda  { background-color: var(--crema-warm); }

.home-riga-griglia {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  width: 100%;
  min-height: clamp(420px, 55vw, 680px);
}

.home-riga-griglia--inversa .home-riga-media { order: -1; }

.home-riga-testo {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  padding: clamp(3rem, 7vw, 6rem) clamp(2rem, 6vw, 5rem);
}

.home-titolo {
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 3vw, 2.8rem);
  font-weight: 400;
  font-style: italic;
  color: var(--testo);
  line-height: 1.2;
  margin: 1rem 0 1.4rem;
}

.home-corpo {
  font-family: var(--font-body);
  font-size: clamp(0.95rem, 1.3vw, 1.05rem);
  color: var(--testo-medio);
  line-height: 1.8;
  margin-bottom: 0;
}

.home-corpo strong {
  color: var(--testo);
  font-weight: 700;
}

.home-media-wrap {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: clamp(320px, 45vw, 680px);
  overflow: hidden;
  background: var(--crema-warm);
}

.home-img,
.home-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.home-media-wrap:hover .home-img,
.home-media-wrap:hover .home-video {
  transform: scale(1.04);
}

/* ── Reveal on scroll ────────────────────────────────────────── */
.rivela {
  opacity: 0;
  transition: opacity 0.9s ease, transform 0.9s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.rivela[data-dir="sx"] { transform: translateX(-40px); }
.rivela[data-dir="dx"] { transform: translateX(40px); }

.rivela.visibile {
  opacity: 1;
  transform: translateX(0);
}

.home-deco-img {
  display: block;
  max-width: 100%;
  width: clamp(160px, 28vw, 320px);
  height: auto;
  margin-top: 1.8rem;
  object-fit: contain;
}

/* ── Home Responsive ─────────────────────────────────────────── */
@media (max-width: 900px) {
  .home-riga-griglia,
  .home-riga-griglia--inversa {
    grid-template-columns: 1fr;
  }

  .home-riga-griglia--inversa .home-riga-media { order: 0; }
  .home-riga-media { order: -1; }

  .home-media-wrap { min-height: 56vw; }

  .home-titolo { font-size: clamp(1.6rem, 5vw, 2.2rem); }
}

/* ── Section Storia ──────────────────────────────────────────── */
.storia-section {
  position: relative;
  z-index: 2;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: clamp(5rem, 10vw, 9rem) clamp(1.5rem, 5vw, 4rem);
}

.storia-bg {
  position: absolute;
  inset: -20%;
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  z-index: 0;
}

.storia-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    160deg,
    rgba(20, 8, 3, 0.62) 0%,
    rgba(42, 26, 14, 0.72) 60%,
    rgba(20, 8, 3, 0.82) 100%
  );
  z-index: 1;
}

.storia-linea-top,
.storia-linea-bottom {
  position: absolute;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--rosso), var(--oro), var(--rosso));
  z-index: 3;
}

.storia-linea-top    { top: 0; }
.storia-linea-bottom { bottom: 0; }

.storia-inner {
  position: relative;
  z-index: 2;
  max-width: 780px;
  width: 100%;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.4rem;
}

.storia-etichetta {
  color: var(--oro-light);
  letter-spacing: 0.28em;
}

.storia-titolo {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5vw, 4.2rem);
  font-weight: 400;
  font-style: italic;
  color: var(--bianco);
  line-height: 1.15;
  margin: 0;
  text-shadow:
    0 2px 4px rgba(8, 2, 0, 0.6),
    0 6px 24px rgba(8, 2, 0, 0.4);
}

.storia-linea {
  opacity: 0.6;
}

.storia-corpo {
  font-family: var(--font-body);
  font-size: clamp(0.95rem, 1.5vw, 1.1rem);
  font-style: italic;
  color: rgba(253, 246, 236, 0.82);
  line-height: 1.85;
  margin: 0;
  text-shadow: 0 1px 6px rgba(8, 2, 0, 0.5);
}

.storia-sottocorpo {
  font-family: var(--font-ui);
  font-size: clamp(0.82rem, 1.1vw, 0.95rem);
  letter-spacing: 0.1em;
  color: rgba(253, 246, 236, 0.5);
  margin: 0;
  text-transform: uppercase;
}

@media (max-width: 768px) {
  .storia-bg {
    background-attachment: scroll;
    inset: 0;
  }

  .storia-titolo { font-size: clamp(2rem, 8vw, 2.8rem); }
}

/* ── Pasta Slider ────────────────────────────────────────────── */

/* Striscia titolo rossa */
.pasta-titolo-striscia {
  background: transparent;
  padding: 0.75rem clamp(1.5rem, 5vw, 4rem);
}

.pasta-titolo-striscia-testo {
  font-family: var(--font-ui);
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #ffffff;
  text-shadow: 0 1px 6px rgba(0,0,0,0.55), 0 2px 18px rgba(0,0,0,0.35);
  margin: 0;
}

.pasta-slider-section {
  position: relative;
  z-index: 2;
  background: #e9decf;
  padding: clamp(1rem, 2vw, 1.5rem) 0 clamp(0.8rem, 1.5vw, 1.2rem);
}

.pasta-slider-header {
  display: none;
}

/* Wrapper con frecce ai lati — full width */
.pasta-slider-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
}

.pasta-slider-viewport {
  overflow: hidden;
  position: relative;
  cursor: grab;
  user-select: none;
  flex: 1;
  min-width: 0;
}

.pasta-slider-viewport:active { cursor: grabbing; }

.pasta-slider-track {
  display: flex;
  gap: 0;
  transition: transform 0.45s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  will-change: transform;
}

/* ── Pasta Card — no bordi, sfondo bianco ───────────────────── */
.pasta-card {
  flex: 0 0 auto;
  width: 160px;
  padding: 0.6rem 0.6rem 0.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: background 0.3s ease;
  position: relative;
  background: transparent;
}

.pasta-card:hover {
  background: transparent;
}

.pasta-card-img-wrap {
  width: 160px;
  height: 160px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0.5rem;
  background: transparent;
}

.pasta-card-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  mix-blend-mode: multiply;
  transition: transform 0.4s ease;
}

.pasta-card:hover .pasta-card-img { transform: translateY(-5px) scale(1.04); }

.pasta-card-nome {
  font-family: var(--font-ui);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--testo-medio);
  text-align: center;
  margin: 0;
  transition: color 0.3s;
}

.pasta-card:hover .pasta-card-nome { color: var(--rosso); }

/* Frecce laterali — allineate verticalmente al centro delle immagini */
.pasta-slider-nav {
  display: none; /* nascosto — ora le frecce sono nel wrapper */
}

.pasta-nav-btn {
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  border: none;
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(90, 62, 43, 0.35);
  transition: all 0.3s ease;
  padding: 0;
  margin: 0 clamp(0.5rem, 1.5vw, 1.5rem);
}

.pasta-nav-btn:hover {
  color: var(--rosso);
}

.pasta-nav-btn svg {
  width: 22px;
  height: 22px;
  stroke-width: 1.5;
}

@media (max-width: 768px) {
  .pasta-card { width: 200px; }
  .pasta-card-img-wrap { width: 200px; height: 200px; }
  .pasta-nav-btn { width: 28px; }
}

/* ── Loader ──────────────────────────────────────────────────── */
.loader {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  min-height: 100dvh;
  min-height: 100vh;
  z-index: 99999;
  background-color: #3a1f0d;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translateZ(0);
  -webkit-transform: translateZ(0);
  transition: opacity 0.6s ease, visibility 0.6s ease;
}

.loader.nascosto {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.loader-inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: clamp(200px, 50vmin, 260px);
  height: clamp(200px, 50vmin, 260px);
}

.loader-arco {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  animation: loader-ruota 1.6s linear infinite;
}

.loader-arco-traccia {
  stroke: rgba(200, 146, 42, 0.12);
}

.loader-arco-giro {
  stroke: var(--oro);
  stroke-dashoffset: 0;
  transform-origin: center;
}

.loader-logo {
  position: relative;
  z-index: 1;
  width: clamp(100px, 14vw, 140px);
  height: auto;
  animation: loader-pulsa 2s ease-in-out infinite;
}

@keyframes loader-ruota {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

@keyframes loader-pulsa {
  0%, 100% { opacity: 0.75; transform: scale(1); }
  50%       { opacity: 1;    transform: scale(1.04); }
}

body.loading {
  overflow: hidden;
}

/* ── Texture grain overlay globale ───────────────────────────── */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.022;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  background-size: 256px;
}