/* ============================================
   IL GELATIERE ALBA — Prototipo CSS
   Mobile-first, responsive, elegante
   ============================================ */

/* Font */
@font-face {
  font-family: 'Hind';
  src: url('../assets/Hind-Semibold.ttf') format('truetype');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

/* Variabili */
:root {
  --rosa: #b06f66;
  --rosa-hover: #9a5e56;
  --rosa-light: #c9938b;
  --arancione: #db864a;
  --viola: #9569a0;
  --verde: #9cb244;
  --crema: #faf7f2;
  --crema-scuro: #faf7f2;
  --bianco: #ffffff;
  --testo: #3d3232;
  --testo-light: #7a6b6b;
  --grigio: #d4ccc8;
  --grigio-light: #ece8e4;
  --ombra: 0 2px 12px rgba(120, 80, 70, 0.1);
  --ombra-forte: 0 4px 24px rgba(120, 80, 70, 0.15);
  --raggio: 12px;
  --raggio-grande: 20px;
  --transizione: all 0.3s ease;
  --font: 'Hind', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* Reset */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font);
  font-weight: 600;
  color: var(--testo);
  background-color: var(--crema);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

a {
  color: inherit;
  text-decoration: none;
}

/* Container */
.container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ============================================
   BOTTONI
   ============================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px 32px;
  border: none;
  border-radius: var(--raggio);
  font-family: var(--font);
  font-weight: 600;
  font-size: 1.05rem;
  cursor: pointer;
  transition: var(--transizione);
  text-align: center;
  min-height: 52px;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

.btn-primary {
  background-color: var(--rosa);
  color: var(--bianco);
  box-shadow: 0 4px 16px rgba(176, 111, 102, 0.3);
}

.btn-primary:hover {
  background-color: var(--rosa-hover);
  box-shadow: 0 6px 20px rgba(176, 111, 102, 0.4);
  transform: translateY(-2px);
}

.btn-primary:active {
  transform: translateY(0);
}

.btn-secondary {
  background-color: transparent;
  color: var(--rosa);
  border: 2px solid var(--rosa);
}

.btn-secondary:hover {
  background-color: var(--rosa);
  color: var(--bianco);
}

.btn-whatsapp {
  background-color: #25d366;
  color: var(--bianco);
  box-shadow: 0 4px 16px rgba(37, 211, 102, 0.3);
}

.btn-whatsapp:hover {
  background-color: #1fb855;
  transform: translateY(-2px);
}

.btn-sm {
  padding: 10px 20px;
  font-size: 0.9rem;
  min-height: 44px;
}

.btn-lg {
  padding: 20px 40px;
  font-size: 1.2rem;
  border-radius: var(--raggio-grande);
}

.btn-block {
  width: 100%;
}

.btn-ghost {
  background: transparent;
  color: var(--testo-light);
  border: none;
  text-decoration: underline;
}

.btn-ghost:hover {
  color: var(--rosa);
}

/* ============================================
   CARD
   ============================================ */

.card {
  background: var(--bianco);
  border-radius: var(--raggio);
  padding: 24px;
  box-shadow: var(--ombra);
  transition: var(--transizione);
}

.card:hover {
  box-shadow: var(--ombra-forte);
}

.card-selectable {
  cursor: pointer;
  border: 2px solid transparent;
}

.card-selectable.selected {
  border-color: var(--rosa);
  box-shadow: 0 0 0 3px rgba(176, 111, 102, 0.2);
}

.card-selectable.selected::after {
  content: '✓';
  position: absolute;
  top: 12px;
  right: 12px;
  width: 28px;
  height: 28px;
  background: var(--rosa);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
}

/* ============================================
   BADGE
   ============================================ */

.badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
}

.badge-rosa { background: rgba(176,111,102,0.12); color: var(--rosa); }
.badge-arancione { background: rgba(219,134,74,0.12); color: var(--arancione); }
.badge-viola { background: rgba(149,105,160,0.12); color: var(--viola); }
.badge-verde { background: rgba(156,178,68,0.12); color: var(--verde); }
.badge-grigio { background: var(--grigio-light); color: var(--testo-light); }
.badge-vegan { background: rgba(74,140,63,0.1); color: #4a8c3f; display: inline-flex; align-items: center; gap: 3px; }

/* ============================================
   HERO (Landing)
   ============================================ */

.hero {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px 20px 100px;
  background: var(--crema);
}

.hero-logo {
  width: 280px;
  max-width: 80vw;
  margin-bottom: 24px;
}

.hero-subtitle {
  font-size: 1.2rem;
  color: var(--rosa);
  margin-bottom: 4px;
  letter-spacing: 0.5px;
}

.hero-location {
  font-size: 0.95rem;
  color: var(--testo-light);
  margin-bottom: 6px;
}

.hero-address {
  font-size: 0.85rem;
  color: var(--testo-light);
  margin-bottom: 32px;
}

.hero .btn-primary {
  animation: pulse 2.5s ease-in-out infinite;
}

/* Messaggio salta la coda nell'hero */
.hero-salta-coda {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 16px;
}

.hero-salta-coda span {
  font-family: 'Hind', sans-serif;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--verde);
}

.hero-nav {
  display: flex;
  align-items: flex-start;
  gap: 0;
  margin-top: 40px;
}

.hero-nav-icon-link {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.hero-nav-icon-link svg {
  opacity: 0.5;
}

.hero-nav-link {
  font-size: 0.85rem;
  color: var(--testo-light);
  padding: 8px 12px;
  transition: var(--transizione);
  letter-spacing: 0.3px;
}

.hero-nav-link:hover {
  color: var(--rosa);
}

.hero-nav-sep {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--grigio);
  flex-shrink: 0;
}

/* ============================================
   SEZIONE COME FUNZIONA
   ============================================ */

.section {
  padding: 60px 20px;
  scroll-margin-top: 20px;
}

.section-alt {
  background: var(--bianco);
}

#come-funziona {
  padding: 60px 10px;
}

#come-funziona .container {
  padding: 0 4px;
}

.section-title {
  text-align: center;
  font-size: 1.6rem;
  color: var(--testo);
  margin-bottom: 40px;
}

.steps {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-width: 800px;
  margin: 0 auto;
  padding: 0 4px;
}

.step-card {
  margin-left: 0;
  margin-right: 0;
}

