/*
 * CreceWeb Lumen Pro — context-only front-end layer.
 * Loaded only when the current request resolves a profile that needs an
 * advanced width or a contextual header presentation.
 */

/* Lumen owns header mode. Pro only changes its surface in the resolved context.
 *
 * A transparent profile is a true overlay: the hero must be visible without a
 * tinted surface, backdrop blur or inherited header opacity. The stronger
 * selector keeps late Customizer or block styles from turning the initial
 * state into a semi-transparent version of Lumen's solid header. */
body.cw-lumen-pro-header-transparent .cw-site-header.cw-lumen-pro-header--transparent {
	/* The solid-to-transparent handoff is a state change, not a decorative
	 * fade. A surface transition leaves a visible trail over the first part of
	 * the hero, especially in Fijo al desplazarse. */
	transition: none;
}

body.cw-lumen-pro-header-transparent .cw-site-header.cw-lumen-pro-header--transparent:not(.cw-lumen-pro-header-is-solid) {
	background: transparent !important;
	background-color: transparent !important;
	background-image: none !important;
	border-bottom-color: transparent !important;
	box-shadow: none !important;
	backdrop-filter: none;
	-webkit-backdrop-filter: none;
	opacity: 1;
}

/* Normal mode overlays the initial hero and remains transparent while it scrolls out of view. */
body.cw-lumen-pro-header-transparent.cw-lumen-pro-header-placement--normal .cw-site-header.cw-lumen-pro-header--overlay {
	position: absolute !important;
	top: 0 !important;
	left: 0 !important;
	right: 0 !important;
	width: 100% !important;
	max-width: none;
	margin: 0;
	box-sizing: border-box;
	z-index: 9990;
}

/* The bridge class is deliberately narrow: when the profile has no qualifying
 * hero, the progressive script removes it and the Theme returns the header to
 * the normal solid flow. */
body.cw-lumen-pro-header-transparent.cw-lumen-pro-header-placement--normal .cw-site-header:not(.cw-lumen-pro-header--overlay) {
	position: relative !important;
	top: auto !important;
	left: auto !important;
	right: auto !important;
	width: auto !important;
	max-width: none;
	margin: 0;
	box-sizing: border-box;
	z-index: auto;
}

/* Fijo al desplazarse remains native CSS sticky and keeps its document slot.
 * It starts with Lumen Theme's solid surface; only its visual colors/logo change
 * while the anchored header is genuinely over the Hero. Fijo desde el inicio
 * remains the only mode that overlays the Hero from the first paint. */
body.cw-lumen-pro-controls-header-placement.cw-lumen-pro-header-placement--sticky .cw-site-header,
body.cw-lumen-pro-header-transparent.cw-lumen-pro-header-placement--sticky .cw-site-header {
	position: sticky !important;
	top: 0;
	width: 100%;
	max-width: none;
	margin: 0;
	box-sizing: border-box;
	z-index: 99990;
}
body.cw-lumen-pro-header-transparent.cw-lumen-pro-header-placement--fixed .cw-site-header {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	width: 100%;
	max-width: none;
	margin: 0;
	box-sizing: border-box;
	z-index: 99990;
}

/* Keep the anchored states below the WordPress admin bar while logged in. */
.admin-bar.cw-lumen-pro-header-transparent.cw-lumen-pro-header-placement--normal .cw-site-header,
.admin-bar.cw-lumen-pro-header-transparent.cw-lumen-pro-header-placement--sticky .cw-site-header,
.admin-bar.cw-lumen-pro-header-transparent.cw-lumen-pro-header-placement--fixed .cw-site-header {
	top: 32px !important;
}

/* Once the transparent phase ends, Lumen Theme regains ownership of the
 * solid header. Do not impose a generic background, text color or CTA color
 * here: the global Customizer values must apply in both fixed modes. The
 * explicit Surface and Brand variants below remain intentional profile
 * overrides. */

@media (max-width: 782px) {
	.admin-bar.cw-lumen-pro-header-transparent.cw-lumen-pro-header-placement--normal .cw-site-header,
	.admin-bar.cw-lumen-pro-header-transparent.cw-lumen-pro-header-placement--sticky .cw-site-header,
	.admin-bar.cw-lumen-pro-header-transparent.cw-lumen-pro-header-placement--fixed .cw-site-header {
		top: 46px !important;
	}
}

@media (prefers-reduced-motion: reduce) {
	.cw-site-header.cw-lumen-pro-header--transparent { transition: none; }
}

/* Profile width helpers use Lumen's own width variables. */
body.cw-lumen-pro-width--standard .cw-content-wrap {
	width: min(calc(100% - 2rem), var(--cw-layout-content, 760px));
}


/* A standard reading width needs a wider outer canvas when a sidebar is present.
 * Otherwise the content column collapses to a few hundred pixels. The normal
 * no-sidebar standard width remains unchanged. */
