/* ============================================
   BRIVIDO — Gelateria Artigianale
   Modern site with real photography
   ============================================ */

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

:root {
  --bg: #fdf6ee;
  --bg-soft: #fbeadb;
  --cream: #fff9f1;
  --ink: #2a1c14;
  --ink-soft: #6b574a;
  --rose: #ff8aa3;
  --rose-deep: #e84f6e;
  --peach: #ffb088;
  --pistachio: #b9d4a3;
  --mint: #cfe9d6;
  --butter: #ffe6a3;
  --accent: var(--rose-deep);

  --radius-sm: 14px;
  --radius-md: 22px;
  --radius-lg: 32px;
  --radius-pill: 999px;

  --shadow-sm: 0 6px 18px rgba(45, 22, 10, 0.06);
  --shadow-md: 0 18px 40px rgba(45, 22, 10, 0.08);
  --shadow-lg: 0 30px 60px rgba(45, 22, 10, 0.12);

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}

html { scroll-behavior: smooth; }
html, body { background: var(--bg); }

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  color: var(--ink);
  line-height: 1.6;
  overflow-x: hidden;
  background:
    radial-gradient(1200px 600px at 80% -10%, rgba(255, 138, 163, 0.22), transparent 60%),
    radial-gradient(900px 500px at -10% 40%, rgba(255, 230, 163, 0.30), transparent 60%),
    radial-gradient(800px 500px at 110% 70%, rgba(207, 233, 214, 0.35), transparent 60%),
    var(--bg);
}

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

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
  position: relative;
  z-index: 1;
}

/* ============================================
   Custom cursor (desktop only)
   ============================================ */
.cursor {
  position: fixed;
  top: 0; left: 0;
  width: 32px; height: 32px;
  border-radius: 50%;
  background: var(--rose);
  pointer-events: none;
  z-index: 9999;
  mix-blend-mode: multiply;
  transform: translate(-50%, -50%);
  transition: width .25s var(--ease-out), height .25s var(--ease-out), background .2s;
  display: none;
}
.cursor.active {
  width: 64px; height: 64px;
  background: var(--peach);
}
@media (hover: hover) and (pointer: fine) {
  .cursor { display: block; }
  body { cursor: none; }
  a, button, .card, .magnetic { cursor: none; }
}

/* ============================================
   Navbar
   ============================================ */
.navbar {
  position: sticky;
  top: 16px;
  z-index: 50;
  margin: 16px 16px 0;
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 14px 24px;
  background: rgba(255, 249, 241, 0.72);
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  border: 1px solid rgba(45, 22, 10, 0.06);
  border-radius: var(--radius-pill);
  box-shadow: var(--shadow-sm);
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--ink);
  font-family: 'Fraunces', serif;
}
.logo-mark {
  display: inline-grid;
  place-items: center;
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--bg-soft);
  font-weight: 800;
  font-size: 18px;
  transform: rotate(-6deg);
  transition: transform .3s var(--ease-spring);
}
.logo:hover .logo-mark { transform: rotate(8deg) scale(1.06); }
.logo-text {
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}
.logo-text i {
  color: var(--rose-deep);
  font-style: normal;
}

.navbar nav {
  display: flex;
  gap: 28px;
}
.navbar nav a {
  color: var(--ink);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  position: relative;
  padding: 4px 0;
  transition: color .2s;
}
.navbar nav a::after {
  content: "";
  position: absolute;
  left: 0; bottom: -2px;
  width: 0; height: 2px;
  background: var(--rose-deep);
  border-radius: 2px;
  transition: width .25s var(--ease-out);
}
.navbar nav a:hover { color: var(--rose-deep); }
.navbar nav a:hover::after { width: 100%; }

.nav-cta {
  padding: 10px 20px;
  background: var(--ink);
  color: var(--cream);
  border-radius: var(--radius-pill);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  transition: transform .25s var(--ease-spring), background .2s;
}
.nav-cta:hover {
  background: var(--rose-deep);
  transform: translateY(-2px);
}

