:root {
  --cream: #f5efe5;
  --cream-2: #fbf7ef;
  --paper: #fffaf2;
  --ink: #2b2d26;
  --muted: #746e63;
  --sage: #51624e;
  --sage-dark: #2f3f33;
  --terracotta: #ad613c;
  --terracotta-dark: #8e472b;
  --sand: #d8c7a8;
  --line: rgba(83, 71, 54, .16);
  --shadow: 0 28px 70px rgba(54, 42, 27, .13);
  --serif: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
  --sans: 'Montserrat', Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--cream);
  font-family: var(--sans);
  line-height: 1.68;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
button, input, select { font: inherit; }

::selection { background: rgba(173, 97, 60, .22); }

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  padding: 16px 28px;
  transition: padding .3s ease, background .3s ease, box-shadow .3s ease;
}
.site-header.is-scrolled {
  padding: 10px 22px;
  background: rgba(250, 246, 238, .92);
  backdrop-filter: blur(18px);
  box-shadow: 0 14px 40px rgba(54, 42, 27, .08);
}
.nav-shell {
  width: min(1180px, calc(100vw - 44px));
  min-height: 88px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 190px 1fr auto auto;
  align-items: center;
  gap: 28px;
}
.brand {
  width: 154px;
  text-decoration: none;
  display: block;
}
.brand img {
  width: 154px;
  height: auto;
  object-fit: contain;
  mix-blend-mode: multiply;
}
.main-nav {
  justify-self: center;
  display: flex;
  align-items: center;
  gap: 32px;
}
.main-nav a {
  text-decoration: none;
  text-transform: uppercase;
  font-size: .76rem;
  letter-spacing: .12em;
  font-weight: 700;
  color: #2f302a;
  position: relative;
  padding: 10px 0;
}
.main-nav a::after {
  content: '';
  position: absolute;
  left: 0;
  right: 100%;
  bottom: 0;
  height: 2px;
  background: var(--terracotta);
  transition: right .25s ease;
}
.main-nav a:hover::after,
.main-nav a.active::after { right: 0; }

.nav-toggle {
  display: none;
  appearance: none;
  border: 0;
  background: transparent;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  cursor: pointer;
  justify-self: end;
}
.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  margin: 5px auto;
  background: var(--ink);
  transition: transform .25s ease, opacity .25s ease;
}
.nav-toggle.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.is-open span:nth-child(2) { opacity: 0; }
.nav-toggle.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 14px 24px;
  border-radius: 6px;
  text-decoration: none;
  text-transform: uppercase;
  font-size: .75rem;
  letter-spacing: .12em;
  font-weight: 800;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .25s ease, background .25s ease, color .25s ease, border-color .25s ease, box-shadow .25s ease;
  white-space: nowrap;
}
.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(98, 58, 34, .16);
}
.btn-solid { background: var(--terracotta); color: #fffaf4; }
.btn-solid:hover { background: var(--terracotta-dark); }
.btn-outline { color: var(--terracotta-dark); border-color: rgba(142, 71, 43, .38); background: rgba(255, 250, 242, .22); }
.btn-outline:hover { background: #fff7ec; border-color: var(--terracotta); }
.btn-ghost { color: #fff; border-color: rgba(255,255,255,.58); background: rgba(255,255,255,.08); backdrop-filter: blur(8px); }
.nav-cta { justify-self: end; }

.language-switch {
  justify-self: end;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px;
  border: 1px solid rgba(112, 92, 65, .18);
  border-radius: 999px;
  background: rgba(255, 250, 242, .72);
  box-shadow: 0 8px 22px rgba(54, 42, 27, .07);
}
.language-switch a {
  min-width: 34px;
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  text-decoration: none;
  font-size: .68rem;
  letter-spacing: .12em;
  font-weight: 800;
  color: var(--sage-dark);
}
.language-switch a.is-current {
  background: var(--sage-dark);
  color: #fffaf2;
}
.language-switch a:not(.is-current):hover {
  background: rgba(173, 97, 60, .12);
  color: var(--terracotta-dark);
}


.hero {
  min-height: 100svh;
  position: relative;
  display: grid;
  align-items: center;
  overflow: hidden;
  background: var(--cream-2);
}
.hero-bg {
  position: absolute;
  inset: 0;
  background-image: url('../img/hero.jpg');
  background-size: cover;
  background-position: 68% 50%;
  filter: saturate(.92) contrast(.95) brightness(1.04);
  transform: scale(1.02);
}
.hero-veiling {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(250,245,236,.93) 0%, rgba(250,245,236,.78) 28%, rgba(250,245,236,.33) 52%, rgba(250,245,236,.06) 100%),
    radial-gradient(circle at 10% 82%, rgba(180, 98, 54, .22), transparent 32%),
    linear-gradient(180deg, rgba(246,239,226,.80) 0%, rgba(246,239,226,.08) 28%, rgba(87,62,38,.13) 100%);
}
.hero-content {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100vw - 46px));
  margin: 0 auto;
  padding-top: 120px;
  max-width: 1180px;
}
.kicker,
.section-label {
  margin: 0 0 16px;
  color: var(--terracotta-dark);
  text-transform: uppercase;
  letter-spacing: .22em;
  font-size: .74rem;
  font-weight: 800;
}
.hero h1,
.villa-text h2,
.section-heading h2,
.split-content h2,
.booking-copy h2,
.contact-card h2 {
  font-family: var(--serif);
  font-weight: 600;
  letter-spacing: -.025em;
  line-height: .98;
  color: var(--ink);
}
.hero h1 {
  width: min(610px, 92vw);
  margin: 0;
  font-size: clamp(3.1rem, 7vw, 6.4rem);
}
.small-line {
  display: block;
  width: 52px;
  height: 2px;
  background: var(--terracotta);
  margin: 26px 0 18px;
}
.hero-copy {
  width: min(520px, 92vw);
  margin: 0 0 30px;
  color: #514c42;
  font-family: Georgia, serif;
  font-size: clamp(1.05rem, 1.45vw, 1.25rem);
  line-height: 1.55;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }

