/*
 * Module "seo" — no visual change intended.
 *
 * inc/seo-images.php wraps images in <picture class="compak-fx-pic"> to offer a lighter WebP copy.
 * "display: contents" removes the wrapper's own box, so the <img> lays out exactly as before
 * (same parent, same size, same object-fit / aspect-ratio rules).
 */
picture.compak-fx-pic {
	display: contents;
}

/*
 * The one existing rule that targets the gallery photo as a direct child of its link
 * (assets/css/shop.css, "Sac shopping" main photo cropped), repeated for the <img> inside the picture.
 */
.postid-7558 .woocommerce-product-gallery__image:first-child > a > picture > img {
	aspect-ratio: 800 / 650;
	object-position: 50% 100%;
}
/* Up to 880px shop.css switches gallery photos to "contain" with a later rule of equal weight, which
   wins over the crop there; this repeat must not out-weigh it. */
@media (min-width: 881px) {
	.postid-7558 .woocommerce-product-gallery__image:first-child > a > picture > img {
		object-fit: cover;
	}
}

/* =========================================================================================
 * Words for search engines (inc/seo-content.php): text block under the range tabs, FAQ lists,
 * home page "Questions fréquentes" band. Uses the tp-* tokens of module global.
 * ======================================================================================= */
.tp-seo-text {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
	gap: 50px;
	margin: 50px 0 60px;
	padding-top: 45px;
	border-top: 1px solid var(--tp-line, #e5e5e5);
}
.tp-seo-text__main, .tp-seo-text__faq { min-width: 0; }
.tp-seo-text .tp-seo-text__h,
.tp-seo-text .tp-faq__title {
	margin: 0 0 18px;
	color: var(--tp-heading, #16211a);
	font-size: 26px;
	font-weight: 700;
	line-height: 32px;
}
.tp-seo-text p { margin: 0 0 16px; }
.tp-seo-text__points { margin-bottom: 24px; }
.tp-seo-text__cta { margin: 0; }
@media (max-width: 959px) {
	.tp-seo-text { grid-template-columns: minmax(0, 1fr); gap: 40px; }
}
@media (max-width: 767px) {
	.tp-seo-text { margin: 30px 0 40px; padding-top: 30px; }
	.tp-seo-text .tp-seo-text__h, .tp-seo-text .tp-faq__title { font-size: 22px; line-height: 28px; }
}

/* FAQ list: native <details>, + / − marker. */
.tp-faq { border-top: 1px solid var(--tp-line, #e5e5e5); }
.tp-faq__item { border-bottom: 1px solid var(--tp-line, #e5e5e5); }
.tp-faq__q {
	position: relative;
	display: block;
	padding: 16px 44px 16px 0;
	color: var(--tp-heading, #16211a);
	font-size: 17px;
	font-weight: 500;
	line-height: 24px;
	list-style: none;
	cursor: pointer;
}
.tp-faq__q::-webkit-details-marker { display: none; }
.tp-faq__q::after {
	content: "+";
	position: absolute;
	top: 50%;
	right: 6px;
	width: 28px;
	height: 28px;
	margin-top: -14px;
	border-radius: 50%;
	background: var(--tp-accent, #00752f);
	color: #fff;
	font-size: 20px;
	font-weight: 400;
	line-height: 27px;
	text-align: center;
}
.tp-faq__item[open] > .tp-faq__q::after { content: "\2212"; }
.tp-faq__q:hover { color: var(--tp-accent, #00752f); }
.tp-faq__a { padding: 0 44px 18px 0; color: var(--tp-text, #3d4a42); }
.tp-faq__a p { margin: 0; }

/* Home page band (white, after "COMPAK, c'est aussi"). */
.tp-faq-section { padding: 0 0 70px; background: #f4f8f5; }
.tp-faq-wrap { max-width: 900px; margin: 0 auto; }
.tp-faq-section .tp-faq__title.tp-title { margin-bottom: 32px; }
.tp-faq-section .tp-faq { background: #fff; border: 1px solid var(--tp-line, #e5e5e5); border-radius: 8px; padding: 0 24px; }
.tp-faq-section .tp-faq__item:last-child { border-bottom: 0; }
@media (max-width: 767px) {
	.tp-faq-section { padding-bottom: 50px; }
	.tp-faq-section .tp-faq { padding: 0 16px; }
	.tp-faq__q { font-size: 16px; }
}

.tp-seo-read { grid-column: 1 / -1; margin: -30px 0 50px; font-size: 15px; }
.tp-seo-read a { font-weight: 500; text-decoration: underline; text-underline-offset: 3px; }

/* =========================================================================================
 * "Conseils" articles (inc/seo-articles.php, inc/seo-article-template.php).
 * ======================================================================================= */
.tp-article-main { padding: 40px 0 70px; }
.tp-article { max-width: 780px; margin: 0 auto; }
.tp-article__crumbs { margin: 0 0 18px; font-size: 14px; color: var(--tp-text, #3d4a42); }
.tp-article__crumbs span { margin: 0 6px; }
.tp-article .tp-article__title,
.tp-articles__h1 {
	margin: 0 0 14px;
	color: var(--tp-heading, #16211a);
	font-size: 40px;
	font-weight: 700;
	line-height: 48px;
	text-wrap: balance;
}
.tp-articles__h1 { margin-top: 10px; }
.tp-article__meta { margin: 0 0 26px; color: #5d6a62; font-size: 14px; }
.tp-article__media { margin: 0 0 32px; overflow: hidden; border-radius: 8px; background: #f3efe6; }
.tp-article__img { display: block; width: 100%; height: auto; max-height: 460px; object-fit: cover; }
.tp-article__body { font-size: 17px; line-height: 29px; color: var(--tp-text, #3d4a42); }
.tp-article__body h2 {
	margin: 38px 0 14px;
	color: var(--tp-heading, #16211a);
	font-size: 26px;
	font-weight: 700;
	line-height: 32px;
}
.tp-article__body p { margin: 0 0 18px; }
.tp-article__body ul { margin: 0 0 20px; padding-left: 24px; }
.tp-article__body li { margin: 0 0 8px; line-height: 27px; }
.tp-article__body li::marker { color: var(--tp-accent, #00752f); }
.tp-article__body strong { font-weight: 700; color: var(--tp-heading, #16211a); }
.tp-article__body a { font-weight: 500; text-decoration: underline; text-underline-offset: 3px; }
.tp-article__cta {
	margin: 44px 0 0;
	padding: 26px 28px;
	border-radius: 10px;
	background: #f4f8f5;
	border: 1px solid #dbe7df;
}
.tp-article__cta p { margin: 0 0 14px; }
.tp-article__cta .tp-article__cta-title { margin-bottom: 8px; color: var(--tp-heading, #16211a); font-size: 21px; font-weight: 700; line-height: 28px; }
.tp-article__cta-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin: 0 !important; }
.tp-article-more { margin-top: 30px; }

/* Article cards (list page, "À lire aussi"). */
.tp-articles__intro { max-width: 720px; margin: 0 0 34px; font-size: 18px; line-height: 28px; }
.tp-articles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 30px; }
.tp-article-card {
	display: flex;
	flex-direction: column;
	min-width: 0;
	overflow: hidden;
	border: 1px solid var(--tp-border, #e9e9e9);
	border-radius: 8px;
	background: #fff;
	transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.tp-article-card:hover, .tp-article-card:focus-within { transform: translateY(-4px); box-shadow: 0 14px 30px rgba(0, 0, 0, 0.12); }
.tp-article-card__media { display: block; aspect-ratio: 16 / 10; overflow: hidden; background: #f3efe6; }
.tp-article-card__img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s ease-out; }
.tp-article-card:hover .tp-article-card__img { transform: scale(1.05); }
.tp-article-card__body { display: flex; flex: 1; flex-direction: column; padding: 20px 22px 22px; }
.tp-article-card .tp-article-card__title { margin: 0 0 10px; font-size: 19px; font-weight: 700; line-height: 25px; }
.tp-article-card__title a { color: var(--tp-heading, #16211a); }
.tp-article-card__title a:hover { color: var(--tp-accent, #00752f); }
.tp-article-card__excerpt { margin: 0 0 16px; font-size: 15px; line-height: 23px; }
.tp-article-card__more { margin-top: auto; font-size: 14px; font-weight: 700; letter-spacing: 0.03em; text-transform: uppercase; }
.tp-article-card__more::after { content: " →"; }
@media (max-width: 959px) {
	.tp-articles { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
}
@media (max-width: 767px) {
	.tp-article-main { padding: 24px 0 50px; }
	.tp-article .tp-article__title, .tp-articles__h1 { font-size: 28px; line-height: 34px; }
	.tp-article__body { font-size: 16px; line-height: 27px; }
	.tp-article__body h2 { font-size: 22px; line-height: 28px; }
	.tp-articles { grid-template-columns: minmax(0, 1fr); }
	.tp-article__cta { padding: 20px; }
}
@media (prefers-reduced-motion: reduce) { .tp-article-card, .tp-article-card:hover, .tp-article-card__img { transition: none; transform: none; } }

/* The theme's content wrapper adds nothing on article pages (same as catalogue pages). */
body.tp-article-page #page #content.site-content { margin: 0; padding: 0; }
body.tp-article-page #content > .col-full { max-width: none; margin: 0; padding: 0; }
