/* =====================================================
   PÁGINA PRINCIPAL — MUNICIPIO DE HUICHAPAN
   index.css
   ===================================================== */

/* ── RESET ──────────────────────────────────────────── */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* ── VARIABLES ──────────────────────────────────────── */
:root {
    --primary:      #961637;
    --primary-dark: #c1905e;
    --gold:         #BFA184;
    --dark:         #1a1a1a;
    --mid:          #444444;
    --muted:        #888888;
    --light:        #f7f7f7;
    --white:        #ffffff;
    --border:       rgba(0, 0, 0, 0.08);
    --radius:       6px;
    --radius-lg:    12px;
    --shadow:       0 4px 24px rgba(0, 0, 0, 0.07);
    --shadow-hover: 0 12px 36px rgba(0, 0, 0, 0.12);
}
@font-face {
  font-family: 'SuperStarfish';
  src: url('fonts/SuperStarfish.ttf') format('truetype');
}
@font-face {
  font-family: 'GoodMatcha';
  src: url('fonts/GoodMatcha.otf') format('truetype');
}
/* ── BASE ───────────────────────────────────────────── */
body {
    font-family: 'Poppins', sans-serif;
    background: #ffffff;
    color: var(--dark);
}

/* ── BOTONES GLOBALES ───────────────────────────────── */
.idx-btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    background: var(--primary);
    color: #fff;
    border-radius: 50px;
    font-family: 'Poppins', sans-serif;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    text-decoration: none;
    transition: background 0.25s ease,
                transform 0.2s ease,
                box-shadow 0.25s ease;
}

.idx-btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(119, 23, 47, 0.35);
}

.idx-btn-outline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 11px 28px;
    background: transparent;
    color: #fff;
    border: 1.5px solid rgba(255, 255, 255, 0.5);
    border-radius: 50px;
    font-family: 'Poppins', sans-serif;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    text-decoration: none;
    transition: background 0.25s ease,
                border-color 0.25s ease,
                transform 0.2s ease;
}

.idx-btn-outline:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: #fff;
    transform: translateY(-2px);
}

/* ── ESTRUCTURA DE SECCIONES ────────────────────────── */
.idx-section {
    padding: 72px 80px;
}

.idx-section-inner {
    max-width: 1200px;
    margin: 0 auto;
}

.idx-section-header {
    margin-bottom: 48px;
}

.idx-section-sup {
    font-size: 9.5px;
    font-weight: 600;
    letter-spacing: 0.32em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.idx-section-sup::before {
    content: '';
    width: 28px;
    height: 1px;
    background: var(--gold);
    opacity: 0.6;
    display: inline-block;
}

.idx-section-title {
    font-family: 'GoodMatcha', sans-serif;
    font-size: clamp(1.6rem, 3vw, 2.4rem);
    font-weight: 900;
    color: var(--dark);
    line-height: 1.15;
    letter-spacing: -0.02em;
    margin-bottom: 12px;
}

.idx-section-desc {
    font-size: 14px;
    color: var(--muted);
    line-height: 1.7;
    max-width: 560px;
}

/* =====================================================
   COMPENSACIÓN PARA HEADER FIJO DEL MENÚ (70px)
   ===================================================== 
.idx-hero {
    margin-top: 70px;
}
*/
/* El menú de secciones debe pegarse DEBAJO del header fijo */
.idx-secnav {
    top: 70px;
}

/* =====================================================
   HERO PRINCIPAL + SLIDER INTEGRADO
   ===================================================== */
.idx-hero {
    position: relative;
    display: flex;
    align-items: center;
    padding: 80px 80px 80px;
    overflow: visible;          /* NO hidden — evita cortar título por arriba */
    background-color: #0e0309;
    isolation: isolate;         /* contiene el stacking context del hero */
}

/* min-height SOLO en desktop */
@media (min-width: 901px) {
    .idx-hero {
        min-height: clamp(480px, 88vh, 92vh);
    }
}

/* Fondo con imagen — confinado con clip-path para no salir del hero */
.idx-hero-bg {
    position: absolute;
    inset: 0;
    background-image: url('https://www.huichapan.gob.mx/images/huichapan.jpg');
    background-size: cover;
    background-position: center 30%;
    opacity: 0.32;
    z-index: 0;
    clip-path: inset(0);        /* contiene el fondo sin afectar al overflow del padre */
}

/* Gradiente oscuro — también confinado */
.idx-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        135deg,
        rgba(10, 2, 5, 0.94) 0%,
        rgba(119, 23, 47, 0.42) 55%,
        rgba(10, 2, 5, 0.70) 100%
    );
    z-index: 1;
}

/* Línea decorativa izquierda */
.idx-hero::after {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, var(--primary) 0%, var(--gold) 100%);
    z-index: 2;
}

/* ── Layout dos columnas ── */
.idx-hero-inner {
    position: relative;
    z-index: 3;
    width: 100%;
    max-width: 1160px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 560px;
    gap: 48px;
    align-items: center;
}

/* ── Columna izquierda: contenido ── */
.idx-hero-content {
    animation: heroFadeIn 0.9s ease both;
}

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

