/**
 * Concours — vue publique (alignée sur le style « duels des dieux » / missions maisons).
 */

.avc--front {
	max-width: 980px;
	margin: 0 auto 2.5rem;
	font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
	color: #0f172a;
}

.avc-section {
	margin-bottom: 2.75rem;
}

.avc-section__head {
	margin-bottom: 1.1rem;
}

.avc-section-title {
	margin: 0;
	font-size: 1.35rem;
	font-weight: 800;
	letter-spacing: -0.02em;
	padding-bottom: 0.5rem;
	border-bottom: 3px solid transparent;
	border-image: linear-gradient(90deg, #6366f1, #8b5cf6, #f59e0b) 1;
}

.avc-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
	gap: 1.35rem;
}

/* Carte concours — même esprit que .avm-mission */
.avc-card {
	position: relative;
	display: flex;
	flex-direction: column;
	border-radius: 20px;
	overflow: hidden;
	background: linear-gradient(155deg, #0f172a 0%, #1e293b 55%, #334155 100%);
	color: #f1f5f9;
	border: 1px solid rgba(148, 163, 184, 0.22);
	box-shadow: 0 20px 50px -20px rgba(15, 23, 42, 0.55);
}

.avc-card::before {
	content: "";
	position: absolute;
	inset: 0 0 auto 0;
	height: 3px;
	background: linear-gradient(90deg, #6366f1, #8b5cf6, #f59e0b);
	opacity: 0.9;
	z-index: 2;
}

.avc-card--active {
	border-color: rgba(239, 68, 68, 0.4);
	box-shadow: 0 0 0 1px rgba(239, 68, 68, 0.12), 0 24px 56px -16px rgba(239, 68, 68, 0.28);
}

.avc-card--upcoming {
	border-color: rgba(56, 189, 248, 0.35);
	box-shadow: 0 0 0 1px rgba(56, 189, 248, 0.1), 0 20px 48px -18px rgba(14, 165, 233, 0.2);
}

.avc-card--ended {
	opacity: 0.92;
	filter: saturate(0.88);
}

.avc-card__hero {
	position: relative;
	max-height: 200px;
	overflow: hidden;
	flex-shrink: 0;
}

.avc-card__hero-img {
	width: 100%;
	height: 200px;
	object-fit: cover;
	display: block;
	vertical-align: middle;
}

.avc-card__hero-scrim {
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, transparent 0%, rgba(15, 23, 42, 0.55) 70%, #1e293b 100%);
	pointer-events: none;
}

.avc-card-body {
	padding: 1.1rem 1.2rem 1.25rem;
	flex: 1;
	display: flex;
	flex-direction: column;
	gap: 0.55rem;
}

.avc-card__head {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 0.65rem;
	margin-bottom: 0.15rem;
}

.avc-card-title {
	margin: 0;
	font-size: 1.2rem;
	font-weight: 800;
	letter-spacing: -0.02em;
	line-height: 1.25;
	flex: 1;
	min-width: 0;
}

.avc-phase-pill {
	flex-shrink: 0;
	font-size: 0.62rem;
	font-weight: 800;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	padding: 0.28rem 0.55rem;
	border-radius: 999px;
	border: 1px solid rgba(255, 255, 255, 0.12);
	background: rgba(255, 255, 255, 0.08);
	color: #e2e8f0;
}

.avc-phase-pill--active {
	background: #ef4444;
	border-color: rgba(255, 255, 255, 0.2);
	color: #fff;
	animation: avc-pulse 1.6s ease-in-out infinite;
}

.avc-phase-pill--upcoming {
	background: rgba(14, 165, 233, 0.35);
	border-color: rgba(125, 211, 252, 0.45);
	color: #e0f2fe;
}

.avc-phase-pill--ended {
	background: rgba(71, 85, 105, 0.5);
	color: #cbd5e1;
}

@keyframes avc-pulse {
	0%,
	100% {
		opacity: 1;
	}
	50% {
		opacity: 0.72;
	}
}

.avc-card-excerpt {
	margin: 0;
	font-size: 0.9rem;
	line-height: 1.5;
	color: #cbd5e1;
}

.avc-rewards {
	margin: 0.2rem 0 0;
	padding: 0.65rem 0.75rem;
	border-radius: 12px;
	background: rgba(245, 158, 11, 0.12);
	border: 1px solid rgba(245, 158, 11, 0.32);
	font-size: 0.88rem;
	line-height: 1.45;
}

.avc-rewards-label {
	display: block;
	font-weight: 800;
	font-size: 0.68rem;
	text-transform: uppercase;
	letter-spacing: 0.1em;
	margin-bottom: 0.35rem;
	color: #fde68a;
}

.avc-rewards-body {
	margin: 0;
	color: #fef3c7;
}

.avc-rewards-body p:first-child {
	margin-top: 0;
}

.avc-rewards-body p:last-child {
	margin-bottom: 0;
}

.avc-card .avc-rewards-body a {
	color: #fde68a;
	text-decoration: underline;
	text-underline-offset: 2px;
}

.avc-countdown {
	display: flex;
	align-items: baseline;
	justify-content: center;
	flex-wrap: wrap;
	gap: 0.5rem 0.75rem;
	margin: 0.35rem 0 0;
	padding: 0.55rem 0.85rem;
	border-radius: 12px;
	background: rgba(0, 0, 0, 0.35);
	border: 1px solid rgba(255, 255, 255, 0.08);
}

.avc-countdown-label {
	font-size: 0.72rem;
	text-transform: uppercase;
	letter-spacing: 0.08em;
	color: #94a3b8;
}

.avc-countdown-value {
	font-variant-numeric: tabular-nums;
	font-size: 1.45rem;
	font-weight: 800;
	color: #fef3c7;
}

.avc-end-hint {
	margin: 0;
	font-size: 0.82rem;
	color: #94a3b8;
	text-align: center;
}

.avc-req {
	margin: 0.35rem 0 0;
	padding: 0.75rem 0.85rem;
	border-radius: 12px;
	border: 1px solid rgba(148, 163, 184, 0.35);
	background: rgba(15, 23, 42, 0.45);
	font-size: 0.88rem;
}

.avc-req__title {
	margin: 0 0 0.5rem;
	font-size: 0.95rem;
	font-weight: 700;
	color: #e2e8f0;
}

.avc-req__note {
	margin: 0 0 0.5rem;
	color: #cbd5e1;
	line-height: 1.45;
}

.avc-req__list,
.avc-req__status {
	margin: 0 0 0.65rem;
	padding-left: 1.15rem;
	color: #cbd5e1;
}

.avc-req__list a,
.avc-req__status-item a {
	color: #a5b4fc;
}

.avc-req__status-item--ok::before {
	content: "✓ ";
	color: #4ade80;
}

.avc-req__status-item--pending::before {
	content: "○ ";
	color: #fbbf24;
}

.avc-req__status-item--fail::before {
	content: "! ";
	color: #f87171;
}

.avc-req__ig-form {
	margin-top: 0.65rem;
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
	align-items: flex-start;
}

.avc-req__ig-label span {
	display: block;
	font-size: 0.82rem;
	color: #94a3b8;
	margin-bottom: 0.25rem;
}

.avc-req__ig-label input {
	width: 100%;
	max-width: 280px;
	padding: 0.45rem 0.55rem;
	border-radius: 8px;
	border: 1px solid rgba(148, 163, 184, 0.4);
	background: rgba(0, 0, 0, 0.25);
	color: #f8fafc;
	font-family: inherit;
}

.avc-btn--ig,
.avc-btn--primary {
	background: rgba(99, 102, 241, 0.25);
	color: #e0e7ff;
	border: 1px solid rgba(129, 140, 248, 0.45);
	box-shadow: none;
}

.avc-btn--primary {
	background: linear-gradient(135deg, #6366f1, #8b5cf6);
	color: #fff;
	border: none;
}

.avc-req__ig-msg {
	margin: 0;
	font-size: 0.82rem;
}

.avc-req__ig-msg--ok {
	color: #86efac;
}

.avc-req__ig-msg--err {
	color: #fca5a5;
}

.avc-req__ig-done {
	margin: 0.5rem 0 0;
	color: #cbd5e1;
}

.avc-req__ig-done a {
	color: #a5b4fc;
}

.avc-register-form {
	margin-top: 0.5rem;
	padding: 0.85rem;
	border-radius: 12px;
	border: 1px solid rgba(129, 140, 248, 0.35);
	background: rgba(99, 102, 241, 0.1);
	display: flex;
	flex-direction: column;
	gap: 0.65rem;
}

.avc-register-form__step {
	margin: 0;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.5rem;
}

.avc-register-form__step-n {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 1.35rem;
	height: 1.35rem;
	border-radius: 999px;
	background: rgba(99, 102, 241, 0.35);
	color: #e0e7ff;
	font-size: 0.75rem;
	font-weight: 800;
}

.avc-registered-ok {
	margin: 0;
	font-size: 0.9rem;
	color: #86efac;
	font-weight: 600;
	text-align: center;
}

.avc-btn-register--submit {
	width: 100%;
}

.avc-conditions {
	margin: 0.35rem 0 0;
	font-size: 0.88rem;
	border-radius: 12px;
	border: 1px solid rgba(255, 255, 255, 0.1);
	background: rgba(255, 255, 255, 0.04);
	padding: 0.35rem 0.65rem 0.5rem;
}

.avc-conditions summary {
	cursor: pointer;
	font-weight: 700;
	list-style: none;
	color: #c7d2fe;
	padding: 0.25rem 0;
}

.avc-conditions summary::-webkit-details-marker {
	display: none;
}

.avc-conditions summary::after {
	content: "▾";
	float: right;
	font-size: 0.75rem;
	opacity: 0.7;
	transition: transform 0.2s ease;
}

.avc-conditions[open] summary::after {
	transform: rotate(-180deg);
}

.avc-conditions-body {
	margin-top: 0.45rem;
	padding-top: 0.45rem;
	border-top: 1px solid rgba(255, 255, 255, 0.08);
	line-height: 1.55;
	color: #e2e8f0;
}

.avc-conditions-body a {
	color: #a5b4fc;
}

.avc-card__foot {
	margin-top: auto;
	padding-top: 0.75rem;
	display: flex;
	flex-direction: column;
	gap: 0.65rem;
	align-items: stretch;
}

.avc-participants {
	margin: 0;
	font-size: 0.82rem;
	font-weight: 600;
	color: #a5b4fc;
	text-align: center;
	padding: 0.4rem 0.5rem;
	border-radius: 10px;
	background: rgba(99, 102, 241, 0.12);
	border: 1px solid rgba(129, 140, 248, 0.25);
}

.avc-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	text-align: center;
	gap: 0.35rem;
	padding: 0.65rem 1.1rem;
	border-radius: 12px;
	font-size: 0.92rem;
	font-weight: 700;
	font-family: inherit;
	cursor: pointer;
	border: none;
	text-decoration: none;
	transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.15s ease;
}

.avc-btn-register {
	background: linear-gradient(135deg, #4f46e5, #7c3aed);
	color: #fff;
	box-shadow: 0 8px 24px rgba(79, 70, 229, 0.35);
}

.avc-btn-register:hover:not(:disabled) {
	transform: translateY(-1px);
	box-shadow: 0 12px 28px rgba(79, 70, 229, 0.45);
}

.avc-btn-register:disabled,
.avc-btn-register.is-registered {
	background: rgba(34, 197, 94, 0.25);
	color: #bbf7d0;
	border: 1px solid rgba(74, 222, 128, 0.35);
	box-shadow: none;
	cursor: default;
}

.avc-btn--ghost {
	background: rgba(255, 255, 255, 0.08);
	color: #e2e8f0;
	border: 1px solid rgba(255, 255, 255, 0.18);
	box-shadow: none;
}

.avc-btn--ghost:hover {
	background: rgba(255, 255, 255, 0.14);
	color: #fff;
}

.avc-empty {
	max-width: 560px;
	margin: 2rem auto;
	padding: 2rem 1.5rem;
	text-align: center;
	border-radius: 20px;
	background: linear-gradient(155deg, #0f172a 0%, #1e293b 100%);
	color: #cbd5e1;
	border: 1px solid rgba(148, 163, 184, 0.25);
	box-shadow: 0 16px 40px -20px rgba(15, 23, 42, 0.5);
}

.avc-empty p {
	margin: 0;
	font-size: 1rem;
	line-height: 1.5;
}

@media (max-width: 520px) {
	.avc-grid {
		grid-template-columns: 1fr;
	}

	.avc-card__head {
		flex-direction: column;
		align-items: flex-start;
	}

	.avc-phase-pill {
		align-self: flex-start;
	}
}
