body {
    font-family: 'Roboto', sans-serif;
    line-height: 1.6;
    color: #333;
    margin: 0;
    padding: 0;
}

.contenido-detalle {
    max-width: 900px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.contenido-header {
    margin-bottom: 3rem;
    text-align: center;
    padding: 2rem;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 15px;
}

.contenido-header h1 {
    margin: 1rem 0;
    color: #2c3e50;
    font-size: 2.5rem;
    line-height: 1.2;
}

.meta-info {
    color: #7f8c8d;
    font-size: 1rem;
    margin-top: 1rem;
}

.meta-info time {
    display: inline-block;
    margin-right: 1rem;
}

.contenido-imagen-principal {
    margin: 3rem 0;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.contenido-imagen-principal img {
    width: 100%;
    height: auto;
    min-height: 400px;
    max-height: 600px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.contenido-imagen-principal:hover img {
    transform: scale(1.02);
}

.contenido-texto {
    line-height: 1.8;
    margin-bottom: 3rem;
    font-size: 1.1rem;
    color: #2c3e50;
    text-align: justify;
}

.contenido-texto p {
	margin-bottom: 1.5rem;
}

.contenido-texto h2, .contenido-texto h3 {
    color: #2c3e50; margin-top: 2rem; margin-bottom: 1rem;
}

.galeria {
    margin: 4rem 0;
    padding: 2rem;
    background: #f8f9fa;
    border-radius: 15px;
}

.galeria h3 {
    margin-bottom: 2rem;
    color: #2c3e50;
    font-size: 1.5rem;
    text-align: center;
}

.galeria-miniaturas {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 1rem;
}

.miniatura-container {
    cursor: pointer;
    transition: transform 0.3s ease;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.miniatura-container:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.miniatura-container img {
    width: 100%;
    height: 120px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.miniatura-container:hover img {
    transform: scale(1.1);
}

.galeria-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    backdrop-filter: blur(5px);
}

.galeria-popup-contenido {
    position: relative;
    max-width: 90%;
    max-height: 90%;
    border-radius: 15px;
    overflow: hidden;
}

.cerrar-popup {
    position: absolute;
    top: -50px;
    right: 0;
    color: white;
    font-size: 2.5rem;
    cursor: pointer;
    background: rgba(0, 0, 0, 0.5);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s ease;
}

.cerrar-popup:hover {
    background: rgba(0, 0, 0, 0.8);
}

.imagen-popup {
    max-width: 100%;
    max-height: 80vh;
    display: block;
    margin: 0 auto;
    border-radius: 10px;
}

.galeria-controls {
    position: absolute;
    top: 50%;
    width: 100%;
    display: flex;
    justify-content: space-between;
    transform: translateY(-50%);
    padding: 0 20px;
}

.galeria-controls button {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    font-size: 2rem;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    cursor: pointer;
    transition: background 0.3s ease;
    backdrop-filter: blur(0px);
}

.galeria-controls button:hover {
    background: rgba(255, 255, 255, 0.4);
}

.galeria-info {
    text-align: center;
    margin-top: 1rem;
}


.descargar-imagen {
    color: white;
    text-decoration: none;
    background: #3498db;
    padding: 0.8rem 1.5rem;
    border-radius: 8px;
    display: inline-block;
    font-weight: 500;
    transition: background-color 0.3s ease;
}

.descargar-imagen:hover {
    background: #2980b9;
}

.noticias-recientes {
    max-width: 1200px;
	margin: 2rem auto;
	padding: 0 1rem;
}

.noticias-recientes .seccion-titulo {
    text-align: center;
	margin-bottom: 2rem;
	color: #2c3e50;
}

.noticias-recientes .noticias-grid {
    display: grid;
	grid-template-columns: 2fr 1fr 1fr;
	grid-template-rows: 200px 200px;
	gap: 1rem;
	height: 400px;
}

.noticias-recientes .noticia-tarjeta:first-child {
    grid-column: 1 / 2;
	grid-row: 1 / 3;
}

.noticias-recientes .noticia-tarjeta {
    background: white; border-radius: 8px;
	overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
	flex-direction: column;
}

.noticias-recientes .noticia-tarjeta:hover {
    transform: translateY(-5px);
	box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.noticias-recientes .noticia-tarjeta a {
    display: flex;
	flex-direction: column;
	height: 100%;
	text-decoration: none;
	color: inherit;
}

.noticias-recientes .noticia-imagen-container {
    position: relative;
	width: 100%;
	flex-shrink: 0;
	overflow: hidden;
    height: 60%;
}

.noticias-recientes .noticia-tarjeta:first-child .noticia-imagen-container {
    height: 65%;
}

.noticias-recientes .noticia-imagen-principal,
.noticias-recientes .noticia-imagen-secundaria {
    position: absolute;
	top: 0; left: 0;
	width: 100%;
	height: 100%;
    object-fit: cover;
	object-position: center center;
    transition: opacity 0.5s ease;
}

.noticias-recientes .noticia-imagen-secundaria {
	opacity: 0;
}

.noticias-recientes .noticia-tarjeta:hover .noticia-imagen-principal {
	opacity: 0;
}

.noticias-recientes .noticia-tarjeta:hover .noticia-imagen-secundaria {
	opacity: 1;
}

.noticias-recientes .noticia-info {
    padding: 1rem;
	background: white;
	flex-grow: 1;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
}

.noticias-recientes .noticia-info h3 {
    margin: 0 0 0.5rem 0;
	font-size: 0.6rem;
	color: #2c3e50;
	line-height: 1.3;
    display: -webkit-box; -webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
	font-weight: 600;
    flex-grow: 1;
}

.noticias-recientes .noticia-tarjeta:first-child .noticia-info h3 {
	font-size: 1.2rem;
}

.noticias-recientes .noticia-info time {
    font-size: 0.75rem;
	color: #7f8c8d;
	margin-top: auto;
	flex-shrink: 0;
	font-weight: 500;
}

.ver-mas-container { 
	text-align: center;
	margin-top: 2rem;
}

.ver-mas-btn {
	display: inline-block; 
	padding: 0.75rem 1.5rem;
	background-color: #3498db;
	color: white;
	text-decoration: none;
	border-radius: 4px;
	transition: background-color 0.3s ease; 
}

.ver-mas-btn:hover {
	background-color: #2980b9;
	color: white; 
}

.contenedor-noticias {
	max-width: 1200px;
	margin: 2rem auto;
	padding: 0 1rem;
}

.filtros-container {
	display: flex;
	flex-wrap: wrap;
	gap: 1rem;
	align-items: flex-end;
	justify-content: space-between;
	margin-bottom: 2rem;
}

.categorias-tabs {
	display: flex;
	gap: 0.5rem;
	flex-wrap: wrap;
}

.categoria-tab {
	padding: 0.6rem 1rem;
	background: #ecf0f1;
	border: none;
	border-radius: 4px;
	cursor: pointer;
	transition: background-color 0.3s ease;
}

.categoria-tab.active {
	background: #3498db;
	color: white;
}

.contenidos-listado {
	display: grid;
	grid-template-columns: 1fr;
	gap: 2rem;
}

.contenido-resumen {
    background: white; border-radius: 12px;
	overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.contenido-resumen:hover {
	transform: translateY(-5px);
	box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.contenido-resumen a {
	display: grid;
	grid-template-columns: 300px 1fr;
	text-decoration: none;
	color: inherit;
	height: 100%;
}

.contenido-resumen img {
    width: 100%;
    height: 260px;
    object-fit: cover;
    object-position: center center;
    transition: transform 0.3s ease;
}

.contenido-resumen:hover img {
    transform: scale(1.05);
}
.contenido-info { padding: 2rem; display: flex; flex-direction: column; }
.categoria-badge { display: inline-block; padding: 0.4rem 0.8rem; background: #3498db; color: white; border-radius: 6px; font-size: 0.8rem; font-weight: 500; margin-bottom: 1rem; align-self: flex-start; }
.contenido-info h2 { margin: 0 0 1rem; color: #2c3e50; font-size: 1.4rem; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.resumen { margin: 0 0 1.5rem; color: #7f8c8d; line-height: 1.6; flex-grow: 1; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.contenido-info time { display: block; font-size: 0.9rem; color: #95a5a6; font-weight: 500; margin-top: auto; }

.filtros-form .filtrar-btn {
    padding: 0.6rem 1.2rem !important;
    border-radius: 4px !important; border: none !important; background-color: var(--theme-color) !important;
    color: white !important; font-weight: 500 !important; cursor: pointer !important;
    
}
.filtros-form .filtrar-btn:hover { background-color: var(--jmas-cyan) !important; }
.filtros-form {
  display: flex !important;
  gap: 0.8rem !important;
  align-items: center !important;
}

.filtros-form .form-group {
  margin: 0 !important;
  padding: 0 !important;
  display: flex;
  align-items: center;
}

.filtros-form .form-control,
.filtros-form input[type="date"] {
  height: 42px !important;
  min-height: 42px !important;
  padding: 0.6rem 0.8rem !important;
  line-height: 1 !important;
  box-sizing: border-box !important;
}

.filtros-form .filtrar-btn {
  height: 42px !important;
  min-height: 42px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}

.filtros-container { align-items: center; }

.filtros-form .form-control:focus,
.filtros-form input[type="date"]:focus {
  background-color: #fff !important;
  border-color: var(--theme-color) !important;
  outline: none !important;
  box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.25) !important;
  transition: background-color 0.2s ease, box-shadow 0.2s ease;
}

@media (max-width: 1024px) {
    .noticias-recientes .noticias-grid { grid-template-columns: 1fr 1fr; grid-template-rows: auto; height: auto; }
    .noticias-recientes .noticia-tarjeta { height: auto; }
    .noticias-recientes .noticia-tarjeta:first-child { grid-column: 1 / 3; }
    .noticias-recientes .noticia-tarjeta:nth-child(n+4) { display: none; }
    .noticias-recientes .noticia-imagen-container { aspect-ratio: 16/9; height: auto; }
}

@media (max-width: 768px) {
    .noticias-recientes .noticias-grid { grid-template-columns: 1fr; }
    .noticias-recientes .noticia-tarjeta:first-child { grid-column: 1 / 2; }
    .contenido-resumen a { grid-template-columns: 1fr; }
    .contenido-resumen img { height: 200px; }
    .filtros-container { flex-direction: column; align-items: stretch; }
    .categorias-tabs, .filtros-form { justify-content: center; }
    .contenido-header h1 { font-size: 2rem; }
}

@media (max-width: 480px) {
    .filtros-form { flex-direction: column; width: 100%; }
    .filtros-form .form-control, .filtros-form button { width: 100%; }
    .contenido-header h1 { font-size: 1.5rem; }
    .contenido-texto { font-size: 1rem; }
}

.social-embed-container {
	display: flex;
	justify-content: center;
	width: 100%;
	margin: 30px 0;
}