.idx-hero-sup {
    font-size: 9.5px;
    font-weight: 600;
    letter-spacing: 0.36em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.idx-hero-sup::before {
    content: '';
    width: 32px;
    height: 1px;
    background: var(--gold);
    opacity: 0.5;
    display: inline-block;
}

.idx-hero-title {
    font-family: 'Montserrat', sans-serif;
    font-size: clamp(2.2rem, 5vw, 3.4rem);
    font-weight: 900;
    color: #fff;
    line-height: 1.0;
    letter-spacing: -0.03em;
    margin-bottom: 24px;
}

.idx-hero-title span {
    color: var(--gold);
    display: block;
}

.idx-hero-desc {
    font-size: 15px;
    font-weight: 300;
    color: rgba(255, 255, 255, 0.62);
    line-height: 1.8;
    max-width: 460px;
    margin-bottom: 40px;
}

.idx-hero-actions {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
}

/* =====================================================
   TARJETA-SLIDER DENTRO DEL HERO
   ===================================================== */
.idx-hero-slider-card {
    position: relative;
    background: rgba(255, 255, 255, 0.055);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.13);
    border-radius: 18px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    animation: heroFadeIn 0.9s 0.25s ease both;
    /* Sombra elegante con tinte primario */
    box-shadow:
        0 24px 64px rgba(0, 0, 0, 0.45),
        0 0 0 1px rgba(191, 161, 132, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.07);
}

/* ── Barra de progreso en la parte superior ── */
.idx-hsc-progress {
    position: absolute;
    top: 0;
    left: 0;
    height: 2px;
    width: 0%;
    background: linear-gradient(90deg, var(--primary), var(--gold));
    z-index: 10;
    border-radius: 0 2px 0 0;
    transition: none;
}

/* ── Track: altura fija, todos los slides absolutamente posicionados ── */
.idx-hsc-track {
    position: relative;
    height: 360px;   /* altura fija — todos los slides se apilan aquí */
    flex-shrink: 0;
}

.idx-hsc-slide {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.55s ease;
    overflow: hidden;
}

.idx-hsc-slide.is-active {
    opacity: 1;
    pointer-events: all;
}

/* ── Visual superior ── */
.idx-hsc-visual {
    width: 100%;
    height: 185px;
    overflow: hidden;
    flex-shrink: 0;
    position: relative;
}

/* Foto */
.idx-hsc-visual img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: transform 0.6s ease;
}

.idx-hsc-slide.is-active:hover .idx-hsc-visual img {
    transform: scale(1.04);
}

/* Degradado sobre la foto */
.idx-hsc-visual::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 60%;
    background: linear-gradient(transparent, rgba(5, 1, 3, 0.72));
    pointer-events: none;
}

/* Icono / ilustración SVG */
.idx-hsc-visual--icon {
    background: linear-gradient(145deg, rgba(119,23,47,0.22) 0%, rgba(10,2,5,0.6) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.idx-hsc-visual--icon::after {
    display: none;
}

.idx-hsc-visual--icon svg {
    width: 88px;
    height: 88px;
    opacity: 0.92;
    filter: drop-shadow(0 4px 16px rgba(119,23,47,0.35));
}

/* ── Cuerpo del slide ── */
.idx-hsc-body {
    padding: 20px 24px 4px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
}

.idx-hsc-tag {
    display: inline-block;
    font-size: 8px;
    font-weight: 700;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--gold);
    background: rgba(191, 161, 132, 0.12);
    border: 1px solid rgba(191, 161, 132, 0.2);
    border-radius: 4px;
    padding: 3px 9px;
    align-self: flex-start;
}

.idx-hsc-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 17px;
    font-weight: 800;
    color: #ffffff;
    line-height: 1.25;
    letter-spacing: -0.01em;
}

.idx-hsc-text {
    font-size: 12.5px;
    color: rgba(255, 255, 255, 0.58);
    line-height: 1.65;
}

.idx-hsc-text strong {
    color: rgba(255, 255, 255, 0.82);
    font-weight: 600;
}

/* ── Botones de acción del slide ── */
.idx-hsc-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 4px;
    padding-bottom: 4px;
}

.idx-hsc-btn {
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.75);
    text-decoration: none;
    padding: 6px 13px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 50px;
    transition: background 0.2s ease,
                color 0.2s ease,
                border-color 0.2s ease;
    white-space: nowrap;
}

.idx-hsc-btn:hover {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

/* ── Navegación inferior ── */
.idx-hsc-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 24px 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.07);
    background: rgba(0, 0, 0, 0.18);
}

.idx-hsc-nav-btn {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.16);
    background: rgba(255, 255, 255, 0.06);
    color: rgba(255, 255, 255, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s ease,
                color 0.2s ease,
                border-color 0.2s ease;
    flex-shrink: 0;
}

.idx-hsc-nav-btn:hover {
    background: rgba(255, 255, 255, 0.14);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.35);
}

.idx-hsc-dots {
    display: flex;
    gap: 6px;
    align-items: center;
}

.idx-hsc-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.25);
    cursor: pointer;
    padding: 0;
    transition: background 0.25s ease,
                transform 0.25s ease,
                width 0.25s ease;
}

.idx-hsc-dot.is-active {
    background: var(--gold);
    width: 18px;
    border-radius: 3px;
    transform: none;
}

/* =====================================================
   SECCIÓN UNIFICADA: HORARIOS + CLIMA + FACEBOOK
   ===================================================== */
.idx-info-section {
    background: var(--light);
    padding: 64px 80px;
}
.idx-info-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: stretch;
}
.idx-info-left {
    display: flex;
    flex-direction: column;
    gap: 36px;
}
.idx-info-block { display: flex; flex-direction: column; }
.idx-info-block-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
}
.idx-info-block-head--simple { display: block; margin-bottom: 20px; }

/* Typography reutilizada */
.idx-horarios-sup {
    font-size: 9.5px;
    font-weight: 600;
    letter-spacing: 0.32em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 12px;
}
.idx-horarios-sup::before {
    content: '';
    width: 28px; height: 1px;
    background: var(--gold); opacity: 0.6;
    display: inline-block;
}
.idx-horarios-h2 {
    font-family: 'GoodMatcha', sans-serif;
    font-size: clamp(1.2rem, 2.2vw, 1.7rem);
    font-weight: 900;
    color: var(--dark);
    letter-spacing: -0.02em;
    line-height: 1.1;
}

