/* b5_itk — menu principal sur mobile et tablette : texte = page, chevron = sous-menu. */

/* Le bouton chevron n'existe que sur mobile / tablette. */
.navbar .b5-itk-chevron {
  display: none;
}
@media (max-width: 991.98px), (hover: none) {
  /* Ligne de la rubrique : texte à gauche, zone chevron à droite (52 px). */
  .navbar .navbar-nav > .nav-item.dropdown {
    display: grid;
    grid-template-columns: 1fr 52px;
    align-items: stretch;
  }
  .navbar .navbar-nav > .nav-item.dropdown > .dropdown-menu {
    grid-column: 1 / -1;
  }
  /* Le triangle Bootstrap du lien est inutile : le chevron est dans son bouton. */
  .navbar .navbar-nav > .nav-item.dropdown > .dropdown-toggle::after {
    display: none;
  }
  .navbar .b5-itk-chevron {
    display: grid;
    place-items: center;
    padding: 0;
    border: 0;
    border-top: 1px solid rgba(255, 255, 255, .12);
    border-left: 1px solid rgba(255, 255, 255, .22);
    background: rgba(0, 0, 0, .08);
    color: #fff;
    cursor: pointer;
  }
  .navbar .b5-itk-chevron::before {
    content: "";
    width: 14px;
    height: 14px;
    background: currentColor;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") center / contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") center / contain no-repeat;
    transition: transform .2s;
  }
  .navbar .b5-itk-chevron[aria-expanded="true"]::before {
    transform: rotate(180deg);
  }
  .navbar .b5-itk-chevron:focus-visible {
    outline: 2px solid #f2c94c;
    outline-offset: -2px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .navbar .b5-itk-chevron::before { transition: none; }
}
