/* Valeurs par défaut — écrasées par Solutions > Apparence (variables injectées par PHP). */
.stsol {
	--stsol-accent: #2f5bea;
	--stsol-accent-text: #fff;
	--stsol-title: #0f172a;
	--stsol-text: #475569;
	--stsol-card: #fff;
	--stsol-border: #e2e8f0;
	--stsol-soon: #d97706;
	--stsol-radius: 14px;
	--stsol-gap: 22px;
	--stsol-tint: rgba(0, 0, 0, .05);
	box-sizing: border-box;
	color: var(--stsol-text);
}
@supports (background: color-mix(in srgb, red 10%, white)) {
	.stsol { --stsol-tint: color-mix(in srgb, var(--stsol-accent) 10%, transparent); }
}
.stsol *, .stsol *::before, .stsol *::after { box-sizing: border-box; }

/* Profils : onglets soulignés */
.stsol-audiences { margin-bottom: 26px; }
.stsol-audiences__tabs { display: flex; flex-wrap: wrap; gap: 22px; border-bottom: 1px solid var(--stsol-border); }
.stsol-audiences__tab {
	appearance: none; background: none; border: 0; cursor: pointer; font: inherit; font-weight: 600; font-size: 15px;
	padding: 0 0 10px; margin-bottom: -1px; color: var(--stsol-text); border-bottom: 2px solid transparent;
}
.stsol-audiences__tab.is-active { color: var(--stsol-title); border-bottom-color: var(--stsol-accent); }
.stsol-audiences__text { margin: 14px 0 0; max-width: 62ch; line-height: 1.6; }

/* Filtres : contrôle segmenté */
.stsol-filters {
	display: inline-flex; flex-wrap: wrap; gap: 4px; padding: 4px; margin-bottom: 28px;
	background: var(--stsol-tint); border-radius: calc(var(--stsol-radius) + 4px);
}
.stsol-chip {
	appearance: none; cursor: pointer; font: inherit; font-size: 14px; font-weight: 600; line-height: 1;
	padding: 11px 16px; border: 0; border-radius: var(--stsol-radius); background: transparent; color: var(--stsol-text);
	transition: background .15s, color .15s;
}
.stsol-chip:hover { color: var(--stsol-title); }
.stsol-chip.is-active { background: var(--stsol-accent); color: var(--stsol-accent-text); }

/* Grille */
.stsol-grid { display: grid; gap: var(--stsol-gap); grid-template-columns: repeat(var(--stsol-cols, 3), minmax(0, 1fr)); }
@media (max-width: 1023px) { .stsol-grid { grid-template-columns: repeat(min(var(--stsol-cols, 3), 2), minmax(0, 1fr)); } }
@media (max-width: 639px)  { .stsol-grid { grid-template-columns: 1fr; } }
.stsol-card[hidden] { display: none; }

/* Carte */
.stsol-card {
	position: relative; display: flex; flex-direction: column; overflow: hidden;
	padding: 26px 26px 22px 30px; background: var(--stsol-card);
	border: 1px solid var(--stsol-border); border-radius: var(--stsol-radius);
	transition: transform .2s, box-shadow .2s;
}
.stsol-card::before {
	content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px;
	background: var(--stsol-accent); opacity: .35; transition: opacity .2s, width .2s;
}
.stsol-card:hover { transform: translateY(-3px); box-shadow: 0 12px 28px -16px rgba(15, 23, 42, .35); }
.stsol-card:hover::before { opacity: 1; width: 6px; }

