/*
Theme Name: Maison
Theme URI: https://www.seo-design.io
Author: SEO Design
Description: Magazine éditorial pour les sites maison, déco et bricolage. Style par site : palette, typographie, mise en page, header, cartes (Personnaliser → Style du site). Basé sur SEO Design Pro 3.0.
Version: 3.2.0
License: GNU General Public License v2 or later
Text Domain: seodesign
*/

/* ---------- Variables (surchargées par Personnaliser → Style du site) ---------- */
:root {
	--bg: #f6f1ea; --surface: #fffdf9; --ink: #221c17; --ink-soft: #6e6259; --muted: #6e6259;
	--line: #e6ddd2; --accent: #b4532a; --accent-2: #7c8a6a; --accent-ink: #fff;
	--head-bg: #efe6da; --head-ink: #221c17; --head-soft: #6e6259; --radius: 14px;
	--font-head: Fraunces, Georgia, serif; --font-body: Inter, system-ui, sans-serif;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 17px/1.7 var(--font-body); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { font-family: var(--font-head); font-weight: 600; line-height: 1.18; letter-spacing: -.01em; margin: 0 0 .5em; color: var(--ink); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
.mh-wrap, .fl-blog-wrap { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* ---------- Header ---------- */
.mh-header { position: sticky; top: 0; z-index: 50; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.mh-header .mh-wrap { display: flex; align-items: center; gap: 24px; min-height: 72px; }
.mh-brand { display: flex; align-items: center; gap: 12px; margin-right: auto; }
.mh-logo { max-height: 44px; width: auto; }
.mh-mark { width: 38px; height: 38px; display: grid; place-items: center; border-radius: var(--radius); background: var(--accent); color: var(--accent-ink); font: 600 20px/1 var(--font-head); }
.mh-name { font: 600 21px/1.1 var(--font-head); }
.mh-nav { display: flex; align-items: center; gap: 22px; }
.mh-nav ul { list-style: none; display: flex; gap: 22px; margin: 0; padding: 0; }
.mh-nav a { font-size: 15px; font-weight: 500; color: var(--ink-soft); transition: color .2s; }
.mh-nav a:hover, .mh-nav .current-menu-item a { color: var(--accent); }
.mh-search input { width: 170px; padding: 9px 14px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); font: inherit; font-size: 14px; color: var(--ink); }
.mh-toggle, .mh-burger { display: none; }

/* ---------- En-tête magazine ---------- */
.fl-blog-head { background: var(--head-bg); color: var(--head-ink); padding: 64px 0 40px; margin-bottom: 48px; }
.fl-pill-label, .fl-cat, .fl-feat-cat, .fl-cat-pill { display: inline-block; font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.fl-blog-head h1 { color: var(--head-ink); font-size: clamp(34px, 5vw, 56px); margin: 10px 0 12px; }
.fl-blog-head p { max-width: 620px; color: var(--head-soft); margin: 0; }
.fl-cats { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 28px; }
.fl-cats a { color: var(--ink); padding: 8px 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: 14px; font-weight: 500; }
.fl-cats a:hover, .fl-cats a.is-active { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }

/* ---------- Mise en page ---------- */
.fl-blog-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 48px; padding-bottom: 80px; }
.fl-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px; }

/* Article vedette */
.fl-feat { display: grid; grid-template-columns: 1.15fr 1fr; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; margin-bottom: 32px; transition: box-shadow .25s; }
.fl-feat:hover { box-shadow: 0 18px 40px -24px rgba(0,0,0,.35); }
.fl-feat-img { position: relative; min-height: 300px; background: var(--head-bg); }
.fl-feat-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.fl-badge { position: absolute; top: 16px; left: 16px; z-index: 1; display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; background: var(--surface); font-size: 12px; font-weight: 600; }
.fl-star { width: 14px; height: 14px; }
.fl-feat-body { padding: 36px; display: flex; flex-direction: column; justify-content: center; }
.fl-feat-body h2 { font-size: clamp(24px, 2.6vw, 32px); margin: 10px 0 12px; }
.fl-readmore { display: inline-flex; align-items: center; gap: 8px; margin-top: 18px; font-weight: 600; font-size: 15px; color: var(--accent); }
.fl-readmore svg { width: 18px; height: 18px; transition: transform .2s; }
.fl-feat:hover .fl-readmore svg { transform: translateX(4px); }

/* Cartes */
.fl-card { display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: transform .25s, box-shadow .25s; }
.fl-card:hover { transform: translateY(-3px); box-shadow: 0 16px 34px -22px rgba(0,0,0,.35); }
.fl-card-img { position: relative; aspect-ratio: 16 / 10; background: var(--head-bg); overflow: hidden; }
.fl-card-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.fl-card:hover .fl-card-img img { transform: scale(1.04); }
.fl-cat-pill { position: absolute; top: 12px; left: 12px; z-index: 1; padding: 5px 10px; border-radius: 999px; background: var(--surface); font-size: 11px; }
.fl-card-body { padding: 22px 22px 24px; display: flex; flex-direction: column; flex: 1; }
.fl-card-body h3 { font-size: 21px; margin: 0 0 10px; }
.fl-card-exc { color: var(--ink-soft); font-size: 15px; line-height: 1.6; margin: 0 0 16px; }
.fl-card-meta, .fl-art-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin-top: auto; font-size: 13px; color: var(--muted); }
.dot { width: 4px; height: 4px; border-radius: 50%; background: currentColor; opacity: .6; }
.fl-ph, .fl-card-ph { position: absolute; inset: 0; display: grid; place-items: center; background: linear-gradient(135deg, var(--head-bg), color-mix(in srgb, var(--accent) 18%, var(--head-bg))); }
.fl-ph svg { width: 44px; opacity: .5; }

/* Pagination */
.fl-pagination { display: flex; justify-content: center; gap: 8px; margin-top: 48px; }
.fl-pagination a, .fl-pagination span { min-width: 42px; height: 42px; display: grid; place-items: center; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: 14px; font-weight: 600; }
.fl-pagination .current, .fl-pagination a:hover { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }

/* Sidebar */
.fl-blog-side { display: flex; flex-direction: column; gap: 24px; }
.fl-side-box, .fl-side-about { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.fl-blog-side h4 { font-size: 18px; margin-bottom: 14px; }
.fl-side-cats a { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-top: 1px solid var(--line); font-size: 15px; }
.fl-side-cats a:first-of-type { border-top: 0; }
.fl-side-cats a:hover .cname { color: var(--accent); }
.cdot { width: 8px; height: 8px; border-radius: 50%; }
.cname { flex: 1; }
.ccount { font-size: 12px; color: var(--muted); background: var(--bg); padding: 2px 8px; border-radius: 999px; }
.fl-side-recent a { display: flex; gap: 12px; align-items: center; padding: 10px 0; border-top: 1px solid var(--line); }
.fl-side-recent a:first-of-type { border-top: 0; }
.rthumb { width: 64px; height: 64px; flex: none; border-radius: calc(var(--radius) / 1.5); object-fit: cover; background: var(--head-bg); }
.rtit { font-size: 14px; font-weight: 500; line-height: 1.4; }
.fl-side-recent a:hover .rtit { color: var(--accent); }
.fl-side-about { background: var(--head-bg); color: var(--head-ink); }
.fl-side-about h4 { color: var(--head-ink); }
.fl-side-about p { margin: 0; font-size: 15px; color: var(--head-soft); }

/* ---------- Article ---------- */
.fl-back { display: inline-flex; align-items: center; gap: 6px; margin: 40px 0 24px; font-size: 14px; font-weight: 500; color: var(--ink-soft); }
.fl-back svg { width: 18px; height: 18px; }
.fl-back:hover { color: var(--accent); }
.fl-art-head h1 { font-size: clamp(32px, 4.4vw, 50px); margin: 12px 0 18px; }
.fl-art-meta { margin: 0 0 28px; }
.av { width: 30px; height: 30px; display: grid; place-items: center; border-radius: 50%; background: var(--accent); color: var(--accent-ink); font-weight: 600; font-size: 13px; }
.fl-art-cover { border-radius: var(--radius); overflow: hidden; margin-bottom: 36px; }
.fl-art-cover img { width: 100%; }
.fl-prose { max-width: 720px; font-size: 18px; }
.fl-prose > * + * { margin-top: 1.1em; }
.fl-prose h2 { font-size: 30px; margin-top: 1.8em; }
.fl-prose h3 { font-size: 23px; margin-top: 1.5em; }
.fl-prose a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.fl-prose img, .fl-prose figure { border-radius: var(--radius); }
.fl-prose blockquote { margin: 1.6em 0; padding: 4px 0 4px 24px; border-left: 3px solid var(--accent); font: 500 22px/1.5 var(--font-head); color: var(--ink); }
.fl-prose ul, .fl-prose ol { padding-left: 1.3em; }
.fl-prose li::marker { color: var(--accent); }
.fl-prose table { width: 100%; border-collapse: collapse; font-size: 15px; }
.fl-prose th, .fl-prose td { padding: 10px 12px; border-bottom: 1px solid var(--line); text-align: left; }
.fl-prose th { background: var(--head-bg); }
.fl-tags { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 40px; padding-top: 24px; border-top: 1px solid var(--line); }
.fl-tags a { padding: 5px 12px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); font-size: 13px; }
.fl-tags a:hover { border-color: var(--accent); color: var(--accent); }

/* ---------- Footer ---------- */
.mh-footer { background: var(--ink); color: color-mix(in srgb, var(--bg) 75%, transparent); padding: 56px 0 28px; font-size: 15px; }
.mh-foot-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: 40px; }
.mh-foot-name { font: 600 24px/1.2 var(--font-head); color: var(--bg); margin-bottom: 10px; }
.mh-footer h4 { font-family: var(--font-body); font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--bg); margin-bottom: 14px; }
.mh-footer ul { list-style: none; margin: 0; padding: 0; }
.mh-footer li { margin-bottom: 8px; }
.mh-footer a:hover { color: var(--bg); }
.mh-foot-bottom { margin-top: 40px; padding-top: 22px; border-top: 1px solid rgba(255,255,255,.12); font-size: 13px; }

