/* ==========================================================================
   Haras de la Pillière — feuille de style principale
   Identité : ivoire chaud, bleu du logo, typographie serif élégante.
   ========================================================================== */

:root {
	--navy: #1e2f63;
	--navy-dark: #141f45;
	--ink: #161a26;
	--muted: #5d6376;
	--ivory: #f8f6f1;
	--sand: #efeae0;
	--line: #e1dbcd;
	--bronze: #9a7b4f;
	--white: #fff;

	--serif: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
	--sans: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;

	--wrap: 1180px;
	--prose: 720px;
	--gutter: clamp(20px, 4vw, 40px);
	--radius: 6px;
	--header-h: 84px;
	--shadow: 0 1px 2px rgba(20, 31, 69, .06), 0 8px 24px rgba(20, 31, 69, .08);
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 16px); }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
	margin: 0;
	background: var(--ivory);
	color: var(--ink);
	font-family: var(--sans);
	font-size: 1.0625rem;
	line-height: 1.7;
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
}
img, iframe, video { max-width: 100%; }
img { height: auto; }
a { color: var(--navy); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--navy-dark); }
:focus-visible { outline: 2px solid var(--navy); outline-offset: 3px; border-radius: 2px; }

h1, h2, h3, h4 {
	font-family: var(--serif);
	font-weight: 600;
	line-height: 1.1;
	letter-spacing: -.005em;
	margin: 0 0 .5em;
	color: var(--ink);
	text-wrap: balance;
}
h1 { font-size: clamp(2.6rem, 5.2vw, 4.4rem); }
h2 { font-size: clamp(2rem, 3.4vw, 3rem); }
h3 { font-size: clamp(1.4rem, 2vw, 1.75rem); line-height: 1.2; }
p { margin: 0 0 1.1em; text-wrap: pretty; }
.muted { color: var(--muted); }
.sr-only, .screen-reader-text {
	position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0;
	overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
	position: absolute; left: 12px; top: -60px; z-index: 200; background: var(--navy); color: #fff;
	padding: 10px 16px; border-radius: 4px; text-decoration: none; transition: top .2s;
}
.skip-link:focus { top: 12px; color: #fff; }

.kicker {
	font-family: var(--sans);
	font-size: .78rem; font-weight: 600; letter-spacing: .18em; text-transform: uppercase;
	color: var(--bronze); margin: 0 0 1rem;
	display: flex; align-items: center; gap: .8rem;
}
.kicker::before { content: ""; width: 32px; height: 1px; background: currentColor; flex: none; }
.kicker a { color: inherit; text-decoration: none; }
.kicker a:hover { text-decoration: underline; }

/* ---------- En-tête ---------- */
.site-header {
	position: sticky; top: 0; z-index: 100;
	border-bottom: 1px solid transparent;
	transition: border-color .25s, box-shadow .25s;
}
/* Le flou est porté par un pseudo-élément : un « backdrop-filter » sur l'en-tête lui-même
   empêcherait le menu mobile (position: fixed) de couvrir tout l'écran. */
.site-header::before {
	content: ""; position: absolute; inset: 0; z-index: -1; background: rgba(248, 246, 241, .92);
	-webkit-backdrop-filter: saturate(1.4) blur(12px); backdrop-filter: saturate(1.4) blur(12px);
}
.site-header.is-scrolled { border-bottom-color: var(--line); box-shadow: 0 6px 24px rgba(20, 31, 69, .05); }
.header-in {
	max-width: 1400px; margin: 0 auto; padding: 0 var(--gutter);
	height: var(--header-h); display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.brand { display: flex; align-items: center; gap: 14px; text-decoration: none; color: var(--ink); flex: none; position: relative; z-index: 130; }
.brand-mark { display: block; width: 46px; height: auto; }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-name { font-family: var(--serif); font-size: 1.65rem; font-weight: 700; color: var(--navy); letter-spacing: -.005em; }
.brand-sub { font-size: .66rem; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); margin-top: 4px; font-weight: 500; }

.primary-nav .menu { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: 2px; flex-wrap: nowrap; }
.primary-nav li { position: relative; }
.primary-nav a {
	display: block; padding: 10px 12px; text-decoration: none; color: var(--ink); white-space: nowrap;
	font-size: .93rem; font-weight: 500; letter-spacing: .005em; border-radius: 4px; position: relative;
}
.primary-nav a::after {
	content: ""; position: absolute; left: 13px; right: 13px; bottom: 5px; height: 1px;
	background: var(--navy); transform: scaleX(0); transform-origin: left; transition: transform .25s ease;
}
.primary-nav a:hover, .primary-nav .current-menu-item > a, .primary-nav .current-menu-ancestor > a, .primary-nav .current-menu-parent > a { color: var(--navy); }
.primary-nav a:hover::after, .primary-nav .current-menu-item > a::after, .primary-nav .current-menu-ancestor > a::after, .primary-nav .current-menu-parent > a::after { transform: scaleX(1); }

.primary-nav .menu-item-has-children > a { padding-right: 24px; }
.primary-nav .menu-item-has-children > a::before {
	content: ""; position: absolute; right: 10px; top: 50%; width: 5px; height: 5px; margin-top: -4px;
	border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg); opacity: .6;
}
.primary-nav .sub-menu {
	list-style: none; margin: 0; padding: 8px; position: absolute; left: 0; top: 100%; min-width: 210px;
	background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow);
	opacity: 0; visibility: hidden; transform: translateY(6px); transition: opacity .18s, transform .18s, visibility .18s;
}
.primary-nav li:hover > .sub-menu, .primary-nav li:focus-within > .sub-menu { opacity: 1; visibility: visible; transform: none; }
.primary-nav .sub-menu a { padding: 9px 12px; }
.primary-nav .sub-menu a::after { display: none; }
.primary-nav .sub-menu a:hover { background: var(--ivory); }

