/**
 * Jursoc UNLP — sistema tipográfico institucional
 * Títulos: EB Garamond | Cuerpo e interfaz: Inter
 */

:root {
	--font-heading: "EB Garamond", Georgia, "Times New Roman", serif;
	--font-body: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

	--jursoc-font-heading: var(--font-heading);
	--jursoc-font-body: var(--font-body);

	--jursoc-weight-regular: 400;
	--jursoc-weight-medium: 500;
	--jursoc-weight-semibold: 600;

	--jursoc-leading-body: 1.65;
	--jursoc-leading-body-tight: 1.5;
	--jursoc-leading-heading: 1.18;
	--jursoc-leading-heading-lg: 1.12;

	--jursoc-tracking-heading-tight: -0.02em;
	--jursoc-tracking-heading: -0.01em;
	--jursoc-tracking-heading-sm: 0.01em;
	--jursoc-tracking-label: 0.08em;
	--jursoc-tracking-ui: 0.01em;

	/* Kadence — alineación con tokens Jursoc */
	--global-body-font-family: var(--font-body);
	--global-heading-font-family: var(--font-heading);
	--global-primary-nav-font-family: var(--font-body);
	--global-fallback-font: sans-serif;
	--global-display-fallback-font: serif;
}

/* —— Base —— */
html {
	font-family: var(--font-body);
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	text-rendering: optimizeLegibility;
}

body {
	font-family: var(--font-body);
	font-weight: var(--jursoc-weight-regular);
	line-height: var(--jursoc-leading-body);
}

/* —— Títulos editoriales —— */
h1,
.h1,
h2,
.h2 {
	font-family: var(--font-heading);
	font-weight: var(--jursoc-weight-semibold);
	letter-spacing: var(--jursoc-tracking-heading-tight);
	line-height: var(--jursoc-leading-heading-lg);
}

h3,
.h3,
h4,
.h4 {
	font-family: var(--font-heading);
	font-weight: var(--jursoc-weight-semibold);
	letter-spacing: var(--jursoc-tracking-heading);
	line-height: var(--jursoc-leading-heading);
}

h5,
.h5,
h6,
.h6 {
	font-family: var(--font-heading);
	font-weight: var(--jursoc-weight-medium);
	letter-spacing: var(--jursoc-tracking-heading-sm);
	line-height: 1.28;
}

.wp-block-heading,
.entry-title,
.page-title,
.site-title,
.site-description {
	font-family: var(--font-heading);
}

/* —— Contenido —— */
p,
li,
dd,
dt,
figcaption,
label,
legend,
td,
th {
	font-family: var(--font-body);
}

strong,
b {
	font-weight: var(--jursoc-weight-medium);
}

em,
i,
cite {
	font-family: var(--font-heading);
	font-style: italic;
}

.entry-content,
.content-area,
.wp-block-post-content {
	font-family: var(--font-body);
	font-weight: var(--jursoc-weight-regular);
	line-height: var(--jursoc-leading-body);
}

/* —— Navegación Kadence —— */
.primary-navigation a,
#primary-menu a,
#primary-menu .menu-item > a,
.secondary-navigation a,
#secondary-navigation a,
#secondary-navigation .menu-item > a,
.mobile-navigation a,
.header-navigation a {
	font-family: var(--font-body) !important;
	letter-spacing: var(--jursoc-tracking-ui);
}

.primary-navigation a,
#primary-menu a,
#primary-menu .menu-item > a,
.header-navigation.header-navigation-style-standard a {
	font-weight: var(--jursoc-weight-medium) !important;
}

.secondary-navigation a,
#secondary-navigation a,
#secondary-navigation .menu-item > a {
	font-weight: var(--jursoc-weight-regular) !important;
}

/* —— Botones —— */
button,
input[type="button"],
input[type="submit"],
input[type="reset"],
.button,
.wp-block-button__link,
.kb-button,
.header-button-wrap .button,
.mobile-header-button-wrap .button,
.jursoc-filter-pill,
.jursoc-pagination__btn {
	font-family: var(--font-body) !important;
	font-weight: var(--jursoc-weight-semibold) !important;
	letter-spacing: var(--jursoc-tracking-ui);
}

/* —— Formularios y tablas —— */
input,
textarea,
select,
.wp-block-search__input,
.jursoc-search__input {
	font-family: var(--font-body) !important;
	font-weight: var(--jursoc-weight-regular);
	line-height: var(--jursoc-leading-body-tight);
}

table,
.wp-block-table {
	font-family: var(--font-body);
	font-size: inherit;
	line-height: var(--jursoc-leading-body-tight);
}

