/* ADCOM+ Colleges, styles publics. */

.adcom-colleges {
	--ac-fond: #eef2f1;
	--ac-surface: #ffffff;
	--ac-encre: #16323b;
	--ac-encre-doux: #5b747c;
	--ac-filet: #cfdad8;
	--ac-public: #1f6f8b;
	--ac-prive: #a8593b;
	--ac-accent: #c98a1f;
	--ac-positif: #2e7d5b;
	--ac-negatif: #b3402f;

	font-family: "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	color: var(--ac-encre);
	background: var(--ac-fond);
	padding: 2rem 1.25rem 1.5rem;
	border-radius: 4px;
	line-height: 1.5;
}

.adcom-colleges *,
.adcom-colleges *::before,
.adcom-colleges *::after {
	box-sizing: border-box;
}

.ac-visuellement-cache {
	position: absolute;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
}

.adcom-colleges :focus-visible {
	outline: 2px solid var(--ac-accent);
	outline-offset: 2px;
}

/* En-tete */

.ac-tete {
	max-width: 44rem;
	margin-bottom: 1.75rem;
}

.ac-titre {
	margin: 0 0 0.35rem;
	font-size: clamp(1.5rem, 4vw, 2.1rem);
	font-weight: 600;
	letter-spacing: -0.015em;
	line-height: 1.15;
	color: var(--ac-encre);
}

.ac-intro {
	margin: 0;
	color: var(--ac-encre-doux);
	font-size: 0.975rem;
}

/* Ruban de trajet */

.ac-ruban {
	position: relative;
	height: 78px;
	margin: 0 0 0.25rem;
	padding: 0 0.5rem;
}

.ac-ruban-piste {
	position: absolute;
	inset: 0 0.5rem 26px;
	border-bottom: 2px solid var(--ac-encre);
}

.ac-pastille {
	position: absolute;
	bottom: -7px;
	width: 13px;
	height: 13px;
	margin-left: -6.5px;
	padding: 0;
	border: 2px solid var(--ac-surface);
	border-radius: 50%;
	background: var(--ac-public);
	cursor: pointer;
	transition: transform 0.12s ease;
}

.ac-pastille[data-statut="prive"] {
	background: var(--ac-prive);
}

.ac-pastille:hover,
.ac-pastille:focus-visible,
.ac-pastille.est-visee {
	transform: scale(1.55);
	z-index: 3;
}

.ac-pastille.est-masquee {
	opacity: 0.18;
	pointer-events: none;
}

.ac-ruban-origine {
	position: absolute;
	bottom: -14px;
	left: -1px;
	width: 3px;
	height: 28px;
	background: var(--ac-encre);
}

.ac-ruban-graduations {
	position: absolute;
	right: 0.5rem;
	bottom: 0;
	left: 0.5rem;
	height: 22px;
}

.ac-graduation {
	position: absolute;
	transform: translateX(-50%);
	color: var(--ac-encre-doux);
	font-size: 0.72rem;
	white-space: nowrap;
}

.ac-ruban-legende {
	margin: 0 0 1.5rem;
	color: var(--ac-encre-doux);
	font-size: 0.8rem;
}

/* Barre d outils */

.ac-barre {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem 1rem;
	align-items: center;
	padding-bottom: 1rem;
	border-bottom: 1px solid var(--ac-filet);
	margin-bottom: 1.25rem;
}

.ac-recherche {
	flex: 1 1 15rem;
}

.ac-recherche input {
	width: 100%;
	padding: 0.55rem 0.75rem;
	border: 1px solid var(--ac-filet);
	border-radius: 3px;
	background: var(--ac-surface);
	color: inherit;
	font: inherit;
}

.ac-filtres {
	display: flex;
	border: 1px solid var(--ac-filet);
	border-radius: 3px;
	background: var(--ac-surface);
	overflow: hidden;
}

.ac-puce {
	padding: 0.5rem 0.9rem;
	border: 0;
	border-right: 1px solid var(--ac-filet);
	background: transparent;
	color: var(--ac-encre-doux);
	font: inherit;
	font-size: 0.9rem;
	cursor: pointer;
}

.ac-puce:last-child {
	border-right: 0;
}

.ac-puce.est-active {
	background: var(--ac-encre);
	color: #fff;
}

.ac-tri {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	font-size: 0.9rem;
	color: var(--ac-encre-doux);
}

.ac-tri select {
	padding: 0.5rem 0.6rem;
	border: 1px solid var(--ac-filet);
	border-radius: 3px;
	background: var(--ac-surface);
	color: var(--ac-encre);
	font: inherit;
	font-size: 0.9rem;
}

/* Carte */

.ac-carte {
	height: 340px;
	margin-bottom: 1.25rem;
	border: 1px solid var(--ac-filet);
	border-radius: 3px;
}

.ac-carte-bulle strong {
	display: block;
	font-size: 0.95rem;
}

.ac-carte-bulle span {
	color: #5b747c;
	font-size: 0.82rem;
}

/* Liste */

.ac-compte {
	margin: 0 0 0.75rem;
	color: var(--ac-encre-doux);
	font-size: 0.85rem;
}

.ac-liste {
	margin: 0;
	padding: 0;
	list-style: none;
	border-top: 1px solid var(--ac-filet);
}