/* ============================================
   Hero
   ============================================ */
.hero {
  position: relative;
  padding: 60px 0;
  min-height: 90vh;
  display: flex;
  align-items: center;
}
.hero-inner {
  width: 100%;
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 80px;
  align-items: center;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 16px;
  background: var(--cream);
  border: 1px solid rgba(45, 22, 10, 0.08);
  border-radius: var(--radius-pill);
  font-size: 0.85rem;
  font-weight: 500;
  margin-bottom: 28px;
  box-shadow: var(--shadow-sm);
}
.badge-dot {
  width: 8px; height: 8px;
  background: #4caf50;
  border-radius: 50%;
  box-shadow: 0 0 0 0 rgba(76, 175, 80, 0.5);
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(76, 175, 80, 0.5); }
  70% { box-shadow: 0 0 0 10px rgba(76, 175, 80, 0); }
  100% { box-shadow: 0 0 0 0 rgba(76, 175, 80, 0); }
}

.hero-title {
  font-family: 'Fraunces', serif;
  font-size: clamp(2.4rem, 5.8vw, 4.6rem);
  line-height: 1;
  letter-spacing: -0.03em;
  font-weight: 600;
  margin-bottom: 24px;
  max-width: 18ch;
}
.hero-title span {
  display: block;
}
.hero-title .italic {
  font-style: italic;
  font-weight: 400;
  color: var(--rose-deep);
}
.hero-title .dot {
  color: var(--rose-deep);
  font-style: normal;
}

.hero-sub {
  font-size: clamp(1.05rem, 1.4vw, 1.2rem);
  color: var(--ink-soft);
  max-width: 52ch;
  margin-bottom: 36px;
}

.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 48px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 30px;
  border-radius: var(--radius-pill);
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
  transition: transform .3s var(--ease-spring), box-shadow .3s, background .25s, color .25s;
  border: none;
  cursor: pointer;
}
.btn-primary {
  background: var(--ink);
  color: var(--cream);
}
.btn-primary:hover {
  background: var(--rose-deep);
  transform: translateY(-3px);
  box-shadow: 0 14px 30px rgba(232, 79, 110, 0.35);
}
.btn-primary svg { transition: transform .3s var(--ease-spring); }
.btn-primary:hover svg { transform: translateX(4px); }

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border: 1.5px solid rgba(45, 22, 10, 0.18);
}
.btn-ghost:hover {
  background: var(--ink);
  color: var(--cream);
  border-color: var(--ink);
  transform: translateY(-3px);
}

.hero-stats {
  display: flex;
  gap: 40px;
  flex-wrap: wrap;
  border-top: 1px solid rgba(45, 22, 10, 0.1);
  padding-top: 28px;
  max-width: 560px;
}
.stat strong {
  font-family: 'Fraunces', serif;
  font-size: 2.1rem;
  font-weight: 600;
  display: block;
  line-height: 1;
  color: var(--ink);
}
.stat span {
  font-size: 0.85rem;
  color: var(--ink-soft);
  margin-top: 4px;
  display: block;
}

/* Hero photo */
.hero-photo {
  position: relative;
  aspect-ratio: 4 / 5;
  max-width: 520px;
  margin-left: auto;
  border-radius: var(--radius-lg);
  overflow: visible;
  animation: photo-float 8s ease-in-out infinite;
}
.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: var(--radius-lg);
  box-shadow: 0 30px 60px rgba(45, 22, 10, 0.22);
}
@keyframes photo-float {
  0%, 100% { transform: translateY(0) rotate(0); }
  50%      { transform: translateY(-12px) rotate(-0.5deg); }
}
.hero-photo::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg, rgba(255, 138, 163, 0.0), rgba(255, 138, 163, 0.15));
  z-index: 1;
  pointer-events: none;
}

