.ij-cal {
  --ij-vert: #0a3c3c;
  --ij-mauve: #a387da;
  --ij-lime: #d6ea66;
  --ij-sarcelle: #2f7a74;
  --ij-fond: #e3eee6;
  --ij-ligne: rgba(27, 58, 60, 0.18);
  color: var(--ij-vert);
  font-family: inherit;
  font-size: 0.95rem;
  max-width: none; /* Prend toute la largeur de la colonne de texte. */
  /* Retrait pour s'aligner sur le texte du thème (trait mauve + marge). Ajustable. */
  margin-left: var(--ij-retrait, 22px);
}
.ij-cal__vide[hidden] { display: none; }
.ij-cal *, .ij-cal *::before, .ij-cal *::after { box-sizing: border-box; }

.ij-cal__head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 2px; }
.ij-cal__titre { margin: 0; font-size: 1.05rem; font-weight: 600; text-transform: capitalize; color: var(--ij-mauve); letter-spacing: 0.05em; }
.ij-cal__nav {
  width: 32px; height: 32px; padding: 0; border-radius: 50%;
  border: 1px solid var(--ij-vert); background: transparent; color: var(--ij-vert);
  font-size: 0.95rem; line-height: 1; cursor: pointer;
}
.ij-cal__nav:hover:not(:disabled) { background: var(--ij-vert); color: #fff; }
.ij-cal__nav:disabled { opacity: 0.3; cursor: default; }
.ij-cal__nav:focus-visible { outline: 3px solid var(--ij-mauve); outline-offset: 2px; }
.ij-cal__heures { margin: 0 0 8px; font-size: 0.9rem; }

.ij-cal__grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); border-top: 1px solid var(--ij-vert); border-left: 1px solid var(--ij-vert); }
.ij-cal__dow { padding: 4px 2px; text-align: center; font-size: 0.65rem; font-weight: 600; letter-spacing: 0.12em; border-right: 1px solid var(--ij-vert); border-bottom: 1px solid var(--ij-vert); }
.ij-day, .ij-blank { min-height: 48px; padding: 3px 4px; border-right: 1px solid var(--ij-vert); border-bottom: 1px solid var(--ij-vert); display: flex; flex-direction: column; }
.ij-day__num { align-self: flex-end; font-size: 0.8rem; line-height: 1.1; color: var(--ij-mauve); font-variant-numeric: tabular-nums; }
.ij-day__dow { display: none; }
.ij-day__slots { display: flex; flex-wrap: wrap; gap: 2px; margin-top: auto; }
.ij-day.is-past { opacity: 0.35; }
.ij-day.is-today { box-shadow: inset 0 0 0 2px var(--ij-mauve); }
.ij-day.is-today .ij-day__num { font-weight: 700; color: var(--ij-vert); }

.ij-chip {
  position: relative; display: inline-flex; align-items: center; justify-content: center;
  min-width: 22px; height: 20px; padding: 0 3px;
  border-radius: 8px 2px 8px 2px;
  font-size: 0.6rem; font-weight: 700; letter-spacing: 0.02em;
}
.ij-chip--vert { background: var(--ij-vert); color: #fff; }
.ij-chip--mauve { background: var(--ij-mauve); color: var(--ij-vert); }
.ij-chip--lime { background: var(--ij-lime); color: var(--ij-vert); }
.ij-chip--sarcelle { background: var(--ij-sarcelle); color: #fff; }
.ij-chip--blanc { background: #fff; color: var(--ij-vert); box-shadow: inset 0 0 0 1.5px var(--ij-vert); }
.ij-chip--gris { background: #d9dedb; color: var(--ij-vert); }
.ij-chip__d {
  position: absolute; top: -5px; right: -5px;
  width: 14px; height: 14px; border-radius: 50%;
  background: #fff; color: var(--ij-vert); border: 1px solid var(--ij-vert);
  font-size: 0.55rem; line-height: 12px; text-align: center;
}
.ij-chip--gris .ij-chip__d { position: static; }

.ij-cal__vide { margin: 8px 0 0; font-style: italic; font-size: 0.9rem; }
.ij-cal__legende { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 6px; }
.ij-cal .ij-cal__legende li { display: flex; align-items: center; gap: 8px; margin: 0; padding: 0; font-size: 0.85rem; }
.ij-cal .ij-cal__legende li::before { content: none; }
.ij-cal__legende .ij-cal__h { font-size: 0.8rem; opacity: 0.85; }

.ij-sr { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* Mobile : liste des jours de présence à venir */
@media (max-width: 600px) {
  .ij-cal__grid { display: block; border: 0; border-top: 1px solid var(--ij-vert); }
  .ij-cal__dow, .ij-blank, .ij-day.is-empty, .ij-day.is-past { display: none; }
  .ij-day { min-height: 0; flex-direction: row; align-items: center; gap: 10px; border: 0; border-bottom: 1px solid var(--ij-ligne); padding: 6px 4px; }
  .ij-day__num { align-self: center; width: 22px; text-align: right; font-size: 0.95rem; font-weight: 600; }
  .ij-day__dow { display: block; text-transform: capitalize; }
  .ij-day__slots { margin: 0 0 0 auto; }
  .ij-day.is-today { box-shadow: none; background: rgba(160, 138, 216, 0.15); }
}
