/**
 * Foro ODS - Estilos globales del sitio.
 * Se carga en todas las paginas publicas despues de frontend.css.
 */

@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700;800&display=swap');

/* Tipografia general */
body,
button,
input,
select,
textarea,
.wp-block-button__link {
	font-family: 'Montserrat', Arial, sans-serif !important;
}

nav a,
.menu a,
.ct-button,
.wp-element-button {
	font-family: 'Montserrat', Arial, sans-serif !important;
	font-weight: 600;
}

h1,
h2,
h3,
h4,
h5,
h6,
.entry-title,
.page-title {
	font-family: 'Montserrat', Arial, sans-serif !important;
	font-weight: 700;
}

/* Cabecera fija global: Home, paginas internas y landing. */
html {
	scroll-padding-top: 120px;
}

#header.ct-header,
header#header {
	position: sticky !important;
	top: 0;
	z-index: 99999 !important;
	background: #fff;
	box-shadow: 0 6px 20px rgba(30, 38, 72, 0.08);
}

body.admin-bar #header.ct-header,
body.admin-bar header#header {
	top: 32px;
}

@media (max-width: 782px) {
	html {
		scroll-padding-top: 100px;
	}

	body.admin-bar #header.ct-header,
	body.admin-bar header#header {
		top: 46px;
	}
}

/* Linea amarilla del menu: solo hover en escritorio */
@media (min-width: 1000px) {
	#header [data-id="menu"] > ul > li > a {
		background-image: linear-gradient(#f6b108, #f6b108) !important;
		background-repeat: no-repeat !important;
		background-position: center calc(50% + 17px) !important;
		background-size: 0 3px !important;
		transition:
			color 0.25s ease,
			background-size 0.25s ease !important;
	}

	#header [data-id="menu"] > ul > li:hover > a,
	#header [data-id="menu"] > ul > li:focus-within > a {
		background-size: calc(100% - 28px) 3px !important;
	}

	/* El enlace activo no conserva la linea */
	#header [data-id="menu"] > ul > li.current-menu-item:not(:hover) > a,
	#header [data-id="menu"] > ul > li.current_page_item:not(:hover) > a,
	#header [data-id="menu"] > ul > li.current-menu-ancestor:not(:hover) > a {
		background-size: 0 3px !important;
		border-bottom: 0 !important;
		box-shadow: none !important;
	}
}

/* Pie de pagina global */
#footer.ct-footer {
	position: relative;
	overflow: hidden;
	color: #fefefe;
	background: #2d1c42;
}

#footer.ct-footer [data-row] {
	border: 0 !important;
	background: transparent !important;
}

#footer.ct-footer [data-row="middle"] {
	position: relative;
	background: linear-gradient(110deg, #291a3d 0%, #48245c 48%, #73338a 100%) !important;
}

/* Circulos decorativos del esqueleto. */
#footer.ct-footer [data-row="middle"]::before,
#footer.ct-footer [data-row="middle"]::after {
	content: "";
	position: absolute;
	z-index: 0;
	pointer-events: none;
	border-radius: 50%;
}

#footer.ct-footer [data-row="middle"]::before {
	top: -230px;
	right: -135px;
	width: 520px;
	height: 520px;
	border: 70px solid rgba(255, 255, 255, 0.035);
}

#footer.ct-footer [data-row="middle"]::after {
	top: -90px;
	right: 5px;
	width: 245px;
	height: 245px;
	background: rgba(34, 18, 51, 0.12);
}

#footer.ct-footer [data-row="middle"] > .ct-container {
	position: relative;
	z-index: 1;
	align-items: start;
	gap: 54px !important;
	padding-top: 50px !important;
	padding-bottom: 36px !important;
}

#footer.ct-footer [data-row="middle"] .ct-widget,
#footer.ct-footer [data-row="middle"] .ct-widget > *,
#footer.ct-footer [data-row="middle"] .wp-block-group,
#footer.ct-footer [data-row="middle"] .wp-block-group > * {
	margin-top: 0;
}