/* —— Breadcrumbs y paginación —— */
.kadence-breadcrumbs,
.breadcrumbs,
.jursoc-pagination,
.jursoc-pagination__status,
.navigation.pagination,
.page-numbers {
	font-family: var(--font-body);
}

/* —— Footer —— */
.jursoc-footer-institucional,
.site-footer,
footer[role="contentinfo"] {
	font-family: var(--font-body);
	line-height: var(--jursoc-leading-body);
}

.jursoc-footer-institucional strong {
	font-family: var(--font-body);
	font-weight: var(--jursoc-weight-semibold);
}

/* —— Citas y destacados institucionales —— */
blockquote,
.wp-block-quote,
.wp-block-pullquote,
q {
	font-family: var(--font-heading);
	font-weight: var(--jursoc-weight-medium);
	line-height: var(--jursoc-leading-heading);
	letter-spacing: var(--jursoc-tracking-heading-sm);
}

/* —— Componentes Jursoc (interfaz = Inter por defecto) —— */
[class*="jursoc-"] {
	font-family: var(--font-body);
}

/* —— Hero y secciones destacadas (Garamond) —— */
.jursoc-hero__title,
.jursoc-hero__lead,
.jursoc-section-title,
.jursoc-cinematic__title,
.jursoc-news-rotator__title,
.jursoc-hero-hub__title,
.jursoc-hero-hub__stat-value,
.jursoc-claustro-section__title,
.jursoc-claustro-section__lead,
.jursoc-accesos-menu__title,
.jursoc-home-ranking__title,
.jursoc-eventos-carousel__heading,
.jursoc-sec-pill__title {
	font-family: var(--font-heading) !important;
	font-weight: var(--jursoc-weight-semibold);
	letter-spacing: var(--jursoc-tracking-heading-tight);
	line-height: var(--jursoc-leading-heading);
}

/* Labels / UI compacta (Inter) */
.jursoc-hero__eyebrow,
.jursoc-home-section__lead,
.jursoc-filter-pill,
.jursoc-claustros-link__label,
.jursoc-secretarias-nav__label,
.jursoc-accesos-menu__label,
.jursoc-home-ranking__kind,
.jursoc-calendar-widget__title,
.jursoc-chat-mockup__title {
	font-family: var(--font-body) !important;
}

.jursoc-hero__eyebrow,
.jursoc-home-ranking__title,
.jursoc-eventos-carousel__heading,
.jursoc-accesos-menu__title {
	font-weight: var(--jursoc-weight-semibold);
	letter-spacing: var(--jursoc-tracking-label);
	text-transform: uppercase;
}

/* Cards de noticias */
.jursoc-card__title {
	font-family: var(--font-heading) !important;
	font-weight: var(--jursoc-weight-semibold);
	letter-spacing: var(--jursoc-tracking-heading-sm);
	line-height: 1.25;
}

.jursoc-card__meta,
.jursoc-card__excerpt,
.jursoc-card__cta,
.jursoc-results-count {
	font-family: var(--font-body) !important;
}

/* Modales claustro */
.jursoc-claustro-modal,
.jursoc-claustro-modal__title,
.jursoc-claustro-modal__shortcut-label {
	font-family: var(--font-body);
}

.jursoc-claustro-modal__title {
	font-family: var(--font-heading) !important;
	font-weight: var(--jursoc-weight-semibold);
}

/* Bloques Kadence / editor */
[class*="wp-block-kadence"],
.kb-blocks-bg,
.kt-blocks-carousel {
	font-family: var(--font-body);
}

[class*="wp-block-kadence"] .wp-block-heading,
[class*="wp-block-kadence"] h1,
[class*="wp-block-kadence"] h2,
[class*="wp-block-kadence"] h3,
[class*="wp-block-kadence"] h4,
[class*="wp-block-kadence"] h5,
[class*="wp-block-kadence"] h6 {
	font-family: var(--font-heading);
}

/* Accesibilidad: conservar familias al escalar tamaño */
html.jursoc-a11y-font-lg,
html.jursoc-a11y-font-xl {
	font-family: var(--font-body);
}

/* —— Responsive —— */
@media (max-width: 767px) {
	h1,
	.h1 {
		letter-spacing: -0.015em;
		line-height: 1.2;
	}

	h2,
	.h2,
	h3,
	.h3 {
		letter-spacing: -0.01em;
		line-height: 1.22;
	}

	.jursoc-cinematic__title,
	.jursoc-hero__title {
		letter-spacing: -0.015em;
		line-height: 1.18;
	}
}

@media (prefers-reduced-motion: reduce) {
	* {
		text-rendering: auto;
	}
}
