/* ==========================================================================
   SETTIMO — Landing "Ristorante di Pesce a Firenze" (Google Ads)
   Palette brand: ottanio / verde petrolio + bianco. Cucina di mare contemporanea.
   Stack: vanilla, self-contained, font di sistema (zero rete esterna → CWV puliti).
   Struttura .lp-* clonata dalla landing Riva (Lighthouse 100/100/100/100).
   ========================================================================== */

/* === TOKENS === */
:root {
  --ottanio:      #0E5C63;   /* verde petrolio / ottanio brand */
  --ottanio-deep: #093E43;   /* scuro per fondali */
  --ottanio-ink:  #06292D;   /* quasi-nero marino, hero/footer */
  --ottanio-soft: #137A82;   /* accent più chiaro */
  --oro:          #C9A227;   /* accento caldo CTA su fondo scuro/chiaro (≥4.5:1) */
  --oro-chiaro:   #E8C65A;   /* oro più chiaro per testo piccolo su fondo ottanio (contrasto AA) */
  --sabbia:       #F4F1EA;   /* bianco caldo (gesso) */
  --sabbia-warm:  #E9E3D6;
  --grigio:       #3F4A4C;   /* testo su chiaro */
  --bianco:       #FFFFFF;

  --font-display: 'Cormorant Garamond', 'Cormorant', Georgia, 'Times New Roman', serif;
  --font-body:    system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;

  --ease: cubic-bezier(.22,.61,.36,1);
  --maxw: 1280px;
  --pad: clamp(1.25rem, 5vw, 4.5rem);
  --header-h: 68px;
}

/* === RESET / BASE === */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

/* === SITE MOBILE OVERFLOW-X LOCK (regola bloccante) === */
html, body {
  overflow-x: hidden;
  overflow-x: clip;
  overscroll-behavior-x: none;
  max-width: 100vw;
}
body {
  font-family: var(--font-body);
  font-weight: 400;
  color: var(--grigio);
  background: var(--sabbia);
  line-height: 1.6;
  touch-action: pan-y;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img, video { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: 0; background: none; }

/* === A11Y === */
.skip-link {
  position: absolute; top: -100px; left: 1rem; z-index: 2000;
  background: var(--ottanio-ink); color: var(--sabbia);
  padding: .75rem 1.25rem; font-size: .85rem; letter-spacing: .04em; border-radius: 0 0 8px 8px;
}
.skip-link:focus { top: 0; }
*:focus-visible { outline: 2px solid var(--oro); outline-offset: 3px; }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* === TYPOGRAPHY === */
h1, h2, h3 { font-family: var(--font-display); font-weight: 600; line-height: 1.06; }
.pill {
  display: inline-block; font-family: var(--font-body);
  font-size: .7rem; font-weight: 600; letter-spacing: .2em; text-transform: uppercase;
  padding: .5rem .9rem; border: 1px solid currentColor; border-radius: 100px;
}

/* === LAYOUT === */
.wrap { max-width: var(--maxw); margin: 0 auto; padding-left: var(--pad); padding-right: var(--pad); }
.section { padding-top: clamp(3.5rem, 8vw, 7rem); padding-bottom: clamp(3.5rem, 8vw, 7rem); position: relative; }
.section--light { background: var(--sabbia); color: var(--grigio); }
.section--ottanio { background: var(--ottanio); color: var(--sabbia); }
.section--deep { background: var(--ottanio-deep); color: var(--sabbia); }
.section--ink { background: var(--ottanio-ink); color: var(--sabbia); }
.lp-h2 {
  font-family: var(--font-display); font-weight: 600; line-height: 1.05;
  letter-spacing: -.005em; font-size: clamp(2rem, 5vw, 3.6rem);
}
.body-text { font-size: 1.06rem; line-height: 1.65; }

/* === BUTTONS === */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .55rem;
  font-family: var(--font-body); font-size: .9rem; font-weight: 600;
  letter-spacing: .02em; padding: 1.05rem 2rem; border-radius: 100px;
  transition: background-color .3s var(--ease), color .3s var(--ease), transform .25s var(--ease), border-color .3s var(--ease);
  white-space: nowrap; min-height: 48px;
}
.btn .arrow { transition: transform .3s var(--ease); }
.btn:hover .arrow { transform: translateX(.3rem); }
.btn--primary { background: var(--oro); color: var(--ottanio-ink); }
.btn--primary:hover { background: #dcb43a; transform: translateY(-1px); }
.btn--solid { background: var(--ottanio); color: var(--bianco); }
.btn--solid:hover { background: var(--ottanio-deep); }
.btn--line { border: 1px solid rgba(244,241,234,.5); color: var(--sabbia); }
.btn--line:hover { background: rgba(244,241,234,.1); border-color: var(--sabbia); }
.btn--ghost { border: 1px solid rgba(14,92,99,.4); color: var(--ottanio); }
.btn--ghost:hover { background: var(--ottanio); color: var(--bianco); border-color: var(--ottanio); }
.btn--gesso { background: var(--sabbia); color: var(--ottanio-ink); }
.btn--gesso:hover { background: var(--oro); }

/* === HEADER minimale (logo + lingua) === */
.lp-head {
  position: absolute; top: 0; left: 0; right: 0; z-index: 5;
  display: flex; align-items: center; justify-content: space-between;
  padding: 1rem var(--pad);
}
.lp-head__logo { display: flex; align-items: center; }
.lp-head__logo img { height: 30px; width: auto; }
.lp-head .lang-switch { display: flex; gap: .4rem; align-items: center; font-size: .76rem; font-weight: 600; letter-spacing: .08em; color: var(--sabbia); }
.lp-head .lang-switch a { opacity: .55; display: inline-flex; align-items: center; min-height: 44px; padding: 0 .35rem; }
.lp-head .lang-switch a.active { opacity: 1; }
.lp-head .lang-switch .sep { opacity: .35; }

/* === HERO === */
.lp-hero { position: relative; min-height: 92svh; display: flex; align-items: flex-end; overflow: hidden; background: var(--ottanio-ink); }
.lp-hero img.lp-hero__img, .lp-hero video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.lp-hero::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(6,41,45,.42) 0%, rgba(6,41,45,.5) 45%, rgba(6,41,45,.9) 100%); z-index: 1; }
.lp-hero__inner { position: relative; z-index: 2; width: 100%; padding-bottom: clamp(2.5rem, 6vw, 4.5rem); padding-top: calc(var(--header-h) + 2rem); }
.lp-hero h1 {
  color: var(--bianco); font-family: var(--font-display); font-weight: 600;
  line-height: 1; letter-spacing: -.01em; font-size: clamp(2.7rem, 7vw, 5.4rem); max-width: 16ch;
}
.lp-hero__sub { color: rgba(244,241,234,.92); font-size: clamp(1.05rem, 2.2vw, 1.45rem); max-width: 40ch; margin-top: 1.1rem; line-height: 1.4; }
.lp-hero__sub b { color: var(--bianco); font-weight: 600; }