body.cw-lumen-pro-width--standard .cw-screen-layout--left,
body.cw-lumen-pro-width--standard .cw-screen-layout--right {
	width: min(
		calc(100% - 2rem),
		max(
			var(--cw-layout-wide, 1120px),
			calc(var(--cw-layout-content, 760px) + var(--cw-sidebar-width, 320px) + 3rem)
		)
	);
}

body.cw-lumen-pro-width--wide .cw-content-wrap,
body.cw-lumen-pro-width--wide .cw-content-wrap.cw-screen-layout--none {
	width: min(calc(100% - 2rem), var(--cw-layout-wide, 1120px));
}

body.cw-lumen-pro-width--wide .cw-entry--single .cw-single-post,
body.cw-lumen-pro-width--wide .cw-entry--single .entry-header,
body.cw-lumen-pro-width--wide .cw-entry--single .entry-content {
	max-width: none;
}

body.cw-lumen-pro-width--full .cw-content-wrap,
body.cw-lumen-pro-width--full .cw-content-wrap.cw-screen-layout--none {
	width: 100%;
	max-width: none;
}

body.cw-lumen-pro-width--full .cw-entry--single .cw-single-post,
body.cw-lumen-pro-width--full .cw-entry--single .entry-header,
body.cw-lumen-pro-width--full .cw-entry--single .entry-content {
	max-width: none;
}


/* Gutenberg + Lumen: Hero ancho completo.
 * The post-hero canvas does not use .cw-content-wrap, so it needs its own
 * width contract. The adjacent selector deliberately excludes Elementor:
 * Elementor heroes carry .cw-hero-template__hero--elementor and keep the
 * previously validated containment rules unchanged. */
body.cw-lumen-pro-width--standard .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--none {
	width: min(calc(100% - 2rem), var(--cw-layout-content, 760px));
}

body.cw-lumen-pro-width--standard .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--left,
body.cw-lumen-pro-width--standard .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--right {
	width: min(
		calc(100% - 2rem),
		calc(var(--cw-layout-content, 760px) + var(--cw-sidebar-width, 320px) + clamp(1.75rem, 4vw, 4rem))
	);
}

body.cw-lumen-pro-width--wide .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--none {
	width: min(calc(100% - 2rem), var(--cw-layout-wide, 1120px));
}

body.cw-lumen-pro-width--wide .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--left,
body.cw-lumen-pro-width--wide .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--right {
	width: min(
		calc(100% - 2rem),
		calc(var(--cw-layout-wide, 1120px) + var(--cw-sidebar-width, 320px) + clamp(1.75rem, 4vw, 4rem))
	);
}

body.cw-lumen-pro-width--full .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout {
	width: calc(100% - 2rem);
	max-width: none;
}

@media (max-width: 960px) {
	/* Gutenberg Hero only: once Lumen stacks the sidebar, width refers to the
	 * single content column. Elementor is excluded by the adjacent selector. */
	body.cw-lumen-pro-width--standard .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout,
	body.cw-lumen-pro-width--wide .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout {
		width: min(
			calc(100% - var(--cw-tablet-gutter, 32px) - var(--cw-tablet-gutter, 32px)),
			var(--cw-layout-wide, 1120px)
		);
	}

	body.cw-lumen-pro-width--standard .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout {
		width: min(
			calc(100% - var(--cw-tablet-gutter, 32px) - var(--cw-tablet-gutter, 32px)),
			var(--cw-layout-content, 760px)
		);
	}

	body.cw-lumen-pro-width--full .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout {
		width: calc(100% - var(--cw-tablet-gutter, 32px) - var(--cw-tablet-gutter, 32px));
	}

	body.cw-lumen-pro-width--standard .cw-screen-layout--left,
	body.cw-lumen-pro-width--standard .cw-screen-layout--right {
		display: block;
		width: min(calc(100% - var(--cw-tablet-gutter, 32px) - var(--cw-tablet-gutter, 32px)), var(--cw-layout-content, 760px));
	}

	body.cw-lumen-pro-width--wide .cw-content-wrap,
	body.cw-lumen-pro-width--full .cw-content-wrap {
		width: min(calc(100% - var(--cw-tablet-gutter, 32px) - var(--cw-tablet-gutter, 32px)), var(--cw-layout-wide, 1120px));
	}
}

@media (max-width: 782px) {
	.admin-bar.cw-lumen-pro-header-transparent.cw-lumen-pro-controls-sticky .cw-site-header {
		top: 46px;
	}
}

