/* Navigation Ressources : styles limités au header public. */
.resources-nav {
  position: relative;
  min-width: 0;
  flex-shrink: 0;
}
.resources-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  list-style: none;
  white-space: nowrap;
  user-select: none;
}
.resources-toggle::-webkit-details-marker { display: none; }
.resources-toggle::after {
  content: "";
  width: 7px;
  height: 7px;
  flex: 0 0 7px;
  margin-top: -3px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
}
.resources-nav[open] > .resources-toggle::after {
  margin-top: 3px;
  transform: rotate(225deg);
}
.resources-nav.is-active:not([open]) > .resources-toggle:not(:hover):not(:focus-visible) { color: #1D4ED8; }
.resources-nav[open] > .resources-toggle { color: #FFFFFF; background: var(--blue); }
.resources-toggle:is(:hover, :focus-visible) { font-weight: 900; }
.resources-toggle:focus-visible {
  outline: 3px solid #1D4ED8;
  outline-offset: 3px;
  box-shadow: 0 0 0 3px #FFFFFF;
}
.resources-nav:not([open]) > .resources-panel { display: none; }
.resources-panel {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  z-index: 60;
  display: grid;
  gap: 4px;
  width: max-content;
  min-width: 172px;
  max-width: calc(100vw - 32px);
  max-height: calc(100dvh - var(--site-header-inner-height, 82px) - 28px);
  overflow-y: auto;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--white);
  box-shadow: var(--shadow-md);
}
.primary-nav .resources-panel > a {
  justify-content: flex-start;
  min-width: 0;
  min-height: 44px;
  padding: 10px 14px;
  border-radius: 8px;
  white-space: normal;
}
.primary-nav .resources-panel > a:is(:hover, :focus-visible) { font-weight: 900; }
.primary-nav .resources-panel > a[aria-current="page"] { font-weight: 900; text-decoration: underline; text-underline-offset: .25em; }
@media (min-width: 1245px) {
  .has-resources-nav .header-inner { gap: 18px; }
  .has-resources-nav .primary-nav { gap: 12px; min-width: 0; }
  .has-resources-nav .primary-nav > :is(a, .nav-button),
  .has-resources-nav .resources-toggle { min-width: 0; padding-inline: 12px; }
}
@media (max-width: 1244px) {
  .resources-nav { width: 100%; }
  .primary-nav .resources-toggle {
    display: flex;
    justify-content: space-between;
    width: 100%;
    white-space: normal;
  }
  .resources-panel {
    position: static;
    width: auto;
    min-width: 0;
    max-width: 100%;
    max-height: none;
    margin: 4px 8px 4px 14px;
    padding: 0 0 0 8px;
    border: 0;
    border-left: 2px solid var(--blue);
    border-radius: 0;
    box-shadow: none;
    overflow: visible;
  }
}
@media (prefers-reduced-motion: reduce) {
  .resources-toggle { transform: none !important; transition: none; }
}
