/* ============================================================
   PICCOLO BAR — styles.css
   Palette calda "casa piemontese": carta, legno, terracotta, oliva.
   ============================================================ */

:root {
  --paper:      #FBF6EC;
  --paper-2:    #F4EAD8;
  --paper-3:    #ECDFC7;
  --ink:        #2B2018;
  --ink-soft:   #5C4B3C;
  --ink-faint:  #8A7660;
  --wood:       #3A2418;
  --terracotta: #BC5A2E;
  --terracotta-dk: #9E4720;
  --amber:      #D98A3D;
  --olive:      #6E7045;
  --line:       rgba(58, 36, 24, 0.14);
  --shadow:     0 18px 40px -22px rgba(43, 32, 24, 0.55);
  --shadow-sm:  0 8px 22px -14px rgba(43, 32, 24, 0.5);
  --radius:     14px;
  --maxw:       1150px;
  --serif:      'Fraunces', Georgia, 'Times New Roman', serif;
  --sans:       'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

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

html { scroll-behavior: smooth; scroll-padding-top: 84px; }

body {
  font-family: var(--sans);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.65;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

/* ---------- Tipografia ---------- */
.h2 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(1.9rem, 4vw, 2.9rem);
  line-height: 1.12;
  letter-spacing: -0.01em;
  color: var(--wood);
}
.h3 { font-family: var(--serif); font-weight: 600; font-size: 1.5rem; color: var(--wood); line-height: 1.2; }
.eyebrow {
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--terracotta);
  margin-bottom: 14px;
}
.lead { font-size: 1.12rem; color: var(--ink-soft); max-width: 56ch; }

/* ---------- Bottoni ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--sans);
  font-weight: 600;
  font-size: 0.98rem;
  padding: 14px 28px;
  border-radius: 999px;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: transform .2s ease, background .2s ease, color .2s ease, box-shadow .2s ease;
  white-space: nowrap;
}
.btn-sm { padding: 9px 18px; font-size: 0.9rem; }
.btn-solid { background: var(--terracotta); color: var(--paper); box-shadow: var(--shadow-sm); }
.btn-solid:hover { background: var(--terracotta-dk); transform: translateY(-2px); }
.btn-ghost { background: transparent; color: var(--paper); border-color: rgba(251, 246, 236, 0.55); }
.btn-ghost:hover { background: rgba(251, 246, 236, 0.14); border-color: var(--paper); transform: translateY(-2px); }

/* ============================================================
   HEADER
   ============================================================ */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  transition: background .35s ease, box-shadow .35s ease, padding .35s ease;
  padding: 18px 0;
}
/* Scrim per leggibilità del menu sopra l'hero chiaro */
.site-header::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 140px;
  background: linear-gradient(180deg, rgba(20, 12, 6, 0.55), rgba(20, 12, 6, 0));
  pointer-events: none;
  z-index: -1;
  opacity: 1;
  transition: opacity .35s ease;
}
.site-header.scrolled::before { opacity: 0; }
.site-header.scrolled {
  background: rgba(251, 246, 236, 0.92);
  backdrop-filter: blur(10px);
  box-shadow: 0 1px 0 var(--line);
  padding: 10px 0;
}
.header-inner { display: flex; align-items: center; justify-content: space-between; }

.brand { display: flex; align-items: center; gap: 11px; }
.brand-mark {
  display: grid; place-items: center;
  width: 38px; height: 38px;
  background: var(--terracotta);
  color: var(--paper);
  font-family: var(--serif);
  font-weight: 700;
  font-size: 1.3rem;
  border-radius: 10px;
  flex: none;
}
.brand-text {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.35rem;
  color: var(--paper);
  transition: color .35s ease;
  letter-spacing: -0.01em;
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.35);
}
.scrolled .brand-text { color: var(--wood); text-shadow: none; }