.step-card {
  display: flex;
  align-items: center;
  gap: 20px;
  background: var(--crema);
  border-radius: var(--raggio);
  padding: 24px;
  border-left: 4px solid transparent;
}

.step-card:nth-child(1) { border-left-color: var(--arancione); }
.step-card:nth-child(2) { border-left-color: var(--viola); }
.step-card:nth-child(3) { border-left-color: var(--verde); }

.step-icon {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.step-card:nth-child(1) .step-icon { background: rgba(219,134,74,0.12); color: var(--arancione); }
.step-card:nth-child(2) .step-icon { background: rgba(149,105,160,0.12); color: var(--viola); }
.step-card:nth-child(3) .step-icon { background: rgba(156,178,68,0.12); color: var(--verde); }

.step-icon svg {
  width: 28px;
  height: 28px;
}

.step-icon-illustration {
  width: 120px;
  height: 120px;
  background: none;
  overflow: hidden;
}

.step-icon-illustration img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.step-text h3 {
  font-size: 1.1rem;
  margin-bottom: 4px;
}

.step-text p {
  font-size: 0.9rem;
  color: var(--testo-light);
}

.steps-note {
  text-align: center;
  margin-top: 24px;
  font-size: 0.85rem;
  color: var(--testo-light);
}

/* ============================================
   GRIGLIA GUSTI
   ============================================ */

.gusti-category {
  margin-bottom: 16px;
  font-size: 0.85rem;
  color: var(--testo-light);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Nascondi categorie nello step 2 ordine */
.gusto-substep .gusti-category {
  display: none;
}

.gusti-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}

.gusto-card {
  background: var(--bianco);
  border-radius: var(--raggio);
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: var(--ombra);
  transition: var(--transizione);
}

.gusto-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--ombra-forte);
}

.gusto-dot {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  flex-shrink: 0;
}

.gusto-name {
  font-size: 0.95rem;
  font-weight: 600;
}

/* Card con foto gusto */
.gusto-card-photo {
  cursor: pointer;
  position: relative;
}

.gusto-card-photo:hover {
  border: 1px solid var(--rosa-light);
}

.gusto-camera {
  position: absolute;
  top: 8px;
  right: 8px;
  color: var(--rosa-light);
  opacity: 0.6;
  transition: var(--transizione);
}

.gusto-card-photo:hover .gusto-camera {
  opacity: 1;
  color: var(--rosa);
}

/* Lightbox */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(0, 0, 0, 0.8);
  align-items: center;
  justify-content: center;
  padding: 20px;
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}

.lightbox.active {
  display: flex;
}

.lightbox-close {
  position: absolute;
  top: 16px;
  right: 20px;
  width: 44px;
  height: 44px;
  border: none;
  background: rgba(255, 255, 255, 0.15);
  color: white;
  font-size: 2rem;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transizione);
  line-height: 1;
}

.lightbox-close:hover {
  background: rgba(255, 255, 255, 0.3);
}

.lightbox-content {
  text-align: center;
  animation: fadeInUp 0.3s ease;
}

.lightbox-img {
  max-width: 90vw;
  max-height: 70vh;
  border-radius: var(--raggio-grande);
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.4);
}

.lightbox-caption {
  color: white;
  font-size: 1.2rem;
  font-weight: 600;
  margin-top: 16px;
  letter-spacing: 0.5px;
}

/* ============================================
   CTA RIDONDANTE
   ============================================ */

/* Salta la coda — messaggio chiave homepage */
.salta-coda-section {
  padding: 24px 20px 8px;
}

.salta-coda-text {
  font-family: 'Hind', sans-serif;
  font-weight: 600;
  font-size: 1.2rem;
  color: var(--verde);
  margin: 0;
}

.cta-section {
  text-align: center;
  padding: 50px 20px;
  background: var(--crema);
}

.cta-section h2 {
  font-size: 1.4rem;
  color: var(--testo);
  margin-bottom: 20px;
}

/* ============================================
   FOOTER / CONTATTI
   ============================================ */

.footer {
  background: var(--rosa);
  color: var(--bianco);
  padding: 32px 20px;
  text-align: center;
}

.footer-contacts {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
}

.footer-contact-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 1rem;
  color: var(--bianco);
}

.footer-contact-item svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.footer-contact-item a {
  color: var(--bianco);
  text-decoration: none;
  border-bottom: 1px solid rgba(255,255,255,0.3);
}

.footer-contact-item a:hover {
  border-bottom-color: var(--bianco);
}

.footer-social {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-bottom: 24px;
}

.footer-social a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255,255,255,0.15);
  color: var(--bianco);
  transition: var(--transizione);
}

.footer-social a:hover {
  background: rgba(255,255,255,0.3);
  transform: translateY(-2px);
}

.footer-social svg {
  width: 22px;
  height: 22px;
}

.footer-copy {
  font-size: 0.8rem;
  opacity: 0.7;
}

/* ============================================
   STICKY CTA (solo mobile)
   ============================================ */

.sticky-cta {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 12px 20px;
  padding-bottom: calc(12px + env(safe-area-inset-bottom));
  background: var(--bianco);
  box-shadow: 0 -4px 20px rgba(0,0,0,0.1);
  z-index: 100;
  transform: translateY(100%);
  transition: transform 0.3s ease;
}

.sticky-cta.visible {
  transform: translateY(0);
}

.sticky-cta .btn {
  width: 100%;
}

/* ============================================
   BACK TO TOP
   ============================================ */

.back-to-top {
  position: fixed;
  bottom: 90px;
  right: 20px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: none;
  background: rgba(176, 111, 102, 0.7);
  color: var(--bianco);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 99;
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition: opacity 0.3s ease, transform 0.3s ease, background 0.3s ease;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
  -webkit-tap-highlight-color: transparent;
}

.back-to-top.visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.back-to-top:hover {
  background: var(--rosa);
  box-shadow: 0 4px 16px rgba(176, 111, 102, 0.4);
}

@media (min-width: 768px) {
  .back-to-top {
    bottom: 32px;
  }
}

/* ============================================
   HEADER (ordine + admin)
   ============================================ */

.header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--bianco);
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  padding: 12px 20px;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1100px;
  margin: 0 auto;
}

.header-logo {
  height: 36px;
}

.header-title {
  font-size: 0.9rem;
  color: var(--testo-light);
}

.header-illustration {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  transition: opacity 0.3s ease;
}

