/* ==========================================================================
   Ristorante Pizzeria Pino Smeraldino — San Lazzaro di Savena
   Direction: "verace napoletana, smeraldo" — nome = smeraldo (verde), sala
   napoletana (murale di Piazza del Plebiscito). Canvas avorio-tovaglia,
   UNICO accento smeraldo + bande profonde smeraldo. DM Serif Display + Manrope.
   Dials: VARIANCE 6 / MOTION 3 (solo CSS) / DENSITY 4. Mobile-first (390px).
   ========================================================================== */

:root {
  --bg: #f7f3ea;            /* avorio-tovaglia (canvas) */
  --surface: #fdfbf5;       /* card / superfici chiare */
  --band-cream: #efe8d8;    /* banda alternata crema */
  --ink: #1a231d;           /* verde-carbone (testo) */
  --muted: #515a4c;         /* salvia-grigio (secondario, AA su avorio) */
  --line: #e0d8c6;          /* filetti su avorio */

  --emerald: #0e6146;       /* UNICO accento: CTA, link, filetti */
  --emerald-deep: #0c4a35;  /* bande profonde: hero, firme, footer */
  --on-emerald: #f7f3ea;    /* testo avorio sopra lo smeraldo */
  --on-emerald-dim: #c6d7c8;/* secondario pallido sopra lo smeraldo */
  --emerald-line: #2c6a52;  /* filetti dentro le bande smeraldo */

  --font-display: "DM Serif Display", "Playfair Display", Georgia, serif;
  --font-body: "Manrope", -apple-system, "Segoe UI", system-ui, sans-serif;
  --radius: 14px;
  --measure: 64ch;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

* { box-sizing: border-box; margin: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; height: auto;}

a { color: var(--emerald); text-underline-offset: 3px; }

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: 0.005em;
}
h2 { font-size: clamp(1.9rem, 5vw, 2.7rem); }
h3 { font-size: 1.3rem; }

.serif-i { font-style: italic; }

/* -- shared layout ---------------------------------------------------------- */
.wrap { max-width: 1080px; margin-inline: auto; padding-inline: 1.25rem; }
.measure { max-width: var(--measure); }

.section { padding-block: clamp(3.4rem, 8vw, 5.75rem); }
.eyebrow {
  font-size: 0.72rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.2em;
  color: var(--emerald);
}
.lead { color: var(--muted); max-width: 58ch; margin-top: 0.9rem; font-size: 1.075rem; }