.brand-logo { height: 54px; width: auto; display: block; transition: height .35s ease; }
.scrolled .brand-logo { height: 42px; }
.brand-logo .pic { fill: #E8A45C; }
.brand-logo .bar { fill: #FBF6EC; }
.scrolled .brand-logo .pic { fill: #9E4720; }
.scrolled .brand-logo .bar { fill: #3A2418; }

.nav { display: flex; align-items: center; gap: 30px; }
.nav > a:not(.btn) {
  font-weight: 500;
  font-size: 0.98rem;
  color: var(--paper);
  position: relative;
  transition: color .25s ease, opacity .25s ease;
  opacity: 0.96;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.3);
}
.scrolled .nav > a:not(.btn) { text-shadow: none; }
.nav > a:not(.btn)::after {
  content: ""; position: absolute; left: 0; bottom: -6px;
  width: 0; height: 2px; background: var(--terracotta);
  transition: width .25s ease;
}
.nav > a:not(.btn):hover::after { width: 100%; }
.scrolled .nav > a:not(.btn) { color: var(--ink); opacity: 1; }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none; border: none; cursor: pointer;
  padding: 8px;
}
.nav-toggle span {
  width: 26px; height: 2.5px; border-radius: 2px;
  background: var(--paper);
  transition: transform .3s ease, opacity .3s ease, background .35s ease;
}
.scrolled .nav-toggle span { background: var(--wood); }

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.hero-bg {
  position: absolute; inset: 0;
  background-size: cover;
  background-position: center 60%;
  transform: scale(1.05);
  animation: heroZoom 14s ease-out forwards;
}
@keyframes heroZoom { to { transform: scale(1); } }
.hero-overlay {
  position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(30,18,10,0.55) 0%, rgba(30,18,10,0.22) 35%, rgba(30,18,10,0.62) 100%);
}
.hero-content { position: relative; z-index: 2; color: var(--paper); padding-top: 60px; padding-bottom: 60px; }
.hero-kicker {
  font-size: 0.85rem; letter-spacing: 0.28em; text-transform: uppercase;
  font-weight: 600; color: var(--amber); margin-bottom: 22px;
}
.hero-title {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(3.4rem, 11vw, 8rem);
  line-height: 0.95;
  letter-spacing: -0.02em;
  text-shadow: 0 14px 40px rgba(0,0,0,0.35);
}
.hero-sub {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(1.25rem, 3vw, 1.9rem);
  margin: 22px 0 36px;
  line-height: 1.3;
  color: #F3E6D2;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }

.scroll-cue {
  position: absolute; bottom: 28px; left: 50%; transform: translateX(-50%);
  z-index: 2;
  width: 26px; height: 42px;
  border: 2px solid rgba(251,246,236,0.6);
  border-radius: 14px;
  display: grid; place-items: start center;
  padding-top: 8px;
}
.scroll-cue span {
  width: 4px; height: 8px; border-radius: 2px; background: var(--paper);
  animation: scrollDot 1.6s ease-in-out infinite;
}
@keyframes scrollDot { 0%,100% { opacity: .3; transform: translateY(0);} 50% { opacity: 1; transform: translateY(8px);} }

/* ============================================================
   SEZIONI — generale + reveal
   ============================================================ */
.section { padding: clamp(64px, 9vw, 120px) 0; }
.section-head { max-width: 660px; margin: 0 auto clamp(40px, 6vw, 64px); text-align: center; }
.section-head .eyebrow { margin-bottom: 14px; }
.section-head .lead { margin: 18px auto 0; }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(36px, 6vw, 80px); align-items: center; }

.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ---------- Storia ---------- */
.storia { background: var(--paper); }
.storia-text p { margin-top: 18px; color: var(--ink-soft); }
.storia-text .h2 { margin-bottom: 6px; }
.storia-quote {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.18rem;
  color: var(--wood);
  border-left: 3px solid var(--terracotta);
  padding-left: 20px;
  margin-top: 26px !important;
}
.storia-img { position: relative; }
.storia-img img {
  width: 100%; aspect-ratio: 4/5; object-fit: cover;
  border-radius: var(--radius); box-shadow: var(--shadow);
}
.storia-img figcaption {
  font-family: var(--serif); font-style: italic;
  text-align: center; color: var(--ink-faint);
  margin-top: 14px; font-size: 0.98rem;
}

/* ---------- Merenda ---------- */
.merenda { background: var(--paper-2); }
.merenda-feature {
  display: grid; grid-template-columns: 0.85fr 1fr; gap: clamp(28px, 5vw, 56px);
  align-items: center;
  margin-bottom: clamp(44px, 6vw, 70px);
}
.merenda-feature figure { overflow: hidden; border-radius: var(--radius); box-shadow: var(--shadow); }
.merenda-feature img { width: 100%; aspect-ratio: 4/5; object-fit: cover; transition: transform .9s ease; }
.merenda-feature:hover img { transform: scale(1.04); }
.merenda-feature-text .h3 { margin-bottom: 12px; }
.merenda-feature-text p { color: var(--ink-soft); }

.dish-grid {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.dish {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px 24px 22px;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
  position: relative;
}
.dish::before {
  content: ""; position: absolute; top: 24px; left: 24px;
  width: 26px; height: 2px; background: var(--terracotta); border-radius: 2px;
  opacity: .8;
}
.dish h4 { font-family: var(--serif); font-weight: 600; font-size: 1.2rem; color: var(--wood); margin: 18px 0 6px; }
.dish p { font-size: 0.97rem; color: var(--ink-soft); }
.dish:hover { transform: translateY(-4px); box-shadow: var(--shadow-sm); border-color: transparent; }
.dish-feature { background: var(--wood); border-color: var(--wood); }
.dish-feature::before { background: var(--amber); }
.dish-feature h4 { color: var(--paper); }
.dish-feature p { color: var(--paper-3); }
.dish-feature em { color: var(--amber); font-style: italic; }

/* ---------- Cantina ---------- */
.cantina { background: var(--wood); }
.cantina .eyebrow { color: var(--amber); }
.cantina .h2 { color: var(--paper); }
.cantina-text .h2 { margin-bottom: 6px; }
.cantina-text p { margin-top: 18px; color: var(--paper-3); }
.cantina-img img {
  width: 100%; aspect-ratio: 4/5; object-fit: cover; object-position: center 22%;
  border-radius: var(--radius); box-shadow: var(--shadow);
}
.cantina-points { list-style: none; margin: 22px 0 4px; display: grid; gap: 12px; }
.cantina-points li {
  position: relative; padding-left: 30px;
  color: var(--paper); font-family: var(--serif); font-size: 1.18rem;
}
.cantina-points li::before {
  content: ""; position: absolute; left: 0; top: 0.62em;
  width: 16px; height: 2px; background: var(--amber);
}

/* ---------- Prezzo ---------- */
.price-card {
  margin-top: clamp(40px, 6vw, 64px);
  background: var(--wood);
  color: var(--paper);
  border-radius: var(--radius);
  padding: clamp(34px, 5vw, 52px);
  text-align: center;
  box-shadow: var(--shadow);
}
.price-eyebrow {
  font-size: 0.78rem; letter-spacing: 0.22em; text-transform: uppercase;
  font-weight: 600; color: var(--amber); margin-bottom: 24px;
}
.price-rows { display: flex; align-items: center; justify-content: center; gap: clamp(30px, 7vw, 70px); }
.price-row { display: flex; flex-direction: column; gap: 6px; }
.price-num {
  font-family: var(--serif); font-weight: 600;
  font-size: clamp(2.8rem, 8vw, 4.2rem); line-height: 1; color: var(--paper);
}
.price-lbl { font-size: 0.95rem; color: var(--paper-3); letter-spacing: 0.02em; }
.price-divider { width: 1px; height: 64px; background: rgba(251, 246, 236, 0.22); }
.price-note { margin-top: 26px; color: var(--paper-3); font-size: 1.02rem; line-height: 1.55; }

/* ---------- Galleria ---------- */
.galleria { background: var(--paper); }
.masonry { columns: 3; column-gap: 16px; }
.masonry-item {
  break-inside: avoid;
  margin-bottom: 16px;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  position: relative;
}
.masonry-item img { width: 100%; transition: transform .6s ease, filter .4s ease; }
.masonry-item::after {
  content: ""; position: absolute; inset: 0;
  background: rgba(58,36,24,0); transition: background .35s ease;
}
.masonry-item:hover img { transform: scale(1.05); }
.masonry-item:hover::after { background: rgba(58,36,24,0.12); }

/* ---------- Testimonianza ---------- */
.testimonial { background: var(--wood); }
.quote-card { max-width: 760px; margin: 0 auto; text-align: center; color: var(--paper); }
.quote-pull {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(1.8rem, 4.5vw, 2.9rem);
  line-height: 1.15;
  color: var(--amber);
  margin-bottom: 30px;
}
.quote-body p { color: var(--paper-3); margin-top: 16px; font-size: 1.05rem; }
.quote-body p:first-child { margin-top: 0; }
.quote-body strong { color: var(--paper); }
.quote-author {
  margin-top: 28px;
  font-family: var(--serif); font-style: italic;
  color: var(--ink-faint);
  font-size: 1rem;
}

/* ---------- Recensioni ---------- */
.recensioni { background: var(--paper); }
.reviews { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; }
.review-card {
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 30px 26px;
  display: flex; flex-direction: column; gap: 14px;
  transition: transform .25s ease, box-shadow .25s ease;
}
.review-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-sm); }
.stars { color: var(--amber); font-size: 1.15rem; letter-spacing: 3px; }
.stars .star-empty { color: rgba(58, 36, 24, 0.22); }
.review-card blockquote {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.12rem;
  line-height: 1.5;
  color: var(--wood);
}
.review-card figcaption { margin-top: auto; padding-top: 6px; }
.rev-name { display: block; font-weight: 600; color: var(--ink); }
.rev-meta { display: block; font-size: 0.85rem; color: var(--ink-faint); }