/* ============================================
   PROGRESS BAR (flusso ordine)
   ============================================ */

/* ============================================
   ALTRA VASCHETTA — schermata intermedia
   ============================================ */
.altra-vaschetta-screen {
  max-width: 420px;
  margin: 0 auto;
  padding: 48px 20px 40px;
  text-align: center;
}

.altra-vaschetta-icon {
  margin-bottom: 20px;
  opacity: 0.7;
}

.altra-vaschetta-title {
  font-size: 1.4rem;
  color: var(--testo);
  margin-bottom: 8px;
}

.altra-vaschetta-sub {
  font-size: 0.9rem;
  color: var(--testo-light);
  margin-bottom: 32px;
}

.altra-vaschetta-actions .btn {
  padding: 16px 24px;
  font-size: 1.05rem;
}

/* ============================================
   ONBOARDING SCREEN
   ============================================ */
.onboarding-screen {
  max-width: 500px;
  margin: 0 auto;
  padding: 32px 20px 40px;
  text-align: center;
}

.onboarding-title {
  font-size: 1.4rem;
  color: var(--testo);
  margin-bottom: 24px;
}

.onboarding-steps {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 28px;
}

.onboarding-step {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--crema);
  border-radius: var(--raggio);
  padding: 12px 16px;
  text-align: left;
}

.onboarding-icon {
  flex-shrink: 0;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  overflow: hidden;
  border: 2.5px solid transparent;
}

.onboarding-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.onboarding-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.onboarding-text strong {
  font-size: 0.95rem;
  color: var(--testo);
}

.onboarding-text span {
  font-size: 0.82rem;
  color: var(--testo-light);
}

.onboarding-info {
  text-align: left;
  list-style: none;
  padding: 0;
  margin: 0 0 28px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.onboarding-info li {
  font-size: 0.8rem;
  color: #9a8e82;
  line-height: 1.5;
  padding-left: 16px;
  position: relative;
}

.onboarding-info li::before {
  content: '•';
  position: absolute;
  left: 0;
  color: var(--rosa);
}

.onboarding-info a {
  color: var(--verde);
  font-weight: 600;
  text-decoration: none;
}

.onboarding-screen {
  display: flex;
  flex-direction: column;
  min-height: calc(100vh - 70px);
  min-height: calc(100dvh - 70px);
}

.btn-onboarding {
  width: 100%;
  padding: 24px 24px;
  font-size: 1.35rem;
  font-weight: 700;
  border-radius: 16px;
  margin-top: auto;
}

.progress-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  padding: 12px 20px;
  background: var(--bianco);
}

.progress-step {
  display: flex;
  align-items: center;
}

.progress-dot {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--grigio-light);
  color: var(--testo-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
  transition: var(--transizione);
  flex-shrink: 0;
}

.progress-dot.active {
  background: var(--rosa);
  color: var(--bianco);
}

.progress-dot.done {
  background: var(--verde);
  color: var(--bianco);
}

.progress-line {
  width: 40px;
  height: 3px;
  background: var(--grigio-light);
  transition: var(--transizione);
}

.progress-line.done {
  background: var(--verde);
}

/* ============================================
   STEP CONTENT (flusso ordine)
   ============================================ */

.step-content {
  display: none;
  padding: 16px 20px 180px;
  max-width: 700px;
  margin: 0 auto;
}

.step-content.active {
  display: block;
}

.step-header {
  margin-bottom: 16px;
}

.step-header h2 {
  font-size: 1.4rem;
  color: var(--testo);
  margin-bottom: 4px;
}

.step-header p {
  color: var(--testo-light);
  font-size: 0.9rem;
}

/* Vaschette grid */
/* Wrapper */
.vaschette-wrapper {
  overflow: hidden;
}

.vaschette-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* Card in focus: flex row con frecce inline */
.vaschetta-card.focus {
  display: flex;
  flex-wrap: wrap;
}

.vaschetta-focus-row {
  display: flex;
  gap: 10px;
  align-items: stretch;
}

/* Frecce navigazione — dentro il flusso, a destra della card in focus */
.vaschette-nav {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex-shrink: 0;
  width: 42px;
}

.vaschette-nav-btn {
  flex: 1;
  width: 42px;
  min-height: 44px;
  border-radius: 12px;
  border: 2px solid var(--rosa-light);
  background: var(--bianco);
  color: var(--rosa);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transizione);
  box-shadow: var(--ombra);
}

.vaschette-nav-btn:hover {
  background: var(--rosa);
  color: white;
  border-color: var(--rosa);
}

.vaschette-nav-btn:disabled {
  opacity: 0.25;
  cursor: default;
  pointer-events: none;
}

/* Card base — stato compresso */
.vaschetta-card {
  position: relative;
  background: var(--bianco);
  border-radius: var(--raggio);
  padding: 14px 20px;
  box-shadow: var(--ombra);
  cursor: pointer;
  border: 2px solid transparent;
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
}

