/* =========================================================
   LA MAISON GROUP — stile del sito
   Mobile first · breakpoint 768px e 1024px
   ========================================================= */

:root {
  /* Colori */
  --navy: #0B1F3A;
  --navy-light: #1C3A63;
  --gold: #C9A227;
  --white: #FFFFFF;
  --grey-bg: #F4F6F9;
  --text: #1A1A1A;
  --text-muted: #5A6475;
  --border: #D5DAE1;
  --whatsapp: #25D366;
  --success: #1E7B4C;
  --error: #B42318;

  /* Forme */
  --radius: 8px;
  --radius-btn: 6px;
  --shadow: 0 4px 16px rgba(11, 31, 58, 0.08);
  --shadow-hover: 0 12px 32px rgba(11, 31, 58, 0.14);

  /* Spaziature (solo questi valori) */
  --s-4: 4px;
  --s-8: 8px;
  --s-12: 12px;
  --s-16: 16px;
  --s-24: 24px;
  --s-32: 32px;
  --s-48: 48px;
  --s-64: 64px;
  --s-96: 96px;
  --s-128: 128px;

  /* Misure che cambiano con lo schermo (telefono) */
  --gutter: 20px;
  --section-y: 56px;
  --header-h: 84px;
  --logo-h: 70px; /* +40% (ottobre 2026) */
  --grid-gap: var(--s-24);

  /* Testi (telefono) */
  --fs-h1: 40px;
  --fs-h2: 28px;
  --fs-h3: 20px;
  --fs-body: 16px;
  --fs-label: 12px;

  --font-title: "Playfair Display", Georgia, "Times New Roman", serif;
  --font-text: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

@media (min-width: 768px) {
  :root {
    --gutter: 32px;
    --section-y: 72px;
    --header-h: 92px;
    --logo-h: 78px; /* +40% (ottobre 2026) */
    --fs-h1: 52px;
    --fs-h2: 34px;
    --fs-h3: 22px;
  }
}

@media (min-width: 1024px) {
  :root {
    --gutter: 40px;
    --section-y: 96px;
    --header-h: 112px;
    --logo-h: 94px; /* +40% (ottobre 2026) */
    --grid-gap: var(--s-32);
    --fs-h1: 64px;
    --fs-h2: 40px;
    --fs-h3: 24px;
    --fs-body: 17px;
    --fs-label: 13px;
  }
}

/* ---------- Base ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-h);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--white);
  color: var(--text);
  font-family: var(--font-text);
  font-size: var(--fs-body);
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

body.menu-open { overflow: hidden; }

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
ul { margin: 0; padding: 0; list-style: none; }
p { margin: 0 0 var(--s-16); }

:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

.skip-link {
  position: absolute; top: var(--s-8); left: var(--s-8); z-index: 100;
  padding: var(--s-8) var(--s-16); background: var(--gold); color: var(--navy);
  border-radius: var(--radius-btn); transform: translateY(-200%);
}
.skip-link:focus { transform: none; }

.container {
  width: 100%;
  max-width: calc(1200px + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* ---------- Tipografia ---------- */
h1, h2, h3 {
  font-family: var(--font-title);
  font-weight: 600;
  line-height: 1.2;
  color: var(--navy);
  margin: 0;
}
h1 { font-size: var(--fs-h1); line-height: 1.1; }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); }

/* Oro su bianco solo nei titoli da 24px in su (h1, h2) */
h1 .accent,
h2 .accent { color: var(--gold); }
/* Parole in oro dentro i testi: stesso oro dei titoli */
p .accent { color: var(--gold); font-weight: 600; }

.label {
  display: block;
  margin: 0 0 var(--s-12);
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  line-height: 1.4;
  color: var(--navy-light); /* su sfondo chiaro: l'oro piccolo non si legge */
}
.label::before {
  content: "";
  display: inline-block;
  width: var(--s-24);
  height: 2px;
  margin-right: var(--s-12);
  vertical-align: middle;
  background: var(--gold); /* linea decorativa in oro */
}
.on-navy .label { color: var(--gold); }

.section-head {
  max-width: 720px;
  margin-bottom: var(--s-32);
}
.section-head--center { margin-inline: auto; text-align: center; }
.section-head p { margin: var(--s-16) 0 0; color: var(--text-muted); }

.section-head-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--s-24);
  margin-bottom: var(--s-32);
}
.section-head-row .section-head { margin-bottom: 0; }

@media (min-width: 1024px) {
  .section-head,
  .section-head-row { margin-bottom: var(--s-48); }
}

/* ---------- Pulsanti ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--s-8);
  min-height: 48px;
  padding: 0 28px;
  border: 2px solid transparent;
  border-radius: var(--radius-btn);
  font-family: var(--font-text);
  font-size: 16px;
  font-weight: 600;
  line-height: 1.2;
  text-align: center;
  cursor: pointer;
  transition: background-color 0.3s, color 0.3s, border-color 0.3s;
}
.btn svg { width: 20px; height: 20px; flex: none; }

.btn--primary { background: var(--navy); color: var(--white); }
.btn--primary:hover { background: var(--navy-light); }

.btn--secondary { border-color: var(--navy); color: var(--navy); background: transparent; }
.btn--secondary:hover { background: var(--navy); color: var(--white); }

/* Su sfondo navy */
.btn--gold { background: var(--gold); color: var(--navy); }
.btn--gold:hover { background: var(--white); }

.btn--outline-light { border-color: var(--white); color: var(--white); background: transparent; }
.btn--outline-light:hover { background: var(--white); color: var(--navy); }

.btn-row { display: flex; flex-wrap: wrap; gap: var(--s-12); }

/* ---------- Header ---------- */
.header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  height: var(--header-h);
  background: transparent;
  transition: background-color 0.3s, box-shadow 0.3s;
}
/* Trasparente in cima alla pagina; navy quando si scorre, per restare leggibile sulle sezioni chiare */
.header.is-scrolled { background: var(--navy); box-shadow: 0 4px 24px rgba(0, 0, 0, 0.25); }
/* Menu aperto: header e pannello bianchi */
.menu-open .header { background: var(--white); box-shadow: none; }
.menu-open .burger { color: var(--navy); }

.header__inner {
  display: flex;
  align-items: center;
  gap: var(--s-32);
  height: 100%;
}

/* Logo con sfondo trasparente: versione chiara sul blu, originale quando la barra è bianca (menù aperto) */
.header__logo { display: block; flex: none; }
.header__logo img { display: block; height: var(--logo-h); width: auto; }
.header__logo .logo--dark { display: none; }
.menu-open .header .logo--light { display: none; }
.menu-open .header .logo--dark { display: block; }

.nav { display: none; }

.header__cta { display: none; }

.burger {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  margin-left: auto;
  padding: 0;
  border: 0;
  background: none;
  color: var(--white);
  cursor: pointer;
}
.burger svg { width: 28px; height: 28px; }
.burger .icon-close { display: none; }
.menu-open .burger .icon-open { display: none; }
.menu-open .burger .icon-close { display: block; }

@media (min-width: 1024px) {
  .burger { display: none; }
  .nav {
    display: flex;
    gap: var(--s-16);
    margin-left: auto;
  }
  .nav a {
    position: relative;
    padding: var(--s-8) 0;
    font-size: 15px;
    color: var(--white);
    white-space: nowrap;
    transition: color 0.3s;
  }
  .nav a:hover,
  .nav a[aria-current="page"] { color: var(--gold); }
  .nav a[aria-current="page"]::after {
    content: "";
    position: absolute;
    left: 0; right: 0; bottom: 0;
    height: 2px;
    background: var(--gold);
  }
}