/* Horarios grid */
.idx-horarios-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}
/* Emergencias ocupa el ancho completo */
.idx-horarios-grid .idx-hora-card:last-child {
    grid-column: span 2;
}
/* Emergencias en horizontal */
.idx-horarios-grid .idx-hora-card:last-child .idx-hora-body {
    flex-direction: row;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 14px;
    min-height: auto;
    padding: 14px 20px;
}
.idx-hora-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.idx-hora-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-hover); }
.idx-hora-head {
    background: var(--primary);
    padding: 12px 16px;
    display: flex; align-items: center; gap: 8px;
}
.idx-hora-head svg { color: var(--gold); flex-shrink: 0; }
.idx-hora-head-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 11.5px; font-weight: 800; color: #fff; letter-spacing: 0.03em;
}
.idx-hora-body {
    padding: 16px 12px;
    display: flex; flex-direction: column; gap: 9px;
    min-height: 120px; justify-content: center;
    align-items: center; text-align: center;
}
.idx-hora-sep {
    width: 26px; height: 2px;
    background: linear-gradient(90deg, var(--primary), var(--gold));
    border-radius: 2px;
}
.idx-hora-range {
    font-family: 'Montserrat', sans-serif;
    font-size: 15px; font-weight: 700; color: var(--dark); line-height: 1.2;
}
.idx-hora-badge {
    display: inline-flex; align-items: center; gap: 5px;
    font-size: 10px; font-weight: 700; letter-spacing: 0.07em;
    text-transform: uppercase; padding: 4px 11px; border-radius: 50px;
}
.idx-hora-badge--open   { background: rgba(34, 197, 94, 0.12); color: #16a34a; }
.idx-hora-badge--closed { background: rgba(100, 116, 139, 0.1); color: #64748b; }
.idx-hora-badge--always { background: rgba(34, 197, 94, 0.12); color: #16a34a; }
.idx-hora-badge .dot {
    width: 6px; height: 6px; border-radius: 50%;
    background: currentColor;
    animation: pulse-dot 1.8s ease-in-out infinite;
}
@keyframes pulse-dot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%       { opacity: .5; transform: scale(.7); }
}
.idx-countdown {
    font-family: 'Montserrat', sans-serif;
    font-size: 11.5px; font-weight: 600; color: var(--primary);
    background: rgba(119, 23, 47, 0.07);
    border-radius: 50px; padding: 4px 12px; text-align: center;
}
.idx-hora-cta {
    display: inline-flex; align-items: center; gap: 5px;
    margin-top: 2px; padding: 6px 14px;
    background: var(--primary); color: #fff; border-radius: 50px;
    font-size: 9.5px; font-weight: 600; letter-spacing: 0.1em;
    text-transform: uppercase; text-decoration: none;
    transition: background 0.25s ease, transform 0.2s ease;
}
.idx-hora-cta:hover { background: var(--primary-dark); transform: translateY(-1px); }

/* ── Clima ── */
.idx-clima-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    display: flex; flex-direction: column;
    box-shadow: var(--shadow);
    flex: 1;
}
.idx-clima-loading {
    display: flex; flex-direction: column; align-items: center;
    justify-content: center; gap: 12px; padding: 40px 20px;
    color: var(--muted); font-size: 13px; flex: 1;
}
.idx-clima-spinner {
    width: 24px; height: 24px;
    border: 2.5px solid var(--border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.idx-clima-error {
    display: flex; flex-direction: column; align-items: center;
    justify-content: center; gap: 10px; padding: 40px 20px;
    color: var(--muted); font-size: 13px; text-align: center; flex: 1;
}
.idx-clima-error svg { color: #e2a04a; opacity: 0.7; }
.idx-clima-content { flex: 1; display: flex; flex-direction: column; }
.idx-clima-hoy {
    padding: 14px 20px;
    background: linear-gradient(135deg, var(--primary) 0%, #a02040 100%);
    color: #fff;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 14px;
    flex-wrap: nowrap;
}
.idx-clima-icon { font-size: 30px; line-height: 1; flex-shrink: 0; }
.idx-clima-temp-wrap {
    display: flex; align-items: flex-start; gap: 1px;
    line-height: 1; flex-shrink: 0;
}
.idx-clima-temp {
    font-family: 'Montserrat', sans-serif;
    font-size: 32px; font-weight: 900;
    letter-spacing: -0.04em; line-height: 1;
}
.idx-clima-unit {
    font-family: 'Montserrat', sans-serif;
    font-size: 14px; font-weight: 600; margin-top: 4px; opacity: 0.75;
}
.idx-clima-hoy-info {
    display: flex; flex-direction: column; gap: 3px;
    flex: 1; min-width: 0;
}
.idx-clima-desc {
    font-size: 12px; font-weight: 600; opacity: 0.92;
    text-transform: capitalize;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.idx-clima-meta {
    display: flex; flex-wrap: wrap; gap: 8px;
    font-size: 10px; opacity: 0.80;
}
.idx-clima-meta span { display: flex; align-items: center; gap: 3px; white-space: nowrap; }
.idx-clima-forecast {
    display: grid; grid-template-columns: repeat(3, 1fr);
    border-top: 1px solid var(--border);
}
.idx-clima-day {
    display: flex; flex-direction: column; align-items: center;
    gap: 5px; padding: 14px 10px;
    border-right: 1px solid var(--border);
}
.idx-clima-day:last-child { border-right: none; }
.idx-clima-day-name {
    font-size: 9px; font-weight: 700; letter-spacing: 0.1em;
    text-transform: uppercase; color: var(--muted);
}
.idx-clima-day-icon { font-size: 22px; line-height: 1; }
.idx-clima-day-range {
    display: flex; gap: 5px;
    font-family: 'Montserrat', sans-serif; font-size: 12px;
}
.idx-clima-day-range b  { color: var(--dark); font-weight: 700; }
.idx-clima-day-range em { color: var(--muted); font-style: normal; }

/* ── Facebook (columna derecha — altura completa) ── */
.idx-info-right {
    display: flex; flex-direction: column;
}
.idx-fb-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    display: flex; flex-direction: column;
    box-shadow: var(--shadow);
    flex: 1;
}
.idx-fb-plugin {
    flex: 1; overflow: hidden; line-height: 0;
    min-height: 540px;
}
.idx-fb-plugin iframe {
    width: 100% !important;
    height: 100% !important;
    min-height: 540px;
    border: none; display: block;
}
.idx-fb-cta {
    display: flex; align-items: center; justify-content: center;
    gap: 8px; padding: 14px 20px;
    background: #1877f2; color: #fff;
    font-size: 11px; font-weight: 700; letter-spacing: 0.08em;
    text-transform: uppercase; text-decoration: none;
    transition: background 0.22s ease; flex-shrink: 0;
}
.idx-fb-cta:hover { background: #1464d2; }

/* =====================================================
   ACCESOS RÁPIDOS
   ===================================================== */
.idx-accesos {
    background: var(--light);
}

.idx-accesos-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.idx-acceso-card {
    display: flex;
    align-items: center;
    gap: 16px;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px 18px;
    text-decoration: none;
    color: var(--dark);
    transition: transform 0.25s ease,
                box-shadow 0.25s ease,
                border-color 0.25s ease;
    position: relative;
    overflow: hidden;
}

.idx-acceso-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 3px; height: 100%;
    background: linear-gradient(180deg, var(--primary) 0%, var(--gold) 100%);
    transform: scaleY(0);
    transform-origin: top;
    transition: transform 0.3s ease;
}

.idx-acceso-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-hover);
    border-color: rgba(119, 23, 47, 0.15);
}

.idx-acceso-card:hover::before {
    transform: scaleY(1);
}

.idx-acceso-icon {
    width: 44px; height: 44px;
    border-radius: 10px;
    background: rgba(119, 23, 47, 0.07);
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
    transition: background 0.25s ease;
}

.idx-acceso-icon svg { color: var(--primary); }

.idx-acceso-card:hover .idx-acceso-icon {
    background: rgba(119, 23, 47, 0.13);
}

.idx-acceso-body {
    display: flex; flex-direction: column; gap: 3px; flex: 1;
}

.idx-acceso-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 13px; font-weight: 700; color: var(--dark); line-height: 1.3;
}

.idx-acceso-desc {
    font-size: 11px; color: var(--muted); line-height: 1.5;
}

.idx-acceso-arrow {
    color: #ccc; flex-shrink: 0;
    transition: color 0.2s ease, transform 0.2s ease;
}

.idx-acceso-card:hover .idx-acceso-arrow {
    color: var(--primary); transform: translateX(3px);
}

/* =====================================================
   TABLERO DE CONVOCATORIAS
   ===================================================== */
.idx-convocatorias { background: #ffffff; }

/* Divisor entre carrusel y tablero */
.idx-conv-divider {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 40px 0 28px;
}

.idx-conv-divider::before,
.idx-conv-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--border);
}

.idx-conv-divider span {
    font-family: 'Montserrat', sans-serif;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--muted);
    white-space: nowrap;
}

