/* GrupENOIA · Portfolio de proyectos (v1.1)
 * Sigue el sistema visual de la home y las fichas: hero fotográfico con velo
 * negro, titulares DM Sans en mayúsculas, secciones crema / negro, tarjetas con
 * píldora granate y botón negro. CSS acotado a .enp-* para no afectar a otras páginas.
 * Colores y fuentes salen de los globales de Elementor (kit 7). */

.enp-page,
.enp,
.enp-back {
	--enp-primary: var(--e-global-color-primary, #742307);
	--enp-cream: var(--e-global-color-secondary, #FBF9F6);
	--enp-text: var(--e-global-color-text, #1A1A1A);
	--enp-muted: var(--e-global-color-accent, #666666);
	--enp-dark: #1A1A1A; /* fondo de las franjas oscuras del sitio (= color de texto global) */
	--enp-head: var(--e-global-typography-primary-font-family, "DM Sans"), sans-serif;
	--enp-body: var(--e-global-typography-text-font-family, "Montserrat"), sans-serif;
	--enp-max: 1140px;
	--enp-gutter: clamp(20px, 4vw, 40px);
	--enp-section: clamp(64px, 8vw, 100px);
	font-family: var(--enp-body);
	color: var(--enp-text);
}

.enp-page { background: var(--enp-cream); overflow-x: clip; }
.enp-page *, .enp * { box-sizing: border-box; }
.enp-page h1, .enp-page h2, .enp-page h3, .enp h3 { font-family: var(--enp-head); font-weight: 600; margin: 0; }
.enp-page p { margin: 0; }

/* Contenedor común */
.enp-page > .enp-intro,
.enp-page > .enp-projects,
.enp-page .enp-cta {
	width: 100%;
	max-width: calc(var(--enp-max) + 2 * var(--enp-gutter));
	margin-left: auto;
	margin-right: auto;
	padding-left: var(--enp-gutter);
	padding-right: var(--enp-gutter);
}

/* Títulos de sección: mismo patrón que la home
   (antetítulo granate 32px + subtítulo oscuro 28px, centrados) */
.enp-page .enp-kicker {
	font-family: var(--enp-head);
	font-size: 32px;
	font-weight: 600;
	line-height: 1.1;
	color: var(--enp-primary);
	text-align: center;
	text-transform: uppercase;
	margin-bottom: 14px;
}
.enp-page .enp-intro h2,
.enp-page .enp-projects h2 {
	font-size: 28px;
	line-height: 1.2;
	color: var(--enp-text);
	text-align: center;
}

/* ---------- A. Hero fotográfico ---------- */
.enp-page .enp-hero.wp-block-cover {
	min-height: 620px;
	padding: 96px var(--enp-gutter);
	margin: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	text-align: center;
}
.enp-page .enp-hero .wp-block-cover__background { background-color: #000 !important; opacity: .65 !important; }
.enp-page .enp-hero .wp-block-cover__inner-container {
	max-width: 900px;
	width: 100%;
	color: var(--enp-cream);
}
.enp-page .enp-hero .enp-eyebrow {
	font-family: var(--enp-head);
	font-size: 18px;
	font-weight: 600;
	letter-spacing: .04em;
	text-transform: uppercase;
	color: var(--enp-cream);
	margin-bottom: 16px;
}
.enp-page .enp-hero h1 {
	font-size: clamp(36px, 4.6vw, 66px);
	line-height: 1.05;
	text-transform: uppercase;
	color: var(--enp-cream);
}
.enp-page .enp-hero .enp-sub {
	font-family: var(--enp-head);
	font-size: clamp(22px, 2vw, 28px);
	font-weight: 600;
	color: var(--enp-cream);
	margin-top: 18px;
}
.enp-page .enp-hero .enp-lead {
	font-size: 16px;
	line-height: 1.7;
	color: var(--enp-cream);
	max-width: 760px;
	margin: 18px auto 0;
}
.enp-page .enp-hero .wp-block-buttons { justify-content: center; margin-top: 28px; }

/* Botones de la página (mismo estilo que la home: Montserrat 15/500, radio 3px) */
.enp-page .wp-block-button__link {
	display: inline-block;
	padding: 12px 24px;
	border-radius: 3px;
	font-family: var(--enp-body);
	font-size: 15px;
	font-weight: 500;
	line-height: 1.4;
	text-decoration: none;
	background: var(--enp-primary);
	color: var(--enp-cream);
	border: 1px solid var(--enp-primary);
	transition: background .2s ease, color .2s ease, border-color .2s ease;
}
.enp-page .wp-block-button__link:hover { background: var(--enp-dark); border-color: var(--enp-dark); color: #fff; }
.enp-page .is-style-outline .wp-block-button__link { background: transparent; color: #fff; border-color: #fff; }
.enp-page .is-style-outline .wp-block-button__link:hover { background: #fff; color: var(--enp-dark); }
.enp-page .wp-block-button__link:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; }

/* ---------- B. Introducción ---------- */
.enp-page > .enp-intro {
	padding-top: var(--enp-section);
	padding-bottom: 24px;
	text-align: center;
}
.enp-page .enp-intro .enp-intro-text {
	max-width: 820px;
	margin: 20px auto 0;
	font-size: 15px;
	line-height: 1.7;
	color: var(--enp-text);
}

/* ---------- C. Listado ---------- */
.enp-page > .enp-projects {
	padding-top: clamp(40px, 5vw, 64px);
	padding-bottom: var(--enp-section);
	scroll-margin-top: 100px;
}

.enp-filters {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 10px;
	margin: 28px 0 40px;
}
.enp-filter {
	appearance: none;
	border: 1px solid var(--enp-text);
	border-radius: 20px;
	background: transparent;
	color: var(--enp-text);
	padding: 9px 18px;
	min-height: 44px;
	font-family: var(--enp-body);
	font-size: 14px;
	font-weight: 500;
	line-height: 1.2;
	text-transform: uppercase;
	cursor: pointer;
	transition: background .2s ease, color .2s ease, border-color .2s ease;
}
.enp-filter .enp-count { font-weight: 400; opacity: .75; margin-left: 4px; }
.enp-filter:hover:not(:disabled) { background: var(--enp-text); color: #fff; }
.enp-filter.is-active,
.enp-filter.is-active:hover { background: var(--enp-primary); border-color: var(--enp-primary); color: var(--enp-cream); }
.enp-filter:disabled { opacity: .35; cursor: default; }
.enp-filter:focus-visible { outline: 2px solid var(--enp-primary); outline-offset: 3px; }

.enp-list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 32px;
	align-items: stretch;
}
.enp-item { margin: 0; padding: 0; min-width: 0; display: flex; }
.enp-item[hidden] { display: none; }
.enp-item::before, .enp-item::marker { content: none; }

/* Tarjeta: réplica del patrón de la home */
.enp-card {
	display: flex;
	flex-direction: column;
	width: 100%;
	padding: 10px 10px 24px;
	border-radius: 4px;
	box-shadow: 8px 0 24px rgba(0, 0, 0, .4);
	background: transparent;
}
.enp-pill {
	margin: 0 0 10px;
	padding: 6px 14px;
	border-radius: 20px;
	background: var(--enp-primary);
	color: var(--enp-cream);
	font-family: var(--enp-head);
	font-size: 20px;
	font-weight: 600;
	line-height: 1.2;
	text-transform: uppercase;
}
.enp-media {
	position: relative;
	display: block;
	aspect-ratio: 4 / 3;
	overflow: hidden;
	background: #ECE7E0;
}
.enp-img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform .6s ease;
}
.enp-img--empty { position: absolute; inset: 0; }
.enp-card:hover .enp-img { transform: scale(1.03); }
.is-vendido .enp-img { filter: saturate(.6); }

.enp-badge {
	position: absolute;
	top: 12px;
	right: 12px;
	display: inline-flex;
	align-items: center;
	gap: 7px;
	padding: 6px 12px;
	border-radius: 20px;
	background: var(--enp-cream);
	color: var(--enp-text);
	font-family: var(--enp-body);
	font-size: 12px;
	font-weight: 600;
	line-height: 1;
	text-transform: uppercase;
}
.enp-badge::before {
	content: "";
	width: 8px; height: 8px;
	border-radius: 50%;
	background: var(--enp-primary);
}
.enp-badge--en-proceso::before { background: transparent; box-shadow: inset 0 0 0 1.5px var(--enp-primary); }
.enp-badge--vendido { background: var(--enp-text); color: #fff; }
.enp-badge--vendido::before { background: #fff; }

.enp-body {
	display: flex;
	flex-direction: column;
	flex: 1;
	padding: 18px 8px 0;
}
.enp-body > :nth-last-child(2) { margin-bottom: 22px; }
.enp-title {
	font-size: 24px;
	font-weight: 700;
	line-height: 1.15;
	text-transform: uppercase;
}
.enp-title a { color: var(--enp-primary); text-decoration: none; }
.enp-title a:hover { text-decoration: underline; text-underline-offset: 4px; }
.enp-sum {
	margin: 12px 0 0;
	font-size: 15px;
	line-height: 1.7;
	color: var(--enp-text);
}
.enp-btn {
	align-self: flex-start;
	margin-top: auto;
	display: inline-block;
	padding: 12px 24px;
	border-radius: 3px;
	background: var(--enp-text);
	color: #fff;
	font-family: var(--enp-body);
	font-size: 15px;
	font-weight: 500;
	text-transform: uppercase;
	text-decoration: none;
	transition: background .2s ease;
}
.enp-btn:hover, .enp-btn:focus { background: var(--enp-primary); color: #fff; }
.enp-btn:focus-visible { outline: 2px solid var(--enp-primary); outline-offset: 3px; }

.enp-empty { text-align: center; font-size: 16px; color: var(--enp-muted); }

/* ---------- E. CTA de cierre (franja negra como en el resto del sitio) ---------- */
.enp-page .enp-cta-wrap {
	background: var(--enp-dark);
	color: var(--enp-cream);
	padding-top: var(--enp-section);
	padding-bottom: var(--enp-section);
	margin: 0;
}
.enp-page .enp-cta { text-align: center; }
.enp-page .enp-cta h2 {
	font-size: 32px;
	line-height: 1.15;
	text-transform: uppercase;
	color: var(--enp-cream);
}
.enp-page .enp-cta .enp-cta-text {
	max-width: 720px;
	margin: 18px auto 0;
	font-size: 16px;
	line-height: 1.7;
	color: var(--enp-cream);
}
.enp-page .enp-cta .wp-block-buttons {
	justify-content: center;
	flex-wrap: wrap;
	gap: 12px;
	margin-top: 28px;
}

/* ---------- Enlace de retorno en las fichas ---------- */
.enp-back {
	max-width: 1024px;
	margin: 0 auto;
	padding: 40px 20px 56px;
	font-family: var(--enp-body);
}
.enp-back a {
	color: var(--enp-primary);
	font-size: 15px;
	font-weight: 500;
	text-decoration: none;
	border-bottom: 1px solid currentColor;
	padding-bottom: 2px;
}
.enp-back a:focus-visible { outline: 2px solid var(--enp-primary); outline-offset: 4px; }

.enp .screen-reader-text,
.enp .enp-state-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;
}

/* ---------- Tablet (breakpoint Elementor ≤ 1024) ---------- */
@media (max-width: 1024px) {
	.enp-page .enp-hero.wp-block-cover { min-height: 540px; }
	.enp-list { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px; }
}

/* ---------- Móvil (breakpoint Elementor ≤ 767) ---------- */
@media (max-width: 767px) {
	.enp-page .enp-hero.wp-block-cover { min-height: 520px; padding-top: 72px; padding-bottom: 72px; }
	.enp-page .enp-hero .enp-eyebrow { font-size: 15px; }
	.enp-page .enp-hero .enp-lead { font-size: 15px; }
	.enp-page .enp-kicker { font-size: 26px; }
	.enp-page .enp-intro h2, .enp-page .enp-projects h2 { font-size: 22px; }
	.enp-page .enp-cta h2 { font-size: 26px; }

	.enp-filters { gap: 8px; }
	.enp-filter { font-size: 13px; padding: 8px 14px; }

	.enp-list { grid-template-columns: 1fr; gap: 32px; }
	.enp-pill { font-size: 18px; }
	.enp-title { font-size: 22px; }

	.enp-page .wp-block-buttons { flex-direction: column; align-items: stretch; }
	.enp-page .wp-block-button, .enp-page .wp-block-button__link { width: 100%; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
	.enp-img, .enp-filter, .enp-btn { transition: none; }
	.enp-card:hover .enp-img { transform: none; }
}
