/* =========================================================
   Alerte de rappel (DESIGN.md 5.5 et 5.6) et bandeau « toast ».
   L'alerte passe au-dessus de tout : panneau Rappels, voile de nuit.
   ========================================================= */
.alerte-fond {
  position: fixed; inset: 0; z-index: 30;
  display: grid; place-items: center; padding: 16px;
  padding: max(16px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) max(16px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));
  background: var(--scrim);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
}
.alerte-fond[hidden] { display: none; }
.alerte {
  width: min(440px, 100%);
  background: var(--sheet-bg); color: var(--sheet-ink);
  border-radius: var(--r-sheet); text-align: center; overflow: hidden;
  box-shadow: var(--sh-float);
}
.alerte-bande {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  background: var(--red-ink); color: #fff; font: 700 18px var(--font); padding: 10px;
}
body.nuit .alerte-bande { color: #1d1d1f; }
.alerte-bande .ic { width: 20px; height: 20px; }
.alerte-corps { padding: 28px 26px 22px; display: grid; gap: 8px; justify-items: center; }
.alerte-ic {
  width: 76px; height: 76px; border-radius: 18px; background: var(--orange); color: #fff;
  display: grid; place-items: center; margin-bottom: 6px;
}
.alerte-ic .ic { width: 42px; height: 42px; }
.alerte h2 { margin: 0; font: 700 28px/1.2 var(--font); overflow-wrap: anywhere; }
.alerte p {
  margin: 0; font: 400 20px var(--font); color: var(--sheet-muted);
  display: flex; gap: 4px 6px; align-items: center; justify-content: center; flex-wrap: wrap;
}
.alerte p > span { display: inline-flex; align-items: center; gap: 8px; }
.alerte .alerte-rang { font: 600 16px var(--font); }
.alerte .qui.deux i { box-shadow: 0 0 0 2px var(--sheet-bg-plein); }
.alerte button {
  display: block; width: 100%; min-height: 64px;
  border: 0; border-top: 1px solid var(--sheet-line); background: transparent;
  font: 400 22px var(--font); color: var(--blue-ink); cursor: pointer;
}
.alerte button.b { font-weight: 700; }
/* Anneau de focus à l'intérieur du bouton (sinon il est coupé par les bords arrondis de la carte) */
.alerte button:focus-visible { outline-offset: -5px; border-radius: 12px; }
.alerte button:disabled { opacity: .5; }

/* Bandeau en bas de l'écran */
.toast {
  position: fixed; left: 50%; bottom: 32px; transform: translateX(-50%); z-index: 40;
  bottom: calc(32px + env(safe-area-inset-bottom));
  display: flex; align-items: center; gap: 16px; max-width: calc(100% - 32px);
  /* max-content : sinon, centré par left: 50 %, le bandeau se tassait sur la moitié de la largeur (iPhone) */
  width: max-content;
  background: rgba(30,30,32,.94); color: #fff; border-radius: var(--r-pill);
  padding: 4px 8px 4px 24px; min-height: 56px; font: 500 18px var(--font); box-shadow: var(--sh-float);
}
.toast[hidden] { display: none; }
.toast span { padding: 10px 0; }
.toast button {
  min-height: 48px; padding: 0 16px; border: 0; border-radius: var(--r-pill);
  background: rgba(255,255,255,.16); color: #fff; font: 700 18px var(--font); cursor: pointer;
}

@media (max-width: 700px) {
  .alerte h2 { font-size: 24px; }
  .alerte p { font-size: 17px; }
  .alerte button { min-height: 56px; font-size: 19px; }
  .toast { font-size: 16px; bottom: calc(20px + env(safe-area-inset-bottom)); border-radius: 20px; }
}