@media (max-width: 781px) {
	body.cw-lumen-pro-width--wide .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout,
	body.cw-lumen-pro-width--full .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout {
		width: calc(100% - var(--cw-mobile-gutter, 16px) - var(--cw-mobile-gutter, 16px));
	}

	body.cw-lumen-pro-width--standard .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout {
		width: min(
			calc(100% - var(--cw-mobile-gutter, 16px) - var(--cw-mobile-gutter, 16px)),
			var(--cw-layout-content, 760px)
		);
	}

	body.cw-lumen-pro-width--wide .cw-content-wrap,
	body.cw-lumen-pro-width--full .cw-content-wrap {
		width: min(calc(100% - var(--cw-mobile-gutter, 16px) - var(--cw-mobile-gutter, 16px)), var(--cw-layout-wide, 1120px));
	}
}

@media (prefers-reduced-motion: reduce) {
	.cw-site-header.cw-lumen-pro-header--transparent,
	.cw-header-behavior--sticky .cw-site-header.cw-lumen-pro-header--smart-sticky {
		transition: none;
	}
}

/* Gutenberg + Hero ancho completo — breakpoint intermedio.
 * Lumen apila las sidebars a 960px para las plantillas generales. En esta
 * plantilla el hero ya está separado del contenido y, entre 841px y 960px,
 * todavía hay canvas suficiente para conservar las dos columnas. Keep this
 * strictly Gutenberg-only so Elementor retains its validated behavior. */
@media (min-width: 841px) and (max-width: 960px) {
	body.cw-lumen-pro-width--standard .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--right,
	body.cw-lumen-pro-width--wide .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--right,
	body.cw-lumen-pro-width--full .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--right {
		display: grid;
		width: calc(100% - 2rem);
		max-width: none;
		grid-template-columns: minmax(0, 1fr) var(--cw-sidebar-width, 320px);
		grid-template-areas: "content sidebar";
		gap: clamp(1.75rem, 4vw, 4rem);
		align-items: start;
	}

	body.cw-lumen-pro-width--standard .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--left,
	body.cw-lumen-pro-width--wide .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--left,
	body.cw-lumen-pro-width--full .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--left {
		display: grid;
		width: calc(100% - 2rem);
		max-width: none;
		grid-template-columns: var(--cw-sidebar-width, 320px) minmax(0, 1fr);
		grid-template-areas: "sidebar content";
		gap: clamp(1.75rem, 4vw, 4rem);
		align-items: start;
	}

	body.cw-lumen-pro-width--standard .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--right > .cw-hero-template__content,
	body.cw-lumen-pro-width--wide .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--right > .cw-hero-template__content,
	body.cw-lumen-pro-width--full .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--right > .cw-hero-template__content {
		grid-column: 1;
		grid-row: 1;
	}

	body.cw-lumen-pro-width--standard .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--right > .cw-sidebar,
	body.cw-lumen-pro-width--wide .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--right > .cw-sidebar,
	body.cw-lumen-pro-width--full .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--right > .cw-sidebar {
		grid-column: 2;
		grid-row: 1;
		align-self: start;
		margin-block-start: 0 !important;
	}

	body.cw-lumen-pro-width--standard .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--left > .cw-hero-template__content,
	body.cw-lumen-pro-width--wide .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--left > .cw-hero-template__content,
	body.cw-lumen-pro-width--full .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--left > .cw-hero-template__content {
		grid-column: 2;
		grid-row: 1;
	}

	body.cw-lumen-pro-width--standard .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--left > .cw-sidebar,
	body.cw-lumen-pro-width--wide .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--left > .cw-sidebar,
	body.cw-lumen-pro-width--full .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout.cw-screen-layout--left > .cw-sidebar {
		grid-column: 1;
		grid-row: 1;
		align-self: start;
		margin-block-start: 0 !important;
	}
}

/* Gutenberg Hero grid from Lumen 1.4.14.
 * Lumen isolates the post-hero grid from .cw-screen-layout. These rules only
 * size its outer canvas; they do not change Elementor or the shared layouts. */
body.cw-lumen-pro-width--standard .cw-hero-template__layout--gutenberg.cw-hero-template__layout--none {
	width: min(calc(100% - 2rem), var(--cw-layout-content, 760px));
}

body.cw-lumen-pro-width--standard .cw-hero-template__layout--gutenberg.cw-hero-template__layout--left,
body.cw-lumen-pro-width--standard .cw-hero-template__layout--gutenberg.cw-hero-template__layout--right {
	width: min(
		calc(100% - 2rem),
		max(
			var(--cw-layout-wide, 1120px),
			calc(var(--cw-layout-content, 760px) + var(--cw-sidebar-width, 320px) + clamp(1.75rem, 4vw, 4rem))
		)
	);
}

body.cw-lumen-pro-width--wide .cw-hero-template__layout--gutenberg.cw-hero-template__layout--none {
	width: min(calc(100% - 2rem), var(--cw-layout-wide, 1120px));
}