/* Il pulsante in header entra solo quando c'è spazio per tutte le voci */
@media (min-width: 1280px) {
  .nav { gap: var(--s-24); }
  .header__cta { display: inline-flex; }
}

/* Pannello menu a tutto schermo (sotto 1024px) */
.mobile-menu {
  position: fixed;
  inset: var(--header-h) 0 0 0;
  z-index: 49;
  display: flex;
  flex-direction: column;
  gap: var(--s-32);
  padding: var(--s-32) var(--gutter) var(--s-48);
  overflow-y: auto;
  background: var(--white);
  opacity: 0;
  visibility: hidden;
  transform: translateY(calc(-1 * var(--s-16)));
  transition: opacity 0.3s, transform 0.3s, visibility 0.3s;
}
.menu-open .mobile-menu { opacity: 1; visibility: visible; transform: none; }

.mobile-menu ul { display: flex; flex-direction: column; }
.mobile-menu li a {
  display: block;
  padding: var(--s-12) 0;
  border-bottom: 1px solid rgba(11, 31, 58, 0.12);
  font-family: var(--font-title);
  font-size: 24px;
  color: var(--navy);
}
.mobile-menu li a[aria-current="page"] { color: var(--navy-light); text-decoration: underline; text-decoration-color: var(--gold); text-underline-offset: 6px; }
.mobile-menu .btn { align-self: flex-start; }
.mobile-menu .btn--gold:hover { background: var(--navy); color: var(--white); }

@media (min-width: 1024px) {
  .mobile-menu { display: none; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  display: flex;
  align-items: center;
  height: 100vh;
  height: 100svh;
  min-height: 600px;
  max-height: 900px;
  padding-top: var(--header-h);
  overflow: hidden;
  background: var(--navy);
  color: var(--white);
}
.hero__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: rgba(11, 31, 58, 0.6); /* velatura navy al 60% */
}
.hero__content { position: relative; z-index: 2; }
.hero h1 { color: var(--white); letter-spacing: 1px; }
/* Titolo della Home: corsivo elegante, sempre maiuscolo */
.hero #hero-title {
  font-family: "Cormorant Garamond", var(--font-title);
  font-style: italic;
  font-weight: 600;
  font-size: calc(var(--fs-h1) * 1.2);
  line-height: 1;
  letter-spacing: 3px;
  text-transform: uppercase;
}
.hero #hero-title strong { font-weight: 700; }
.hero h1 .accent { color: var(--gold); }
.hero__subtitle {
  max-width: 640px;
  margin: var(--s-16) 0 var(--s-32);
  font-family: var(--font-title);
  font-size: 20px;
  line-height: 1.4;
  color: var(--gold);
}
@media (min-width: 1024px) {
  .hero__subtitle { font-size: 24px; margin-bottom: var(--s-48); }
}

/* ---------- Sezioni ---------- */
.section { padding-block: var(--section-y); }
.section--grey { background: var(--grey-bg); }
.section--navy { background: var(--navy); color: var(--white); }
.section--navy h2 { color: var(--white); }

.section__footer {
  display: flex;
  justify-content: center;
  margin-top: var(--s-32);
}
@media (min-width: 1024px) {
  .section__footer { margin-top: var(--s-48); }
}

/* ---------- Griglie: 1 / 2 / 3 per riga ---------- */
.grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--grid-gap);
}
@media (min-width: 768px) {
  .grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
  .grid--3 { grid-template-columns: repeat(3, 1fr); }
  .grid--4 { grid-template-columns: repeat(4, 1fr); }
}

/* ---------- Schede ---------- */
.card {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-hover); }

.card__media {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--grey-bg);
}
.card__media img { width: 100%; height: 100%; object-fit: cover; }

.card__body {
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: var(--s-8);
  padding: var(--s-24);
}
.card__body p { margin: 0; color: var(--text-muted); }
.card__meta {
  font-size: 14px;
  color: var(--text-muted);
}
.card__link {
  margin-top: auto;
  padding-top: var(--s-8);
  font-weight: 600;
  color: var(--navy);
}
.card__link::after { content: " →"; }
.card .btn { margin-top: auto; align-self: flex-start; }

/* Tutta la scheda cliccabile */
.card__stretched::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
}

.badge {
  position: absolute;
  top: var(--s-12);
  left: var(--s-12);
  z-index: 2;
  padding: var(--s-4) var(--s-12);
  border-radius: var(--s-16);
  background: var(--navy);
  color: var(--white);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
}
.badge--example { left: auto; right: var(--s-12); background: var(--white); color: var(--navy); }

/* Icona dei servizi */
.icon-circle {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  margin-bottom: var(--s-8);
  border-radius: 50%;
  background: var(--navy);
  color: var(--gold);
  flex: none;
}
.icon-circle svg { width: 24px; height: 24px; }
.service .icon-circle {
  position: absolute;
  top: calc(-1 * var(--s-24));
  left: var(--s-24);
  margin: 0;
  box-shadow: 0 0 0 var(--s-4) var(--white);
}
.service .card__body { position: relative; padding-top: var(--s-48); }

/* ---------- Perché sceglierci ---------- */
.feature {
  display: flex;
  flex-direction: column;
  gap: var(--s-8);
}
.feature p { margin: 0; color: var(--text-muted); }

/* ---------- Immobili ---------- */
.price {
  font-family: var(--font-title);
  font-size: 24px; /* oro su bianco solo da 24px in su */
  font-weight: 600;
  line-height: 1.2;
  color: var(--gold);
}
.specs {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-8) var(--s-16);
  margin: var(--s-4) 0 var(--s-8);
  padding-top: var(--s-12);
  border-top: 1px solid var(--border);
  font-size: 14px;
  color: var(--text-muted);
}
.specs li { display: inline-flex; align-items: center; gap: var(--s-4); }
.specs svg { width: 16px; height: 16px; color: var(--navy-light); }

/* ---------- Prima / dopo ---------- */
.before-after {
  --pos: 50%;
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  user-select: none;
}
.before-after img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.before-after .ba-before { clip-path: inset(0 calc(100% - var(--pos)) 0 0); }
.before-after .ba-divider {
  position: absolute;
  top: 0; bottom: 0;
  left: var(--pos);
  width: 2px;
  background: var(--white);
  transform: translateX(-1px);
  pointer-events: none;
}
.before-after .ba-divider::after {
  content: "↔";
  position: absolute;
  top: 50%;
  left: 50%;
  display: grid;
  place-items: center;
  width: var(--s-32);
  height: var(--s-32);
  border-radius: 50%;
  background: var(--white);
  color: var(--navy);
  transform: translate(-50%, -50%);
  box-shadow: var(--shadow);
}
.before-after input {
  position: absolute;
  inset: 0;
  z-index: 3;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: ew-resize;
}
.before-after .ba-tag {
  position: absolute;
  bottom: var(--s-12);
  z-index: 2;
  padding: var(--s-4) var(--s-8);
  border-radius: var(--s-4);
  background: rgba(11, 31, 58, 0.8);
  color: var(--white);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  pointer-events: none;
}
.before-after .ba-tag--before { left: var(--s-12); }
.before-after .ba-tag--after { right: var(--s-12); }

/* ---------- Recensioni ---------- */
.review {
  display: flex;
  flex-direction: column;
  gap: var(--s-16);
  padding: var(--s-32) var(--s-24);
}
.review blockquote { margin: 0; color: var(--text); }
.review__author { margin-top: auto; font-size: 14px; color: var(--text-muted); }
.review__author strong { display: block; color: var(--navy); font-size: 16px; }