/* ---------- Prenota ---------- */
.prenota { background: var(--wood); }
.prenota .eyebrow { color: var(--amber); }
.prenota .h2 { color: var(--paper); }
.prenota .lead { color: var(--paper-3); }
.booking { max-width: 680px; margin: 0 auto; }
.bk-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.bk-field { display: flex; flex-direction: column; gap: 7px; margin-bottom: 16px; }
.bk-field > span { font-size: 0.82rem; letter-spacing: 0.03em; color: var(--paper-3); font-weight: 500; }
.bk-field small { color: rgba(251, 246, 236, 0.5); font-weight: 400; }
.bk-field input, .bk-field select {
  font-family: var(--sans); font-size: 1rem; color: var(--wood);
  background: var(--paper); border: 1.5px solid transparent; border-radius: 10px;
  padding: 13px 14px; width: 100%; -webkit-appearance: none; appearance: none;
}
.bk-field input::placeholder { color: var(--ink-faint); }
.bk-field input:focus, .bk-field select:focus { outline: none; border-color: var(--amber); }
.bk-note { margin-bottom: 22px; }
.bk-submit { width: 100%; font-size: 1.05rem; padding: 16px; }
.bk-hint { text-align: center; margin-top: 13px; font-size: 0.85rem; color: rgba(251, 246, 236, 0.5); }
@media (max-width: 560px) { .bk-grid { grid-template-columns: 1fr; } }

