/*
 * Tema ANI — estilos del sitio anadie.gob.gt.
 * Escrito para este sitio a partir de los valores medidos en pantalla (no deriva del CSS de
 * Induxo). Base: Bootstrap 4.0.0 y Font Awesome 4.7. Los colores y fuentes de las opciones del
 * tema se agregan aparte como CSS en línea (inc/css-dinamico.php).
 */

/* ---------- Base ---------- */
html body {
	color: #666;
	font-weight: 400;
	line-height: 26px;
	-webkit-font-smoothing: antialiased;
}
p {
	margin-bottom: 25px;
}
a {
	line-height: inherit;
}
/* Imágenes de la biblioteca insertadas en el contenido: 10 px arriba y abajo, como en el original. */
img[class*="wp-image-"] {
	margin-top: 10px;
	margin-bottom: 10px;
}
a:hover,
a:focus {
	text-decoration: none;
}
img {
	max-width: 100%;
	height: auto;
}
h1 { font-size: 36px; line-height: 36px; }
h2 { font-size: 30px; line-height: 36px; }
h3 { font-size: 24px; line-height: 28.8px; margin-bottom: 20px; }
h4 { font-size: 18px; line-height: 28px; }
h5 { font-family: "Zilla Slab", serif; font-size: 16px; }
h6 { font-family: "Zilla Slab", serif; font-size: 14px; line-height: 24px; }
.elementor-widget-container > p,
.elementor-tab-content > p,
.elementor-shortcode > p,
.premium-person-content > p,
.blog-content > p {
	margin-bottom: 25px;
}
.elementor-widget-container > ul {
	margin-bottom: 0;
}
.entry-content > p {
	margin: 32px 0;
}

/* ---------- Cabecera ----------
 * La cabecera es la plantilla de Elementor "Cabecera ANI" (colores, sombra y rellenos están ahí).
 * Contrato: su sección principal lleva las clases "header navbar-sticky"; ani.js agrega "sticky"
 * al bajar y estas reglas la fijan arriba. Si se quitan esas clases en Elementor, la cabecera deja
 * de quedar fija. */
.header {
	line-height: 26px;
}

/* Fija al bajar solo en escritorio, como en el sitio original. */
@media (min-width: 992px) {
	.navbar-sticky.sticky {
		position: fixed;
		top: 0;
		left: 0;
		right: 0;
		z-index: 999;
		animation: ani-bajar 0.4s;
	}
}
@keyframes ani-bajar {
	from { transform: translateY(-100%); }
	to { transform: translateY(0); }
}

/* ---------- Banner de página ---------- */
.banner-area {
	position: relative;
	z-index: 1;
	padding: 138px 0;
	background-position: 50% 50%;
	background-size: cover;
}
.banner-area::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
}
.banner-title {
	color: #fff;
	font-size: 64px;
	font-weight: 600;
	line-height: 70px;
}

/* ---------- Contenido de páginas y blog ---------- */
.main-container {
	padding: 80px 0;
	color: #666;
	line-height: 26px;
}
.main-container.blog,
.main-container.blog-single {
	padding-bottom: 50px;
}
.xs-page-header {
	margin-bottom: 30px;
}
.xs-page-header > h2,
.entry-title {
	font-size: 30px;
	line-height: 36px;
}
.section-title {
	position: relative;
	font-size: 36px;
	font-weight: 300;
	line-height: 36px;
}
.section-title > span {
	font-weight: 700;
}
.post-meta {
	margin-bottom: 0;
	color: #ff5c23;
}
.ts-blog {
	margin-left: 0;
	margin-right: 0;
}
.blog-box {
	margin: 0;
	padding: 40px;
	border: 1px solid #d2d2d2;
}
.ts-post-title {
	font-size: 24px;
	line-height: 28.8px;
	margin-bottom: 20px;
}
.btn-link {
	font-size: 13px;
	font-weight: 700;
}
.pagination {
	margin-bottom: 0;
}
.page-link {
	display: inline-block;
	color: #666;
	margin-right: 8px;
	border-radius: 3px;
	line-height: normal;
	text-align: center;
}
.error-code {
	margin-bottom: 20px;
	color: #333;
	font-size: 150px;
	line-height: 150px;
}

