/* =========================================================
   Casa Salina 2.0 — strato visivo
   Stessi colori e caratteri del sito (Playfair Display + Open Sans, terracotta #A8796F),
   impaginazione più ariosa e animazioni allo scorrimento.
   ========================================================= */
:root {
  --paper: #f6f3ee;
  --sand: #ece5da;
  --ink: #2b2a28;
  --ink-2: #6d6a65;
  --ink-3: #9a968f;
  --line: rgba(43, 42, 40, .12);
  --accent: #A8796F;
  --accent-d: #8E645B;
  --night: #151412;
  --serif: 'Playfair Display', Georgia, serif;
  --sans: 'Open Sans', system-ui, sans-serif;
  --ease: cubic-bezier(.2, .7, .1, 1);
  --gut: clamp(18px, 4vw, 56px);
}
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
body.v2 { background: var(--paper); color: var(--ink-2); font-family: var(--sans); font-weight: 300; overflow-x: clip; }
.v2 img { max-width: 100%; }
.v2-serif { font-family: var(--serif); font-style: italic; font-weight: 400; color: var(--ink); }
.v2-kicker { font-size: 11px; letter-spacing: 4px; text-transform: uppercase; font-weight: 600; color: var(--accent); margin: 0 0 18px; }
.v2-wrap { max-width: 1280px; margin: 0 auto; padding: 0 var(--gut); }
.v2-btn {
  display: inline-flex; align-items: center; gap: 12px; padding: 16px 30px; background: var(--accent); color: #fff;
  font-size: 11px; letter-spacing: 2.5px; text-transform: uppercase; font-weight: 600; transition: background .35s, transform .35s var(--ease);
}
.v2-btn:hover { background: var(--accent-d); transform: translateY(-2px); }
.v2-btn.ghost { background: transparent; border: 1px solid currentColor; }
.v2-btn.ghost:hover { background: #fff; color: var(--ink); border-color: #fff; }
.v2-btn.dark { background: var(--ink); }
.v2-btn.dark:hover { background: var(--accent); }

/* ---------- header ---------- */
.v2-header {
  position: fixed; inset: 0 0 auto 0; z-index: 60; height: 76px; display: flex; align-items: center;
  transition: background .45s, height .45s, box-shadow .45s, transform .5s var(--ease); color: #fff;
}
.v2-header .v2-wrap { width: 100%; display: flex; align-items: center; gap: 28px; max-width: 1440px; }
.v2-logo img { height: 38px; width: auto; filter: brightness(0) invert(1); transition: filter .45s, height .45s; }
.v2-header.scrolled { background: rgba(246, 243, 238, .94); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); height: 64px; color: var(--ink); box-shadow: 0 1px 0 var(--line); }
.v2-header.scrolled .v2-logo img { filter: none; height: 32px; }
.v2-header.hide { transform: translateY(-100%); }
#nav-menu { margin-left: auto; gap: 26px; align-items: center; }
#nav-menu a { font-size: 11px; letter-spacing: 2.5px; text-transform: uppercase; font-weight: 600; opacity: .85; transition: opacity .3s, color .3s; }
#nav-menu a:hover { opacity: 1; color: var(--accent); }
.v2-lang { font-size: 11px; letter-spacing: 2px; font-weight: 600; border: 1px solid currentColor; padding: 6px 10px; opacity: .8; }
.v2-lang:hover { opacity: 1; }
.v2-cta { padding: 11px 20px; }
#mobile-menu-btn { margin-left: auto; width: 44px; height: 44px; display: none; position: relative; color: inherit; }
#mobile-menu-btn span { position: absolute; left: 11px; right: 11px; height: 1.5px; background: currentColor; transition: transform .35s var(--ease), top .35s var(--ease); }
#mobile-menu-btn span:first-child { top: 17px; } #mobile-menu-btn span:last-child { top: 26px; }
@media (max-width: 1023px) {
  #mobile-menu-btn { display: block; }
  .v2-header .v2-cta { display: none; }
  #nav-menu { position: fixed; inset: 64px 0 auto 0; background: var(--paper); color: var(--ink); flex-direction: column; align-items: flex-start; gap: 0; padding: 12px var(--gut) 28px; box-shadow: 0 30px 40px -20px rgba(0,0,0,.25); }
  #nav-menu a { font-size: 13px; padding: 14px 0; width: 100%; border-bottom: 1px solid var(--line); opacity: 1; }
  #nav-menu.flex ~ #mobile-menu-btn span:first-child { top: 21px; transform: rotate(45deg); }
  #nav-menu.flex ~ #mobile-menu-btn span:last-child { top: 21px; transform: rotate(-45deg); }
}

