/* Fiche partenaire : tout est préfixé .cc-fiche pour ne pas entrer en conflit avec Divi. */

.cc-fiche {
	--cc-creme: #fefcf4;
	--cc-sable: #f0ebd8;
	--cc-orange: #f9b565;
	--cc-orange-fonce: #e9a04c;
	--cc-bleu: #7088ac;
	--cc-bleu-texte: #5a7194;
	--cc-encre: #202858;

	color: var(--cc-encre);
	font-family: "CC Basier", Helvetica, Arial, sans-serif;
	font-size: 16px;
	line-height: 1.4;
}

/* L'identifiant est nécessaire : Divi met #main-content sur fond blanc */
#main-content.cc-fiche {
	background: var(--cc-creme);
}

.cc-fiche *,
.cc-fiche *::before,
.cc-fiche *::after {
	box-sizing: border-box;
}

.cc-fiche a:focus-visible {
	outline: 3px solid var(--cc-bleu);
	outline-offset: 2px;
}

.cc-fiche__contenu {
	display: grid;
	gap: 56px;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
	margin: 0 auto;
	max-width: 1320px;
	padding: 32px 24px 88px;
}

/* Colonne gauche : reste visible quand la liste des offres est longue */

.cc-fiche__partenaire {
	align-self: start;
	position: sticky;
	top: 100px;
}

.admin-bar .cc-fiche__partenaire {
	top: 132px;
}

.cc-fiche .cc-fiche__retour {
	align-items: center;
	color: var(--cc-encre);
	display: inline-flex;
	font-weight: 600;
	gap: 8px;
	margin-bottom: 16px;
	text-decoration: none;
	transition: transform 0.2s ease;
}

.cc-fiche .cc-fiche__retour:hover {
	transform: translateX(-4px);
}

.cc-fiche__media {
	position: relative;
}

.cc-fiche__photo {
	aspect-ratio: 16 / 9;
	background: var(--cc-sable);
	border-radius: 24px;
	display: block;
	object-fit: cover;
	width: 100%;
}

.cc-fiche__logo {
	background: #fff;
	border: 4px solid #fff;
	border-radius: 50%;
	bottom: -36px;
	box-shadow: 0 6px 20px rgba(32, 40, 88, 0.15);
	height: 92px;
	left: 28px;
	object-fit: cover;
	position: absolute;
	width: 92px;
}

.cc-fiche .cc-fiche__nom {
	color: var(--cc-encre);
	font-family: "CC Gilbert", Helvetica, Arial, sans-serif;
	font-size: 44px;
	font-weight: 700;
	line-height: 1.1;
	margin: 52px 0 4px;
	padding: 0;
}

.cc-fiche .cc-fiche__categorie {
	color: var(--cc-bleu-texte);
	font-size: 18px;
	margin: 0 0 14px;
	padding: 0;
}

.cc-fiche .cc-fiche__tags {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	list-style: none;
	margin: 0 0 20px;
	padding: 0;
}

.cc-fiche__tags li {
	background: var(--cc-sable);
	border-radius: 10px;
	font-size: 14px;
	padding: 6px 12px;
}

.cc-fiche__adresse {
	align-items: center;
	border-bottom: 1px solid var(--cc-sable);
	border-top: 1px solid var(--cc-sable);
	display: flex;
	gap: 16px;
	justify-content: space-between;
	padding: 14px 0;
}

.cc-fiche .cc-fiche__adresse p {
	margin: 0;
	padding: 0;
}

.cc-fiche__adresse p span {
	margin-right: 4px;
}

.cc-fiche .cc-fiche__y-aller {
	background: var(--cc-orange);
	border-radius: 100px;
	box-shadow: 0 6px 20px rgba(249, 181, 101, 0.5);
	color: #fff;
	flex: 0 0 auto;
	font-weight: 600;
	padding: 11px 28px;
	text-decoration: none;
	transition: box-shadow 0.2s ease, transform 0.2s ease;
}

/* Au survol, les boutons grossissent légèrement */
.cc-fiche .cc-fiche__y-aller:hover {
	box-shadow: 0 10px 26px rgba(249, 181, 101, 0.65);
	transform: scale(1.05);
}

/* Colonne droite : les offres. Décalées de la hauteur du lien retour, pour que
   le premier titre s'aligne sur le haut de la photo */

.cc-fiche__offres {
	padding-top: calc(1.4em + 16px);
}

.cc-fiche__bloc + .cc-fiche__bloc {
	margin-top: 32px;
}

.cc-fiche .cc-fiche__titre {
	color: var(--cc-encre);
	font-family: "CC Basier", Helvetica, Arial, sans-serif;
	font-size: 21px;
	font-weight: 600;
	line-height: 1.2;
	margin: 0;
	padding: 0;
}

.cc-fiche .cc-fiche__sous-titre {
	color: var(--cc-bleu-texte);
	margin: 2px 0 14px;
	padding: 0;
}

.cc-fiche .cc-fiche__liste {
	display: grid;
	gap: 10px;
	list-style: none;
	margin: 0;
	padding: 0;
}

