/* ============================================================
   Trattoria "da Ugo" — Fano
   Palette ispirata alla facciata e al logo reali del locale:
   pietra chiara, legno di botte, rosso vino, ferro battuto.
   ============================================================ */

:root{
  --cream: #f4ecdd;
  --cream-2: #ecdfc7;
  --stone: #d8c9ab;
  --wood: #a9793f;
  --wood-dark: #6b4526;
  --wine: #6f1f2c;
  --wine-dark: #4a1420;
  --wine-light: #8f3040;
  --charcoal: #201a15;
  --charcoal-2: #2c241d;
  --ink: #26190f;
  --paper: #faf5ea;
  --line: rgba(38,25,15,0.15);
  --line-light: rgba(250,245,234,0.18);

  --font-title: "Fraunces", "Iowan Old Style", Georgia, serif;
  --font-body: "Inter", "Helvetica Neue", Arial, sans-serif;

  --container: 1180px;
}

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

html{ scroll-behavior: smooth; }

body{
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.6;
  -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(--container);
  margin: 0 auto;
  padding: 0 24px;
}

.eyebrow{
  display: inline-block;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 5px;
  text-transform: uppercase;
  color: var(--wine);
  margin-bottom: 14px;
}

.eyebrow.on-dark{ color: var(--stone); }

h1, h2, h3{
  font-family: var(--font-title);
  font-weight: 700;
  line-height: 1.08;
  margin: 0 0 18px;
  color: var(--ink);
}

.section-title{
  font-size: clamp(32px, 5vw, 56px);
  letter-spacing: -0.5px;
}

.section-lede{
  max-width: 560px;
  color: rgba(38,25,15,0.68);
  font-size: 17px;
}

.section{
  position: relative;
  padding: 110px 0;
}

.section.tight{ padding: 80px 0; }

.section-head{
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 24px;
  margin-bottom: 56px;
}

.divider-line{
  width: 0;
  height: 2px;
  background: var(--wine);
  margin: 22px 0 0;
  transition: width 1.1s cubic-bezier(.16,.84,.44,1);
}
.in-view .divider-line{ width: 92px; }

/* reveal on scroll */
.reveal{
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .9s cubic-bezier(.16,.84,.44,1), transform .9s cubic-bezier(.16,.84,.44,1);
}
.reveal.in-view{ opacity: 1; transform: translateY(0); }
.reveal-d1{ transition-delay: .08s; }
.reveal-d2{ transition-delay: .16s; }
.reveal-d3{ transition-delay: .24s; }
.reveal-d4{ transition-delay: .32s; }

/* ============ TOPBAR ============ */
.topbar{
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 28px;
  transition: background .4s ease, padding .4s ease, box-shadow .4s ease;
}
.topbar::before{
  content: "";
  position: absolute;
  inset: 0;
  background: var(--paper);
  opacity: 0;
  transition: opacity .4s ease;
  z-index: -1;
  box-shadow: 0 6px 24px rgba(0,0,0,0.08);
}
.topbar.scrolled::before{ opacity: 1; }
.topbar.scrolled{ padding: 12px 28px; }

.topbar-brand{
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 20px;
  color: var(--paper);
  letter-spacing: .5px;
  transition: color .4s ease;
}
.topbar.scrolled .topbar-brand{ color: var(--ink); }
.topbar-brand span{ color: var(--wine-light); }
.topbar.scrolled .topbar-brand span{ color: var(--wine); }

.topbar-cta{
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--wine);
  color: var(--paper) !important;
  padding: 11px 22px;
  border-radius: 3px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  transition: background .25s ease, transform .25s ease;
}
.topbar-cta:hover{ background: var(--wine-dark); transform: translateY(-2px); }

/* ============ HERO ============ */
.hero{
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  background: var(--charcoal);
}
.hero-bg{
  position: absolute;
  inset: 0;
  background-image: url("img/hero-facciata.jpg");
  background-size: cover;
  background-position: center 30%;
  transform: scale(1.12);
  will-change: transform;
}
.hero-bg::after{ content: ""; }
.hero-scrim{
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(20,13,9,0.55) 0%, rgba(20,13,9,0.35) 30%, rgba(20,13,9,0.55) 65%, rgba(15,10,7,0.94) 100%);
}
.hero-inner{
  position: relative;
  z-index: 2;
  width: 100%;
  padding: 0 24px 90px;
  max-width: var(--container);
  margin: 0 auto;
  color: var(--paper);
}
.hero-logo{
  width: 108px;
  height: 108px;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid rgba(250,245,234,0.85);
  margin-bottom: 30px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.45);
  opacity: 0;
  animation: pop-in 1s cubic-bezier(.2,.9,.3,1.2) .3s forwards;
}
.hero-logo img{ width: 100%; height: 100%; object-fit: cover; }