/* ---------- hero ---------- */
.v2-hero { position: relative; height: 100svh; min-height: 620px; overflow: hidden; background: var(--night); color: #fff; display: flex; align-items: flex-end; }
.v2-hero-slides { position: absolute; inset: 0; }
.v2-hero-slides figure { position: absolute; inset: 0; margin: 0; opacity: 0; transition: opacity 1.6s ease; }
.v2-hero-slides figure.on { opacity: 1; }
.v2-hero-slides img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.12); }
.v2-hero-slides figure.on img { animation: kenburns 9s ease-out forwards; }
@keyframes kenburns { from { transform: scale(1.12); } to { transform: scale(1); } }
.v2-hero-shade { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(10,10,9,.78) 0%, rgba(10,10,9,.35) 50%, rgba(10,10,9,.05) 80%), linear-gradient(0deg, rgba(10,10,9,.6), transparent 45%); }
.v2-hero-inner { position: relative; z-index: 2; padding-bottom: clamp(70px, 12vh, 130px); width: 100%; }
.v2-hero h1 { font-weight: 300; font-size: clamp(36px, 5.6vw, 84px); line-height: 1.05; letter-spacing: .5px; margin: 0 0 34px; color: #fff; max-width: 15ch; }
.v2-hero h1 .l { display: block; overflow: hidden; padding-bottom: .08em; }
.v2-hero h1 .l > span { display: inline-block; }
.v2-hero h1 .acc { color: #e2b3a8; font-weight: 600; }
.v2-hero h1 .v2-serif { color: #fff; font-size: 1.12em; }
.v2-hero .v2-kicker { color: rgba(255,255,255,.75); }
.v2-hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }
.v2-hero-dots { position: absolute; z-index: 3; right: var(--gut); bottom: 40px; display: flex; gap: 10px; }
.v2-hero-dots button { width: 34px; height: 2px; background: rgba(255,255,255,.35); position: relative; overflow: hidden; }
.v2-hero-dots button.on::after { content: ""; position: absolute; inset: 0; background: #fff; animation: dotfill 6s linear forwards; }
@keyframes dotfill { from { transform: translateX(-100%); } to { transform: none; } }

/* ---------- manifesto ---------- */
.v2-manifesto { padding: clamp(100px, 14vw, 190px) 0 clamp(70px, 9vw, 120px); text-align: center; }
.v2-manifesto .v2-big { font-family: var(--serif); font-style: italic; color: var(--ink); font-size: clamp(30px, 4.2vw, 62px); line-height: 1.18; max-width: 22ch; margin: 0 auto 60px; }
.v2-big .w { display: inline-block; opacity: .15; }
.v2-story { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(30px, 6vw, 90px); text-align: left; max-width: 1080px; margin: 0 auto; font-size: 15.5px; line-height: 1.9; }
.v2-story p { margin: 0 0 18px; }
.v2-story strong { color: var(--ink); font-weight: 600; }
@media (max-width: 800px) { .v2-story { grid-template-columns: 1fr; } }

/* ---------- numeri ---------- */
.v2-numbers { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.v2-numbers .v2-wrap { display: grid; grid-template-columns: repeat(4, 1fr); }
.v2-num { padding: 44px 20px; text-align: center; }
.v2-num + .v2-num { border-left: 1px solid var(--line); }
.v2-num b { display: block; font-family: var(--serif); font-weight: 400; font-size: clamp(40px, 4.6vw, 64px); color: var(--ink); line-height: 1; }
.v2-num span { display: block; margin-top: 12px; font-size: 11px; letter-spacing: 2.5px; text-transform: uppercase; font-weight: 600; color: var(--ink-3); }
@media (max-width: 700px) { .v2-numbers .v2-wrap { grid-template-columns: 1fr 1fr; } .v2-num:nth-child(3) { border-left: 0; } .v2-num:nth-child(n+3) { border-top: 1px solid var(--line); } }

/* ---------- spazi (scorrimento orizzontale) ---------- */
.v2-spaces { background: var(--night); color: #fff; position: relative; }
.v2-spaces-head { padding: clamp(90px, 10vw, 140px) 0 50px; }
.v2-spaces-head h2 { font-size: clamp(34px, 4.4vw, 64px); color: #fff; margin: 0; }
.v2-spaces-pin { height: 100vh; overflow: hidden; }
.v2-spaces-track { display: flex; height: 100%; width: max-content; gap: 3vw; padding: 0 var(--gut); align-items: center; }
.v2-space { position: relative; height: 74vh; width: min(62vw, 980px); flex: none; overflow: hidden; }
.v2-space img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.12); }
.v2-space figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 30px 34px; background: linear-gradient(0deg, rgba(10,10,9,.82), transparent); }
.v2-space figcaption b { display: block; font-family: var(--serif); font-style: italic; font-weight: 400; font-size: clamp(26px, 2.6vw, 40px); }
.v2-space figcaption span { display: block; max-width: 46ch; font-size: 14px; line-height: 1.7; color: rgba(255,255,255,.82); margin-top: 6px; }
.v2-space .idx { position: absolute; top: 24px; left: 30px; font-size: 11px; letter-spacing: 3px; font-weight: 600; color: rgba(255,255,255,.75); }
.v2-spaces-bar { position: absolute; left: var(--gut); right: var(--gut); bottom: 34px; height: 1px; background: rgba(255,255,255,.18); }
.v2-spaces-bar i { position: absolute; inset: 0; background: var(--accent); transform-origin: left; transform: scaleX(0); }
@media (max-width: 900px) {
  .v2-spaces-pin { height: auto; overflow: visible; padding-bottom: 60px; }
  .v2-spaces-track { flex-direction: column; width: 100%; gap: 22px; }
  .v2-space { width: 100%; height: 62vh; }
  .v2-spaces-bar { display: none; }
}

/* ---------- dotazioni ---------- */
.v2-section { padding: clamp(90px, 11vw, 160px) 0; }
.v2-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 30px; margin-bottom: clamp(40px, 6vw, 70px); flex-wrap: wrap; }
.v2-head h2 { font-size: clamp(34px, 4.4vw, 64px); margin: 0; line-height: 1.08; }
.v2-head p { max-width: 44ch; margin: 0; font-size: 15px; line-height: 1.8; }
.v2-amen { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.v2-amen article { background: #fff; overflow: hidden; }
.v2-amen .ph { aspect-ratio: 4 / 5; overflow: hidden; }
.v2-amen img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease); }
.v2-amen article:hover img { transform: scale(1.07); }
.v2-amen .tx { padding: 24px 22px 28px; }
.v2-amen h3 { font-family: var(--serif); font-style: italic; font-weight: 400; font-size: 22px; color: var(--ink); margin: 0 0 10px; }
.v2-amen p { font-size: 14px; line-height: 1.75; margin: 0; }
@media (max-width: 1000px) { .v2-amen { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .v2-amen { grid-template-columns: 1fr; } }

/* ---------- camere ---------- */
.v2-rooms { background: var(--sand); }
.v2-room { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(30px, 6vw, 90px); align-items: center; }
.v2-room + .v2-room { margin-top: clamp(80px, 10vw, 140px); }
.v2-room:nth-child(even) .v2-room-media { order: 2; }
.v2-room-media { position: relative; aspect-ratio: 5 / 4; overflow: hidden; cursor: zoom-in; }
.v2-room-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 1.1s ease, transform 6s ease; transform: scale(1.06); }
.v2-room-media img.on { opacity: 1; transform: scale(1); }
.v2-room-media .count { position: absolute; right: 16px; bottom: 16px; background: rgba(21,20,18,.7); color: #fff; font-size: 11px; letter-spacing: 2px; padding: 8px 12px; font-weight: 600; }
.v2-room .floor { font-size: 11px; letter-spacing: 3px; text-transform: uppercase; font-weight: 600; color: var(--accent); }
.v2-room h3 { font-family: var(--serif); font-style: italic; font-weight: 400; color: var(--ink); font-size: clamp(40px, 4.6vw, 68px); margin: 10px 0 6px; line-height: 1; }
.v2-room h4 { font-weight: 400; font-size: 18px; color: var(--ink); margin: 0 0 18px; }
.v2-room p { font-size: 15px; line-height: 1.85; margin: 0 0 22px; }
.v2-feat { list-style: none; padding: 0; margin: 0 0 30px; display: grid; grid-template-columns: 1fr 1fr; gap: 10px 20px; font-size: 13.5px; }
.v2-feat li::before { content: "—"; color: var(--accent); margin-right: 10px; }
.v2-room-actions { display: flex; gap: 12px; flex-wrap: wrap; }
@media (max-width: 860px) { .v2-room { grid-template-columns: 1fr; } .v2-room:nth-child(even) .v2-room-media { order: 0; } }

/* ---------- gallery ---------- */
.v2-filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 34px; }
.v2-filters button { padding: 10px 18px; border: 1px solid var(--line); font-size: 11px; letter-spacing: 2px; text-transform: uppercase; font-weight: 600; color: var(--ink-2); transition: all .3s; }
.v2-filters button:hover { border-color: var(--ink); color: var(--ink); }
.v2-filters button.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.v2-masonry { columns: 3 320px; column-gap: 14px; }
.v2-masonry a { display: block; margin: 0 0 14px; overflow: hidden; break-inside: avoid; position: relative; }
.v2-masonry img { width: 100%; display: block; transition: transform 1s var(--ease), opacity .4s; }
.v2-masonry a:hover img { transform: scale(1.05); }
.v2-masonry a.hidden-by-filter { display: none; }

/* lightbox 2.0 */
.v2-lb { position: fixed; inset: 0; z-index: 200; background: rgba(12,12,11,.96); display: flex; align-items: center; justify-content: center; opacity: 0; pointer-events: none; transition: opacity .35s; }
.v2-lb.open { opacity: 1; pointer-events: auto; }
.v2-lb img { max-width: 92vw; max-height: 84vh; object-fit: contain; box-shadow: 0 30px 80px rgba(0,0,0,.5); }
.v2-lb button { position: absolute; color: #fff; font-size: 30px; width: 56px; height: 56px; display: grid; place-items: center; opacity: .8; transition: opacity .3s; }
.v2-lb button:hover { opacity: 1; }
.v2-lb .x { top: 18px; right: 18px; font-size: 26px; }
.v2-lb .pv { left: 14px; top: 50%; transform: translateY(-50%); }
.v2-lb .nx { right: 14px; top: 50%; transform: translateY(-50%); }
.v2-lb .ct { position: absolute; bottom: 22px; left: 50%; transform: translateX(-50%); color: rgba(255,255,255,.7); font-size: 12px; letter-spacing: 2px; }

/* ---------- blocchi del sito attuale inseriti nella 2.0 ---------- */
.v2 #recensioni, .v2 #contatti { background: var(--paper) !important; }
.v2 #dovesiamo { border-top: 0 !important; }

/* ---------- footer ---------- */
.v2-footer { background: var(--night); color: #9a968f; padding-top: clamp(70px, 9vw, 120px); overflow: hidden; }
.v2-footer-mark { font-family: var(--serif); font-style: italic; font-size: clamp(64px, 14vw, 230px); line-height: .9; text-align: center; color: transparent; background: linear-gradient(180deg, rgba(255,255,255,.16), rgba(255,255,255,0) 90%); -webkit-background-clip: text; background-clip: text; white-space: nowrap; user-select: none; }
.v2-footer-grid { display: grid; grid-template-columns: 1.4fr repeat(4, 1fr); gap: 34px; padding: 60px 0 50px; border-top: 1px solid rgba(255,255,255,.1); margin-top: 40px; font-size: 13px; line-height: 2; }
.v2-footer h5 { color: #fff; font-size: 11px; letter-spacing: 3px; text-transform: uppercase; font-weight: 600; margin: 0 0 14px; }
.v2-footer a:hover { color: #fff; }
.v2-footer .logo img { height: 40px; filter: brightness(0) invert(1); opacity: .9; margin-bottom: 16px; }
.v2-footer-bottom { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding: 24px 0 34px; border-top: 1px solid rgba(255,255,255,.1); font-size: 11px; letter-spacing: 2px; text-transform: uppercase; }
.v2-credit strong { color: #fff; font-weight: 600; letter-spacing: 3px; transition: color .3s; }
.v2-credit:hover strong { color: var(--accent); }
@media (max-width: 900px) { .v2-footer-grid { grid-template-columns: 1fr 1fr; } .v2-footer-grid > div:first-child { grid-column: 1 / -1; } }

/* stato iniziale per le animazioni (senza JS resta tutto visibile) */
.v2-js [data-up] { opacity: 0; transform: translateY(40px); }

/* hero: più contrasto e titolo su righe più lunghe */
.v2-hero-shade { background: linear-gradient(90deg, rgba(10,10,9,.86) 0%, rgba(10,10,9,.62) 38%, rgba(10,10,9,.18) 72%, rgba(10,10,9,.05) 100%), linear-gradient(0deg, rgba(10,10,9,.72), transparent 50%), linear-gradient(180deg, rgba(10,10,9,.45), transparent 25%); }
.v2-hero-inner { max-width: 1440px; }
.v2-hero h1 { font-size: clamp(34px, 4.6vw, 74px); max-width: 20ch; text-shadow: 0 2px 30px rgba(0,0,0,.35); }

/* galleria: prime 15 foto, poi "Mostra tutte" */
.v2-masonry a.more-hidden { display: none; }
.v2-more-wrap { text-align: center; margin-top: 26px; }
