/* ==========================================================================
   Villaggio Isuledda v2 - stile editoriale
   Serif in maiuscolo, foto squadrate, blocchi piatti, linee sottili.
   Palette originale: verde acqua #6AC6C0 dominante, bianco, #38A29B e #1F8074.
   ========================================================================== */

:root {
	--teal: #6AC6C0;
	--teal-dark: #38A29B;
	--deep: #1F8074;
	--ink: #0E3532;
	--white: #FFFFFF;
	--paper: #F7F6F4;
	--line: rgba(14, 53, 50, 0.38);
	--line-light: rgba(255, 255, 255, 0.4);

	--font-serif: "Andada Pro", Georgia, serif;
	--font-body: "Open Sans", system-ui, sans-serif;

	--maxw: 1240px;
	--gutter: clamp(1.25rem, 4vw, 3rem);
	--header-h: 84px;
	--hero-gap: clamp(.6rem, 1.2vw, 1rem);
	--ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 1rem); height: auto; }
body.v2 {
	margin: 0;
	background: var(--teal);
	color: var(--ink);
	font-family: var(--font-serif);
	font-size: 1.1rem;
	line-height: 1.7;
	-webkit-font-smoothing: antialiased;
	overflow-x: hidden;
}
body.v2.prenota-lock, body.v2.menu-open { overflow: hidden; }
.v2 img { max-width: 100%; height: auto; display: block; }
:where(.v2 a) { color: inherit; text-decoration: none; }
.v2 p { margin: 0 0 1.1em; }
.v2 h1, .v2 h2, .v2 h3 { font-family: var(--font-serif); font-weight: 400; line-height: 1.1; margin: 0; text-wrap: balance; }
.v2 .wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }
.v2 :focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }

/* ---------- Bottoni (rettangolari, linea sottile) ---------- */
.btn {
	display: inline-flex; align-items: center; justify-content: center; gap: .7em;
	padding: 1em 2.2em; border: 1px solid currentColor; border-radius: 0;
	font: 400 .95rem/1 var(--font-serif); letter-spacing: .14em; text-transform: uppercase;
	background: transparent; color: var(--ink); cursor: pointer;
	transition: background-color .3s, color .3s, border-color .3s;
}
.btn:hover { background: var(--ink); color: var(--white); border-color: var(--ink); }
.btn--solid { background: var(--deep); color: var(--white); border-color: var(--deep); }
.btn--solid:hover { background: var(--ink); border-color: var(--ink); }
.btn--light { color: var(--white); }
.btn--light:hover { background: var(--white); color: var(--deep); border-color: var(--white); }
.btn .arrow { transition: transform .35s var(--ease); }
.btn:hover .arrow { transform: translateX(4px); }

/* ---------- Header: verde scuro, ben presente, link sempre visibili ---------- */
.site-header {
	position: fixed; z-index: 1000; top: calc(var(--hero-gap) + .9rem); left: 0; right: 0;
	padding: 0 calc(var(--hero-gap) + .9rem); color: var(--white); pointer-events: none;
	transition: top .35s var(--ease), padding .35s var(--ease);
}
.site-header.is-scrolled { top: .6rem; padding: 0 var(--hero-gap); }
.site-header__bar {
	pointer-events: auto; max-width: none; height: 64px; margin: 0 auto; padding: 0 .9rem 0 1.6rem;
	display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 2rem;
	border-radius: 999px; background: rgba(14, 53, 50, .5); border: 0;
	-webkit-backdrop-filter: blur(16px) saturate(1.4); backdrop-filter: blur(16px) saturate(1.4);
	box-shadow: 0 18px 40px -22px rgba(0, 0, 0, .55);
	transition: background-color .35s, height .35s var(--ease);
}
.site-header.is-scrolled .site-header__bar { background: rgba(14, 53, 50, .78); height: 56px; }
.site-header__logo img { height: 38px; width: auto; transition: height .35s var(--ease); }
.site-header.is-scrolled .site-header__logo img { height: 34px; }
.site-nav { display: flex; align-items: center; justify-content: center; gap: clamp(1rem, 2.6vw, 2.8rem); }
.site-nav a {
	position: relative; padding: .5em 0; font: 400 .92rem/1 var(--font-serif);
	letter-spacing: .16em; text-transform: uppercase; color: var(--white);
}
.site-nav a:not(.is-cta)::after {
	content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: var(--teal);
	transform: scaleX(0); transform-origin: right; transition: transform .45s var(--ease);
}
.site-nav a:not(.is-cta):hover::after { transform: scaleX(1); transform-origin: left; }
.site-header__side { display: flex; align-items: center; gap: 1.4rem; }
.site-header__cta {
	background: var(--teal); color: var(--ink); padding: .85em 1.7em; border-radius: 999px; font: 400 .92rem/1 var(--font-serif);
	letter-spacing: .16em; text-transform: uppercase; transition: background-color .3s, color .3s;
}
.site-header__cta:hover { background: var(--white); }
.lang-switch { display: flex; gap: .9rem; font: 400 .85rem/1 var(--font-serif); letter-spacing: .12em; }
.lang-switch a { opacity: .6; transition: opacity .2s; }
.lang-switch a.is-active, .lang-switch a:hover { opacity: 1; }
.lang-switch a.is-active { text-decoration: underline; text-underline-offset: .4em; }

.burger { display: none; width: 46px; height: 46px; background: transparent; border: 0; color: var(--white); cursor: pointer; align-items: center; justify-content: center; }
.burger span, .burger span::before, .burger span::after {
	display: block; width: 26px; height: 1px; background: currentColor; content: ""; position: relative; transition: transform .35s var(--ease), background-color .2s;
}
.burger span::before { position: absolute; top: -8px; }
.burger span::after { position: absolute; top: 8px; }
.burger.is-active span { background: transparent; }
.burger.is-active span::before { top: 0; transform: rotate(45deg); }
.burger.is-active span::after { top: 0; transform: rotate(-45deg); }

.mobile-menu {
	position: fixed; inset: 0; z-index: 990; background: var(--deep); color: var(--white);
	display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 1.6rem;
	opacity: 0; visibility: hidden; transition: opacity .45s ease, visibility .45s;
}
.mobile-menu.is-open { opacity: 1; visibility: visible; }
.mobile-menu img { width: 130px; margin-bottom: 1rem; }
.mobile-menu a.m-link { font: 400 1.9rem/1.2 var(--font-serif); letter-spacing: .08em; text-transform: uppercase; }
.mobile-menu a.m-link.is-cta { background: var(--teal); color: var(--ink); padding: .5em 1.5em; font-size: 1.3rem; }
.mobile-menu .lang-switch { margin-top: 1rem; gap: 1.4rem; font-size: 1rem; }