/* Contenuto espandibile */
.vaschetta-card .vaschetta-placeholder {
  width: 100%;
  height: 0;
  border-radius: 8px;
  background: var(--crema);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0;
  overflow: hidden;
  opacity: 0;
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.vaschetta-card .vaschetta-info {
  font-size: 0;
  color: var(--testo-light);
  margin-bottom: 0;
  opacity: 0;
  height: 0;
  overflow: hidden;
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.vaschetta-card .vaschetta-price {
  font-size: 0;
  font-weight: 600;
  color: var(--rosa);
  margin-top: 0;
  opacity: 0;
  height: 0;
  overflow: hidden;
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Riga compressa: nome + prezzo inline */
.vaschetta-card .vaschetta-name {
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.vaschetta-card .vaschetta-name .compact-price {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--rosa);
  margin-left: auto;
}

.vaschetta-card .vaschetta-name .compact-grammi {
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--testo-light);
  margin-left: 8px;
}

/* Card FOCUS — stato espanso */
.vaschetta-card.focus {
  padding: 20px;
  border-color: var(--rosa-light);
  box-shadow: 0 4px 16px rgba(176,111,102,0.12);
  flex: 1;
  min-width: 0;
  display: block;
}

.vaschetta-card.focus .vaschetta-placeholder {
  height: 80px;
  opacity: 1;
  margin-bottom: 12px;
}

.vaschetta-card.focus .vaschetta-placeholder svg {
  width: 90px;
  height: auto;
  color: var(--rosa-light);
}

.vaschetta-card.focus .vaschetta-name {
  font-size: 1.2rem;
  margin-bottom: 4px;
}

.vaschetta-card.focus .vaschetta-name .compact-price,
.vaschetta-card.focus .vaschetta-name .compact-grammi {
  display: none;
}

.vaschetta-card.focus .vaschetta-info {
  font-size: 0.85rem;
  opacity: 1;
  height: auto;
  margin-bottom: 2px;
}

.vaschetta-card.focus .vaschetta-price {
  font-size: 1.3rem;
  opacity: 1;
  height: auto;
  margin-top: 8px;
}

/* Card selezionata (confermata) */
.vaschetta-card.selected {
  border-color: var(--rosa);
  box-shadow: 0 0 0 3px rgba(176,111,102,0.15);
}

.vaschetta-card.selected::after {
  content: '\2713';
  position: absolute;
  top: 12px;
  right: 12px;
  width: 28px;
  height: 28px;
  background: var(--rosa);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
}

/* Nasconde check nelle card compresse */
.vaschetta-card:not(.focus).selected::after {
  width: 20px;
  height: 20px;
  font-size: 11px;
  top: 50%;
  transform: translateY(-50%);
}

/* Mini SVG nella card compressa */
.vaschetta-card .vaschetta-placeholder svg {
  width: 90px;
  height: auto;
  color: var(--rosa-light);
}

.vaschetta-card:not(.focus) .vaschetta-placeholder {
  width: 36px;
  height: 28px;
  border-radius: 4px;
  background: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0;
  margin-right: 10px;
  opacity: 1;
  overflow: visible;
  flex-shrink: 0;
}

.vaschetta-card:not(.focus) .vaschetta-placeholder svg {
  width: 36px;
  height: auto;
}

.vaschetta-card:not(.focus) {
  display: flex;
  align-items: center;
  flex-direction: row;
  gap: 0;
}

.vaschetta-card:not(.focus) .vaschetta-name {
  flex: 1;
}

/* Gusti selector */
.gusti-counter-bar {
  position: sticky;
  top: 60px;
  background: var(--bianco);
  padding: 12px 0;
  margin-bottom: 16px;
  z-index: 10;
  border-bottom: 1px solid var(--grigio-light);
}

.gusti-counter {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 1rem;
}

.gusti-counter-num {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--rosa);
}

.gusto-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  border-bottom: 1px solid var(--grigio-light);
}

.gusto-row-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.gusto-row-dot {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  flex-shrink: 0;
}

.gusto-row-name {
  font-size: 1rem;
}

.gusto-row-controls {
  display: flex;
  align-items: center;
  gap: 12px;
}

.gusto-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid var(--rosa);
  background: transparent;
  color: var(--rosa);
  font-size: 1.2rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transizione);
  font-family: var(--font);
}

.gusto-btn:hover:not(:disabled) {
  background: var(--rosa);
  color: var(--bianco);
}

.gusto-btn:disabled {
  border-color: var(--grigio);
  color: var(--grigio);
  cursor: not-allowed;
}

.gusto-qty {
  font-size: 1.1rem;
  font-weight: 700;
  min-width: 20px;
  text-align: center;
}

/* Gusti summary sticky */
.gusti-summary {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--bianco);
  box-shadow: 0 -4px 20px rgba(0,0,0,0.1);
  padding: 16px 20px;
  padding-bottom: calc(16px + env(safe-area-inset-bottom));
  z-index: 100;
}

.gusti-summary-text {
  font-size: 0.85rem;
  color: var(--testo-light);
  margin-bottom: 8px;
  text-align: center;
}

/* Extra */
.extra-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.extra-card {
  display: flex;
  align-items: center;
  gap: 16px;
  background: var(--bianco);
  border-radius: var(--raggio);
  padding: 16px 20px;
  box-shadow: var(--ombra);
  cursor: pointer;
  border: 2px solid transparent;
  transition: var(--transizione);
}

.extra-card.selected {
  border-color: var(--arancione);
  background: rgba(219,134,74,0.04);
}

.extra-checkbox {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  border: 2px solid var(--grigio);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: var(--transizione);
}

.extra-checkbox svg {
  display: none;
}

.extra-card.selected .extra-checkbox {
  background: var(--arancione);
  border-color: var(--arancione);
  color: white;
}

.extra-card.selected .extra-checkbox svg {
  display: block;
}

.extra-info {
  flex: 1;
}

.extra-name {
  font-weight: 600;
  font-size: 1rem;
}

.extra-price {
  color: var(--arancione);
  font-weight: 600;
  font-size: 1.1rem;
  flex-shrink: 0;
}

/* Time slots */
.time-slots {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.time-slot {
  padding: 14px;
  text-align: center;
  background: var(--bianco);
  border: 2px solid var(--grigio-light);
  border-radius: var(--raggio);
  font-weight: 600;
  cursor: pointer;
  transition: var(--transizione);
  font-family: var(--font);
  font-size: 1rem;
}

.time-slot:hover {
  border-color: var(--rosa);
}

.time-slot.selected {
  background: var(--rosa);
  color: var(--bianco);
  border-color: var(--rosa);
}

/* Checkout */
.checkout-card {
  background: var(--bianco);
  border-radius: var(--raggio-grande);
  padding: 28px;
  box-shadow: var(--ombra-forte);
}

.checkout-row {
  display: flex;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid var(--grigio-light);
  gap: 12px;
}

.checkout-row:last-of-type {
  border-bottom: none;
}

.checkout-label {
  color: var(--testo-light);
  font-size: 0.95rem;
  flex-shrink: 0;
}

.checkout-value {
  font-weight: 600;
  text-align: right;
  word-break: break-word;
}

.checkout-total {
  display: flex;
  justify-content: space-between;
  padding: 16px 0 0;
  margin-top: 8px;
  border-top: 2px solid var(--testo);
  font-size: 1.3rem;
  font-weight: 700;
}

.checkout-order-code {
  text-align: center;
  margin: 20px 0;
  font-size: 2rem;
  font-weight: 700;
  color: var(--rosa);
}

/* Order status (Deliveroo style) */
.order-status {
  padding: 32px 20px 80px;
  max-width: 500px;
  margin: 0 auto;
  text-align: center;
}

.order-status-code {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--rosa);
  margin-bottom: 8px;
}