.cc-fiche__offre {
	align-items: center;
	border-radius: 20px;
	color: #fff;
	display: flex;
	font-size: 16px;
	font-weight: 500;
	gap: 14px;
	line-height: 1.3;
	padding: 12px 20px 15px 14px;
}

.cc-fiche__offre--one-shot {
	background: var(--cc-orange);
	box-shadow: inset 0 -5px 0 var(--cc-orange-fonce);
}

.cc-fiche__offre--permanente {
	background: var(--cc-bleu);
	box-shadow: inset 0 -5px 0 var(--cc-bleu-texte);
}

.cc-fiche__offre span {
	align-items: center;
	background: rgba(255, 255, 255, 0.35);
	border-radius: 50%;
	display: flex;
	flex: 0 0 auto;
	font-size: 22px;
	height: 46px;
	justify-content: center;
	width: 46px;
}

.cc-fiche__offre--permanente span {
	background: #fff;
}

.cc-fiche__profiter {
	margin-top: 28px;
	text-align: center;
}

.cc-fiche .cc-fiche__bouton {
	background: var(--cc-creme);
	border-radius: 40px;
	box-shadow: 0 6px 30px rgba(32, 40, 88, 0.14);
	color: var(--cc-encre);
	display: inline-block;
	font-weight: 600;
	padding: 18px 40px;
	text-decoration: none;
	transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.cc-fiche .cc-fiche__bouton:hover {
	box-shadow: 0 10px 34px rgba(32, 40, 88, 0.2);
	transform: scale(1.05);
}

.cc-fiche .cc-fiche__mention {
	color: var(--cc-bleu-texte);
	font-size: 14px;
	margin: 16px 0 0;
	padding: 0;
}

/* Tablette : les deux colonnes s'empilent */
@media (max-width: 980px) {
	.cc-fiche__contenu {
		gap: 32px;
		grid-template-columns: minmax(0, 1fr);
		padding: 8px 16px 64px;
	}

	.cc-fiche__partenaire {
		position: static;
	}

	/* Colonnes empilées : plus rien à aligner */
	.cc-fiche__offres {
		padding-top: 0;
	}

	.cc-fiche .cc-fiche__nom {
		font-size: 34px;
	}
}

/* Mobile : calqué sur la fiche de l'appli */
@media (max-width: 767px) {
	.cc-fiche__contenu {
		gap: 18px;
		padding: 0 0 56px;
	}

	/* Le décalage de la colonne fixe du desktop ne doit pas s'appliquer ici */
	.cc-fiche__partenaire,
	.admin-bar .cc-fiche__partenaire {
		position: relative;
		top: 0;
	}

	/* Bouton retour rond, posé sur la photo */
	.cc-fiche .cc-fiche__retour {
		background: #fff;
		border-radius: 50%;
		box-shadow: 0 4px 14px rgba(32, 40, 88, 0.2);
		font-size: 24px;
		height: 40px;
		justify-content: center;
		left: 12px;
		line-height: 1;
		margin: 0;
		padding-bottom: 4px;
		position: absolute;
		top: 12px;
		width: 40px;
		z-index: 2;
	}

	.cc-fiche__retour-texte {
		clip: rect(0 0 0 0);
		clip-path: inset(50%);
		height: 1px;
		overflow: hidden;
		position: absolute;
		white-space: nowrap;
		width: 1px;
	}

	.cc-fiche__photo {
		aspect-ratio: 4 / 3;
		border-radius: 0;
	}

	.cc-fiche__logo {
		border-color: var(--cc-creme);
		bottom: -32px;
		height: 76px;
		left: 24px;
		width: 76px;
	}

	.cc-fiche .cc-fiche__nom,
	.cc-fiche .cc-fiche__categorie,
	.cc-fiche .cc-fiche__tags,
	.cc-fiche__adresse,
	.cc-fiche__offres {
		margin-left: 28px;
		margin-right: 28px;
	}

	.cc-fiche .cc-fiche__nom {
		font-size: 28px;
		margin-top: 44px;
	}

	.cc-fiche .cc-fiche__categorie {
		font-size: 16px;
		margin-bottom: 12px;
	}

	.cc-fiche .cc-fiche__tags {
		margin-bottom: 14px;
	}

	.cc-fiche__adresse {
		font-size: 14px;
		gap: 12px;
		padding: 12px 0;
	}

	.cc-fiche .cc-fiche__y-aller {
		padding: 10px 22px;
	}

	.cc-fiche__bloc + .cc-fiche__bloc {
		margin-top: 22px;
	}

	.cc-fiche .cc-fiche__titre {
		font-size: 18px;
	}

	.cc-fiche .cc-fiche__sous-titre {
		font-size: 13px;
		margin-bottom: 10px;
	}

	.cc-fiche__offre {
		font-size: 16px;
		padding: 14px 16px 17px 14px;
	}

	.cc-fiche__offre span {
		font-size: 24px;
		height: 52px;
		width: 52px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.cc-fiche *,
	.cc-fiche *::before,
	.cc-fiche *::after {
		transition: none !important;
	}
}