#footer.ct-footer [data-row="middle"] :is(.widget-title, h2, h3, h4) {
	margin: 0 0 22px !important;
	color: #f6b108 !important;
	font-size: 17px !important;
	font-weight: 800 !important;
	line-height: 1.25 !important;
	letter-spacing: 0.035em;
	text-transform: uppercase;
}

#footer.ct-footer [data-row="middle"] p,
#footer.ct-footer [data-row="middle"] li,
#footer.ct-footer [data-row="middle"] a {
	color: rgba(255, 255, 255, 0.88) !important;
	font-size: 16px !important;
	line-height: 1.55 !important;
}

#footer.ct-footer [data-row="middle"] p {
	margin: 0 0 12px !important;
}

#footer.ct-footer [data-row="middle"] ul,
#footer.ct-footer [data-row="middle"] .wp-block-navigation__container {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 13px !important;
	margin: 0 !important;
	padding: 0 !important;
	list-style: none;
}

#footer.ct-footer [data-row="middle"] a {
	text-decoration: none;
	transition: color 0.2s ease;
}

#footer.ct-footer [data-row="middle"] a:hover {
	color: #f6b108 !important;
}

/* Logo dentro de la tarjeta blanca. */
#footer.ct-footer [data-row="middle"] .ct-container > div:first-child img {
	display: block;
	box-sizing: border-box;
	width: 100% !important;
	max-width: 365px !important;
	height: auto !important;
	margin: 0 0 20px !important;
	padding: 12px 20px;
	border-radius: 16px;
	background: #fefefe;
}

#footer.ct-footer [data-row="middle"] .ct-container > div:first-child p {
	max-width: 410px;
}

/* Redes sociales compactas y visibles. */
#footer.ct-footer .wp-block-social-links,
#footer.ct-footer .stk-block-social-buttons__button-container {
	display: flex !important;
	flex-direction: row !important;
	gap: 12px !important;
	margin: 22px 0 0 !important;
	padding: 0 !important;
}

#footer.ct-footer .wp-social-link,
#footer.ct-footer .stk-block-social-buttons__button {
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	width: 48px !important;
	height: 48px !important;
	margin: 0 !important;
	border: 1px solid rgba(255, 255, 255, 0.3) !important;
	border-radius: 12px !important;
	color: #fff !important;
	background: transparent !important;
}

#footer.ct-footer .wp-social-link svg,
#footer.ct-footer .stk-block-social-buttons__button svg {
	width: 20px !important;
	height: 20px !important;
	fill: currentColor !important;
}

/* Franja inferior del copyright. */
#footer.ct-footer [data-row="bottom"] {
	border-top: 1px solid rgba(255, 255, 255, 0.12) !important;
	background: #241533 !important;
}

#footer.ct-footer [data-row="bottom"] > .ct-container {
	min-height: 54px !important;
	padding-top: 13px !important;
	padding-bottom: 13px !important;
}

#footer.ct-footer .ct-footer-copyright,
#footer.ct-footer .ct-footer-copyright p {
	margin: 0 !important;
	color: rgba(255, 255, 255, 0.72) !important;
	font-size: 13px !important;
	line-height: 1.4 !important;
}

@media (min-width: 1000px) {
	#footer.ct-footer [data-row="middle"] > .ct-container {
		grid-template-columns: minmax(320px, 1.35fr) repeat(2, minmax(170px, 0.8fr)) minmax(230px, 1fr) !important;
	}
}

@media (min-width: 690px) and (max-width: 999px) {
	#footer.ct-footer [data-row="middle"] > .ct-container {
		grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
		gap: 38px !important;
	}
}

@media (max-width: 689px) {
	#footer.ct-footer [data-row="middle"] > .ct-container {
		grid-template-columns: 1fr !important;
		gap: 30px !important;
		padding-top: 38px !important;
		padding-bottom: 30px !important;
	}

	#footer.ct-footer [data-row="middle"] .ct-container > div:first-child img {
		max-width: 320px !important;
	}
}