@media (max-width: 1060px) {
	.site-nav, .site-header__side { display: none; }
	.site-header__bar { grid-template-columns: 1fr auto; }
	.burger { display: inline-flex; }
	.site-header__bar { height: 56px; padding: 0 .5rem 0 1.2rem; }
}

/* ---------- Hero: foto grande e smussata, contenuto al centro, barra di prenotazione in basso ---------- */
.hero2 { padding: var(--hero-gap) 0 clamp(3rem, 6vw, 5rem); }
.v2 .hero2 > .wrap { max-width: none; padding: 0 var(--hero-gap); }
@media (min-width: 761px) { .v2 .hero2 > .wrap { width: 86%; padding: 0; } }
.hero2__media { width: 100%; position: relative; height: min(86svh, 880px); min-height: 560px; overflow: hidden; border-radius: clamp(22px, 3vw, 44px); background: var(--teal-dark); isolation: isolate; }
.hero2__shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(14,53,50,.35) 0%, rgba(14,53,50,.12) 40%, rgba(14,53,50,.55) 100%); }
.hero2__content { position: absolute; inset: 5rem 0 6.5rem; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 1.4rem; padding: 1.5rem var(--gutter); color: var(--white); }
.hero2__logo { margin: 0; line-height: 0; }
.hero2__logo-svg { display: block; width: min(300px, 46vw); height: auto; margin: 0 auto; filter: drop-shadow(0 6px 30px rgba(0,0,0,.35)); }
.hero2__tagline { font-size: clamp(1.05rem, 1.7vw, 1.35rem); line-height: 1.55; max-width: 42ch; margin: 0; text-wrap: balance; text-shadow: 0 2px 16px rgba(0,0,0,.45); }
.hero2__actions { display: flex; gap: .9rem; flex-wrap: wrap; justify-content: center; margin-top: .4rem; }
.btn--teal { background: var(--teal); color: var(--ink); border-color: var(--teal); }
.btn--teal:hover { background: var(--white); color: var(--deep); border-color: var(--white); }
.screen-reader-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.booking { position: absolute; left: clamp(.8rem, 2vw, 1.5rem); right: clamp(.8rem, 2vw, 1.5rem); bottom: clamp(.8rem, 2vw, 1.5rem); z-index: 2; display: grid; grid-template-columns: 1fr 1fr 1fr; border: 1px solid var(--line-light); border-radius: 999px; overflow: hidden; background: rgba(14, 53, 50, .28); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.booking button {
	appearance: none; background: transparent; border: 0; color: var(--white); cursor: pointer;
	padding: 1.05em 1em; font: 400 1.05rem/1 var(--font-serif); display: flex; align-items: center; justify-content: center; gap: .6em;
	transition: background-color .3s, color .3s;
}
.booking button + button { border-left: 1px solid var(--line-light); }
.booking button:hover { background: var(--white); color: var(--deep); }
.booking button:last-child { background: var(--deep); color: var(--white); text-transform: uppercase; letter-spacing: .14em; font-size: .95rem; }
.booking button:last-child:hover { background: var(--ink); color: var(--white); }
.icon { width: 1em; height: 1em; flex: none; }
.booking .icon { width: 1.1em; height: 1.1em; }
.btn .arrow { display: inline-flex; }
.btn .arrow .icon { width: 1.15em; height: 1.15em; }
@media (max-width: 640px) {
	.hero2__media { min-height: 600px; }
	.hero2__content { inset: 6.4rem 0 9rem; gap: 1.1rem; }
	.hero2__logo-svg { width: min(200px, 52vw); }
	.booking { grid-template-columns: 1fr 1fr; border-radius: 28px; }
	.booking button:last-child { grid-column: 1 / -1; border-left: 0; border-top: 1px solid var(--line-light); }
}

.hero__slide { position: absolute; inset: 0; background-size: cover; background-position: center; opacity: 0; transform: scale(1.06); transition: opacity 1.6s ease; }
.hero__slide.is-active { opacity: 1; animation: kenburns 9s ease-out forwards; }
@keyframes kenburns { from { transform: scale(1.08); } to { transform: scale(1); } }
.hero__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 1.6s ease; pointer-events: none; }
.hero__video.is-playing { opacity: 1; }
.hero__dots { position: absolute; right: 1.4rem; top: 1.4rem; z-index: 2; display: flex; gap: .5rem; }
.hero__dot { width: 34px; height: 3px; background: rgba(255,255,255,.45); border: 0; padding: 0; cursor: pointer; overflow: hidden; position: relative; }
.hero__dot::after { content: ""; position: absolute; inset: 0; background: var(--white); transform: scaleX(0); transform-origin: left; }
.hero__dot.is-active::after { animation: dotfill 7s linear forwards; }
@keyframes dotfill { to { transform: scaleX(1); } }


