/* Bar Viscuso — landing page.
   Impaginazione: testata grande, riga di icone (mappa, telefono) su un filetto,
   quattro bottoni-scheda uno sotto l'altro: il primo, il menu, pieno in arancio.
   Identità "Aci Castello": basalto delle colonne laviche, mare Ionio, un caldo di sole
   sulla pietra. Pagina sempre scura: la roccia nera è il soggetto.
   Per cambiare i colori modifica solo i token qui sotto. */

@font-face {
  font-family: "Fraunces";
  src: url("/fonts/fraunces-latin-600-normal.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Fraunces";
  src: url("/fonts/fraunces-latin-400-italic.woff2") format("woff2");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}

:root {
  /* Basalto: la roccia su cui sta il castello */
  --basalto-900: #0a0f12;
  --basalto-800: #111a1f;
  --basalto-700: #18242a;
  --basalto-600: #22313a;
  /* Mare Ionio: dal fondale alla schiuma */
  --mare-900: #072b38;
  --mare-700: #0e5468;
  --mare-500: #2e8aa3;
  --mare-300: #6fc0d2;
  /* Luce */
  --schiuma: #e9f2f4;
  --sole: #c98a3c;

  --bg: var(--basalto-900);
  --page: var(--basalto-800);
  --text: var(--schiuma);
  --muted: #93a8b0;
  --line: #27373f;
  --accent: var(--mare-300);
  --card-from: var(--basalto-700);
  --card-to: var(--basalto-800);
  --font-display: "Fraunces", ui-serif, Georgia, serif;
  --font-body: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color-scheme: dark;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.5 var(--font-body);
  -webkit-text-size-adjust: 100%;
}

[hidden] {
  display: none !important;
}

/* Colonna centrale "da telefono", anche su desktop */
.page {
  max-width: 480px;
  min-height: 100dvh;
  margin: 0 auto;
  background: var(--page);
  display: flex;
  flex-direction: column;
  box-shadow: 0 0 80px rgb(0 0 0 / 0.6);
}

/* Testata: parete di basalto, con il bagliore del mare sotto l'orizzonte */
.hero {
  position: relative;
  overflow: hidden;
  padding: 46px 24px 52px;
  text-align: center;
  color: var(--schiuma);
  background:
    radial-gradient(120% 70% at 50% 118%, rgb(46 138 163 / 0.5), transparent 62%),
    linear-gradient(180deg, rgb(10 15 18 / 0.86), rgb(17 26 31 / 0.94)),
    url("/patterns/basalto.svg") center / 92px 92px;
  border-bottom: 1px solid var(--mare-700);
}

/* Onde che scorrono sul filo dell'orizzonte */
.hero::after {
  content: "";
  position: absolute;
  left: -120px;
  right: -120px;
  bottom: 10px;
  height: 20px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='20' viewBox='0 0 120 20'%3E%3Cpath d='M0 12q15-10 30 0t30 0 30 0 30 0' fill='none' stroke='%236fc0d2' stroke-width='2' stroke-linecap='round' opacity='.45'/%3E%3C/svg%3E") repeat-x 0 0 / 120px 20px;
  pointer-events: none;
}

/* Marchio: logo del bar (immagine 3:2 con alone dorato) */
.emblema {
  width: min(320px, 78vw);
  height: auto;
  margin: 0 auto 18px;
  display: block;
}

.hero h1 {
  margin: 0;
  font: 600 2.6rem/1.05 var(--font-display);
  letter-spacing: 0.01em;
}

.hero-sub {
  margin: 8px 0 0;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--mare-300);
}

.hero-claim {
  margin: 18px auto 0;
  max-width: 300px;
  font-size: 1.05rem;
  line-height: 1.45;
  color: #c6d6db;
}

/* Riga di icone su un filetto */
.social {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 20px;
  margin-top: -26px;
  position: relative;
  z-index: 1;
}

.social-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--sole));
}

.social-line:last-child {
  background: linear-gradient(90deg, var(--sole), transparent);
}

.social-btn {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: var(--basalto-700);
  border: 1px solid var(--line);
  box-shadow: 0 6px 18px rgb(0 0 0 / 0.5);
  color: var(--mare-300);
  transition: border-color 0.18s, color 0.18s, transform 0.18s;
}

.social-btn[href]:hover,
.social-btn[href]:focus-visible {
  border-color: var(--mare-500);
  color: var(--schiuma);
  transform: translateY(-2px);
}

.social-btn svg,
.action svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

svg .fill {
  fill: currentColor;
  stroke: none;
}

