/* ============================================================================
   FM PROYECTOS 2026 — /proyectos/ con diseño editorial (borrador del 22-oct-2026).
   Solo se encola en páginas con la meta _fm_proyectos_2026 = 1 (functions.php) y todo va bajo
   body.fm-proy-2026: no afecta a ninguna otra página.
   Tokens: los --fm-* de la cabecera 2026 (fm-header-2026.css, global). Tipografía: Inter local
   (solo hay peso 400: las «mayúsculas finas» son 400 con tracking amplio).
   ============================================================================ */
body.fm-proy-2026 {
	--fm-p-ancho: 1280px;
	--fm-p-margen: clamp(20px, 5vw, 72px);
	--fm-p-lenta: 1200ms;
	--fm-p-media: 500ms;
}
@media (prefers-reduced-motion: reduce) {
	body.fm-proy-2026 { --fm-p-lenta: 0ms; --fm-p-media: 0ms; }
}
body.fm-proy-2026 .fm-p { font-family: 'Inter', Helvetica, Arial, sans-serif; color: var(--fm-texto); }
body.fm-proy-2026 .fm-p .et_pb_row { width: auto !important; max-width: var(--fm-p-ancho) !important; padding: 0 !important; margin: 0 var(--fm-p-margen) !important; }
@media (min-width: 1424px) { body.fm-proy-2026 .fm-p .et_pb_row { margin: 0 auto !important; } }
body.fm-proy-2026 .fm-p .et_pb_column { margin-bottom: 0 !important; }
body.fm-proy-2026 .fm-p h1,
body.fm-proy-2026 .fm-p h2,
body.fm-proy-2026 .fm-p h3 { font-family: 'Inter', Helvetica, Arial, sans-serif !important; font-weight: 400 !important; padding: 0 !important; }
body.fm-proy-2026 .fm-p p { padding: 0 !important; }
body.fm-proy-2026 .fm-p-eyebrow {
	font-size: 11px; font-weight: 500; line-height: 1.5; letter-spacing: 3px; text-transform: uppercase;
	color: var(--fm-tierra-texto); margin: 0 0 18px !important;
}
/* Enlace «Ver proyecto»: texto en mayúsculas con línea fina que se alarga */
body.fm-proy-2026 .fm-p-ver {
	display: inline-block; padding: 6px 0 8px; font-size: 12px; font-weight: 500; letter-spacing: 2px; text-transform: uppercase;
	color: var(--fm-texto) !important; text-decoration: none;
	background: linear-gradient(var(--fm-tierra), var(--fm-tierra)) left bottom / 32px 1px no-repeat;
	transition: background-size var(--fm-p-media) ease;
}
body.fm-proy-2026 .fm-p-ver:hover,
body.fm-proy-2026 .fm-p-ver:focus-visible { background-size: 100% 1px; }
body.fm-proy-2026 .fm-p a:focus-visible { outline: 2px solid var(--fm-tierra); outline-offset: 3px; }
body.fm-proy-2026 .fm-p-sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }

/* ---------- 1. Hero a sangre ---------- */
body.fm-proy-2026 .fm-p-hero.et_pb_section {
	position: relative; display: flex !important; flex-direction: column; justify-content: flex-end;
	min-height: 100vh !important; min-height: 100svh !important; padding: calc(var(--fm-h-alto, 112px) + 40px) 0 clamp(48px, 9vh, 104px) !important;
	background-size: cover !important; background-position: center !important; background-color: #2a2622;
}
/* Degradado sutil: abajo y a la izquierda (donde va el texto); arriba lo justo para la cabecera transparente */
body.fm-proy-2026 .fm-p-hero.et_pb_section::before {
	content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 0;
	background:
		linear-gradient(to top, rgba(20, 17, 14, .80) 0%, rgba(20, 17, 14, .55) 40%, rgba(20, 17, 14, .12) 70%, rgba(20, 17, 14, .30) 100%),
		linear-gradient(to right, rgba(20, 17, 14, .45) 0%, rgba(20, 17, 14, 0) 60%);
	/* contraste medido sobre los píxeles de la foto: eyebrow de 11 px ≥ 5,2:1 y H1 ≥ 7,3:1 en el peor punto */
}
body.fm-proy-2026 .fm-p-hero .et_pb_row { position: relative; z-index: 1; }
body.fm-proy-2026 .fm-p-hero__txt { max-width: 760px; color: #fff; }
body.fm-proy-2026 .fm-p-hero .fm-p-eyebrow { color: #fff; opacity: .92; }
body.fm-proy-2026 .fm-p-hero h1 {
	font-size: clamp(40px, 6.2vw, 92px) !important; line-height: 1.02 !important; letter-spacing: .06em; text-transform: uppercase;
	color: #fff !important; margin: 0 0 24px !important;
}
body.fm-proy-2026 .fm-p-hero__entrada { max-width: 520px; font-size: 17px; line-height: 1.6; color: #fff; margin: 0 !important; }
@media (max-width: 767px) {
	body.fm-proy-2026 .fm-p-hero.et_pb_section { min-height: 75vh !important; min-height: 75svh !important; padding-bottom: 40px !important; }
	body.fm-proy-2026 .fm-p-hero h1 { font-size: clamp(34px, 10.5vw, 48px) !important; letter-spacing: .04em; }
	body.fm-proy-2026 .fm-p-hero__entrada { font-size: 15.5px; }
}

/* ---------- 2. Introducción ---------- */
body.fm-proy-2026 .fm-p-intro.et_pb_section { padding: clamp(80px, 12vw, 160px) 0 clamp(64px, 9vw, 120px) !important; background: #fff; }
body.fm-proy-2026 .fm-p-intro__in { max-width: 640px; margin: 0 auto; text-align: center; }
body.fm-proy-2026 .fm-p-intro h2 { font-size: clamp(28px, 3vw, 40px) !important; line-height: 1.2 !important; color: var(--fm-texto) !important; margin: 0 0 48px !important; }
body.fm-proy-2026 .fm-p-intro__lista { list-style: none !important; margin: 0; padding: 0 !important; text-align: left; border-top: 1px solid var(--fm-greige); }
body.fm-proy-2026 .fm-p-intro__lista li { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 8px 32px; padding: 22px 0 !important; border-bottom: 1px solid var(--fm-greige); }
body.fm-proy-2026 .fm-p-intro__lista h3 { font-size: 12px !important; font-weight: 500 !important; line-height: 1.7 !important; letter-spacing: 2px; text-transform: uppercase; color: var(--fm-tierra-texto) !important; margin: 0 !important; }
body.fm-proy-2026 .fm-p-intro__lista p { font-size: 16px; line-height: 1.7; color: var(--fm-texto); margin: 0 !important; }
@media (max-width: 600px) { body.fm-proy-2026 .fm-p-intro__lista li { grid-template-columns: minmax(0, 1fr); } }

/* ---------- 3. Proyectos destacados: bloques editoriales alternos (foto 7/12, texto 5/12) ---------- */
body.fm-proy-2026 .fm-p-dest.et_pb_section { padding: 0 0 clamp(64px, 9vw, 128px) !important; background: #fff; }
body.fm-proy-2026 .fm-p-dest__cab { margin-bottom: clamp(40px, 6vw, 72px); }
body.fm-proy-2026 .fm-p-dest__cab h2 { font-size: clamp(28px, 3vw, 40px) !important; line-height: 1.2 !important; color: var(--fm-texto) !important; margin: 0 !important; }
body.fm-proy-2026 .fm-p-bloque { margin: 0 0 clamp(64px, 9vw, 128px) !important; }
body.fm-proy-2026 .fm-p-bloque:last-child { margin-bottom: 0 !important; }
body.fm-proy-2026 .fm-p-bloque__in { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(32px, 5vw, 80px); align-items: center; }
body.fm-proy-2026 .fm-p-bloque--inv .fm-p-bloque__in { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); }
body.fm-proy-2026 .fm-p-bloque--inv .fm-p-bloque__foto { order: 2; }
body.fm-proy-2026 .fm-p-bloque__foto { position: relative; overflow: hidden; aspect-ratio: 4 / 3; background: var(--fm-arena); margin: 0; }
body.fm-proy-2026 .fm-p-bloque__foto img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transform: scale(1); transition: transform var(--fm-p-lenta) ease; }
body.fm-proy-2026 .fm-p-bloque:hover .fm-p-bloque__foto img,
body.fm-proy-2026 .fm-p-bloque:focus-within .fm-p-bloque__foto img { transform: scale(1.04); }
body.fm-proy-2026 .fm-p-bloque__n { display: block; font-size: 13px; letter-spacing: 3px; color: var(--fm-tierra-texto); margin: 0 0 20px; }
body.fm-proy-2026 .fm-p-bloque h3 {
	font-size: clamp(30px, 3.4vw, 52px) !important; line-height: 1.08 !important; letter-spacing: .08em; text-transform: uppercase;
	color: var(--fm-texto) !important; margin: 0 0 16px !important;
}
body.fm-proy-2026 .fm-p-bloque__meta { font-size: 12px; letter-spacing: 2px; text-transform: uppercase; color: var(--fm-tierra-texto); margin: 0 0 20px !important; }
body.fm-proy-2026 .fm-p-bloque__txt { font-size: 16px; line-height: 1.75; color: var(--fm-texto); margin: 0 0 28px !important; max-width: 46ch; }
@media (max-width: 980px) {
	body.fm-proy-2026 .fm-p-bloque__in,
	body.fm-proy-2026 .fm-p-bloque--inv .fm-p-bloque__in { grid-template-columns: minmax(0, 1fr); gap: 28px; }
	body.fm-proy-2026 .fm-p-bloque--inv .fm-p-bloque__foto { order: 0; }
}

/* ---------- 4. Todos los proyectos: rejilla de 2 columnas (una ficha = un módulo de texto de Divi) ---------- */
body.fm-proy-2026 .fm-p-todos.et_pb_section { padding: clamp(64px, 9vw, 128px) 0 !important; background: var(--fm-arena); }
body.fm-proy-2026 .fm-p-todos__cab { margin-bottom: clamp(36px, 5vw, 64px); }
body.fm-proy-2026 .fm-p-todos__cab h2 { font-size: clamp(28px, 3vw, 40px) !important; line-height: 1.2 !important; color: var(--fm-texto) !important; margin: 0 !important; }
body.fm-proy-2026 .fm-p-rejilla.et_pb_column { display: grid !important; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(40px, 5vw, 72px) clamp(20px, 3vw, 40px); float: none; width: 100% !important; }
body.fm-proy-2026 .fm-p-rejilla::after { display: none !important; }
body.fm-proy-2026 .fm-p-ficha { margin: 0 !important; }
body.fm-proy-2026 .fm-p-ficha__in { position: relative; }
body.fm-proy-2026 .fm-p-ficha__img { position: relative; display: block; overflow: hidden; aspect-ratio: 3 / 2; background: var(--fm-greige); }
body.fm-proy-2026 .fm-p-ficha__img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transform: scale(1); transition: transform var(--fm-p-lenta) ease; }
body.fm-proy-2026 .fm-p-ficha__in:hover .fm-p-ficha__img img,
body.fm-proy-2026 .fm-p-ficha__in:focus-within .fm-p-ficha__img img { transform: scale(1.05); }
body.fm-proy-2026 .fm-p-ficha h3 { font-size: 20px !important; line-height: 1.3 !important; letter-spacing: .1em; text-transform: uppercase; color: var(--fm-texto) !important; margin: 22px 0 6px !important; }
/* Un solo enlace por ficha (en el H3) estirado sobre toda la ficha; el foco se dibuja alrededor de la ficha */
body.fm-proy-2026 .fm-p-ficha h3 a { color: inherit !important; text-decoration: none; }
body.fm-proy-2026 .fm-p-ficha h3 a::after { content: ""; position: absolute; inset: 0; z-index: 1; }
body.fm-proy-2026 .fm-p-ficha h3 a:focus-visible { outline: none; }
body.fm-proy-2026 .fm-p-ficha h3 a:focus-visible::after { outline: 2px solid var(--fm-tierra); outline-offset: 6px; }
body.fm-proy-2026 .fm-p-ficha .fm-p-ver { pointer-events: none; }
body.fm-proy-2026 .fm-p-ficha__in:hover .fm-p-ver,
body.fm-proy-2026 .fm-p-ficha__in:focus-within .fm-p-ver { background-size: 100% 1px; }
@media (max-width: 767px) { body.fm-proy-2026 .fm-p-rejilla.et_pb_column { grid-template-columns: minmax(0, 1fr); } }

/* ---------- 5. Franja de cifras ---------- */
body.fm-proy-2026 .fm-p-cifras.et_pb_section { padding: clamp(56px, 7vw, 96px) 0 !important; background: var(--fm-fondo-cabecera) !important; }
body.fm-proy-2026 .fm-p-cifras__lista { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px; list-style: none !important; margin: 0; padding: 0 !important; text-align: center; }
body.fm-proy-2026 .fm-p-cifras__lista li { padding: 0 !important; }
body.fm-proy-2026 .fm-p-cifra { display: block; font-size: clamp(30px, 3.4vw, 52px); line-height: 1.05; letter-spacing: .02em; color: var(--fm-texto); white-space: nowrap; }
body.fm-proy-2026 .fm-p-cifra__t { display: block; margin-top: 12px; font-size: 12px; letter-spacing: 2px; text-transform: uppercase; color: var(--fm-tierra-texto); }
@media (max-width: 980px) { body.fm-proy-2026 .fm-p-cifras__lista { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 44px; } }
@media (max-width: 400px) { body.fm-proy-2026 .fm-p-cifras__lista { column-gap: 12px; } body.fm-proy-2026 .fm-p-cifra { font-size: 26px; } }

/* ---------- 6. Cierre ---------- */
body.fm-proy-2026 .fm-p-cierre.et_pb_section { padding: clamp(80px, 11vw, 150px) 0 !important; background: #fff; text-align: center; }
body.fm-proy-2026 .fm-p-cierre__in { max-width: 640px; margin: 0 auto; }
body.fm-proy-2026 .fm-p-cierre h2 { font-size: clamp(30px, 3.6vw, 48px) !important; line-height: 1.15 !important; color: var(--fm-texto) !important; margin: 0 0 22px !important; }
body.fm-proy-2026 .fm-p-cierre p { font-size: 16px; line-height: 1.7; margin: 0 0 36px !important; }
body.fm-proy-2026 .fm-p-botones { display: flex; flex-wrap: wrap; justify-content: center; gap: 16px; }
/* CTA de borde (mismo estilo que «Ver catálogo» de los departamentos) */
body.fm-proy-2026 .fm-p-cta {
	display: inline-block; min-width: 180px; padding: 14px 28px; font-size: 12px; font-weight: 500; line-height: 1.4; letter-spacing: 2px; text-transform: uppercase;
	color: var(--fm-texto) !important; text-decoration: none; border: 1px solid var(--fm-tierra); background: transparent; transition: background-color var(--fm-p-media) ease;
}
body.fm-proy-2026 .fm-p-cta:hover { background: var(--fm-greige); }