body.cw-lumen-pro-width--wide .cw-hero-template__layout--gutenberg.cw-hero-template__layout--left,
body.cw-lumen-pro-width--wide .cw-hero-template__layout--gutenberg.cw-hero-template__layout--right {
	width: min(
		calc(100% - 2rem),
		calc(var(--cw-layout-wide, 1120px) + var(--cw-sidebar-width, 320px) + clamp(1.75rem, 4vw, 4rem))
	);
}

body.cw-lumen-pro-width--full .cw-hero-template__layout--gutenberg {
	width: calc(100% - 2rem);
	max-width: none;
}

@media (max-width: 640px) {
	body.cw-lumen-pro-width--standard .cw-hero-template__layout--gutenberg,
	body.cw-lumen-pro-width--wide .cw-hero-template__layout--gutenberg {
		width: min(
			calc(100% - var(--cw-mobile-gutter, 16px) - var(--cw-mobile-gutter, 16px)),
			var(--cw-layout-wide, 1120px)
		);
	}

	body.cw-lumen-pro-width--full .cw-hero-template__layout--gutenberg {
		width: calc(100% - var(--cw-mobile-gutter, 16px) - var(--cw-mobile-gutter, 16px));
	}
}


/* Profile visibility controls. They only apply when an active profile asks for
 * an explicit hide state; the free theme markup remains untouched. */
body.cw-lumen-pro-title-hidden .cw-template-main :is(.entry-title, .wp-block-post-title) {
	display: none;
}
body.cw-lumen-pro-header-hidden :is(.cw-top-bar-widgets, .cw-site-header) {
	display: none;
}
body.cw-lumen-pro-footer-hidden .cw-site-footer {
	display: none;
}

/* Transparent profiles can keep a white/contrast logo over a hero and return
 * to the standard brand image as soon as the header takes its solid surface.
 * The standard logo alone owns the document-flow geometry. The alternate image
 * is absolutely layered inside that same box, so it never reserves a second
 * row, changes the header height or moves the identity/navigation alignment. */
body.cw-lumen-pro-has-alternate-logo .cw-lumen-pro-logo-link {
	display: block !important;
	position: relative;
	flex: 0 0 auto;
	line-height: 0;
}
body.cw-lumen-pro-has-alternate-logo .cw-lumen-pro-logo-link .cw-lumen-pro-logo-standard {
	display: block !important;
	position: relative;
	z-index: 1;
	transition: none !important;
}
body.cw-lumen-pro-has-alternate-logo .cw-lumen-pro-logo-link .cw-lumen-pro-logo-alternate {
	display: block !important;
	position: absolute !important;
	inset: 0;
	z-index: 2;
	width: 100% !important;
	height: 100% !important;
	max-width: 100% !important;
	object-fit: contain;
	transition: none !important;
}
/* Fallback for installations that have an alternate logo but no standard
 * Custom Logo configured. There is no standard image to define the box there,
 * so the alternate remains in normal flow and remains usable. */
body.cw-lumen-pro-has-alternate-logo .cw-lumen-pro-logo-link--alternate-only .cw-lumen-pro-logo-alternate {
	position: relative !important;
	inset: auto;
	width: var(--cw-logo-width, 40px) !important;
	height: auto !important;
	max-width: min(var(--cw-logo-width, 40px), 45vw) !important;
}
body.cw-lumen-pro-has-alternate-logo .cw-lumen-pro-logo-link .cw-lumen-pro-logo-standard {
	opacity: 1;
	visibility: visible;
}
body.cw-lumen-pro-has-alternate-logo .cw-lumen-pro-logo-link .cw-lumen-pro-logo-alternate {
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
}
body.cw-lumen-pro-header-transparent .cw-site-header.cw-lumen-pro-header--transparent:not(.cw-lumen-pro-header-is-solid) .cw-lumen-pro-logo-standard {
	opacity: 0;
	visibility: hidden;
}
body.cw-lumen-pro-header-transparent .cw-site-header.cw-lumen-pro-header--transparent:not(.cw-lumen-pro-header-is-solid) .cw-lumen-pro-logo-alternate {
	opacity: 1;
	visibility: visible;
}
body.cw-lumen-pro-header-transparent .cw-site-header.cw-lumen-pro-header--transparent.cw-lumen-pro-header-is-solid .cw-lumen-pro-logo-standard {
	opacity: 1;
	visibility: visible;
}
body.cw-lumen-pro-header-transparent .cw-site-header.cw-lumen-pro-header--transparent.cw-lumen-pro-header-is-solid .cw-lumen-pro-logo-alternate {
	opacity: 0;
	visibility: hidden;
}
@media (prefers-reduced-motion: reduce) {
	.cw-lumen-pro-logo-standard,
	.cw-lumen-pro-logo-alternate {
		transition: none !important;
	}
}

/* Cabecera avanzada por perfil ------------------------------------------------
 * These rules only use Lumen's public header classes and navigation markup.
 * They never change the global Customizer settings stored by the free theme. */