.hero-photo-badge {
  position: absolute;
  top: 20px;
  left: -28px;
  background: var(--cream);
  border-radius: var(--radius-pill);
  padding: 12px 18px 12px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: var(--shadow-lg);
  z-index: 2;
  animation: badge-bob 4s ease-in-out infinite;
}
@keyframes badge-bob {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-6px); }
}
.badge-emoji {
  width: 36px; height: 36px;
  background: var(--butter);
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 18px;
}
.hero-photo-badge strong {
  font-family: 'Fraunces', serif;
  font-size: 1.15rem;
  display: block;
  line-height: 1;
}
.hero-photo-badge small {
  font-size: 0.78rem;
  color: var(--ink-soft);
}

.hero-photo-tag {
  position: absolute;
  bottom: 24px;
  right: -22px;
  background: var(--ink);
  color: var(--cream);
  padding: 10px 18px;
  border-radius: var(--radius-pill);
  font-size: 0.85rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  box-shadow: var(--shadow-lg);
  z-index: 2;
  animation: badge-bob 4s ease-in-out infinite reverse;
}
.tag-dot {
  width: 8px; height: 8px;
  background: var(--rose);
  border-radius: 50%;
  box-shadow: 0 0 0 0 rgba(255, 138, 163, 0.6);
  animation: pulse 2s infinite;
}

.scroll-hint {
  position: absolute;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  width: 28px;
  height: 44px;
  border: 2px solid rgba(45, 22, 10, 0.22);
  border-radius: 14px;
  display: grid;
  place-items: start center;
  padding-top: 8px;
}
.scroll-hint span {
  width: 4px; height: 8px;
  background: var(--ink);
  border-radius: 2px;
  animation: scroll-bob 1.6s ease-in-out infinite;
}
@keyframes scroll-bob {
  0%   { transform: translateY(0); opacity: 1; }
  60%  { transform: translateY(14px); opacity: 0; }
  100% { transform: translateY(0); opacity: 1; }
}

/* ============================================
   Marquee
   ============================================ */
.marquee {
  overflow: hidden;
  border-top: 1px solid rgba(45, 22, 10, 0.08);
  border-bottom: 1px solid rgba(45, 22, 10, 0.08);
  background: var(--ink);
  color: var(--cream);
  padding: 20px 0;
  font-family: 'Fraunces', serif;
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  font-style: italic;
  font-weight: 400;
}
.marquee-track {
  display: inline-flex;
  gap: 32px;
  white-space: nowrap;
  animation: marquee 30s linear infinite;
  padding-left: 32px;
}
.marquee-track span:nth-child(even) {
  color: var(--rose);
}
@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* ============================================
   Sections
   ============================================ */
.section {
  padding: 120px 0;
  position: relative;
}

.section-head {
  margin-bottom: 64px;
  max-width: 720px;
}
.section-head.center {
  text-align: center;
  margin-left: auto;
  margin-right: auto;
}
.eyebrow {
  display: inline-block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--rose-deep);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 16px;
}
h2 {
  font-family: 'Fraunces', serif;
  font-size: clamp(2.2rem, 5vw, 3.8rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  font-weight: 600;
  margin-bottom: 16px;
}
h2 .italic {
  font-style: italic;
  font-weight: 400;
  color: var(--rose-deep);
}
.lead {
  font-size: 1.1rem;
  color: var(--ink-soft);
  max-width: 56ch;
}

/* ============================================
   Gusti grid
   ============================================ */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 28px;
}
.card {
  --tilt-x: 0deg;
  --tilt-y: 0deg;
  background: var(--cream);
  border-radius: var(--radius-lg);
  padding: 0;
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(45, 22, 10, 0.06);
  box-shadow: var(--shadow-sm);
  transform-style: preserve-3d;
  transform: perspective(900px) rotateX(var(--tilt-x)) rotateY(var(--tilt-y));
  transition: box-shadow .4s var(--ease-out), border-color .3s;
}
.card:hover {
  box-shadow: var(--shadow-lg);
  border-color: var(--accent);
}

