/* =====================================================================
   KERMESSE (kermesse/index.php): layout desktop
   Attivo solo da 992px e solo su questa pagina (body.ke-d). Mobile invariato,
   tranne la sezione "set" nascosta quando non ci sono prodotti (vedi sotto).
   ===================================================================== */

/* sezione "I set pensati per te" senza prodotti: non mostrare la fascia vuota */
.ke-d section.products.slider:has(> .gold):has(.productsSetSwiper.alt):not(:has(.swiper-slide)) { display: none; }

@media (min-width: 992px) {
  .ke-d { --ke-max: 1200px; --ke-gold: #be894a; --ke-space: clamp(48px, 5vw, 80px); }

  /* apertura: altezza contenuta */
  .ke-d section.home.kermesse { min-height: 520px; }
  .ke-d section.home.kermesse > .container { max-width: var(--ke-max); }

  /* promo: banner principale a sinistra, due banner impilati a destra, immagini intere */
  .ke-d .ke-promo {
    display: grid; grid-template-columns: 1fr 1fr; grid-auto-rows: auto; gap: 12px;
    max-width: var(--ke-max); margin: 12px auto 0; padding: 0 32px;
  }
  .ke-d .ke-promo > a:first-child { grid-row: 1 / span 2; display: block; }
  .ke-d .ke-promo > a > section { margin: 0 !important; }
  .ke-d .ke-promo .home-promo {
    height: 100% !important; min-height: 0; aspect-ratio: 3333 / 2536;
    background-size: cover; background-position: center; padding: 0 !important;
  }
  .ke-d .ke-promo .home-test.box-image { height: auto; }
  .ke-d .ke-promo .home-test.box-image img { display: block; width: 100%; height: auto; aspect-ratio: 3333 / 1208; object-fit: cover; }
  /* se esiste un solo banner, occupa tutta la larghezza */
  .ke-d .ke-promo:not(:has(> a:nth-child(2))) { grid-template-columns: 1fr; }

  /* video verticale: centrato e contenuto, su fascia neutra */
  .ke-d section.ke-video { background: #f5f1ec; margin: var(--ke-space) 0 !important; padding: 48px 0 !important; }
  .ke-d section.ke-video video { display: block; height: 620px; width: auto; max-width: 100%; margin: 0 auto; border-radius: 8px; box-shadow: 0 20px 40px -24px rgba(0, 0, 0, .45); }

  /* caroselli categorie e prodotti allineati al contenitore */
  .ke-d .productsSwiper, .ke-d .productsSetSwiper { max-width: var(--ke-max) !important; }

  /* newsletter centrata */
  .ke-d section.welcome .row { justify-content: center; }
}