.stars { display: inline-flex; gap: var(--s-4); color: var(--gold); }
.stars svg { width: 20px; height: 20px; }
.stars .is-off { color: var(--border); }

/* Sul telefono le recensioni scorrono in orizzontale */
@media (max-width: 767px) {
  .reviews-track {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 85%;
    grid-template-columns: none;
    gap: var(--s-16);
    margin-inline: calc(-1 * var(--gutter));
    padding: var(--s-4) var(--gutter) var(--s-16);
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
  }
  .reviews-track::-webkit-scrollbar { display: none; }
  .reviews-track > * { scroll-snap-align: center; }
}

.empty {
  grid-column: 1 / -1;
  padding: var(--s-48) var(--s-24);
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  text-align: center;
  color: var(--text-muted);
}

/* ---------- Fascia finale ---------- */
.cta { text-align: center; }
.cta h2 { max-width: 720px; margin-inline: auto; }
.cta h2 .accent { color: var(--gold); }
.cta p {
  max-width: 560px;
  margin: var(--s-16) auto var(--s-32);
  color: rgba(255, 255, 255, 0.85);
}
.cta .btn-row { justify-content: center; }

/* ---------- Footer ----------
   Colonne: 1 marchio · 2 contatti · 3 link rapidi · 4 dati societari
   Telefono: una sotto l'altra, link rapidi su 2 colonne
   Tablet: marchio su tutta la riga, poi contatti + dati, poi link su 4 colonne
   Computer: 4 colonne affiancate, link rapidi su 2 colonne */
.footer {
  padding: var(--s-32) 0 var(--s-16);
  background: var(--navy);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.85);
  font-size: 15px;
}
.footer__grid {
  display: grid;
  grid-template-columns: 1fr;
  grid-template-areas: "brand" "contatti" "dati";
  gap: var(--s-16);
}
.footer__grid > :nth-child(1) { grid-area: brand; }
.footer__grid > :nth-child(2) { grid-area: contatti; }
.footer__grid > :nth-child(3) { grid-area: dati; }

.footer h2 {
  margin: 0 0 var(--s-8);
  padding-bottom: var(--s-4);
  border-bottom: 1px solid rgba(201, 162, 39, 0.35);
  font-family: var(--font-text);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--gold);
}
.footer p { margin: 0 0 var(--s-8); line-height: 1.5; }
.footer p:last-child { margin-bottom: 0; }
.footer a:hover { color: var(--gold); }
.footer strong { color: var(--white); font-weight: 600; }
.footer__logo { display: inline-block; margin-bottom: var(--s-12); }
.footer__logo img { height: 94px; width: auto; } /* +40% (ottobre 2026) */

/* Contatti: nome e ruolo, sotto i numeri; ogni persona è un blocco */
.footer__grid > :nth-child(2) p > br { display: none; }
.footer__grid > :nth-child(2) p > a { display: flex; align-items: center; min-height: 36px; width: fit-content; }
.footer__grid > :nth-child(2) p > strong { display: inline-block; margin-bottom: 0; }

/* Dati societari: righe ravvicinate come i numeri dei contatti */
.footer__grid > :nth-child(3) p { margin-bottom: var(--s-4); }

@media (min-width: 768px) {
  .footer { padding-top: 40px; }
  .footer__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-areas: "brand brand" "contatti dati";
    gap: var(--s-16) var(--s-32);
  }
  /* marchio: logo e frase affiancati */
  .footer__grid > :nth-child(1) { display: flex; align-items: center; gap: var(--s-24); }
  .footer__grid > :nth-child(1) .footer__logo { margin-bottom: 0; }
  .footer__grid > :nth-child(1) p { margin: 0; max-width: 32ch; }
}
@media (min-width: 1024px) {
  .footer { padding-top: var(--s-48); }
  .footer__grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.3fr);
    grid-template-areas: "brand contatti dati";
    gap: var(--s-24) var(--s-32);
  }
  .footer__grid > :nth-child(1) { display: block; }
  .footer__grid > :nth-child(1) .footer__logo { margin-bottom: var(--s-12); }
}
/* Con il mouse bastano righe più basse; al tocco restano almeno 40-44px */
@media (pointer: fine) {
  .footer__grid > :nth-child(2) p > a { min-height: 28px; }
}

.footer__bottom {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-top: var(--s-24);
  padding-top: var(--s-8);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 14px;
  color: rgba(255, 255, 255, 0.7);
}
.footer__bottom nav { display: flex; flex-wrap: wrap; gap: 0 var(--s-24); }
.footer__bottom nav a { display: inline-flex; align-items: center; min-height: 44px; }
@media (min-width: 768px) {
  .footer__bottom { flex-direction: row; align-items: center; justify-content: space-between; gap: var(--s-24); }
}

/* ---------- WhatsApp fisso ---------- */
.whatsapp-float {
  position: fixed;
  right: var(--s-24);
  bottom: calc(var(--s-24) + env(safe-area-inset-bottom, 0px));
  z-index: 40;
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--whatsapp);
  color: var(--white);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
  transition: transform 0.3s;
}
.whatsapp-float:hover { transform: scale(1.08); }
.whatsapp-float svg { width: 32px; height: 32px; }

/* ---------- Animazioni di comparsa allo scorrimento ---------- */
:root { --ease-out: cubic-bezier(.22,.61,.36,1); --ease-back: cubic-bezier(.34,1.56,.64,1); }
.js .reveal {
  opacity: 0;
  transform: var(--reveal-from, translateY(48px));
  transition: opacity 0.9s var(--ease-out), transform 0.9s var(--ease-out);
}
.js .reveal.is-visible { opacity: 1; transform: none; }
/* le schede di una griglia entrano una dopo l'altra, dal basso con un leggero zoom */
.js .grid > .reveal { --reveal-from: translateY(64px) scale(0.94); }
.js .grid > .reveal:nth-child(2) { transition-delay: 0.12s; }
.js .grid > .reveal:nth-child(3) { transition-delay: 0.24s; }
.js .grid > .reveal:nth-child(4) { transition-delay: 0.36s; }
.js .grid > .reveal:nth-child(5) { transition-delay: 0.48s; }
.js .grid > .reveal:nth-child(n+6) { transition-delay: 0.6s; }
/* testo e foto affiancati entrano da lati opposti */
.js .split > .reveal:not(.split__media) { --reveal-from: translateX(-64px); }
.js .split__media.reveal { --reveal-from: translateX(64px) scale(0.92); }
.js .zone__text.reveal { --reveal-from: translateX(-64px); }
.js .zone__map.reveal { --reveal-from: translateY(40px) scale(0.9); }
/* riquadri blu: il contenuto cresce */
.js .cta .reveal { --reveal-from: translateY(40px) scale(0.96); }

/* titoli di sezione: la lineetta oro si allunga e il titolo si scopre dal basso */
.js .reveal .label::before, .js .page-hero__content .label::before { width: 0; transition: width 0.8s var(--ease-out) 0.3s; }
.js .reveal.is-visible .label::before, .js .page-hero__content .label::before { width: var(--s-24); }
.js .page-hero__content .label::before { animation: label-line 0.8s var(--ease-out) 0.4s both; }
@keyframes label-line { from { width: 0; } to { width: var(--s-24); } }
.js .section-head.reveal h2, .js .split .reveal h2, .js .cta .reveal h2 {
  clip-path: inset(-20% -5% 100% -5%);
  transform: translateY(40px);
  transition: clip-path 1s var(--ease-out) 0.15s, transform 1s var(--ease-out) 0.15s;
}
.js .section-head.reveal.is-visible h2, .js .split .reveal.is-visible h2, .js .cta .reveal.is-visible h2 {
  clip-path: inset(-20% -5% -20% -5%);
  transform: none;
}
.js .section-head.reveal p, .js .cta .reveal p, .js .cta .reveal .btn-row {
  opacity: 0; transform: translateY(20px);
  transition: opacity 0.8s var(--ease-out) 0.45s, transform 0.8s var(--ease-out) 0.45s;
}
.js .cta .reveal .btn-row { transition-delay: 0.6s; }
.js .section-head.reveal.is-visible p, .js .cta .reveal.is-visible p, .js .cta .reveal.is-visible .btn-row { opacity: 1; transform: none; }
/* intestazioni delle pagine interne */
.page-hero__content > * { animation: hero-in 1s var(--ease-out) both; }
.page-hero__content > :nth-child(2) { animation-delay: 0.15s; }
.page-hero__content > :nth-child(3) { animation-delay: 0.3s; }