.card-art {
  width: 100%;
  height: 240px;
  overflow: hidden;
  position: relative;
}
.card-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .8s var(--ease-out);
}
.card:hover .card-art img { transform: scale(1.08); }
.card-art::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 50%, color-mix(in srgb, var(--accent) 35%, transparent));
  opacity: 0;
  transition: opacity .4s var(--ease-out);
}
.card:hover .card-art::after { opacity: 1; }

.card-body {
  padding: 24px 26px 26px;
}
.card-body h3 {
  font-family: 'Fraunces', serif;
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}
.card-body p {
  font-size: 0.95rem;
  color: var(--ink-soft);
  margin-bottom: 18px;
}
.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px dashed rgba(45, 22, 10, 0.12);
  padding-top: 14px;
}
.card-meta span:first-child {
  font-weight: 600;
  color: var(--ink);
}
.tag {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 10px;
  background: color-mix(in srgb, var(--accent) 14%, transparent);
  color: var(--accent);
  border-radius: var(--radius-pill);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.gusti-foot {
  text-align: center;
  margin-top: 48px;
  color: var(--ink-soft);
  font-style: italic;
}

/* ============================================
   Esperienza (chi siamo)
   ============================================ */
.two-col {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 80px;
  align-items: center;
}
.esperienza-text p {
  color: var(--ink-soft);
  font-size: 1.05rem;
  margin-bottom: 18px;
  max-width: 56ch;
}

.features {
  margin-top: 32px;
  display: grid;
  gap: 18px;
}
.feature {
  display: flex;
  gap: 18px;
  align-items: flex-start;
}
.feature-ic {
  width: 48px; height: 48px;
  background: var(--cream);
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: var(--rose-deep);
  flex-shrink: 0;
  box-shadow: var(--shadow-sm);
}
.feature h4 {
  font-family: 'Fraunces', serif;
  font-size: 1.15rem;
  margin-bottom: 2px;
}
.feature p { font-size: 0.92rem; color: var(--ink-soft); }

/* Esperienza art collage */
.esperienza-art {
  position: relative;
  height: 560px;
}
.art-card {
  position: absolute;
  background: var(--cream);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  border: 1px solid rgba(45, 22, 10, 0.06);
  overflow: hidden;
  transition: transform .5s var(--ease-spring);
}
.art-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.art-card-1 {
  top: 0; left: 0;
  width: 60%;
  aspect-ratio: 4 / 5;
  transform: rotate(-4deg);
}
.art-card-1:hover { transform: rotate(0deg) scale(1.03); }
.art-card-1 .art-label {
  position: absolute;
  bottom: 16px; left: 16px; right: 16px;
  background: rgba(255, 249, 241, 0.92);
  backdrop-filter: blur(10px);
  padding: 12px 16px;
  border-radius: var(--radius-md);
}
.art-card-2 {
  bottom: 40px; right: 0;
  width: 72%;
  font-style: italic;
  font-family: 'Fraunces', serif;
  font-size: 1.1rem;
  line-height: 1.4;
  padding: 28px;
  transform: rotate(3deg);
  background: var(--bg-soft);
}
.art-card-2:hover { transform: rotate(0deg) scale(1.02); }
.art-card-2 small {
  display: block;
  margin-top: 14px;
  font-family: 'Inter', sans-serif;
  font-style: normal;
  color: var(--ink-soft);
  font-size: 0.85rem;
}
.art-card-3 {
  top: 270px; left: 24px;
  width: 50%;
  aspect-ratio: 1 / 1;
  transform: rotate(6deg);
}
.art-card-3:hover { transform: rotate(0deg) scale(1.03); }
.art-card-3 .art-label {
  position: absolute;
  bottom: 14px; left: 14px; right: 14px;
  padding: 10px 14px;
  border-radius: var(--radius-md);
  background: rgba(42, 28, 20, 0.85);
  backdrop-filter: blur(8px);
  color: var(--cream);
}

.art-label strong {
  display: block;
  font-family: 'Fraunces', serif;
  font-size: 1.1rem;
  font-weight: 600;
}
.art-label span {
  font-size: 0.82rem;
  opacity: 0.85;
}

/* ============================================
   Contatti
   ============================================ */
.contacts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-bottom: 80px;
}
.contact-card {
  background: var(--cream);
  border-radius: var(--radius-lg);
  padding: 32px;
  text-decoration: none;
  color: var(--ink);
  text-align: left;
  border: 1px solid rgba(45, 22, 10, 0.06);
  box-shadow: var(--shadow-sm);
  transition: transform .3s var(--ease-spring), box-shadow .3s;
  display: block;
}
.contact-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}
.contact-ic {
  width: 52px; height: 52px;
  background: var(--bg-soft);
  border-radius: 16px;
  display: grid;
  place-items: center;
  color: var(--rose-deep);
  margin-bottom: 18px;
}
.contact-card h4 {
  font-family: 'Fraunces', serif;
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: 8px;
}
.contact-card p {
  color: var(--ink-soft);
  margin-bottom: 18px;
  line-height: 1.5;
}
.contact-link {
  font-size: 0.9rem;
  color: var(--rose-deep);
  font-weight: 600;
}

