/* =========================================================
   ESCEP-NIGER - Liste des Admis
   Couleurs officielles : bleu #1a73ee, jaune #ebe20f, rouge #ff1d23
   ========================================================= */

.escep-admis-app {
	--escep-bleu: #1a73ee;
	--escep-bleu-fonce: #0d4fb0;
	--escep-jaune: #ebe20f;
	--escep-rouge: #ff1d23;
	--escep-gris: #f4f7fc;
	--escep-gris-bord: #dbe4f0;
	--escep-texte: #1f2733;
	--escep-texte-doux: #5a6b82;

	max-width: 1100px;
	margin: 0 auto;
	padding: 4px;
	color: var(--escep-texte);
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	font-size: 15px;
	line-height: 1.5;
	box-sizing: border-box;
}

.escep-admis-app *,
.escep-admis-app *::before,
.escep-admis-app *::after {
	box-sizing: border-box;
}

/* ---------- En-tête ---------- */
.escep-header {
	display: flex;
	align-items: center;
	gap: 22px;
	flex-wrap: wrap;
	background: #ffffff;
	border: 1px solid var(--escep-gris-bord);
	border-top: 6px solid var(--escep-bleu);
	border-radius: 14px;
	padding: 22px 26px;
	box-shadow: 0 6px 22px rgba(26, 115, 238, 0.08);
}

.escep-header-logo {
	flex: 0 0 auto;
	line-height: 0;
}

.escep-header-logo img {
	max-width: 210px !important;
	width: auto !important;
	height: auto !important;
	display: block !important;
	visibility: visible !important;
	opacity: 1 !important;
	max-height: none !important;
}

.escep-header-logo picture {
	display: block;
}

.escep-header-text {
	flex: 1;
	min-width: 240px;
}

.escep-title {
	margin: 0 0 4px;
	font-size: 26px;
	font-weight: 800;
	color: var(--escep-bleu);
	line-height: 1.2;
}

.escep-subtitle {
	margin: 0 0 6px;
	font-size: 15px;
	color: var(--escep-texte-doux);
	font-weight: 600;
}

.escep-ref {
	margin: 0;
	font-size: 13px;
	color: var(--escep-texte-doux);
	font-style: italic;
}

/* ---------- Statistiques ---------- */
.escep-stats {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 14px;
	margin: 18px 0;
}

.escep-stat {
	border-radius: 12px;
	padding: 16px 14px;
	text-align: center;
	color: #fff;
	box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
}

.escep-stat-admis {
	background: linear-gradient(135deg, var(--escep-bleu), var(--escep-bleu-fonce));
}

