:root {
	--vert-fonce: #d6c01e;
	--vert-moyen: #eed30a;
	--vert-clair: #ffffd0;
	--vert-border: #fffd69;
}

body {
	background: linear-gradient(to bottom, #ffffff, #ffec5e);
	color: #111111;
	font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
	padding: 2rem;
}

header {
	margin-bottom: 1rem;
}

header nav {
	display: flex;
	justify-content: space-between;
	align-items: center;
}

header nav ul {
	list-style: none;
	margin: 0;
	padding: 0.75rem 0;
	display: flex;
	gap: 1.5rem;
}

header nav ul li strong {
	color: var(--vert-fonce);
	font-size: 1.1rem;
}

header nav ul li a {
	color: var(--vert-fonce);
	text-decoration: none;
	font-weight: 500;
}

header nav ul li a:hover {
	text-decoration: underline;
}

.hero {
	text-align: center;
	padding: 3rem 1rem 2rem;
}

.hero h1 {
	color: var(--vert-fonce);
	margin-bottom: 1rem;
}

.hero p {
	color: #333333;
	max-width: 520px;
	margin: 0 auto;
}

.intro {
	padding: 1.5rem 2rem;
	border-radius: 8px;
	border: 1px solid var(--vert-border);
	background: #ffffff;
	margin-bottom: 2rem;
	text-align: center;
}
.intro h2 {
	color: var(--vert-fonce);
}

.intro p {
	list-style: none;
	padding: 0;
	margin: 0;
	text-align: center;
}

.intro p:first-child {
	font-weight: 600;
	font-size: 1.1rem;
	color: var(--vert-fonce);
	margin-bottom: 0.5rem;
}

.intro p:last-child {
	color: #333333;
}

.avertissement {
	color: #888888;
	font-size: 0.85rem;
	text-align: center;
}

.pictogramme {
	display: flex;
	gap: 1.5rem;
	margin-bottom: 2.5rem;
}

.carte {
	flex: 1 1 150px;
	min-width: 0;
	max-width: 100%;
	background: rgba(255, 255, 255, 0.6);
	border: 1px solid #e5e7eb;
	border-radius: 12px;
	padding: 2rem 1.5rem;
	text-align: center;
	box-shadow: 0 1px 6px rgba(0, 0, 0, 0.06);
}

.carte img {
	width: 70px;
	height: 70px;
	border-radius: 50%;
	object-fit: cover;
	margin: 0 auto 1rem;
	background: var(--vert-clair);
	padding: 6px;
	border: none;
	display: block;
}

.carte p:nth-child(2) {
	font-weight: 700;
	font-size: 1.05rem;
	color: var(--vert-fonce);
	margin-bottom: 0.3rem;
}

.carte p:nth-child(3) {
	color: #777777;
	font-size: 0.8rem;
}
.carte li {
	text-align: left;
}

.introscenario {
	flex: 1 1 200px;
	min-width: 0;
	max-width: 100%;
	background: var(--vert-fonce);
	color: #ffffff;
	border: 1px solid #e5e7eb;
	border-radius: 140px;
	padding: 2rem 2.5rem 3.5rem 2.5rem;
	text-align: center;
	box-shadow: 0 1px 6px rgba(0, 0, 0, 0.06);
	justify-self: center;
}

.introscenario img {
	width: 70px;
	height: 70px;
	border-radius: 50%;
	object-fit: cover;
	margin: 0 auto 1rem;
	background: var(--vert-clair);
	padding: 6px;
	border: none;
	display: block;
}

.introscenario p:nth-child(2) {
	font-weight: 700;
	font-size: 1.05rem;
	color: var(--vert-fonce);
	margin-bottom: 0.3rem;
}

.introscenario p {
	text-align: left;
}

.cta {
	text-align: center;
	margin-bottom: 2rem;
	a {
		color: white;
	}
}

.cta a {
	text-decoration: none;
}

.cta button {
	background-color: var(--vert-moyen);
	border: none;
	border-radius: 50px;
	padding: 0.85rem 2.5rem;
	font-size: 1rem;
	font-weight: 600;
	color: #ffffff;
	cursor: pointer;
	transition:
		background-color 0.2s ease,
		transform 0.2s ease;
}

.cta button:hover {
	background-color: var(--vert-fonce);
	transform: translateY(-2px);
}

footer {
	padding: 1.2rem 1rem;
	margin-top: 2rem;
	text-align: center;
}

footer small,
footer a {
	color: var(--vert-fonce);
}

footer a:hover {
	text-decoration: underline;
}

@media (max-width: 600px) {
	.pictogramme {
		flex-direction: column;
	}
}

/* ============================================
   VIEW_SCENARIO - Styles additionnels
   ============================================ */

/* --- Header : profil personnage (coin haut droite) --- */
.header-character {
	display: flex;
	align-items: center;
	gap: 0.75rem;
}

.header-character img {
	width: 44px;
	height: 44px;
	border-radius: 50%;
	object-fit: cover;
	background: var(--vert-clair);
	padding: 3px;
}

.header-character-info {
	text-align: right;
	line-height: 1.3;
}

.header-character-info strong {
	display: block;
	font-size: 1rem;
	color: var(--vert-fonce);
}

.header-character-info span {
	font-size: 0.82rem;
	color: #666;
}

/* --- Bandeau sélecteur de scénarios --- */
.scenario-selector {
	background: #ffffff;
	border-bottom: 1px solid #e5e7eb;
	padding: 1rem 1.5rem 0.75rem;
	margin-bottom: 1.5rem;
	position: sticky;
	top: 0;
	z-index: 10;
}

.scenario-selector-label {
	font-size: 0.82rem;
	color: #555;
	margin-bottom: 0.6rem;
	font-weight: 500;
}

.scenario-links {
	display: flex;
	gap: 0.75rem;
	flex-wrap: wrap;
}

.scenario-links button {
	flex: 1;
	min-width: 140px;
	background: #f8f8f8;
	border: 2px solid #e5e7eb;
	border-radius: 12px;
	padding: 0.6rem 1rem;
	cursor: pointer;
	text-align: center;
	transition:
		border-color 0.2s,
		background 0.2s;
}

.scenario-links button a {
	display: block;
	font-weight: 700;
	font-size: 0.95rem;
	text-decoration: none;
	color: inherit;
}

.scenario-links button small {
	display: block;
	font-size: 0.7rem;
	color: #888;
	margin-top: 0.2rem;
}

/* Couleurs par scénario */
.scenario-links button:nth-child(1) {
	border-color: #247e00;
	background: #f0faf3;
	color: #247e00;
}

.scenario-links button:nth-child(1) a {
	color: var(--vert-fonce);
}
.scenario-links button:nth-child(1):has(a.active) {
	background: #247e00;
	color: #ffffff;
	a {
		color: #ffffff;
	}
	small {
		color: #73faa5;
	}
}

.scenario-links button:nth-child(2) {
	border-color: #f97316;
	background: #fff4ed;
	color: #c2410c;
}

.scenario-links button:nth-child(2) a {
	color: #c2410c;
}

.scenario-links button:nth-child(3) {
	border-color: #b91c1c;
	background: #fff5f5;
	color: #b91c1c;
}

.scenario-links button:nth-child(3) a {
	color: #b91c1c;
}

.scenario-links button:nth-child(3):has(a.active) {
	background: #b91c1c;
	color: #ffffff;
	a {
		color: #ffffff;
	}
	small {
		color: #f6a3a3;
	}
}

.scenario-links button:nth-child(2):has(a.active) {
	background: #f97316;
	color: #ffffff;
	a {
		color: #ffffff;
	}
	small {
		color: #ffc194;
	}
}

.scenario-links button:has(a.active) {
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}
/* --- Carte personnage (introscenario) --- */
.introscenario {
	display: flex;
	flex-direction: column;
	background: transparent;
	border: none;
	border-radius: 0;
	box-shadow: none;
	padding: 0;
	margin-bottom: 1.5rem;
	text-align: center;
}

.introscenario img {
	width: 56px;
	height: 56px;
	border-radius: 50%;
	border: 2px solid var(--vert-border);
	background: var(--vert-clair);
	padding: 4px;
	margin-bottom: 0.4rem;
}

.introscenario h2 {
	font-size: 1.1rem;
	color: var(--vert-fonce);
	margin: 0 0 0.2rem;
}

.introscenario p {
	font-size: 0.82rem;
	color: #555;
	margin: 0.1rem 0;
	text-align: center;
}

/* --- Timeline des stories --- */
.stories {
	position: relative;
	padding-left: 2rem;
	margin-bottom: 2rem;
}

/* Ligne verticale de la timeline */
.stories::before {
	content: "";
	position: absolute;
	left: 0.45rem;
	top: 1rem;
	bottom: 1rem;
	width: 2px;
	background: linear-gradient(to bottom, #3b82f6, #cbd5e1);
	border-radius: 2px;
}

/* Chaque phase = un <details> */
.stories details {
	position: relative;
	background: #ffffff;
	border: 1px solid #e5e7eb;
	border-radius: 12px;
	margin-bottom: 1rem;
	padding: 1rem 1.25rem;
	box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
	transition: box-shadow 0.2s;
}

.stories details:hover {
	box-shadow: 0 3px 10px rgba(0, 0, 0, 0.09);
}

/* Point de la timeline */
.stories details::before {
	content: "";
	position: absolute;
	left: -1.75rem;
	top: 1.1rem;
	width: 12px;
	height: 12px;
	border-radius: 50%;
	background: #cbd5e1;
	border: 2px solid #ffffff;
	box-shadow: 0 0 0 2px #cbd5e1;
}

/* Phase ouverte = point bleu + bordure bleue */

/* Le summary = en-tête cliquable de la phase */
.stories details summary {
	display: flex;
	justify-content: space-between;
	align-items: center;
	cursor: pointer;
	list-style: none; /* retire le triangle natif */
	gap: 1rem;
}

.stories details summary::-webkit-details-marker {
	display: none; /* retire le triangle sur Safari */
}

.stories details summary h1 {
	font-size: 1rem;
	font-weight: 600;
	color: #111;
	margin: 0;
}

.stories details summary h2 {
	font-size: 0.82rem;
	font-weight: 400;
	color: #777;
	margin: 0.15rem 0 0;
}

.stories details summary .summary-left {
	flex: 1;
}

/* Flèche custom à droite */
.stories details summary::after {
	content: "›";
	font-size: 1.4rem;
	color: #aaa;
	transform: rotate(90deg);
	transition: transform 0.2s;
	flex-shrink: 0;
}

.stories details[open] summary::after {
	transform: rotate(270deg);
}

.badge-rcp {
	background: var(--vert-fonce);
	color: #ffffff;
	font-size: 0.75rem;
	font-weight: 700;
	border-radius: 50px;
	padding: 0.25rem 0.75rem;
	flex-shrink: 0;
}

.story-content {
	margin-top: 1rem;
	padding-top: 1rem;
	border-top: 1px solid #f0f0f0;
	font-size: 0.95rem;
	line-height: 1.7;
	color: #222;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 1rem;
}

.story-content img {
	width: 100%;
	max-width: 600px;
	height: auto;
	border-radius: 10px;
	object-fit: cover;
	display: block;
}

section:has(h2) {
	background: #ffffff;
	border: 1px solid var(--vert-border);
	border-radius: 12px;
	padding: 1.25rem 1.5rem;
	margin-top: 1.5rem;
}

section h2 {
	color: var(--vert-fonce);
	font-size: 1rem;
	margin-bottom: 0.5rem;
}

/* --- Responsive --- */
@media (max-width: 600px) {
	.scenario-links {
		flex-direction: column;
	}

	.stories {
		padding-left: 1.5rem;
	}
}
/* --- Bloc fin de parcours : caché par défaut --- */
#fin-parcours {
	display: none;
	margin-top: 1.5rem;
}

/* Visible uniquement quand le dernier <details> est ouvert */
.stories:has(details:last-of-type[open]) ~ #fin-parcours {
	display: block;
}