.idx-conv-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.idx-conv-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 28px 26px 24px;
    display: flex; flex-direction: column; gap: 12px;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
    position: relative; overflow: hidden;
}

.idx-conv-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--gold));
    transform: scaleX(0); transform-origin: left;
    transition: transform 0.35s ease;
}

.idx-conv-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
    border-color: rgba(119, 23, 47, 0.15);
}

.idx-conv-card:hover::before { transform: scaleX(1); }

.idx-conv-featured {
    grid-column: span 2;
    background: linear-gradient(135deg, #fdf4f5 0%, #fff 60%);
    border-color: rgba(119, 23, 47, 0.15);
}

.idx-conv-tag {
    font-size: 9px; font-weight: 700; letter-spacing: 0.2em;
    text-transform: uppercase; color: var(--primary);
    background: rgba(119, 23, 47, 0.07);
    border-radius: 4px; padding: 4px 10px; align-self: flex-start;
}

.idx-conv-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 17px; font-weight: 800; color: var(--dark); line-height: 1.3;
}

.idx-conv-body {
    font-size: 13px; color: var(--mid); line-height: 1.7; flex: 1;
}

.idx-conv-links {
    display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px;
}

.idx-conv-link {
    font-size: 10px; font-weight: 600; letter-spacing: 0.1em;
    text-transform: uppercase; color: var(--primary); text-decoration: none;
    padding: 6px 14px;
    border: 1.5px solid rgba(119, 23, 47, 0.25); border-radius: 50px;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.idx-conv-link:hover {
    background: var(--primary); color: #fff; border-color: var(--primary);
}

/* =====================================================
   CONOCE EL MUNICIPIO
   ===================================================== */
.idx-conoce {
    background: var(--light);
    padding-top: 0; padding-bottom: 0;
}

.idx-conoce-inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 520px;
}

.idx-conoce-text {
    padding: 80px 72px 80px 80px;
    display: flex; flex-direction: column; justify-content: center;
}

