/* =========================================================
   Dimore in Centro — design system v2
   Cormorant Garamond (titoli) + Manrope (testo e interfaccia)
   Neutri caldi, oro per Il Carapace, bordeaux per Le Volte.
   Navbar flottante a pillola ispirata a "Navbar 1" di 21st.dev.
   ========================================================= */
:root {
  --bg: #faf7f2; --surface: #fff; --sand: #f1ebe1; --sand-2: #e9e1d4;
  --ink: #1d1915; --ink-2: #2b251f; --muted: #6b6158; --line: #e6ddd0;
  --gold: #a8792a; --gold-deep: #7a561a; --gold-soft: #f5ead6; --gold-light: #e9c987;
  --wine: #7b1e31; --wine-deep: #5a1423; --wine-soft: #f4e3e6; --wine-light: #e8a9b6;
  --green: #1f8f4e; --green-deep: #17753f;
  --accent: var(--ink); --accent-deep: var(--ink); --accent-soft: var(--sand); --accent-light: var(--gold-light);
  --serif: "Cormorant Garamond", "Times New Roman", Georgia, serif;
  --sans: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  --pad: clamp(1.1rem, 4vw, 2.5rem);
  --hh: 5.4rem;
  --r-sm: .75rem; --r: 1.25rem; --r-lg: 1.75rem;
  /* v3 (rifinitura VectorLab): contorno sottile prima dell'ombra, ombre morbide con alfa < .08 */
  --edge: rgba(29, 25, 21, .09); --edge-2: rgba(29, 25, 21, .14);
  --sh-1: 0 1px 2px rgba(29, 25, 21, .04), 0 4px 16px rgba(29, 25, 21, .04);
  --sh-2: 0 1px 3px rgba(29, 25, 21, .05), 0 12px 32px rgba(29, 25, 21, .07);
  /* movimento: solo 150 / 200 / 300 ms, uscita morbida */
  --t1: 150ms; --t2: 200ms; --t3: 300ms;
  --ease: cubic-bezier(.16, 1, .3, 1);
}
.theme-volte { --accent: var(--wine); --accent-deep: var(--wine-deep); --accent-soft: var(--wine-soft); --accent-light: var(--wine-light); }
.theme-carapace { --accent: var(--gold); --accent-deep: var(--gold-deep); --accent-soft: var(--gold-soft); --accent-light: var(--gold-light); }

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 6.5rem; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 1.0625rem/1.6 var(--sans); overflow-x: hidden; padding-bottom: 4.6rem; -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
button { font: inherit; }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 500; line-height: 1.1; margin: 0 0 .5em; letter-spacing: -.01em; text-wrap: balance; }
h2 { font-size: clamp(2.2rem, 5vw, 3.4rem); }
h3 { font-size: 1.55rem; font-weight: 600; }
p { margin: 0 0 1em; }
strong { font-weight: 600; }
.muted { color: var(--muted); }
.small { font-size: .88rem; }
.skip { position: absolute; left: -999px; top: 0; background: #fff; padding: .6rem 1rem; z-index: 100; border-radius: .5rem; }
.skip:focus { left: .5rem; top: .5rem; }
:focus-visible { outline: 2px solid var(--accent-deep); outline-offset: 3px; border-radius: 4px; }
.container { width: min(100% - 2 * var(--pad), 72rem); margin-inline: auto; }
.narrow { width: min(100% - 2 * var(--pad), 44rem); }
.plain { list-style: none; margin: 0; padding: 0; }

/* =========================================================
   NAVBAR FLOTTANTE (21st.dev "Navbar 1", in HTML/CSS)
   ========================================================= */
.site-header { position: fixed; inset: 0 0 auto 0; z-index: 50; padding: calc(.75rem + env(safe-area-inset-top)) var(--pad) 0; pointer-events: none; }
.header-in { pointer-events: auto; position: relative; display: flex; align-items: center; justify-content: space-between; gap: 1rem; height: 4.25rem; width: min(100%, 70rem); margin-inline: auto; padding: 0 .5rem 0 1.5rem; border-radius: 999px; }
/* barra color avorio (lo stesso tono della pagina) con un filo dorato appena visibile;
   sta su uno pseudo-elemento così il menu a tutto schermo resta "fixed" sulla finestra */
.header-in::before { content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; background: rgba(251, 248, 243, .97); border: 1px solid rgba(168, 121, 42, .22); box-shadow: var(--sh-1); transition: box-shadow var(--t3) var(--ease); }
.site-header.scrolled .header-in::before { box-shadow: var(--sh-2); }

/* marchio: arco dorato + filo verticale + "Dimore in Centro" su due righe con "Foligno · Umbria" */
.brand { position: relative; z-index: 2; display: inline-flex; align-items: center; gap: .875rem; text-decoration: none; color: var(--ink); white-space: nowrap; }
.brand-mark { position: relative; flex: none; display: block; width: 1.875rem; height: 1.875rem; color: transparent; }
.brand-mark svg { width: 100%; height: 100%; opacity: 0; }
/* il simbolo è un ritaglio (mask) dell'arco, riempito con un oro caldo leggermente sfumato */
.brand-mark::after { content: ""; position: absolute; inset: 0;
  background: linear-gradient(160deg, #a8792a 0%, #d0a456 40%, #a8792a 65%, #7a561a 100%);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 64' fill='none' stroke='%23000' stroke-width='6' stroke-linecap='round'%3E%3Cpath d='M14 52V30a18 18 0 0 1 36 0v22'/%3E%3Cpath d='M25 52V33a7 7 0 0 1 14 0v19'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 64' fill='none' stroke='%23000' stroke-width='6' stroke-linecap='round'%3E%3Cpath d='M14 52V30a18 18 0 0 1 36 0v22'/%3E%3Cpath d='M25 52V33a7 7 0 0 1 14 0v19'/%3E%3C/svg%3E") center / contain no-repeat;
  }
.brand-text { display: flex; flex-direction: column; align-items: center; gap: .3125rem; padding-left: .875rem; border-left: 1px solid rgba(168, 121, 42, .35); font: 600 1.3125rem/1 var(--serif); letter-spacing: .015em; color: var(--ink); }
/* seconda riga piccola e centrata sotto il nome (scelta dell'utente: sotto i 12px, solo qui) */
.brand-text::after { content: "Foligno \00b7 Umbria"; font: 600 .5625rem/1 var(--sans); letter-spacing: .24em; margin-right: -.24em; text-transform: uppercase; color: var(--gold-deep); }

.nav { display: flex; align-items: center; gap: .25rem; }
.nav a { position: relative; color: var(--ink-2); text-decoration: none; font: 500 .875rem/1 var(--sans); letter-spacing: .01em; padding: .75rem .875rem; border-radius: 999px; }
.nav a:hover { color: var(--ink); }
.nav a[aria-current] { color: var(--ink); font-weight: 600; }
.nav .lang { font-size: .75rem; font-weight: 600; letter-spacing: .14em; color: var(--muted); padding: .75rem .75rem; }
.nav .nav-cta { margin-left: .25rem; background: var(--ink); color: #faf3e3; font-weight: 600; letter-spacing: .02em; padding: .9375rem 1.5rem; box-shadow: inset 0 0 0 1px rgba(233, 201, 135, .35); transition: transform var(--t1) var(--ease); }
.nav .nav-cta:hover { background: #000; color: #faf3e3; }
/* desktop: voci al centro della barra, lingua e "Prenota" a destra; pagina corrente con un punto d'oro sotto */
@media (min-width: 64rem) {
  .nav { flex: 1; }
  .nav a:first-child { margin-left: auto; }
  .nav .lang { margin-left: auto; }
  .nav a[aria-current]::after { content: ""; position: absolute; left: 50%; bottom: .3125rem; width: .25rem; height: .25rem; margin-left: -.125rem; border-radius: 50%; background: var(--gold); }
}
.nav .nav-cta:active { transform: scale(.97); }
/* desktop: passando sopra, ogni voce si solleva come un tasto (bordo, ombra morbida, -2px);
   la "superficie" del tasto è uno pseudo-elemento che appare in dissolvenza */
@media (min-width: 64rem) and (hover: hover) {
  .nav a { isolation: isolate; transition: transform var(--t1) var(--ease); }
  .nav a::before { content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; background: #fff; border: 1px solid var(--edge-2); box-shadow: 0 1px 2px rgba(29, 25, 21, .06), 0 6px 14px rgba(29, 25, 21, .07); opacity: 0; transition: opacity var(--t1) var(--ease); }
  .nav a:hover, .nav a[aria-current]:hover { background: transparent; transform: translateY(-2px); }
  .nav a:hover::before { opacity: 1; }
  .nav a:active { transform: translateY(0); }
  .nav a:active::before { box-shadow: 0 1px 2px rgba(29, 25, 21, .06); }
  .nav .nav-cta::before { background: #000; border-color: #000; box-shadow: 0 2px 4px rgba(29, 25, 21, .12), 0 8px 18px rgba(29, 25, 21, .16); }
  .nav .nav-cta:hover { background: var(--ink); }
}

.burger { display: none; position: relative; z-index: 3; width: 3rem; height: 3rem; border-radius: 50%; border: 1px solid rgba(168, 121, 42, .28); background: #fff; color: var(--ink); cursor: pointer; transition: transform var(--t1); }
.burger:active { transform: scale(.94); }
.burger span { position: absolute; left: .875rem; right: .875rem; top: calc(50% - 1px); height: 2px; background: currentColor; border-radius: 2px; transition: transform var(--t3) var(--ease), opacity var(--t2); }
.burger span:nth-child(1) { transform: translateY(-6px); } .burger span:nth-child(3) { transform: translateY(6px); }
.burger[aria-expanded="true"] span:nth-child(1) { transform: rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.burger[aria-expanded="true"] span:nth-child(3) { transform: rotate(-45deg); }

@media (max-width: 63.99rem) {
  .burger { display: block; }
  .header-in { padding-left: 1rem; padding-right: .5rem; }
  /* menu a tutto schermo che entra da destra, come nella navbar di 21st */
  .nav { position: fixed; inset: 0; z-index: 1; flex-direction: column; align-items: stretch; justify-content: flex-start; gap: .5rem; padding: calc(6.5rem + env(safe-area-inset-top)) var(--pad) 2rem; background: var(--bg); overflow-y: auto; counter-reset: nav;
    transform: translateX(100%); visibility: hidden; transition: transform var(--t3) var(--ease), visibility var(--t3); }
  body.menu-open .nav { transform: none; visibility: visible; }
  body.menu-open { overflow: hidden; }
  /* voci del menu: righe-scheda bianche con numero, nome in Manrope e freccia */
  .nav a { counter-increment: nav; display: flex; align-items: center; gap: 1rem; font: 600 1.375rem/1.2 var(--sans); letter-spacing: -.01em; color: var(--ink); padding: 1.125rem 1.25rem; border-radius: var(--r); border: 1px solid var(--edge); background: #fff !important; box-shadow: var(--sh-1); opacity: 0; transform: translateX(8px); transition: opacity var(--t3) var(--ease), transform var(--t3) var(--ease); }
  .nav a::before { content: counter(nav, decimal-leading-zero); min-width: 1.5rem; font: 500 .8125rem/1 var(--sans); letter-spacing: .08em; color: var(--muted); }
  .nav a::after { content: "\2192"; margin-left: auto; font-weight: 400; color: var(--muted); }
  body.menu-open .nav a:active { transform: scale(.98); }
  body.menu-open .nav a { opacity: 1; transform: none; }
  body.menu-open .nav a:nth-child(1) { transition-delay: 60ms; } body.menu-open .nav a:nth-child(2) { transition-delay: 90ms; }
  body.menu-open .nav a:nth-child(3) { transition-delay: 120ms; } body.menu-open .nav a:nth-child(4) { transition-delay: 150ms; }
  body.menu-open .nav a:nth-child(5) { transition-delay: 180ms; } body.menu-open .nav a:nth-child(6) { transition-delay: 210ms; }
  body.menu-open .nav a:nth-child(7) { transition-delay: 240ms; }
  /* pagina corrente: scheda piena nel colore della casa (bordeaux, oro o scuro) */
  .nav a[aria-current] { background: var(--accent-deep) !important; border-color: var(--accent-deep); color: #fff; }
  .nav a[aria-current]::before, .nav a[aria-current]::after { color: rgba(255, 255, 255, .7); }
  .nav .lang, .nav .nav-cta { counter-increment: none; box-shadow: none; }
  .nav .lang::before, .nav .lang::after, .nav .nav-cta::before, .nav .nav-cta::after { content: none; }
  .nav .lang { align-self: flex-start; margin: 1rem 0 0; font: 600 .875rem var(--sans); letter-spacing: .08em; padding: .75rem 1.25rem; border: 1px solid var(--edge-2) !important; border-radius: 999px; background: transparent !important; }
  .nav .nav-cta { justify-content: center; margin: .75rem 0 0; font: 600 1rem var(--sans); padding: 1.125rem; border-radius: 999px; border: 0; background: var(--ink) !important; color: #fff; }
  body.menu-open .mbar { display: none; }
}
@media (max-width: 26rem) { .brand { gap: .625rem; } .brand-text { font-size: 1.1875rem; padding-left: .625rem; } .brand-mark { width: 1.625rem; height: 1.625rem; } }

/* ---------- bottoni ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; min-height: 3rem; padding: .75rem 1.5rem; border-radius: 999px; font: 600 .9375rem var(--sans); text-decoration: none; border: 1px solid transparent; cursor: pointer; transition: transform var(--t1) var(--ease); text-align: center; }
.btn:active { transform: scale(.97); }
.btn-solid, .btn-theme { background: var(--ink); color: #fff; }
.btn-solid:hover, .btn-theme:hover { background: #000; }
.c-carapace .btn-theme { background: var(--gold-deep); } .c-volte .btn-theme { background: var(--wine); }
.c-carapace .btn-theme:hover { background: #5e4214; } .c-volte .btn-theme:hover { background: var(--wine-deep); }
.link-arrow { font-weight: 600; text-decoration: none; color: var(--ink); border-bottom: 1px solid var(--accent, var(--ink)); padding-bottom: 2px; }
.link-arrow::after { content: " \2192"; display: inline-block; transition: transform var(--t2) var(--ease); }
.link-arrow:hover::after { transform: translateX(4px); }

/* ---------- etichette ---------- */
.eyebrow { display: inline-flex; align-items: center; gap: .75rem; font: 600 .75rem/1.2 var(--sans); letter-spacing: .2em; text-transform: uppercase; color: var(--gold-deep); margin-bottom: 1rem; }
.eyebrow::before { content: ""; width: 2rem; height: 1px; background: currentColor; }

/* =========================================================
   HOME: le due case affiancate
   ========================================================= */
.split { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: .5rem; min-height: 100svh; padding: .5rem; background: var(--bg); }
.split-p { position: relative; display: flex; align-items: center; justify-content: center; text-align: center; color: #fff; text-decoration: none; overflow: hidden; min-height: calc(100svh - 1rem); border-radius: var(--r-lg); isolation: isolate; }
.split-p img { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; transition: transform var(--t3) var(--ease); }
.split-p:hover img { transform: scale(1.02); }
.sp-shade { position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(15, 12, 10, .45) 0, rgba(15, 12, 10, .18) 35%, rgba(15, 12, 10, .3) 60%, rgba(15, 12, 10, .72) 100%); }
.sp-in { display: flex; flex-direction: column; align-items: center; gap: .75rem; padding: 0 var(--pad) 6rem; max-width: 34rem; }
.sp-name { font: 500 clamp(2.6rem, 5.4vw, 4.6rem)/1.1 var(--serif); letter-spacing: -.01em; text-shadow: 0 2px 24px rgba(0, 0, 0, .35); }
/* voto sulla foto: fondo scuro pieno al posto del vetro sfocato */
.sp-rate { display: inline-flex; align-items: center; gap: .5rem; font: 500 .875rem var(--sans); padding: .25rem 1rem .25rem .25rem; border-radius: 999px; background: rgba(15, 12, 10, .55); border: 1px solid rgba(255, 255, 255, .28); }
.sp-rate b { display: inline-grid; place-items: center; min-width: 2.25rem; height: 1.75rem; border-radius: 999px; background: #fff; color: var(--ink); font-weight: 600; font-size: .8125rem; }
.sp-btn { margin-top: .5rem; display: inline-flex; align-items: center; gap: .5rem; min-height: 3rem; padding: .5rem 1.5rem; border-radius: 999px; font: 600 .875rem var(--sans); background: #fff; color: var(--ink); }
.sp-btn::after { content: "\2192"; transition: transform var(--t2) var(--ease); }
.split-p:hover .sp-btn::after { transform: translateX(4px); }

.db-wrap { position: absolute; z-index: 4; left: 0; right: 0; bottom: 2rem; display: flex; flex-direction: column; align-items: center; gap: 1rem; pointer-events: none; padding-inline: var(--pad); }
.db-wrap > * { pointer-events: auto; }
.split-title { margin: 0; color: #fff; font: 600 .75rem/1.2 var(--sans); letter-spacing: .24em; text-transform: uppercase; text-shadow: 0 1px 12px rgba(0, 0, 0, .6); pointer-events: none !important; }
.datebar { display: flex; align-items: stretch; background: #fff; border-radius: 999px; padding: .5rem .5rem .5rem 1.25rem; border: 1px solid var(--edge); box-shadow: 0 12px 32px rgba(0, 0, 0, .18); color: var(--ink); }
.datebar label { display: flex; flex-direction: column; justify-content: center; padding: .25rem 1rem; border-right: 1px solid var(--line); }
.datebar label span { font: 600 .75rem var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.datebar input { border: 0; background: transparent; font: 600 .9375rem var(--sans); color: var(--ink); padding: .125rem 0; width: 9.5rem; min-height: 1.75rem; }
.datebar input:focus { outline: none; }
.datebar label:focus-within span { color: var(--gold-deep); }
.datebar .db-g input { width: 3.5rem; }
.datebar button { margin-left: .5rem; border: 0; border-radius: 999px; background: var(--ink); color: #fff; padding: 0 1.75rem; font: 600 .875rem var(--sans); cursor: pointer; min-height: 3.25rem; transition: transform var(--t1) var(--ease); }
.datebar button:hover { background: #000; }
.datebar button:active { transform: scale(.97); }

/* ---------- hero (pagine appartamento e Foligno) ---------- */
.hero { position: relative; min-height: 86svh; display: flex; align-items: flex-end; color: #fff; background: var(--ink); overflow: hidden; margin: .5rem; border-radius: var(--r-lg); isolation: isolate; }
.hero img { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; }
.hero-shade { position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(15, 12, 10, .42) 0, rgba(15, 12, 10, 0) 28%, rgba(15, 12, 10, .12) 55%, rgba(15, 12, 10, .78) 100%); }
.hero-text { width: min(100% - 2 * var(--pad), 72rem); margin: 0 auto; padding-bottom: clamp(2.2rem, 6vw, 4.5rem); }
.hero h1 { font-size: clamp(3rem, 9vw, 6.4rem); line-height: 1.1; margin-bottom: .15em; text-shadow: 0 2px 24px rgba(0, 0, 0, .3); }
.hero p { font-size: clamp(1.05rem, 2.4vw, 1.3rem); max-width: 34rem; opacity: .95; }
.g-hero { min-height: 62svh; }
/* titolo Foligno: etichetta sottile, titolo leggero con "Foligno" in corsivo dorato */
.g-hero h1 { max-width: 14ch; font-weight: 500; font-size: clamp(2.75rem, 8vw, 6rem); letter-spacing: -.02em; line-height: 1.1; }
.g-hero h1 em { font-style: italic; color: var(--gold-light); }
.g-kicker { display: inline-flex; align-items: center; gap: .75rem; margin: 0 0 1rem; font: 600 .75rem/1.2 var(--sans); letter-spacing: .22em; text-transform: uppercase; color: rgba(255, 255, 255, .9); }
.g-kicker::before { content: ""; width: 2.5rem; height: 1px; background: var(--gold-light); }

.badge { display: inline-flex; flex-direction: column; gap: .25rem; margin: .5rem 0 0; padding: .75rem 1.25rem; border-radius: var(--r); background: rgba(15, 12, 10, .55); border: 1px solid rgba(255, 255, 255, .28); color: #fff; line-height: 1.2; }
.badge strong { font: 600 1.5rem/1.1 var(--serif); }
.badge span { font-size: .8125rem; color: rgba(255, 255, 255, .9); }
.apt-img .badge { position: absolute; left: 1rem; bottom: 1rem; margin: 0; background: rgba(15, 12, 10, .6); }

/* ---------- sezioni ---------- */
.section { padding: clamp(4rem, 9vw, 7rem) 0; }
.band { background: var(--sand); }
.sec-head { max-width: 44rem; margin-bottom: clamp(2rem, 4vw, 3rem); }
.sec-head h2 { margin-bottom: .3em; }
.h2-left { margin-bottom: .6em; }

/* perché sceglierci */
.why-grid { display: grid; gap: 1rem; grid-template-columns: repeat(4, 1fr); counter-reset: why; }
.why-item { position: relative; background: var(--surface); border-radius: var(--r); padding: 1.5rem 1.5rem 1.75rem; box-shadow: var(--sh-1); border: 1px solid var(--edge); counter-increment: why; }
.why-item::before { content: "0" counter(why); display: block; font: 500 2.5rem/1.1 var(--serif); color: var(--gold); margin-bottom: 1rem; }
.why-item:nth-child(even)::before { color: var(--wine); }
.why-item h3 { font: 600 1rem/1.3 var(--sans); margin-bottom: .5rem; letter-spacing: 0; }
.why-item p { margin: 0; color: var(--muted); font-size: .9375rem; line-height: 1.6; }

/* card appartamenti */
.apt-grid { display: grid; gap: clamp(1.5rem, 3vw, 2rem); grid-template-columns: repeat(2, 1fr); }
.apt-grid.one { grid-template-columns: minmax(0, 40rem); }
.apt-card { background: var(--surface); border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--sh-1); border: 1px solid var(--edge); display: flex; flex-direction: column; transition: transform var(--t3) var(--ease); }
.apt-card:hover { box-shadow: var(--sh-2); border-color: var(--edge-2); transform: translateY(-2px); }
.c-carapace { --accent: var(--gold); --accent-deep: var(--gold-deep); }
.c-volte { --accent: var(--wine); --accent-deep: var(--wine-deep); }
.apt-img { position: relative; display: block; aspect-ratio: 16 / 10; background: var(--sand); overflow: hidden; }
.apt-img img { width: 100%; height: 100%; object-fit: cover; transition: transform var(--t3) var(--ease); }
.apt-card:hover .apt-img img { transform: scale(1.02); }
.apt-body { padding: 1.5rem 1.5rem 1.75rem; display: flex; flex-direction: column; align-items: flex-start; flex: 1; }
.apt-body h3 { font-size: 2.1rem; font-weight: 500; margin-bottom: .3em; }
.apt-body h3 a { text-decoration: none; }
.apt-body .btn { margin-top: auto; }
.facts { font: 600 .875rem var(--sans); letter-spacing: .04em; color: var(--accent-deep); }
.mini-score { font-size: .875rem; color: var(--muted); margin-bottom: .75rem; }
.mini-score span { display: inline-grid; place-items: center; min-width: 2.25rem; height: 1.75rem; background: var(--accent-deep); color: #fff; font-weight: 600; border-radius: .5rem; margin-right: .5rem; font-size: .8125rem; }

.ticks { list-style: none; margin: 0 0 .5rem; padding: 0; }
.ticks li { position: relative; padding: .5rem 0 .5rem 2rem; font-weight: 500; border-bottom: 1px solid var(--line); }
.ticks li:last-child { border-bottom: 0; }
.ticks li::before { content: ""; position: absolute; left: 0; top: .75rem; width: 1.25rem; height: 1.25rem; border-radius: 50%; background: var(--accent-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231d1915' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / .75rem no-repeat; }

.map { border-radius: var(--r); overflow: hidden; aspect-ratio: 4 / 3; background: var(--sand); box-shadow: var(--sh-1); border: 1px solid var(--line); }
.map iframe { width: 100%; height: 100%; border: 0; }

/* =========================================================
   RECENSIONI
   ========================================================= */
.reviews { background: var(--bg); }
.rcol { margin-bottom: 3.5rem; --accent: var(--gold); --accent-deep: var(--gold-deep); --accent-soft: var(--gold-soft); }
.rcol.r-volte { --accent: var(--wine); --accent-deep: var(--wine-deep); --accent-soft: var(--wine-soft); }
.reviews.one .rcol { margin-bottom: 0; }
.rhead { display: flex; align-items: center; gap: 1.25rem; margin-bottom: 1.5rem; }
.rscore { flex: none; width: 5.5rem; height: 5.5rem; border-radius: var(--r); background: var(--accent-deep); color: #fff; display: grid; place-content: center; text-align: center; line-height: 1.1; }
.rnum { font: 600 2.25rem var(--serif); } .rof { font-size: .75rem; letter-spacing: .1em; text-transform: uppercase; color: rgba(255, 255, 255, .85); margin-top: .25rem; }
.rname { font: 500 2rem/1.1 var(--serif); margin: 0; }
.rcount { margin: .125rem 0 .5rem; color: var(--muted); font-size: .875rem; }
/* punteggi parziali: testo semplice, senza capsule */
.chips { display: flex; flex-wrap: wrap; gap: .25rem 1.25rem; list-style: none; margin: 0; padding: 0; font-size: .875rem; }
.chips li { color: var(--ink); }
.chips li span { color: var(--muted); }
.rwrap { position: relative; }
.rrow, .strack { display: flex; gap: 1rem; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; -webkit-overflow-scrolling: touch; overscroll-behavior-x: contain; scroll-behavior: smooth; }
.rrow::-webkit-scrollbar, .strack::-webkit-scrollbar { display: none; }
.rrow { padding: .5rem var(--pad) 1.5rem; margin-inline: calc(-1 * var(--pad)); scroll-padding-inline: var(--pad); }
.rcard { flex: 0 0 min(84%, 22rem); scroll-snap-align: start; margin: 0; background: var(--surface); border-radius: var(--r); padding: 1.5rem 1.5rem 1.25rem; box-shadow: var(--sh-1); border: 1px solid var(--edge); display: flex; flex-direction: column; }
.rcard blockquote { position: relative; margin: .75rem 0 1.25rem; font: italic 500 1.3125rem/1.4 var(--serif); flex: 1; }
.rcard blockquote p { margin: 0; }
.rcard figcaption { font-size: .875rem; color: var(--muted); padding-top: 1rem; border-top: 1px solid var(--line); }
.rcard figcaption strong { color: var(--ink); }
.stars { color: var(--accent); display: flex; gap: 2px; }
.rarr, .sarr { position: absolute; top: 50%; width: 3rem; height: 3rem; border-radius: 50%; border: 1px solid var(--edge-2); background: #fff; color: var(--ink); font-size: 1.75rem; line-height: 1; cursor: pointer; display: none; place-items: center; box-shadow: var(--sh-2); padding: 0 0 .25rem; transition: transform var(--t1) var(--ease); }
.rarr:hover, .sarr:hover { border-color: var(--ink); }
.rarr:active, .sarr:active { transform: scale(.94); }
.rarr { margin-top: -1.75rem; } .sarr { margin-top: -1.5rem; }
/* frecce recensioni fuori dal testo: metà sul bordo, metà sul margine (il testo inizia dopo 1.5rem di padding) */
.r-prev { left: -1.75rem; } .r-next { right: -1.75rem; }
.s-prev { left: 1rem; } .s-next { right: 1rem; }
@media (hover: hover) and (min-width: 48rem) { .rarr, .sarr { display: grid; } }

/* =========================================================
   PAGINA APPARTAMENTO
   ========================================================= */
.facts-bar { position: relative; z-index: 2; margin-top: -3.25rem; }
.facts-row { display: grid; grid-template-columns: repeat(4, 1fr); margin: 0; padding: 1.25rem .5rem; text-align: center; background: var(--surface); border-radius: var(--r); border: 1px solid var(--edge); box-shadow: var(--sh-2); width: min(100%, 52rem); margin-inline: auto; }
.fact + .fact { border-left: 1px solid var(--line); }
.fact dt { font: 600 .75rem var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.fact dd { margin: .25rem 0 0; font: 500 2rem/1.1 var(--serif); color: var(--accent-deep); }
.about { max-width: 46rem; margin-bottom: 2.5rem; }
.about p { font-size: 1.125rem; color: #3b332c; }
.about strong { color: var(--ink); font-weight: 600; }
.beds { padding: 1rem 1.25rem; border-radius: var(--r-sm); background: var(--accent-soft); color: var(--accent-deep) !important; font-size: 1rem !important; }
.panels { display: grid; gap: 1.25rem; grid-template-columns: 1fr 1.4fr; align-items: start; }
.panel { background: var(--surface); border-radius: var(--r); padding: 2rem; box-shadow: var(--sh-1); border: 1px solid var(--edge); }
.panel h3 { font-size: 1.875rem; font-weight: 500; }
.sgroup h4 { font: 600 .75rem var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--accent-deep); margin: 1.5rem 0 .5rem; }
.sgroup:first-of-type h4 { margin-top: 0; }
.amen { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 0 1.5rem; }
.amen li { padding: .5rem 0 .5rem 1.25rem; position: relative; font-weight: 500; font-size: 1rem; border-bottom: 1px solid var(--line); }
.amen li::before { content: ""; position: absolute; left: 0; top: 1.075rem; width: .45rem; height: .45rem; background: var(--accent); border-radius: 50%; }

/* galleria */
.gallery { padding-bottom: clamp(2.5rem, 6vw, 4.5rem); }
.slider { position: relative; margin-top: .5rem; }
.strack { padding: .25rem var(--pad) 1rem; scroll-padding-inline: var(--pad); }
.slide { flex: 0 0 86%; scroll-snap-align: center; aspect-ratio: 4 / 3; border-radius: var(--r); overflow: hidden; background: var(--sand-2); border: 1px solid var(--edge); -webkit-tap-highlight-color: transparent; cursor: zoom-in; }
.slide img { width: 100%; height: 100%; object-fit: cover; transition: transform var(--t3) var(--ease); }
.slide:hover img { transform: scale(1.02); }
.scount { position: absolute; right: calc(var(--pad) + .75rem); bottom: 1.75rem; margin: 0; background: rgba(15, 12, 10, .72); color: #fff; font-weight: 600; font-size: .8125rem; letter-spacing: .04em; border-radius: 999px; padding: .25rem .75rem; }

/* lightbox */
.lb { position: fixed; inset: 0; z-index: 90; background: rgba(12, 10, 8, .95); display: grid; place-items: center; touch-action: pan-y; animation: lb-in var(--t2) var(--ease); }
@keyframes lb-in { from { opacity: 0; } }
.lb[hidden] { display: none; }
.lb-img { max-width: 94vw; max-height: 86svh; object-fit: contain; border-radius: .5rem; user-select: none; -webkit-user-drag: none; }
.lb button { position: absolute; background: rgba(255, 255, 255, .12); color: #fff; border: 1px solid rgba(255, 255, 255, .24); border-radius: 50%; width: 3.25rem; height: 3.25rem; font-size: 1.875rem; line-height: 1; cursor: pointer; }
.lb button:hover { background: rgba(255, 255, 255, .24); }
.lb-x { top: calc(1rem + env(safe-area-inset-top)); right: 1rem; } .lb-p { left: 1rem; top: 50%; margin-top: -1.625rem; } .lb-n { right: 1rem; top: 50%; margin-top: -1.625rem; }
.lb-c { position: absolute; bottom: calc(1.25rem + env(safe-area-inset-bottom)); left: 0; right: 0; text-align: center; color: rgba(255, 255, 255, .8); margin: 0; font-weight: 600; font-size: .875rem; letter-spacing: .06em; }
@media (max-width: 47.99rem) { .lb-p, .lb-n { display: none; } }

/* =========================================================
   CHIEDI UN PREVENTIVO
   ========================================================= */
.q-sec { position: relative; overflow: hidden; color: #fff; text-align: center; padding: clamp(4.5rem, 10vw, 7.5rem) 0; margin: 0 .5rem; border-radius: var(--r-lg);
  background: radial-gradient(50rem 26rem at 50% -10%, color-mix(in srgb, var(--accent-light) 30%, transparent), transparent 65%), linear-gradient(170deg, #241e19, #15110e); }
.theme-volte .q-sec { background: radial-gradient(50rem 26rem at 50% -10%, rgba(232, 169, 182, .22), transparent 65%), linear-gradient(170deg, #3a1520, #1a0d11); }
.theme-carapace .q-sec { background: radial-gradient(50rem 26rem at 50% -10%, rgba(233, 201, 135, .25), transparent 65%), linear-gradient(170deg, #3a2a12, #17110a); }
/* intestazione del preventivo: titolo dritto con filo d'oro, testo e vantaggi allineati a sinistra;
   su schermi larghi a due colonne (testo e contatti a sinistra, modulo a destra) */
.qwrap { max-width: 44rem; margin-inline: auto; scroll-margin-top: 6.5rem; text-align: left; }
.q-head { margin-bottom: 2rem; }
.q-head h2 { position: relative; font: 500 clamp(2.5rem, 6vw, 3.75rem)/1.1 var(--serif); letter-spacing: -.01em; color: #fff; margin: 0 0 1rem; padding-top: 1.5rem; }
.q-head h2::before { content: ""; position: absolute; top: 0; left: 0; width: 3rem; height: 2px; background: var(--accent-light); }
.q-head > p { font-size: 1.125rem; line-height: 1.6; max-width: 26rem; margin: 0 0 1.75rem; color: rgba(255, 255, 255, .82); }
/* vantaggi: testo semplice con un punto colorato, senza capsule */
/* vantaggi: elenco verticale con spunta dorata in un piccolo tondo */
.q-chips { list-style: none; margin: 0; padding: 0; display: grid; gap: .75rem; }
.q-chips li { display: flex; align-items: center; gap: .75rem; font: 500 1rem/1.4 var(--sans); }
.q-chips li::before { content: ""; flex: none; width: 1.5rem; height: 1.5rem; border-radius: 50%; border: 1px solid rgba(233, 201, 135, .7);
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23e9c987' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4L18 8.5'/%3E%3C/svg%3E") center / .875rem no-repeat; }
@media (min-width: 64rem) {
  .qwrap { max-width: 68rem; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.35fr); grid-template-rows: auto 1fr; column-gap: 4.5rem; align-items: start; }
  .q-head { grid-column: 1; grid-row: 1; margin: 0; padding-top: 1rem; }
  .qwrap > .quote { grid-column: 2; grid-row: 1 / span 2; }
  .qwrap > .q-contacts { grid-column: 1; grid-row: 2; align-self: end; flex-direction: column; align-items: flex-start; margin: 2.5rem 0 0; }
}
.quote { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; text-align: left; background: var(--surface); color: var(--ink); border-radius: var(--r-lg); padding: clamp(1.5rem, 4vw, 2.25rem); border: 1px solid rgba(255, 255, 255, .12); box-shadow: 0 24px 48px rgba(0, 0, 0, .25); }
.field { display: flex; flex-direction: column; gap: .5rem; min-width: 0; }
.field label { font: 600 .75rem var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.field input, .field select, .field textarea { font: 500 1rem var(--sans); width: 100%; min-height: 3.25rem; padding: .75rem 1rem; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--bg); color: var(--ink); }
.field textarea { resize: vertical; }
.field input:hover, .field select:hover, .field textarea:hover { border-color: #d3c7b6; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; background: #fff; border-color: var(--accent-deep); box-shadow: 0 0 0 4px var(--accent-soft); }
.full { grid-column: 1 / -1; }
.actions { display: flex; flex-wrap: wrap; gap: .75rem; }
.actions .btn { flex: 1 1 12rem; min-height: 3.5rem; }
.q-wa { background: var(--green); color: #fff; }
.q-wa:hover { background: var(--green-deep); }
.q-mail { background: transparent; color: var(--ink); border-color: var(--edge-2); }
.q-mail:hover { border-color: var(--ink); background: var(--ink); color: #fff; }
.form-err { color: #a3121e; font-weight: 600; margin: 0; grid-column: 1 / -1; padding: .75rem 1rem; background: #fdecee; border-radius: var(--r-sm); }
.form-note { font-size: .8125rem; color: var(--muted); margin: 0; text-align: center; }
.q-contacts { list-style: none; margin: 2rem 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: .5rem; justify-content: flex-start; }
.q-contacts a { display: inline-flex; align-items: center; gap: .5rem; color: #fff; text-decoration: none; font-weight: 600; font-size: .9375rem; padding: .75rem 1.25rem; border: 1px solid rgba(255, 255, 255, .28); border-radius: 999px; }
.q-contacts a:hover { background: #fff; color: var(--ink); }
.q-contacts svg { width: 1.125rem; height: 1.125rem; }

/* home: preventivo su sfondo chiaro */
.q-sec.q-neutral { background: var(--sand); color: var(--ink); }
.q-neutral .q-head h2 { color: var(--ink); }
.q-neutral .q-head > p { color: var(--muted); }
.q-neutral .q-head h2::before { background: var(--gold); }
.q-neutral .q-chips li::before { border-color: var(--gold); background-color: #fff; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237a561a' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4L18 8.5'/%3E%3C/svg%3E"); }
.q-neutral .quote { border-color: var(--edge); box-shadow: var(--sh-2); }
.q-neutral .q-contacts a { color: var(--ink); border-color: #d6cbbb; background: rgba(255, 255, 255, .5); }
.q-neutral .q-contacts a:hover { background: var(--ink); color: #fff; }

/* ---------- pagine di testo ---------- */
.page-top { padding-top: calc(var(--hh) + 3rem); }
.h1-plain { font-size: clamp(2.6rem, 7vw, 4rem); }
.small-h { font: 600 1.5rem var(--serif); margin-top: 1.8em; }

/* =========================================================
   PAGINA FOLIGNO
   ========================================================= */
.g-map { padding: clamp(2.5rem, 5vw, 4rem) 0 0; }
.map-wide { aspect-ratio: 16 / 8; max-height: 34rem; position: relative; isolation: isolate; }
.g-maplink { text-align: center; margin: 1.25rem 0 0; }

/* ---------- mappa interattiva (Leaflet) ---------- */
/* segnaposto: tondo colorato con bordo bianco, casa per gli appartamenti, P per i parcheggi */
.pin { flex: none; display: inline-grid; place-items: center; width: 2.25rem; height: 2.25rem; border-radius: 50%; border: 2px solid #fff; color: #fff; font: 600 1rem/1 var(--sans); box-shadow: 0 1px 3px rgba(29, 25, 21, .25), 0 4px 12px rgba(29, 25, 21, .18); }
.pin-home { background-position: center; background-repeat: no-repeat; background-size: 1.125rem; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 10.5 12 3l9 7.5'/%3E%3Cpath d='M5.5 9v11h13V9'/%3E%3Cpath d='M10 20v-5.5h4V20'/%3E%3C/svg%3E"); }
.pin-volte { background-color: var(--wine); }
.pin-carapace { background-color: var(--gold-deep); }
.pin-free { background-color: #2d6a4f; }
.pin-paid { background-color: var(--ink); }
.leaflet-marker-icon.pin-home { width: 2.75rem !important; height: 2.75rem !important; background-size: 1.375rem; }
.map-legend { list-style: none; margin: 1rem 0 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: .75rem 1.5rem; font-size: .875rem; font-weight: 500; }
.map-legend li { display: inline-flex; align-items: center; gap: .5rem; }
.map-legend .pin { width: 1.75rem; height: 1.75rem; font-size: .8125rem; background-size: .875rem; box-shadow: none; border-width: 1.5px; }
/* su schermi larghi la legenda sta dentro la mappa, in basso a sinistra */
.map-canvas { position: absolute; inset: 0; }
.map-canvas.leaflet-container { background: #f1ebe1; }
.map-label { width: max-content !important; height: auto !important; transform-origin: 0 0; translate: -50% -50%; padding: 0; font: 600 .75rem/1.2 var(--sans); color: #6b6158; letter-spacing: .02em; text-align: center; white-space: nowrap; text-shadow: 0 0 3px #fff, 0 0 3px #fff, 0 0 3px #fff; pointer-events: none; }
.map-label-water { color: #5d8494; font-style: italic; font-weight: 500; }
/* città vicine: nome, segnaposto, etichetta con km e minuti, tasto per tornare al centro */
.map-label-town { translate: -50% -190%; font: 600 .8125rem/1.2 var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); }
.map-label-town.is-on { font-size: .9375rem; color: var(--ink); }
.pin-town { width: 1.375rem; height: 1.375rem; background: #fff; border: 4px solid var(--gold-deep); }
.route-badge { width: max-content !important; height: auto !important; translate: -50% -50%; padding: .375rem .875rem; border-radius: 999px; background: var(--ink); color: #faf3e3; border: 1px solid rgba(233, 201, 135, .45); font: 600 .8125rem/1.3 var(--sans); white-space: nowrap; box-shadow: var(--sh-2); pointer-events: none; }
.route-badge b { color: var(--gold-light); font-weight: 600; }
/* nascosto finché non si sceglie una città (selettore doppio per vincere su .leaflet-bar) */
.leaflet-bar.map-back { display: none; }
.leaflet-bar.map-back.is-on { display: flex; }
.map-back a { display: inline-flex !important; align-items: center; gap: .5rem; width: auto !important; padding: 0 1rem; font: 600 .875rem/1 var(--sans) !important; }
@media (min-width: 48rem) {
  .map .map-legend.on-map { position: absolute; z-index: 1000; left: 1rem; bottom: 1rem; margin: 0; flex-direction: column; align-items: flex-start; gap: .5rem; padding: .75rem 1rem; background: #fff; border: 1px solid var(--edge-2); border-radius: var(--r-sm); box-shadow: var(--sh-1); }
}

/* stile essenziale di Leaflet (riscritto qui: niente fogli di stile esterni) */
.leaflet-container { overflow: hidden; background: var(--sand); font-family: var(--sans); -webkit-tap-highlight-color: transparent; outline-offset: 1px; }
.leaflet-pane, .leaflet-tile, .leaflet-marker-icon, .leaflet-marker-shadow, .leaflet-tile-container, .leaflet-pane > svg, .leaflet-pane > canvas, .leaflet-zoom-box, .leaflet-image-layer, .leaflet-layer { position: absolute; left: 0; top: 0; }
.leaflet-container img { max-width: none !important; max-height: none !important; }
.leaflet-tile, .leaflet-marker-icon { user-select: none; -webkit-user-drag: none; }
.leaflet-tile { visibility: hidden; } .leaflet-tile-loaded { visibility: inherit; }
/* mappa più calda e meno colorata, in tono con il sito */
.leaflet-tile-pane { z-index: 200; filter: grayscale(.55) sepia(.12) contrast(.95) brightness(1.03); }
.leaflet-overlay-pane { z-index: 400; } .leaflet-shadow-pane { z-index: 500; } .leaflet-marker-pane { z-index: 600; } .leaflet-tooltip-pane { z-index: 650; } .leaflet-popup-pane { z-index: 700; }
.leaflet-zoom-animated { transform-origin: 0 0; }
.leaflet-zoom-anim .leaflet-zoom-animated { transition: transform var(--t2) cubic-bezier(0, 0, .25, 1); }
.leaflet-zoom-anim .leaflet-tile, .leaflet-pan-anim .leaflet-tile { transition: none; }
.leaflet-zoom-anim .leaflet-zoom-hide { visibility: hidden; }
.leaflet-marker-icon, .leaflet-tile-container { pointer-events: none; }
.leaflet-marker-icon.leaflet-interactive, .leaflet-interactive { pointer-events: auto; cursor: pointer; }
.leaflet-grab { cursor: grab; } .leaflet-dragging .leaflet-grab { cursor: grabbing; }
.leaflet-container.leaflet-touch-zoom { touch-action: pan-x pan-y; }
.leaflet-container.leaflet-touch-drag { touch-action: pinch-zoom; }
.leaflet-container.leaflet-touch-drag.leaflet-touch-zoom { touch-action: none; }
.leaflet-control { position: relative; z-index: 800; pointer-events: auto; float: left; clear: both; }
.leaflet-top, .leaflet-bottom { position: absolute; z-index: 1000; pointer-events: none; }
.leaflet-top { top: 0; } .leaflet-right { right: 0; } .leaflet-bottom { bottom: 0; } .leaflet-left { left: 0; }
.leaflet-right .leaflet-control { float: right; margin-right: 1rem; } .leaflet-left .leaflet-control { margin-left: 1rem; }
.leaflet-top .leaflet-control { margin-top: 1rem; } .leaflet-bottom .leaflet-control { margin-bottom: 0; }
.leaflet-bar { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--edge-2); border-radius: var(--r-sm); box-shadow: var(--sh-1); overflow: hidden; }
.leaflet-bar a { display: grid; place-items: center; width: 2.5rem; height: 2.5rem; color: var(--ink); text-decoration: none; font: 500 1.25rem/1 var(--sans); }
.leaflet-bar a + a { border-top: 1px solid var(--line); }
.leaflet-bar a:hover { background: var(--sand); }
.leaflet-bar a.leaflet-disabled { color: #b5aca0; cursor: default; background: #fff; }
.leaflet-control-attribution { margin: 0; padding: .125rem .5rem; background: rgba(255, 255, 255, .85); color: var(--muted); font-size: .75rem; line-height: 1.4; border-top-left-radius: .375rem; }
.leaflet-control-attribution a { color: var(--ink-2); }
.leaflet-popup { position: absolute; text-align: center; margin-bottom: 1.75rem; }
.leaflet-popup-content-wrapper { text-align: left; background: #fff; color: var(--ink); border: 1px solid var(--edge-2); border-radius: var(--r-sm); box-shadow: var(--sh-2); }
.leaflet-popup-content { margin: 1rem 2.25rem 1rem 1.125rem; min-width: 12rem; font-size: .875rem; line-height: 1.5; }
.leaflet-popup-tip-container { width: 2.5rem; height: 1.25rem; position: absolute; left: 50%; margin-top: -1px; margin-left: -1.25rem; overflow: hidden; pointer-events: none; }
.leaflet-popup-tip { width: 1rem; height: 1rem; margin: -.5rem auto 0; background: #fff; border: 1px solid var(--edge-2); transform: rotate(45deg); }
.leaflet-container a.leaflet-popup-close-button { position: absolute; top: .25rem; right: .25rem; display: grid; place-items: center; width: 2rem; height: 2rem; border-radius: 50%; color: var(--muted); font: 400 1.25rem/1 var(--sans); text-decoration: none; }
.leaflet-container a.leaflet-popup-close-button:hover { background: var(--sand); color: var(--ink); }
.mp-name { display: block; font: 600 1.25rem/1.2 var(--serif); margin-bottom: .25rem; }
.mp-meta { display: block; color: var(--muted); }
.mp-tag { display: inline-block; margin: .25rem 0 .5rem; padding: .125rem .5rem; border-radius: .375rem; font: 600 .75rem/1.5 var(--sans); letter-spacing: .06em; text-transform: uppercase; background: var(--sand); color: var(--ink-2); }
.mp-tag.free { background: #e3f0e8; color: #1f5a3f; }
.mp-walk { display: block; }
.mp-warn { display: block; margin-top: .25rem; color: #9a1220; font-weight: 600; }
.mp-link { display: inline-block; margin-top: .5rem; font-weight: 600; color: var(--ink) !important; text-decoration: underline; text-underline-offset: 3px; }
.g-pills { position: sticky; top: 5.5rem; z-index: 30; margin-top: 2.5rem; pointer-events: none; }
.g-pills .container { display: flex; gap: .25rem; overflow-x: auto; padding: .375rem; scrollbar-width: none; justify-content: center; width: max-content; max-width: calc(100% - 2 * var(--pad)); border-radius: 999px; background: #fff; border: 1px solid var(--edge-2); box-shadow: var(--sh-1); pointer-events: auto; }
.g-pills a { flex: none; font: 600 .875rem var(--sans); text-decoration: none; padding: .5rem 1rem; border-radius: 999px; color: var(--ink-2); }
.g-pills a:hover { background: var(--ink); color: #fff; }
.g-sec { padding: clamp(3.5rem, 8vw, 6rem) 0; }
.g-h2 { text-align: center; margin: 0 auto 2.5rem; }
.g-intro { text-align: center; max-width: 38rem; margin: -1.25rem auto 2.5rem; color: var(--muted); }
.sights { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; max-width: 64rem; margin-inline: auto; counter-reset: sight; }
.sight { position: relative; background: var(--surface); border-radius: var(--r); padding: 1.5rem 1.75rem 1.5rem 4.5rem; box-shadow: var(--sh-1); border: 1px solid var(--edge); counter-increment: sight; }
.sight::before { content: counter(sight); position: absolute; left: 1.5rem; top: 1.5rem; width: 2.25rem; height: 2.25rem; border-radius: 50%; display: grid; place-items: center; background: var(--gold-soft); color: var(--gold-deep); font: 600 1.2rem/1 var(--serif); }
.sight:nth-child(even)::before { background: var(--wine-soft); color: var(--wine); }
.sight h3 { font: 600 1rem/1.3 var(--sans); letter-spacing: 0; margin-bottom: .5rem; }
.sight p { margin: 0; color: var(--muted); font-size: .9375rem; }
.sight:last-child:nth-child(odd) { grid-column: 1 / -1; }

.g-near { background: linear-gradient(170deg, #241e19, #15110e); color: #fff; margin: 0 .5rem; border-radius: var(--r-lg); }
.g-near .g-h2 { color: #fff; }
.towns { list-style: none; margin: 0 auto 1.5rem; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: .75rem; max-width: 54rem; }
.towns li { display: flex; }
/* ogni città è un tasto: porta alla mappa e disegna la strada da Foligno */
.town { display: block; width: 100%; padding: 1.5rem 1rem 1.25rem; text-align: center; color: inherit; font: inherit; background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .12); border-radius: var(--r); cursor: pointer;
  transition: transform var(--t2) var(--ease), background-color var(--t2) var(--ease), border-color var(--t2) var(--ease); }
.town:hover { background: rgba(255, 255, 255, .1); border-color: rgba(233, 201, 135, .55); transform: translateY(-2px); }
.town:active { transform: translateY(0) scale(.98); }
.town:focus-visible { outline: 2px solid var(--gold-light); outline-offset: 3px; }
.town[aria-pressed="true"] { background: rgba(233, 201, 135, .14); border-color: var(--gold-light); }
.town-cta { display: inline-flex; align-items: center; gap: .375rem; margin-top: .75rem; font: 600 .75rem/1.2 var(--sans); letter-spacing: .06em; font-style: normal; color: var(--gold-light); opacity: .85; }
.town-cta::after { content: "\2191"; transition: transform var(--t2) var(--ease); }
.town:hover .town-cta::after { transform: translateY(-2px); }
.towns strong { font: 500 2.75rem/1.1 var(--serif); color: var(--gold-light); }
.towns small { font: 600 .8125rem var(--sans); margin-left: .25rem; color: var(--gold-light); }
.towns span { display: block; margin-top: .5rem; font: 600 .75rem var(--sans); letter-spacing: .16em; text-transform: uppercase; color: rgba(255, 255, 255, .9); }
.g-note, .g-train { text-align: center; max-width: 38rem; margin: 0 auto .5rem; }
.g-note { font-size: .875rem; color: rgba(255, 255, 255, .65); }
.g-train { color: rgba(255, 255, 255, .9); }

.parks { display: grid; gap: 1rem; max-width: 54rem; margin: 0 auto 1.5rem; }
.pk { display: flex; gap: 1.25rem; background: var(--surface); border-radius: var(--r); padding: 1.5rem; box-shadow: var(--sh-1); border: 1px solid var(--edge); }
.pk-best { border: 1px solid var(--gold); box-shadow: var(--sh-2); }
.pk-p { flex: none; width: 3rem; height: 3rem; border-radius: var(--r-sm); background: var(--ink); color: #fff; display: grid; place-items: center; font: 600 1.25rem var(--sans); }
.pk-best .pk-p { background: var(--gold); }
.pk-body { flex: 1; min-width: 0; }
.pk-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem 1rem; }
.pk h3 { font: 600 1.0625rem var(--sans); letter-spacing: 0; margin: 0; }
.pk p { margin: .25rem 0 0; color: var(--muted); font-size: .9375rem; }
.pk .pk-addr { margin: .25rem 0 .125rem; font-size: .875rem; }
.pk-addr a { color: var(--ink); font-weight: 600; text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: 3px; }
.pk-addr a:hover { text-decoration-color: var(--ink); }
.pk .pk-warn { margin-top: .75rem; padding: .75rem 1rem; border-radius: var(--r-sm); background: #fdf0f0; color: #9a1220; font-size: .9375rem; }
.ptags { display: flex; gap: .375rem; flex-wrap: wrap; }
.ptag { font: 600 .75rem var(--sans); letter-spacing: .08em; text-transform: uppercase; border-radius: .375rem; padding: .25rem .5rem; background: var(--sand); }
.ptag.best { background: var(--gold); color: #fff; }
.ptag.free { background: #e3f3e8; color: #17692f; }
.ptag.paid { background: var(--sand); color: var(--ink-2); }
.pk-min { list-style: none; margin: 1rem 0 0; padding: 1rem 0 0; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: .5rem 2rem; font-size: .875rem; }
.pk-min span { color: var(--muted); margin-right: .5rem; }
.g-pnote { text-align: center; }
.g-cta { text-align: center; margin-top: 2.25rem; }

/* =========================================================
   FOOTER
   ========================================================= */
.site-footer { background: #15110e; color: #cfc4b5; padding: 4.5rem 0 2rem; margin-top: .5rem; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { color: var(--gold-light); }
.foot-grid { display: grid; gap: 2.5rem; grid-template-columns: 1.6fr 1fr 1.3fr; }
.foot-brand { font: 500 2rem/1.2 var(--serif); color: #fff; margin: 0 0 .5rem; }
.foot-h { font: 600 .75rem var(--sans); letter-spacing: .18em; text-transform: uppercase; color: var(--gold-light); margin-bottom: 1rem; }
.site-footer .muted { color: #a39784; max-width: 22rem; }
.site-footer li { padding: .25rem 0; }
.foot-bottom { margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid rgba(255, 255, 255, .1); display: flex; flex-wrap: wrap; gap: .5rem 2rem; justify-content: space-between; font-size: .8125rem; color: #8f8473; }
.foot-bottom p { margin: 0; }

/* ---------- barra fissa telefono (fondo pieno, bordo visibile) ---------- */
.mbar { position: fixed; left: .5rem; right: .5rem; bottom: calc(.5rem + env(safe-area-inset-bottom)); z-index: 40; display: flex; gap: .5rem; padding: .375rem; border-radius: 999px; background: #fff; border: 1px solid var(--edge-2); box-shadow: var(--sh-2); }
.mbar a { flex: 1; display: flex; align-items: center; justify-content: center; gap: .5rem; min-height: 3rem; border-radius: 999px; font-weight: 600; font-size: .9375rem; text-decoration: none; color: #fff; transition: transform var(--t1); }
.mbar a:active { transform: scale(.97); }
.mbar-call { background: var(--ink); } .mbar-wa { background: var(--green); }
.mbar svg { width: 1.25rem; height: 1.25rem; }

/* ---------- comparsa allo scorrimento (solo con JS) ---------- */
.rv { opacity: 0; transform: translateY(14px); transition: opacity 500ms var(--ease), transform 600ms var(--ease); }

/* ---------- interazioni fluide: colori, bordi e ombre cambiano in dissolvenza ---------- */
.btn, .sp-btn, .q-contacts a, .g-pills a, .site-footer a, .link-arrow, .pk-addr a, .rarr, .sarr, .lb button, .leaflet-bar a, .burger, .mbar a, .nav .lang {
  transition: transform var(--t2) var(--ease), background-color var(--t2) var(--ease), color var(--t2) var(--ease), border-color var(--t2) var(--ease), box-shadow var(--t2) var(--ease), text-decoration-color var(--t2) var(--ease);
}
.field input, .field select, .field textarea { transition: border-color var(--t2) var(--ease), box-shadow var(--t2) var(--ease), background-color var(--t2) var(--ease); }
.apt-card { transition: transform var(--t3) var(--ease), box-shadow var(--t3) var(--ease), border-color var(--t3) var(--ease); }
.split-p img, .apt-img img, .slide img { transition: transform 600ms var(--ease); }
@media (hover: hover) {
  .btn:hover, .sp-btn:hover, .q-contacts a:hover { transform: translateY(-1px); }
  .split-p:hover img { transform: scale(1.03); }
}

/* ---------- passaggio tra le pagine: zoom verso la destinazione ----------
   La foto dell'appartamento cliccata (home o scheda "l'altro appartamento") si allarga fino a
   diventare la foto grande della pagina di arrivo; il resto della pagina zooma verso il punto
   toccato e sfuma. La barra in alto resta ferma. Browser senza supporto: cambio pagina normale. */
@view-transition { navigation: auto; }
.site-header { view-transition-name: site-header; }
body.menu-open .site-header { view-transition-name: none; }
.sp-carapace img, .theme-carapace .hero img, .c-carapace .apt-img img { view-transition-name: apt-carapace; }
.sp-volte img, .theme-volte .hero img, .c-volte .apt-img img { view-transition-name: apt-volte; }
::view-transition-group(*) { animation-duration: 450ms; animation-timing-function: cubic-bezier(.22, 1, .36, 1); }
::view-transition-old(apt-carapace), ::view-transition-new(apt-carapace),
::view-transition-old(apt-volte), ::view-transition-new(apt-volte) { width: 100%; height: 100%; object-fit: cover; overflow: hidden; }
::view-transition-image-pair(apt-carapace), ::view-transition-image-pair(apt-volte) { border-radius: var(--r-lg); overflow: hidden; }
::view-transition-old(root) { transform-origin: var(--vt-x, 50%) var(--vt-y, 50%); animation: vt-out 360ms cubic-bezier(.4, 0, .9, .4) both; }
::view-transition-new(root) { transform-origin: var(--vt-x, 50%) var(--vt-y, 50%); animation: vt-in 450ms cubic-bezier(.22, 1, .36, 1) 80ms both; }
@keyframes vt-out { to { opacity: 0; transform: scale(1.12); filter: blur(2px); } }
@keyframes vt-in { from { opacity: 0; transform: scale(.96); } }
.rv.in { opacity: 1; transform: none; }

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (min-width: 48rem) {
  .slide { flex-basis: 58%; }
  .rcard { flex-basis: 23rem; }
  .rrow { padding-inline: 0; margin-inline: 0; }
  body { padding-bottom: 0; }
  .mbar { display: none; }
}
@media (min-width: 80rem) { .slide { flex-basis: 44rem; aspect-ratio: 3 / 2; } }
@media (max-width: 62rem) {
  .why-grid { grid-template-columns: repeat(2, 1fr); }
  .panels { grid-template-columns: 1fr; }
}
@media (max-width: 47.99rem) {
  :root { --hh: 4.8rem; }
  body { font-size: 1rem; }
  .header-in { height: 3.6rem; }
  .split { grid-template-columns: 1fr; gap: .5rem; padding: .5rem; min-height: 0; }
  .split-p { min-height: 52svh; border-radius: var(--r); }
  .split-p:first-child { padding-top: 4rem; }
  .sp-in { padding: 0 var(--pad); gap: .5rem; }
  .sp-name { font-size: 2.625rem; }
  .db-wrap { position: static; padding: .5rem .5rem 0; }
  .split-title { color: var(--muted); text-shadow: none; }
  .datebar { width: 100%; flex-wrap: wrap; border-radius: var(--r); padding: 1rem; gap: .5rem; box-shadow: var(--sh-1); }
  .datebar label { border: 1px solid var(--line); border-radius: var(--r-sm); padding: .5rem .75rem; flex: 1 1 8rem; }
  .datebar input { width: 100%; font-size: 16px; }
  .datebar button { flex: 1 1 100%; margin: 0; }
  .hero { min-height: 78svh; margin: .5rem; border-radius: var(--r); }
  .g-hero { min-height: 56svh; }
  .apt-grid { grid-template-columns: 1fr; }
  .why-grid { grid-template-columns: 1fr; }
  .facts-bar { margin-top: -2.6rem; }
  .facts-row { grid-template-columns: repeat(2, 1fr); row-gap: 1rem; }
  .fact:nth-child(3) { border-left: 0; }
  .amen { grid-template-columns: 1fr; }
  .quote { grid-template-columns: 1fr 1fr; gap: .9rem; padding: 1.2rem; }
  .q-sec, .g-near { margin: 0 .5rem; border-radius: var(--r); }
  .q-contacts li, .q-contacts a { width: 100%; justify-content: center; }
  .foot-grid { grid-template-columns: 1fr; }
  .rhead { align-items: flex-start; }
  .rname { font-size: 1.7rem; }
  .field input, .field select, .field textarea { font-size: 16px; }
  .sights { grid-template-columns: 1fr; }
  .towns { grid-template-columns: repeat(2, 1fr); }
  .map-wide { aspect-ratio: 4 / 5; max-height: 32rem; }
  .map-legend { justify-content: flex-start; gap: .75rem 1.25rem; }
  .pk { padding: 1.1rem; gap: .9rem; } .pk-p { width: 2.5rem; height: 2.5rem; }
  .g-pills { top: 4.9rem; }
  .g-pills .container { justify-content: flex-start; }
}
@media (prefers-reduced-motion: reduce) {
  @view-transition { navigation: none; }
  html, .rrow, .strack { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
  .rv { opacity: 1; transform: none; }
}