.impact-section {
	background: #ffffff;
	border: 1px solid var(--vert-border);
	border-radius: 12px;
	padding: 1.25rem 1.5rem;
	margin-bottom: 1.5rem;
}

.impact-section h2 {
	color: var(--vert-fonce);
	font-size: 1rem;
	margin-bottom: 0.5rem;
}

.fin-block {
	background: #ffffff;
	border: 1px solid #e5e7eb;
	border-radius: 16px;
	padding: 2.5rem 2rem;
	text-align: center;
	box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}

.fin-checkmark {
	width: 64px;
	height: 64px;
	border-radius: 50%;
	background: linear-gradient(135deg, #06b6d4, #10b981);
	color: #ffffff;
	font-size: 1.8rem;
	font-weight: 700;
	display: flex;
	align-items: center;
	justify-content: center;
	margin: 0 auto 1.25rem;
}

.fin-block h3 {
	font-size: 1.15rem;
	font-weight: 700;
	color: #111;
	margin-bottom: 0.6rem;
}

.fin-block > p {
	color: #555;
	font-size: 0.92rem;
	max-width: 520px;
	margin: 0 auto 1.5rem;
	line-height: 1.6;
}

.sources-block {
	display: flex;
	align-items: flex-start;
	gap: 1rem;
	background: #f0f7ff;
	border: 1px solid #bfdbfe;
	border-radius: 12px;
	padding: 1rem 1.25rem;
	text-align: left;
	margin-bottom: 1.5rem;
}

.sources-icon {
	font-size: 1.4rem;
	flex-shrink: 0;
	margin-top: 0.1rem;
}

.sources-block strong {
	display: block;
	font-size: 0.95rem;
	color: #111;
	margin-bottom: 0.35rem;
}

.sources-block p {
	font-size: 0.85rem;
	color: #444;
	margin: 0 0 0.5rem;
	line-height: 1.5;
}

.sources-block a {
	font-size: 0.85rem;
	color: #2563eb;
	text-decoration: none;
	font-weight: 500;
}

.sources-block a:hover {
	text-decoration: underline;
}

.btn-autre-personnage:hover {
	opacity: 0.9;
	transform: translateY(-2px);
}
#fin-parcours {
	display: none;
}

.stories:has(details:last-of-type[open]) ~ #fin-parcours {
	display: block;
}