/* icone: entrano con un piccolo rimbalzo */
.js .reveal .icon-circle, .js .reveal .stay-step__n, .js .reveal .val-steps li::before {
  scale: 0.3; rotate: -25deg; opacity: 0;
  transition: scale 0.7s var(--ease-back) 0.35s, rotate 0.7s var(--ease-back) 0.35s, opacity 0.4s ease 0.35s;
}
.js .reveal.is-visible .icon-circle, .js .reveal.is-visible .stay-step__n, .js .reveal.is-visible .val-steps li::before { scale: 1; rotate: 0deg; opacity: 1; }

/* foto delle schede: arrivano con uno zoom che si assesta */
.js .card.reveal .card__media img { scale: 1.25; transition: scale 1.6s var(--ease-out) 0.1s; }
.js .card.reveal.is-visible .card__media img { scale: 1; }
.js .card.reveal.is-visible:hover .card__media img { scale: 1.06; transition-duration: 0.6s; transition-delay: 0s; }

/* foto affiancate ai testi: scorrono dentro la cornice (parallasse) */
.js .split__media { overflow: hidden; border-radius: var(--radius); box-shadow: var(--shadow); }
.js .split__media img { box-shadow: none; scale: 1.18; translate: 0 var(--py, 0); will-change: translate; }

/* mappa: le province si accendono una dopo l'altra */
.zone__map:not(.is-shown) .zone__prov.is-active { fill: #E3E7ED; }
.zone__prov { transition: fill 0.6s ease; }

/* barra di avanzamento della pagina */
.scroll-progress {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1001;
  height: 3px; background: var(--gold);
  transform: scaleX(0); transform-origin: 0 50%;
  pointer-events: none;
}

/* riquadri blu: grande scritta in trasparenza che scorre di lato */
.cta { position: relative; overflow: hidden; }
.cta > .container { position: relative; z-index: 1; }
.cta::before {
  content: "LA MAISON GROUP";
  position: absolute; top: 50%; left: 0;
  font-family: var(--font-title, serif); font-style: italic; font-weight: 600;
  font-size: clamp(96px, 18vw, 260px); line-height: 1; white-space: nowrap;
  color: rgba(201, 162, 39, 0.1);
  transform: translate(calc(8% - var(--p, 0.5) * 32%), -50%);
  pointer-events: none;
}

/* logo un po' più piccolo quando si scorre */
.header__logo img { transition: scale 0.35s var(--ease-out); transform-origin: 0 50%; }
.header.is-scrolled .header__logo img { scale: 0.86; }

/* Foto iniziale della Home: dissolvenza con zoom lento */
.hero__img[data-hero-slide] {
  transform: scale(1);
  transition: opacity 1.6s ease, transform 9s linear;
  will-change: opacity, transform;
}
.js .hero__img[data-hero-slide]:not(.is-active) { opacity: 0; }
.hero__img[data-hero-slide].is-active { opacity: 1; transform: scale(1.08); }
.hero__content > * { animation: hero-in 1s cubic-bezier(.22,.61,.36,1) both; }
.hero__content > :nth-child(2) { animation-delay: 0.25s; }
@keyframes hero-in { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }
.hero__dots {
  position: absolute; left: 50%; bottom: var(--s-24); z-index: 2;
  display: flex; gap: 4px; transform: translateX(-50%);
}
.hero__dots button, .reviews-dots button {
  width: 32px; height: 32px; padding: 0; border: 0; background: none; cursor: pointer;
  display: grid; place-items: center;
}
.hero__dots button::before, .reviews-dots button::before {
  content: ""; display: block; width: 8px; height: 8px; border-radius: 999px;
  background: rgba(255, 255, 255, 0.55); transition: width 0.3s, background 0.3s;
}
.hero__dots button[aria-current="true"]::before { width: 24px; background: var(--gold); }
.reviews-dots { display: flex; justify-content: center; gap: 2px; margin-top: var(--s-8); }
.reviews-dots[hidden] { display: none; }
.reviews-dots button::before { background: var(--border); }
.reviews-dots button[aria-current="true"]::before { width: 24px; background: var(--gold); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .js .reveal h2, .js .reveal p, .js .reveal .btn-row, .js .reveal .label::before, .js .reveal .icon-circle, .js .reveal .stay-step__n, .js .reveal .val-steps li::before, .js .card.reveal .card__media img { transition: none !important; clip-path: none !important; opacity: 1 !important; transform: none !important; scale: none !important; rotate: none !important; }
  .js .reveal .label::before { width: var(--s-24); }
  .page-hero__content > *, .js .page-hero__content .label::before { animation: none; }
  .js .split__media img { scale: none; translate: none; }
  .cta::before { transform: translate(0, -50%); }
  .zone__map:not(.is-shown) .zone__prov.is-active { fill: var(--gold); }
  .hero__img[data-hero-slide], .hero__content > * { transition: none; animation: none; transform: none; }
  .card, .card:hover { transition: none; transform: none; }
}

/* =========================================================
   Pagine interne
   ========================================================= */

/* ---------- Intestazione pagina (foto + velatura navy 60%) ---------- */
.page-hero {
  position: relative;
  display: flex;
  align-items: flex-end;
  min-height: 400px;
  padding: calc(var(--header-h) + var(--s-64)) 0 var(--s-48);
  overflow: hidden;
  background: var(--navy);
  color: var(--white);
}
.page-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: rgba(11, 31, 58, 0.6);
}
.page-hero .hero__img { aspect-ratio: auto; }
.page-hero__content { position: relative; z-index: 2; max-width: 800px; }
.page-hero h1 { color: var(--white); }
.page-hero h1 .accent { color: var(--gold); }
.page-hero p {
  max-width: 640px;
  margin: var(--s-16) 0 0;
  color: rgba(255, 255, 255, 0.9);
}
@media (min-width: 1024px) {
  .page-hero { min-height: 520px; padding-bottom: var(--s-64); }
}

/* ---------- Testo + immagine ---------- */
.split {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-32);
  align-items: center;
}
.split__media img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.split .section-head { margin-bottom: var(--s-24); }
.split p { color: var(--text); }
.split .btn { margin-top: var(--s-8); }
@media (min-width: 1024px) {
  .split { grid-template-columns: 1fr 1fr; gap: var(--s-64); }
  .split--reverse .split__media { order: -1; }
}

