/**
 * Widget Détail opportunité (Single) — design calqué sur le template d'origine.
 * Hero image pleine largeur (full-bleed) + bandeau titre/meta + corps 2 colonnes.
 */
.snf-detail {
	--green:  var(--snf-green, #00A8E8);
	--green2: var(--snf-green2, #00D9FF);
	--navy:   var(--snf-navy, #1A2A3A);
	--white:  var(--snf-white, #fff);
	--muted:  var(--snf-muted, #777);
	--paper:  var(--snf-paper, #F5F0E8);
}

/* ------------------------------------------------------------------ */
/* Hero image pleine largeur (image mise en avant de l'opportunité).    */
/* full-bleed : s'étend d'un bord à l'autre quel que soit le conteneur. */
/* ------------------------------------------------------------------ */
.det-image-hero,
.det-hero {
	width: 100vw;
	margin-left: calc(50% - 50vw);
	margin-right: calc(50% - 50vw);
}
.det-image-hero {
	position: relative;
	height: clamp(200px, 34vw, 340px);
	margin-top: -10px;
	overflow: hidden;
	background-color: #f0f0f0;
	background-size: cover;
	background-position: center center;
	background-repeat: no-repeat;
}
.det-image-overlay {
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, .2) 50%, rgba(0, 168, 232, .5) 100%);
	z-index: 2;
}

/* Bandeau titre + badges + meta-strip. */
.det-hero {
	background: linear-gradient(135deg, rgba(0, 168, 232, .05), rgba(0, 217, 255, .05));
	padding: 46px 6% 38px;
	position: relative;
	overflow: hidden;
}
.det-hero-inner {
	position: relative;
	z-index: 2;
	max-width: 1200px;
	margin: 0 auto;
}
.det-badges {
	display: flex;
	gap: 10px;
	flex-wrap: wrap;
	margin-bottom: 18px;
}
.detail-badge {
	display: inline-flex;
	align-items: center;
	font-family: var(--fh, 'Josefin Sans', sans-serif);
	font-size: .62rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .11em;
	padding: 5px 13px;
	border-radius: 100px;
	border: 1.5px solid rgba(0, 168, 232, .5);
	color: var(--green);
	background: rgba(0, 217, 255, .15);
}
.det-type-subvention { border-color: rgba(0, 217, 255, .6); color: #00A8E8; background: rgba(0, 217, 255, .15); }
.det-type-pret       { border-color: rgba(255, 215, 0, .7); color: #b8860b; background: rgba(255, 215, 0, .14); }
.det-statut-encours  { border-color: rgba(31, 157, 85, .5); color: #1f9d55; background: rgba(31, 157, 85, .12); }
.det-statut-cloture  { border-color: rgba(211, 47, 47, .5); color: #d32f2f; background: rgba(220, 0, 0, .10); }

.detail-title {
	font-family: var(--fd, 'Josefin Sans', sans-serif);
	font-size: clamp(2rem, 4.5vw, 3.4rem);
	color: var(--navy);
	line-height: 1;
	letter-spacing: .03em;
	margin: 0 0 8px;
	max-width: 900px;
}

.det-meta-strip {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
	gap: 18px 24px;
	margin-top: 26px;
}
.det-meta-label {
	font-family: var(--fh, 'Josefin Sans', sans-serif);
	font-size: .65rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .11em;
	color: var(--muted);
	margin-bottom: 6px;
}
.det-meta-val {
	font-family: var(--fh, 'Josefin Sans', sans-serif);
	font-size: .95rem;
	font-weight: 700;
	color: var(--navy);
}
.det-meta-val.green { color: var(--green); font-size: 1rem; }
.det-meta-val--sm   { font-size: .78rem; line-height: 1.4; font-weight: 600; }
.det-bailleur-val {
	display: flex;
	align-items: center;
	gap: 10px;
}
.det-bailleur-logo {
	width: 34px;
	height: 34px;
	object-fit: contain;
	border-radius: 50%;
	background: #fff;
	padding: 3px;
	flex-shrink: 0;
	border: 1px solid rgba(0, 0, 0, .08);
	box-shadow: 0 1px 4px rgba(0, 0, 0, .1);
}

/* ------------------------------------------------------------------ */
/* Corps : contenu principal + sidebar.                                 */
/* ------------------------------------------------------------------ */
.det-body {
	max-width: 1200px;
	margin: 0 auto;
	padding: 46px 6%;
	display: grid;
	grid-template-columns: 1fr 340px;
	gap: 32px;
	align-items: start;
}

/* Sections principales. */
.det-section {
	background: var(--white);
	border-radius: 12px;
	padding: 26px 30px;
	margin-bottom: 20px;
	border: 1px solid #E3DBD0;
	box-shadow: 0 1px 6px rgba(0, 0, 0, .05);
}
.det-section:last-child { margin-bottom: 0; }
.det-section-head {
	margin-bottom: 18px;
	padding-bottom: 14px;
	border-bottom: 2px solid #F0E8DF;
}
.det-section-title {
	font-family: var(--fd, 'Josefin Sans', sans-serif);
	font-size: 1.5rem;
	letter-spacing: .04em;
	color: var(--navy);
}
.det-section p {
	font-size: .93rem;
	color: #454545;
	line-height: 1.8;
	margin: 0;
}

/* Checklist (puces cochées). */
.det-list {
	list-style: none;
	padding: 0;
	margin: 4px 0 0;
	display: flex;
	flex-direction: column;
	gap: 10px;
}
.det-list li {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	font-size: .91rem;
	color: #454545;
	line-height: 1.65;
}
.det-list li::before {
	content: '✓';
	display: flex;
	align-items: center;
	justify-content: center;
	min-width: 20px;
	height: 20px;
	background: linear-gradient(135deg, var(--green), var(--green2));
	color: #fff;
	border-radius: 50%;
	font-size: .6rem;
	font-weight: 800;
	margin-top: 1px;
	box-shadow: 0 2px 6px rgba(0, 168, 232, .25);
}

/* Sidebar. */
.det-sidebar { position: relative; }
.det-side-card,
.det-docs-section {
	background: var(--white);
	border-radius: 12px;
	border: 1px solid #E3DBD0;
	overflow: hidden;
	margin-bottom: 16px;
	box-shadow: 0 1px 6px rgba(0, 0, 0, .05);
}
.det-side-head {
	background: linear-gradient(135deg, var(--navy), #0d2e1e);
	padding: 13px 18px;
}
.det-side-head h4 {
	font-family: var(--fh, 'Josefin Sans', sans-serif);
	font-size: .68rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .13em;
	color: var(--green2);
	margin: 0;
}
.det-info-row {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 8px;
	padding: 11px 18px;
	border-bottom: 1px solid #F0E8DF;
}
.det-info-row:last-child { border-bottom: none; }
.det-ir-label {
	font-family: var(--fh, 'Josefin Sans', sans-serif);
	font-size: .63rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: .09em;
	color: #9a9087;
	flex-shrink: 0;
}
.det-ir-val {
	font-family: var(--fh, 'Josefin Sans', sans-serif);
	font-size: .82rem;
	font-weight: 700;
	color: var(--navy);
	text-align: right;
	max-width: 190px;
	word-break: break-word;
}
.det-ir-val--green { color: var(--green); font-size: .95rem; }
.det-ir-val--bailleur {
	display: flex;
	align-items: center;
	gap: 8px;
	justify-content: flex-end;
}
.det-ir-logo {
	width: 26px;
	height: 26px;
	object-fit: contain;
	border-radius: 50%;
	background: #fff;
	padding: 2px;
	flex-shrink: 0;
	border: 1px solid rgba(0, 0, 0, .08);
	box-shadow: 0 1px 3px rgba(0, 0, 0, .1);
}

/* CTA. */
.det-cta-stack {
	display: flex;
	flex-direction: column;
	gap: 10px;
}
.det-btn-primary,
.det-btn-secondary {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	font-family: var(--fh, 'Josefin Sans', sans-serif);
	font-size: .8rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .1em;
	padding: 15px 20px;
	border-radius: 10px;
	text-decoration: none;
	cursor: pointer;
	width: 100%;
}
.det-btn-primary {
	background: linear-gradient(135deg, var(--green), var(--green2));
	color: #fff;
	border: none;
	box-shadow: 0 4px 16px rgba(0, 168, 232, .3);
	transition: opacity .2s, transform .15s;
}
.det-btn-primary:hover { opacity: .92; transform: translateY(-1px); color: #fff; }
.det-btn-secondary {
	background: var(--white);
	color: var(--navy);
	border: 2px solid #E3DBD0;
	transition: all .2s;
}
.det-btn-secondary:hover { border-color: var(--green); color: var(--green); }

/* Documents. */
.det-docs-head {
	background: linear-gradient(135deg, #FF8C42, #FF6B35);
	padding: 13px 18px;
}
.det-docs-head h4 {
	font-family: var(--fh, 'Josefin Sans', sans-serif);
	font-size: .68rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .13em;
	color: #fff;
	margin: 0;
}
.det-doc-item {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	padding: 12px 18px;
	border-bottom: 1px solid #F0E8DF;
	transition: background .2s;
}
.det-doc-item:last-child { border-bottom: none; }
.det-doc-item:hover { background: #FAFAF8; }
.det-doc-info {
	display: flex;
	align-items: center;
	gap: 12px;
	flex: 1;
	min-width: 0;
}
.det-doc-icon {
	color: var(--green);
	flex-shrink: 0;
	display: inline-flex;
}
.det-doc-name {
	display: flex;
	flex-direction: column;
	gap: 2px;
	min-width: 0;
}
.det-doc-title {
	font-family: var(--fh, 'Josefin Sans', sans-serif);
	font-size: .8rem;
	font-weight: 600;
	color: var(--navy);
}
.det-doc-size {
	font-family: var(--fh, 'Josefin Sans', sans-serif);
	font-size: .6rem;
	color: #9a9087;
	text-transform: uppercase;
	letter-spacing: .04em;
}
.det-doc-dl {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	background: #f5f3f0;
	color: var(--navy);
	border-radius: 8px;
	flex-shrink: 0;
	transition: all .2s;
	text-decoration: none;
}
.det-doc-dl:hover { background: var(--green); color: #fff; }

/* ------------------------------------------------------------------ */
/* Responsive.                                                          */
/* ------------------------------------------------------------------ */
@media (max-width: 960px) {
	.det-body { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
	.det-hero { padding: 32px 6% 28px; }
	.det-section { padding: 22px 20px; }
}

/* ------------------------------------------------------------------ */
/* Barre d'action collante (mobile) — action primaire au pouce.        */
/* ------------------------------------------------------------------ */
.snf-detail__actionbar {
	display: none;
}
@media (max-width: 767px) {
	.snf-detail__actionbar {
		position: fixed;
		left: 0;
		right: 0;
		bottom: 0;
		z-index: 250;
		display: flex;
		align-items: center;
		gap: 14px;
		padding: 12px 5%;
		padding-bottom: calc(12px + env(safe-area-inset-bottom, 0px));
		background: var(--snf-white, #fff);
		border-top: 1px solid var(--snf-border, #E8E2D8);
		box-shadow: 0 -6px 24px rgba(0, 0, 0, .12);
		animation: snf-actionbar-in .3s ease both;
	}
	@media (prefers-reduced-motion: reduce) {
		.snf-detail__actionbar { animation: none; }
	}
	.snf-detail__actionbar-info {
		display: flex;
		flex-direction: column;
		line-height: 1.2;
		flex-shrink: 0;
	}
	.snf-detail__actionbar-info span {
		font-family: var(--fh, 'Josefin Sans', sans-serif);
		font-size: .6rem;
		font-weight: 700;
		text-transform: uppercase;
		letter-spacing: .1em;
		color: var(--snf-muted, #777);
	}
	.snf-detail__actionbar-info strong {
		font-family: var(--fd, 'Josefin Sans', sans-serif);
		font-size: 1.05rem;
		color: var(--snf-navy, #1A2A3A);
	}
	.snf-detail__actionbar-cta {
		flex: 1 1 auto;
		text-align: center;
		min-height: 48px;
		display: inline-flex;
		align-items: center;
		justify-content: center;
		padding: 12px 18px;
	}
	.snf-detail--has-actionbar {
		padding-bottom: 84px;
	}
}
@keyframes snf-actionbar-in {
	from { transform: translateY(100%); }
	to   { transform: none; }
}
