/*
 * Ixtli Programas — estilos del frontend.
 * Clases con prefijo ixtli-programas-; paleta sobria acorde al sitio
 * (azul institucional #1b396a / vino #9d2449 / dorado #a67c2e).
 */

.ixtli-programas {
	max-width: 1080px;
	margin: 0 auto;
}

/* Encabezado del programa. */
.ixtli-programas-encabezado {
	margin-bottom: 1.4em;
}

.ixtli-programas-encabezado-imagen img {
	display: block;
	width: 100%;
	height: auto;
	border-radius: 6px;
}

.ixtli-programas-encabezado-texto {
	margin-top: 1em;
}

.ixtli-programas-titulo {
	color: #1b396a;
	font-size: 1.6rem;
	font-weight: 700;
	line-height: 1.3;
	margin: 0.35em 0 0;
}

/* Badge de tipo de programa. */
.ixtli-programas-badge {
	display: inline-block;
	padding: 0.2em 0.8em;
	border-radius: 999px;
	font-size: 0.78rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.4px;
	background: #1b396a;
	color: #fff;
}

.ixtli-programas-badge--licenciatura {
	background: #9d2449;
}

/* Submenú de secciones: pestañas/píldoras horizontales que envuelven. */
.ixtli-programas-submenu {
	margin: 0 0 1.6em;
	border-bottom: 3px solid #a67c2e;
}

.ixtli-programas-submenu-lista {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	list-style: none;
	margin: 0;
	padding: 0;
}

.ixtli-programas-submenu-enlace {
	display: inline-block;
	padding: 0.5em 1em;
	border: 1px solid #d7dbe0;
	border-bottom: 0;
	border-radius: 8px 8px 0 0;
	background: #f4f5f7;
	color: #1b396a;
	font-size: 0.92rem;
	font-weight: 600;
	text-decoration: none;
	line-height: 1.3;
	transition: background-color 0.15s ease, color 0.15s ease;
}

.ixtli-programas-submenu-enlace:hover,
.ixtli-programas-submenu-enlace:focus-visible {
	background: #e8ebef;
	text-decoration: none;
}

.ixtli-programas-submenu-enlace.activo,
.ixtli-programas-submenu-enlace[aria-current='page'] {
	background: #1b396a;
	border-color: #1b396a;
	color: #fff;
}

/* Contenido de la sección. */
.ixtli-programas-seccion-titulo {
	color: #1b396a;
	font-size: 1.25rem;
	font-weight: 700;
	margin: 0 0 1em;
	padding-bottom: 0.35em;
	border-bottom: 2px solid #e2e4e8;
}

.ixtli-programas-pdf {
	display: block;
	width: 100%;
	height: 75vh;
	min-height: 420px;
	border: 1px solid #d7dbe0;
	border-radius: 6px;
	background: #f4f5f7;
}

.ixtli-programas-descargar {
	margin: 1em 0 0;
	text-align: right;
}

.ixtli-programas-boton {
	display: inline-block;
	padding: 0.6em 1.4em;
	border-radius: 6px;
	background: #9d2449;
	color: #fff;
	font-weight: 700;
	font-size: 0.95rem;
	text-decoration: none;
}

.ixtli-programas-boton:hover,
.ixtli-programas-boton:focus-visible {
	background: #7e1d3c;
	color: #fff;
	text-decoration: none;
}

/* Archive: rejilla de tarjetas. */
.ixtli-programas-archive-encabezado {
	margin-bottom: 1.4em;
}

.ixtli-programas-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
	gap: 1.4em;
}

.ixtli-programas-card {
	display: flex;
	flex-direction: column;
	background: #fff;
	border: 1px solid #e2e4e8;
	border-radius: 8px;
	overflow: hidden;
}

.ixtli-programas-card-imagen img {
	display: block;
	width: 100%;
	height: auto;
}

.ixtli-programas-card-cuerpo {
	padding: 1em 1.1em 1.2em;
}

.ixtli-programas-card-titulo {
	font-size: 1.05rem;
	font-weight: 700;
	margin: 0.6em 0 0.3em;
	line-height: 1.35;
}

.ixtli-programas-card-titulo a {
	color: #1b396a;
	text-decoration: none;
}

.ixtli-programas-card-titulo a:hover,
.ixtli-programas-card-titulo a:focus-visible {
	text-decoration: underline;
}

.ixtli-programas-card-resumen {
	font-size: 0.9rem;
	color: #4b5563;
	margin: 0;
}

.ixtli-programas-sin-resultados {
	padding: 1.4em;
	background: #f7f8fa;
	border: 1px solid #e2e4e8;
	border-radius: 6px;
}

/* Móvil: visor de PDF más bajo y submenú con píldoras envolventes. */
@media (max-width: 600px) {
	.ixtli-programas-pdf {
		height: 60vh;
		min-height: 320px;
	}

	.ixtli-programas-submenu {
		border-bottom: 0;
	}

	.ixtli-programas-submenu-lista {
		gap: 8px;
	}

	.ixtli-programas-submenu-enlace {
		border: 1px solid #d7dbe0;
		border-radius: 999px;
	}

	.ixtli-programas-submenu-enlace.activo,
	.ixtli-programas-submenu-enlace[aria-current='page'] {
		border-color: #1b396a;
	}
}