@keyframes pop-in{
  from{ opacity: 0; transform: scale(.7) translateY(10px); }
  to{ opacity: 1; transform: scale(1) translateY(0); }
}

.hero-title{
  font-size: clamp(48px, 9vw, 108px);
  color: var(--paper);
  margin: 0 0 10px;
  letter-spacing: -1px;
}
.hero-title em{
  font-style: italic;
  color: var(--stone);
}
.hero-sub{
  font-size: clamp(15px, 1.8vw, 19px);
  color: rgba(250,245,234,0.82);
  max-width: 480px;
  margin: 0 0 40px;
  font-weight: 300;
}
.hero-ctas{
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.btn{
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 30px;
  border-radius: 3px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  transition: transform .25s ease, background .25s ease, box-shadow .25s ease;
  border: 1px solid transparent;
}
.btn-primary{
  background: var(--wine);
  color: var(--paper);
  box-shadow: 0 10px 26px rgba(111,31,44,0.4);
}
.btn-primary:hover{ background: var(--wine-light); transform: translateY(-3px); }
.btn-outline{
  border-color: rgba(250,245,234,0.5);
  color: var(--paper);
}
.btn-outline:hover{ border-color: var(--paper); background: rgba(250,245,234,0.08); transform: translateY(-3px); }

.hero-scrollcue{
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  color: rgba(250,245,234,0.65);
  font-size: 11px;
  letter-spacing: 3px;
  text-transform: uppercase;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.hero-scrollcue::after{
  content: "";
  width: 1px;
  height: 34px;
  background: rgba(250,245,234,0.5);
  animation: cue 1.8s ease-in-out infinite;
}
@keyframes cue{
  0%{ transform: scaleY(0); transform-origin: top; opacity: 0; }
  50%{ transform: scaleY(1); transform-origin: top; opacity: 1; }
  51%{ transform-origin: bottom; }
  100%{ transform: scaleY(0); transform-origin: bottom; opacity: 0; }
}

/* ============ MARQUEE STRIP ============ */
.marquee{
  background: var(--wine);
  color: var(--paper);
  overflow: hidden;
  padding: 14px 0;
  white-space: nowrap;
}
.marquee-track{
  display: inline-flex;
  gap: 48px;
  animation: scroll-left 32s linear infinite;
}
.marquee span{
  font-family: var(--font-title);
  font-style: italic;
  font-size: 18px;
  letter-spacing: .5px;
  opacity: .95;
}
.marquee span::after{
  content: "\2022";
  margin-left: 48px;
  opacity: .6;
}
@keyframes scroll-left{
  from{ transform: translateX(0); }
  to{ transform: translateX(-50%); }
}

/* ============ STORIA ============ */
.storia{ background: var(--cream); }
.storia-grid{
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px;
  align-items: center;
}
@media(min-width: 900px){
  .storia-grid{ grid-template-columns: 0.95fr 1.05fr; gap: 70px; }
}
.storia-photo{
  position: relative;
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0 30px 60px -20px rgba(38,25,15,0.35);
}
.storia-photo img{
  width: 100%;
  aspect-ratio: 4/5;
  object-fit: cover;
  transition: transform 1.4s cubic-bezier(.16,.84,.44,1);
}
.storia-photo:hover img{ transform: scale(1.06); }
.storia-photo-tag{
  position: absolute;
  bottom: 18px;
  left: 18px;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-title);
  font-style: italic;
  font-size: 14px;
  padding: 8px 16px;
  border-radius: 2px;
}
.storia-text p{
  font-size: 17px;
  color: rgba(38,25,15,0.78);
  margin: 0 0 18px;
  max-width: 520px;
}
.storia-stats{
  display: flex;
  gap: 36px;
  margin-top: 36px;
  flex-wrap: wrap;
}
.storia-stat b{
  display: block;
  font-family: var(--font-title);
  font-size: 34px;
  color: var(--wine);
}
.storia-stat span{
  font-size: 12px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: rgba(38,25,15,0.55);
}

/* ============ MENU / GALLERY ============ */
.menu-section{ background: var(--paper); }

.mosaic{
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  grid-auto-rows: 130px;
  gap: 14px;
}
.mosaic-item{
  position: relative;
  overflow: hidden;
  border-radius: 4px;
  cursor: default;
}
.mosaic-item img{
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .8s cubic-bezier(.16,.84,.44,1), filter .8s ease;
}
.mosaic-item:hover img{ transform: scale(1.08); }
.mosaic-caption{
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 30px 18px 16px;
  background: linear-gradient(180deg, transparent, rgba(15,10,7,0.85));
  color: var(--paper);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity .4s ease, transform .4s ease;
}
.mosaic-item:hover .mosaic-caption{ opacity: 1; transform: translateY(0); }
.mosaic-caption b{ font-family: var(--font-title); font-size: 17px; display:block; }
.mosaic-caption span{ font-size: 12px; opacity: .8; }

.m1{ grid-column: span 3; grid-row: span 3; }
.m2{ grid-column: span 3; grid-row: span 2; }
.m3{ grid-column: span 2; grid-row: span 2; }
.m4{ grid-column: span 2; grid-row: span 2; }
.m5{ grid-column: span 2; grid-row: span 2; }
.m6{ grid-column: span 3; grid-row: span 2; }

@media(max-width: 860px){
  .mosaic{ grid-template-columns: repeat(2, 1fr); grid-auto-rows: 180px; }
  .m1,.m2,.m3,.m4,.m5,.m6{ grid-column: span 1; grid-row: span 2; }
  .m1{ grid-column: span 2; grid-row: span 3; }
}

.dish-list{
  margin-top: 60px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 0;
  border-top: 1px solid var(--line);
}
.dish-row{
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 20px 4px;
  border-bottom: 1px solid var(--line);
}
.dish-row b{ font-family: var(--font-title); font-size: 17px; font-weight: 600; }
.dish-row span{ font-size: 13px; color: rgba(38,25,15,0.55); }

/* ============ REVIEWS ============ */
.reviews{
  background: var(--charcoal);
  color: var(--paper);
}
.review-grid{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 28px;
  margin-top: 20px;
}
.review-card{
  background: var(--charcoal-2);
  border: 1px solid var(--line-light);
  border-radius: 6px;
  padding: 34px 28px;
  text-align: center;
}
.review-score{
  font-family: var(--font-title);
  font-size: 46px;
  color: var(--stone);
}
.review-stars{ color: var(--wine-light); letter-spacing: 3px; margin: 10px 0; font-size: 16px; }
.review-source{ font-size: 13px; letter-spacing: 1px; text-transform: uppercase; color: rgba(250,245,234,0.55); }
.review-count{ font-size: 12px; color: rgba(250,245,234,0.4); margin-top: 4px; }

/* ============ DOVE SIAMO ============ */
.map-section{ background: var(--cream-2); }
.map-grid{
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
}
@media(min-width: 900px){
  .map-grid{ grid-template-columns: 1fr 1.2fr; align-items: stretch; }
}
.map-info{
  background: var(--paper);
  border-radius: 6px;
  padding: 44px 38px;
  box-shadow: 0 20px 50px -25px rgba(38,25,15,0.4);
}
.info-row{
  display: flex;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.info-row:last-child{ border-bottom: none; }
.info-row .ico{
  width: 34px; height: 34px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--wine);
  color: var(--paper);
  display: flex; align-items: center; justify-content: center;
  font-size: 15px;
}
.info-row b{ display:block; font-size: 14px; }
.info-row span{ font-size: 14px; color: rgba(38,25,15,0.65); }
.map-frame{
  border-radius: 6px;
  overflow: hidden;
  min-height: 340px;
  filter: sepia(12%) saturate(85%);
  border: 1px solid var(--line);
}
.map-frame iframe{ width: 100%; height: 100%; min-height: 340px; border: 0; }

/* ============ CONTATTI ============ */
.contact{
  background: var(--wine-dark);
  color: var(--paper);
  text-align: center;
}
.contact .section-title{ color: var(--paper); }
.contact .section-lede{ color: rgba(250,245,234,0.75); margin: 0 auto 40px; }
.contact-ctas{ display: flex; justify-content: center; gap: 18px; flex-wrap: wrap; }

/* ============ FOOTER ============ */
footer{
  background: var(--charcoal);
  color: rgba(250,245,234,0.6);
  padding: 46px 0 30px;
  font-size: 13px;
}
.footer-inner{
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}
.footer-brand{
  font-family: var(--font-title);
  font-size: 18px;
  color: var(--paper);
}
.universe-badge{
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: rgba(250,245,234,0.55);
  transition: color .25s ease;
  font-size: 12px;
  letter-spacing: .3px;
}
.universe-badge b{ color: rgba(250,245,234,0.85); font-weight: 600; }
.universe-badge:hover{ color: var(--paper); }

@media(max-width: 600px){
  .section{ padding: 76px 0; }
  .hero-inner{ padding-bottom: 60px; }
}
