/*
 * TEC Séjours : styles publics.
 * Inspirés des pages vitrines du site (ex. /nos-colos/mondes-imaginaires/) :
 * fond blanc, sections séparées par un filet noir fin, titres Montserrat noirs soulignés
 * d'un court trait jaune, texte gris Luciole, encadrés gris clair, puces simples.
 */

:root {
	--tecs-vert: var(--wp-admin-theme-color, #002a00);
	--tecs-vert-survol: #0d3b12;
	--tecs-vert-clair: var(--wp-admin-theme-color-lighter, #4a8150);
	--tecs-jaune: var(--primary-color, #f9ea3e);
	--tecs-jaune-fonce: var(--primary-color-darker-10, #daca16);
	--tecs-titre: #000;
	--tecs-texte: #666;
	--tecs-encre: #333;
	--tecs-gris: #777;
	--tecs-encadre: #f2f2f2;
	--tecs-trait: #e2e2e2;
	--tecs-filet: #000;
	--tecs-rouge: #b3261e;
	--tecs-police-titres: "Montserrat", sans-serif;
}

/* Masque le formulaire de réservation de WP Travel Engine (y compris sa fenêtre surgissante) quand l'option est active. */
.tecs-sans-resa-wte .wte-popup-booking-wrapper,
.tecs-sans-resa-wte .wpte-bf-outer,
.tecs-sans-resa-wte .wte-bf-price-wrap,
.tecs-sans-resa-wte .wpte-booking-area {
	display: none !important;
}

/* Masque l'encadré « infos clés » de WP Travel Engine (option, pages séjours gérées). */
.tecs-sans-infos-wte .secondary-trip-info {
	display: none !important;
}

/* ------------------------------------------------------------------
 * Éléments communs
 * ------------------------------------------------------------------ */

/* Titres de section : comme « Présentation du séjour » sur les pages vitrines */
.tecs-essentiel__titre,
.tecs-inscriptions > h2,
.tecs-avis > h2 {
	margin: 0 0 1.1em;
	color: var(--tecs-titre);
	font-family: var(--tecs-police-titres);
	font-size: 1.6em;
	font-weight: 700;
	line-height: 1.2;
}
.tecs-essentiel__titre::after,
.tecs-inscriptions > h2::after,
.tecs-avis > h2::after {
	content: "";
	display: block;
	width: 40px;
	height: 3px;
	margin-top: 0.45em;
	background: var(--tecs-jaune);
}

/* Sous-titres : comme « Les points forts » */
.tecs-tarifs__table caption,
.tecs-inclus__titre,
.tecs-cote__titre {
	color: var(--tecs-titre);
	font-family: var(--tecs-police-titres);
	font-weight: 700;
}

/* Boutons : comme « Voir les disponibilités » sur les pages vitrines (jaune, texte noir souligné) */
.tecs-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.6em;
	padding: 0.85em 1.6em;
	border: 0;
	border-radius: 5px;
	background: var(--tecs-jaune);
	color: #000;
	font-family: "Roboto", var(--button-font, sans-serif);
	font-size: 1em;
	font-weight: 600;
	line-height: 1.2;
	text-transform: none;
	text-decoration: underline;
	text-underline-offset: 3px;
	text-align: center;
	transition: background-color 0.2s linear;
}
.tecs-btn:hover,
.tecs-btn:focus {
	background: var(--tecs-jaune-fonce);
	color: #000;
	text-decoration: underline;
}
.tecs-btn__icone {
	flex: none;
	width: 1.05em;
	height: 1.05em;
}
.tecs-btn--plein {
	display: flex;
	width: 100%;
}

/* Liens : soulignés, comme dans le texte du site */
.tecs-lien-aide,
.tecs-lien,
.tecs-aide a,
.tecs-session__secours a,
.tecs-fait dd a,
.tecs-tarifs__aide a {
	color: var(--tecs-encre);
	font-weight: 600;
	text-decoration: underline;
	text-underline-offset: 3px;
}
.tecs-lien-aide:hover,
.tecs-lien:hover,
.tecs-aide a:hover,
.tecs-session__secours a:hover,
.tecs-fait dd a:hover,
.tecs-tarifs__aide a:hover {
	color: var(--tecs-vert);
}

.tecs-essentiel a:focus-visible,
.tecs-inscriptions a:focus-visible,
.tecs-inscriptions button:focus-visible,
.tecs-cote a:focus-visible,
.tecs-prochaines a:focus-visible {
	outline: 3px solid var(--tecs-vert);
	outline-offset: 2px;
}

/* ------------------------------------------------------------------
 * L'essentiel
 * ------------------------------------------------------------------ */
.tecs-essentiel {
	margin: 1.5em 0 2.5em;
	padding: 2em 0 1.75em;
	border-top: 1px solid var(--tecs-filet);
	border-bottom: 1px solid var(--tecs-filet);
	color: var(--tecs-texte);
}
.tecs-essentiel__faits {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
	gap: 1.1em 1.5em;
	margin: 0 0 1.5em;
}
.tecs-fait {
	margin: 0;
}
.tecs-fait dt {
	margin: 0 0 0.15em;
	color: var(--tecs-gris);
	font-size: 0.85em;
	font-weight: 400;
}
.tecs-fait dd {
	margin: 0;
	color: var(--tecs-encre);
	font-weight: 700;
	line-height: 1.4;
}
.tecs-essentiel__caf {
	margin: 0 0 1.5em;
	padding: 0.9em 1.15em;
	background: var(--tecs-encadre);
	color: var(--tecs-encre);
	line-height: 1.6;
}
.tecs-essentiel__caf strong {
	color: var(--tecs-encre);
}
.tecs-caf-note {
	display: block;
	margin-top: 0.35em;
	font-style: italic;
	color: var(--tecs-gris);
	font-size: 0.85em;
	line-height: 1.5;
}
.tecs-essentiel__points {
	margin: 0 0 1.5em 1.2em;
	padding: 0;
	list-style: disc;
	columns: 2 260px;
	column-gap: 2.5em;
}
.tecs-essentiel__points li {
	margin: 0 0 0.35em;
	break-inside: avoid;
	line-height: 1.6;
}
.tecs-essentiel__points li::marker {
	color: var(--tecs-encre);
}
.tecs-essentiel__liens {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 1em 1.75em;
	margin: 0;
}

/* ------------------------------------------------------------------
 * Dates et inscriptions
 * ------------------------------------------------------------------ */
.tecs-inscriptions {
	margin: 2.5em 0;
	padding-top: 2em;
	border-top: 1px solid var(--tecs-filet);
	scroll-margin-top: 110px;
	color: var(--tecs-texte);
}
.tecs-vide {
	padding: 1em 1.25em;
	background: var(--tecs-encadre);
	font-style: italic;
}

/* Liste des sessions */
.tecs-sessions,
.tecs-prochaines {
	margin: 0;
	padding: 0;
	list-style: none;
	border-top: 1px solid var(--tecs-trait);
}
.tecs-session,
.tecs-prochaine {
	margin: 0;
	border-bottom: 1px solid var(--tecs-trait);
	scroll-margin-top: 110px;
}
.tecs-session__entete {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.5em 1em;
	width: 100%;
	padding: 1em 0.5em;
	border: 0;
	background: transparent;
	color: var(--tecs-encre);
	font: inherit;
	text-align: left;
}
/* Le thème stylise tous les boutons : on neutralise ces styles pour l'en-tête des sessions. */
.tecs-inscriptions button.tecs-session__entete,
.tecs-inscriptions button.tecs-session__entete:hover,
.tecs-inscriptions button.tecs-session__entete:focus,
.tecs-inscriptions button.tecs-session__entete:active {
	margin: 0;
	border: 0;
	border-radius: 0;
	box-shadow: none;
	color: var(--tecs-encre);
	font: inherit;
	letter-spacing: normal;
	text-transform: none;
	line-height: 1.4;
	height: auto;
	cursor: pointer;
}
.tecs-inscriptions button.tecs-session__entete {
	background: transparent;
}
.tecs-inscriptions button.tecs-session__entete:hover,
.tecs-inscriptions button.tecs-session__entete:focus,
.tecs-inscriptions button.tecs-session__entete[aria-expanded="true"] {
	background: var(--tecs-encadre);
}
.tecs-session__dates {
	flex: 1 1 15em;
	color: var(--tecs-titre);
	font-family: var(--tecs-police-titres);
	font-size: 1.05em;
	font-weight: 700;
}
.tecs-session__infos {
	display: flex;
	flex-wrap: wrap;
	gap: 0 0.9em;
	margin: 0;
	padding: 0;
	list-style: none;
	color: var(--tecs-gris);
	font-size: 0.9em;
}
.tecs-session__infos li {
	margin: 0;
}
.tecs-session__infos li + li::before {
	content: "·";
	margin-right: 0.9em;
}
.tecs-session__action {
	margin-left: auto;
	padding: 0.5em 0.95em;
	border-radius: 5px;
	background: var(--tecs-jaune);
	color: #000;
	font-family: "Roboto", var(--button-font, sans-serif);
	font-size: 0.95em;
	font-weight: 600;
	text-decoration: underline;
	text-underline-offset: 3px;
	white-space: nowrap;
}
.tecs-session__action::after {
	content: "";
	display: inline-block;
	width: 0.42em;
	height: 0.42em;
	margin-left: 0.6em;
	border: solid #000;
	border-width: 0 2px 2px 0;
	transform: translateY(-0.2em) rotate(45deg);
	transition: transform 0.2s ease;
}
button[aria-expanded="true"] .tecs-session__action::after {
	transform: translateY(0.05em) rotate(-135deg);
}
.tecs-session__panneau {
	padding: 0.5em 0.5em 1.5em;
	background: var(--tecs-encadre);
}
.tecs-session__details {
	margin: 0 0 1em;
}
.tecs-session__formulaire {
	display: block;
	width: 100%;
	min-height: 750px;
	border: 0;
	background: #fff;
}
.tecs-session__secours {
	margin: 0.75em 0 0;
	color: var(--tecs-gris);
	font-size: 0.9em;
}

/* « Complet » : bien visible, sans être criard */
.tecs-tampon {
	margin-left: auto;
	padding: 0.3em 0.8em 0.2em;
	border: 2px solid currentColor;
	border-radius: 4px;
	font-family: var(--button-font, inherit);
	font-size: 0.95em;
	font-weight: 700;
	white-space: nowrap;
	transform: rotate(-2deg);
}
.tecs-tampon--complet {
	color: var(--tecs-rouge);
	background: #fff;
}
.tecs-tampon--bientot {
	color: var(--tecs-encre);
	border-width: 1px;
	border-style: dashed;
	font-weight: 600;
	transform: none;
}
.tecs-session--complet .tecs-session__dates,
.tecs-session--complet .tecs-session__infos {
	opacity: 0.55;
}

.tecs-aide {
	margin: 1em 0 0;
	font-size: 0.95em;
}

/* Grille tarifaire */
.tecs-tarifs {
	margin: 2.5em 0 2em;
	overflow-x: auto;
}
.tecs-tarifs__table {
	width: 100%;
	border-collapse: collapse;
	margin: 0;
}
.tecs-tarifs__table caption {
	padding: 0 0 0.6em;
	font-size: 1.25em;
	text-align: left;
}
.tecs-tarifs__table th,
.tecs-tarifs__table td {
	padding: 0.7em 0.9em 0.7em 0;
	border-bottom: 1px solid var(--tecs-trait);
	text-align: left;
	vertical-align: top;
}
.tecs-tarifs__table thead th {
	border-bottom: 1px solid var(--tecs-filet);
	color: var(--tecs-titre);
}
.tecs-tarifs__table tbody th {
	width: 30%;
	color: var(--tecs-encre);
	font-weight: 600;
}
.tecs-tarifs__table td strong {
	color: var(--tecs-encre);
}
.tecs-tarifs__note {
	display: block;
	font-weight: 400;
	color: var(--tecs-gris);
	font-size: 0.85em;
}
.tecs-tarifs__mention {
	color: var(--tecs-encre);
	font-size: 0.9em;
}
.tecs-tarifs__notes {
	margin: 0.75em 0 0;
	color: var(--tecs-gris);
	font-size: 0.9em;
}
/* Comme l'encadré « Lire également » des pages vitrines */
.tecs-tarifs__aide {
	margin: 1.25em 0 0;
	padding: 1em 1.25em;
	background: var(--tecs-encadre);
	font-style: italic;
}

/* Ce tarif comprend / ne comprend pas */
.tecs-inclus {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
	gap: 1em 2.5em;
	margin: 0 0 1em;
}
.tecs-inclus__titre {
	margin: 0 0 0.6em;
	font-size: 1.1em;
}
.tecs-inclus__liste {
	margin: 0;
	padding: 0;
	list-style: none;
}
.tecs-inclus__liste li {
	position: relative;
	margin: 0 0 0.4em;
	padding-left: 1.5em;
	line-height: 1.5;
}
.tecs-inclus__liste--oui li::before {
	content: "";
	position: absolute;
	left: 0.2em;
	top: 0.3em;
	width: 0.35em;
	height: 0.7em;
	border: solid var(--tecs-encre);
	border-width: 0 2px 2px 0;
	transform: rotate(45deg);
}
.tecs-inclus__liste--non li::before,
.tecs-inclus__liste--non li::after {
	content: "";
	position: absolute;
	left: 0.1em;
	top: 0.7em;
	width: 0.8em;
	height: 2px;
	background: var(--tecs-gris);
	transform: rotate(45deg);
}
.tecs-inclus__liste--non li::after {
	transform: rotate(-45deg);
}

/* Liste « prochaines sessions » (shortcode pour les pages vitrines) */
.tecs-prochaine {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.5em 1em;
	padding: 1em 0.5em;
}
.tecs-prochaine .tecs-btn,
.tecs-prochaine .tecs-tampon {
	margin-left: auto;
}

/* ------------------------------------------------------------------
 * Colonne de droite : prochains départs
 * ------------------------------------------------------------------ */
.tecs-cote {
	margin: 0 0 1.5em;
	padding: 1.25em 0 0.5em;
	border-top: 1px solid var(--tecs-filet);
	color: var(--tecs-texte);
}
.tecs-cote__titre {
	margin: 0 0 0.6em;
	font-size: 1.25em;
}
.tecs-cote__titre::after {
	content: "";
	display: block;
	width: 40px;
	height: 3px;
	margin-top: 0.4em;
	background: var(--tecs-jaune);
}
.tecs-cote__dates {
	margin: 0 0 0.75em;
	padding: 0;
	list-style: none;
}
.tecs-cote__dates li {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: 0.25em 0.5em;
	margin: 0;
	padding: 0.55em 0;
	border-bottom: 1px solid var(--tecs-trait);
	color: var(--tecs-encre);
	font-weight: 600;
}
.tecs-mini {
	padding: 0 0.45em;
	border-radius: 3px;
	font-size: 0.8em;
	font-weight: 700;
}
.tecs-mini--complet {
	border: 1px solid var(--tecs-rouge);
	color: var(--tecs-rouge);
}
.tecs-mini--bientot {
	border: 1px dashed var(--tecs-gris);
	color: var(--tecs-encre);
	font-weight: 600;
}
.tecs-cote__plus,
.tecs-cote__base {
	margin: 0 0 0.75em;
	color: var(--tecs-gris);
	font-size: 0.9em;
}
.tecs-cote__caf {
	margin: 0.25em 0 0.75em;
	padding: 0.75em 0.9em;
	background: var(--tecs-encadre);
	color: var(--tecs-encre);
	font-size: 0.95em;
	line-height: 1.55;
}
.tecs-cote__vide {
	margin: 0;
}

/* ------------------------------------------------------------------
 * Avis (extension « Gestionnaire d'Avis »)
 * Ses styles ne se chargent que si le shortcode est dans le texte de la page :
 * ces règles de secours reproduisent sa mise en page sur les pages séjours.
 * ------------------------------------------------------------------ */
.tecs-avis {
	margin: 3em 0 2em;
	padding-top: 2em;
	border-top: 1px solid var(--tecs-filet);
}
.tecs-avis .tecav-grille {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
	gap: 1.25em;
	margin: 0 0 1.5em;
}
.tecs-avis .tecav-carte {
	position: relative;
	padding: 1.25em 1.25em 1em;
	border-radius: 10px;
	background: #f6f6f6;
}
.tecs-avis .tecav-quote {
	color: var(--primary-color, #f9ea3e);
}
.tecs-avis .tecav-badge {
	display: inline-block;
	padding: 0.1em 0.7em;
	border: 2px solid #f5c842;
	border-radius: 999px;
	font-size: 0.85em;
}

/* Liste d'avis : on masque les filtres propres au BAFA et le choix du type (toujours « Colo » ici). */
.tecs-avis--liste .tecav-filtres > div:has(#tecav-f-type),
.tecs-avis--liste .tecav-filtres > div:has(#tecav-f-formation),
.tecs-avis--liste .tecav-filtres > div:has(#tecav-f-hebergement) {
	display: none;
}

/* ------------------------------------------------------------------
 * Petits écrans et préférences
 * ------------------------------------------------------------------ */
@media (max-width: 600px) {
	.tecs-session__action,
	.tecs-tampon {
		margin-left: 0;
	}
	.tecs-tarifs__table tbody th {
		width: auto;
	}
	.tecs-essentiel__titre,
	.tecs-inscriptions > h2,
	.tecs-avis > h2 {
		font-size: 1.35em;
	}
}
@media (max-width: 480px) {
	.tecs-avis .tecav-grille {
		grid-template-columns: 1fr;
	}
}
@media (prefers-reduced-motion: reduce) {
	.tecs-btn,
	.tecs-session__action::after {
		transition: none;
	}
}
