
/* QuiMedica – standard layout & typography */

/* Imposta margini e larghezze comode per tutto il sito */
section,
header,
footer {
  margin-left: auto;
  margin-right: auto;
  max-width: 1400px; /* limita la larghezza massima su monitor ampi */
}

/* Padding laterale più ampio per tutti i container */
.container {
  padding-left: 2rem;   /* 32px su mobile */
  padding-right: 2rem;
}

@media (min-width: 640px) {
  .container {
    padding-left: 3rem;   /* 48px su tablet */
    padding-right: 3rem;
  }
}

@media (min-width: 1024px) {
  .container {
    padding-left: 4rem;   /* 64px su desktop */
    padding-right: 4rem;
  }
}

/* Migliora la leggibilità dei paragrafi */
p {
  line-height: 1.65;
  margin-bottom: 1em;
  color: #334155; /* Slate 700 */
}

/* Titoli più ariosi */
h1, h2, h3, h4 {
  line-height: 1.2;
  margin-bottom: 0.6em;
  color: #174fbf; /* blu brand */
}

/* Pulsanti coerenti */

a.btn-primary:hover,
button.btn-primary:hover {
  transform: scale(1.03);
  box-shadow: 0 4px 10px rgba(23,79,191,0.25);
}

/* Testi nei form più leggibili su mobile */
input, textarea {
  font-size: 1rem;
}

/* Footer più compatto su mobile */
footer p {
  font-size: 0.9rem;
  color: #64748b; /* Slate 500 */
}

/* Hover interattivo sulle card degli studi */
.card .aspect-\[4\/3\] img {
  transition: transform 0.35s ease, filter 0.35s ease, box-shadow 0.35s ease;
}

.card:hover .aspect-\[4\/3\] img {
  transform: scale(1.05);
  filter: brightness(1.04);
  box-shadow: 0 12px 28px rgba(0,0,0,0.22);
}
.badge-new{
  display:inline-flex;align-items:center;justify-content:center;
  height:24px;min-width:46px;padding:0 .6rem;border-radius:9999px;
  font-size:.75rem;font-weight:800;letter-spacing:.03em;
  color:white;background:linear-gradient(135deg,#1e40af,#2563eb,#60a5fa);
  box-shadow:0 6px 16px rgba(37,99,235,.35);
  animation:pulseNew 1.2s ease-in-out infinite;
}
@keyframes pulseNew{
  0%,100%{transform:scale(1);filter:brightness(1)}
  50%{transform:scale(1.06);filter:brightness(1.08)}
}
/* opzionale: leggero alzamento del riquadro eventi */
#eventi .rounded-2xl{transition:transform .25s ease, box-shadow .25s ease}
#eventi .rounded-2xl:hover{transform:translateY(-2px);box-shadow:0 12px 28px rgba(0,0,0,.08)}
#eventi h3 {
  font-size: 1.875rem; /* ≈ text-3xl */
  font-weight: 700;
  line-height: 1.2;
  color: #174fbf; /* blu brand */
}
/* Lightbox – fix desktop Chrome: immagine sempre intera e centrata */
.lightbox-backdrop{
  position: fixed; inset: 0;
  background: rgba(15,23,42,.75);
  display: none; align-items: center; justify-content: center;
  z-index: 70;
  padding: 24px;               /* evita che tocchi i bordi e che venga “tagliata” */
  box-sizing: border-box;
}

/* Lightbox – fix Chrome desktop: mai taglio in basso, scroll se serve */
.lightbox-backdrop{
  position: fixed; inset: 0;
  background: rgba(15,23,42,.75);
  display: none; align-items: center; justify-content: center;
  z-index: 70;
  padding: 20px;               /* bordo di sicurezza */
  box-sizing: border-box;
}

.lightbox-backdrop.open{ display:flex; }

/* Contenitore scorrevole se l’immagine eccede */
.lightbox-fig{
  max-width: min(1100px, 88vw);
  max-height: calc(100vh - 120px);  /* conservativo per caption/chiudi */
  overflow: auto;                    /* <-- evita il “taglio” */
  box-sizing: border-box;
  margin: 0 auto;
}