/* === TRUST ROW === */
.lp-trust { display: flex; flex-wrap: wrap; align-items: center; gap: .55rem 1.3rem; margin-top: 1.7rem; color: var(--sabbia); font-size: .95rem; }
.lp-trust b { color: var(--bianco); }
.lp-trust .stars { color: var(--oro); letter-spacing: .08em; }
.lp-trust .dot { width: 5px; height: 5px; border-radius: 50%; background: rgba(244,241,234,.4); display: inline-block; }
.lp-trust .open-now { display: inline-flex; align-items: center; gap: .45rem; }
.lp-trust .open-now::before { content: ''; width: 9px; height: 9px; border-radius: 50%; background: #43c463; box-shadow: 0 0 0 3px rgba(67,196,99,.25); }
.lp-trust .open-now.is-closed::before { background: #d99a3a; box-shadow: 0 0 0 3px rgba(217,154,58,.22); }

/* === CTA ROW === */
.lp-cta-row { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 2rem; }
.lp-call { color: var(--sabbia); align-self: center; font-size: .95rem; opacity: .9; }
.lp-call a { text-decoration: underline; text-underline-offset: 3px; font-weight: 600; }

/* === CUCINA DI MARE (cards) === */
.lp-cucina { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(.9rem, 2vw, 1.4rem); margin-top: 2.4rem; }
.lp-cucina__item { position: relative; aspect-ratio: 4/5; border-radius: 14px; overflow: hidden; }
.lp-cucina__item img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.lp-cucina__item:hover img { transform: scale(1.05); }
.lp-cucina__cap { position: absolute; left: 0; right: 0; bottom: 0; padding: 2rem 1.1rem 1rem; color: #fff; background: linear-gradient(180deg, transparent, rgba(6,41,45,.88)); }
.lp-cucina__cap strong { display: block; font-family: var(--font-display); font-size: 1.35rem; font-weight: 600; line-height: 1.1; }
.lp-cucina__cap span { font-size: .86rem; opacity: .85; }

/* === GALLERY === */
.lp-gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(.6rem, 1.4vw, 1rem); margin-top: 2.4rem; }
.lp-gallery__item { position: relative; aspect-ratio: 1/1; border-radius: 10px; overflow: hidden; }
.lp-gallery__item img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.lp-gallery__item:hover img { transform: scale(1.06); }
.lp-gallery__item--wide { grid-column: span 2; aspect-ratio: 2/1; }

/* === DOVE SIAMO (mappa + orari) === */
.lp-find { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(1.5rem, 4vw, 3.5rem); align-items: center; }
.lp-find__map { aspect-ratio: 4/3; border-radius: 16px; overflow: hidden; box-shadow: 0 24px 60px -22px rgba(6,41,45,.5); background: var(--ottanio-deep); }
.lp-find__map iframe { width: 100%; height: 100%; border: 0; display: block; }
.lp-map-facade { width: 100%; height: 100%; border: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .55rem; cursor: pointer; background: var(--ottanio-deep); color: var(--sabbia); font-family: var(--font-body); transition: background .25s var(--ease); }
.lp-map-facade svg { width: 40px; height: 40px; fill: var(--oro); }
.lp-map-facade strong { font-weight: 600; letter-spacing: .02em; font-size: 1rem; }
.lp-map-facade small { opacity: .75; font-size: .85rem; }
.lp-map-facade:hover { background: var(--ottanio-ink); }
.lp-find__addr .big { font-family: var(--font-display); font-size: clamp(1.7rem, 3.5vw, 2.4rem); line-height: 1.12; display: block; margin-bottom: .5rem; color: var(--bianco); }
.lp-find__addr p { color: rgba(244,241,234,.85); font-size: 1.04rem; line-height: 1.65; max-width: 42ch; }
.lp-hours { margin: 1.5rem 0; display: grid; grid-template-columns: auto 1fr; gap: .35rem 1.4rem; font-size: 1rem; max-width: 360px; }
.lp-hours dt { color: rgba(244,241,234,.92); } .lp-hours dd { text-align: right; color: var(--bianco); }
.lp-hours .closed { color: rgba(244,241,234,.78); }
.lp-ferie { font-size: .9rem; color: rgba(244,241,234,.85); margin-top: -.4rem; margin-bottom: 1.2rem; }

/* === GOOGLE REVIEWS SLIDER (riuso reviews.js) === */
.gslider { margin-top: 1.5rem; }
.gslider__badge { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; margin-bottom: 1.5rem; font-family: var(--font-body); }
.gslider__stars { color: var(--oro); letter-spacing: 2px; }
.gslider__badge strong { font-size: 1.15rem; color: var(--ottanio-ink); }
.gslider__count { color: #5a6261; }
.gslider__all { margin-left: auto; color: var(--ottanio); text-decoration: underline; text-underline-offset: 3px; font-weight: 600; }
.gslider__viewport { position: relative; }
.gslider__track { display: flex; gap: 24px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: .75rem; scrollbar-width: thin; -webkit-overflow-scrolling: touch; }
.review { background: var(--bianco); border: 1px solid var(--sabbia-warm); border-radius: 14px; padding: 1.5rem 1.6rem; }
.gslider__track .gslider__card { flex: 0 0 min(420px, 85%); scroll-snap-align: start; margin: 0; }
.review__stars { color: var(--oro); letter-spacing: 2px; margin-bottom: .6rem; }
.review__quote { font-size: 1.02rem; line-height: 1.55; color: var(--grigio); margin-bottom: .9rem; }
.review__who { font-size: .85rem; color: var(--ottanio); font-style: normal; opacity: 1; }
.gslider__btn { position: absolute; top: 50%; transform: translateY(-50%); width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--ottanio); background: var(--bianco); color: var(--ottanio); font-size: 1.5rem; line-height: 1; cursor: pointer; display: none; z-index: 2; }
.gslider__btn--prev { left: -12px; }
.gslider__btn--next { right: -12px; }
@media (hover: hover) and (min-width: 768px) { .gslider__btn { display: block; } }

/* === FAQ === */
.lp-faq { max-width: 760px; margin: 2.2rem auto 0; }
.lp-faq details { border-bottom: 1px solid rgba(14,92,99,.18); padding: .3rem 0; }
.lp-faq summary { cursor: pointer; list-style: none; padding: 1.1rem 2rem 1.1rem 0; font-family: var(--font-display); font-size: 1.25rem; font-weight: 600; color: var(--ottanio-ink); position: relative; }
.lp-faq summary::-webkit-details-marker { display: none; }
.lp-faq summary::after { content: '+'; position: absolute; right: 0; top: 50%; transform: translateY(-50%); font-size: 1.5rem; color: var(--ottanio); transition: transform .25s var(--ease); }
.lp-faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.lp-faq p { padding: 0 0 1.2rem; color: var(--grigio); line-height: 1.6; }

/* === FINAL CTA === */
.lp-final { text-align: center; }
.lp-final h2 { color: var(--bianco); }
.lp-final .lead { color: rgba(244,241,234,.92); margin: 1rem auto 0; max-width: 34ch; font-size: 1.1rem; }
.lp-final .lp-cta-row { justify-content: center; }

/* === FOOTER === */
.lp-foot { background: var(--ottanio-ink); color: rgba(244,241,234,.7); font-size: .82rem; padding: 2.2rem var(--pad); text-align: center; line-height: 1.9; }
.lp-foot a { color: rgba(244,241,234,.9); text-decoration: underline; text-underline-offset: 2px; }

/* === STICKY MOBILE CTA — z-index 1400 (sotto cookie banner 1500) === */
.lp-sticky { position: fixed; left: 0; right: 0; bottom: 0; z-index: 1400; display: none; gap: .5rem; padding: .6rem .7rem calc(.6rem + env(safe-area-inset-bottom)); background: var(--ottanio-ink); border-top: 1px solid rgba(201,162,39,.35); }
.lp-sticky a { flex: 1 1 0; padding: 1rem .8rem; font-size: .82rem; min-height: 48px; }
.lp-sticky.is-hidden { display: none !important; }

/* === COOKIE BANNER (riuso consent.js, palette ottanio) === */
[data-cookie-banner] {
  position: fixed; bottom: clamp(.85rem, 2vw, 1.5rem); right: clamp(.85rem, 2vw, 1.5rem); left: auto;
  width: min(400px, calc(100vw - 1.7rem)); background: var(--ottanio-ink); color: var(--sabbia);
  padding: 1.4rem 1.5rem 1.45rem; border: 1px solid rgba(201,162,39,.2); border-radius: 16px;
  box-shadow: 0 24px 64px -16px rgba(0,0,0,.5); z-index: 1500; font-family: var(--font-body);
  font-size: .85rem; line-height: 1.6; animation: cookieSlideUp .5s cubic-bezier(.16,1,.3,1) both;
}
@keyframes cookieSlideUp { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: translateY(0); } }
@keyframes cookieFadeIn { from { opacity: 0; } to { opacity: 1; } }
[data-cookie-banner] h3 { color: var(--bianco); font-family: var(--font-display); font-weight: 600; letter-spacing: .01em; }
[data-cookie-banner] p { color: rgba(244,241,234,.82); }
[data-cookie-banner] a { color: var(--oro); text-underline-offset: 2px; }
[data-cookie-banner] .cb-actions { display: flex; flex-wrap: wrap; gap: .55rem; }
[data-cookie-banner] button { padding: .68rem 1.15rem; font-weight: 600; font-family: var(--font-body); font-size: .82rem; border: 0; border-radius: 9px; cursor: pointer; transition: background .2s var(--ease), border-color .2s var(--ease), transform .15s var(--ease); }
[data-cookie-banner] .btn-accept { background: var(--oro); color: var(--ottanio-ink); flex: 1 1 100%; order: -1; }
[data-cookie-banner] .btn-accept:hover { background: #dcb43a; transform: translateY(-1px); }
[data-cookie-banner] .btn-reject { background: transparent; color: var(--sabbia); border: 1px solid rgba(244,241,234,.28); flex: 1 1 auto; }
[data-cookie-banner] .btn-reject:hover { border-color: var(--sabbia); background: rgba(244,241,234,.06); }
[data-cookie-banner] .btn-customize { background: transparent; color: rgba(244,241,234,.72); text-decoration: underline; font-weight: 500; padding-left: .4rem; padding-right: .4rem; flex: 0 0 auto; }
[data-cookie-banner] .btn-customize:hover { color: var(--sabbia); }
[data-cookie-banner] .close-x { position: absolute; top: .55rem; right: .7rem; font-size: 1.35rem; line-height: 1; background: transparent; border: 0; color: var(--sabbia); opacity: .5; cursor: pointer; padding: .2rem .35rem; transition: opacity .2s; }
[data-cookie-banner] .close-x:hover { opacity: 1; }

/* === RESPONSIVE === */
@media (max-width: 900px) {
  .lp-find { grid-template-columns: 1fr; }
  .lp-cucina { grid-template-columns: 1fr; }
  .lp-gallery { grid-template-columns: repeat(2, 1fr); }
  .lp-gallery__item--wide { grid-column: span 2; aspect-ratio: 2/1; }
  .lp-sticky { display: flex; }
  body { padding-bottom: 4.6rem; }
}
@media (max-width: 520px) {
  [data-cookie-banner] { left: 0; right: 0; bottom: 0; width: 100%; border-radius: 16px 16px 0 0; padding: 1.3rem 1.15rem calc(1.3rem + env(safe-area-inset-bottom)); }
  [data-cookie-banner] .btn-reject { flex: 1 1 100%; }
  [data-cookie-banner] .btn-customize { flex: 1 1 100%; padding: .5rem; }
  .lp-cta-row { gap: .6rem; }
  .lp-call { flex: 1 1 100%; margin-top: .2rem; }
}
@media (prefers-reduced-motion: reduce) {
  .lp-cucina__item img, .lp-gallery__item img { transition: none; }
  [data-cookie-banner] { animation: none; }
  html { scroll-behavior: auto; }
}