.promise-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  background: rgba(255, 250, 242, .72);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 1px 0 rgba(255,255,255,.5) inset;
}
.promise-item {
  min-height: 172px;
  text-align: center;
  padding: 34px 28px 28px;
  position: relative;
}
.promise-item:not(:last-child)::after {
  content: '';
  position: absolute;
  right: 0;
  top: 32px;
  bottom: 32px;
  width: 1px;
  background: var(--line);
}
.promise-icon {
  display: block;
  color: #9d8461;
  font-size: 2.3rem;
  line-height: 1;
  margin-bottom: 14px;
  font-family: Georgia, serif;
}
.promise-item h2 {
  margin: 0 0 8px;
  font-size: .78rem;
  text-transform: uppercase;
  letter-spacing: .18em;
  color: #51493d;
}
.promise-item p { margin: 0 auto; max-width: 260px; color: var(--muted); font-family: Georgia, serif; line-height: 1.45; }

.villa-section {
  display: grid;
  grid-template-columns: minmax(320px, 1fr) minmax(420px, 1.22fr);
  min-height: 560px;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}
.villa-text {
  padding: clamp(68px, 8vw, 110px) clamp(38px, 7vw, 120px);
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.villa-text h2,
.section-heading h2,
.split-content h2,
.booking-copy h2,
.contact-card h2 { font-size: clamp(2.45rem, 4.3vw, 4.15rem); margin: 0; }
.villa-text p,
.split-content p,
.section-heading p,
.booking-copy p,
.contact-card p {
  color: #5e5a50;
  font-family: Georgia, serif;
  font-size: 1.05rem;
  max-width: 640px;
}
.villa-text .btn { margin-top: 18px; align-self: flex-start; }
.villa-photo { margin: 0; min-height: 520px; overflow: hidden; }
.villa-photo img { width: 100%; height: 100%; object-fit: cover; object-position: center; filter: saturate(.92) brightness(1.02); }

.section-pad { padding: clamp(72px, 8vw, 116px) max(24px, calc((100vw - 1180px) / 2)); }
.section-heading { margin: 0 auto 48px; max-width: 760px; }
.section-heading.center { text-align: center; }
.decor { display: inline-block; margin: 10px 0 8px; color: var(--terracotta); font-size: 1.1rem; }

.room-grid {
  width: min(1080px, calc(100vw - 46px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px;
}
.image-card {
  background: rgba(255,250,242,.82);
  box-shadow: var(--shadow);
  overflow: hidden;
  border-radius: 2px;
  border: 1px solid rgba(112, 92, 65, .12);
  transition: transform .35s ease, box-shadow .35s ease;
}
.image-card:hover { transform: translateY(-8px); box-shadow: 0 34px 80px rgba(54, 42, 27, .18); }
.image-card img { width: 100%; height: clamp(290px, 31vw, 360px); object-fit: cover; }
.image-card-body { padding: 26px 28px 30px; }
.image-card-body h3,
.destination-card h3,
.mini-card h3 {
  margin: 0 0 8px;
  color: #312f29;
  font-family: var(--serif);
  font-size: 1.8rem;
  line-height: 1.05;
}
.image-card-body p,
.destination-card span,
.mini-card p { margin: 0; color: var(--muted); font-family: Georgia, serif; line-height: 1.55; }

.split-section {
  display: grid;
  width: min(1180px, calc(100vw - 46px));
  margin: 0 auto;
  grid-template-columns: .95fr 1.05fr;
  gap: 56px;
  align-items: center;
}
.split-section.section-pad {
  padding-left: 0;
  padding-right: 0;
}
.split-photo { margin: 0; position: relative; }
.split-photo::before {
  content: '';
  position: absolute;
  inset: -20px 20px 20px -20px;
  border: 1px solid rgba(173,97,60,.28);
  z-index: -1;
}
.split-photo img {
  width: 100%;
  height: clamp(420px, 42vw, 620px);
  object-fit: cover;
  box-shadow: var(--shadow);
}
.service-list {
  margin-top: 30px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.service-list div {
  background: rgba(255,250,242,.72);
  border: 1px solid rgba(112, 92, 65, .13);
  padding: 20px;
}
.service-list strong { display: block; color: var(--sage-dark); margin-bottom: 4px; }
.service-list span { display: block; color: var(--muted); font-family: Georgia, serif; font-size: .98rem; line-height: 1.45; }

.experience-band {
  background:
    linear-gradient(rgba(47,63,51,.89), rgba(47,63,51,.89)),
    url('../img/polignano.jpg') center/cover no-repeat;
  color: #fff;
}
.experience-band .section-label,
.experience-band .decor { color: #efc39f; }
.experience-band h2,
.experience-band p { color: #fff7ed; }
.experience-grid {
  width: min(1180px, calc(100vw - 46px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.mini-card {
  padding: 34px;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.2);
  backdrop-filter: blur(7px);
}
.mini-card span { color: #efc39f; font-weight: 800; letter-spacing: .16em; }
.mini-card h3 { color: #fff; margin-top: 12px; }
.mini-card p { color: rgba(255,247,237,.82); }

.destinations-section { background: var(--cream-2); }
.destination-grid {
  width: min(1180px, calc(100vw - 46px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
}
.destination-card {
  background: var(--paper);
  border: 1px solid rgba(112, 92, 65, .13);
  box-shadow: 0 22px 56px rgba(54, 42, 27, .10);
  overflow: hidden;
  transition: transform .35s ease, box-shadow .35s ease;
}
.destination-card:hover { transform: translateY(-8px); box-shadow: 0 32px 70px rgba(54, 42, 27, .17); }
.destination-card img { width: 100%; height: 255px; object-fit: cover; }
.destination-card div { padding: 24px 26px 28px; }
.destination-card p { margin: 0 0 8px; color: var(--terracotta-dark); text-transform: uppercase; letter-spacing: .14em; font-size: .72rem; font-weight: 800; }

.booking-section {
  background:
    radial-gradient(circle at 8% 0%, rgba(173,97,60,.14), transparent 34%),
    linear-gradient(135deg, #fff9f0, #efe2cf);
}
.booking-card {
  width: min(1120px, calc(100vw - 46px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.02fr .98fr;
  gap: 42px;
  align-items: center;
  padding: clamp(32px, 5vw, 58px);
  background: rgba(255,250,242,.78);
  border: 1px solid rgba(112,92,65,.15);
  box-shadow: var(--shadow);
}
.booking-form {
  display: grid;
  gap: 12px;
  background: #fffaf2;
  border: 1px solid rgba(112,92,65,.14);
  padding: 30px;
}
.booking-form label { font-size: .76rem; text-transform: uppercase; letter-spacing: .14em; font-weight: 800; color: var(--sage-dark); }
.booking-form input,
.booking-form select {
  width: 100%;
  min-height: 50px;
  border: 1px solid rgba(112,92,65,.22);
  background: #fff;
  padding: 12px 14px;
  color: var(--ink);
  outline: none;
}
.booking-form input:focus,
.booking-form select:focus { border-color: var(--terracotta); box-shadow: 0 0 0 4px rgba(173,97,60,.12); }
.price-note {
  padding: 16px;
  background: #f5ebdd;
  border-left: 3px solid var(--terracotta);
  color: #4f4a40;
  font-family: Georgia, serif;
}
.booking-buttons { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 8px; }
.booking-buttons .btn { flex: 1 1 150px; }

.contact-section { background: var(--paper); }
.contact-card {
  width: min(1080px, calc(100vw - 46px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.2fr .8fr;
  gap: 40px;
  align-items: center;
}
.contact-links {
  display: grid;
  gap: 12px;
  background: var(--cream-2);
  border: 1px solid rgba(112, 92, 65, .13);
  padding: 30px;
  box-shadow: 0 18px 44px rgba(54, 42, 27, .08);
}
.contact-links a,
.contact-links span {
  text-decoration: none;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(112, 92, 65, .14);
  color: var(--sage-dark);
  font-weight: 700;
}
.contact-links a:hover { color: var(--terracotta-dark); }
.contact-links span { color: var(--muted); border-bottom: 0; }

.floating-whatsapp {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 60;
  min-height: 48px;
  padding: 13px 18px;
  border-radius: 999px;
  text-decoration: none;
  color: #fff;
  background: #1fae5b;
  box-shadow: 0 14px 34px rgba(31,174,91,.28);
  font-size: .76rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  font-weight: 800;
}

.site-footer {
  background: #272b23;
  color: rgba(255,250,242,.78);
  padding: 34px 24px;
}
.footer-inner {
  width: min(1180px, calc(100vw - 46px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 110px 1fr auto;
  gap: 28px;
  align-items: center;
}
.site-footer img { width: 105px; mix-blend-mode: screen; opacity: .9; }
.site-footer strong { color: #fffaf2; font-family: var(--serif); font-size: 1.5rem; font-weight: 600; }
.site-footer p { margin: 3px 0; font-family: Georgia, serif; }

.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .7s ease, transform .7s ease;
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }

.flatpickr-calendar { font-family: var(--sans); }
.flatpickr-day.selected,
.flatpickr-day.startRange,
.flatpickr-day.endRange,
.flatpickr-day.selected:hover,
.flatpickr-day.startRange:hover,
.flatpickr-day.endRange:hover {
  background: var(--terracotta);
  border-color: var(--terracotta);
}
.flatpickr-day.inRange { background: rgba(173,97,60,.12); border-color: rgba(173,97,60,.12); box-shadow: -5px 0 0 rgba(173,97,60,.12), 5px 0 0 rgba(173,97,60,.12); }


/* Mini calendario disponibilità in home */
.mini-availability {
  display: grid;
  gap: 10px;
  padding: 16px;
  background: #fffdf8;
  border: 1px solid rgba(112,92,65,.14);
  box-shadow: 0 16px 34px rgba(54,42,27,.08);
}
.mini-cal-title-row,
.mini-cal-head,
.mini-cal-legend {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.mini-cal-title-row span {
  font-size: .76rem;
  text-transform: uppercase;
  letter-spacing: .14em;
  font-weight: 800;
  color: var(--sage-dark);
}
.mini-cal-title-row a,
.mini-cal-full {
  font-size: .72rem;
  font-weight: 800;
  color: var(--terracotta-dark);
  text-decoration: none;
  border-bottom: 1px solid rgba(142,71,43,.28);
}
.mini-cal-head {
  padding: 4px 0 2px;
}
.mini-cal-head strong {
  font-family: var(--serif);
  font-size: 1.35rem;
  color: var(--ink);
}
.mini-cal-nav {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(112,92,65,.16);
  background: #fff6e8;
  color: var(--sage-dark);
  text-decoration: none;
  font-size: 1.35rem;
  line-height: 1;
}
.mini-cal-legend {
  justify-content: flex-start;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: .74rem;
  font-weight: 700;
}
.mini-cal-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.mini-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  display: inline-block;
}
.mini-dot-free { background: #2f8f55; }
.mini-dot-busy { background: #c4493d; }
.mini-cal-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 5px;
}
.mini-cal-weekday {
  min-height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: .68rem;
  font-weight: 800;
  text-transform: uppercase;
}
.mini-cal-day {
  min-height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  text-decoration: none;
  font-size: .82rem;
  font-weight: 800;
  color: #fff;
  transition: transform .18s ease, box-shadow .18s ease, filter .18s ease;
}
.mini-cal-day.free {
  background: #2f8f55;
  border-color: rgba(47,143,85,.32);
}
.mini-cal-day.busy {
  background: #c4493d;
  border-color: rgba(196,73,61,.30);
}
.mini-cal-day.out-month {
  opacity: .28;
  filter: grayscale(.45);
}
a.mini-cal-day.free:hover {
  transform: translateY(-1px);
  box-shadow: 0 9px 20px rgba(47,143,85,.22);
}
.mini-availability-fallback p {
  margin: 0;
  color: var(--muted);
  font-family: Georgia, serif;
}

@media (max-width: 1060px) {
  .nav-shell { grid-template-columns: 150px 1fr auto auto; gap: 14px; }
  .main-nav { gap: 18px; }
  .main-nav a { font-size: .7rem; }
  .brand, .brand img { width: 132px; }
}

@media (max-width: 900px) {
  .site-header { padding: 10px 14px; background: rgba(250,246,238,.94); backdrop-filter: blur(16px); }
  .nav-shell { width: min(100%, calc(100vw - 24px)); min-height: 72px; grid-template-columns: 132px 1fr auto 46px; }
  .nav-toggle { display: block; grid-column: 4; grid-row: 1; }
  .language-switch { grid-column: 3; grid-row: 1; }
  .nav-cta { display: none; }
  .main-nav {
    position: absolute;
    left: 18px;
    right: 18px;
    top: 88px;
    display: grid;
    gap: 0;
    background: rgba(255,250,242,.98);
    border: 1px solid rgba(112,92,65,.12);
    box-shadow: var(--shadow);
    padding: 14px;
    transform: translateY(-12px);
    opacity: 0;
    pointer-events: none;
    transition: opacity .22s ease, transform .22s ease;
  }
  .main-nav.is-open { opacity: 1; pointer-events: auto; transform: translateY(0); }
  .main-nav a { padding: 15px 8px; border-bottom: 1px solid rgba(112,92,65,.10); }
  .main-nav a:last-child { border-bottom: 0; }
  .main-nav a::after { display: none; }
  .hero { min-height: 92svh; }
  .hero-bg { background-position: 56% 50%; }
  .hero-veiling { background: linear-gradient(90deg, rgba(250,245,236,.92), rgba(250,245,236,.62), rgba(250,245,236,.16)); }
  .hero-content { padding-top: 118px; }
  .promise-strip { grid-template-columns: repeat(2, 1fr); }
  .promise-item:nth-child(2)::after { display: none; }
  .villa-section,
  .split-section,
  .booking-card,
  .contact-card { grid-template-columns: 1fr; }
  .villa-photo { min-height: 420px; order: -1; }
  .villa-text { padding: 58px 24px; }
  .room-grid,
  .experience-grid,
  .destination-grid { grid-template-columns: 1fr 1fr; }
  .split-section { gap: 38px; }
  .split-photo img { height: clamp(330px, 55vw, 500px); }
  .footer-inner { grid-template-columns: 1fr; text-align: center; justify-items: center; }
}

@media (max-width: 640px) {
  .btn { width: 100%; white-space: normal; text-align: center; }
  .hero-actions { width: min(100%, 360px); }
  .hero h1 { font-size: clamp(2.85rem, 15vw, 4rem); }
  .hero-copy { font-size: 1.02rem; }
  .promise-strip,
  .room-grid,
  .experience-grid,
  .destination-grid,
  .service-list { grid-template-columns: 1fr; }
  .promise-item:not(:last-child)::after { display: none; }
  .promise-item { min-height: 150px; border-bottom: 1px solid var(--line); }
  .image-card img,
  .destination-card img { height: 245px; }
  .section-pad { padding: 68px 0; }
  .split-section { width: min(100%, calc(100vw - 46px)); }
  .split-photo img { height: 320px; }
  .booking-card { padding: 24px; }
  .booking-form { padding: 22px; }
  .floating-whatsapp { left: 18px; right: 18px; text-align: center; justify-content: center; display: flex; align-items: center; }
  .contact-links { padding: 22px; }
}

@media (max-width: 420px) {
  .language-switch { gap: 3px; padding: 4px; }
  .language-switch a { min-width: 30px; min-height: 28px; font-size: .63rem; }
}