/* Botones del tema */
.btn.btn-primary.solid {
	margin-top: 30px;
	padding: 0 35px;
	border: 0;
	border-radius: 0;
	font-size: 14px;
	font-weight: 700;
	line-height: 42px;
	text-transform: uppercase;
}
.title-bg-small {
	display: inline-block;
	margin-bottom: 15px;
	padding: 3px 18px;
	color: #fff;
	font-size: 14px;
	font-weight: 700;
	line-height: 24px;
	text-transform: uppercase;
}

/* ---------- Widgets del tema (proyectos, video) ---------- */
.recent-project-wrapper {
	margin-bottom: 35px;
}
.recent-project-img {
	overflow: hidden;
}
.recent-project-img > img {
	width: 100%;
}
.recent-project-info {
	margin-top: 20px;
}
.project-category {
	margin-bottom: 10px;
}
.ts-title {
	font-size: 24px;
	font-weight: 600;
	line-height: 28.8px;
	margin-bottom: 0;
}
.ts-play-btn {
	display: inline-block;
	position: relative;
	border-radius: 50%;
}
.btn-hover-anim {
	display: block;
	position: absolute;
	inset: 0;
	border-radius: 50%;
	opacity: 0.3;
}

/* ---------- WooCommerce (listados de documentos) ---------- */
.woocommerce ul.products li.product {
	padding-bottom: 10px;
}
.woocommerce ul.products li.product .woocommerce-loop-product__title {
	padding: 0 0 10px;
}
.filter-title {
	font-size: 18px;
	line-height: 28px;
}

/* ---------- Pie de página ---------- */
.ts-footer,
.copy-right {
	line-height: 26px;
}
.BackTo {
	display: none;
	color: #979797;
	position: fixed;
	right: 14px;
	bottom: 30px;
	z-index: 9;
	width: 44px;
	padding: 8px 0;
	border-radius: 50%;
	text-align: center;
}
.BackTo a {
	display: inline-block;
	margin-top: 2px;
	color: #fff;
	font-size: 20px;
	font-weight: 700;
	line-height: 20px;
}