body.cw-lumen-pro-controls-header-placement.cw-lumen-pro-header-placement--normal:not(.cw-lumen-pro-header-transparent) .cw-site-header {
	position: relative !important;
	top: auto !important;
	left: auto !important;
	right: auto !important;
	width: auto !important;
	max-width: none;
	margin: 0;
	box-sizing: border-box;
}

/* Non-transparent profiles retain the legacy fixed implementation. A
 * transparent sticky profile is intentionally excluded: it uses the native
 * sticky rule above so it keeps its layout slot during the handoff to hero. */
body.cw-lumen-pro-controls-header-placement.cw-lumen-pro-header-placement--fixed .cw-site-header.cw-header-is-fixed {
	position: fixed !important;
	top: 0;
	left: 0;
	right: 0;
	width: 100% !important;
	max-width: none;
	margin: 0;
	box-sizing: border-box;
	z-index: 99990;
}

.admin-bar.cw-lumen-pro-controls-header-placement.cw-lumen-pro-header-placement--sticky .cw-site-header {
	top: 32px !important;
}
.admin-bar.cw-lumen-pro-controls-header-placement.cw-lumen-pro-header-placement--fixed .cw-site-header.cw-header-is-fixed {
	top: 32px;
}

/* Surface variants are contextual only when the profile itself starts
 * solid. A transparent initial state always returns to the global Lumen Theme
 * colors as soon as it reaches the solid phase. */
body.cw-lumen-pro-header-variant--surface .cw-site-header:not(.cw-lumen-pro-header--transparent) {
	background: var(--cw-color-surface) !important;
	background-color: var(--cw-color-surface) !important;
	border-bottom-color: var(--cw-color-border) !important;
}

body.cw-lumen-pro-header-variant--brand .cw-site-header:not(.cw-lumen-pro-header--transparent) {
	background: var(--cw-color-primary) !important;
	background-color: var(--cw-color-primary) !important;
	border-bottom-color: var(--cw-color-primary) !important;
	color: #fff;
}

body.cw-lumen-pro-header-variant--brand .cw-site-header:not(.cw-lumen-pro-header--transparent) :is(a, .site-title, .site-description, .wp-block-site-title, .wp-block-site-tagline) {
	color: #fff !important;
}

/* Transparent profiles always receive a safe, readable contrast baseline before
 * JavaScript runs. Empty color fields intentionally use these recommended values;
 * saved profile values are injected later as CSS variables and override them.
 * The mobile panel has its own surface and deliberately falls back to Lumen while open. */
body.cw-lumen-pro-header-transparent {
	--cw-lumen-pro-transparent-navigation-color: #ffffff;
	--cw-lumen-pro-transparent-navigation-active-color: #10b981;
	--cw-lumen-pro-transparent-cta-background-color: #10b981;
	--cw-lumen-pro-transparent-cta-text-color: #ffffff;
}

/* The header marker is generated on the server. Fijo al desplazarse starts
 * with the solid marker, then removes it only while it is fixed and genuinely
 * overlaps the hero; returning to the initial flow restores global colors. */