.idx-conoce-titulo { font-size: clamp(1.8rem, 3vw, 2.8rem); }

.idx-conoce-desc {
    font-size: 14px; color: var(--mid); line-height: 1.85;
    margin-top: 20px; max-width: 480px;
}

.idx-conoce-datos {
    display: flex; gap: 32px; margin-top: 36px;
    padding-top: 28px; border-top: 1px solid var(--border);
}

.idx-dato { display: flex; flex-direction: column; gap: 4px; }

.idx-dato-num {
    font-family: 'Montserrat', sans-serif;
    font-size: 22px; font-weight: 900; color: var(--primary); line-height: 1;
}

.idx-dato-label {
    font-size: 10px; font-weight: 500; color: var(--muted); letter-spacing: 0.05em;
}

.idx-conoce-img-wrap {
    position: relative; overflow: hidden;
}

.idx-conoce-img {
    width: 100%; height: 100%; object-fit: cover; display: block;
    transition: transform 0.6s ease;
}

.idx-conoce-img-wrap:hover .idx-conoce-img { transform: scale(1.04); }

.idx-conoce-img-wrap::before {
    content: '';
    position: absolute; inset: 0;
    background: linear-gradient(135deg, rgba(119, 23, 47, 0.25) 0%, transparent 60%);
    z-index: 1; pointer-events: none;
}

.idx-conoce-img-badge {
    position: absolute; bottom: 20px; left: 20px; z-index: 2;
    display: inline-flex; align-items: center; gap: 6px;
    background: rgba(10, 2, 5, 0.7); backdrop-filter: blur(6px);
    border: 1px solid rgba(255, 255, 255, 0.15); color: #fff;
    font-size: 11px; font-weight: 500; padding: 7px 14px; border-radius: 50px;
}

.idx-conoce-img-badge svg { color: var(--gold); flex-shrink: 0; }

/* =====================================================
   MISIÓN Y VISIÓN
   ===================================================== */
