/*
 * By Night V220 — alignement desktop du menu supérieur et des filtres d'accueil.
 * Feuille volontairement séparée afin de contourner tout ancien cache CSS.
 */

@media (min-width:1024px) {
  :root {
    --home-filter-outer-space:clamp(26px,3vw,54px);
    --home-filter-center-space:clamp(170px,15vw,250px);
  }

  /* Espace réellement visible entre Agenda/Guide et Reportages/Actualités. */
  body > [data-primary-actions].is-group-transition .primary-actions-dock-group {
    gap:clamp(26px,2.35vw,38px)!important;
  }

  /* Les filtres reprennent les trois zones du bandeau supérieur : gauche, logo, droite. */
  body:has(.home-screen-events) .home-events-filter-row,
  body:has(.home-screen-guide) .home-guide-filter-shell,
  body:has(.home-screen-editorial) .home-report-filter-shell,
  .home-news-filter-shell {
    left:50%!important;
    width:100vw!important;
    max-width:100vw!important;
    margin-left:-50vw!important;
    padding-left:var(--home-filter-outer-space)!important;
    padding-right:var(--home-filter-outer-space)!important;
    transform:none!important;
    grid-template-columns:minmax(0,1fr) var(--home-filter-center-space) minmax(0,1fr)!important;
    column-gap:0!important;
  }

  body:has(.home-screen-events) .home-events-filter-row > :first-child,
  body:has(.home-screen-guide) .home-guide-filter-shell > :first-child,
  body:has(.home-screen-editorial) .home-report-filter-shell > :first-child,
  .home-news-filter-shell > :first-child {
    grid-column:1!important;
    justify-self:center!important;
  }

  body:has(.home-screen-events) .home-events-filter-row > :last-child,
  body:has(.home-screen-guide) .home-guide-filter-shell > :last-child,
  body:has(.home-screen-editorial) .home-report-filter-shell > :last-child,
  .home-news-filter-shell > :last-child {
    grid-column:3!important;
    justify-self:center!important;
  }

  body:has(.home-screen-events) .home-events-filter-group,
  body:has(.home-screen-editorial) .home-report-filter-group,
  .home-news-filter-group,
  body:has(.home-screen-guide) .home-guide-filter-areas {
    width:max-content!important;
    max-width:100%!important;
    justify-content:center!important;
    text-align:center!important;
  }

  /* Le séparateur suit précisément l'axe du logo et non le bord d'un filtre. */
  body:has(.home-screen-events) .home-events-filter-row::after,
  body:has(.home-screen-guide) .home-guide-filter-shell::after,
  body:has(.home-screen-editorial) .home-report-filter-shell::after,
  .home-news-filter-shell::after {
    left:50%!important;
  }

  /* Deux lignes strictement identiques en largeur dans le filtre Guide. */
  body:has(.home-screen-guide) .home-guide-filter-types {
    width:100%!important;
    max-width:100%!important;
    justify-self:stretch!important;
  }

  body:has(.home-screen-guide) .home-guide-type-row {
    display:flex!important;
    width:100%!important;
    min-width:100%!important;
    max-width:100%!important;
    align-items:center!important;
    justify-content:space-between!important;
    gap:clamp(3px,.45vw,7px)!important;
  }

  body:has(.home-screen-guide) .home-guide-type-row button {
    flex:0 0 auto!important;
  }

  body:has(.home-screen-guide) .home-guide-type-row .home-guide-option-switch {
    width:76px!important;
    min-width:76px!important;
    max-width:76px!important;
    flex:0 0 76px!important;
    justify-content:flex-end!important;
  }
}