.big-cta {
  background: var(--ink);
  color: var(--cream);
  border-radius: var(--radius-lg);
  padding: 60px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.big-cta h3 {
  font-family: 'Fraunces', serif;
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  font-weight: 600;
  margin-bottom: 28px;
  letter-spacing: -0.02em;
  position: relative;
}
.big-cta .btn {
  background: var(--cream);
  color: var(--ink);
}
.big-cta .btn:hover {
  background: var(--rose);
  color: var(--ink);
}

/* ============================================
   Footer
   ============================================ */
footer {
  padding: 32px 0;
  border-top: 1px solid rgba(45, 22, 10, 0.08);
  background: var(--bg);
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 14px;
}
.footer-brand strong {
  display: block;
  font-family: 'Fraunces', serif;
  font-size: 1.1rem;
}
.footer-brand small {
  color: var(--ink-soft);
  font-size: 0.85rem;
}
.footer-meta {
  display: flex;
  gap: 10px;
  color: var(--ink-soft);
  font-size: 0.85rem;
}

/* ============================================
   Scroll reveal
   ============================================ */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition:
    opacity .8s var(--ease-out),
    transform .8s var(--ease-out);
  transition-delay: calc(var(--delay, 0) * 1ms);
}
.reveal.in {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 1024px) {
  .hero-inner { grid-template-columns: 1fr; gap: 48px; }
  .hero-photo { max-width: 460px; margin: 0 auto; }
  .hero-photo-badge { left: -10px; }
  .hero-photo-tag { right: -8px; }
  .two-col { grid-template-columns: 1fr; gap: 48px; }
  .esperienza-art { height: 480px; }
}
@media (max-width: 720px) {
  .container { padding: 0 20px; }
  .navbar { margin: 12px 8px 0; }
  .nav-inner { padding: 12px 16px; }
  .navbar nav { display: none; }
  .nav-cta { padding: 8px 16px; font-size: 0.85rem; }

  .hero { padding: 40px 0; min-height: auto; }
  .hero-photo { max-width: 100%; }
  .hero-photo-badge { left: 8px; top: 12px; padding: 10px 14px 10px 10px; }
  .hero-photo-tag { right: 8px; bottom: 16px; }
  .hero-stats { gap: 24px; }
  .stat strong { font-size: 1.6rem; }

  .section { padding: 80px 0; }

  .contacts { grid-template-columns: 1fr; }
  .big-cta { padding: 40px 24px; }

  .art-card-1, .art-card-2, .art-card-3 {
    position: relative; width: 100%;
    top: auto; left: auto; right: auto; bottom: auto;
    margin-bottom: 16px; transform: none;
    aspect-ratio: auto;
  }
  .art-card-1, .art-card-3 { height: 280px; }
  .esperienza-art { height: auto; }

  .marquee { font-size: 1.4rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}
