/* ===== Pages d'authentification (login, forgot, code, verify) ===== */

.auth-shell {
	min-height: 100vh;
	display: flex;
	background: #f4f5f7;
}

/* ---- Panneau visuel (gauche, masqué en mobile) ---- */

.auth-visual {
	position: relative;
	flex: 1 1 46%;
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
	background: #141820;
}

.auth-visual::before,
.auth-visual::after {
	content: "";
	position: absolute;
	border-radius: 50%;
	filter: blur(10px);
}

.auth-visual::before {
	width: 420px;
	height: 420px;
	top: -140px;
	left: -110px;
	background: radial-gradient(circle, rgba(1, 124, 202, .55), transparent 70%);
	animation: authFloat 16s ease-in-out infinite;
}

.auth-visual::after {
	width: 360px;
	height: 360px;
	bottom: -150px;
	right: -90px;
	background: radial-gradient(circle, rgba(255, 255, 255, .16), transparent 70%);
	animation: authFloat 20s ease-in-out infinite reverse;
}

.auth-visual-photo {
	position: absolute;
	inset: 0;
	background-size: cover;
	background-position: center;
	opacity: .55;
}

.auth-visual-overlay {
	position: absolute;
	inset: 0;
	background: linear-gradient(155deg, rgba(10, 14, 20, .92) 0%, color-mix(in srgb, var(--auth-accent, #c10040) 88%, #000) 55%, color-mix(in srgb, var(--auth-accent, #c10040) 85%, transparent) 100%);
}

.auth-visual-content {
	position: relative;
	z-index: 2;
	text-align: center;
	color: #fff;
	padding: 48px;
	max-width: 420px;
}

.auth-visual-logo-wrap {
	width: 92px;
	height: 92px;
	border-radius: 24px;
	background: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	margin: 0 auto 26px;
	box-shadow: 0 14px 32px rgba(0, 0, 0, .28);
}

.auth-visual-logo-wrap img {
	width: 62px;
	height: auto;
}

.auth-visual-content h1 {
	font-size: 1.6rem;
	font-weight: 700;
	line-height: 1.3;
	margin-bottom: 14px;
}

.auth-visual-content p {
	color: rgba(255, 255, 255, .8);
	font-size: .98rem;
	line-height: 1.55;
}

@keyframes authFloat {
	0%, 100% { transform: translate(0, 0) scale(1); }
	50% { transform: translate(24px, -18px) scale(1.06); }
}

/* ---- Panneau formulaire (droite) ---- */

.auth-form-panel {
	flex: 1 1 54%;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 32px 20px;
}

.auth-card {
	width: 100%;
	max-width: 400px;
	background: #fff;
	border-radius: 20px;
	padding: 46px 40px;
	box-shadow: 0 20px 50px rgba(20, 20, 30, .10), 0 2px 8px rgba(20, 20, 30, .06);
	text-align: center;
	animation: authRise .5s ease both;
}

@keyframes authRise {
	from { opacity: 0; transform: translateY(16px); }
	to { opacity: 1; transform: translateY(0); }
}

.auth-card-logo {
	width: 56px;
	margin: 0 auto 16px;
	display: block;
	height: auto;
}

.auth-icon {
	width: 60px;
	height: 60px;
	border-radius: 50%;
	margin: 0 auto 18px;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 1.6rem;
	color: #fff;
	background: linear-gradient(135deg, var(--auth-accent, #c10040) 0%, color-mix(in srgb, var(--auth-accent, #c10040) 70%, #000) 100%);
	box-shadow: 0 10px 24px color-mix(in srgb, var(--auth-accent, #c10040) 35%, transparent);
}

.auth-card h2 {
	font-size: 1.5rem;
	font-weight: 700;
	margin-bottom: 8px;
}

.auth-card p.subtitle {
	color: #6c757d;
	font-size: .93rem;
	margin-bottom: 26px;
}

.auth-card form {
	text-align: left;
}

.auth-field {
	margin-bottom: 22px;
}

.auth-card .form-label {
	font-weight: 600;
	font-size: .85rem;
	color: #33363d;
}

.auth-card .form-control,
.auth-card .input-group-text {
	border: 1.5px solid #e7e8ec;
	border-radius: 12px;
	padding: .65rem .9rem;
	background: #fbfbfd;
}

.auth-card .input-group-text {
	color: var(--auth-accent, #c10040);
}

.auth-card .input-group .btn-show-password {
	border: 1.5px solid #e7e8ec;
	background: #fbfbfd;
}

.auth-card .input-group {
	border-radius: 12px;
}

/* L'arrondi dépend de la position réelle dans le groupe (icône+input ou input+bouton oeil),
   pas du type d'élément : seul le bord extérieur (premier/dernier enfant) est arrondi. */
.auth-card .input-group > .form-control,
.auth-card .input-group > .input-group-text,
.auth-card .input-group > .btn-show-password {
	border-radius: 0;
}

.auth-card .input-group > :first-child {
	border-radius: 12px 0 0 12px;
}

.auth-card .input-group > :last-child {
	border-radius: 0 12px 12px 0;
}

.auth-card .input-group > *:not(:first-child) {
	border-left: none;
}

.auth-card .form-control:focus {
	border-color: var(--auth-accent, #c10040);
	box-shadow: 0 0 0 .18rem color-mix(in srgb, var(--auth-accent, #c10040) 15%, transparent);
	background: #fff;
}

.auth-card .input-group:focus-within .input-group-text,
.auth-card .input-group:focus-within .btn-show-password {
	border-color: var(--auth-accent, #c10040);
}

.code-input {
	font-size: 1.7rem;
	letter-spacing: .6rem;
	font-weight: 700;
	text-align: center;
}

.btn-auth {
	display: block;
	width: 100%;
	padding: .75rem 1rem;
	border: none;
	border-radius: 12px;
	background: linear-gradient(135deg, var(--auth-accent, #c10040) 0%, color-mix(in srgb, var(--auth-accent, #c10040) 75%, #000) 100%);
	color: #fff;
	font-weight: 600;
	letter-spacing: .01em;
	transition: transform .18s ease, box-shadow .18s ease;
	box-shadow: 0 10px 24px color-mix(in srgb, var(--auth-accent, #c10040) 28%, transparent);
}

.btn-auth:hover {
	transform: translateY(-2px);
	box-shadow: 0 14px 30px color-mix(in srgb, var(--auth-accent, #c10040) 38%, transparent);
	color: #fff;
}

.btn-auth:active {
	transform: translateY(0);
}

.auth-link {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	margin-top: 20px;
	font-size: .88rem;
	color: #6c757d;
	text-decoration: none;
	font-weight: 500;
}

.auth-link:hover {
	color: var(--auth-accent, #c10040);
}

.auth-link-plain {
	display: block;
	width: 100%;
	background: none;
	border: none;
	padding: 4px 0;
	font-size: .88rem;
	color: #6c757d;
	font-weight: 500;
	text-align: center;
}

.auth-link-plain:hover {
	color: var(--auth-accent, #c10040);
}

.auth-options {
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 10px 16px;
	margin: 4px 0 28px;
	font-size: .88rem;
}

.auth-options .form-check {
	display: flex;
	align-items: center;
	gap: 8px;
	padding-left: 0;
	margin: 0;
	min-height: 0;
}

.auth-options .form-check-input {
	margin: 0;
	flex-shrink: 0;
}

.auth-options .form-check-label {
	margin: 0;
}

.auth-options .form-check-input:checked {
	background-color: var(--auth-accent, #c10040);
	border-color: var(--auth-accent, #c10040);
}

.auth-options a {
	color: var(--auth-accent, #c10040);
	text-decoration: none;
	font-weight: 500;
}

.auth-options a:hover {
	text-decoration: underline;
}

.auth-card .alert {
	border: none;
	border-radius: 12px;
	text-align: left;
	font-size: .88rem;
}

.auth-copyright {
	text-align: center;
	color: #9aa0aa;
	font-size: .78rem;
	margin-top: 22px;
}

@media (max-width: 991.98px) {
	.auth-visual {
		display: none;
	}

	.auth-form-panel {
		padding: 40px 18px;
		min-height: 100vh;
		background: linear-gradient(180deg, #f7f7fa, #eef0f4);
	}
}

@media (prefers-reduced-motion: reduce) {
	.auth-visual::before,
	.auth-visual::after,
	.auth-card {
		animation: none;
	}
}
