/* Page « Comment ça marche ? » (view/pages/aide.html). Couleurs de la marque : assets/css/site/00.theme.css */
@layer site {

/* le site fixe le texte du body à 75 % : taille de lecture confortable pour cette page */
.aide { font-size: 1rem; line-height: 1.55; }
.aide { --aide-bleu: var(--ra-skin, #01b7f2); --aide-rouge: var(--ra-rouge, #e01a33); --aide-marine: var(--ra-marine, #2d3e52); }
.aide-section { padding: 4rem 0; }
.aide-fond { background: linear-gradient(180deg, #f3fbfe 0%, #e6f6fd 100%); }
.aide-h2 { color: var(--aide-marine); font-weight: 700; font-size: 1.8rem; margin-bottom: 1rem; }
.aide-intro { max-width: 46rem; font-size: 1.05rem; line-height: 1.6; }

/* ---------------- introduction */
.aide-hero { padding: 3.5rem 0 3rem; background: radial-gradient(circle at 50% 0%, #ffffff 0%, #e6f6fd 70%); }
.aide-titre { color: var(--aide-marine); font-weight: 800; font-size: clamp(1.7rem, 4vw, 2.6rem); line-height: 1.2; margin-bottom: 1rem; }
.aide-sous-titre { max-width: 44rem; font-size: 1.15rem; line-height: 1.6; }
.aide-compteur {
	background: #fff; border-radius: 1.25rem; padding: 1.5rem 1rem; box-shadow: 0 6px 24px rgba(1, 120, 160, .12);
	display: flex; flex-direction: column; align-items: center; gap: .25rem; height: 100%;
}
.aide-compteur > i { font-size: 2rem; color: var(--aide-bleu); }
/* chiffres à largeur fixe : la valeur animée ne fait pas bouger la mise en page (CLS) */
.aide-compteur-valeur { font-size: 2.2rem; font-weight: 800; color: var(--aide-rouge); font-variant-numeric: tabular-nums; min-height: 1.2em; }
.aide-compteur-libelle { color: var(--aide-marine); font-weight: 600; font-size: 1rem; }

/* ---------------- étapes */
.aide-etapes { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: .75rem; margin: 2rem 0 1.5rem; }
.aide-etape {
	position: relative; display: flex; flex-direction: column; align-items: center; gap: .5rem;
	width: 11rem; padding: 1.25rem .75rem 1rem; border: 2px solid transparent; border-radius: 1.25rem;
	background: #fff; box-shadow: 0 4px 16px rgba(0, 0, 0, .06); cursor: pointer;
	transition: transform .25s ease, border-color .25s ease, box-shadow .25s ease;
}
.aide-etape img { width: 72px; height: 72px; object-fit: contain; }
.aide-etape:hover { transform: translateY(-3px); }
.aide-etape.active { border-color: var(--aide-bleu); box-shadow: 0 8px 28px rgba(1, 183, 242, .3); transform: translateY(-4px); }
.aide-etape-num {
	position: absolute; top: -.75rem; left: -.5rem; width: 2rem; height: 2rem; border-radius: 50%;
	background: var(--aide-rouge); color: #fff; font-weight: 800; display: flex; align-items: center; justify-content: center;
}
.aide-etape-titre { font-weight: 700; color: var(--aide-marine); font-size: .95rem; text-align: center; }
.aide-fleche { font-size: 1.5rem; color: var(--aide-rouge); }
.aide-etape-detail {
	max-width: 44rem; margin: 0 auto; background: #fff; border-radius: 1rem; padding: 1.25rem 1.5rem;
	box-shadow: 0 4px 16px rgba(0, 0, 0, .06); font-size: 1.1rem; min-height: 6.5rem;  /* hauteur réservée : pas de saut au changement de texte */
}
.aide-progression { height: 4px; background: #e6f6fd; border-radius: 2px; overflow: hidden; margin-bottom: 1rem; }
.aide-progression span { display: block; height: 100%; width: 0; background: var(--aide-bleu); }
.aide-progression span.anime { animation: aide-progression 6s linear forwards; }
@keyframes aide-progression { from { width: 0; } to { width: 100%; } }

/* ---------------- démonstration */
.aide-demo { background: #fff; border-radius: 1.5rem; padding: 1.5rem; box-shadow: 0 10px 32px rgba(1, 120, 160, .15); position: relative; }
.aide-demo-animal { display: flex; align-items: center; gap: 1rem; margin-bottom: 1rem; }
.aide-jauge { position: relative; height: 2.25rem; background: #fde8eb; border-radius: 1.25rem; overflow: hidden; margin-bottom: 1rem; }
.aide-jauge-remplie { position: absolute; inset: 0 auto 0 0; width: 0; background: linear-gradient(90deg, #ff6b7d, var(--aide-rouge)); transition: width .35s ease; }
.aide-jauge-texte { position: relative; display: flex; height: 100%; align-items: center; justify-content: center; font-weight: 700; color: var(--aide-marine); font-variant-numeric: tabular-nums; }
.aide-demo-bouton { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; }
.aide-demo-bouton:active { transform: scale(.97); }
.aide-demo-pied { display: flex; justify-content: space-between; flex-wrap: wrap; gap: .5rem; margin-top: 1rem; font-size: .95rem; font-variant-numeric: tabular-nums; }
.aide-demo-total { color: #198754; font-weight: 700; }
/* message en surimpression : n'agrandit pas le bloc (CLS) */
.aide-demo-bravo {
	position: absolute; left: 50%; top: 45%; transform: translate(-50%, -50%); white-space: nowrap;
	background: #198754; color: #fff; font-weight: 700; padding: .75rem 1.25rem; border-radius: 2rem;
	box-shadow: 0 8px 24px rgba(25, 135, 84, .35); animation: aide-bravo 1.6s ease forwards; pointer-events: none;
}
@keyframes aide-bravo { 0% { opacity: 0; transform: translate(-50%, -30%) scale(.8); } 15% { opacity: 1; transform: translate(-50%, -50%) scale(1); } 80% { opacity: 1; } 100% { opacity: 0; transform: translate(-50%, -70%); } }
.aide-patte-volante { position: absolute; font-size: 1.5rem; color: var(--aide-rouge); pointer-events: none; animation: aide-vole .9s ease-out forwards; }
@keyframes aide-vole { from { opacity: 1; transform: translateY(0) scale(1); } to { opacity: 0; transform: translateY(-80px) scale(1.4); } }

/* ---------------- Super Pattes */
.aide-carte {
	display: flex; flex-direction: column; gap: .5rem; height: 100%; padding: 1.5rem; border-radius: 1.25rem;
	background: #fff; box-shadow: 0 4px 16px rgba(0, 0, 0, .06); text-decoration: none; color: inherit;
	transition: transform .2s ease, box-shadow .2s ease;
}
.aide-carte:hover { transform: translateY(-4px); box-shadow: 0 10px 28px rgba(1, 120, 160, .2); color: inherit; }
.aide-carte-icone { width: 3.25rem; height: 3.25rem; border-radius: 1rem; background: #e6f6fd; color: var(--aide-bleu); font-size: 1.6rem; display: flex; align-items: center; justify-content: center; }
.aide-carte-titre { font-weight: 800; color: var(--aide-marine); font-size: 1.15rem; }
.aide-carte-texte { flex: 1; }
.aide-carte-action { color: var(--aide-rouge); font-weight: 700; }

/* ---------------- profils */
.aide-profils-onglets { display: flex; justify-content: center; flex-wrap: wrap; gap: .5rem; margin: 1.5rem 0 2rem; }
.aide-profils-onglets button {
	border: 2px solid var(--aide-bleu); background: #fff; color: var(--aide-marine); font-weight: 700;
	border-radius: 2rem; padding: .6rem 1.25rem; transition: background .2s ease, color .2s ease;
}
.aide-profils-onglets button.active { background: var(--aide-bleu); color: #fff; }
.aide-profil { max-width: 46rem; margin: 0 auto; animation: aide-apparait .35s ease; }
@keyframes aide-apparait { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.aide-liste { counter-reset: aide; list-style: none; padding: 0; margin: 0 0 2rem; }
.aide-liste li { counter-increment: aide; position: relative; padding: .9rem 1rem .9rem 3.5rem; margin-bottom: .75rem; background: #fff; border-radius: 1rem; box-shadow: 0 2px 10px rgba(0, 0, 0, .05); font-size: 1.05rem; }
.aide-liste li::before {
	content: counter(aide); position: absolute; left: 1rem; top: 50%; transform: translateY(-50%);
	width: 1.8rem; height: 1.8rem; border-radius: 50%; background: var(--aide-rouge); color: #fff; font-weight: 800;
	display: flex; align-items: center; justify-content: center;
}

/* ---------------- questions */
.aide-faq { max-width: 48rem; }
.aide-faq details { background: #fff; border-radius: 1rem; box-shadow: 0 2px 10px rgba(0, 0, 0, .05); margin-bottom: .75rem; }
.aide-faq summary { cursor: pointer; padding: 1rem 1.25rem; font-weight: 700; color: var(--aide-marine); list-style: none; display: flex; justify-content: space-between; gap: 1rem; }
.aide-faq summary::-webkit-details-marker { display: none; }
.aide-faq summary::after { content: "+"; color: var(--aide-rouge); font-size: 1.4rem; line-height: 1; transition: transform .2s ease; }
.aide-faq details[open] summary::after { transform: rotate(45deg); }
.aide-faq details p { padding: 0 1.25rem 1.25rem; margin: 0; }

/* ---------------- appel final */
.aide-final { padding: 4rem 0; background: linear-gradient(135deg, var(--aide-bleu) 0%, #0a7fb0 100%); }
.aide-final-bouton { display: inline-flex; align-items: center; gap: .5rem; animation: aide-pulse 2.4s ease-in-out infinite; }
@keyframes aide-pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(224, 26, 51, .55); } 50% { box-shadow: 0 0 0 14px rgba(224, 26, 51, 0); } }

/* ---------------- apparition au défilement (classe posée par aide.js : sans JS, tout est visible) */
.aide-js .aide-revele { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; }
.aide-js .aide-revele.visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
	.aide *, .aide *::before, .aide *::after { animation: none !important; transition: none !important; }
	.aide-js .aide-revele { opacity: 1; transform: none; }
}
}