/* ---------- Formule di gestione ---------- */
.plans {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--grid-gap);
}
@media (min-width: 768px) {
  .plans { grid-template-columns: repeat(2, 1fr); }
}
.plan {
  display: flex;
  flex-direction: column;
  gap: var(--s-16);
  padding: var(--s-32) var(--s-24);
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
@media (min-width: 1024px) {
  .plan { padding: var(--s-48); }
}
.plan p { margin: 0; color: var(--text-muted); }
.plan .btn { margin-top: auto; align-self: flex-start; }
.plan--featured { background: var(--navy); border-color: var(--navy); color: var(--white); }
.plan--featured h3 { color: var(--white); }
.plan--featured p { color: rgba(255, 255, 255, 0.85); }
.plan__tag { font-size: 14px; font-weight: 600; color: var(--navy-light); }
.plan--featured .plan__tag { color: var(--gold); }

.checklist {
  display: grid;
  gap: var(--s-12);
  margin: var(--s-8) 0 var(--s-16);
}
.checklist li { display: flex; align-items: flex-start; gap: var(--s-12); }
.checklist svg { width: 20px; height: 20px; margin-top: var(--s-4); flex: none; color: var(--gold); }

.note {
  margin: var(--s-32) auto 0;
  max-width: 640px;
  text-align: center;
  color: var(--text-muted);
}

/* ---------- Come funziona ---------- */
.steps {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-32);
  counter-reset: step;
}
@media (min-width: 768px) {
  .steps { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
  .steps { grid-template-columns: repeat(4, 1fr); }
}
.step {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: var(--s-8);
  counter-increment: step;
}
.step::before {
  content: counter(step);
  display: grid;
  place-items: center;
  width: var(--s-48);
  height: var(--s-48);
  margin-bottom: var(--s-8);
  border-radius: 50%;
  background: var(--navy);
  color: var(--gold); /* numero oro su fondo navy */
  font-family: var(--font-title);
  font-size: 20px;
  font-weight: 600;
}
.step p { margin: 0; color: var(--text-muted); }
@media (min-width: 1024px) {
  /* linea che collega i passi */
  .step:not(:last-child)::after {
    content: "";
    position: absolute;
    top: var(--s-24);
    left: calc(var(--s-48) + var(--s-16));
    right: calc(-1 * var(--s-16));
    height: 1px;
    background: var(--border);
  }
}

/* Schede "Cosa è incluso" */
.feature-card { gap: var(--s-8); padding: var(--s-32) var(--s-24); }
.feature-card p { margin: 0; color: var(--text-muted); }
ol.steps { margin: 0; padding: 0; list-style: none; }

/* ---------- Intestazione senza foto ---------- */
.page-hero--plain { min-height: 0; padding-top: calc(var(--header-h) + var(--s-48)); }
.page-hero--plain::before { display: none; }
@media (min-width: 1024px) {
  .page-hero--plain { min-height: 0; padding-top: calc(var(--header-h) + var(--s-96)); }
}

/* ---------- Moduli ---------- */
.form-card {
  padding: var(--s-32) var(--s-24);
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
@media (min-width: 1024px) {
  .form-card { padding: var(--s-48); }
}
.form-card h2 { margin-bottom: var(--s-8); }
.form-card > p { color: var(--text-muted); }

.form {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-16) var(--s-24);
  margin-top: var(--s-24);
}
@media (min-width: 768px) {
  .form { grid-template-columns: repeat(2, 1fr); }
  .form .full { grid-column: 1 / -1; }
}
.field { display: flex; flex-direction: column; gap: var(--s-8); margin: 0; padding: 0; border: 0; min-width: 0; }
.field label,
.field legend {
  padding: 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--navy);
}
.field .optional { font-weight: 400; color: var(--text-muted); }
.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 48px;
  padding: var(--s-12) var(--s-16);
  border: 1px solid var(--border);
  border-radius: var(--radius-btn);
  background: var(--white);
  font: inherit;
  font-size: 16px; /* evita lo zoom automatico su iPhone */
  color: var(--text);
}
.field textarea { min-height: 128px; resize: vertical; }
.field input:focus,
.field select:focus,
.field textarea:focus { outline: 2px solid var(--navy-light); outline-offset: -1px; border-color: var(--navy-light); }
.field .hint { font-size: 14px; color: var(--text-muted); }

.consent {
  display: flex;
  align-items: flex-start;
  gap: var(--s-12);
  font-size: 15px;
  color: var(--text-muted);
  cursor: pointer;
}
.consent input { width: 20px; height: 20px; margin: var(--s-4) 0 0; flex: none; accent-color: var(--navy); }
.consent a { color: var(--navy); text-decoration: underline; }