.escep-stat-attente {
	background: linear-gradient(135deg, var(--escep-rouge), #c8161b);
}

.escep-stat-filieres {
	background: linear-gradient(135deg, #f5c400, var(--escep-jaune));
	color: #4a3f00;
}

.escep-stat-num {
	display: block;
	font-size: 32px;
	font-weight: 800;
	line-height: 1;
}

.escep-stat-label {
	display: block;
	margin-top: 6px;
	font-size: 13px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.03em;
	opacity: 0.95;
}

/* ---------- Formulaire de recherche ---------- */
.escep-filters {
	display: grid;
	grid-template-columns: 2fr 1.4fr 1.4fr 1.2fr auto;
	gap: 14px;
	align-items: end;
	background: var(--escep-gris);
	border: 1px solid var(--escep-gris-bord);
	border-radius: 14px;
	padding: 18px 18px;
	margin-bottom: 8px;
}

.escep-filter {
	display: flex;
	flex-direction: column;
	min-width: 0;
}

.escep-filter label {
	font-size: 12px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.03em;
	color: var(--escep-bleu-fonce);
	margin-bottom: 6px;
}

.escep-filter input[type="text"],
.escep-filter select {
	width: 100%;
	padding: 11px 12px;
	border: 2px solid var(--escep-gris-bord);
	border-radius: 9px;
	font-size: 14px;
	background: #fff;
	color: var(--escep-texte);
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
	-webkit-appearance: none;
	appearance: none;
}

.escep-filter select {
	background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2214%22%20height%3D%2214%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22%231a73ee%22%20stroke-width%3D%223%22%3E%3Cpath%20d%3D%22M6%209l6%206%206-6%22%2F%3E%3C%2Fsvg%3E");
	background-repeat: no-repeat;
	background-position: right 12px center;
	padding-right: 34px;
}

.escep-filter input[type="text"]:focus,
.escep-filter select:focus {
	outline: none;
	border-color: var(--escep-bleu);
	box-shadow: 0 0 0 3px rgba(26, 115, 238, 0.15);
}

.escep-filter-reset {
	justify-content: flex-end;
}

.escep-btn-reset {
	padding: 11px 18px;
	border: none;
	border-radius: 9px;
	background: var(--escep-rouge);
	color: #fff;
	font-size: 14px;
	font-weight: 700;
	cursor: pointer;
	white-space: nowrap;
	transition: background 0.15s ease, transform 0.05s ease;
}

.escep-btn-reset:hover {
	background: #d81419;
}

.escep-btn-reset:active {
	transform: translateY(1px);
}

/* ---------- Info résultats ---------- */
.escep-result-info {
	margin: 12px 2px 18px;
	font-size: 14px;
	font-weight: 600;
	color: var(--escep-texte-doux);
}

/* ---------- Groupes / listes ---------- */
.escep-groupe {
	margin-bottom: 26px;
}

.escep-groupe-titre {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 10px;
	font-size: 17px;
	font-weight: 700;
	color: var(--escep-texte);
	margin: 0 0 12px;
	padding-bottom: 10px;
	border-bottom: 3px solid var(--escep-jaune);
}

.escep-count {
	color: var(--escep-texte-doux);
	font-weight: 600;
	font-size: 15px;
}

.escep-badge {
	display: inline-block;
	padding: 4px 12px;
	border-radius: 999px;
	font-size: 12px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.03em;
	color: #fff;
}

.escep-badge-admis {
	background: var(--escep-bleu);
}

.escep-badge-attente {
	background: var(--escep-rouge);
}

/* ---------- Tableau ---------- */
.escep-table-wrap {
	overflow-x: auto;
	border: 1px solid var(--escep-gris-bord);
	border-radius: 12px;
	background: #fff;
}

.escep-table {
	width: 100%;
	border-collapse: collapse;
	font-size: 14px;
	min-width: 560px;
}

.escep-table thead th {
	background: var(--escep-bleu);
	color: #fff;
	text-align: left;
	padding: 12px 14px;
	font-weight: 700;
	font-size: 13px;
	text-transform: uppercase;
	letter-spacing: 0.02em;
	white-space: nowrap;
}

.escep-table thead th.escep-col-ordre,
.escep-table thead th.escep-col-rang {
	text-align: center;
}

.escep-table tbody td {
	padding: 11px 14px;
	border-top: 1px solid var(--escep-gris-bord);
	vertical-align: middle;
}

.escep-col-ordre,
.escep-col-rang {
	text-align: center;
	font-weight: 700;
	color: var(--escep-bleu-fonce);
	white-space: nowrap;
}

.escep-col-nom {
	font-weight: 600;
}

.escep-col-naiss {
	color: var(--escep-texte-doux);
	white-space: nowrap;
}

.escep-table tbody tr:nth-child(even) td {
	background: #fafbfe;
}

.escep-table tbody tr:hover td {
	background: #eef4ff;
}

/* Surlignage de la correspondance de recherche */
.escep-highlight {
	background: var(--escep-jaune);
	color: #4a3f00;
	border-radius: 3px;
	padding: 0 2px;
	font-weight: 700;
}

/* ---------- Aucun résultat ---------- */
.escep-no-result,
.escep-no-result-groupe {
	text-align: center;
	padding: 26px 16px;
	color: var(--escep-texte-doux);
	font-weight: 600;
	background: var(--escep-gris);
	border: 1px dashed var(--escep-gris-bord);
	border-radius: 12px;
}

/* ---------- Pied ---------- */
.escep-footer {
	margin-top: 22px;
	padding: 18px 20px;
	background: var(--escep-gris);
	border-left: 5px solid var(--escep-jaune);
	border-radius: 10px;
	font-size: 13.5px;
	color: var(--escep-texte-doux);
}

.escep-footer p {
	margin: 0 0 8px;
}

.escep-footer p:last-child {
	margin-bottom: 0;
}

.escep-footer strong {
	color: var(--escep-rouge);
}

.escep-footer-contact {
	font-size: 12.5px;
	font-weight: 600;
}

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (max-width: 860px) {
	.escep-filters {
		grid-template-columns: 1fr 1fr;
	}
	.escep-filter-search {
		grid-column: 1 / -1;
	}
	.escep-filter-reset {
		grid-column: 1 / -1;
	}
	.escep-btn-reset {
		width: 100%;
	}
}

@media (max-width: 600px) {
	.escep-title {
		font-size: 21px;
	}
	.escep-header {
		padding: 18px;
		gap: 14px;
	}
	.escep-header-logo img {
		max-width: 160px;
	}
	.escep-stats {
		grid-template-columns: 1fr;
	}
	.escep-filters {
		grid-template-columns: 1fr;
	}

	/* Transformation du tableau en cartes empilées */
	.escep-table {
		min-width: 0;
	}
	.escep-table thead {
		display: none;
	}
	.escep-table,
	.escep-table tbody,
	.escep-table tr,
	.escep-table td {
		display: block;
		width: 100%;
	}
	.escep-table tbody tr {
		margin: 10px;
		border: 1px solid var(--escep-gris-bord);
		border-radius: 10px;
		overflow: hidden;
	}
	.escep-table tbody td {
		display: flex;
		justify-content: space-between;
		align-items: center;
		text-align: right;
		padding: 10px 14px;
		border-top: none;
		border-bottom: 1px solid var(--escep-gris-bord);
	}
	.escep-table tbody tr td:last-child {
		border-bottom: none;
	}
	.escep-table tbody tr:nth-child(even) td,
	.escep-table tbody tr:hover td {
		background: #fff;
	}
	.escep-table tbody td::before {
		content: attr(data-label);
		font-weight: 700;
		text-transform: uppercase;
		font-size: 11px;
		letter-spacing: 0.03em;
		color: var(--escep-bleu);
		text-align: left;
		margin-right: 14px;
	}
	.escep-col-nom {
		background: var(--escep-gris) !important;
	}
}
