/* ==========================================================================
   FSH — Tunnel de dons
   Étape 1 (sélection du projet) : reprise fidèle de la maquette fournie.
   Le reste du tunnel (montant, identité, adresse, paiement) est le widget
   RaiseNow Tamaro : voir la section "TAMARO — best effort" en bas de fichier
   pour ce qui peut / ne peut pas être stylé depuis ce CSS.
   ========================================================================== */

.fsh-td {
  --fsh-red: #cc0000;
  --fsh-red-dark: #a30000;
  --fsh-red-tint: #fdebeb;
  --fsh-red-tint-2: #fbe0e0;
  --ink: #161616;
  --n50: #fafafa;
  --n100: #f5f5f6;
  --n200: #e4e4e6;
  --n300: #d2d2d5;
  --n400: #a3a3a8;
  --n500: #76767c;
  --n600: #56565b;
  --n700: #3a3a3e;

  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Plus Jakarta Sans", Arial, sans-serif;
  color: var(--ink);
  max-width: 560px;
  margin: 0 auto;
  box-sizing: border-box;
}
.fsh-td *,
.fsh-td *::before,
.fsh-td *::after { box-sizing: border-box; }

/* progress bar */
.fsh-td-top { margin-bottom: 6px; }
.fsh-td-progress .pp {
  display: flex; justify-content: space-between; align-items: center; margin-bottom: 7px;
}
.fsh-td-progress .lbl { font-size: 12px; font-weight: 600; color: var(--n600); }
.fsh-td-progress .cnt { font-family: ui-monospace, monospace; font-size: 11px; color: var(--n500); }
.fsh-td-bar { height: 6px; border-radius: 999px; background: var(--n200); overflow: hidden; }
.fsh-td-bar i { display: block; height: 100%; border-radius: 999px; background: var(--fsh-red); transition: width .3s; }

.fsh-td-h2 { font-size: 22px; font-weight: 800; letter-spacing: -.01em; margin: 16px 0 4px; }
.fsh-td-lede { font-size: 14px; color: var(--n500); margin: 0 0 16px; }

/* search */
.fsh-td-search {
  display: flex; align-items: center; gap: 9px; border: 1.5px solid var(--n200); border-radius: 12px;
  padding: 11px 13px; margin-bottom: 14px; background: var(--n50);
}
.fsh-td-search svg { stroke: var(--n400); flex: 0 0 auto; }
.fsh-td-search input {
  border: none; background: none; outline: none; font-size: 14px; width: 100%; color: var(--ink);
}

/* grid of project cards */
.fsh-td-grid { display: grid; grid-template-columns: 1fr; gap: 10px; }
@media (min-width: 640px) {
  .fsh-td-grid { grid-template-columns: 1fr 1fr; }
}

.fsh-td-card {
  display: flex; align-items: center; gap: 12px; border: 1.5px solid var(--n200); border-radius: 14px;
  padding: 13px 14px; background: #fff; cursor: pointer; position: relative; transition: .15s;
  min-height: 56px;
}
.fsh-td-card:hover { border-color: var(--n300); }
.fsh-td-card:focus-visible { outline: 2px solid var(--fsh-red); outline-offset: 2px; }
.fsh-td-card .ico {
  width: 38px; height: 38px; border-radius: 11px; background: var(--n100);
  display: grid; place-items: center; flex: 0 0 auto; color: var(--fsh-red);
}
.fsh-td-card .txt b { display: block; font-size: 14px; font-weight: 700; color: var(--ink); line-height: 1.2; }
.fsh-td-card .txt span { display: block; font-size: 11.5px; color: var(--n500); margin-top: 2px; line-height: 1.3; }
.fsh-td-card .tick {
  position: absolute; top: 11px; right: 11px; width: 20px; height: 20px; border-radius: 50%;
  border: 1.5px solid var(--n300); display: grid; place-items: center; background: #fff; color: #fff;
}
.fsh-td-card[aria-checked="true"] {
  border-color: var(--fsh-red); border-width: 2px; background: var(--fsh-red-tint);
  box-shadow: 0 6px 16px -10px rgba(204, 0, 0, .5);
}
.fsh-td-card[aria-checked="true"] .ico { background: var(--fsh-red-tint-2); }
.fsh-td-card[aria-checked="true"] .tick { background: var(--fsh-red); border-color: var(--fsh-red); }

.fsh-td-noresult { color: var(--n500); font-size: 13.5px; padding: 20px 4px; text-align: center; }

/* CTA button */
.fsh-td-btn {
  width: 100%; margin-top: 18px; border: none; border-radius: 13px; background: var(--n200);
  color: var(--n500); font-weight: 700; font-size: 15px; padding: 15px 16px; cursor: not-allowed;
  display: flex; align-items: center; justify-content: center; gap: 8px; transition: .15s;
}
.fsh-td-btn:not(:disabled) {
  background: var(--fsh-red); color: #fff; cursor: pointer; box-shadow: 0 10px 24px -12px rgba(204, 0, 0, .55);
}
.fsh-td-btn:not(:disabled):hover { background: var(--fsh-red-dark); }

/* back link on step 2 */
.fsh-td-back {
  display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--n600);
  background: none; border: none; cursor: pointer; padding: 0; margin-bottom: 14px;
}
.fsh-td-back:hover { color: var(--fsh-red); }

/* ==========================================================================
   TAMARO — best effort
   RaiseNow rend le widget Tamaro dans son propre balisage HTML (que nous ne
   contrôlons pas et qui peut changer d'une version à l'autre). L'essentiel
   du thème (couleurs de marque, police, boutons) se règle normalement dans
   RaiseNow Hub (Réglages du widget > Branding). Ce bloc ne fait qu'un
   ajustement minimal du conteneur : à affiner via l'inspecteur du navigateur
   une fois le widget réellement affiché sur test.fsh.ngo.
   ========================================================================== */
.fsh-td-step-tamaro { min-height: 200px; }
#fsh-td-tamaro-container { font-family: inherit; }

/* Mode "Tamaro seul" : le plugin ne fournit qu'un conteneur, tout le style
   visible vient soit de RaiseNow Hub, soit du CSS personnalisé (section 6
   des réglages), soit de vos propres règles ciblant le DOM réel de Tamaro. */
.fsh-td--tamaro-only #fsh-td-tamaro-container { min-height: 200px; }