/* -- buttons ---------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  text-decoration: none; font-weight: 600; font-size: 0.98rem;
  padding: 0.72rem 1.4rem; border-radius: 999px;
  border: 1.5px solid transparent;
  transition: transform 0.25s var(--ease), background-color 0.25s var(--ease),
              border-color 0.25s var(--ease), color 0.25s var(--ease);
}
.btn:active { transform: translateY(1px); }

/* on ivory canvas */
.btn-primary { background: var(--emerald); color: var(--on-emerald); }
.btn-primary:hover { background: #0a5038; transform: translateY(-2px); }
.btn-ghost { background: transparent; color: var(--emerald); border-color: var(--emerald); }
.btn-ghost:hover { background: var(--emerald); color: var(--on-emerald); transform: translateY(-2px); }

/* on emerald band */
.btn-cream { background: var(--on-emerald); color: var(--emerald-deep); }
.btn-cream:hover { background: #fffdf7; transform: translateY(-2px); }
.btn-outline { background: transparent; color: var(--on-emerald); border-color: rgba(247,243,234,0.55); }
.btn-outline:hover { border-color: var(--on-emerald); background: rgba(247,243,234,0.1); transform: translateY(-2px); }

.btn svg { width: 1em; height: 1em; }

/* -- topbar ----------------------------------------------------------------- */
.topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; justify-content: space-between; align-items: center;
  gap: 1rem;
  padding: 0.7rem 1.25rem;
  background: color-mix(in srgb, var(--bg) 90%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.brand {
  font-family: var(--font-display); font-size: 1.32rem; color: var(--ink);
  text-decoration: none; letter-spacing: 0.01em;
}
.brand span { color: var(--emerald); }
.topbar .btn { padding: 0.5rem 1.1rem; font-size: 0.9rem; }

/* -- emerald band (hero, firme, footer share this substrate) ---------------- */
.band { background: var(--emerald-deep); color: var(--on-emerald); }
.band h2, .band h3 { color: var(--on-emerald); }
.band .eyebrow { color: #7fc9a4; }

/* -- hero ------------------------------------------------------------------- */
.hero { padding-block: clamp(3.2rem, 10vw, 5.5rem) clamp(3rem, 9vw, 5rem); }
.hero-inner { max-width: 800px; }
.hero h1 {
  font-size: clamp(3rem, 12vw, 5.6rem);
  margin: 0.7rem 0 0;
  line-height: 0.98;
}
.hero h1 .of { display: block; font-size: 0.6em; color: var(--on-emerald-dim); font-style: italic; letter-spacing: 0.01em; }
.hero-sub {
  color: var(--on-emerald-dim);
  font-size: clamp(1.05rem, 2.6vw, 1.25rem);
  max-width: 47ch; margin: 1.3rem 0 0; line-height: 1.5;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 2rem; }

/* -- showcase full-bleed image ---------------------------------------------- */
.showcase { background: var(--emerald-deep); }
.showcase img {
  width: 100%; height: clamp(240px, 52vw, 520px); object-fit: cover;
  object-position: center 42%;
}

/* -- story (split) ---------------------------------------------------------- */
.story-grid { display: grid; gap: 2.2rem; align-items: start; }
.story-figs { display: grid; gap: 0.85rem; }
.story-figs img { width: 100%; height: auto; border-radius: var(--radius); box-shadow: 0 18px 40px rgba(26,35,29,0.14); }
.story-figs .big { aspect-ratio: 4 / 3; object-fit: cover; }
.story-figs .wide { aspect-ratio: 16 / 10; object-fit: cover; object-position: center 45%; }
.figcap { font-size: 0.85rem; color: var(--muted); margin-top: 0.15rem; }
.stat-row {
  display: flex; flex-wrap: wrap; gap: 1.6rem 2.4rem;
  margin-top: 1.9rem; padding-top: 1.6rem; border-top: 1px solid var(--line);
}
.stat b { display: block; font-family: var(--font-display); font-size: 1.9rem; color: var(--emerald); line-height: 1; }
.stat span { font-size: 0.9rem; color: var(--muted); }

/* -- firme (signature pizzas, on emerald band) ------------------------------ */
.firme-grid { display: grid; gap: 1.6rem; margin-top: 2.1rem; align-items: stretch; }
.firme-cards { display: grid; gap: 1.1rem; }
.firma {
  background: var(--surface); color: var(--ink);
  border-radius: var(--radius); padding: 1.5rem 1.5rem 1.35rem;
}
.firma-top { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; }
.firma h3 { color: var(--ink); font-size: 1.65rem; }
.firma .price { font-family: var(--font-display); color: var(--emerald); font-size: 1.4rem; font-variant-numeric: tabular-nums; }
.firma p { color: var(--muted); margin-top: 0.5rem; font-size: 0.98rem; }
.firme-photo img {
  width: 100%; height: 100%; min-height: 240px; object-fit: cover;
  border-radius: var(--radius);
}
.firme-note { color: var(--on-emerald-dim); font-size: 0.9rem; margin-top: 1.4rem; }

/* -- carta (menu) ----------------------------------------------------------- */
.carta-grid { display: grid; gap: 2.4rem 3rem; margin-top: 2.2rem; }
.carta-cat { break-inside: avoid; }
.carta-cat h3 {
  color: var(--emerald); font-size: 1.35rem;
  padding-bottom: 0.55rem; border-bottom: 2px solid var(--line);
  margin-bottom: 0.7rem;
}
.dish { padding: 0.55rem 0; }
.dish + .dish { border-top: 1px solid var(--line); }
.dish-head { display: flex; justify-content: space-between; align-items: baseline; gap: 0.8rem; }
.dish-name { font-weight: 600; color: var(--ink); }
.dish-price { color: var(--emerald); font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.dish-desc { color: var(--muted); font-size: 0.9rem; margin-top: 0.1rem; }
.carta-note {
  margin-top: 2.4rem; padding: 1.1rem 1.3rem; border-radius: var(--radius);
  background: var(--band-cream); color: var(--muted); font-size: 0.92rem;
}
.carta-note strong { color: var(--ink); }

/* -- contact (orari & dove) ------------------------------------------------- */
.info-grid { display: grid; gap: 2.2rem; margin-top: 2rem; }
.hours { width: 100%; border-collapse: collapse; }
.hours td { padding: 0.5rem 0; border-bottom: 1px solid var(--line); }
.hours td:last-child { text-align: right; color: var(--muted); font-variant-numeric: tabular-nums; }
.hours tr.today td { color: var(--emerald); font-weight: 700; }
.contact-lines { line-height: 1.9; }
.contact-lines a { font-weight: 600; }
.contact-actions { display: flex; flex-wrap: wrap; gap: 0.7rem; margin-top: 1.4rem; }
.addr { color: var(--muted); font-style: normal; display: block; margin-bottom: 0.4rem; }

/* -- footer ----------------------------------------------------------------- */
.footer { padding-block: clamp(2.6rem, 6vw, 3.4rem); }
.footer-top { display: grid; gap: 1.4rem; }
.footer .brand { color: var(--on-emerald); font-size: 1.5rem; }
.footer .brand span { color: #7fc9a4; }
.footer p { color: var(--on-emerald-dim); font-size: 0.92rem; }
.footer a { color: var(--on-emerald); font-weight: 600; }
.footer-meta {
  margin-top: 2rem; padding-top: 1.4rem; border-top: 1px solid var(--emerald-line);
  display: flex; flex-wrap: wrap; gap: 0.4rem 1.2rem; justify-content: space-between;
  color: var(--on-emerald-dim); font-size: 0.85rem;
}
.demo-note { opacity: 0.85; }

/* -- entrance motion (MOTION 3, CSS only, respects reduced-motion) ---------- */
@media (prefers-reduced-motion: no-preference) {
  .fade-up { opacity: 0; transform: translateY(16px); animation: fadeUp 0.7s var(--ease) forwards; }
  .d1 { animation-delay: 0.06s; }
  .d2 { animation-delay: 0.14s; }
  .d3 { animation-delay: 0.22s; }
  @keyframes fadeUp { to { opacity: 1; transform: none; } }
}

/* ==========================================================================
   RESPONSIVE — scale up from mobile
   ========================================================================== */
@media (min-width: 720px) {
  .story-grid { grid-template-columns: 1fr 1fr; gap: 3rem; }
  .firme-grid { grid-template-columns: 1.05fr 0.95fr; }
  .carta-grid { grid-template-columns: 1fr 1fr; }
  .info-grid { grid-template-columns: 1.1fr 0.9fr; gap: 3rem; }
  .footer-top { grid-template-columns: 1fr auto; align-items: end; }
}

@media (min-width: 1000px) {
  .hero { padding-block: 6rem 5.5rem; }
}
