
.choix { position: relative; display: block; }
.choix-natif {
  position: absolute !important; inset: 0 !important; width: 100% !important; height: 100% !important;
  margin: 0 !important; opacity: 0 !important; pointer-events: none !important;
}
.choix-bouton {
  -webkit-appearance: none; appearance: none;
  display: flex; align-items: center; justify-content: space-between; gap: .6em;
  box-sizing: border-box; width: 100%; margin: 0; padding: 0;
  border: 0; background: transparent; color: inherit;
  font: inherit; letter-spacing: inherit; text-align: left; line-height: inherit; cursor: pointer;
}
.choix-bouton:disabled { cursor: default; opacity: .5; }
.choix-valeur { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.choix-chevron { flex: none; width: .72em; height: .48em; transition: transform .18s ease; }
.choix-bouton[aria-expanded="true"] .choix-chevron { transform: rotate(180deg); }
.choix:has(.choix-natif:focus) .choix-bouton { outline: 2px solid var(--choix-accent, #1b1b1b); outline-offset: 2px; }

.choix-pop {
  position: fixed; z-index: 1000; box-sizing: border-box;
  max-width: calc(100vw - 16px);
  background: var(--choix-fond, #fff); color: var(--choix-texte, #1b1b1b);
  border: 1px solid var(--choix-bord, rgba(0, 0, 0, .14));
  border-radius: var(--choix-rayon, 6px);
  box-shadow: var(--choix-ombre, 0 18px 40px -18px rgba(0, 0, 0, .38));
  font-family: var(--choix-police, inherit); font-size: 1rem; line-height: 1.35;
  animation: choixVient .14s ease-out;
}
@keyframes choixVient { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.choix-pop--haut { animation-name: choixVientHaut; }
@keyframes choixVientHaut { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

.choix-liste { max-height: min(20rem, 60vh); overflow: auto; padding: 6px; outline: 0; overscroll-behavior: contain; }
.choix-option {
  padding: .62em .85em; border-radius: max(0px, calc(var(--choix-rayon, 6px) - 2px));
  cursor: pointer; white-space: nowrap; user-select: none;
}
.choix-option.est-actif { background: var(--choix-survol, rgba(0, 0, 0, .07)); }
.choix-option[aria-selected="true"] { background: var(--choix-accent, #1b1b1b); color: var(--choix-accent-texte, #fff); }
.choix-option[aria-disabled="true"] { opacity: .38; cursor: default; }
.choix-groupe { padding: .75em .85em .3em; font-size: .8em; color: var(--choix-doux, rgba(0, 0, 0, .58)); }
.choix-liste:focus-visible .choix-option.est-actif { outline: 1px solid var(--choix-accent, #1b1b1b); outline-offset: -1px; }

.choix-cal { width: 20rem; padding: 14px 14px 12px; }
.choix-cal-tete { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 0 0 8px; }
.choix-cal-titre { margin: 0; font-weight: 600; font-size: 1.02em; }
.choix-mois {
  -webkit-appearance: none; appearance: none; flex: none;
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; padding: 0; border: 0; border-radius: var(--choix-rayon, 6px);
  background: transparent; color: inherit; cursor: pointer;
}
.choix-mois svg { width: 8px; height: 12px; }
.choix-mois:hover { background: var(--choix-survol, rgba(0, 0, 0, .07)); }
.choix-mois:disabled { opacity: .28; cursor: default; background: transparent; }
.choix-mois:focus-visible { outline: 2px solid var(--choix-accent, #1b1b1b); outline-offset: 1px; }
.choix-grille { width: 100%; border-collapse: separate; border-spacing: 2px; table-layout: fixed; }
.choix-grille th { padding: 4px 0 6px; font-size: .78em; font-weight: 500; color: var(--choix-doux, rgba(0, 0, 0, .58)); text-align: center; }
.choix-jour {
  height: 40px; padding: 0; text-align: center; vertical-align: middle;
  border-radius: var(--choix-rayon, 6px); cursor: pointer; font-variant-numeric: tabular-nums; user-select: none;
}
.choix-jour:hover { background: var(--choix-survol, rgba(0, 0, 0, .07)); }
.choix-jour.est-aujourdhui { box-shadow: inset 0 0 0 1px var(--choix-doux, rgba(0, 0, 0, .58)); }
.choix-jour[aria-selected="true"] { background: var(--choix-accent, #1b1b1b); color: var(--choix-accent-texte, #fff); box-shadow: none; }
.choix-jour[aria-disabled="true"] { color: var(--choix-doux, rgba(0, 0, 0, .58)); opacity: .45; cursor: default; background: transparent; text-decoration: line-through; text-decoration-thickness: 1px; }
.choix-jour:focus-visible { outline: 2px solid var(--choix-accent, #1b1b1b); outline-offset: -2px; }
.choix-note { margin: 8px 4px 0; font-size: .8em; color: var(--choix-doux, rgba(0, 0, 0, .58)); }

@media (max-width: 420px) { .choix-cal { width: calc(100vw - 16px); } }
@media (prefers-reduced-motion: reduce) {
  .choix-pop { animation: none; }
  .choix-chevron { transition: none; }
}