.idx-mision { background: #ffffff; }

.idx-mv-grid {
    display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px;
}

.idx-mv-card {
    background: var(--white); border: 1px solid var(--border);
    border-radius: var(--radius-lg); padding: 36px 32px 32px;
    display: flex; flex-direction: column; gap: 16px;
    position: relative; overflow: hidden;
    transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.idx-mv-card::after {
    content: '';
    position: absolute; bottom: -40px; right: -40px;
    width: 160px; height: 160px; border-radius: 50%;
    background: radial-gradient(circle, rgba(119, 23, 47, 0.05) 0%, transparent 70%);
    pointer-events: none;
}

.idx-mv-card:hover { box-shadow: var(--shadow-hover); transform: translateY(-3px); }

.idx-mv-icon {
    width: 44px; height: 44px; border-radius: 10px;
    background: linear-gradient(135deg, var(--primary), #a02040);
    display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}

.idx-mv-icon svg { color: #fff; }

.idx-mv-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 16px; font-weight: 800; color: var(--dark);
    letter-spacing: 0.04em; text-transform: uppercase;
}

.idx-mv-body { font-size: 13.5px; color: var(--mid); line-height: 1.85; }

/* =====================================================
   DOCUMENTOS INSTITUCIONALES
   ===================================================== */
.idx-documentos { background: var(--light); }

.idx-doc-grid {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px;
}

.idx-doc-card {
    display: flex; align-items: center; gap: 14px;
    background: var(--white); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 18px 16px;
    text-decoration: none; color: var(--dark);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
    position: relative; overflow: hidden;
}

.idx-doc-card::before {
    content: '';
    position: absolute; top: 0; left: 0; width: 3px; height: 100%;
    background: linear-gradient(180deg, var(--primary) 0%, var(--gold) 100%);
    transform: scaleY(0); transform-origin: top; transition: transform 0.3s ease;
}

.idx-doc-card:hover {
    transform: translateY(-3px); box-shadow: var(--shadow-hover);
    border-color: rgba(119, 23, 47, 0.15);
}

.idx-doc-card:hover::before { transform: scaleY(1); }

.idx-doc-icon {
    width: 38px; height: 38px; border-radius: 8px;
    background: rgba(119, 23, 47, 0.07);
    display: flex; align-items: center; justify-content: center; flex-shrink: 0;
    transition: background 0.25s ease;
}

.idx-doc-icon svg { color: var(--primary); }
.idx-doc-card:hover .idx-doc-icon { background: rgba(119, 23, 47, 0.13); }

.idx-doc-body {
    display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0;
}

.idx-doc-cat {
    font-size: 8.5px; font-weight: 700; letter-spacing: 0.18em;
    text-transform: uppercase; color: var(--gold);
}

.idx-doc-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 12.5px; font-weight: 700; color: var(--dark); line-height: 1.35;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

.idx-doc-sub {
    font-size: 11px; color: var(--muted); line-height: 1.4;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

.idx-doc-arrow {
    color: #ccc; flex-shrink: 0;
    transition: color 0.2s ease, transform 0.2s ease;
}

.idx-doc-card:hover .idx-doc-arrow { color: var(--primary); transform: translateX(3px); }

/* =====================================================
   ORNAMENTO FINAL
   ===================================================== */
.idx-ornament {
    text-align: center; padding: 40px 0 56px; background: var(--light);
}

.idx-ornament span {
    display: inline-block; width: 6px; height: 6px;
    border-radius: 50%; background: var(--gold); margin: 0 4px; opacity: 0.5;
}

.idx-ornament span:nth-child(2) {
    opacity: 1; background: var(--primary); width: 8px; height: 8px; vertical-align: middle;
}

/* =====================================================
   CLIMA + REDES SOCIALES
   ===================================================== */
.idx-social-clima {
    background: #ffffff;
    padding-top: 64px;
    padding-bottom: 64px;
}

.idx-sc-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: start;
}

.idx-sc-header { margin-bottom: 24px; }
.idx-sc-header .idx-section-title { 
    font-size: clamp(1.4rem, 2.4vw, 1.9rem); 
    
    
}

/* ── Clima: tarjeta ── */
.idx-clima-card {
    background: var(--light);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    min-height: 260px;
    display: flex;
    flex-direction: column;
}

/* Loading */
.idx-clima-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    padding: 60px 24px;
    color: var(--muted);
    font-size: 13px;
    flex: 1;
}

.idx-clima-spinner {
    width: 28px;
    height: 28px;
    border: 2.5px solid var(--border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Error */
.idx-clima-error {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 48px 24px;
    color: var(--muted);
    font-size: 13px;
    text-align: center;
    flex: 1;
}
.idx-clima-error svg { color: #e2a04a; opacity: 0.7; }

/* Contenido */
.idx-clima-content { flex: 1; display: flex; flex-direction: column; }

/* Bloque principal — Hoy */
.idx-clima-hoy {
    padding: 28px 28px 20px;
    background: linear-gradient(135deg, var(--primary) 0%, #a02040 100%);
    color: #fff;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.idx-clima-icon {
    font-size: 52px;
    line-height: 1;
    margin-bottom: 4px;
}

.idx-clima-temp-wrap {
    display: flex;
    align-items: flex-start;
    gap: 4px;
    line-height: 1;
}

.idx-clima-temp {
    font-family: 'Montserrat', sans-serif;
    font-size: 56px;
    font-weight: 900;
    letter-spacing: -0.04em;
    line-height: 1;
}

.idx-clima-unit {
    font-family: 'Montserrat', sans-serif;
    font-size: 24px;
    font-weight: 600;
    margin-top: 10px;
    opacity: 0.75;
}

.idx-clima-desc {
    font-size: 15px;
    font-weight: 500;
    opacity: 0.88;
    text-transform: capitalize;
}

.idx-clima-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 6px;
    padding-top: 12px;
    border-top: 1px solid rgba(255,255,255,0.18);
    font-size: 12px;
    opacity: 0.82;
}

.idx-clima-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
}

/* Pronóstico 3 días */
.idx-clima-forecast {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    border-top: 1px solid var(--border);
}

.idx-clima-day {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 18px 12px;
    border-right: 1px solid var(--border);
}
.idx-clima-day:last-child { border-right: none; }

.idx-clima-day-name {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--muted);
}

.idx-clima-day-icon { font-size: 26px; line-height: 1; }

.idx-clima-day-range {
    display: flex;
    gap: 6px;
    font-family: 'Montserrat', sans-serif;
    font-size: 13px;
}
.idx-clima-day-range b  { color: var(--dark); font-weight: 700; }
.idx-clima-day-range em { color: var(--muted); font-style: normal; }

/* ── Facebook: tarjeta ── */
.idx-fb-card {
    background: var(--light);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.idx-fb-plugin {
    flex: 1;
    overflow: hidden;
    line-height: 0;
}

.idx-fb-plugin iframe {
    width: 100% !important;
    min-height: 480px;
    border: none;
    display: block;
}

.idx-fb-cta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 20px;
    background: #1877f2;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-decoration: none;
    transition: background 0.22s ease, transform 0.18s ease;
    border-top: none;
}
.idx-fb-cta:hover {
    background: #1464d2;
    transform: none;
}

/* =====================================================
   FLAYERS — CARRUSEL
   ===================================================== */
.idx-flayers { background: var(--light); }

/* Wrapper: flechas + viewport */
.idx-fc-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0;
}

/* Viewport: ventana que recorta la pista */
.idx-fc-viewport {
    flex: 1;
    overflow: hidden;
}

/* Pista deslizable */
.idx-fc-track {
    display: flex;
    gap: 20px;
    transition: transform 0.42s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform;
}

/* Tarjeta individual — ancho fijo para que caben N */
.idx-fc-item {
    flex: 0 0 calc(25% - 15px);   /* 4 col default */
    min-width: 0;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
}
.idx-fc-item::before {
    content: '';
    position: absolute; top: 0; left: 0; right: 0; height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--gold));
    transform: scaleX(0); transform-origin: left;
    transition: transform 0.3s ease; z-index: 2;
}
.idx-fc-item:hover { transform: translateY(-5px); box-shadow: var(--shadow-hover); }
.idx-fc-item:hover::before { transform: scaleX(1); }

/* Imagen con proporción 4:5 (1080×1350) */
.idx-fc-img-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 5;
    overflow: hidden;
    background: var(--light);
    cursor: pointer;
}
.idx-fc-img-wrap img {
    width: 100%; height: 100%;
    object-fit: cover; object-position: top;
    display: block;
    transition: transform 0.5s ease;
}
.idx-fc-item:hover .idx-fc-img-wrap img { transform: scale(1.04); }

/* Overlay con lupa */
.idx-fc-overlay {
    position: absolute; inset: 0;
    background: rgba(119, 23, 47, 0);
    display: flex; align-items: center; justify-content: center;
    transition: background 0.3s ease;
}
.idx-fc-item:hover .idx-fc-overlay { background: rgba(119, 23, 47, 0.32); }
.idx-fc-zoom {
    width: 44px; height: 44px; border-radius: 50%;
    background: rgba(255,255,255,0.95);
    display: flex; align-items: center; justify-content: center;
    color: var(--primary);
    opacity: 0; transform: scale(0.7);
    transition: opacity 0.3s ease, transform 0.3s ease;
    box-shadow: 0 4px 16px rgba(0,0,0,0.2);
}
.idx-fc-item:hover .idx-fc-zoom { opacity: 1; transform: scale(1); }