body.cw-lumen-pro-header-transparent .cw-site-header.cw-lumen-pro-header--transparent:not(.cw-lumen-pro-header-is-solid) .cw-classic-navigation--primary:not(.is-open) .cw-classic-navigation__menu > li:not(.cw-lumen-pro-header-cta) > a {
	color: var(--cw-lumen-pro-transparent-navigation-color) !important;
}
body.cw-lumen-pro-header-transparent .cw-site-header.cw-lumen-pro-header--transparent:not(.cw-lumen-pro-header-is-solid) .cw-classic-navigation--primary:not(.is-open) .cw-classic-navigation__menu > li:not(.cw-lumen-pro-header-cta):is(:hover, :focus-within, .current-menu-item, .current_page_item, .current-menu-ancestor, .current-menu-parent, .current_page_ancestor) > a {
	color: var(--cw-lumen-pro-transparent-navigation-active-color) !important;
}
body.cw-lumen-pro-header-transparent .cw-site-header.cw-lumen-pro-header--transparent:not(.cw-lumen-pro-header-is-solid) .cw-classic-navigation--primary:not(.is-open) .cw-classic-navigation__toggle {
	color: var(--cw-lumen-pro-transparent-navigation-color) !important;
	border-color: currentColor !important;
}
body.cw-lumen-pro-header-transparent .cw-site-header.cw-lumen-pro-header--transparent:not(.cw-lumen-pro-header-is-solid) .cw-classic-navigation--primary:not(.is-open) .cw-lumen-pro-header-cta > .cw-lumen-pro-header-cta__link {
	background: var(--cw-lumen-pro-transparent-cta-background-color) !important;
	color: var(--cw-lumen-pro-transparent-cta-text-color) !important;
}
body.cw-lumen-pro-header-transparent .cw-site-header.cw-lumen-pro-header--transparent:not(.cw-lumen-pro-header-is-solid) .cw-classic-navigation--primary:not(.is-open) .cw-lumen-pro-header-cta > .cw-lumen-pro-header-cta__link:hover,
body.cw-lumen-pro-header-transparent .cw-site-header.cw-lumen-pro-header--transparent:not(.cw-lumen-pro-header-is-solid) .cw-classic-navigation--primary:not(.is-open) .cw-lumen-pro-header-cta > .cw-lumen-pro-header-cta__link:focus-visible {
	background: color-mix(in srgb, var(--cw-lumen-pro-transparent-cta-background-color) 88%, #000) !important;
	color: var(--cw-lumen-pro-transparent-cta-text-color) !important;
}

/* Selective header elements. The header itself remains in the document unless
 * the existing global header visibility control explicitly hides it. */
body.cw-lumen-pro-header-logo-hidden .cw-site-header .cw-site-identity > :is(.wp-block-site-logo, .custom-logo-link),
body.cw-lumen-pro-header-logo-hidden .cw-site-header .cw-site-identity > .cw-lumen-pro-logo-link {
	display: none !important;
}
body.cw-lumen-pro-header-site-title-hidden .cw-site-header .cw-site-identity .site-title,
body.cw-lumen-pro-header-site-title-hidden .cw-site-header .cw-site-identity .wp-block-site-title {
	display: none !important;
}
body.cw-lumen-pro-header-tagline-hidden .cw-site-header .cw-site-identity .site-description,
body.cw-lumen-pro-header-tagline-hidden .cw-site-header .cw-site-identity .wp-block-site-tagline {
	display: none !important;
}
body.cw-lumen-pro-header-navigation-hidden .cw-site-header .cw-classic-navigation--primary {
	display: none !important;
}

/* CTA: one safe WordPress-menu item, visually promoted without introducing a
 * second navigation system. */
.cw-site-header .cw-classic-navigation__menu > .cw-lumen-pro-header-cta > .cw-lumen-pro-header-cta__link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: var(--cw-header-action-min-height, 2.55rem);
	padding: var(--cw-header-action-padding-block, .58rem) var(--cw-header-action-padding-inline, 1rem);
	border: 1px solid transparent;
	border-radius: var(--cw-header-action-radius, .7rem);
	background: var(--cw-color-primary);
	color: #fff !important;
	font-weight: var(--cw-header-action-font-weight, 700);
	line-height: var(--cw-header-action-line-height, 1.2);
	white-space: nowrap;
	text-decoration: none !important;
	transition: transform 160ms ease, box-shadow 160ms ease, background-color 160ms ease;
}
.cw-site-header .cw-classic-navigation__menu > .cw-lumen-pro-header-cta > .cw-lumen-pro-header-cta__link::after {
	display: none !important;
}
.cw-site-header .cw-classic-navigation__menu > .cw-lumen-pro-header-cta > .cw-lumen-pro-header-cta__link:hover,
.cw-site-header .cw-classic-navigation__menu > .cw-lumen-pro-header-cta > .cw-lumen-pro-header-cta__link:focus-visible {
	background: var(--cw-color-accent-strong, var(--cw-color-primary));
	box-shadow: 0 .45rem 1.1rem rgb(15 23 42 / 16%);
	transform: translateY(-1px);
}
body.cw-lumen-pro-header-variant--brand .cw-site-header:not(.cw-lumen-pro-header--transparent) .cw-lumen-pro-header-cta__link {
	background: #fff;
	color: var(--cw-color-primary) !important;
}

@media (min-width: 1025px) {
	body.cw-lumen-pro-header-cta-desktop-hidden .cw-lumen-pro-header-cta { display: none !important; }
	body.cw-lumen-pro-header-density-desktop--compact .cw-site-header__inner { padding-block: .4rem !important; }
	body.cw-lumen-pro-header-density-desktop--normal .cw-site-header__inner { padding-block: .8rem !important; }
	body.cw-lumen-pro-header-density-desktop--spacious .cw-site-header__inner { padding-block: 1.2rem !important; }
}

@media (min-width: 782px) and (max-width: 1024px) {
	body.cw-lumen-pro-header-cta-tablet-hidden .cw-lumen-pro-header-cta { display: none !important; }
	body.cw-lumen-pro-header-density-tablet--compact .cw-site-header__inner { padding-block: .4rem !important; }
	body.cw-lumen-pro-header-density-tablet--normal .cw-site-header__inner { padding-block: .7rem !important; }
	body.cw-lumen-pro-header-density-tablet--spacious .cw-site-header__inner { padding-block: 1rem !important; }
}