/* ---------- Variantes par site ---------- */
/* Header centré */
.hd-centre .mh-header .mh-wrap { flex-direction: column; gap: 10px; padding-top: 18px; padding-bottom: 14px; }
.hd-centre .mh-brand { margin: 0 auto; }
.hd-centre .mh-nav { justify-content: center; }
.hd-centre .fl-blog-head { text-align: center; }
.hd-centre .fl-blog-head p { margin: 0 auto; }
.hd-centre .fl-cats { justify-content: center; }
/* Cartes */
.cd-carrees { --radius: 3px; }
.cd-plates { --radius: 10px; }
.cd-plates .fl-card, .cd-plates .fl-feat { background: transparent; border: 0; box-shadow: none; }
.cd-plates .fl-card:hover { transform: none; box-shadow: none; }
.cd-plates .fl-card-img, .cd-plates .fl-feat-img { border-radius: var(--radius); overflow: hidden; }
.cd-plates .fl-card-body { padding: 16px 0 0; }
.cd-plates .fl-feat-body { padding: 28px 0 28px 36px; }
.cd-plates .fl-card:hover h3 { color: var(--accent); }
/* Grille pleine largeur */
.lay-grille .fl-blog-layout { grid-template-columns: 1fr; }
.lay-grille .fl-blog-side { display: none; }
.lay-grille .fl-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
/* Liste éditoriale */
.lay-liste .fl-grid { grid-template-columns: 1fr; gap: 20px; }
.lay-liste .fl-card { flex-direction: row; }
.lay-liste .fl-card-img { flex: 0 0 38%; aspect-ratio: 4 / 3; }
.lay-liste .fl-card-body { justify-content: center; padding: 22px 26px; }
.lay-liste.cd-plates .fl-card-body { padding: 8px 0 8px 26px; }
.lay-liste .fl-card-body h3 { font-size: 23px; }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
	.fl-blog-layout { grid-template-columns: 1fr; }
	.lay-grille .fl-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.fl-blog-side { display: grid; grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px) {
	body { font-size: 16px; }
	.mh-wrap, .fl-blog-wrap { padding: 0 16px; }
	.mh-burger { display: grid; place-items: center; width: 42px; height: 42px; cursor: pointer; }
	.mh-burger span, .mh-burger span::before, .mh-burger span::after { content: ""; display: block; width: 22px; height: 2px; background: var(--ink); position: relative; }
	.mh-burger span::before { position: absolute; top: -7px; } .mh-burger span::after { position: absolute; top: 7px; }
	.mh-nav { display: none; position: absolute; top: 72px; left: 0; right: 0; flex-direction: column; align-items: stretch; gap: 0; padding: 12px 16px 20px; background: var(--surface); border-bottom: 1px solid var(--line); }
	.mh-toggle:checked ~ .mh-nav { display: flex; }
	.mh-nav ul { flex-direction: column; gap: 0; }
	.mh-nav li a { display: block; padding: 12px 0; border-bottom: 1px solid var(--line); }
	.mh-search input { width: 100%; margin-top: 14px; }
	.fl-blog-head { padding: 44px 0 32px; margin-bottom: 32px; }
	.fl-feat { grid-template-columns: 1fr; }
	.fl-feat-img { min-height: 220px; }
	.fl-feat-body { padding: 24px; }
	.fl-grid, .fl-blog-side, .mh-foot-grid, .lay-grille .fl-grid { grid-template-columns: 1fr; }
	.hd-centre .mh-header .mh-wrap { flex-direction: row; padding-top: 0; padding-bottom: 0; }
	.hd-centre .mh-brand { margin: 0 auto 0 0; }
	.lay-liste .fl-card { flex-direction: column; }
	.lay-liste .fl-card-body, .lay-liste.cd-plates .fl-card-body { padding: 16px 0 0; }
	.lay-liste:not(.cd-plates) .fl-card-body { padding: 20px; }
	.cd-plates .fl-feat-body { padding: 20px 0 0; }
	.fl-prose { font-size: 17px; }
}