/* Info inferior */
.idx-fc-info {
    padding: 14px 16px 14px;
    display: flex; flex-direction: column; gap: 5px;
}
.idx-fc-tag {
    font-size: 8px; font-weight: 700; letter-spacing: 0.18em;
    text-transform: uppercase; color: var(--primary);
    background: rgba(119, 23, 47, 0.07);
    border-radius: 4px; padding: 3px 7px; align-self: flex-start;
}
.idx-fc-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 13px; font-weight: 800; color: var(--dark); line-height: 1.3;
}
.idx-fc-date { font-size: 10.5px; color: var(--muted); }
.idx-fc-links { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 2px; }
.idx-fc-btn {
    display: inline-flex; align-items: center; gap: 5px;
    font-size: 9px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase;
    color: var(--primary); text-decoration: none;
    padding: 5px 11px; border: 1.5px solid rgba(119,23,47,0.25); border-radius: 50px;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
}
.idx-fc-btn:hover { background: var(--primary); color: #fff; border-color: var(--primary); }

/* Flechas */
.idx-fc-arrow {
    flex-shrink: 0;
    width: 44px; height: 44px; border-radius: 50%;
    background: var(--white);
    border: 1.5px solid var(--border);
    color: var(--primary);
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 2px 12px rgba(0,0,0,0.1);
    transition: background 0.2s, color 0.2s, box-shadow 0.2s, opacity 0.25s;
    z-index: 2;
}
.idx-fc-arrow:hover:not(:disabled) {
    background: var(--primary); color: #fff;
    box-shadow: 0 4px 20px rgba(119,23,47,0.3);
}
.idx-fc-prev { margin-right: 14px; }
.idx-fc-next { margin-left: 14px; }

/* Contador */
.idx-fc-counter {
    text-align: center;
    margin-top: 18px;
    font-size: 12px;
    color: var(--muted);
    font-weight: 600;
    letter-spacing: 0.08em;
}
.idx-fc-counter span:first-child {
    color: var(--primary);
    font-size: 14px;
}

/* Responsive columnas */
@media (max-width: 1060px) {
    .idx-fc-item { flex: 0 0 calc(33.333% - 14px); }
}
@media (max-width: 768px) {
    .idx-fc-item { flex: 0 0 calc(50% - 10px); }
    .idx-fc-track { gap: 14px; }
}
@media (max-width: 480px) {
    .idx-fc-item { flex: 0 0 calc(100% - 0px); }
    .idx-fc-arrow { width: 36px; height: 36px; }
    .idx-fc-prev { margin-right: 8px; }
    .idx-fc-next { margin-left: 8px; }
}

/* ── Lightbox ── */
.idx-lightbox {
    position: fixed; inset: 0; z-index: 9999;
    background: rgba(5, 1, 3, 0.9);
    backdrop-filter: blur(10px);
    display: flex; align-items: center; justify-content: center;
    padding: 24px;
    opacity: 0; pointer-events: none;
    transition: opacity 0.3s ease;
}
.idx-lightbox.is-open { opacity: 1; pointer-events: all; }
.idx-lb-close {
    position: absolute; top: 20px; right: 20px;
    width: 40px; height: 40px; border-radius: 50%;
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    color: #fff; cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    transition: background 0.2s; z-index: 2;
}
.idx-lb-close:hover { background: rgba(255,255,255,0.22); }
.idx-lb-inner {
    max-width: min(92vw, 560px);
    max-height: 92vh;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: 0 32px 80px rgba(0,0,0,0.65);
    transform: scale(0.9);
    transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.idx-lightbox.is-open .idx-lb-inner { transform: scale(1); }
.idx-lb-inner img {
    display: block; width: 100%; height: auto;
    max-height: 92vh; object-fit: contain;
}

/* =====================================================
   MENÚ DE NAVEGACIÓN DE SECCIONES
   ===================================================== */
.idx-secnav {
    position: sticky;
    top: 0;
    z-index: 200;
    background: var(--white);
    border-bottom: 1px solid var(--border);
    box-shadow: 0 2px 16px rgba(0,0,0,0.07);
}

.idx-secnav-inner {
    max-width: var(--max-w);
    margin: 0 auto;
    padding: 0 40px;
    display: flex;
    align-items: stretch;
    gap: 0;
    justify-content: center;
    overflow-x: auto;
    scrollbar-width: none;
}
.idx-secnav-inner::-webkit-scrollbar { display: none; }

.idx-secnav-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 16px 22px;
    font-size: 12.5px;
    font-weight: 700;
    letter-spacing: 0.03em;
    color: var(--mid);
    text-decoration: none;
    white-space: nowrap;
    border-bottom: 3px solid transparent;
    transition: color 0.22s ease, border-color 0.22s ease, background 0.22s ease;
    position: relative;
}
.idx-secnav-item svg {
    opacity: 0.5;
    transition: opacity 0.22s ease;
    flex-shrink: 0;
}
.idx-secnav-item:hover {
    color: var(--primary);
    background: rgba(119, 23, 47, 0.04);
}
.idx-secnav-item:hover svg { opacity: 0.9; }

.idx-secnav-item.is-active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}
.idx-secnav-item.is-active svg { opacity: 1; }

/* Separador decorativo entre items */
.idx-secnav-item + .idx-secnav-item::before {
    content: '';
    position: absolute;
    left: 0; top: 25%; bottom: 25%;
    width: 1px;
    background: var(--border);
}