/* Modulo valutazione: titoletti e caselle di spunta */
.form__title {
  margin: var(--s-16) 0 0;
  padding-bottom: var(--s-8);
  border-bottom: 1px solid var(--border);
  font-size: 20px;
}
.form__title:first-of-type { margin-top: 0; }
.checks { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s-12) var(--s-16); }
@media (min-width: 768px) {
  .checks { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
.checks label { display: flex; align-items: center; gap: var(--s-8); font-size: 15px; font-weight: 500; color: var(--text); cursor: pointer; }
.checks input { width: 20px; height: 20px; min-height: 0; margin: 0; padding: 0; flex: none; accent-color: var(--navy); }

/* Passaggi "Come funziona" */
.val-steps { counter-reset: passo; margin: var(--s-24) 0 var(--s-32); padding: 0; list-style: none; display: grid; gap: var(--s-24); }
.val-steps li { counter-increment: passo; position: relative; padding-left: 56px; color: var(--text-muted); }
.val-steps li strong { color: var(--navy); font-size: 17px; }
.val-steps li::before {
  content: counter(passo);
  position: absolute; left: 0; top: 0;
  width: 40px; height: 40px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--navy); color: var(--gold);
  font-weight: 700;
}

.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.form .btn { justify-self: start; }
.form .btn[disabled] { opacity: 0.6; cursor: wait; }

.form-alert {
  margin: 0;
  padding: var(--s-12) var(--s-16);
  border-radius: var(--radius-btn);
  font-size: 15px;
}
.form-alert:empty { display: none; }
.form-alert--error { background: #FDECEA; color: var(--error); }

.form-success {
  padding: var(--s-32) var(--s-24);
  border-radius: var(--radius);
  background: var(--grey-bg);
  text-align: center;
}
.form-success:focus { outline: none; }
.form-success svg { width: var(--s-48); height: var(--s-48); margin: 0 auto var(--s-16); color: var(--success); }
.form-success h3 { margin-bottom: var(--s-8); }
.form-success p { color: var(--text-muted); }

/* Stelle da cliccare (1–5) */
.star-input { display: flex; flex-direction: row-reverse; justify-content: flex-end; gap: var(--s-4); }
.star-input input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.star-input label { cursor: pointer; color: var(--border); transition: color 0.2s; }
.star-input label svg { width: var(--s-32); height: var(--s-32); }
.star-input label:hover,
.star-input label:hover ~ label,
.star-input input:checked ~ label { color: var(--gold); }
.star-input input:focus-visible + label { outline: 2px solid var(--navy-light); border-radius: var(--s-4); }

/* ---------- Contatti ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr; gap: var(--s-48); align-items: start; }
@media (min-width: 1024px) {
  .contact-grid { grid-template-columns: 5fr 7fr; gap: var(--s-64); }
}
.contact-person { padding-bottom: var(--s-24); margin-bottom: var(--s-24); border-bottom: 1px solid var(--border); }
.contact-person h3 { margin-bottom: var(--s-4); }
.contact-person .role { margin: 0 0 var(--s-12); font-size: 14px; font-weight: 600; color: var(--navy-light); text-transform: uppercase; letter-spacing: 2px; }
.contact-person .phones { margin: 0 0 var(--s-16); }
.contact-person .phones a { display: block; font-size: 18px; color: var(--navy); }
.btn--whatsapp { background: var(--whatsapp); color: var(--white); }
.btn--whatsapp:hover { background: #1DA851; }
.contact-line { display: flex; align-items: center; gap: var(--s-12); margin: 0 0 var(--s-12); color: var(--navy); }
.contact-line svg { width: 20px; height: 20px; color: var(--navy-light); flex: none; }

/* ---------- Media recensioni ---------- */
.rating-summary { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-16) var(--s-24); margin-bottom: var(--s-48); }
.rating-summary .score { font-family: var(--font-title); font-size: var(--s-64); font-weight: 600; line-height: 1; color: var(--navy); }
.rating-summary .stars svg { width: var(--s-32); height: var(--s-32); }
.rating-summary p { margin: var(--s-4) 0 0; color: var(--text-muted); }

/* =========================================================
   Aree da toccare: almeno 44×44px (controllo a 375/768/1440px)
   ========================================================= */

/* Menu in alto (usato anche su tablet orizzontale) */
@media (min-width: 1024px) {
  .nav a { display: inline-flex; align-items: center; min-height: 48px; }
}

/* Footer: altezze dei link definite nella sezione Footer */

/* Numeri di telefono nella pagina Contatti */
.contact-person .phones a { display: flex; align-items: center; min-height: 44px; }
.contact-line a { display: inline-flex; align-items: center; min-height: 44px; }

/* Stelle del modulo recensioni: 48×48px ciascuna */
.star-input { gap: 0; }
.star-input label { display: grid; place-items: center; width: var(--s-48); height: var(--s-48); }
.star-input { margin-left: calc(-1 * var(--s-8)); }
.nav a { min-width: 44px; }
/* Tutta la riga del consenso è cliccabile: almeno 44px di altezza */
.consent { min-height: 44px; padding-block: var(--s-8); }

/* Testi e foto modificabili: nascosti per un istante finché js/content.js non li aggiorna */
.content-loading [data-edit],
.content-loading [data-edit-img] { visibility: hidden; }

/* ---------- Chi siamo: il team ---------- */
.team { max-width: 880px; margin-inline: auto; }
.team .role { margin: 0; font-size: 14px; font-weight: 600; color: var(--navy-light); text-transform: uppercase; letter-spacing: 2px; }

/* ---------- Pagine legali (Privacy, Cookie) ---------- */
.legal { max-width: 760px; }
.legal h2 { margin: var(--s-32) 0 var(--s-8); font-size: var(--fs-h3); }
.legal p { margin: 0 0 var(--s-16); color: var(--text); overflow-wrap: anywhere; }
.legal a { color: var(--navy); text-decoration: underline; }

/* ---------- Schede immobili: prezzo e pulsante ---------- */
.price small { font-family: var(--font-text); font-size: 15px; font-weight: 400; color: var(--text-muted); }
.card:hover .card__cta { background: var(--navy); color: var(--white); }
.card__stretched { color: inherit; }

/* ---------- Scheda del singolo immobile (immobile.html) ---------- */
.page-hero--compact { min-height: 0; padding-bottom: var(--s-32); }
.scheda__back { margin-bottom: var(--s-16); font-size: 14px; }
.scheda__back a { display: inline-flex; align-items: center; min-height: 44px; color: rgba(255, 255, 255, 0.8); }
.scheda__back a:hover { color: var(--gold); }
.scheda__where { margin: var(--s-8) 0 0; color: rgba(255, 255, 255, 0.85); }
.scheda__hidden { display: inline-block; margin: var(--s-12) 0 0; padding: 2px var(--s-12); border-radius: 999px; background: var(--gold); color: var(--navy); font-size: 13px; font-weight: 600; }
.section--tight { padding-top: var(--s-32); }

.scheda__grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--s-32); }
.scheda__main { display: flex; flex-direction: column; gap: var(--s-24); min-width: 0; }
.scheda__block h2 { margin: 0 0 var(--s-12); font-size: var(--fs-h3); }
.scheda__block p { margin: 0 0 var(--s-12); }
.scheda__box { gap: var(--s-16); padding: var(--s-24); }
.scheda__box .price { margin: 0; }
.scheda__box .btn { align-self: stretch; margin-top: 0; }
@media (min-width: 1024px) {
  .scheda__grid { grid-template-columns: minmax(0, 1fr) 360px; gap: var(--s-48); align-items: start; }
  .scheda__side { position: sticky; top: calc(var(--header-h) + var(--s-24)); }
}

.facts { display: grid; margin: 0; }
.facts div { display: flex; justify-content: space-between; gap: var(--s-16); padding: var(--s-8) 0; border-bottom: 1px solid var(--border); }
.facts dt { color: var(--text-muted); }
.facts dd { margin: 0; font-weight: 600; color: var(--navy); text-align: right; }

.specs--large { gap: var(--s-12) var(--s-24); font-size: 16px; }
.specs--large svg { width: 20px; height: 20px; }

.tags { display: flex; flex-wrap: wrap; gap: var(--s-8); margin: 0; padding: 0; list-style: none; }
.tags li { padding: var(--s-4) var(--s-12); border: 1px solid var(--border); border-radius: 999px; background: var(--grey-bg); font-size: 14px; color: var(--navy); }

/* Galleria foto */
.gallery__main { position: relative; overflow: hidden; border-radius: var(--radius); background: var(--grey-bg); aspect-ratio: 3 / 2; }
.gallery__main img { width: 100%; height: 100%; object-fit: cover; }
.gallery__nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  display: grid; place-items: center; width: 44px; height: 44px; padding: 0;
  border: 0; border-radius: 50%; background: rgba(255, 255, 255, 0.9); color: var(--navy);
  font-size: 28px; line-height: 1; cursor: pointer; box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}
.gallery__nav--prev { left: var(--s-12); }
.gallery__nav--next { right: var(--s-12); }
.gallery__count { position: absolute; right: var(--s-12); bottom: var(--s-12); padding: 2px var(--s-8); border-radius: 999px; background: rgba(11, 31, 58, 0.75); color: var(--white); font-size: 13px; }
.gallery__thumbs { display: flex; gap: var(--s-8); margin: var(--s-8) 0 0; padding: 0 0 var(--s-4); list-style: none; overflow-x: auto; scroll-snap-type: x mandatory; }
.gallery__thumbs li { flex: none; scroll-snap-align: start; }
.gallery__thumbs button { display: block; width: 88px; aspect-ratio: 3 / 2; padding: 0; border: 2px solid transparent; border-radius: var(--radius-btn); overflow: hidden; background: none; cursor: pointer; opacity: 0.7; }
.gallery__thumbs button[aria-current="true"] { border-color: var(--gold); opacity: 1; }
.gallery__thumbs img { width: 100%; height: 100%; object-fit: cover; }
@media (min-width: 768px) { .gallery__thumbs button { width: 112px; } }