/* Bottoni-scheda */
.actions {
  list-style: none;
  margin: 0;
  padding: 32px 20px 8px;
  display: grid;
  gap: 14px;
}

.action {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px 14px 14px;
  min-height: 88px;
  border-radius: 18px;
  text-decoration: none;
  color: var(--text);
  background: linear-gradient(100deg, var(--card-from), var(--card-to));
  border: 1px solid var(--line);
  box-shadow: 0 6px 20px rgb(0 0 0 / 0.45);
  transition: transform 0.18s, box-shadow 0.18s, border-color 0.18s;
}

.action[href]:hover,
.action[href]:focus-visible {
  transform: translateY(-2px);
  border-color: var(--mare-700);
  box-shadow: 0 12px 28px rgb(0 0 0 / 0.55), 0 0 0 1px rgb(46 138 163 / 0.25);
}

.action:focus-visible,
.social-btn:focus-visible {
  outline: 2px solid var(--mare-300);
  outline-offset: 3px;
}

.action-icon {
  flex: none;
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--sole);
  background: radial-gradient(circle at 34% 28%, var(--basalto-600), var(--basalto-900));
  border: 1px solid var(--sole);
  box-shadow: inset 0 2px 8px rgb(0 0 0 / 0.5);
}

.action-icon svg {
  width: 26px;
  height: 26px;
}

.action-text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

/* Maiuscoletto spaziato tolto: a 390px "Lascia una recensione" andava a capo */
.action-text strong {
  font-size: 1.02rem;
  font-weight: 700;
  line-height: 1.3;
}

.action-text small {
  font-size: 0.85rem;
  color: var(--muted);
  line-height: 1.35;
}

.action-go {
  flex: none;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1.5px solid var(--mare-500);
  color: var(--mare-300);
}

.action-go svg {
  width: 18px;
  height: 18px;
}

/* Il menu è il motivo per cui si apre la pagina: unica scheda piena */
.action-primary {
  color: var(--basalto-900);
  background: linear-gradient(100deg, var(--sole), #b8782e);
  border-color: var(--sole);
}

.action-primary .action-text small {
  color: var(--basalto-900);
}

.action-primary .action-icon {
  background: var(--basalto-900);
  box-shadow: none;
}

.action-primary .action-go {
  border-color: var(--basalto-900);
  color: var(--basalto-900);
}

.action-primary[href]:hover,
.action-primary[href]:focus-visible {
  border-color: #e0a94a;
}

/* Link non ancora configurato */
.action.is-soon {
  opacity: 0.5;
  cursor: default;
}

.social-btn.is-soon {
  color: var(--muted);
  cursor: default;
}

.action.is-soon .action-text small {
  font-weight: 700;
  color: var(--sole);
}

.footer {
  margin-top: auto;
  padding: 28px 20px calc(20px + env(safe-area-inset-bottom));
  text-align: center;
  font-size: 0.8rem;
  color: var(--muted);
}

/* Fascia di basalto a chiudere la pagina */
.footer::before {
  content: "";
  display: block;
  height: 26px;
  margin: 0 -20px 16px;
  background: url("/patterns/basalto.svg") repeat-x center / 26px 26px;
  border-top: 1px solid var(--mare-700);
  opacity: 0.9;
}

.footer p {
  margin: 0;
}

.footer p + p {
  margin-top: 4px;
}

.footer a {
  color: inherit;
}

/* ---------------------------------------------------------------------------
   Animazioni. Tutte dentro questo blocco: chi ha chiesto al sistema operativo
   di ridurre le animazioni vede la pagina ferma, senza nessuna regola in meno.
   --------------------------------------------------------------------------- */
@media (prefers-reduced-motion: no-preference) {
  @keyframes sorgi {
    from {
      opacity: 0;
      transform: translateY(16px);
    }
    to {
      opacity: 1;
      transform: none;
    }
  }

  @keyframes affiora {
    from {
      opacity: 0;
      transform: scale(0.92);
    }
    to {
      opacity: 1;
      transform: none;
    }
  }

  /* La risacca: le onde scorrono di una piastrella intera, quindi senza scatto */
  @keyframes risacca {
    to {
      background-position-x: 120px;
    }
  }

  .emblema {
    animation: affiora 0.9s cubic-bezier(0.22, 1, 0.36, 1) both;
  }

  .hero h1,
  .hero-sub,
  .hero-claim {
    animation: sorgi 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
  }

  .hero h1 { animation-delay: 0.1s; }
  .hero-sub { animation-delay: 0.18s; }
  .hero-claim { animation-delay: 0.26s; }

  .hero::after {
    animation: risacca 11s linear infinite;
  }

}