/* ---------- Sezioni ---------- */
.section { padding: clamp(3rem, 6vw, 5rem) 0; position: relative; }
.section--white { background: var(--paper); color: var(--deep); }
.section--teal { background: var(--teal); color: var(--ink); }
.emblem { display: block; width: 92px; height: 92px; margin: 0 auto 1.8rem; }
.emblem svg { width: 100%; height: 100%; }
.emblem .icon { width: 100%; height: 100%; stroke-width: .5; }
.rule-title { text-align: center; font-size: clamp(2.2rem, 5.2vw, 4.2rem); text-transform: uppercase; letter-spacing: .04em; padding: .22em 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section--white .rule-title { border-color: rgba(31, 128, 116, .4); }
.on-dark .rule-title { border-color: var(--line-light); }
.lead { text-align: center; font-size: clamp(1.3rem, 2.4vw, 1.85rem); line-height: 1.5; max-width: 58rem; margin: 2.2rem auto 0; }
.cols { columns: 1; column-gap: 3rem; margin-top: clamp(2rem, 4vw, 3rem); }
@media (min-width: 760px) { .cols { columns: 2; } }
.cols p { break-inside: avoid-column; }

/* Foto squadrate */
.mosaic { display: grid; gap: 1rem; margin-top: clamp(2.5rem, 5vw, 4rem); grid-template-columns: 1fr; }
@media (min-width: 760px) { .mosaic { grid-template-columns: 1.7fr 1fr; grid-template-rows: 1fr 1fr; } .mosaic a:first-child { grid-row: 1 / 3; } }
.mosaic a { position: relative; display: block; overflow: hidden; background: var(--teal); min-height: 260px; }
.mosaic img { width: 100%; height: 100%; object-fit: cover; position: absolute; inset: 0; transition: transform 1.2s var(--ease); }
.mosaic a:hover img { transform: scale(1.05); }
.zoom { position: absolute; right: 1rem; bottom: 1rem; width: 42px; height: 42px; background: var(--white); color: var(--deep); display: grid; place-items: center; opacity: 0; transition: opacity .35s; }
.zoom .icon { width: 20px; height: 20px; }
.mosaic a:hover .zoom { opacity: 1; }

.band { width: 100%; aspect-ratio: 16 / 9; max-height: 78vh; min-height: 260px; border-radius: clamp(24px, 3.6vw, 48px); background-size: cover; background-position: center; margin-top: clamp(2.5rem, 5vw, 4rem); }

/* Villini: blocco scuro piatto con selettore */
.on-dark { background: var(--deep); color: var(--white); }
.rooms-tabs { display: flex; justify-content: center; gap: clamp(1.4rem, 5vw, 4rem); margin-top: clamp(2.5rem, 5vw, 4rem); border-bottom: 1px solid var(--line-light); }
.rooms-tab { background: none; border: 0; color: rgba(255,255,255,.65); font: 400 clamp(1.1rem, 2.4vw, 1.7rem)/1 var(--font-serif); padding: 0 0 1.1rem; cursor: pointer; position: relative; transition: color .3s; }
.rooms-tab::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: var(--teal); transform: scaleX(0); transition: transform .4s var(--ease); }
.rooms-tab:hover, .rooms-tab.is-active { color: var(--white); }
.rooms-tab.is-active::after { transform: scaleX(1); }
.rooms-panel { display: none; grid-template-columns: 1fr; gap: clamp(1.5rem, 4vw, 3.5rem); align-items: center; margin-top: clamp(2rem, 4vw, 3.5rem); }
.rooms-panel.is-active { display: grid; animation: fadein .7s var(--ease); }
@keyframes fadein { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@media (min-width: 860px) { .rooms-panel { grid-template-columns: 1.25fr 1fr; } }
.rooms-panel__img { width: 100%; aspect-ratio: 4 / 3; overflow: hidden; background: var(--teal-dark); }
.rooms-panel__img img { width: 100%; height: 100%; object-fit: cover; }
.rooms-panel h3 { font-size: clamp(2.2rem, 4.6vw, 3.6rem); text-transform: uppercase; letter-spacing: .04em; }
.rooms-panel .price { margin: 1.1rem 0 1.4rem; padding: .8rem 0; border-top: 1px solid var(--line-light); border-bottom: 1px solid var(--line-light); display: flex; align-items: baseline; gap: .9rem; }
.rooms-panel .price small { font: 400 .85rem/1 var(--font-serif); letter-spacing: .16em; text-transform: uppercase; opacity: .85; }
.rooms-panel .price strong { font: 400 2rem/1 var(--font-serif); color: var(--teal); }

/* San Teodoro */
.trio { display: grid; gap: 1rem; margin-top: clamp(2.5rem, 5vw, 4rem); grid-template-columns: 1fr; }
@media (min-width: 760px) { .trio { grid-template-columns: repeat(3, 1fr); } }
.trio > * { width: 100%; aspect-ratio: 4 / 5; overflow: hidden; background: var(--teal-dark); min-height: 280px; }
.trio img, .trio iframe { width: 100%; height: 100%; object-fit: cover; border: 0; display: block; }

/* ---------- Footer ---------- */
.site-footer { background: var(--deep); color: var(--white); padding: clamp(3.5rem, 7vw, 6rem) 0 2rem; font-family: var(--font-serif); line-height: 1.7; }
.site-footer__grid { display: grid; gap: 2.5rem; grid-template-columns: 1fr; align-items: start; }
@media (min-width: 860px) { .site-footer__grid { grid-template-columns: 1.1fr 1fr 1.3fr; gap: 4rem; } }
.site-footer img { width: 170px; }
.site-footer h4 { font: 400 .85rem/1 var(--font-serif); letter-spacing: .24em; text-transform: uppercase; margin: 0 0 1.1rem; padding-top: 1rem; border-top: 1px solid var(--line-light); color: var(--teal); }
.site-footer p { margin: 0 0 .6rem; }
.site-footer a { text-decoration: underline; text-decoration-color: rgba(255,255,255,.35); text-underline-offset: .25em; transition: text-decoration-color .25s, color .25s; }
.site-footer a:hover { color: var(--teal); text-decoration-color: var(--teal); }
.site-footer__legal { margin-top: 3rem; font-size: .85rem; opacity: .75; line-height: 1.6; }

.float { position: fixed; right: 1.4rem; bottom: 1.4rem; width: 56px; height: 56px; z-index: 900; transition: transform .35s var(--ease); }
.float:hover { transform: scale(1.08); }
.float img { width: 100%; height: 100%; }

/* Header, menu, footer: stessi caratteri anche nelle pagine interne */
.site-header, .mobile-menu, .site-footer, .float, .btn { font-family: var(--font-serif); }

/* ---------- Animazioni di comparsa ---------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .9s var(--ease), transform .9s var(--ease); transition-delay: var(--d, 0s); }
.reveal.is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	.reveal { opacity: 1; transform: none; transition: none; }
	.hero__slide.is-active, .hero__dot.is-active::after { animation: none; }
	.hero__dot.is-active::after { transform: scaleX(1); }
	*, *::before, *::after { transition-duration: .01ms !important; }
}

/* Menu in vetro più stretto: pillola compatta centrata (solo desktop) */
@media (min-width: 1061px) {
	.site-header__bar {
		width: min(1120px, 94%); max-width: 100%; height: 72px; padding: 0 1.5rem 0 3rem;
		grid-template-columns: auto 1fr auto; gap: clamp(1.6rem, 3vw, 3rem);
	}
	.site-header.is-scrolled .site-header__bar { height: 62px; }
	.site-nav { gap: clamp(1rem, 1.8vw, 1.8rem); }
	.site-header__logo img { height: 40px; }
	.site-header.is-scrolled .site-header__logo img { height: 34px; }
}


/* Titoli grandi piu' leggeri: Andada Pro parte da 400, qui serve un serif con peso 300 */
.v2 .rule-title, .v2 .rooms-panel h3 {
	font-family: "Fraunces", var(--font-serif);
	font-weight: 300;
	font-optical-sizing: auto;
	letter-spacing: .05em;
}


/* San Teodoro: mosaico a incastro (foto alta, panorama, foto + mappa) */
.sanmosaic { display: grid; gap: 1rem; margin-top: clamp(2.5rem, 5vw, 4rem); grid-template-columns: 1fr; }
.sanmosaic > div { position: relative; overflow: hidden; background: var(--teal-dark); min-height: 280px; }
.sanmosaic img, .sanmosaic iframe { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border: 0; display: block; }
.sanmosaic .sm-b { background-size: cover; background-position: center; min-height: 320px; }
@media (min-width: 900px) {
	.sanmosaic { grid-template-columns: repeat(12, 1fr); grid-template-rows: clamp(300px, 27vw, 420px) clamp(260px, 23vw, 360px); }
	.sanmosaic > div { min-height: 0; }
	.sanmosaic .sm-a { grid-column: 1 / 6; grid-row: 1 / 3; }
	.sanmosaic .sm-b { grid-column: 6 / 13; grid-row: 1; }
	.sanmosaic .sm-c { grid-column: 6 / 9; grid-row: 2; }
	.sanmosaic .sm-d { grid-column: 9 / 13; grid-row: 2; }
}

/* Gioco di smussi: solo nel mosaico di San Teodoro (angoli grandi alternati a piccoli) */
.sanmosaic > div { border-radius: 20px; }
@media (min-width: 900px) {
	.sanmosaic .sm-a { border-radius: 56px 12px 12px 56px; }
	.sanmosaic .sm-b { border-radius: 12px 56px 12px 12px; }
	.sanmosaic .sm-c { border-radius: 12px; }
	.sanmosaic .sm-d { border-radius: 12px 12px 56px 12px; }
}


/* ==========================================================================
   Rifinitura eleganza: tipografia, ritmo, comparsa delle foto, dettagli
   ========================================================================== */

/* Testo: piu' arioso e ben spezzato */
body.v2 { font-size: 1.05rem; line-height: 1.85; text-wrap: pretty; }
.v2 p { text-wrap: pretty; }

/* Frasi di apertura nello stesso carattere leggero dei titoli */
.v2 .lead { font-family: "Fraunces", var(--font-serif); font-weight: 300; font-optical-sizing: auto; }
.v2 .lead { line-height: 1.55; letter-spacing: .005em; }
.v2 .hero2__tagline { font-size: clamp(1.1rem, 1.8vw, 1.4rem); letter-spacing: .01em; text-shadow: 0 2px 18px rgba(0,0,0,.55); }

/* Titoli e ritmo delle sezioni */
.v2 .rule-title { letter-spacing: .08em; padding: .28em 0; }
.section { padding: clamp(3rem, 6vw, 5rem) 0; }
.emblem { opacity: .9; }

/* Bottoni e testi di servizio: piu' spazio tra le lettere */
.btn { letter-spacing: .2em; padding: 1.05em 2.4em; }
.site-nav a, .site-header__cta { letter-spacing: .2em; }
.rooms-tab { letter-spacing: .06em; }
.rooms-panel .price strong { font-family: "Fraunces", var(--font-serif); font-weight: 500; font-size: 2.3rem; }
.rooms-panel .price small { letter-spacing: .22em; }

/* Foto: si "aprono" con una maschera quando compaiono */
.band.reveal, .sanmosaic.reveal, .mosaic.reveal {
	opacity: 1; transform: none;
	clip-path: inset(7% 4% 7% 4%);
	transition: clip-path 1.6s var(--ease);
}
.band.reveal.is-in, .sanmosaic.reveal.is-in, .mosaic.reveal.is-in { clip-path: inset(0 0 0 0); }

/* Hover lento sulle foto del mosaico di San Teodoro */
.sanmosaic img, .sanmosaic .sm-b { transition: transform 1.4s var(--ease); }
.sanmosaic > div:hover img { transform: scale(1.05); }

/* Dettagli: barra di scorrimento e selezione */
html { scrollbar-width: thin; scrollbar-color: var(--deep) var(--teal); }
::selection { background: var(--deep); color: var(--white); }

/* Footer: logo piu' sobrio e testi meno compressi */
.site-footer img { width: clamp(200px, 20vw, 280px); opacity: 1; }
.site-footer h4 { letter-spacing: .3em; }

@media (prefers-reduced-motion: reduce) {
	.band.reveal, .sanmosaic.reveal, .mosaic.reveal { clip-path: none; transition: none; }
}


/* Sipario: hero e sezioni restano ancorati e quella successiva scorre sopra */
.v2 { --sec-rad: clamp(28px, 4vw, 52px); }
.v2 .hero2 { position: sticky; top: 0; z-index: 0; padding-bottom: clamp(2rem, 4vw, 3.5rem); }
.v2 main > section:not(.hero2) {
	position: sticky; top: 0; z-index: 1;
	border-radius: var(--sec-rad) var(--sec-rad) 0 0;
	box-shadow: 0 -30px 60px -40px rgba(14, 53, 50, .55);
}
/* Le sezioni dopo la prima si sovrappongono un po' alla precedente, cosi' negli angoli arrotondati si vede lei */
.v2 main > section:not(.hero2):not(#villaggio) { margin-top: calc(var(--sec-rad) * -1); padding-top: calc(clamp(5rem, 11vw, 9rem) + var(--sec-rad)); }
@media (prefers-reduced-motion: reduce) { .v2 main > section, .v2 .hero2 { position: relative; } }


/* ==========================================================================
   Sequenza di apertura: il logo si disegna, poi compaiono video, testi ed elementi
   ========================================================================== */
.hero2__logo-svg path { fill: #fff; }
/* Il resto compare in dissolvenza poco dopo l'apertura, uno dopo l'altro */
.hero2__tagline, .hero2__actions, .booking, .site-header__bar {
	transition: opacity .9s ease, transform .9s var(--ease), background-color .35s, height .35s var(--ease);
}
.js-intro:not(.intro-done) .hero2__tagline,
.js-intro:not(.intro-done) .hero2__actions,
.js-intro:not(.intro-done) .booking { opacity: 0; transform: translateY(16px); }
.js-intro:not(.intro-done) .site-header__bar { opacity: 0; transform: translateY(-14px); }
.intro-done .hero2__actions { transition-delay: .15s; }
.intro-done .booking { transition-delay: .3s; }
.intro-done .site-header__bar { transition-delay: .45s; }
.hero__slide.is-active, .hero__video { transition-delay: 0s; }

.intro-finished .hero2__actions, .intro-finished .booking, .intro-finished .site-header__bar { transition-delay: 0s; }


/* Velo Tiffany sopra video e foto dell'hero: scurisce e tinge di verde acqua per far leggere i testi */
.hero2__shade::after {
	content: ""; position: absolute; inset: 0;
	background: #3FB0A7; mix-blend-mode: multiply; opacity: .12;
}
.hero2__tagline { text-shadow: 0 2px 22px rgba(8, 40, 36, .55); }
.hero2__logo-svg { filter: drop-shadow(0 6px 26px rgba(8, 40, 36, .45)); }


/* Apertura: il logo compare in dissolvenza (poi arrivano gli altri elementi) */
.js-intro .hero2__logo-svg { opacity: 0; transition: opacity 1.2s ease; }
.js-intro.intro-run .hero2__logo-svg { opacity: 1; }

/* San Teodoro: testo centrato, a una colonna */
#san-teodoro .cols {
	columns: 1; max-width: 52rem; margin-left: auto; margin-right: auto;
	text-align: center; font-size: 1.12rem; line-height: 1.85;
}


/* ==========================================================================
   Pagine interne: hero con titolo, sezioni, schede, modulo
   ========================================================================== */
.hero2--page .hero2__media { height: min(62svh, 620px); min-height: 380px; }
.hero2--page .hero2__content { inset: 0; padding-top: 4.5rem; }
.v2 .page-title {
	font-family: "Fraunces", var(--font-serif); font-weight: 300; font-optical-sizing: auto;
	font-size: clamp(2.4rem, 6.4vw, 5.4rem); text-transform: uppercase; letter-spacing: .08em; line-height: 1.05;
	color: #fff; text-shadow: 0 4px 30px rgba(8, 40, 36, .5);
}
.hero2__down {
	position: absolute; left: 50%; bottom: 1.4rem; transform: translateX(-50%); z-index: 2;
	width: 46px; height: 46px; display: grid; place-items: center; color: #fff;
	background: rgba(14, 53, 50, .35); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); border-radius: 50%;
	transition: background-color .3s, transform .35s var(--ease);
}
.hero2__down:hover { background: rgba(14, 53, 50, .6); transform: translate(-50%, 4px); }
.hero2__down .icon { width: 22px; height: 22px; }
@media (max-width: 640px) { .hero2--page .hero2__media { height: 52svh; min-height: 320px; } }


/* Contatti: modulo e mappa */
.contact-grid { display: grid; gap: clamp(2rem, 5vw, 4rem); grid-template-columns: 1fr; margin-top: 1rem; }
@media (min-width: 900px) { .contact-grid { grid-template-columns: 1fr 1fr; align-items: stretch; } }
.contact-map { position: relative; min-height: 380px; border-radius: var(--sec-rad, 40px); overflow: hidden; background: var(--teal); }
.contact-map iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; }

