/* Home page styles: layout for carousel+links, events grid, news grid */

/* Page background and overall page width (home) */
body {
    background: linear-gradient(180deg, #f5f7fa 0%, #eef2f6 100%);
    color: #333;
}

/* Limit page content to ~80% width and center */
.home-main.container {
    width: 80%;
    max-width: 1200px;
    margin: 0 auto;
}

/* Hero inner container (also 80% and centered) */
.hero-inner {
    width: 80%;
    max-width: 1200px;
    margin: 0 auto;
}

.home-main {
    padding: 40px 20px;
}

/* Hero section */
.hero-section {
    background-size: cover;
    background-position: center;
    padding: 80px 0;
    color: white;
}

/* .hero-section::before {  Overlay oscuro
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.35);
    z-index: 0;  Asegura que el overlay esté detrás del contenido
} */

.hero-inner .hero-content {
    position: relative;
    z-index: 2;
}

.hero-content h1 {
    font-size: 44px;
    margin: 0 0 8px 0;
}
.hero-content p {
    font-size: 18px;
    margin: 0 0 16px 0;
}

.btn-primary, .btn-secondary {
    display: inline-block;
    padding: 10px 14px;
    border-radius: 6px;
    text-decoration: none;
    color: white;
}

.btn-primary { background: #9c27b0; }
.btn-secondary { background: rgba(255,255,255,0.12); border: 1px solid rgba(255,255,255,0.18); }

/* BLOQUE 1 */
.top-block {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 24px;
    margin-bottom: 40px;
    align-items: start;
}

.carousel {
    position: relative;
    height: 360px;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 6px 20px rgba(0,0,0,0.12);
}
.carousel-track {
    display: flex;
    height: 100%;
    transition: transform 0.5s ease;
}
.carousel-item {
    min-width: 100%;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: flex-end;
}
.carousel-caption {
    background: linear-gradient(180deg, rgba(0,0,0,0) 0%, rgba(0,0,0,0.6) 100%);
    color: white;
    padding: 20px;
    width: 100%;
}
.carousel-prev, .carousel-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,0.35);
    color: white;
    border: none;
    font-size: 28px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    cursor: pointer;
}
.carousel-prev { left: 12px; }
.carousel-next { right: 12px; }

.links-col .links-box {
    background: #fff;
    border-radius: 8px;
    padding: 18px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
}
.links-box h4 { margin-top: 0; }
.links-box ul { list-style: none; padding: 0; margin: 10px 0 0 0; }
.links-box li { margin-bottom: 8px; }
.links-box a { color: #1a73e8; text-decoration: none; }

/* BLOQUE 2: Events grid */
.events-block { margin: 40px 0; }
.events-block h2 { margin-bottom: 16px; }
.events-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
}
.event-card {
    background: #fff;
    padding: 14px;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.04);
}

/* BLOQUE 3: News grid */
.more-news-block { margin: 40px 0; }
.news-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.news-card { background: #fff; border-radius: 8px; overflow: hidden; box-shadow: 0 6px 18px rgba(0,0,0,0.06); }
.news-card img { width: 100%; height: 140px; object-fit: cover; display: block; }
.news-card h4 { margin: 12px; }
.news-card p { margin: 0 12px 12px 12px; color: #444; font-size: 14px; }

/* Responsive */
@media (max-width: 992px) {
    .top-block { grid-template-columns: 1fr; }
    .events-grid { grid-template-columns: repeat(2, 1fr); }
    .news-grid { grid-template-columns: repeat(2, 1fr); }
    .carousel { height: 260px; }
}

@media (max-width: 600px) {
    .events-grid { grid-template-columns: 1fr; }
    .news-grid { grid-template-columns: 1fr; }
    .carousel { height: 200px; }
}

.carousel-link-overlay {
    text-decoration: none;
    display: flex;
    align-items: flex-end;
    width: 100%;
    height: 100%;
}

.carousel-item {
    cursor: pointer;
    transition: transform 0.3s ease;
}

.carousel-item:hover .carousel-caption {
    background: linear-gradient(180deg, rgba(0,0,0,0) 0%, rgba(0,0,0,0.8) 100%);
}

.interest-links {
    list-style: none; /* Quita los puntos por defecto */
    padding: 0;
    margin: 15px 0;
}

/* Cada ítem de la lista */
.interest-links li {
    margin-bottom: 8px;
    border-bottom: 1px solid #f1f5f9; /* Línea divisoria sutil */
    padding-bottom: 8px;
}

/* Estilo del enlace */
.interest-links a {
    color: #9c27b0; /* El púrpura de la Municipalidad */
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    display: inline-block;
    transition: all 0.2s ease;
}

/* Efecto al pasar el mouse */
.interest-links a:hover {
    color: #1a2a40; /* Cambia al azul oscuro */
    transform: translateX(5px); /* Se mueve levemente a la derecha */
}

/* Opcional: Agregar una pequeña flecha antes del texto */
.interest-links a::before {
    content: "→";
    margin-right: 8px;
    font-weight: bold;
}