.primary-nav .menu-cta > a {
	background: var(--navy); color: #fff; padding: 10px 20px; border-radius: 999px; margin-left: 10px;
	transition: background .2s, transform .2s;
}
.primary-nav .menu-cta > a::after { display: none; }
.primary-nav .menu-cta > a:hover, .primary-nav .menu-cta.current-menu-item > a { background: var(--navy-dark); color: #fff; }

.nav-toggle { display: none; }

@media (max-width: 1240px) {
	.nav-toggle {
		display: inline-flex; align-items: center; justify-content: center; width: 46px; height: 46px;
		background: transparent; border: 1px solid var(--line); border-radius: 50%; cursor: pointer; padding: 0; position: relative; z-index: 130;
	}
	.nav-toggle-bars, .nav-toggle-bars::before, .nav-toggle-bars::after {
		display: block; width: 18px; height: 1.5px; background: var(--ink); position: relative; transition: transform .25s, background .25s, opacity .2s;
	}
	.nav-toggle-bars::before, .nav-toggle-bars::after { content: ""; position: absolute; left: 0; }
	.nav-toggle-bars::before { top: -6px; }
	.nav-toggle-bars::after { top: 6px; }
	.nav-open .nav-toggle-bars { background: transparent; }
	.nav-open .nav-toggle-bars::before { top: 0; transform: rotate(45deg); }
	.nav-open .nav-toggle-bars::after { top: 0; transform: rotate(-45deg); }

	.primary-nav {
		position: fixed; inset: 0; z-index: 120; background: var(--ivory); padding: calc(var(--header-h) + 12px) var(--gutter) 40px;
		overflow-y: auto; opacity: 0; visibility: hidden; transform: translateY(-8px); transition: opacity .25s, transform .25s, visibility .25s;
	}
	.nav-open .primary-nav { opacity: 1; visibility: visible; transform: none; }
	.nav-open { overflow: hidden; }
	.primary-nav .menu { flex-direction: column; align-items: stretch; gap: 0; max-width: 520px; margin: 0 auto; }
	.primary-nav a { font-family: var(--serif); font-size: 1.7rem; font-weight: 600; padding: 12px 0; border-bottom: 1px solid var(--line); border-radius: 0; }
	.primary-nav a::after, .primary-nav .menu-item-has-children > a::before { display: none; }
	.primary-nav .menu-item-has-children > a { padding-right: 0; }
	.primary-nav .sub-menu {
		position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; border: 0; background: transparent; padding: 0 0 6px 18px; min-width: 0;
	}
	.primary-nav .sub-menu a { font-family: var(--sans); font-size: 1rem; font-weight: 500; padding: 9px 0; color: var(--muted); border-bottom: 0; }
	.primary-nav .menu-cta > a { margin: 22px 0 0; text-align: center; font-family: var(--sans); font-size: 1rem; border: 0; padding: 14px 20px; }
}
@media (max-width: 480px) { .brand-sub { display: none; } .brand-name { font-size: 1.45rem; } }

/* ---------- Boutons ---------- */
.wp-block-buttons { display: flex; flex-wrap: wrap; gap: 12px; margin: 1.5rem 0 0; }
.wp-block-button__link, .wp-element-button {
	display: inline-block; background: var(--navy); color: #fff; padding: 13px 26px; border-radius: 999px; border: 1.5px solid var(--navy);
	font-family: var(--sans); font-size: .95rem; font-weight: 500; text-decoration: none; line-height: 1.3; cursor: pointer; transition: background .2s, color .2s, border-color .2s, transform .2s;
}
.wp-block-button__link:hover, .wp-element-button:hover { background: var(--navy-dark); border-color: var(--navy-dark); color: #fff; transform: translateY(-1px); }
.is-style-outline > .wp-block-button__link { background: transparent; color: var(--navy); }
.is-style-outline > .wp-block-button__link:hover { background: var(--navy); color: #fff; }
.hp-section--navy .wp-block-button__link { background: #fff; color: var(--navy); border-color: #fff; }
.hp-section--navy .wp-block-button__link:hover { background: var(--sand); border-color: var(--sand); color: var(--navy-dark); }
.hp-section--navy .is-style-outline > .wp-block-button__link { background: transparent; color: #fff; border-color: rgba(255,255,255,.6); }
.hp-section--navy .is-style-outline > .wp-block-button__link:hover { background: #fff; color: var(--navy); }

/* ---------- Bandeau d'accueil ---------- */
.hero { padding: clamp(28px, 5vw, 64px) 0 clamp(48px, 7vw, 96px); }
.hero-in { max-width: 1400px; margin: 0 auto; padding: 0 var(--gutter); display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: clamp(28px, 5vw, 80px); align-items: center; }
.hero h1 { font-size: clamp(3rem, 6.4vw, 5.6rem); margin-bottom: .3em; color: var(--navy-dark); }
.hero .lede { font-size: 1.25rem; color: var(--muted); max-width: 30em; }
.hero-place { font-size: .8rem; letter-spacing: .14em; text-transform: uppercase; color: var(--ink); font-weight: 500; margin-top: 1.8rem; }
.hero-media { position: relative; aspect-ratio: 5 / 4; border-radius: 10px; overflow: hidden; background: var(--sand); box-shadow: var(--shadow); }
.hero-media::after { content: ""; position: absolute; inset: 0; border-radius: inherit; box-shadow: inset 0 0 0 1px rgba(20,31,69,.08); pointer-events: none; }
.hero-slide { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 1.2s ease; }
.hero-slide.is-active { opacity: 1; }
.hero-slide:only-child { opacity: 1; }
@media (max-width: 900px) {
	.hero-in { grid-template-columns: 1fr; }
	.hero-media { order: -1; aspect-ratio: 4 / 3; }
}

/* ---------- En-tête de page ---------- */
.page-hero { padding: clamp(32px, 5vw, 72px) 0 clamp(20px, 3vw, 40px); border-bottom: 1px solid var(--line); }
.page-hero-in { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); display: grid; gap: clamp(24px, 4vw, 64px); align-items: center; }
.page-hero.has-image .page-hero-in { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); }
.page-hero h1 { font-size: clamp(2.6rem, 5vw, 4.2rem); margin-bottom: .25em; color: var(--navy-dark); }
.page-hero .lede { font-size: 1.15rem; color: var(--muted); max-width: 34em; margin-bottom: 0; }
.page-hero-media { margin: 0; aspect-ratio: 4 / 3; border-radius: 10px; overflow: hidden; background: var(--sand); box-shadow: var(--shadow); }
.page-hero-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.subnav { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 1.6rem; }
.subnav a {
	display: inline-block; padding: 7px 16px; border: 1px solid var(--line); border-radius: 999px; font-size: .9rem; font-weight: 500;
	text-decoration: none; color: var(--ink); background: #fff; transition: border-color .2s, color .2s, background .2s;
}
.subnav a:hover { border-color: var(--navy); color: var(--navy); }
.subnav a[aria-current="page"] { background: var(--navy); border-color: var(--navy); color: #fff; }
@media (max-width: 820px) {
	.page-hero.has-image .page-hero-in { grid-template-columns: 1fr; }
	.page-hero-media { order: -1; aspect-ratio: 16 / 10; }
}

/* ---------- Contenu ---------- */
.entry { padding-bottom: 1px; }
.entry > *:not(.alignfull):not(.alignwide) { max-width: var(--prose); margin-left: auto; margin-right: auto; padding-left: var(--gutter); padding-right: var(--gutter); }
.entry > .alignwide { max-width: var(--wrap); margin-left: auto; margin-right: auto; padding-left: var(--gutter); padding-right: var(--gutter); }
.entry > .alignfull { max-width: none; }
.entry > :first-child:not(.hp-section) { margin-top: 3rem; }
.entry > :last-child:not(.hp-section) { margin-bottom: 4rem; }

.hp-section { padding: clamp(48px, 7vw, 96px) 0; }
.hp-section--tint { background: var(--sand); }
.hp-section--white { background: #fff; }
.hp-section--navy { background: var(--navy); color: #eef1fa; }
.hp-section--navy h2, .hp-section--navy h3, .hp-section--navy .kicker { color: #fff; }
.hp-section--navy .kicker { color: #c9b48c; }
.hp-section--navy a { color: #fff; }
.hp-section--tight { padding: clamp(32px, 5vw, 56px) 0; }
.hp-wrap { max-width: var(--wrap); margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }
.hp-prose { max-width: var(--prose); }
.hp-center { text-align: center; margin-left: auto; margin-right: auto; }
.hp-center .kicker { justify-content: center; }
.hp-center .kicker::after { content: ""; width: 32px; height: 1px; background: currentColor; }
.hp-head { max-width: 46rem; margin-bottom: clamp(28px, 4vw, 52px); }
.hp-head p:last-child { margin-bottom: 0; }
.hp-lead { font-size: 1.28rem; line-height: 1.6; color: var(--ink); }
.hp-section h2 { margin-bottom: .45em; }

.entry ul, .entry ol { padding-left: 1.2em; margin: 0 0 1.2em; }
.entry li { margin-bottom: .5em; }
.entry li::marker { color: var(--bronze); }
.hp-ticks { list-style: none; padding: 0 !important; }
.hp-ticks li { position: relative; padding-left: 1.6em; }
.hp-ticks li::before { content: ""; position: absolute; left: 0; top: .72em; width: .8em; height: 1px; background: var(--bronze); }
.hp-ticks li::marker { content: none; }

hr, .wp-block-separator { border: 0; border-top: 1px solid var(--line); margin: 2.4rem 0; }
.wp-block-quote { margin: 2rem 0; padding: 0; border: 0; }
.hp-quote { margin: 3.2rem 0 1.6rem !important; }
.hp-quote p { font-family: var(--serif); font-size: clamp(1.5rem, 2.6vw, 2.1rem); line-height: 1.35; font-style: italic; font-weight: 500; margin-bottom: 1rem; }
.hp-quote cite { font-style: normal; font-size: .85rem; letter-spacing: .12em; text-transform: uppercase; opacity: .8; }

/* Colonnes WordPress */
.wp-block-columns { display: flex; flex-wrap: wrap; gap: clamp(24px, 4vw, 64px); align-items: center; margin: 0; }
.wp-block-column { flex: 1 1 0; min-width: 0; }
@media (max-width: 781px) { .wp-block-columns { flex-direction: column; align-items: stretch; } .wp-block-column { flex-basis: auto; } }
.wp-block-image { margin: 0 0 1.2em; }
.wp-block-image img { display: block; border-radius: 4px; }
.wp-element-caption, figcaption { font-size: .88rem; color: var(--muted); margin-top: .5rem; line-height: 1.45; }
.hp-photo img { border-radius: 8px; box-shadow: var(--shadow); }

/* ---------- Cartes de navigation (accueil) ---------- */
.hp-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(16px, 2.4vw, 32px); }
.hp-card { position: relative; background: #fff; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; transition: box-shadow .3s, transform .3s, border-color .3s; }
.hp-card:hover { box-shadow: var(--shadow); transform: translateY(-3px); border-color: #d3ccb9; }
.hp-card figure { margin: 0; aspect-ratio: 4 / 3; overflow: hidden; background: var(--sand); }
.hp-card figure img { width: 100%; height: 100%; object-fit: cover; object-position: center 30%; border-radius: 0; transition: transform .8s cubic-bezier(.2, .6, .2, 1); }
.hp-card:hover figure img { transform: scale(1.04); }
.hp-card .hp-card-body { padding: 20px 22px 24px; }
.hp-card h3 { margin: 0 0 .3em; font-size: 1.6rem; }
.hp-card h3 a { text-decoration: none; color: var(--navy-dark); }
.hp-card h3 a::after { content: ""; position: absolute; inset: 0; }
.hp-card p { margin: 0; color: var(--muted); font-size: .97rem; line-height: 1.55; }
@media (max-width: 900px) { .hp-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .hp-cards { grid-template-columns: 1fr; } }

/* ---------- Valeurs (« Notre force ») ---------- */
.hp-values { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; margin: 2.4rem 0 0; border-top: 1px solid rgba(255,255,255,.22); }
.hp-value { padding: 26px 26px 6px 0; }
.hp-value + .hp-value { padding-left: 26px; border-left: 1px solid rgba(255,255,255,.22); }
.hp-value .n { font-family: var(--serif); font-size: 1rem; letter-spacing: .1em; color: #c9b48c; margin: 0 0 .4rem; }
.hp-value h3 { font-size: 1.9rem; margin: 0; color: #fff; }
@media (max-width: 700px) {
	.hp-values { grid-template-columns: 1fr; }
	.hp-value, .hp-value + .hp-value { padding: 18px 0; border-left: 0; border-bottom: 1px solid rgba(255,255,255,.22); }
}

/* ---------- Fiches chevaux ---------- */
.hp-horses { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 44px 30px; align-items: start; }
.hp-horse { min-width: 0; }
.hp-horse .wp-block-image { margin: 0 0 16px; }
.hp-horse img { max-width: 100%; height: auto; border-radius: 6px; box-shadow: 0 1px 2px rgba(20,31,69,.08), 0 6px 18px rgba(20,31,69,.07); cursor: zoom-in; }
.hp-horse h3 { margin: 0 0 .15em; font-size: 1.65rem; color: var(--navy-dark); }
.hp-horse .meta { margin: 0 0 .5em; color: var(--muted); font-size: .96rem; line-height: 1.5; }
.hp-horse .note { margin: .4em 0 0; font-size: .96rem; line-height: 1.55; }
.hp-horse ul { font-size: .93rem; color: var(--ink); margin-top: .6em; }
.hp-horses--wide { grid-template-columns: repeat(auto-fill, minmax(min(100%, 380px), 1fr)); }
.hp-horse-lead { grid-column: 1 / -1; }

/* ---------- Galeries (maçonnerie) ----------
   Les sélecteurs sont volontairement précis : ils doivent l'emporter sur les styles par défaut
   de la galerie WordPress (largeurs par colonne, légendes superposées, etc.). */
.wp-block-gallery.has-nested-images.hp-gallery { display: block; column-count: 3; column-gap: 20px; margin: 0; padding: 0; }
.wp-block-gallery.has-nested-images.hp-gallery.columns-2 { column-count: 2; column-gap: 28px; }
.wp-block-gallery.has-nested-images.hp-gallery.columns-4 { column-count: 4; }
.wp-block-gallery.has-nested-images.hp-gallery figure.wp-block-image {
	display: block !important; position: static; break-inside: avoid; margin: 0 0 22px !important; width: auto !important; max-width: none; flex: none;
}
.wp-block-gallery.has-nested-images.hp-gallery figure.wp-block-image img {
	display: block; max-width: 100% !important; height: auto !important; border-radius: 5px; cursor: zoom-in; transition: opacity .25s;
}
.wp-block-gallery.has-nested-images.hp-gallery figure.wp-block-image img:hover { opacity: .92; }
.wp-block-gallery.has-nested-images.hp-gallery figure.wp-block-image figcaption {
	position: static; background: none; color: var(--muted); padding: 0; margin: .55rem 0 0; font-size: .88rem; line-height: 1.45;
	max-height: none; overflow: visible; text-shadow: none; width: auto; text-align: left; -webkit-backdrop-filter: none; backdrop-filter: none;
}
.wp-block-gallery.has-nested-images.hp-gallery figure.wp-block-image figcaption::before { display: none; }
@media (max-width: 900px) { .wp-block-gallery.has-nested-images.hp-gallery, .wp-block-gallery.has-nested-images.hp-gallery.columns-4 { column-count: 2; } }
@media (max-width: 520px) { .wp-block-gallery.has-nested-images.hp-gallery, .wp-block-gallery.has-nested-images.hp-gallery.columns-2, .wp-block-gallery.has-nested-images.hp-gallery.columns-4 { column-count: 1; } }

/* ---------- Chiffres clés ---------- */
.hp-stats { display: flex; flex-wrap: wrap; background: #fff; border-top: 1px solid var(--line); border-left: 1px solid var(--line); border-radius: 8px; overflow: hidden; margin: 0 0 2rem; box-shadow: 0 0 0 1px var(--line) inset; }
.hp-stat { flex: 1 1 116px; background: #fff; padding: 22px 14px; text-align: center; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); margin: 0 -1px -1px 0; }
.hp-stat .v { font-family: var(--serif); font-size: clamp(1.9rem, 3vw, 2.5rem); font-weight: 600; color: var(--navy); line-height: 1; margin: 0; }
.hp-stat .k { font-size: .7rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin: 10px 0 0; line-height: 1.3; font-weight: 500; }

/* ---------- Tableaux ---------- */
.wp-block-table { margin: 0 0 1.6rem; overflow-x: auto; }
.wp-block-table table { width: 100%; border-collapse: collapse; font-size: .98rem; }
.wp-block-table th, .wp-block-table td { padding: 14px 16px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
.wp-block-table thead th { font-family: var(--sans); font-size: .72rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); font-weight: 600; border-bottom: 2px solid var(--navy); background: transparent; }
.wp-block-table tbody th { font-weight: 600; color: var(--navy-dark); }
.hp-price table { background: #fff; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.hp-price td strong { color: var(--navy-dark); }
.hp-pedigree table { background: #fff; border: 1px solid var(--line); }
.hp-pedigree td, .hp-pedigree th { border: 1px solid var(--line); text-align: center; vertical-align: middle; }
.hp-pedigree td.is-self { background: var(--navy); color: #fff; font-family: var(--serif); font-size: 1.5rem; font-weight: 600; }
.hp-pedigree .sub { display: block; font-size: .82rem; color: var(--muted); margin-top: 2px; }
.hp-pedigree td.is-self .sub { color: #c9d1ee; }

/* ---------- Vidéos ---------- */
.hp-video { position: relative; aspect-ratio: 16 / 9; border-radius: 10px; overflow: hidden; background: #000; box-shadow: var(--shadow); margin: 0 0 2.5rem; }
.hp-video:last-child { margin-bottom: 0; }
.hp-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* ---------- Coordonnées / contact ---------- */
.hp-contact-card { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: clamp(22px, 3vw, 36px); }
.hp-contact-card h2, .hp-contact-card h3 { margin-top: 0; }
.hp-contact-list { list-style: none; padding: 0 !important; margin: 0; }
.hp-contact-list li { padding: 12px 0; border-bottom: 1px solid var(--line); margin: 0; display: flex; gap: 14px; }
.hp-contact-list li:last-child { border-bottom: 0; }
.hp-contact-list .l { flex: 0 0 96px; font-size: .72rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); font-weight: 600; padding-top: .3em; }
.hp-map { border-radius: 10px; overflow: hidden; box-shadow: var(--shadow); aspect-ratio: 21 / 9; min-height: 300px; background: var(--sand); margin-bottom: 1.5rem; }
.hp-map iframe { width: 100%; height: 100%; border: 0; display: block; }

/* ---------- Formulaire ---------- */
.hp-form p { margin: 0 0 1.1rem; }
.hp-form label { display: block; font-size: .85rem; font-weight: 600; margin-bottom: 6px; color: var(--ink); }
.hp-form input[type="text"], .hp-form input[type="email"], .hp-form input[type="tel"], .hp-form select, .hp-form textarea {
	width: 100%; font: inherit; color: var(--ink); background: #fff; border: 1px solid #cfc8b6; border-radius: 6px; padding: 12px 14px; transition: border-color .2s, box-shadow .2s;
}
.hp-form textarea { resize: vertical; min-height: 140px; }
.hp-form input:focus, .hp-form select:focus, .hp-form textarea:focus { outline: none; border-color: var(--navy); box-shadow: 0 0 0 3px rgba(30, 47, 99, .15); }
.hp-form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 20px; }
@media (max-width: 600px) { .hp-form-grid { grid-template-columns: 1fr; } }
.hp-form-trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.hp-form-legal { font-size: .85rem; color: var(--muted); }
.hp-form-notice { border-radius: 8px; padding: 16px 20px; margin-bottom: 1.5rem; border: 1px solid; }
.hp-form-notice ul { margin: .5em 0 0; }
.hp-form-notice.is-success { background: #eef6ef; border-color: #b8d6bd; color: #1f4a29; }
.hp-form-notice.is-error { background: #fbeeee; border-color: #e5b9b9; color: #6b1f1f; }

/* ---------- Pied de page ---------- */
.site-footer { background: var(--navy-dark); color: #d5daea; margin-top: 0; }
.footer-grid { max-width: var(--wrap); margin: 0 auto; padding: clamp(48px, 6vw, 80px) var(--gutter) 40px; display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: clamp(28px, 5vw, 72px); }
.footer-brand img { display: block; margin-bottom: 18px; opacity: .95; }
.footer-name { font-family: var(--serif); font-size: 1.9rem; font-weight: 700; color: #fff; margin: 0 0 .3rem; line-height: 1.1; }
.footer-tag { margin: 0 0 1rem; color: #aab3d0; font-size: .95rem; line-height: 1.5; }
.footer-force { font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; color: #c9b48c; margin: 0; }
.footer-title { font-family: var(--sans); font-size: .72rem; letter-spacing: .18em; text-transform: uppercase; font-weight: 600; color: #c9b48c; margin: 0 0 1.1rem; }
.site-footer address { font-style: normal; line-height: 1.6; margin-bottom: .9rem; }
.footer-list { list-style: none; margin: 0; padding: 0; }
.footer-list li { margin-bottom: .5rem; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; text-underline-offset: 4px; }
.site-footer .muted { color: #8f99bb; font-size: .85rem; }
.footer-social { margin-top: 1rem; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.12); max-width: var(--wrap); margin: 0 auto; padding: 22px var(--gutter) 28px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; font-size: .85rem; color: #8f99bb; }
.footer-bottom p { margin: 0; }
@media (max-width: 800px) { .footer-grid { grid-template-columns: 1fr; } }

/* ---------- Divers ---------- */
.hp-simple { max-width: var(--prose); margin: 0 auto; padding: clamp(48px, 8vw, 110px) var(--gutter); }
.hp-404 { text-align: center; }
.hp-404 .kicker { justify-content: center; }

/* ---------- Lightbox ---------- */
.hp-lightbox {
	position: fixed; inset: 0; z-index: 1000; display: none; align-items: center; justify-content: center; padding: 24px;
	background: rgba(12, 17, 38, .94);
}
.hp-lightbox.is-open { display: flex; }
.hp-lightbox figure { margin: 0; max-width: min(1100px, 100%); max-height: 100%; display: flex; flex-direction: column; align-items: center; }
.hp-lightbox img { max-width: 100%; max-height: calc(100vh - 120px); width: auto; height: auto; border-radius: 4px; box-shadow: 0 20px 60px rgba(0,0,0,.5); background: #fff0; }
.hp-lightbox figcaption { color: #dfe3f2; text-align: center; margin-top: 14px; font-size: .95rem; }
.hp-lightbox button {
	position: absolute; background: rgba(255,255,255,.1); color: #fff; border: 0; width: 46px; height: 46px; border-radius: 50%; cursor: pointer; font-size: 1.4rem; line-height: 1;
	display: flex; align-items: center; justify-content: center; transition: background .2s;
}
.hp-lightbox button:hover { background: rgba(255,255,255,.22); }
.hp-lightbox .lb-close { top: 18px; right: 18px; }
.hp-lightbox .lb-prev { left: 18px; top: 50%; margin-top: -23px; }
.hp-lightbox .lb-next { right: 18px; top: 50%; margin-top: -23px; }
@media (max-width: 640px) { .hp-lightbox .lb-prev, .hp-lightbox .lb-next { top: auto; bottom: 18px; margin: 0; } }

/* ---------- Apparition douce au défilement ---------- */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s ease; }
.js .reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
	.js .reveal { opacity: 1; transform: none; transition: none; }
	.hero-slide { transition: none; }
	* { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* ---------- Contenus intégrés (vidéos, carte) : chargés au clic ---------- */
.wp-block-column[style*="flex-basis"] { flex-grow: 0; }
.hp-embed { position: relative; background: #0f1530 var(--poster, none) center 22% / cover no-repeat; }
.hp-embed.hp-map { background-color: var(--sand); }
.hp-embed-play {
	position: absolute; inset: 0; width: 100%; height: 100%; border: 0; padding: 0; cursor: pointer; background: linear-gradient(to top, rgba(12,17,38,.62), rgba(12,17,38,.08) 60%);
	display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; color: #fff; font: inherit;
}
.hp-embed-play .ico {
	width: 72px; height: 72px; border-radius: 50%; background: rgba(255,255,255,.95); display: grid; place-items: center; transition: transform .25s, background .25s;
	box-shadow: 0 8px 30px rgba(0,0,0,.3);
}
.hp-embed-play .ico::before { content: ""; margin-left: 5px; border-style: solid; border-width: 11px 0 11px 18px; border-color: transparent transparent transparent var(--navy); }
.hp-embed-play:hover .ico { transform: scale(1.07); }
.hp-embed-play .txt { font-size: .95rem; font-weight: 500; text-shadow: 0 1px 8px rgba(0,0,0,.5); padding: 0 16px; text-align: center; }
.hp-embed-play small { display: block; font-size: .78rem; opacity: .85; font-weight: 400; margin-top: 2px; }
.hp-map .hp-embed-play { background: none; color: var(--navy-dark); }
.hp-map .hp-embed-play .ico { background: var(--navy); }
.hp-map .hp-embed-play .ico::before { width: 16px; height: 16px; margin: -4px 0 0; border: 0; border-radius: 50% 50% 50% 0; background: #fff; transform: rotate(-45deg); }
.hp-map .hp-embed-play .ico::after { content: ""; position: absolute; width: 6px; height: 6px; border-radius: 50%; background: var(--navy); margin-top: -4px; }
.hp-map .hp-embed-play .ico { position: relative; }
.hp-map .hp-embed-play .txt { text-shadow: none; }
.hp-embed-fallback { position: absolute; left: 16px; bottom: 12px; z-index: 1; color: #fff; font-size: .85rem; }
.hp-embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.js .hp-embed-fallback { display: none; }

/* ---------- Arbre généalogique ---------- */
.hp-tree { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); grid-template-rows: repeat(2, auto); gap: 10px; max-width: 760px; }
.hp-tree > div { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 16px 18px; display: flex; flex-direction: column; justify-content: center; }
.hp-tree strong { font-family: var(--serif); font-size: 1.45rem; line-height: 1.1; color: var(--navy-dark); font-weight: 600; }
.hp-tree span { font-size: .84rem; color: var(--muted); margin-top: 3px; }
.hp-tree .t1 { grid-column: 1; grid-row: 1 / 3; background: var(--navy); border-color: var(--navy); }
.hp-tree .t1 strong { color: #fff; font-size: 2rem; }
.hp-tree .t1 span { color: #c9d1ee; }
.hp-tree .t2.a { grid-column: 2; grid-row: 1; } .hp-tree .t2.b { grid-column: 2; grid-row: 2; }
.hp-tree .t3.a { grid-column: 3; grid-row: 1; } .hp-tree .t3.b { grid-column: 3; grid-row: 2; }
@media (max-width: 560px) { .hp-tree { grid-template-columns: 1fr; } .hp-tree > div { grid-column: 1 !important; grid-row: auto !important; } }

/* ---------- Vignettes supplémentaires d'une fiche cheval ---------- */
.hp-thumbs { display: grid; gap: 8px; margin: -6px 0 16px; }
.hp-thumbs--1 { grid-template-columns: minmax(0, 50%); }
.hp-thumbs--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.hp-thumbs--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.hp-thumbs .wp-block-image { margin: 0; }
.hp-thumbs img { width: 100% !important; aspect-ratio: 4 / 3; object-fit: cover; height: auto; box-shadow: none; border-radius: 4px; }
.hp-cards--two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 560px) { .hp-cards--two { grid-template-columns: 1fr; } }

/* Barre d'administration WordPress (visible quand on est connecté) */
.admin-bar .site-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .site-header { top: 46px; } }
@media (max-width: 600px) { .admin-bar .site-header { top: 0; } }
@media (max-width: 1240px) { .admin-bar .primary-nav { padding-top: calc(var(--header-h) + 12px + 32px); } }
@media (max-width: 600px) { .admin-bar .primary-nav { padding-top: calc(var(--header-h) + 12px); } }