.order-status-subtitle {
  color: var(--bianco);
  background: var(--verde);
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 20px;
  padding: 14px 24px;
  border-radius: 12px;
  text-align: center;
  animation: subtitlePulse 1.5s ease-in-out 4;
}

@keyframes subtitlePulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.03); box-shadow: 0 0 16px rgba(156, 178, 68, 0.4); }
}

.status-timeline {
  position: relative;
  padding-left: 40px;
  text-align: left;
}

.status-timeline::before {
  content: '';
  position: absolute;
  left: 15px;
  top: 0;
  bottom: 0;
  width: 3px;
  background: var(--grigio-light);
}

.status-item {
  position: relative;
  padding: 0 0 32px;
}

.status-item:last-child {
  padding-bottom: 0;
}

.status-dot {
  position: absolute;
  left: -33px;
  top: 2px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--grigio-light);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1;
}

.status-dot.done {
  background: var(--verde);
  color: white;
}

.status-dot.active {
  background: var(--arancione);
  color: white;
  animation: pulse 2s ease-in-out infinite;
}

.status-dot.pending {
  background: var(--grigio-light);
  color: var(--testo-light);
}

.status-item h4 {
  font-size: 1rem;
  margin-bottom: 2px;
}

.status-item p {
  font-size: 0.85rem;
  color: var(--testo-light);
}

.status-detail-card {
  background: var(--bianco);
  border-radius: var(--raggio);
  padding: 20px;
  box-shadow: var(--ombra);
  margin-top: 32px;
  text-align: left;
}

/* ============================================
   PANNELLO ADMIN
   ============================================ */

.admin-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  padding: 16px 20px;
}

.admin-stat {
  background: var(--bianco);
  border-radius: var(--raggio);
  padding: 16px 20px;
  box-shadow: var(--ombra);
  text-align: center;
}

.admin-stat-num {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--rosa);
}

.admin-stat-label {
  font-size: 0.8rem;
  color: var(--testo-light);
}

.admin-orders {
  padding: 16px 20px;
}

.order-card {
  background: var(--bianco);
  border-radius: var(--raggio);
  padding: 20px;
  box-shadow: var(--ombra);
  margin-bottom: 16px;
  border-left: 5px solid var(--grigio);
  transition: var(--transizione);
}

.order-card[data-stato="ricevuto"] {
  border-left-color: var(--arancione);
  animation: borderPulse 2s ease-in-out infinite;
}

.order-card[data-stato="accettato"] {
  border-left-color: var(--viola);
}

.order-card[data-stato="pronto"] {
  border-left-color: var(--verde);
}

.order-card[data-stato="ritirato"] {
  border-left-color: var(--grigio);
  opacity: 0.7;
}

.order-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 12px;
}

.order-code {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--rosa);
}

.order-time {
  font-size: 0.85rem;
  color: var(--testo-light);
}

.order-client {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  font-size: 1rem;
}

.order-client-phone {
  color: var(--testo-light);
  font-size: 0.9rem;
}

.order-details {
  font-size: 0.9rem;
  color: var(--testo-light);
  margin-bottom: 4px;
}

.order-ritiro {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--crema);
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 600;
  margin: 8px 0;
}

.order-total {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--testo);
  margin: 8px 0 16px;
}

.order-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.order-status-btn {
  padding: 10px 16px;
  border-radius: 8px;
  border: 2px solid var(--grigio-light);
  background: transparent;
  font-family: var(--font);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  transition: var(--transizione);
  color: var(--testo-light);
}

.order-status-btn:hover {
  border-color: var(--testo-light);
}

.order-status-btn.active-ricevuto {
  background: var(--arancione);
  color: white;
  border-color: var(--arancione);
}

.order-status-btn.active-accettato {
  background: var(--viola);
  color: white;
  border-color: var(--viola);
}

.order-status-btn.active-pronto {
  background: var(--verde);
  color: white;
  border-color: var(--verde);
}

.order-status-btn.active-ritirato {
  background: var(--grigio);
  color: white;
  border-color: var(--grigio);
}

/* ============================================
   ADMIN TABS
   ============================================ */

.admin-tabs {
  display: flex;
  background: var(--bianco);
  border-bottom: 2px solid var(--grigio-light);
}

.admin-tab {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 14px 8px;
  border: none;
  background: none;
  font-family: var(--font);
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--testo-light);
  cursor: pointer;
  border-bottom: 3px solid transparent;
  margin-bottom: -2px;
  transition: var(--transizione);
  -webkit-tap-highlight-color: transparent;
}

.admin-tab:hover {
  color: var(--rosa);
}

.admin-tab.active {
  color: var(--rosa);
  border-bottom-color: var(--rosa);
}

.admin-tab svg {
  flex-shrink: 0;
}

.admin-tab-content {
  display: none;
}

.admin-tab-content.active {
  display: block;
}

/* ============================================
   ADMIN SECTIONS (catalogo, utenti, impostazioni)
   ============================================ */

.admin-section {
  padding: 24px 20px 40px;
  max-width: 900px;
  margin: 0 auto;
}

.admin-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  gap: 12px;
  flex-wrap: wrap;
}

.admin-section-title {
  font-size: 1.2rem;
  color: var(--testo);
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Admin table */
.admin-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--bianco);
  border-radius: var(--raggio);
  overflow: hidden;
  box-shadow: var(--ombra);
}

.admin-table th,
.admin-table td {
  padding: 12px 16px;
  text-align: left;
  font-size: 0.9rem;
  border-bottom: 1px solid var(--grigio-light);
}

.admin-table th {
  background: var(--crema);
  font-weight: 600;
  color: var(--testo-light);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.admin-table-actions {
  display: flex;
  gap: 8px;
}

.orario-chiuso td {
  opacity: 0.5;
}

/* Icon buttons */
.btn-icon {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  border: 1px solid var(--grigio-light);
  background: var(--bianco);
  color: var(--testo-light);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transizione);
}

.btn-icon:hover {
  border-color: var(--rosa);
  color: var(--rosa);
}

.btn-icon-danger:hover {
  border-color: #d32f2f;
  color: #d32f2f;
}

/* Toggle switch */
.toggle {
  position: relative;
  display: inline-block;
  width: 48px;
  height: 26px;
  flex-shrink: 0;
}