/* ---------- Dove ---------- */
.dove { background: var(--paper-2); }
.info-list { list-style: none; margin: 28px 0 32px; }
.info-list li { padding: 18px 0; border-bottom: 1px solid var(--line); }
.info-list li:first-child { border-top: 1px solid var(--line); }
.info-label {
  display: block; font-size: 0.76rem; letter-spacing: 0.18em; text-transform: uppercase;
  font-weight: 600; color: var(--terracotta); margin-bottom: 4px;
}
.info-value { font-size: 1.1rem; color: var(--wood); font-weight: 500; }
.info-value a:hover { color: var(--terracotta); }
.info-value small { color: var(--ink-faint); font-weight: 400; }

.dove-map { position: relative; height: 100%; min-height: 340px; }
.map-link {
  position: absolute;
  bottom: 14px; right: 14px;
  background: var(--paper);
  color: var(--wood);
  font-weight: 600; font-size: 0.85rem;
  padding: 9px 15px;
  border-radius: 999px;
  box-shadow: var(--shadow-sm);
  transition: background .2s ease, color .2s ease, transform .2s ease;
}
.map-link:hover { background: var(--terracotta); color: var(--paper); transform: translateY(-2px); }
.map-placeholder, .dove-map iframe {
  width: 100%; height: 100%; min-height: 340px;
  border: 0; border-radius: var(--radius); box-shadow: var(--shadow);
}
.map-placeholder {
  display: grid; place-content: center; justify-items: center; gap: 10px;
  background:
    repeating-linear-gradient(45deg, var(--paper-3) 0 16px, var(--paper) 16px 32px);
  color: var(--ink-faint); text-align: center;
}

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer { background: #20140C; color: var(--paper-3); padding: 56px 0 26px; }
.footer-inner { display: flex; flex-wrap: wrap; gap: 30px; justify-content: space-between; align-items: center; }
.footer-brand { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.footer-logo { width: 170px; height: auto; flex: none; }
.footer-name { font-family: var(--serif); font-weight: 600; font-size: 1.3rem; color: var(--paper); }
.footer-tag { font-family: var(--serif); font-style: italic; color: var(--ink-faint); font-size: 0.97rem; }
.footer-addr { font-size: 0.85rem; color: var(--ink-faint); margin-top: 8px; }
.footer-addr a { color: var(--paper-3); }
.footer-addr a:hover { color: var(--amber); }
.footer-links { display: flex; flex-wrap: wrap; gap: 22px; }
.footer-links a { font-size: 0.96rem; color: var(--paper-3); transition: color .2s ease; }
.footer-links a:hover { color: var(--amber); }
.footer-credit {
  text-align: center; margin-top: 40px;
  font-size: 0.85rem; color: rgba(251,246,236,0.4);
  border-top: 1px solid rgba(251,246,236,0.1); padding-top: 22px;
}

/* ============================================================
   LIGHTBOX
   ============================================================ */
.lightbox {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(20, 12, 6, 0.92);
  display: none; align-items: center; justify-content: center;
  padding: 30px;
}
.lightbox.open { display: flex; }
.lb-img {
  max-width: min(92vw, 1000px); max-height: 88vh;
  border-radius: 8px; box-shadow: 0 30px 70px rgba(0,0,0,0.6);
  animation: lbIn .3s ease;
}
@keyframes lbIn { from { opacity: 0; transform: scale(.96);} to { opacity:1; transform: none;} }
.lb-close, .lb-nav {
  position: absolute; background: rgba(251,246,236,0.12); color: var(--paper);
  border: none; cursor: pointer; border-radius: 999px;
  display: grid; place-items: center; transition: background .2s ease;
}
.lb-close { top: 22px; right: 26px; width: 46px; height: 46px; font-size: 2rem; line-height: 1; }
.lb-nav { top: 50%; transform: translateY(-50%); width: 54px; height: 54px; font-size: 2.2rem; line-height: 1; }
.lb-prev { left: 24px; }
.lb-next { right: 24px; }
.lb-close:hover, .lb-nav:hover { background: rgba(251,246,236,0.28); }

/* ============================================================
   MOBILE NAV PANEL
   ============================================================ */
@media (max-width: 860px) {
  .nav {
    position: fixed; inset: 0 0 0 auto;
    width: min(78vw, 320px);
    background: var(--paper);
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: 26px;
    padding: 40px;
    transform: translateX(100%);
    transition: transform .35s cubic-bezier(.4,0,.2,1);
    box-shadow: -20px 0 50px -20px rgba(0,0,0,0.4);
  }
  .nav.open { transform: none; }
  .nav > a:not(.btn) { color: var(--ink) !important; font-size: 1.2rem; opacity: 1; }
  .nav-cta { align-self: stretch; }
  .nav-toggle { display: flex; z-index: 101; }
  .nav-toggle.open span { background: var(--wood); }
  .nav-toggle.open span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
  .nav-toggle.open span:nth-child(2) { opacity: 0; }
  .nav-toggle.open span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 960px) {
  .dish-grid { grid-template-columns: repeat(2, 1fr); }
  .masonry { columns: 2; }
}
@media (max-width: 760px) {
  body { font-size: 16px; }
  .grid-2 { grid-template-columns: 1fr; }
  .merenda-feature { grid-template-columns: 1fr; }
  .reviews { grid-template-columns: 1fr; }
  .storia-img { order: -1; }
  .storia-img img { aspect-ratio: 16/11; }
  .merenda-feature img { aspect-ratio: 16/11; }
}
@media (max-width: 480px) {
  .dish-grid { grid-template-columns: 1fr; }
  .masonry { columns: 1; }
  .hero-actions .btn { flex: 1; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; }
}
