/*
 * Composant filtres global.
 * Utilisé par les archives PDF / Publications et par les annuaires.
 * À garder séparé de pdf-publications.css : les annuaires utilisent les mêmes classes de formulaire.
 */
.ms-filter-panel{
  display:grid;
  gap:20px;
}
.ms-filter-panel__toggle{
  appearance:none;
  border:0;
  background:transparent;
  padding:0;
  display:inline-flex;
  align-items:center;
  gap:12px;
  font-size:1.5rem;
  font-weight:800;
  color:#245b63;
  text-transform:uppercase;
  letter-spacing:.02em;
  justify-self:start;
  cursor:pointer;
  text-decoration:none;
  line-height:1;
}
.ms-filter-panel__toggle:hover,
.ms-filter-panel__toggle:focus{
  color:#245b63;
  text-decoration:none;
}
.ms-filter-panel__icon,
.ms-filter-panel__chevron{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  color:#245b63;
  font-size:1.05em;
  line-height:1;
}
.ms-filter-panel__label{
  color:#245b63;
}
.ms-filter-panel__chevron{
  transition:transform .2s ease;
}
.ms-filter-panel.is-collapsed .ms-filter-panel__chevron{
  transform:rotate(0deg);
}
.ms-filter-panel:not(.is-collapsed) .ms-filter-panel__chevron{
  transform:rotate(180deg);
}
.ms-filter-panel.is-collapsed .ms-filter-panel__body{
  display:none;
}
.ms-pdf-filters{
  display:grid;
  gap:24px;
}
.ms-pdf-filters__grid{
  display:grid;
  grid-template-columns:minmax(240px, 1.5fr) minmax(240px, 1.5fr) minmax(180px, 1fr) minmax(180px, 1fr) minmax(180px, 1fr);
  gap:16px 18px;
  align-items:start;
}
.ms-pdf-filter-field{
  min-width:0;
}
.ms-pdf-filter-field--keyword{
  grid-column:span 1;
}
.ms-pdf-filter-field select,
.ms-pdf-filter-field input{
  width:100%;
  min-height:50px;
  height:50px;
  padding:0 20px;
  border:2px solid #245b63;
  border-radius:999px;
  background:#fff;
  color:#245b63;
  font-size:clamp(.95rem,1vw,1.05rem);
  font-weight:600;
  box-shadow:none;
}
.ms-pdf-filter-field input::placeholder,
.ms-pdf-filter-field select:disabled{
  color:#7e979b;
}
.ms-pdf-filter-field select{
  appearance:none;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='14' viewBox='0 0 22 14'%3E%3Cpath d='M3 3l8 8 8-8' fill='none' stroke='%23245b63' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat:no-repeat;
  background-position:right 22px center;
  padding-right:54px;
}
.ms-pdf-filters__actions{
  display:flex;
  align-items:center;
  gap:14px;
  flex-wrap:wrap;
}
.ms-pdf-filters__actions > *{
  flex:0 0 auto;
}
.ms-filter-button{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:240px;
  min-height:60px;
  padding:0 28px;
  border-radius:999px;
  border:2px solid #245b63;
  background:#fff;
  color:#245b63;
  font-size:1rem;
  font-weight:800;
  text-transform:uppercase;
  text-decoration:none;
}
.ms-filter-button--primary{
  cursor:pointer;
}
.ms-filter-button:hover{
  color:#1d4950;
  border-color:#1d4950;
}
.ms-annuaire-wrap .ms-pdf-filters__grid{
  grid-template-columns:repeat(2, minmax(240px, 1fr));
  max-width:1100px;
}
.ms-annuaire-wrap .ms-pdf-filters__actions{
  max-width:980px;
}
.ms-annuaire-wrap .ms-filter-button{
  flex:1 1 260px;
}
@media (max-width: 1400px){
  .ms-pdf-filters__grid{
    grid-template-columns:repeat(3, minmax(0, 1fr));
  }
  .ms-annuaire-wrap .ms-pdf-filters__grid{
    grid-template-columns:repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 1200px){
  .ms-filter-button{
    min-width:220px;
  }
}
@media (max-width: 767px){
  .ms-filter-panel__toggle{
    font-size:1rem;
  }
  .ms-filter-panel__icon,
  .ms-filter-panel__chevron{
    font-size:1em;
  }
  .ms-pdf-filters__grid,
  .ms-annuaire-wrap .ms-pdf-filters__grid{
    grid-template-columns:1fr;
  }
  .ms-pdf-filter-field select,
  .ms-pdf-filter-field input{
    min-height:50px;
    height:50px;
    border-radius:999px;
  }
  .ms-pdf-filters__actions{
    gap:12px;
  }
  .ms-filter-button,
  .ms-annuaire-wrap .ms-filter-button{
    width:100%;
    min-width:0;
    min-height:60px;
    padding:0 24px;
  }
}