/* Paginación de entradas y documentos */
.pagination li > a,
.page-numbers li > a {
	border: 1px solid var(--ani-primario, #94c951);
	border-radius: 3px;
}

/* ---------- Celular ---------- */
@media (max-width: 767px) {
	.banner-area {
		padding: 60px 0;
	}
	.banner-title {
		font-size: 40px;
		line-height: 44px;
	}
	.blog-box {
		margin: 0 -1px 30px;
	}
	.post-meta {
		margin-bottom: 20px;
	}
	.ts-post-title {
		font-weight: 400;
	}
	.copy-right {
		text-align: center;
	}
}

/* ---------- Celular: nada se sale por el costado ----------
 * Corrige desbordes que ya existían con Induxo (contenido armado para escritorio). */
@media (max-width: 767px) {
	/* Columnas de Elementor con margen lateral de escritorio: el bloque interno se ajusta al
	   espacio que queda en vez de sumar el margen al 100 % (portada, En ejecución). */
	.elementor-column > .elementor-widget-wrap {
		width: auto;
		min-width: 0;
		flex: 1 1 auto;
	}
	/* Widgets con ancho fijo pensado para tableta o escritorio. */
	.elementor-widget {
		max-width: 100%;
	}
	/* Enlaces y textos largos sin espacios (direcciones web pegadas en el contenido). */
	.elementor-widget-container,
	.entry-content {
		overflow-wrap: anywhere;
	}
	/* Figuras decorativas posicionadas que asoman fuera de la pantalla. */
	html,
	body {
		overflow-x: hidden;
	}
}

/* ---------- Cabecera y pie hechos en Elementor (Header Footer Elementor) ----------
 * El diseño se edita en Elementor (Plantillas → Header Footer & Blocks). Aquí solo queda lo que
 * los controles del widget no permiten: la flecha de los submenús ocupa poco, como en el original,
 * para que el menú quepa en una línea. */
@media (min-width: 1025px) {
	.header .hfe-nav-menu > li > .hfe-has-submenu-container .sub-arrow {
		width: 0;
		margin: 0;
		position: relative;
		left: 3.57px;
	}
}
.header .hfe-nav-menu li {
	flex-shrink: 0;
}
.header .hfe-nav-menu a.hfe-menu-item {
	white-space: nowrap;
}
/* Solo la página actual va en verde; el padre del submenú queda como los demás. */
.header .hfe-nav-menu > li.current-menu-item > a.hfe-menu-item,
.header .hfe-nav-menu .sub-menu li.current-menu-item > a {
	color: #94c951;
}
/* Botón del menú en celular: 56 × 40, como el de Bootstrap del original. (Los selectores llevan la
 * clase del widget para pesar más que los que Elementor genera con los controles.) */
.header.header .elementor-widget-navigation-menu.elementor-element.elementor-widget .hfe-nav-menu__toggle .hfe-nav-menu-icon {
	padding: 4px 12px;
	border-color: rgba(0, 0, 0, 0.1);
	line-height: 30px;
}
.header.header .elementor-widget-navigation-menu.elementor-element.elementor-widget .hfe-nav-menu-icon i {
	width: 30px;
	text-align: center;
}
/* Ícono de tres rayas de Font Awesome 4 (más delgado), el mismo del original. */
.header .hfe-nav-menu-icon i.fa-bars::before {
	content: "\f0c9";
	font-family: FontAwesome;
	font-weight: 400;
}

/* Laptops angostas (1025–1199 px): menú compacto para que no se parta en dos líneas. */
@media (min-width: 1025px) and (max-width: 1199px) {
	.header.header .elementor-widget-navigation-menu.elementor-element.elementor-widget .hfe-nav-menu > li > a.hfe-menu-item,
	.header.header .elementor-widget-navigation-menu.elementor-element.elementor-widget .hfe-nav-menu > li > .hfe-has-submenu-container > a.hfe-menu-item {
		padding-left: 5px;
		padding-right: 5px;
		font-size: 12px;
	}
	.header.header .elementor-widget-navigation-menu.elementor-element.elementor-widget .hfe-nav-menu > li {
		margin-right: 6px;
	}
}

/* Menú desplegado en tablet y celular: panel azul con letras blancas, como el original. */
@media (max-width: 1024px) {
	.header.header .elementor-widget-navigation-menu.elementor-element.elementor-widget nav.hfe-dropdown {
		/* !important: el script del widget escribe left y width en línea para ocupar todo el ancho. */
		left: 15px !important;
		right: 15px;
		width: auto !important;
		background: #0d3242;
		box-shadow: none;
	}
	/* El panel se ubica respecto de toda la cabecera, no de la columna del botón. */
	.header .elementor-column,
	.header .elementor-widget-wrap,
	.header .elementor-widget-navigation-menu,
	.header .hfe-nav-menu {
		position: static;
	}
	/* El relleno solo con el menú abierto: cerrado, el panel no debe ocupar alto. */
	.header.header .elementor-widget-navigation-menu.elementor-element.elementor-widget .hfe-active-menu + nav.hfe-dropdown {
		padding: 20px;
	}
	.header.header .elementor-widget-navigation-menu.elementor-element.elementor-widget nav.hfe-dropdown li.menu-item,
	.header.header .elementor-widget-navigation-menu.elementor-element.elementor-widget nav.hfe-dropdown .sub-menu {
		border: 0;
		background: transparent;
	}
	.header.header .elementor-widget-navigation-menu.elementor-element.elementor-widget nav.hfe-dropdown li.menu-item a.hfe-menu-item {
		padding: 7px 0;
		border: 0;
		background: transparent;
		color: #fff;
		font-size: 14px;
		line-height: 36px;
	}
	.header.header .elementor-widget-navigation-menu.elementor-element.elementor-widget nav.hfe-dropdown .sub-menu {
		padding-left: 20px;
		box-shadow: none;
	}
	.header .hfe-nav-menu .sub-arrow:focus:not(:focus-visible) {
		outline: none;
	}
	.header.header .elementor-widget-navigation-menu.elementor-element.elementor-widget nav.hfe-dropdown li.menu-item a.hfe-sub-menu-item {
		padding: 12px 10px;
		border-bottom: 1px solid #fff;
		background: transparent;
		color: #fff;
		font-size: 12px;
		line-height: 26px;
	}
}

/* En el pie los widgets van pegados (los márgenes de cada uno se ponen en Elementor), y el bloque
 * de contacto no deja espacio abajo, como en el original. */
.ts-footer .elementor-widget:not(:last-child) {
	margin-bottom: 0;
	margin-block-end: 0;
}
.ts-footer .elementor-column:last-child p:last-child {
	margin-bottom: 0;
}

/* La categoría de cada entrada se muestra pero no es enlace (antes un snippet, #33). */
.post-cat {
	pointer-events: none;
}