.toggle input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background: var(--grigio);
  border-radius: 26px;
  transition: var(--transizione);
}

.toggle-slider::before {
  content: '';
  position: absolute;
  height: 20px;
  width: 20px;
  left: 3px;
  bottom: 3px;
  background: white;
  border-radius: 50%;
  transition: var(--transizione);
}

.toggle input:checked + .toggle-slider {
  background: var(--verde);
}

.toggle input:checked + .toggle-slider::before {
  transform: translateX(22px);
}

/* Gusti/Extra list in admin */
.admin-gusti-list {
  background: var(--bianco);
  border-radius: var(--raggio);
  box-shadow: var(--ombra);
  overflow: hidden;
}

.admin-gusto-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  border-bottom: 1px solid var(--grigio-light);
  gap: 12px;
  transition: var(--transizione);
}

.admin-gusto-row:last-child {
  border-bottom: none;
}

.admin-gusto-row[data-available="false"] {
  opacity: 0.45;
}

.admin-gusto-row[data-available="false"] .admin-gusto-name {
  text-decoration: line-through;
}

.admin-gusto-left {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  min-width: 0;
}

.admin-gusto-name {
  font-weight: 600;
  font-size: 0.95rem;
}

.admin-gusto-price {
  color: var(--arancione);
  font-weight: 600;
  font-size: 0.9rem;
}

.admin-gusto-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

/* Users list */
.admin-users-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.user-card {
  background: var(--bianco);
  border-radius: var(--raggio);
  padding: 16px 20px;
  box-shadow: var(--ombra);
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.user-card.user-blocked {
  background: #fef2f2;
  border: 1px solid #fca5a5;
}

.user-info {
  flex: 1;
  min-width: 160px;
}

.user-info strong {
  display: block;
  font-size: 1rem;
  margin-bottom: 2px;
}

.user-detail {
  font-size: 0.85rem;
  color: var(--testo-light);
}

.user-mancate {
  display: flex;
  align-items: baseline;
  gap: 4px;
  flex-wrap: wrap;
}

.user-mancate-count {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--arancione);
}

.user-mancate-label {
  font-size: 0.8rem;
  color: var(--testo-light);
}

.user-mancate-date {
  font-size: 0.75rem;
  color: var(--testo-light);
  width: 100%;
}

.user-actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

.user-btn-block {
  background: transparent;
  color: #d32f2f;
  border: 2px solid #d32f2f;
  font-family: var(--font);
  font-weight: 600;
}

.user-btn-block:hover {
  background: #d32f2f;
  color: white;
}

/* Settings form */
.settings-form {
  background: var(--bianco);
  border-radius: var(--raggio);
  box-shadow: var(--ombra);
  overflow: hidden;
}

.settings-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--grigio-light);
  gap: 16px;
  flex-wrap: wrap;
}

.settings-row:last-child {
  border-bottom: none;
}

.settings-label {
  font-weight: 600;
  font-size: 0.95rem;
  padding-top: 6px;
  min-width: 200px;
}

.settings-input-wrap {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.settings-input {
  font-family: var(--font);
  font-weight: 600;
  font-size: 1rem;
  padding: 8px 12px;
  border: 2px solid var(--grigio-light);
  border-radius: 8px;
  background: var(--crema);
  color: var(--testo);
}

.settings-hint {
  font-size: 0.8rem;
  color: var(--testo-light);
}

/* ============================================
   NAVIGATION BOTTOM BAR (flusso ordine)
   ============================================ */

.nav-bottom {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--bianco);
  box-shadow: 0 -4px 20px rgba(0,0,0,0.1);
  padding: 12px 20px;
  padding-bottom: calc(12px + env(safe-area-inset-bottom));
  display: flex;
  align-items: center;
  gap: 12px;
  z-index: 100;
}

.nav-bottom .btn {
  flex: 1;
}

#btn-confirm {
  padding-top: 10px;
  padding-bottom: 10px;
  font-size: 0.95rem;
  line-height: 1.2;
}

/* Pulse glow animation per btn-confirm — infinito, arancione visibile */
#btn-confirm.confirm-pulse {
  animation: confirmPulse 1.2s ease-in-out infinite;
}

@keyframes confirmPulse {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(219, 134, 74, 0.5);
    transform: scale(1);
  }
  50% {
    box-shadow: 0 0 22px 10px rgba(219, 134, 74, 0.3);
    transform: scale(1.04);
  }
}

/* ============================================
   SUCCESS OVERLAY — animazione conferma ordine
   ============================================ */
.success-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(250, 247, 242, 0.97);
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
}

.success-checkmark {
  width: 110px;
  height: 110px;
}

.success-circle {
  stroke-dasharray: 264;
  stroke-dashoffset: 264;
  animation: drawCircle 0.6s ease-out 0.1s forwards;
}

.success-check {
  stroke-dasharray: 80;
  stroke-dashoffset: 80;
  animation: drawCheck 0.4s ease-out 0.5s forwards;
}

@keyframes drawCircle {
  to { stroke-dashoffset: 0; }
}

@keyframes drawCheck {
  to { stroke-dashoffset: 0; }
}

.success-text {
  font-family: 'Hind', sans-serif;
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--verde);
  opacity: 0;
  transform: translateY(12px);
  animation: fadeInUp 0.5s ease-out 0.8s forwards;
}

@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.nav-subtotal {
  text-align: center;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--rosa);
  padding: 4px 0 0;
  width: 100%;
}

/* Validation error */
.validation-error {
  position: fixed;
  bottom: 80px;
  left: 20px;
  right: 20px;
  background: #d32f2f;
  color: white;
  padding: 12px 20px;
  border-radius: var(--raggio);
  text-align: center;
  font-size: 0.9rem;
  font-weight: 600;
  z-index: 200;
  animation: fadeInUp 0.3s ease;
  box-shadow: 0 4px 16px rgba(211, 47, 47, 0.3);
}

/* ============================================
   ANIMAZIONI
   ============================================ */

