/**
 * Styles du shortcode [spliff_ty_page] (thank you page custom).
 * Matche la maquette : header bleu indigo, lignes produit, totaux, RIB, etc.
 */

:root {
	--slty-accent: #5A8BFF;
	--slty-accent-hover: #4A7BEF;
	--slty-accent-light: rgba(90, 139, 255, 0.08);
	--slty-text: #1A1A1A;
	--slty-muted: #6B7280;
	--slty-border: #E5E7EB;
	--slty-card-bg: #FFFFFF;
	--slty-page-bg: #F9F9F9;
	--slty-radius: 12px;
	--slty-shadow: 0 1px 3px rgba(27, 27, 27, 0.06);
	--slty-font: 'Instrument Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
	--slty-font-display: 'Syne', var(--slty-font);
}

/* Force fond clair sur tout le viewport de la thankyou page (override thème) */
body.sl-ty-page {
	background: var(--slty-page-bg) !important;
	min-height: 100vh;
}
body.sl-ty-page .elementor,
body.sl-ty-page .elementor-section-wrap,
body.sl-ty-page main {
	background: var(--slty-page-bg);
	min-height: 100vh;
}

.sl-ty {
	max-width: 720px;
	margin: 0 auto;
	padding: 0 16px 80px;
	font-family: var(--slty-font);
	color: var(--slty-text);
	display: flex;
	flex-direction: column;
	gap: 20px;
	box-sizing: border-box;
	background: var(--slty-page-bg);
}

/* ── Header (bandeau blanc + logo noir) ────────────────────────── */
.sl-ty-header {
	margin: 0 -16px 8px;
	padding: 18px 24px;
	background: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	border-bottom: 1px solid var(--slty-border);
}

.sl-ty-header__link {
	display: inline-flex;
	align-items: center;
	text-decoration: none;
	color: var(--slty-text);
}

.sl-ty-header__logo {
	max-height: 64px;
	width: auto;
	display: block;
}

.sl-ty * {
	box-sizing: border-box;
}

.sl-ty-card {
	background: var(--slty-card-bg);
	border: 1px solid var(--slty-text);
	border-radius: var(--slty-radius);
	padding: 28px 24px;
}

/* ── Bloc Merci ────────────────────────────────────────────────── */
.sl-ty-thanks {
	text-align: left;
}

.sl-ty-check {
	width: 56px;
	height: 56px;
	margin: 0 auto 16px;
	color: var(--slty-accent);
}

.sl-ty-check svg {
	width: 100%;
	height: 100%;
}

.sl-ty-thanks p {
	margin: 0 0 14px;
	font-size: 15px;
	line-height: 1.5;
}

.sl-ty-thanks__title {
	font-family: var(--slty-font-display);
	font-size: 19px !important;
	font-weight: 700;
	letter-spacing: -0.01em;
}

.sl-ty-thanks__cashback strong,
.sl-ty-thanks__cashback .woocommerce-Price-amount {
	color: var(--slty-accent);
	font-weight: 700;
}

.sl-ty-thanks__invitation {
	margin-top: 18px !important;
	font-weight: 600;
	text-align: center;
}

.sl-ty-cta {
	margin-top: 16px;
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.sl-ty-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: auto;
	min-width: 200px;
	max-width: 100%;
	min-height: 38px;
	padding: 8px 24px;
	margin: 0 auto;
	border: none;
	border-radius: 8px;
	font-family: inherit;
	font-size: 13px;
	font-weight: 600;
	text-decoration: none;
	cursor: pointer;
	transition: background 0.2s, transform 0.1s;
	background: #000;
	color: #fff;
}

.sl-ty-btn:hover {
	background: var(--slty-accent);
	color: #fff;
}

.sl-ty-btn:active {
	transform: translateY(1px);
}

.sl-ty-btn--member {
	background: #000;
}

.sl-ty-btn--submit {
	background: var(--slty-accent);
	margin-top: 12px;
}

.sl-ty-btn--submit:hover {
	background: var(--slty-accent-hover);
}

.sl-ty-btn:disabled {
	opacity: 0.6;
	cursor: not-allowed;
}

/* Form password (révélation) */
.sl-ty-password-form {
	margin-top: 4px;
	padding: 16px;
	background: var(--slty-page-bg);
	border-radius: 8px;
}

.sl-ty-password-form[hidden] {
	display: none;
}

.sl-ty-password-form__title {
	margin: 0 0 12px !important;
	font-size: 14px !important;
	font-weight: 600;
	line-height: 1.4;
}

.sl-ty-password-form__input {
	display: block;
	width: 100%;
	height: 44px;
	padding: 10px 14px;
	border: 1px solid var(--slty-border);
	border-radius: 8px;
	background: #fff;
	font-family: inherit;
	font-size: 14px;
	color: var(--slty-text);
}

.sl-ty-password-form__input:focus {
	outline: none;
	border-color: var(--slty-accent);
	box-shadow: 0 0 0 3px rgba(90, 139, 255, 0.18);
}

.sl-ty-password-form__msg {
	margin-top: 10px;
	font-size: 13px;
	min-height: 18px;
	text-align: center;
}

.sl-ty-password-form__msg.sl-ty-msg--error {
	color: #DC2626;
}

.sl-ty-password-form__msg.sl-ty-msg--success {
	color: #16A34A;
	font-weight: 600;
}

/* ── Bloc RIB (BACS) ───────────────────────────────────────────── */
.sl-ty-bacs {
	border: 1.5px solid var(--slty-accent);
	background: var(--slty-accent-light);
}