.stsol-card__head { display: flex; align-items: center; gap: 14px; }
.stsol-card__logo {
	flex: 0 0 56px; width: 56px; height: 56px; display: grid; place-items: center; overflow: hidden;
	border-radius: calc(var(--stsol-radius) * .8); background: var(--stsol-tint);
}
.stsol-card__logo img { width: 100%; height: 100%; object-fit: contain; display: block; }
.stsol-card__initial { font-size: 24px; font-weight: 700; color: var(--stsol-accent); }
.stsol-card__id { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.stsol-card__title { margin: 0; padding: 0; font-size: 19px; line-height: 1.25; font-weight: 700; color: var(--stsol-title); }
.stsol-card__cat {
	display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600;
	letter-spacing: .02em; color: var(--stsol-accent);
}
.stsol-card__cat::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.stsol-card__soon {
	position: absolute; top: 14px; right: 14px; font-size: 11px; font-weight: 700; letter-spacing: .06em;
	text-transform: uppercase; padding: 3px 8px; border-radius: 6px;
	color: var(--stsol-soon); border: 1px dashed currentColor;
}
.stsol-card__soon + .stsol-card__head { padding-right: 70px; }
.stsol-card__desc { margin: 16px 0 22px; font-size: 14.5px; line-height: 1.65; color: var(--stsol-text); }

.stsol-link {
	margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 10px;
	padding-top: 14px; border-top: 1px dashed var(--stsol-border);
	font-weight: 600; font-size: 15px; text-decoration: none; color: var(--stsol-title);
	transition: color .15s;
}
.stsol-link svg {
	width: 32px; height: 32px; padding: 7px; border-radius: 50%; flex: none;
	background: var(--stsol-tint); color: var(--stsol-accent); transition: background .15s, color .15s, transform .15s;
}
.stsol-link:hover { color: var(--stsol-accent); }
.stsol-link:hover svg { background: var(--stsol-accent); color: var(--stsol-accent-text); transform: translateX(3px); }

/* Carrousel */
.stsol-carousel { position: relative; }
.stsol-carousel__head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 24px; }
.stsol-carousel__title { margin: 0; font-size: clamp(22px, 3vw, 32px); line-height: 1.2; color: var(--stsol-title); }
.stsol-carousel__ctrl { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.stsol-carousel__more { margin-right: 10px; color: var(--stsol-accent); font-weight: 600; text-decoration: none; }
.stsol-arrow {
	appearance: none; cursor: pointer; width: 42px; height: 42px; font-size: 18px; line-height: 1;
	border: 0; border-radius: var(--stsol-radius); background: var(--stsol-tint); color: var(--stsol-accent);
	transition: background .15s, color .15s, opacity .15s;
}
.stsol-arrow:hover:not(:disabled) { background: var(--stsol-accent); color: var(--stsol-accent-text); }
.stsol-arrow:disabled { opacity: .4; cursor: default; }
.stsol-carousel__track {
	display: flex; gap: var(--stsol-gap); overflow-x: auto; scroll-snap-type: x mandatory;
	scroll-behavior: smooth; scrollbar-width: none; -webkit-overflow-scrolling: touch;
	padding: 6px 2px 14px; margin: -6px -2px -14px; outline-offset: 4px;
}
.stsol-carousel__track::-webkit-scrollbar { display: none; }
.stsol-carousel__track .stsol-card {
	flex: 0 0 calc((100% - (var(--stsol-pv, 3) - 1) * var(--stsol-gap)) / var(--stsol-pv, 3));
	scroll-snap-align: start;
}
@media (max-width: 1023px) { .stsol-carousel__track .stsol-card { flex-basis: calc((100% - var(--stsol-gap)) / 2); } }
@media (max-width: 639px)  { .stsol-carousel__track .stsol-card { flex-basis: 86%; } }
.stsol-carousel__dots { display: flex; justify-content: center; gap: 6px; margin-top: 26px; }
.stsol-dot {
	appearance: none; cursor: pointer; width: 18px; height: 5px; padding: 0; border: 0; border-radius: 3px;
	background: var(--stsol-border); transition: width .2s, background .2s;
}
.stsol-dot.is-active { width: 34px; background: var(--stsol-accent); }

@media (prefers-reduced-motion: reduce) {
	.stsol-carousel__track { scroll-behavior: auto; }
	.stsol-card, .stsol-link svg { transition: none; }
}