@keyframes pulse {
  0%, 100% { box-shadow: 0 4px 16px rgba(176,111,102,0.3); }
  50% { box-shadow: 0 4px 28px rgba(176,111,102,0.5); }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes borderPulse {
  0%, 100% { border-left-color: var(--arancione); }
  50% { border-left-color: rgba(219,134,74,0.4); }
}

.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================
   RESPONSIVE — tablet e desktop
   ============================================ */

@media (min-width: 768px) {
  .hero-logo {
    width: 400px;
  }

  .hero-subtitle {
    font-size: 1.4rem;
  }

  .steps {
    flex-direction: row;
  }

  .step-card {
    flex-direction: column;
    text-align: center;
    flex: 1;
    border-left: none;
    border-top: 4px solid transparent;
  }

  .step-card:nth-child(1) { border-left: none; border-top-color: var(--arancione); }
  .step-card:nth-child(2) { border-left: none; border-top-color: var(--viola); }
  .step-card:nth-child(3) { border-left: none; border-top-color: var(--verde); }

  .step-icon-illustration {
    width: 150px;
    height: 150px;
  }

  .gusti-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .vaschette-wrapper {
    max-width: 600px;
  }

  .time-slots {
    grid-template-columns: repeat(4, 1fr);
  }

  .footer-contacts {
    flex-direction: row;
    justify-content: center;
    gap: 32px;
  }

  .sticky-cta {
    display: none !important;
  }

  .order-actions {
    flex-wrap: nowrap;
  }
}

@media (min-width: 1024px) {
  .gusti-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .time-slots {
    grid-template-columns: repeat(6, 1fr);
  }
}

/* Mobile sticky CTA show */
@media (max-width: 767px) {
  .sticky-cta {
    display: block;
  }

  .footer {
    padding-bottom: 90px;
  }
}

/* ============================================
   HAMBURGER MENU (admin mobile)
   ============================================ */

.admin-hamburger-btn {
  display: none;
  width: 44px;
  height: 44px;
  border: none;
  background: none;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  color: var(--testo);
  border-radius: 8px;
  transition: var(--transizione);
  -webkit-tap-highlight-color: transparent;
}

.admin-hamburger-btn:hover {
  background: var(--crema);
}

.admin-mobile-menu {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 200;
}

.admin-mobile-menu.open {
  display: block;
}

.admin-mobile-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
}

.admin-mobile-drawer {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  background: var(--bianco);
  border-radius: 0 0 var(--raggio-grande) var(--raggio-grande);
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.15);
  padding-bottom: 8px;
  animation: slideDown 0.25s ease;
}

@keyframes slideDown {
  from { transform: translateY(-100%); opacity: 0; }
  to   { transform: translateY(0);     opacity: 1; }
}

.admin-mobile-drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  border-bottom: 1px solid var(--grigio-light);
}

.admin-mobile-drawer-title {
  font-size: 0.9rem;
  color: var(--testo-light);
  font-weight: 600;
}

.admin-mobile-close {
  width: 36px;
  height: 36px;
  border: none;
  background: var(--crema);
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--testo);
  font-size: 1.2rem;
  -webkit-tap-highlight-color: transparent;
}

.admin-mobile-nav-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 24px;
  width: 100%;
  border: none;
  background: none;
  font-family: var(--font);
  font-weight: 600;
  font-size: 1rem;
  color: var(--testo);
  cursor: pointer;
  transition: var(--transizione);
  text-align: left;
  -webkit-tap-highlight-color: transparent;
}

.admin-mobile-nav-item:hover,
.admin-mobile-nav-item.active {
  background: var(--crema);
  color: var(--rosa);
}

.admin-mobile-nav-divider {
  border: none;
  border-top: 1px solid var(--grigio-light);
  margin: 4px 0;
}

.admin-mobile-export-wrap {
  padding: 8px 20px 4px;
}

/* ============================================
   LANDING HEADER + ACCEDI
   ============================================ */

.header-landing {
  background: transparent;
  box-shadow: none;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
}

.btn-accedi {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--rosa);
  background: rgba(255, 255, 255, 0.8);
  border: 1.5px solid var(--rosa-light);
  border-radius: 20px;
  cursor: pointer;
  transition: var(--transizione);
  font-family: var(--font);
  min-height: 40px;
  text-decoration: none;
}

.btn-accedi:hover {
  background: var(--rosa);
  color: white;
}

.btn-accedi svg {
  width: 18px;
  height: 18px;
}

/* ============================================
   LOGIN INVITE CARD (landing)
   ============================================ */

.login-invite-card {
  text-align: center;
  background: var(--bianco);
  border-radius: var(--raggio-grande);
  padding: 48px 24px;
  max-width: 500px;
  margin: 0 auto;
  box-shadow: var(--ombra-forte);
}

.login-invite-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: rgba(176, 111, 102, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
  color: var(--rosa);
}

.login-invite-icon svg {
  width: 32px;
  height: 32px;
}

.login-invite-card h2 {
  font-size: 1.4rem;
  margin-bottom: 12px;
}

.login-invite-card p {
  color: var(--testo-light);
  margin-bottom: 28px;
  font-size: 0.95rem;
}

.login-invite-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 280px;
  margin: 0 auto;
}

@media (min-width: 480px) {
  .login-invite-actions {
    flex-direction: row;
    max-width: 400px;
  }
  .login-invite-actions .btn {
    flex: 1;
  }
}

/* ============================================
   VASCHETTA SVG (step 2 ordine)
   ============================================ */

.vaschetta-svg-wrap {
  position: sticky;
  top: 50px;
  z-index: 10;
  background: var(--crema);
  padding: 8px 0 4px;
  text-align: center;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--grigio-light);
  transition: padding 0.3s ease, transform 0.3s ease;
}

.vaschetta-svg-wrap.scrolled {
  padding: 8px 0 4px;
}

.vaschetta-svg-wrap.scrolled svg {
  transform: scale(0.75);
  transform-origin: center top;
  transition: transform 0.3s ease;
}

.vaschetta-svg-wrap svg {
  transition: transform 0.3s ease;
}

.vaschetta-svg-wrap svg {
  width: 85%;
  max-width: 400px;
  height: auto;
  display: block;
  margin: 0 auto;
}

.vaschetta-svg-label {
  font-size: 0.9rem;
  color: var(--testo-light);
  margin-top: 10px;
  text-align: center;
  font-weight: 600;
}

.vaschetta-block {
  transition: fill 0.3s ease;
}

/* Overlay del blocco con effetto liquid fill */
.vaschetta-block-overlay {
  clip-path: polygon(0% 100%, 15% 100%, 35% 100%, 50% 100%, 65% 100%, 85% 100%, 100% 100%, 100% 100%, 0% 100%);
  transition: clip-path 0.7s cubic-bezier(0.34, 1.15, 0.64, 1);
}

