/* Pages « calendrier Ramadan » (hub et ville) — feuille autonome, servie telle quelle.
   Charte : docs/BRANDING.md. Rose #B834A0, cyan #00AEEF, nuit #0c0510 / #030005, texte blanc ;
   AUCUN or, beige ni brun. Titres en Fira Sans Condensed, texte en Lato (déjà chargées par layout.html).
   Courbe maison cubic-bezier(.2,.7,.2,1), transitions >= 250 ms, prefers-reduced-motion respecté.
   Échelle typographique : 16 / 18 / 22 / 28-40 px. */


.rtv-prieres, .rtv-cap, .rtv-cap-fond {
  --rtv-rose: #B834A0;
  --rtv-cyan: #00AEEF;
  --rtv-nuit: #0c0510;
  --rtv-nuit-2: #030005;
  --rtv-rose-deep: #3a0820;
  --rtv-rose-soft: #ffd7eb;
  --rtv-muted: rgba(255, 255, 255, .62);
  --rtv-trait: rgba(255, 255, 255, .13);
  --rtv-courbe: cubic-bezier(.2, .7, .2, 1);
}
.rtv-prieres {
  max-width: 820px;
  margin: 0 auto;
  padding: 28px 16px 72px;
  color: #fff;
  font-family: 'Lato', sans-serif;
  font-size: 16px;
  line-height: 1.6;
}
.rtv-prieres *, .rtv-prieres *::before, .rtv-prieres *::after { box-sizing: border-box; }
.rtv-prieres a { color: var(--rtv-cyan); text-decoration: underline; text-underline-offset: 3px; transition: color .3s var(--rtv-courbe); }
.rtv-prieres a:hover { color: #6fd2ff; }
.rtv-prieres a:focus-visible, .rtv-prieres button:focus-visible, .rtv-prieres input:focus-visible,
.rtv-prieres summary:focus-visible, .rtv-prieres .rtv-tableau:focus-visible { outline: 2px solid var(--rtv-cyan); outline-offset: 3px; }
.rtv-muted { color: var(--rtv-muted); }
.rtv-sr { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

/* ---------------------------------------------------------------- titres */
.rtv-prieres h1, .rtv-prieres h2, .rtv-prieres h3 { font-family: 'Fira Sans Condensed', sans-serif; line-height: 1.2; margin: 0; }
.rtv-prieres h1 { font-size: clamp(28px, 7vw, 40px); font-weight: 700; }
.rtv-prieres h2 { font-size: 22px; font-weight: 600; margin-bottom: 12px; }
.rtv-prieres h3.rtv-q { font-size: 18px; font-weight: 600; margin: 22px 0 6px; }
.rtv-prieres p { margin: 0 0 12px; }

/* ---------------------------------------------------------------- fil d'Ariane */
.rtv-fil { margin: 0 0 18px; font-size: 16px; color: var(--rtv-muted); }
.rtv-fil ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 8px; }
.rtv-fil li + li::before { content: "›"; margin-right: 8px; color: var(--rtv-muted); }

.rtv-entete { margin-bottom: 20px; }
.rtv-entete p { margin: 8px 0 0; }

/* ---------------------------------------------------------------- blocs */
.rtv-bloc { margin: 0 0 34px; }
.rtv-lead { font-size: 18px; }
.rtv-reponse .rtv-lead { padding-left: 14px; border-left: 3px solid var(--rtv-rose); }
.rtv-liste { margin: 0; padding-left: 22px; }
.rtv-liste li { margin-bottom: 6px; }

/* ---------------------------------------------------------------- prochaine échéance (hauteur réservée) */
.rtv-prochaine {
  min-height: 132px; margin: 0 0 28px; padding: 16px 18px;
  border: 1px solid rgba(184, 52, 160, .65); border-radius: 14px;
  background: linear-gradient(135deg, rgba(58, 8, 32, .75), rgba(12, 5, 16, .9));
}
.rtv-prochaine p { margin: 0; }
.rtv-prochaine-titre { font-size: 16px; color: var(--rtv-rose-soft); letter-spacing: .06em; text-transform: uppercase; font-family: 'Fira Sans Condensed', sans-serif; }
.rtv-prochaine-valeur { font-family: 'Fira Sans Condensed', sans-serif; font-size: 28px; font-weight: 700; line-height: 1.3; }
.rtv-prochaine-reste { font-size: 18px; }
.rtv-heure { font-family: 'Fira Sans Condensed', sans-serif; font-variant-numeric: tabular-nums; }
.rtv-prochaine-reste .rtv-heure { color: var(--rtv-cyan); font-weight: 600; }
.rtv-decompte { min-height: 28px; margin: 0 0 18px; font-family: 'Fira Sans Condensed', sans-serif; font-size: 18px; font-weight: 600; color: var(--rtv-rose-soft); }
.rtv-decompte:empty { display: none; }

/* ---------------------------------------------------------------- boutons */
.rtv-boutons { display: flex; flex-wrap: wrap; gap: 12px; margin: 0 0 8px; }
.rtv-btn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 10px 20px;
  border: 1px solid var(--rtv-trait); border-radius: 10px; background: rgba(255, 255, 255, .05); color: #fff;
  font-family: 'Fira Sans Condensed', sans-serif; font-size: 16px; font-weight: 600; text-decoration: none; cursor: pointer;
  transition: background .3s var(--rtv-courbe), border-color .3s var(--rtv-courbe), transform .3s var(--rtv-courbe);
}
.rtv-btn:hover { background: rgba(255, 255, 255, .11); border-color: rgba(255, 255, 255, .3); color: #fff; }
.rtv-btn.rtv-btn--principal { background: var(--rtv-rose); border-color: var(--rtv-rose); }
.rtv-btn.rtv-btn--principal:hover { background: #cf44b7; border-color: #cf44b7; }
.rtv-prieres a.rtv-btn, .rtv-prieres a.rtv-btn:hover { color: #fff; text-decoration: none; }
.rtv-btn:disabled { opacity: .6; cursor: default; }

/* ---------------------------------------------------------------- tableaux */
.rtv-tableau { overflow-x: auto; border: 1px solid var(--rtv-trait); border-radius: 12px; background: var(--rtv-nuit); -webkit-overflow-scrolling: touch; }
.rtv-table { width: 100%; border-collapse: separate; border-spacing: 0; font-variant-numeric: tabular-nums; font-size: 16px; }
.rtv-table th, .rtv-table td { padding: 10px 12px; text-align: center; white-space: nowrap; border-bottom: 1px solid rgba(255, 255, 255, .08); font-weight: 400; }
.rtv-table thead th { font-family: 'Fira Sans Condensed', sans-serif; font-weight: 600; color: var(--rtv-rose-soft); background: var(--rtv-rose-deep); border-bottom: 1px solid var(--rtv-trait); }
.rtv-table tbody tr:last-child > * { border-bottom: 0; }
.rtv-table--complet { min-width: 700px; }
.rtv-table tbody th[scope="row"] { text-align: left; font-weight: 600; font-family: 'Fira Sans Condensed', sans-serif; }
.rtv-col-iftar { color: var(--rtv-rose-soft); font-weight: 700; }
/* N° et date restent visibles quand le tableau défile (cellules opaques : rien ne transparaît dessous). */
.rtv-col-n { position: sticky; left: 0; z-index: 2; width: 44px; min-width: 44px; background: var(--rtv-nuit); color: var(--rtv-muted); padding-left: 8px; padding-right: 8px; }
.rtv-col-date { position: sticky; left: 44px; z-index: 2; background: var(--rtv-nuit); }
.rtv-table thead .rtv-col-n, .rtv-table thead .rtv-col-date { background: var(--rtv-rose-deep); z-index: 3; color: var(--rtv-rose-soft); }
.rtv-table--complet .rtv-col-date { box-shadow: 6px 0 8px -6px rgba(0, 0, 0, .7); }
.rtv-table tbody tr.rtv-today > td, .rtv-table tbody tr.rtv-today > th { background: #3a1032; color: #fff; }
.rtv-table tbody tr.rtv-today > .rtv-col-n, .rtv-table tbody tr.rtv-today > .rtv-col-date { background: #3a1032; color: #fff; }
.rtv-table tbody tr.rtv-today > th:first-of-type, .rtv-table tbody tr.rtv-today > td:first-child { box-shadow: inset 3px 0 0 var(--rtv-rose); }
.rtv-table--simple { border: 1px solid var(--rtv-trait); border-radius: 12px; overflow: hidden; background: var(--rtv-nuit); }
.rtv-table--simple th, .rtv-table--simple td { text-align: left; white-space: normal; }
.rtv-table--simple tbody th { font-weight: 600; }
@media (max-width: 559px) {
  .rtv-col-n { display: none; }
  .rtv-col-date { left: 0; }
  .rtv-table th, .rtv-table td { padding: 10px 9px; }
  .rtv-table--complet { min-width: 0; }
}
.rtv-defilement { display: block; margin: 0 0 8px; font-size: 16px; }
@media (min-width: 760px) { .rtv-defilement { display: none; } }

/* ---------------------------------------------------------------- listes de villes */
.rtv-filtre { display: block; margin: 0 0 6px; color: var(--rtv-muted); }
.rtv-champ { width: 100%; max-width: 420px; min-height: 44px; padding: 10px 14px; border: 1px solid var(--rtv-trait); border-radius: 10px; background: rgba(255, 255, 255, .06); color: #fff; font: inherit; }
.rtv-champ::placeholder { color: rgba(255, 255, 255, .45); }
.rtv-villes, .rtv-voisines { list-style: none; margin: 14px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 16px; }
.rtv-villes li, .rtv-voisines li { min-height: 36px; display: flex; align-items: center; flex-wrap: wrap; gap: 0 8px; }
.rtv-voisines { grid-template-columns: 1fr; }
.rtv-villes li[hidden] { display: none; }
@media (min-width: 640px) { .rtv-villes { grid-template-columns: repeat(3, minmax(0, 1fr)); } .rtv-voisines { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.rtv-plus { margin-top: 14px; }
.rtv-plus summary { cursor: pointer; min-height: 44px; display: flex; align-items: center; color: var(--rtv-cyan); }

/* ---------------------------------------------------------------- capture e-mail (montée par JavaScript) */
/* Emplacement vide : hauteur nulle mais toujours dans le flux (IntersectionObserver ne voit pas un élément display:none). */
#rtv-capture:empty { height: 0; margin: 0; padding: 0; overflow: hidden; }
#rtv-capture.rtv-cap-ouvert { margin: 0 0 34px; }
.rtv-cap { position: relative; padding: 20px 18px; border: 1px solid rgba(184, 52, 160, .65); border-radius: 14px; background: linear-gradient(135deg, rgba(58, 8, 32, .8), var(--rtv-nuit)); color: #fff; font-family: 'Lato', sans-serif; font-size: 16px; line-height: 1.5; }
.rtv-cap--A { width: min(440px, calc(100vw - 32px)); max-height: calc(100vh - 32px); overflow: auto; background: var(--rtv-nuit); box-shadow: 0 30px 80px -20px #000; }
.rtv-cap--C { position: fixed; left: 0; right: 0; bottom: 0; z-index: 9000; border-radius: 14px 14px 0 0; max-height: 70vh; overflow: auto; background: var(--rtv-nuit); }
.rtv-cap-fond { position: fixed; inset: 0; z-index: 99998; display: flex; align-items: center; justify-content: center; padding: 16px; background: rgba(0, 0, 0, .65); }
.rtv-cap-fermer { position: absolute; top: 8px; right: 8px; width: 44px; height: 44px; border: 0; border-radius: 50%; background: transparent; color: rgba(255, 255, 255, .7); font-size: 26px; cursor: pointer; }
.rtv-cap-fermer:hover { color: #fff; background: rgba(255, 255, 255, .08); }
.rtv-cap-titre { margin: 0 44px 14px 0; font-family: 'Fira Sans Condensed', sans-serif; font-size: 18px; font-weight: 600; }
.rtv-cap-form { display: grid; gap: 12px; }
.rtv-cap-champ { display: grid; gap: 4px; }
.rtv-cap-champ input[type="email"], .rtv-cap-champ input[type="text"] { min-height: 44px; padding: 10px 12px; border: 1px solid var(--rtv-trait); border-radius: 10px; background: rgba(255, 255, 255, .07); color: #fff; font: inherit; }
.rtv-cap-coche { display: flex; gap: 10px; align-items: flex-start; }
.rtv-cap-coche input { width: 22px; height: 22px; margin-top: 2px; accent-color: var(--rtv-rose); flex: 0 0 auto; }
.rtv-cap-piege { position: absolute; left: -9999px; top: -9999px; width: 1px; height: 1px; overflow: hidden; }
.rtv-cap-msg { margin: 0; color: var(--rtv-rose-soft); }
.rtv-cap-msg:empty { display: none; }

@media (prefers-reduced-motion: reduce) {
  .rtv-prieres *, .rtv-cap, .rtv-cap * { transition: none !important; animation: none !important; }
}

/* =====================================================================================================
   Pages « heure de prière » (hub et ville) — AJOUTS, rien d'existant n'est modifié. Échelle typographique :
   16 / 18 / 22 / 28-40 px. Aucun or : rose, cyan, nuit.
   ===================================================================================================== */

/* Carte « prochaine prière » : le nom et l'heure, puis le compte à rebours, en haut de la page. Hauteur réservée (aucun décalage). */
.rtv-prochaine--heure { min-height: 176px; }
.rtv-prochaine--heure .rtv-prochaine-valeur { margin-top: 4px; }
.rtv-prochaine--heure .rtv-prochaine-reste { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 10px; margin-top: 6px; }
.rtv-prochaine--heure .rtv-compte { font-size: clamp(28px, 9vw, 40px); font-weight: 700; line-height: 1.2; white-space: nowrap; }

/* Tableau du jour (2 colonnes) */
.rtv-table--jour th, .rtv-table--jour td { text-align: left; font-family: 'Fira Sans Condensed', sans-serif; }
.rtv-table--jour td { text-align: right; font-weight: 600; font-variant-numeric: tabular-nums; }
.rtv-table--jour thead th:last-child { text-align: right; }
.rtv-table--jour tbody tr { transition: background .3s var(--rtv-courbe), color .3s var(--rtv-courbe); }
.rtv-table--jour tbody tr.rtv-prochaine-ligne > * { background: #3a1032; color: #fff; }
.rtv-table--jour tbody tr.rtv-prochaine-ligne > th { box-shadow: inset 3px 0 0 var(--rtv-rose); }
.rtv-table--jour tbody tr.rtv-passee > * { color: var(--rtv-muted); }

/* Semaine et mois : première colonne fixe, tableau défilant dans son conteneur */
.rtv-table--heure { min-width: 520px; }
.rtv-table--heure .rtv-col-jour { position: sticky; left: 0; z-index: 2; text-align: left; background: var(--rtv-nuit); box-shadow: 6px 0 8px -6px rgba(0, 0, 0, .7); }
.rtv-table--heure thead .rtv-col-jour { background: var(--rtv-rose-deep); z-index: 3; color: var(--rtv-rose-soft); }
.rtv-table--heure tbody tr.rtv-today > .rtv-col-jour { background: #3a1032; color: #fff; }
.rtv-table--mois { min-width: 560px; }
@media (max-width: 559px) { .rtv-table--heure, .rtv-table--mois { min-width: 0; } }

/* Moments de la journée : le moment en cours est signalé par prieres_heure.js */
.rtv-moments { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 6px; }
.rtv-moments li { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 2px 12px; padding: 10px 14px; border: 1px solid var(--rtv-trait); border-radius: 10px; background: rgba(255, 255, 255, .04); transition: background .3s var(--rtv-courbe), border-color .3s var(--rtv-courbe); }
.rtv-moment-nom { font-family: 'Fira Sans Condensed', sans-serif; font-weight: 600; }
.rtv-moments li.rtv-moment-actuel { border-color: rgba(184, 52, 160, .8); background: rgba(184, 52, 160, .2); }
.rtv-moments li.rtv-moment-actuel .rtv-moment-nom::after { content: " · en ce moment"; font-weight: 400; color: var(--rtv-rose-soft); }

/* Comprendre chaque prière */
.rtv-def { margin: 0; }
.rtv-def dt { margin: 16px 0 4px; font-family: 'Fira Sans Condensed', sans-serif; font-size: 18px; font-weight: 600; }
.rtv-def dd { margin: 0; }

/* Recherche de ville */
.rtv-recherche-ligne { display: flex; flex-wrap: wrap; gap: 12px; }
.rtv-recherche-ligne .rtv-champ { flex: 1 1 220px; max-width: none; }

/* Listes de données locales (communes, mosquées) : respiration avant le paragraphe suivant */
.rtv-prieres .rtv-liste + p, .rtv-prieres .rtv-liste + details, .rtv-prieres .rtv-def + p { margin-top: 12px; }