@media (max-width: 781px) {
	body.cw-lumen-pro-header-cta-mobile-hidden .cw-lumen-pro-header-cta { display: none !important; }
	body.cw-lumen-pro-header-density-mobile--compact .cw-site-header__inner { padding-block: .32rem !important; }
	body.cw-lumen-pro-header-density-mobile--normal .cw-site-header__inner { padding-block: .62rem !important; }
	body.cw-lumen-pro-header-density-mobile--spacious .cw-site-header__inner { padding-block: .92rem !important; }
	.cw-site-header .cw-classic-navigation__menu > .cw-lumen-pro-header-cta > .cw-lumen-pro-header-cta__link {
		width: 100%;
		margin-top: .35rem;
	}
}

@media (max-width: 782px) {
	.admin-bar.cw-lumen-pro-controls-header-placement.cw-lumen-pro-header-placement--sticky .cw-site-header {
		top: 46px !important;
	}
	.admin-bar.cw-lumen-pro-controls-header-placement.cw-lumen-pro-header-placement--fixed .cw-site-header.cw-header-is-fixed {
		top: 46px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.cw-site-header.cw-lumen-pro-header--transparent,
	.cw-site-header.cw-lumen-pro-header--transparent *,
	.cw-site-header .cw-lumen-pro-header-cta__link {
		transition-duration: .01ms !important;
		animation-duration: .01ms !important;
		animation-iteration-count: 1 !important;
	}
	.cw-site-header .cw-lumen-pro-header-cta__link:hover,
	.cw-site-header .cw-lumen-pro-header-cta__link:focus-visible {
		transform: none;
	}
}


/* Paso 4: overrides responsive por perfil ----------------------------------
 * Estos bloques sólo se activan cuando el perfil ganador define un valor
 * explícito para Tablet o Celular. El Theme sigue siendo dueño de gutters,
 * breakpoints de navegación y de los estados estructurales de la cabecera. */
@media (min-width: 782px) and (max-width: 1024px) {
	body.cw-lumen-pro-responsive-tablet-width--standard .cw-content-wrap,
	body.cw-lumen-pro-responsive-tablet-width--standard .cw-content-wrap.cw-screen-layout--none {
		width: min(calc(100% - var(--cw-tablet-gutter, 32px) - var(--cw-tablet-gutter, 32px)), var(--cw-layout-content, 760px));
	}
	body.cw-lumen-pro-responsive-tablet-width--wide .cw-content-wrap,
	body.cw-lumen-pro-responsive-tablet-width--wide .cw-content-wrap.cw-screen-layout--none {
		width: min(calc(100% - var(--cw-tablet-gutter, 32px) - var(--cw-tablet-gutter, 32px)), var(--cw-layout-wide, 1120px));
	}
	body.cw-lumen-pro-responsive-tablet-width--standard .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout {
		width: min(calc(100% - var(--cw-tablet-gutter, 32px) - var(--cw-tablet-gutter, 32px)), var(--cw-layout-content, 760px));
	}
	body.cw-lumen-pro-responsive-tablet-width--wide .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout {
		width: min(calc(100% - var(--cw-tablet-gutter, 32px) - var(--cw-tablet-gutter, 32px)), var(--cw-layout-wide, 1120px));
	}
	body.cw-lumen-pro-responsive-tablet-sidebar-hidden .cw-screen-layout--left,
	body.cw-lumen-pro-responsive-tablet-sidebar-hidden .cw-screen-layout--right,
	body.cw-lumen-pro-responsive-tablet-sidebar-hidden .cw-hero-template__layout--left,
	body.cw-lumen-pro-responsive-tablet-sidebar-hidden .cw-hero-template__layout--right {
		display: block !important;
		width: min(calc(100% - var(--cw-tablet-gutter, 32px) - var(--cw-tablet-gutter, 32px)), var(--cw-layout-wide, 1120px));
	}
	body.cw-lumen-pro-responsive-tablet-sidebar-hidden .cw-sidebar { display: none !important; }
	body.cw-lumen-pro-responsive-tablet-logo--hide .cw-site-header .cw-site-identity > :is(.wp-block-site-logo, .custom-logo-link),
	body.cw-lumen-pro-responsive-tablet-logo--hide .cw-site-header .cw-site-identity > .cw-lumen-pro-logo-link,
	body.cw-lumen-pro-responsive-tablet-site-title--hide .cw-site-header .cw-site-identity :is(.site-title, .wp-block-site-title),
	body.cw-lumen-pro-responsive-tablet-tagline--hide .cw-site-header .cw-site-identity :is(.site-description, .wp-block-site-tagline) { display: none !important; }
	body.cw-lumen-pro-responsive-tablet-logo--show .cw-site-header .cw-site-identity > :is(.wp-block-site-logo, .custom-logo-link, .cw-lumen-pro-logo-link) { display: block !important; }
	body.cw-lumen-pro-responsive-tablet-site-title--show .cw-site-header .cw-site-identity :is(.site-title, .wp-block-site-title),
	body.cw-lumen-pro-responsive-tablet-tagline--show .cw-site-header .cw-site-identity :is(.site-description, .wp-block-site-tagline) { display: block !important; }
}

@media (max-width: 781px) {
	body.cw-lumen-pro-responsive-mobile-width--standard .cw-content-wrap,
	body.cw-lumen-pro-responsive-mobile-width--standard .cw-content-wrap.cw-screen-layout--none {
		width: min(calc(100% - var(--cw-mobile-gutter, 16px) - var(--cw-mobile-gutter, 16px)), var(--cw-layout-content, 760px));
	}
	body.cw-lumen-pro-responsive-mobile-width--wide .cw-content-wrap,
	body.cw-lumen-pro-responsive-mobile-width--wide .cw-content-wrap.cw-screen-layout--none {
		width: min(calc(100% - var(--cw-mobile-gutter, 16px) - var(--cw-mobile-gutter, 16px)), var(--cw-layout-wide, 1120px));
	}
	body.cw-lumen-pro-responsive-mobile-width--standard .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout {
		width: min(calc(100% - var(--cw-mobile-gutter, 16px) - var(--cw-mobile-gutter, 16px)), var(--cw-layout-content, 760px));
	}
	body.cw-lumen-pro-responsive-mobile-width--wide .cw-hero-template__hero:not(.cw-hero-template__hero--elementor) + .cw-hero-template__layout {
		width: min(calc(100% - var(--cw-mobile-gutter, 16px) - var(--cw-mobile-gutter, 16px)), var(--cw-layout-wide, 1120px));
	}
	body.cw-lumen-pro-responsive-mobile-sidebar-hidden .cw-screen-layout--left,
	body.cw-lumen-pro-responsive-mobile-sidebar-hidden .cw-screen-layout--right,
	body.cw-lumen-pro-responsive-mobile-sidebar-hidden .cw-hero-template__layout--left,
	body.cw-lumen-pro-responsive-mobile-sidebar-hidden .cw-hero-template__layout--right {
		display: block !important;
		width: min(calc(100% - var(--cw-mobile-gutter, 16px) - var(--cw-mobile-gutter, 16px)), var(--cw-layout-wide, 1120px));
	}
	body.cw-lumen-pro-responsive-mobile-sidebar-hidden .cw-sidebar { display: none !important; }
	body.cw-lumen-pro-responsive-mobile-logo--hide .cw-site-header .cw-site-identity > :is(.wp-block-site-logo, .custom-logo-link),
	body.cw-lumen-pro-responsive-mobile-logo--hide .cw-site-header .cw-site-identity > .cw-lumen-pro-logo-link,
	body.cw-lumen-pro-responsive-mobile-site-title--hide .cw-site-header .cw-site-identity :is(.site-title, .wp-block-site-title),
	body.cw-lumen-pro-responsive-mobile-tagline--hide .cw-site-header .cw-site-identity :is(.site-description, .wp-block-site-tagline) { display: none !important; }
	body.cw-lumen-pro-responsive-mobile-logo--show .cw-site-header .cw-site-identity > :is(.wp-block-site-logo, .custom-logo-link, .cw-lumen-pro-logo-link) { display: block !important; }
	body.cw-lumen-pro-responsive-mobile-site-title--show .cw-site-header .cw-site-identity :is(.site-title, .wp-block-site-title),
	body.cw-lumen-pro-responsive-mobile-tagline--show .cw-site-header .cw-site-identity :is(.site-description, .wp-block-site-tagline) { display: block !important; }
}

/* 1.8.64 · Paridad vertical sticky en todo el contexto compacto.
 * En Fijo al desplazarse la cabecera conserva su slot en el flujo y deja visible
 * el padding superior editorial del main. La diferencia frente a Fijo desde el
 * inicio también se reproduce en tablet y celular, por lo que la corrección se
 * aplica a cualquier ancho cuando coinciden el contexto compacto y Sticky. */
body.cw-lumen-hero-layout--compact.cw-lumen-pro-header-placement--sticky
.cw-template-main {
	padding-block-start: 0 !important;
}

/* 1.8.65 · Transparencia y continuidad vertical en el contexto apilado.
 * A 960 px o menos la sidebar deja de compartir la fila con el Hero. El canvas
 * vuelve a ser continuo, por lo que una cabecera transparente Sticky puede
 * superponerse al Hero desde el inicio como en las plantillas sin sidebar.
 * El main pierde solo el aire editorial exterior; las zonas seguras internas
 * del Hero continúan reservando el espacio necesario para logo y navegación. */
@media (max-width: 960px) {
	body.cw-lumen-hero-layout--compact
	.cw-template-main {
		padding-block-start: 0 !important;
	}

}