.vaschetta-block-overlay.filled {
  clip-path: polygon(0% 4%, 15% 0%, 35% 3%, 50% 0%, 65% 4%, 85% 1%, 100% 3%, 100% 100%, 0% 100%);
}

.vaschetta-block-text {
  transition: opacity 0.5s ease 0.3s;
  font-family: var(--font);
}

/* Gusto appena selezionato — flash e deselect */
.gusto-select-item.just-selected {
  border-color: var(--verde);
  background: rgba(156, 178, 68, 0.08);
  pointer-events: none;
}

@media (min-width: 768px) {
  .vaschetta-svg-wrap svg {
    width: 55%;
  }
}

/* Desktop: step 2 split-view (vaschetta sx, contenuto dx) */
@media (min-width: 900px) {
  #step-2.active {
    display: flex;
    gap: 32px;
    align-items: flex-start;
    max-width: 1000px;
  }

  .vaschetta-svg-wrap {
    position: sticky;
    top: 80px;
    flex: 0 0 380px;
    background: transparent;
    border-bottom: none;
    padding: 0;
    margin-bottom: 0;
  }

  .vaschetta-svg-wrap svg {
    width: 100%;
    max-width: 380px;
  }

  .vaschetta-svg-wrap.scrolled {
    padding: 0;
  }

  .vaschetta-svg-wrap.scrolled svg {
    transform: none;
  }

  .gusto-substep {
    flex: 1;
    min-width: 0;
  }
}

/* ============================================
   GUSTO SELECT LIST (step 2 sotto-step)
   ============================================ */

.gusto-select-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.gusto-select-item {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 16px;
  background: var(--bianco);
  border: 2px solid var(--grigio-light);
  border-radius: var(--raggio);
  cursor: pointer;
  transition: var(--transizione);
  font-family: var(--font);
  font-size: 1rem;
  font-weight: 600;
  color: var(--testo);
  min-height: 56px;
  text-align: left;
  -webkit-tap-highlight-color: transparent;
}

.gusto-select-item:hover {
  border-color: var(--rosa-light);
  box-shadow: var(--ombra);
}

.gusto-select-item:active {
  transform: scale(0.98);
  border-color: var(--rosa);
}

.gusto-select-name {
  font-size: 1rem;
  flex: 1;
}

.gusto-vegan-icon {
  display: flex;
  align-items: center;
  margin-left: auto;
  opacity: 0.75;
}

/* Legenda e allergie sotto la lista gusti */
.gusti-footer-note {
  margin-top: 20px;
  padding: 12px 16px;
  background: rgba(74,140,63,0.04);
  border-radius: var(--raggio);
  border: 1px solid rgba(74,140,63,0.12);
}

.gusti-legend {
  font-size: 0.78rem;
  color: #4a8c3f;
  margin-bottom: 6px;
}

.gusti-allergie {
  font-size: 0.72rem;
  color: var(--testo-light);
  line-height: 1.4;
}

.gusti-allergie a {
  color: var(--rosa);
  text-decoration: none;
  font-weight: 600;
}

/* ============================================
   GUSTI RECAP (step 2 riepilogo)
   ============================================ */

.gusti-recap-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 24px;
}

.gusti-recap-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: var(--bianco);
  border-radius: var(--raggio);
  box-shadow: var(--ombra);
}

.gusti-recap-num {
  font-size: 0.85rem;
  color: var(--testo-light);
  min-width: 20px;
  font-weight: 600;
}

.gusti-recap-row .gusto-row-dot {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

.gusti-recap-name {
  flex: 1;
  font-weight: 600;
  font-size: 0.95rem;
}

.gusti-recap-change {
  flex-shrink: 0;
  padding: 5px 12px;
  font-size: 0.75rem;
  font-weight: 600;
  font-family: var(--font);
  color: var(--arancione);
  background: rgba(219, 134, 74, 0.1);
  border: 1.5px solid var(--arancione);
  border-radius: 16px;
  cursor: pointer;
  transition: var(--transizione);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  -webkit-tap-highlight-color: transparent;
}

.gusti-recap-change:hover {
  background: var(--arancione);
  color: white;
}

.gusti-recap-actions {
  text-align: center;
}

/* Pulsante Avanti in modalità "Basta X gusti? Prosegui" */
.nav-bottom:has(.btn-skip-style) #btn-prev {
  flex: 0.6;
}

.nav-bottom:has(.btn-skip-style) .btn-skip-style {
  flex: 1.4;
}

.btn.btn-primary.btn-skip-style {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
  padding: 10px 20px;
}

.btn.btn-primary.btn-skip-style .skip-label {
  font-size: 0.68rem;
  font-weight: 400;
  opacity: 0.8;
  letter-spacing: 0.02em;
}

/* ============================================
   ADMIN: IMMAGINE UPLOAD + ORDINAMENTO
   ============================================ */

.admin-img-upload {
  width: 60px;
  height: 60px;
  border: 2px dashed var(--grigio);
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  cursor: pointer;
  transition: var(--transizione);
  color: var(--testo-light);
}

.admin-img-upload:hover {
  border-color: var(--rosa-light);
  color: var(--rosa);
}

.admin-img-upload svg {
  width: 20px;
  height: 20px;
}

.admin-img-upload span {
  font-size: 0.7rem;
}

.admin-table-order {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.btn-icon-sm {
  width: 28px;
  height: 28px;
  padding: 4px;
  border-radius: 6px;
  border: 1px solid var(--grigio-light);
  background: var(--bianco);
  color: var(--testo-light);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transizione);
}

.btn-icon-sm:hover {
  border-color: var(--rosa);
  color: var(--rosa);
}

/* ============================================
   ADMIN RESPONSIVE BREAKPOINTS
   ============================================ */

/* Mobile: hamburger + 2x2 stats */
@media (max-width: 639px) {
  .admin-tabs {
    display: none;
  }

  .admin-hamburger-btn {
    display: flex;
  }

  .header-btn-export {
    display: none;
  }

  .admin-stats {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Desktop: ordini a 2 colonne */
@media (min-width: 1024px) {
  .admin-orders {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    align-items: start;
    gap: 0 20px;
    padding: 20px 24px;
  }

  .order-card {
    margin-bottom: 20px;
  }
}
