/* === HOME ANTI-CROP: Gutenberg Cover + hero background === */

/* Tablet + Mobile: non tagliare le cover */
@media (max-width: 1024px) {
  /* Contenitore cover: altezza elastica + letterbox */
  body.home .wp-block-cover { 
    min-height: 60vh;
    background-color: #000; /* cambia colore se preferisci */
  }
  /* Variante con background su <span> */
  body.home .wp-block-cover__background {
    background-size: contain !important;
    background-position: center center !important;
    background-repeat: no-repeat !important;
  }
  /* Variante con <img> interna (tema/core) */
  body.home .wp-block-cover .wp-block-cover__image-background,
  body.home img.wp-block-cover__image-background {
    width: 100% !important;
    height: 100% !important;
    object-fit: contain !important;
    object-position: center center !important;
  }
}

/* Mobile specifico */
@media (max-width: 768px) {
  body.home .wp-block-cover { min-height: 50vh; }
}

/* Se gli hero usano background su .hero-area / .hero-1..4, forza contain su tablet/mobile */
@media (max-width: 1024px) {
  .hero-area,
  .hero-1, .hero-2, .hero-3, .hero-4 {
    background-size: contain !important;
    background-position: center center !important;
    background-repeat: no-repeat !important;
    background-color: #000; /* “letterbox” per riempire le bande */
  }
}