/* Su desktop ampio, un filo più stretto/alto */
@media (min-width: 1024px){
  .lightbox-fig{
    max-width: min(1000px, 85vw);
    max-height: calc(100vh - 140px);
  }
}

/* Immagine sempre intera, centrata */
.lightbox-fig img{
  display: block;
  width: auto; height: auto;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

/* Didascalia compatta */
.lightbox-cap{
  margin-top: .5rem;
  text-align: center;
  color: #e2e8f0;
  font-size: .85rem; line-height: 1.3;
  max-width: 85vw;
}
/* Spazio leggero sopra/sotto il blocco Eventi quando serve */
.event-card { transition: box-shadow .25s ease, transform .25s ease; }
.event-card:hover { box-shadow: 0 12px 28px rgba(0,0,0,.08); transform: translateY(-2px); }


@keyframes pulseNew{0%,100%{transform:translateY(2px) scale(1)}50%{transform:translateY(2px) scale(1.06)}}

/* Lightbox: robusta anche su Chrome desktop (niente taglio) */
.lightbox-backdrop{position:fixed;inset:0;background:rgba(15,23,42,.75);display:none;align-items:center;justify-content:center;z-index:70;padding:20px;box-sizing:border-box}
.lightbox-backdrop.open{display:flex}
.lightbox-fig{max-width:min(1000px,85vw);max-height:calc(100vh - 140px);overflow:auto;box-sizing:border-box;margin:0 auto}
.lightbox-fig img{display:block;width:auto;height:auto;max-width:100%;max-height:100%;object-fit:contain}
.lightbox-cap{margin-top:.5rem;text-align:center;color:#e2e8f0;font-size:.85rem;line-height:1.3;max-width:85vw}

/* Allineamento immagine teaser Eventi */
@media (min-width: 1024px) {
  #eventi .event-card img {
    margin-top: 4px; /* allineato alla base di “Open Day” */
  }
}

/* =========================
   CTA – Prenota / Info
   ========================= */

/* Prenota: bottone pieno blu */
.btn-primary{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:.5rem;
  padding:.65rem 1.1rem;
  border-radius:9999px;
  background:#174fbf; /* brand-700 */
  color:#fff;
  font-weight:700;
  border:1px solid #174fbf;
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}
.btn-primary:hover{
  background:#123f99; /* brand-800 */
  box-shadow:0 10px 18px rgba(23,79,191,.22);
  transform:translateY(-1px);
}

/* Info: outline blu elegante */
.btn-outline{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:.5rem;
  padding:.65rem 1.1rem;
  border-radius:9999px;
  background:#fff;
  color:#174fbf;
  font-weight:700;
  border:1px solid rgba(23,79,191,.35);
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease, border-color .15s ease;
}
.btn-outline:hover{
  background:rgba(23,79,191,.06);
  border-color:rgba(23,79,191,.6);
  box-shadow:0 10px 18px rgba(23,79,191,.12);
  transform:translateY(-1px);
}
/* CTA bianco (es. "Prenota una visita") */
.btn-white{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:.5rem;
  padding:.65rem 1.1rem;
  border-radius:9999px;
  background:#fff;
  color:#174fbf; /* brand-700 */
  font-weight:700;
  border:1px solid rgba(23,79,191,.35);
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease, border-color .15s ease;
}

/* CTA ghost / bianco (es. "Prenota una visita") */
.btn-ghost{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:.5rem;
  padding:.65rem 1.1rem;
  border-radius:9999px;
  background:#fff;
  color:#174fbf;
  font-weight:700;
  border:1px solid rgba(23,79,191,.35);
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease, border-color .15s ease;
}
.btn-ghost:hover{
  background:rgba(23,79,191,.06);
  border-color:rgba(23,79,191,.6);
  box-shadow:0 10px 18px rgba(23,79,191,.12);
  transform:translateY(-1px);
}