@media (max-width: 768px) {
    .idx-secnav-inner { padding: 0 16px; }
    .idx-secnav-item  { padding: 14px 14px; font-size: 11px; gap: 6px; }
    .idx-secnav-item svg { display: none; }
}

/* =====================================================
   SCROLL REVEAL
   ===================================================== */
.sr-hidden {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.55s ease, transform 0.55s ease;
}
.sr-visible {
    opacity: 1;
    transform: translateY(0);
}

/* =====================================================
   BOTÓN VOLVER AL INICIO
   ===================================================== */
.idx-back-top {
    position: fixed;
    bottom: 32px;
    right: 32px;
    z-index: 999;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 24px rgba(119, 23, 47, 0.4);
    opacity: 0;
    transform: translateY(16px) scale(0.85);
    pointer-events: none;
    transition: opacity 0.3s ease,
                transform 0.3s ease,
                background 0.2s ease,
                box-shadow 0.2s ease;
}
.idx-back-top.is-visible {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: all;
}
.idx-back-top:hover {
    background: var(--primary-dark);
    box-shadow: 0 8px 28px rgba(119, 23, 47, 0.55);
    transform: translateY(-3px) scale(1.05);
}
.idx-back-top:active {
    transform: translateY(0) scale(0.96);
}

/* =====================================================
   RESPONSIVE
   ===================================================== */
@media (max-width: 1100px) {
    .idx-hero-inner {
        grid-template-columns: 1fr 480px;
        gap: 44px;
    }

    .idx-accesos-grid { grid-template-columns: repeat(2, 1fr); }
    .idx-doc-grid     { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 900px) {
    .idx-section { padding: 56px 40px; }

    /* ── HERO: sin altura fija, crece con el contenido ── */
    .idx-hero {
        padding: 48px 28px 52px;
        align-items: flex-start; /* NO center — evita espacio vacío */
    }
    .idx-hero-inner {
        grid-template-columns: 1fr;
        gap: 28px;
        align-items: start;
    }
    .idx-hero-content  { text-align: center; }
    .idx-hero-sup      { justify-content: center; }
    .idx-hero-desc     { margin-left: auto; margin-right: auto; }
    .idx-hero-actions  { justify-content: center; }
    .idx-hero-slider-card { max-width: 500px; margin: 0 auto; width: 100%; }
    .idx-hsc-track        { height: 320px; }
    .idx-hsc-visual       { height: 158px; }

    .idx-conoce-inner    { grid-template-columns: 1fr; }
    .idx-conoce-text     { padding: 56px 40px; }
    .idx-conoce-img-wrap { min-height: 320px; }
    .idx-mv-grid         { grid-template-columns: 1fr; }

    .idx-info-inner      { grid-template-columns: 1fr; gap: 32px; }
    .idx-horarios-grid   { grid-template-columns: repeat(3, 1fr); }
    .idx-info-section    { padding: 48px 40px; }
    .idx-info-block-head { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 640px) {
    .idx-section { padding: 40px 20px; }
    .idx-hero    { padding: 80px 18px 44px; }

    .idx-hero-title   { font-size: 2rem; }
    .idx-hero-desc    { font-size: 14px; margin-bottom: 24px; }
    .idx-hero-actions { flex-direction: column; align-items: center; gap: 10px; }

    .idx-hero-slider-card { max-width: 100%; }
    .idx-hsc-track        { height: 300px; }
    .idx-hsc-visual       { height: 148px; }
    .idx-hsc-body         { padding: 12px 16px 4px; }
    .idx-hsc-title        { font-size: 14px; }

    .idx-accesos-grid  { grid-template-columns: 1fr; }
    .idx-conv-grid     { grid-template-columns: 1fr; }
    .idx-conv-featured { grid-column: span 1; }
    .idx-doc-grid      { grid-template-columns: 1fr; }
    .idx-conoce-datos  { gap: 20px; }

    .idx-info-section  { padding: 36px 20px; }
    .idx-horarios-grid { grid-template-columns: 1fr 1fr; }
    .idx-horarios-grid .idx-hora-card:last-child { grid-column: span 2; }
}

@media (max-width: 420px) {
    .idx-hero { padding: 80px 14px 32px; }

    /* Solo mostrar slider, ocultar texto del héroe */
    .idx-hero-content     { display: none; }
    .idx-hero-slider-card { display: flex; max-width: 100%; width: 100%; }
    .idx-hsc-track        { height: 380px; }
    .idx-hsc-visual       { height: 190px; }

    .idx-secnav-item      { padding: 13px 12px; }
    .idx-secnav-item span { font-size: 10.5px; }
}
.idx-galeria {
    padding: 60px 80px;
    background: #f7f7f7;
}

.idx-galeria-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.idx-galeria-grid img {
    width: 100%;
    height: 260px;
    object-fit: cover;
    border-radius: 16px;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.idx-galeria-grid img:hover {
    transform: scale(1.04);
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

/* LIGHTBOX */
.idx-lightbox {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    z-index: 9999;
}

.idx-lightbox.active {
    opacity: 1;
    pointer-events: all;
}

.idx-lightbox img {
    max-width: 90%;
    max-height: 90%;
    border-radius: 12px;
}

.idx-lightbox-close {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 40px;
    color: #fff;
    cursor: pointer;
}

/* Responsive */
@media (max-width: 900px) {
    .idx-galeria {
        padding: 40px;
    }
    .idx-galeria-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 500px) {
    .idx-galeria {
        padding: 20px;
    }
    .idx-galeria-grid {
        grid-template-columns: 1fr;
    }
    .idx-galeria-grid img {
        height: 220px;
    }
}