.sl-ty-bacs__title {
	font-family: var(--slty-font-display);
	font-size: 18px;
	margin-bottom: 18px;
	font-weight: 700;
	letter-spacing: -0.01em;
}

.sl-ty-bacs__intro {
	margin: 0 0 22px;
	font-size: 14px;
	line-height: 1.5;
	font-weight: 400;
}

.sl-ty-bacs__intro strong,
.sl-ty-bacs__intro .woocommerce-Price-amount {
	font-weight: 700;
}

.sl-ty-bacs__details {
	margin: 0 0 22px;
	padding: 0;
	background: transparent;
	border-radius: 0;
}

.sl-ty-bacs__row {
	font-size: 14px;
	line-height: 1.8;
	word-break: break-word;
	font-weight: 400;
}

.sl-ty-bacs__row strong {
	font-weight: 600;
}

.sl-ty-bacs__notice,
.sl-ty-bacs__note {
	margin: 0 0 16px;
	font-size: 14px;
	line-height: 1.5;
	font-weight: 400;
}

.sl-ty-bacs__notice strong,
.sl-ty-bacs__note strong {
	font-weight: 600;
}

.sl-ty-bacs__note:last-child {
	margin-bottom: 0;
}

.sl-ty-bacs__mail {
	color: var(--slty-accent);
	font-weight: 600;
	text-decoration: none;
	border-bottom: 1px solid currentColor;
}

.sl-ty-bacs__mail:hover {
	color: var(--slty-accent-hover);
}

/* ── Bloc Résumé Commande ──────────────────────────────────────── */
.sl-ty-summary {
	background: var(--slty-accent-light);
	border-radius: var(--slty-radius);
	overflow: hidden;
	box-shadow: var(--slty-shadow);
	display: flex;
	flex-direction: column;
}

.sl-ty-summary__header {
	background: var(--slty-accent);
	color: #fff;
	padding: 12px 20px;
	font-family: var(--slty-font-display);
	font-size: 16px;
	font-weight: 700;
	letter-spacing: -0.005em;
}

.sl-ty-summary__body {
	padding: 16px 20px;
}

.sl-ty-summary__lines {
	display: flex;
	flex-direction: column;
}

.sl-ty-line {
	display: flex;
	align-items: center;
	gap: 14px;
	padding: 12px 0;
	border-bottom: 1px solid var(--slty-border);
}

.sl-ty-line:last-child {
	border-bottom: none;
}

.sl-ty-line__media {
	position: relative;
	width: 56px;
	height: 56px;
	flex-shrink: 0;
}

.sl-ty-line__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	border-radius: 8px;
	display: block;
	background: var(--slty-page-bg);
}

.sl-ty-line__qty {
	position: absolute;
	top: -6px;
	left: -6px;
	min-width: 22px;
	height: 22px;
	padding: 0 6px;
	border-radius: 11px;
	background: var(--slty-text);
	color: #fff;
	font-size: 11px;
	font-weight: 700;
	display: flex;
	align-items: center;
	justify-content: center;
	line-height: 1;
}

.sl-ty-line__name {
	flex: 1;
	font-size: 14px;
	color: var(--slty-text);
	line-height: 1.4;
}

.sl-ty-line__price {
	font-size: 14px;
	font-weight: 700;
	color: var(--slty-text);
	white-space: nowrap;
}

.sl-ty-free {
	color: var(--slty-text);
	font-weight: 700;
}

.sl-ty-summary__totals {
	margin-top: 16px;
	padding-top: 14px;
	border-top: 1px solid var(--slty-border);
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.sl-ty-summary__row {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	gap: 12px;
	font-size: 14px;
	color: var(--slty-text);
}

.sl-ty-summary__row > span:last-child {
	text-align: right;
}

.sl-ty-summary__shipping-method {
	color: var(--slty-muted);
	font-size: 12px;
	display: block;
}

.sl-ty-summary__row--coupon {
	color: var(--slty-accent);
	font-weight: 600;
}

.sl-ty-summary__row--total {
	margin-top: 6px;
	padding-top: 12px;
	border-top: 1px solid var(--slty-border);
	font-size: 16px;
	font-weight: 700;
}

.sl-ty-summary__tax-suffix {
	font-size: 12px;
	font-weight: 400;
	color: var(--slty-muted);
	display: block;
	margin-top: 2px;
}

/* Bouton "Retour au site" (hors résumé, pleine largeur du conteneur) */
.sl-ty-back {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	min-height: 48px;
	padding: 12px 20px;
	background: var(--slty-accent);
	color: #fff;
	border-radius: var(--slty-radius);
	text-decoration: none;
	font-size: 15px;
	font-weight: 600;
	transition: background 0.2s;
}

.sl-ty-back:hover {
	background: var(--slty-accent-hover);
	color: #fff;
}

/* ── Responsive ─────────────────────────────────────────────────── */
@media (max-width: 600px) {
	.sl-ty {
		padding: 0 12px 60px;
	}
	.sl-ty-header__logo {
		max-height: 48px;
	}
	.sl-ty-card {
		padding: 22px 18px;
	}
	.sl-ty-thanks p,
	.sl-ty-thanks__title {
		font-size: 14px !important;
	}
	.sl-ty-line__media {
		width: 48px;
		height: 48px;
	}
	.sl-ty-line__name,
	.sl-ty-line__price,
	.sl-ty-summary__row {
		font-size: 13px;
	}
	.sl-ty-summary__back {
		margin: 0 16px 16px;
	}
}