.ac-item {
	display: grid;
	grid-template-columns: 1fr;
	gap: 0.75rem 1.5rem;
	padding: 1.1rem 0.25rem 1.1rem 0.9rem;
	border-bottom: 1px solid var(--ac-filet);
	border-left: 4px solid var(--ac-public);
	background: var(--ac-surface);
}

.ac-item[data-statut="prive"] {
	border-left-color: var(--ac-prive);
}

.ac-item.est-visee {
	background: #fbf6ea;
}

.ac-item-tete {
	display: flex;
	flex-wrap: wrap;
	gap: 0.4rem 0.75rem;
	align-items: baseline;
}

.ac-nom {
	margin: 0;
	font-size: 1.12rem;
	font-weight: 600;
	letter-spacing: -0.01em;
}

.ac-lieu {
	color: var(--ac-encre-doux);
	font-size: 0.9rem;
}

.ac-etiquette {
	padding: 0.1rem 0.45rem;
	border: 1px solid currentColor;
	border-radius: 2px;
	color: var(--ac-public);
	font-size: 0.72rem;
	font-weight: 600;
}

.ac-item[data-statut="prive"] .ac-etiquette {
	color: var(--ac-prive);
}

.ac-trajet {
	display: flex;
	flex-wrap: wrap;
	gap: 0.3rem 1rem;
	color: var(--ac-encre-doux);
	font-size: 0.88rem;
}

.ac-trajet strong {
	color: var(--ac-encre);
	font-weight: 600;
}

.ac-mesures {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(9.5rem, 1fr));
	gap: 0.85rem;
}

.ac-mesure-nom {
	display: block;
	margin-bottom: 0.15rem;
	color: var(--ac-encre-doux);
	font-size: 0.78rem;
}

.ac-mesure-valeur {
	display: block;
	font-size: 1.15rem;
	font-weight: 600;
	font-variant-numeric: tabular-nums;
	line-height: 1.2;
}

.ac-mesure-valeur.est-absente {
	color: var(--ac-encre-doux);
	font-size: 0.9rem;
	font-weight: 400;
}

.ac-jauge {
	position: relative;
	height: 4px;
	margin-top: 0.4rem;
	background: var(--ac-filet);
}

.ac-jauge-part {
	position: absolute;
	top: 0;
	bottom: 0;
	background: var(--ac-encre);
}

.ac-jauge-repere {
	position: absolute;
	top: -3px;
	bottom: -3px;
	width: 1px;
	background: var(--ac-encre-doux);
}

.ac-va-positive {
	color: var(--ac-positif);
}

.ac-va-negative {
	color: var(--ac-negatif);
}

.ac-services {
	display: flex;
	flex-wrap: wrap;
	gap: 0.35rem;
}

.ac-service {
	padding: 0.15rem 0.5rem;
	background: var(--ac-fond);
	color: var(--ac-encre-doux);
	font-size: 0.78rem;
}

.ac-item-pied {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem 1.25rem;
	align-items: center;
	font-size: 0.85rem;
}

.ac-lien {
	padding: 0;
	border: 0;
	background: none;
	color: var(--ac-public);
	font: inherit;
	text-decoration: underline;
	cursor: pointer;
}

.ac-comparer {
	display: inline-flex;
	gap: 0.4rem;
	align-items: center;
	color: var(--ac-encre-doux);
	cursor: pointer;
}

/* Panneau de comparaison */

.ac-comparaison {
	position: sticky;
	bottom: 0;
	margin-top: 1.5rem;
	padding: 1rem;
	border-top: 3px solid var(--ac-encre);
	background: var(--ac-surface);
	box-shadow: 0 -6px 18px rgba(22, 50, 59, 0.09);
}

.ac-comparaison-tete {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 0.6rem;
}

.ac-comparaison-tete h3 {
	margin: 0;
	font-size: 1rem;
	font-weight: 600;
}

.ac-comparaison-corps {
	overflow-x: auto;
}

.ac-tableau {
	width: 100%;
	border-collapse: collapse;
	font-size: 0.88rem;
}

.ac-tableau th,
.ac-tableau td {
	padding: 0.45rem 0.6rem;
	border-bottom: 1px solid var(--ac-filet);
	text-align: left;
	white-space: nowrap;
}

.ac-tableau th {
	color: var(--ac-encre-doux);
	font-weight: 400;
}

.ac-tableau td {
	font-variant-numeric: tabular-nums;
}

.ac-tableau .ac-colonne-nom {
	font-weight: 600;
}

/* Notes */

.ac-notes {
	margin-top: 1.75rem;
	padding-top: 1rem;
	border-top: 1px solid var(--ac-filet);
	color: var(--ac-encre-doux);
	font-size: 0.8rem;
}

.ac-notes p {
	max-width: 46rem;
	margin: 0 0 0.5rem;
}

.ac-vide {
	padding: 2rem 0;
	color: var(--ac-encre-doux);
}

/* Largeurs superieures */

@media (min-width: 720px) {
	.adcom-colleges {
		padding: 2.5rem 2rem 2rem;
	}

	.ac-item {
		grid-template-columns: minmax(13rem, 1.1fr) minmax(0, 1.6fr);
		align-items: start;
	}

	.ac-item-tete,
	.ac-trajet,
	.ac-services {
		grid-column: 1;
	}

	.ac-mesures {
		grid-row: 1 / span 3;
		grid-column: 2;
	}

	.ac-item-pied {
		grid-column: 1 / -1;
	}
}

@media (prefers-reduced-motion: reduce) {
	.adcom-colleges * {
		transition: none !important;
	}
}