/* Modulo di contatto (Contact Form 7) nello stile della finestra di prenotazione */
.v2 .wpcf7 form p { margin: 0 0 1.2rem; }
.v2 .wpcf7 label { display: block; font: 400 .72rem/1 var(--font-serif); letter-spacing: .2em; text-transform: uppercase; color: var(--deep); }
.v2 .wpcf7 .wpcf7-form-control-wrap { display: block; margin-top: .6rem; }
.v2 .wpcf7 input[type="text"], .v2 .wpcf7 input[type="email"], .v2 .wpcf7 input[type="tel"], .v2 .wpcf7 input[type="url"], .v2 .wpcf7 input[type="number"], .v2 .wpcf7 select {
	width: 100%; height: 48px; padding: 0 1.3rem; border: 1px solid rgba(31, 128, 116, .4); border-radius: 999px; background: #fff;
	font: 400 1rem/1 var(--font-serif); color: var(--ink); box-shadow: none; transition: border-color .25s;
}
.v2 .wpcf7 textarea {
	width: 100%; min-height: 150px; padding: 1rem 1.3rem; border: 1px solid rgba(31, 128, 116, .4); border-radius: 24px; background: #fff;
	font: 400 1rem/1.6 var(--font-serif); color: var(--ink); box-shadow: none; resize: vertical; transition: border-color .25s;
}
.v2 .wpcf7 input:hover, .v2 .wpcf7 textarea:hover, .v2 .wpcf7 input:focus, .v2 .wpcf7 textarea:focus, .v2 .wpcf7 select:focus { border-color: var(--deep); outline: none; }
.v2 .wpcf7 input[type="submit"], .v2 .wpcf7 button[type="submit"] {
	height: 50px; padding: 0 2.4em; border: 0; border-radius: 999px; background: var(--deep); color: #fff; cursor: pointer;
	font: 400 .85rem/1 var(--font-serif); letter-spacing: .2em; text-transform: uppercase; transition: background-color .25s, transform .35s var(--ease);
}
.v2 .wpcf7 input[type="submit"]:hover { background: var(--ink); transform: translateY(-2px); }
.v2 .wpcf7 .wpcf7-not-valid-tip { font-size: .85rem; color: #b3261e; margin: .4rem 0 0 1.2rem; }
.v2 .wpcf7 form .wpcf7-response-output { margin: 1rem 0 0; padding: .9rem 1.3rem; border: 1px solid var(--deep); border-radius: 24px; font-size: .95rem; }
.v2 .wpcf7-acceptance label, .v2 .wpcf7 .wpcf7-list-item-label { text-transform: none; letter-spacing: 0; font-size: .95rem; }


/* Pagina Ville: gruppi e schede dei villini */
.vgrid { display: grid; gap: clamp(1.2rem, 2.4vw, 2rem); grid-template-columns: 1fr; margin-top: clamp(2.5rem, 5vw, 4rem); }
@media (min-width: 680px) { .vgrid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1040px) { .vgrid { grid-template-columns: repeat(3, 1fr); } }
.vcard { display: flex; flex-direction: column; background: #fff; transition: transform .5s var(--ease), box-shadow .5s; }
.section--white .vcard { background: #fff; }
.vcard:hover { transform: translateY(-8px); box-shadow: 0 34px 50px -34px rgba(14, 53, 50, .55); }
.vcard__img { position: relative; display: block; aspect-ratio: 4 / 3; overflow: hidden; background: var(--teal-dark); }
.vcard__img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease); }
.vcard:hover .vcard__img img { transform: scale(1.06); }
.vcard__price { position: absolute; left: 1rem; top: 1rem; background: #fff; color: var(--deep); padding: .5rem .9rem; text-align: center; line-height: 1.15; }
.vcard__price small { display: block; font: 400 .66rem/1.2 var(--font-serif); letter-spacing: .16em; text-transform: uppercase; color: var(--teal-dark); }
.vcard__price strong { font: 500 1.3rem/1.2 "Fraunces", var(--font-serif); }
.vcard__body { display: flex; flex-direction: column; gap: .8rem; padding: 1.6rem 1.6rem 1.8rem; flex: 1; color: var(--ink); }
.vcard__type { font: 400 .72rem/1 var(--font-serif); letter-spacing: .22em; text-transform: uppercase; color: var(--deep); }
.vcard__body h3 { font: 300 1.7rem/1.15 "Fraunces", var(--font-serif); letter-spacing: .03em; color: var(--deep); }
.vcard__body p { margin: 0; flex: 1; font-size: 1rem; line-height: 1.7;
	display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.vcard__body .btn { align-self: flex-start; margin-top: .6rem; padding: .9em 1.8em; }


/* Dettaglio villino */
.page-tags { display: flex; gap: .7rem; flex-wrap: wrap; justify-content: center; margin-top: 1.1rem; }
.page-tags span { padding: .55em 1.3em; border-radius: 999px; background: rgba(255, 255, 255, .18); color: #fff; font: 400 .78rem/1 var(--font-serif); letter-spacing: .2em; text-transform: uppercase; -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }

.sub-title { font: 300 clamp(1.4rem, 2.4vw, 1.9rem)/1.2 "Fraunces", var(--font-serif); letter-spacing: .08em; text-transform: uppercase; color: var(--deep); padding-bottom: .55em; margin: 0 0 1.4rem; border-bottom: 1px solid rgba(31, 128, 116, .35); }
.villa-layout { display: grid; gap: clamp(2rem, 5vw, 4.5rem); grid-template-columns: 1fr; }
@media (min-width: 1000px) { .villa-layout { grid-template-columns: minmax(0, 1.55fr) minmax(300px, 1fr); align-items: start; } .villa-side { position: sticky; top: 6.5rem; } }
.villa-main .sub-title:not(:first-child) { margin-top: clamp(2.5rem, 5vw, 4rem); }
.villa-text { color: var(--ink); }
.villa-text p:last-child { margin-bottom: 0; }
.villa-calendar { overflow-x: auto; }

.spec { background: #fff; padding: 1.6rem 1.8rem 1.2rem; margin-bottom: 1.2rem; }
.spec .sub-title { font-size: 1.3rem; margin-bottom: .6rem; }
.spec ul { list-style: none; margin: 0; padding: 0; }
.spec li { display: flex; justify-content: space-between; gap: 1rem; padding: .7rem 0; border-bottom: 1px solid rgba(31, 128, 116, .18); font-size: 1rem; color: var(--ink); }
.spec li:last-child { border-bottom: 0; }
.spec li span { opacity: .85; }
.spec li strong { font: 500 1.05rem/1.4 "Fraunces", var(--font-serif); color: var(--deep); white-space: nowrap; }
.spec-note { font-size: .92rem; line-height: 1.7; color: var(--ink); opacity: .85; margin: 0 0 1.4rem; }
.villa-cta { width: 100%; }

.gal { display: grid; gap: 1rem; margin-top: clamp(2.5rem, 5vw, 4rem); grid-template-columns: repeat(2, 1fr); }
@media (min-width: 900px) { .gal { grid-template-columns: repeat(3, 1fr); } }
.gal a { position: relative; display: block; aspect-ratio: 4 / 3; overflow: hidden; background: var(--teal-dark); }
.gal a:first-child { grid-column: 1 / -1; aspect-ratio: 16 / 8; }
.gal img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease); }
.gal a:hover img { transform: scale(1.05); }
.gal a:hover .zoom { opacity: 1; }

/* Calendario e modulo di richiesta (WP Booking System) nello stile del tema */
html body.v2 .wpbs-container, html body.v2 .wpbs-container * { font-family: var(--font-serif) !important; }
html body.v2 .wpbs-container .wpbs-heading { font-weight: 400 !important; letter-spacing: .12em; text-transform: uppercase; color: var(--deep) !important; }
html body.v2 .wpbs-container .wpbs-date-number, html body.v2 .wpbs-container .wpbs-legend-item-name { color: var(--ink); }
html body.v2 .wpbs-container .wpbs-legend-item-name { font-size: .78rem; letter-spacing: .06em; }
html body.v2 .wpbs-form-container { margin-top: 2rem; }
html body.v2 .wpbs-form-field { margin-bottom: 1.2rem; }
html body.v2 .wpbs-form-field-label { display: block; font: 400 .72rem/1 var(--font-serif) !important; letter-spacing: .2em; text-transform: uppercase; color: var(--deep) !important; margin: 0 0 .6rem 1rem; }
html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-fields .wpbs-form-field .wpbs-form-field-input input[type="text"], html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-fields .wpbs-form-field .wpbs-form-field-input input[type="email"], html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-fields .wpbs-form-field .wpbs-form-field-input input[type="tel"], html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-fields .wpbs-form-field .wpbs-form-field-input input[type="number"], html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-fields .wpbs-form-field .wpbs-form-field-input select {
	width: 100%; height: 48px; padding: 0 1.3rem; border: 1px solid rgba(31, 128, 116, .4) !important; border-radius: 999px !important; background: #fff !important;
	font: 400 1rem/1 var(--font-serif) !important; color: var(--ink); box-shadow: none !important; transition: border-color .25s;
}
html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-fields .wpbs-form-field .wpbs-form-field-input textarea {
	width: 100%; min-height: 130px; padding: 1rem 1.3rem; border: 1px solid rgba(31, 128, 116, .4) !important; border-radius: 24px !important; background: #fff !important;
	font: 400 1rem/1.6 var(--font-serif) !important; color: var(--ink); box-shadow: none !important; resize: vertical; transition: border-color .25s;
}
html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-fields .wpbs-form-field .wpbs-form-field-input input:hover, html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-fields .wpbs-form-field .wpbs-form-field-input input:focus, html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-fields .wpbs-form-field .wpbs-form-field-input textarea:hover, html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-fields .wpbs-form-field .wpbs-form-field-input textarea:focus { border-color: var(--deep) !important; outline: none; }
html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-fields .wpbs-form-field.wpbs-form-submit-button button, html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-fields .wpbs-form-field.wpbs-form-submit-button button[type="submit"] {
	height: 50px; padding: 0 2.4em; border: 0 !important; border-radius: 999px !important; background: var(--deep) !important; color: #fff !important; cursor: pointer;
	font: 400 .85rem/1 var(--font-serif) !important; letter-spacing: .2em; text-transform: uppercase; box-shadow: none !important; transition: background-color .25s, transform .35s var(--ease);
}
html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-fields .wpbs-form-field.wpbs-form-submit-button button:hover { background: var(--ink) !important; transform: translateY(-2px); }

/* Modulo richiesta villino: altezza campi e pulsante (specificita' alta per battere il plugin) */
html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-field .wpbs-form-field-input input[type="text"],
html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-field .wpbs-form-field-input input[type="email"],
html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-field .wpbs-form-field-input input[type="tel"] { height: 48px !important; }
html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-submit-button button,
html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-submit-button button[type="submit"] {
	height: 50px !important; padding: 0 2.4em !important; border: 0 !important; border-radius: 999px !important;
	background: var(--deep) !important; color: #fff !important; cursor: pointer; box-shadow: none !important;
	font: 400 .85rem/1 var(--font-serif) !important; letter-spacing: .2em; text-transform: uppercase;
	transition: background-color .25s, transform .35s var(--ease);
}
html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-submit-button button:hover { background: var(--ink) !important; transform: translateY(-2px); }

/* Consenso privacy del modulo contatti */
.v2 .wpcf7-acceptance, .v2 .wpcf7-acceptance .wpcf7-list-item { display: block; margin: 0; }
.v2 .wpcf7-acceptance label { display: flex; align-items: flex-start; gap: .8rem; line-height: 1.6; }
.v2 .wpcf7-acceptance input[type="checkbox"] { width: 18px; height: 18px; margin-top: .25rem; flex: none; accent-color: var(--deep); }
.v2 .wpcf7-acceptance .wpcf7-list-item-label { font-size: .88rem; line-height: 1.6; }

/* La prima sezione dopo l'hero non si sovrappone: resta il margine sotto la foto, come in home */
.v2 main > .hero2 + section { margin-top: 0 !important; padding-top: clamp(3rem, 6vw, 4.5rem) !important; }

/* Modulo richiesta: campi larghi quanto la colonna del calendario */
html body.v2 .wpbs-main-wrapper .wpbs-form-container,
html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-fields,
html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-field { width: 100% !important; max-width: none !important; }
html body.v2 .wpbs-main-wrapper .wpbs-form-container .wpbs-form-field .wpbs-form-field-input { width: 100% !important; }

/* Barra di prenotazione piu' compatta e centrata nell'hero */
.hero2 .booking { left: 0; right: 0; margin-left: auto; margin-right: auto; width: min(780px, calc(100% - 2rem)); }
.hero2 .booking button { padding: .95em .8em; font-size: 1rem; }
.hero2 .booking button:last-child { font-size: .85rem; letter-spacing: .12em; }
@media (max-width: 640px) { .hero2 .booking { width: calc(100% - 1.6rem); } }

/* Galleria del villino: meno spazio sopra e sotto */
html body.v2 main > #galleria { padding-top: calc(var(--sec-rad) + 1.5rem) !important; padding-bottom: clamp(3rem, 6vw, 4.5rem) !important; }
html body.v2 #galleria .emblem { margin-bottom: 1.2rem; }
#galleria .gal { margin-top: clamp(1.8rem, 3vw, 2.5rem); }


/* Testo introduttivo delle pagine interne: dimensione di lettura, centrato */
.v2 .intro-text { max-width: 52rem; margin: 1.6rem auto 0; text-align: center; font-size: 1.12rem; line-height: 1.85; color: var(--ink); }
.v2 .intro-text p:last-child { margin-bottom: 0; }


/* Meno spazio tra le sezioni, ovunque */
.v2 main > section:not(.hero2):not(#villaggio) { padding-top: calc(clamp(2.2rem, 4.5vw, 3.5rem) + var(--sec-rad)); }
.v2 main > #villaggio { padding-top: clamp(3rem, 6vw, 4.5rem); }
.emblem { margin-bottom: 1.1rem; }

/* Ville: schede centrate (anche con 1 o 2 per gruppo) e testo introduttivo a due colonne come in home */
.vgrid { --g: clamp(1.2rem, 2.4vw, 2rem); display: flex; flex-wrap: wrap; justify-content: center; gap: var(--g); }
.vgrid .vcard { flex: 0 0 100%; max-width: 100%; }
@media (min-width: 680px) { .vgrid .vcard { flex-basis: calc((100% - var(--g)) / 2); max-width: calc((100% - var(--g)) / 2); } }
@media (min-width: 1040px) { .vgrid .vcard { flex-basis: calc((100% - 2 * var(--g)) / 3); max-width: calc((100% - 2 * var(--g)) / 3); } }

.v2 .intro-text { max-width: none; margin: 1.8rem 0 0; text-align: left; font-size: 1.05rem; line-height: 1.85; columns: 1; column-gap: 3rem; }
@media (min-width: 760px) { .v2 .intro-text { columns: 2; } }
.v2 .intro-text p { break-inside: avoid-column; margin-bottom: 1.1em; }

/* Gruppi di quattro ville: due per due, centrati */
@media (min-width: 680px) {
	.vgrid--4 { max-width: 880px; margin-left: auto; margin-right: auto; }
	.vgrid--4 .vcard { flex-basis: calc((100% - var(--g)) / 2); max-width: calc((100% - var(--g)) / 2); }
}

/* Titoli di blocco (Descrizione, Disponibilità, Servizi, Prezzi...): piu' piccoli e sobri, ovunque */
.v2 .sub-title, .v2 .spec .sub-title {
	font-size: clamp(.95rem, 1.2vw, 1.1rem); letter-spacing: .22em; line-height: 1.3;
	padding-bottom: .8em; margin-bottom: 1.1rem;
}
.v2 .spec .sub-title { margin-bottom: .4rem; }
.v2 .villa-main .sub-title:not(:first-child) { margin-top: clamp(2rem, 4vw, 3rem); }

/* Gruppi di quattro ville: su una sola riga sugli schermi larghi */
@media (min-width: 1100px) {
	.vgrid--4 { max-width: none; }
	.vgrid--4 .vcard { flex-basis: calc((100% - 3 * var(--g)) / 4); max-width: calc((100% - 3 * var(--g)) / 4); }
	.vgrid--4 .vcard__body { padding: 1.3rem 1.2rem 1.5rem; }
	.vgrid--4 .vcard__body h3 { font-size: 1.45rem; }
	.vgrid--4 .vcard__body p { font-size: .95rem; -webkit-line-clamp: 5; }
	.vgrid--4 .vcard__body .btn { padding: .85em 1.2em; letter-spacing: .12em; font-size: .82rem; }
}

/* Testo introduttivo delle pagine interne: centrato, una colonna, leggermente piu' grande */
.v2 .intro-text { max-width: 54rem; margin: 1.6rem auto 0; text-align: center; font-size: 1.22rem; line-height: 1.85; columns: 1; }
@media (min-width: 760px) { .v2 .intro-text { columns: 1; } }
.v2 .intro-text p { margin-bottom: 1em; }

/* Spazio sotto ogni sezione: compensa la sovrapposizione con la successiva (angoli arrotondati) */
.v2 main > section:not(:last-child) { padding-bottom: calc(clamp(2.8rem, 5vw, 4.2rem) + var(--sec-rad)); }

/* Meno spazio tra le schede dei villini */
.vgrid { --g: clamp(.7rem, 1.2vw, 1rem); gap: var(--g); }

/* L'hero mantiene il suo margine sotto la foto (la regola sopra vale per le altre sezioni) */
.v2 main > .hero2 { padding-bottom: clamp(1.4rem, 2.6vw, 2.2rem); }
html body.v2 main > section.hero2.hero2 { padding-bottom: clamp(1.4rem, 2.6vw, 2.2rem) !important; }

/* Gruppi di villini (4, 6, 8 persone): piu' spazio sotto le schede */
html body.v2 main > section[id^="ville-"]:not(:last-child) { padding-bottom: calc(clamp(4.5rem, 8vw, 7rem) + var(--sec-rad)); }
html body.v2 main > section[id^="ville-"]:last-child { padding-bottom: clamp(4.5rem, 8vw, 7rem); }


/* ==========================================================================
   Animazioni in piu': linee dei titoli, comparsa a scalare, foto che si assestano, transizione tra pagine
   ========================================================================== */

/* Le linee sopra e sotto i titoli si aprono dal centro */
.v2 .rule-title { border-top: 0 !important; border-bottom: 0 !important; position: relative; }
.v2 .rule-title::before, .v2 .rule-title::after {
	content: ""; position: absolute; left: 0; right: 0; height: 1px; background: currentColor; opacity: .35;
	transform: scaleX(0); transform-origin: center; transition: transform 1.4s var(--ease) .15s;
}
.v2 .rule-title::before { top: 0; }
.v2 .rule-title::after { bottom: 0; }
.v2 .rule-title.is-in::before, .v2 .rule-title.is-in::after { transform: scaleX(1); }

/* Elenchi e galleria: gli elementi compaiono uno dopo l'altro */
.spec li, .gal a, .mosaic a { opacity: 0; transform: translateY(22px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.spec.is-in li, .gal.is-in a, .mosaic.is-in a { opacity: 1; transform: none; }
.spec.is-in li:nth-child(1), .gal.is-in a:nth-child(1), .mosaic.is-in a:nth-child(1) { transition-delay: .05s; }
.spec.is-in li:nth-child(2), .gal.is-in a:nth-child(2), .mosaic.is-in a:nth-child(2) { transition-delay: .13s; }
.spec.is-in li:nth-child(3), .gal.is-in a:nth-child(3), .mosaic.is-in a:nth-child(3) { transition-delay: .21s; }
.spec.is-in li:nth-child(4), .gal.is-in a:nth-child(4) { transition-delay: .29s; }
.spec.is-in li:nth-child(5), .gal.is-in a:nth-child(5) { transition-delay: .37s; }
.spec.is-in li:nth-child(6), .gal.is-in a:nth-child(6) { transition-delay: .45s; }
.spec.is-in li:nth-child(7), .gal.is-in a:nth-child(7) { transition-delay: .53s; }
.spec.is-in li:nth-child(n+8), .gal.is-in a:nth-child(n+8) { transition-delay: .6s; }
.gal a.is-hover { transition-delay: 0s; }

/* Le foto si assestano: partono leggermente ingrandite */
.vcard__img img, .rooms-panel__img img { transform: scale(1.08); transition: transform 1.6s var(--ease); }
.vcard.is-in .vcard__img img, .rooms-panel.is-active .rooms-panel__img img { transform: scale(1); }
.vcard.is-in:hover .vcard__img img { transform: scale(1.06); }

/* Transizione morbida tra le pagine */
@keyframes page-in { from { opacity: 0; } to { opacity: 1; } }
body.v2 { animation: page-in .7s ease both; }
body.v2.is-leaving { opacity: 0; transition: opacity .28s ease; }

@media (prefers-reduced-motion: reduce) {
	.v2 .rule-title::before, .v2 .rule-title::after { transform: scaleX(1); transition: none; }
	.spec li, .gal a, .mosaic a { opacity: 1; transform: none; transition: none; }
	.vcard__img img, .rooms-panel__img img { transform: none; transition: none; }
	body.v2 { animation: none; }
}

/* Hero su telefono: contenuto piu' compatto, con aria sotto il menu */
@media (max-width: 640px) {
	.hero2:not(.hero2--page) .hero2__media { min-height: 640px; }
	.hero2:not(.hero2--page) .hero2__content { inset: 6.6rem 0 9.4rem; gap: .8rem; }
	.hero2:not(.hero2--page) .hero2__logo-svg { width: min(150px, 42vw); }
	.hero2:not(.hero2--page) .hero2__tagline { font-size: .98rem; line-height: 1.5; max-width: 30ch; }
	.hero2:not(.hero2--page) .hero2__actions { gap: .6rem; margin-top: .2rem; }
	.hero2:not(.hero2--page) .hero2__actions .btn { padding: .85em 1.6em; font-size: .8rem; }
}

/* Logo del menu mobile: piu' grande e ben visibile */
.mobile-menu img { width: 160px; }

/* Su telefono nessun logo al centro dell'hero (e' gia' nel menu); il titolo resta per i motori di ricerca */
@media (max-width: 640px) {
	.hero2:not(.hero2--page) .hero2__logo-svg { display: none; }
	.hero2:not(.hero2--page) .hero2__content { inset: 6rem 0 9rem; gap: 1.2rem; }
	.hero2:not(.hero2--page) .hero2__tagline { font-size: 1.1rem; max-width: 28ch; }
}

@media (max-width: 640px) { .hero2:not(.hero2--page) .hero2__logo-svg, .hero2:not(.hero2--page) .hero2__logo svg { display: none !important; } }

/* Bottoni dell'hero su telefono: impilati e della stessa larghezza */
@media (max-width: 640px) {
	.hero2 .hero2__actions { flex-direction: column; align-items: stretch; width: min(260px, 100%); margin-left: auto; margin-right: auto; }
	.hero2 .hero2__actions .btn { width: 100%; justify-content: center; }
}

/* Hero delle pagine interne su telefono: piu' alto, con spazio per titolo, tag e barra di prenotazione */
@media (max-width: 640px) {
	html body.v2 .hero2--page .hero2__media { height: min(74svh, 640px); min-height: 520px; }
	.hero2--page .hero2__content { inset: 0; padding: 5.5rem var(--gutter) 9.2rem; }
}

/* Su telefono i testi delle sezioni sono centrati */
@media (max-width: 760px) {
	.v2 .cols, .v2 .villa-text { text-align: center; }
}
