/**
 * Estilos personalizados adicionales del tema
 * Estos estilos complementan Tailwind CSS
 */

/* =================================================================
   VARIABLES CSS GLOBALES
   ================================================================= */

:root {
	/* Estas variables se sobrescriben dinámicamente desde el Customizer */
	--cce-primary: #233A79;
	--cce-secondary: #FEC704;
	--cce-link: #233A79;
	--cce-font-size: 16px;
}

/* =================================================================
   ESTILOS GENERALES
   ================================================================= */

* {
	box-sizing: border-box;
}

body {
	font-size: var(--cce-font-size);
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

img {
	max-width: 100%;
	height: auto;
}

/* =================================================================
   CONTENEDOR
   ================================================================= */

.container {
	width: 100%;
	max-width: 1200px;
	margin-left: auto;
	margin-right: auto;
}

/* =================================================================
   HEADER
   ================================================================= */

.site-header {
	transition: all 0.3s ease;
}

.site-header.scrolled {
	background-color: #ffffff;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.site-branding a {
	text-decoration: none;
}

.custom-logo-link {
	display: inline-block;
}

.custom-logo-link img {
	display: block;
	max-height: 50px;
	width: auto;
}

/* Navegación */
.primary-navigation ul {
	list-style: none;
	margin: 0;
	padding: 0;
}

.primary-navigation a {
	text-decoration: none;
	color: #4b5563;
	font-weight: 500;
	transition: color 0.2s;
}

.primary-navigation a:hover {
	color: var(--cce-primary);
}

/* User Menu Dropdown */
.user-menu {
	position: relative;
}

.user-menu .rounded-full {
	border: 2px solid #e5e7eb;
}

/* =================================================================
   FOOTER
   ================================================================= */

.site-footer {
	margin-top: auto;
}

.footer-widget-area h3 {
	font-size: 1.125rem;
	font-weight: 600;
	margin-bottom: 1rem;
	color: #1f2937;
}

.footer-widget-area ul {
	list-style: none;
	margin: 0;
	padding: 0;
}

.footer-widget-area ul li {
	margin-bottom: 0.5rem;
}

.footer-widget-area a {
	color: #6b7280;
	text-decoration: none;
	transition: color 0.2s;
}

.footer-widget-area a:hover {
	color: var(--cce-primary);
}

.footer-navigation ul {
	list-style: none;
	margin: 0;
	padding: 0;
}

.footer-navigation a {
	color: #6b7280;
	text-decoration: none;
	transition: color 0.2s;
}

.footer-navigation a:hover {
	color: var(--cce-primary);
}

/* =================================================================
   PAGINACIÓN
   ================================================================= */

.pagination {
	display: flex;
	justify-content: center;
	gap: 0.5rem;
	list-style: none;
	margin: 0;
	padding: 0;
}

.pagination .page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 2.5rem;
	height: 2.5rem;
	padding: 0.5rem;
	border: 1px solid #e5e7eb;
	border-radius: 0.5rem;
	color: #4b5563;
	text-decoration: none;
	transition: all 0.2s;
}

.pagination .page-numbers:hover {
	background-color: var(--cce-primary);
	border-color: var(--cce-primary);
	color: #ffffff;
}

.pagination .page-numbers.current {
	background-color: var(--cce-primary);
	border-color: var(--cce-primary);
	color: #ffffff;
}

.pagination .page-numbers.dots {
	border: none;
	pointer-events: none;
}

/* =================================================================
   BREADCRUMBS
   ================================================================= */

.breadcrumbs a {
	text-decoration: none;
}

/* =================================================================
   SIDEBAR ESTUDIANTE
   ================================================================= */

.sidebar-estudiante {
	transition: transform 0.3s ease;
}

@media (max-width: 1023px) {
	.sidebar-estudiante {
		transform: translateX(-100%);
	}

	.sidebar-estudiante.open {
		transform: translateX(0);
	}
}

.sidebar-overlay {
	position: fixed;
	inset: 0;
	background-color: rgba(0, 0, 0, 0.5);
	z-index: 30;
	display: none;
}

.sidebar-overlay.show {
	display: block;
}

/* =================================================================
   CARDS DE CAPACITACIÓN
   ================================================================= */

.capacitacion-card {
	position: relative;
	overflow: hidden;
}

.capacitacion-card img {
	transition: transform 0.3s ease;
}

.capacitacion-card:hover img {
	transform: scale(1.05);
}

.capacitacion-badge {
	position: absolute;
	top: 1rem;
	right: 1rem;
	z-index: 10;
}

/* =================================================================
   CALENDARIO (FULLCALENDAR)
   ================================================================= */

.fc {
	border: 1px solid #e5e7eb;
	border-radius: 0.75rem;
	overflow: hidden;
}

.fc .fc-toolbar-title {
	font-size: 1.5rem;
	font-weight: 700;
	color: var(--cce-primary);
}

.fc .fc-button {
	background-color: var(--cce-primary);
	border-color: var(--cce-primary);
}

.fc .fc-button:hover {
	background-color: var(--cce-primary-dark);
	border-color: var(--cce-primary-dark);
}

.fc .fc-button-active {
	background-color: var(--cce-primary-dark);
}

.fc-event {
	background-color: var(--cce-primary);
	border-color: var(--cce-primary);
	cursor: pointer;
}

.fc-event:hover {
	background-color: var(--cce-primary-dark);
}

/* =================================================================
   LOADING STATES
   ================================================================= */

.loading-spinner {
	border: 3px solid #f3f4f6;
	border-top-color: var(--cce-primary);
	border-radius: 50%;
	width: 2rem;
	height: 2rem;
	animation: spin 0.6s linear infinite;
}

@keyframes spin {
	to {
		transform: rotate(360deg);
	}
}

.skeleton {
	background: linear-gradient(90deg, #f3f4f6 25%, #e5e7eb 50%, #f3f4f6 75%);
	background-size: 200% 100%;
	animation: loading 1.5s infinite;
}

@keyframes loading {
	0% {
		background-position: 200% 0;
	}
	100% {
		background-position: -200% 0;
	}
}

/* =================================================================
   RESPONSIVE
   ================================================================= */

@media (max-width: 768px) {
	:root {
		--cce-font-size: 14px;
	}

	h1 {
		font-size: 2rem;
	}

	h2 {
		font-size: 1.75rem;
	}

	h3 {
		font-size: 1.5rem;
	}
}

/* =================================================================
   UTILIDADES
   ================================================================= */

.hover-lift {
	transition: transform 0.2s ease;
}

.hover-lift:hover {
	transform: translateY(-4px);
}

.fade-in {
	animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
	from {
		opacity: 0;
	}
	to {
		opacity: 1;
	}
}

.slide-up {
	animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
	from {
		transform: translateY(20px);
		opacity: 0;
	}
	to {
		transform: translateY(0);
		opacity: 1;
	}
}

/* =================================================================
   ACCESIBILIDAD
   ================================================================= */

.sr-only {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border-width: 0;
}

.skip-link {
	position: absolute;
	top: -40px;
	left: 0;
	background: var(--cce-primary);
	color: #ffffff;
	padding: 0.5rem 1rem;
	text-decoration: none;
	z-index: 100;
}

.skip-link:focus {
	top: 0;
}

/* Focus visible para navegación por teclado */
*:focus-visible {
	outline: 2px solid var(--cce-primary);
	outline-offset: 2px;
}

button:focus-visible,
a:focus-visible {
	outline: 2px solid var(--cce-primary);
	outline-offset: 2px;
}