/* ---------- Home: mappa "Dove operiamo" ---------- */
.zone { display: grid; gap: var(--s-32); align-items: center; }
.zone__map { margin: 0; justify-self: center; width: 100%; max-width: 420px; }
.zone__canvas { aspect-ratio: 1000 / 1312; }
.zone__svg { display: block; width: 100%; height: auto; overflow: visible; }
.zone__prov { fill: #E3E7ED; stroke: var(--white); stroke-width: 1.2; stroke-linejoin: round; transition: fill 0.2s; }
.zone__prov:hover { fill: #CDD4DE; }
.zone__prov.is-active { fill: var(--gold); }
.zone__prov.is-active:hover { fill: #b8931f; }
.zone__map { position: relative; }
.zone__prov.is-hover { fill: #CDD4DE; }
.zone__prov.is-active.is-hover { fill: #b8931f; }
.zone__tip {
  position: absolute;
  z-index: 2;
  transform: translate(-50%, calc(-100% - 14px));
  padding: 6px 12px;
  border-radius: 6px;
  background: var(--navy);
  color: var(--gold);
  font: 600 14px/1.3 var(--font-text);
  text-align: center;
  white-space: nowrap;
  pointer-events: none;
  box-shadow: 0 6px 18px rgba(11, 31, 58, 0.25);
}
.zone__tip span { display: block; font-size: 12px; font-weight: 500; color: var(--white); }
.zone__tip::after {
  content: "";
  position: absolute;
  left: 50%; top: 100%;
  margin-left: -6px;
  border: 6px solid transparent;
  border-top-color: var(--navy);
}
.zone__map figcaption { margin-top: var(--s-8); font-size: 12px; color: var(--text-muted); text-align: center; }
.zone__map.is-editing .zone__prov { cursor: pointer; }
@media (min-width: 768px) {
  .zone { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--s-48); }
  .zone__map { max-width: 460px; }
}

/* ---------- Affitti brevi: richiesta preventivo con calendario ---------- */
.booking-wrap { max-width: 880px; margin-inline: auto; }
.booking fieldset { margin: 0; padding: 0; border: 0; min-width: 0; }
.booking legend { margin-bottom: var(--s-8); padding: 0; font-weight: 600; color: var(--navy); }
.scheda__quote { margin: 0; color: var(--text-muted); }

.cal { position: relative; border: 1px solid var(--border); border-radius: var(--radius); padding: var(--s-12); background: var(--white); }
.cal__nav { position: absolute; top: var(--s-8); left: var(--s-8); right: var(--s-8); display: flex; justify-content: space-between; pointer-events: none; }
.cal__arrow {
  display: grid; place-items: center; width: 40px; height: 40px; padding: 0;
  border: 1px solid var(--border); border-radius: 50%; background: var(--white); color: var(--navy);
  font-size: 24px; line-height: 1; cursor: pointer; pointer-events: auto;
}
.cal__arrow:disabled { opacity: 0.3; cursor: default; }
.cal__months { display: grid; gap: var(--s-24); }
@media (min-width: 768px) { .cal__months { grid-template-columns: 1fr 1fr; } }
.cal__title { margin: 0 0 var(--s-12); line-height: 40px; text-align: center; font-weight: 600; color: var(--navy); text-transform: capitalize; }
.cal__grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 2px 0; }
.cal__dow { padding-bottom: var(--s-4); font-size: 12px; text-align: center; text-transform: uppercase; color: var(--text-muted); }
.cal__day {
  height: 42px; padding: 0; border: 0; border-radius: var(--radius-btn);
  background: none; color: var(--text); font: 500 15px var(--font-text); cursor: pointer;
}
.cal__day:hover:not(:disabled) { background: var(--grey-bg); }
.cal__day:disabled { color: #B8C0CC; text-decoration: line-through; cursor: default; }
.cal__day.is-today { box-shadow: inset 0 0 0 1px var(--navy-light); }
.cal__day.is-range { border-radius: 0; background: rgba(201, 162, 39, 0.18); }
.cal__day.is-start, .cal__day.is-end { background: var(--gold); color: var(--navy); font-weight: 700; }
.cal__day:focus-visible, .cal__arrow:focus-visible { outline: 2px solid var(--navy); outline-offset: 1px; }

.booking__summary { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-8) var(--s-16); margin-top: var(--s-12); min-height: 44px; }
.booking__summary strong { margin-right: var(--s-4); color: var(--navy); }
.booking__nights { padding: 2px var(--s-12); border-radius: 999px; background: var(--navy); color: var(--white); font-size: 14px; font-weight: 600; }
.booking__hint { color: var(--text-muted); }
.booking__reset { min-height: 44px; padding: 0; border: 0; background: none; color: var(--navy); font: inherit; text-decoration: underline; cursor: pointer; }

/* Elementi facoltativi (es. numero svizzero) e social nascosti restano davvero nascosti */
[data-optional][hidden], [data-social][hidden], [data-social-item][hidden] { display: none !important; }

/* Social nel footer */
.footer__social { display: flex; gap: var(--s-8); margin: var(--s-12) 0 0; padding: 0; list-style: none; }
.footer__social a {
  display: grid; place-items: center; width: 44px; height: 44px;
  border: 1px solid rgba(255, 255, 255, 0.25); border-radius: 50%; color: var(--white);
}
.footer__social a:hover { border-color: var(--gold); color: var(--gold); }
.footer__social svg { width: 20px; height: 20px; }
.legal h3 { margin: var(--s-24) 0 var(--s-8); font-family: var(--font-text); font-size: 17px; font-weight: 600; color: var(--navy); }
.legal ul { margin: 0 0 var(--s-16); padding-left: var(--s-24); }
.legal li { margin-bottom: var(--s-8); overflow-wrap: anywhere; }
.legal__date { color: var(--text-muted); font-size: 14px; }

/* ---------- Menù in alto: "Servizi" a tendina ---------- */
.nav__group { position: relative; display: flex; align-items: center; }
.nav__toggle {
  position: relative; display: inline-flex; align-items: center; gap: 6px;
  min-height: 48px; padding: 0; border: 0; background: none;
  color: var(--white); font: 15px var(--font-text); white-space: nowrap; cursor: pointer;
  transition: color 0.3s;
}
.nav__toggle:hover, .nav__group.is-open .nav__toggle, .nav__toggle.is-current { color: var(--gold); }
.nav__toggle.is-current::after { content: ""; position: absolute; left: 0; right: 22px; bottom: 8px; height: 2px; background: var(--gold); }
.nav__chevron { width: 16px; height: 16px; transition: transform 0.2s; }
.nav__group.is-open .nav__chevron { transform: rotate(180deg); }
.nav__dropdown {
  position: absolute; top: 100%; left: 50%; z-index: 60;
  display: flex; flex-direction: column; min-width: 250px; padding: var(--s-8);
  border-radius: var(--radius); background: var(--white); box-shadow: 0 16px 40px rgba(11, 31, 58, 0.22);
  opacity: 0; visibility: hidden; transform: translate(-50%, 6px);
  transition: opacity 0.2s, transform 0.2s, visibility 0.2s;
}
.nav__group.is-open .nav__dropdown { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
@media (hover: hover) and (pointer: fine) {
  .nav__group:hover .nav__dropdown { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
  .nav__group:hover .nav__chevron { transform: rotate(180deg); }
}
.nav .nav__dropdown a {
  display: flex; align-items: center; min-height: 44px; padding: 0 var(--s-12);
  border-radius: var(--radius-btn); color: var(--navy); font-size: 15px;
}
.nav .nav__dropdown a:hover { background: var(--grey-bg); color: var(--navy); }
.nav .nav__dropdown a[aria-current="page"] { color: var(--navy); font-weight: 600; box-shadow: inset 3px 0 0 var(--gold); }
.nav .nav__dropdown a[aria-current="page"]::after { display: none; }

/* Menù su telefono: i servizi raggruppati sotto un titolo */
.mobile-menu__heading {
  display: block; padding: var(--s-16) 0 var(--s-4);
  font-size: 13px; font-weight: 600; letter-spacing: 2px; text-transform: uppercase; color: var(--navy-light);
}
.mobile-menu__group ul { padding-left: var(--s-16); border-left: 2px solid var(--gold); }
.mobile-menu__group li a { font-size: 20px; }

/* ---------- Menù completamente a tendina, a tutte le larghezze ----------
   Telefono: pannello a tutto schermo. Da 768px: pulsante "Menù" e tendina a destra
   sotto la barra; il pulsante "Affida il tuo immobile" resta sempre visibile. */
@media (min-width: 1024px) {
  .nav { display: none; }
  .burger { display: inline-flex; }
  .mobile-menu { display: flex; }
}
.burger { display: inline-flex; align-items: center; justify-content: center; gap: var(--s-8); width: auto; min-width: 48px; }
.burger__label { display: none; font: 600 15px var(--font-text); }

@media (min-width: 768px) {
  body.menu-open { overflow: auto; }
  .header__cta { display: inline-flex; margin-left: auto; }
  .header__cta + .burger { margin-left: var(--s-12); }
  .burger {
    height: 44px; padding: 0 var(--s-16);
    border: 1px solid rgba(255, 255, 255, 0.45); border-radius: var(--radius-btn);
  }
  .burger:hover { border-color: var(--gold); color: var(--gold); }
  .menu-open .burger { border-color: var(--border); }
  .burger svg { width: 22px; height: 22px; }
  .burger__label { display: inline; }

  .mobile-menu {
    inset: auto;
    top: calc(var(--header-h) + var(--s-8));
    right: max(var(--gutter), calc((100vw - 1200px) / 2));
    width: 360px;
    max-height: calc(100vh - var(--header-h) - var(--s-32));
    gap: 0;
    padding: var(--s-16) var(--s-24);
    border-radius: var(--radius);
    box-shadow: 0 20px 50px rgba(11, 31, 58, 0.25);
  }
  .mobile-menu li a { padding: var(--s-8) 0; font-size: 20px; }
  .mobile-menu__group li a { font-size: 17px; }
  .mobile-menu__heading { padding-top: var(--s-12); }
  .mobile-menu > .btn { display: none; } /* è già nella barra */
}

/* Home: senza pulsanti sotto il sottotitolo, il testo resta centrato nella foto */
.hero__subtitle:last-child { margin-bottom: 0; }

/* ---------- Telefono: "Affida il tuo immobile" e "Menù" sempre in alto ----------
   Il pulsante oro va su due righe per stare accanto al logo. */
@media (max-width: 767px) {
  .header__inner { gap: var(--s-8); }
  .header__cta {
    display: inline-flex; margin-left: auto;
    max-width: 118px; min-height: 44px; padding: 4px 10px;
    font-size: 13px; line-height: 1.15; white-space: normal;
  }
  .header__cta + .burger { margin-left: 0; }
  .burger {
    height: 44px; padding: 0 10px; gap: 6px;
    border: 1px solid rgba(255, 255, 255, 0.45); border-radius: var(--radius-btn);
  }
  .menu-open .burger { border-color: var(--border); }
  .burger svg { width: 22px; height: 22px; }
  .burger__label { display: inline; font-size: 14px; }
}
/* Schermi molto stretti (es. 320px): solo l'icona del menù */
@media (max-width: 359px) {
  .burger__label { display: none; }
  .burger { padding: 0; min-width: 44px; }
}
/* Il pulsante è già nella barra in alto: nel pannello del menù non serve ripeterlo */
.mobile-menu > .btn { display: none; }

/* Affitti brevi: prima si sceglie l'alloggio, poi le date */
.stay-step { margin-top: var(--s-48); scroll-margin-top: calc(var(--header-h) + var(--s-16)); }
.stay-step__title { display: flex; align-items: center; gap: var(--s-12); margin: 0 0 var(--s-24); }
.stay-step__n {
  display: grid; place-items: center; flex: none;
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--navy); color: var(--gold);
  font: 700 16px var(--font-text);
}
.stay-step[hidden] + .stay-step .stay-step__n { display: none; } /* senza alloggi pubblicati: niente numeri */
.card__actions { display: flex; flex-direction: column; align-items: stretch; gap: var(--s-4); margin-top: auto; padding-top: var(--s-16); }
.card__actions .btn { width: 100%; }
.card__actions .card__link { align-self: center; display: inline-flex; align-items: center; gap: 6px; min-height: 44px; }
.card.is-chosen { outline: 3px solid var(--gold); outline-offset: -3px; }
.card.is-chosen [data-choose] { background: var(--gold); border-color: var(--gold); color: var(--navy); }
.booking__pick {
  display: flex; flex-direction: column; align-items: flex-start; gap: var(--s-16);
  padding: var(--s-32) var(--s-24);
  border: 2px dashed var(--border); border-radius: var(--radius);
  background: var(--white);
}
.booking__pick[hidden] { display: none; }
.booking__pick p { margin: 0; color: var(--text-muted); }
.booking__pick .btn { white-space: nowrap; flex: none; }
.booking__pick strong { color: var(--navy); }
@media (min-width: 768px) {
  .booking__pick { flex-direction: row; align-items: center; justify-content: space-between; padding: var(--s-32); }
}
.booking__chosen {
  display: flex; align-items: center; gap: var(--s-16);
  padding: var(--s-12); border: 1px solid var(--border); border-radius: var(--radius-btn);
  background: var(--grey-bg);
}
.booking__chosen img { width: 72px; height: 54px; object-fit: cover; border-radius: 4px; flex: none; }
.booking__chosen div { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.booking__chosen strong { color: var(--navy); }
.booking__chosen span { font-size: 14px; color: var(--text-muted); }
.booking__chosen .booking__chosen-label { font-size: 12px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--gold); }
.booking__chosen .booking__reset { display: inline-flex; align-items: center; flex: none; }

/* ---------- Cambio lingua (IT / EN) ---------- */
.lang-switch {
  display: inline-flex; flex: none;
  border: 1px solid rgba(255, 255, 255, 0.45); border-radius: var(--radius-btn);
  overflow: hidden;
}
.lang-switch button {
  min-width: 40px; min-height: 42px; padding: 0 10px;
  border: 0; background: transparent; color: var(--white);
  font: 600 14px var(--font-text); letter-spacing: 0.5px; cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.lang-switch button:hover { color: var(--gold); }
.lang-switch button[aria-pressed="true"] { background: var(--gold); color: var(--navy); cursor: default; }
.menu-open .header .lang-switch { border-color: var(--border); }
.menu-open .header .lang-switch button { color: var(--navy); }
.menu-open .header .lang-switch button[aria-pressed="true"] { color: var(--navy); }
@media (min-width: 768px) {
  .lang-switch { margin-left: var(--s-12); }
  .lang-switch + .burger { margin-left: var(--s-12); }
}
/* Telefono: un solo pulsante con l'altra lingua, il menù con la sola icona */
@media (max-width: 767px) {
  .header__inner { gap: 6px; }
  .lang-switch button { min-width: 36px; padding: 0 6px; min-height: 44px; }
  .lang-switch button[aria-pressed="true"] { display: none; }
  .burger__label { display: none; }
  .burger { padding: 0; min-width: 44px; }
}
@media (max-width: 371px) {
  .header .lang-switch { display: none; } /* resta nel menù */
}
/* Nel menù aperto */
.mobile-menu__lang { display: flex; gap: var(--s-8); margin-bottom: var(--s-8); }
.mobile-menu__lang button {
  flex: 1; min-height: 44px; padding: 0 var(--s-12);
  border: 1px solid var(--border); border-radius: var(--radius-btn); background: var(--white);
  color: var(--navy); font: 600 15px var(--font-text); cursor: pointer;
}
.mobile-menu__lang button[aria-pressed="true"] { background: var(--navy); border-color: var(--navy); color: var(--white); }

/* Testo svuotato dall'area riservata: non occupa spazio (in modifica resta visibile per riscriverlo) */
html:not(.lm-editing) [data-edit][data-empty] { display: none; }
