/* =========================
   UBICACIÓN PREMIUM
========================= */

.municipios-section{

  padding: 120px 8%;

  background:
  url('/images/fondo_ubicacion.png')
  center/cover
  no-repeat;

  position: relative;

  overflow: hidden;

}

/* HEADER */

.municipios-header{

  text-align: center;

  margin-bottom: 70px;

}

.municipios-header h2{

  font-size: 52px;

  color: white;

  margin-bottom: 18px;

  font-weight: 800;

}

.municipios-header p{

  color: rgba(255,255,255,.72);

  font-size: 18px;

  max-width: 700px;

  margin: 0 auto;

  line-height: 1.7;

}

/* GRID */

.municipios-grid{

  display: grid;

  grid-template-columns:
    repeat(4, 1fr);

  gap: 24px;

}

/* CARD */

.municipio-card{

  position: relative;

  height: 240px;

  border-radius: 30px;

  overflow: hidden;

  display: block;

  transition: .4s ease;

  box-shadow:
    0 25px 50px rgba(0,0,0,.25);

  isolation: isolate;

}

/* CARD GRANDE */

.municipio-card.large{

  grid-column: span 2;

  height: 320px;

}

/* IMAGEN */

.municipio-card img{

  width: 100%;
  height: 100%;

  object-fit: cover;

  transition: .7s ease;

}

/* OVERLAY */

.municipio-overlay{

  position: absolute;

  inset: 0;

  background:
    linear-gradient(
      to top,
      rgba(2,6,23,.95),
      rgba(2,6,23,.2)
    );

  z-index: 1;

}

/* INFO */

.municipio-info{

  position: absolute;

  left: 28px;
  bottom: 28px;

  z-index: 3;

}

.municipio-info h3{

  color: white;

  font-size: 34px;

  margin-bottom: 8px;

  font-weight: 800;

  line-height: 1.1;

}

.municipio-info span{

  color: rgba(255,255,255,.82);

  font-size: 15px;

  font-weight: 500;

}

/* HOVER */

.municipio-card:hover{

  transform:
    translateY(-8px);

  box-shadow:
    0 35px 80px rgba(37,99,235,.25);

}

.municipio-card:hover img{

  transform: scale(1.08);

}

/* GLOW */

.municipio-card::after{

  content: "";

  position: absolute;

  inset: 0;

  border-radius: 30px;

  border: 1px solid rgba(255,255,255,.08);

  pointer-events: none;

  z-index: 5;

}

/* RESPONSIVE */

@media(max-width: 1100px){

  .municipios-grid{

    grid-template-columns:
      repeat(2, 1fr);

  }

}

@media(max-width: 768px){

  .municipios-section{

    padding: 90px 20px;

  }

  .municipios-header h2{

    font-size: 38px;

  }

  .municipios-header p{

    font-size: 16px;

  }

  .municipios-grid{

    grid-template-columns: 1fr;

  }

  .municipio-card.large{

    grid-column: span 1;

    height: 260px;

  }

  .municipio-card{

    height: 230px;

  }

  .municipio-info h3{

    font-size: 28px;

  }

}


/* =========================================================
   UBICACIÓN - OPTIMIZACIÓN MÓVIL
   Mantiene intacto el diseño desktop
========================================================= */

@media (max-width: 768px){

  .municipios-section{
    padding: 58px 14px 65px;
    background-position: center;
  }

  /* HEADER */

  .municipios-header{
    margin-bottom: 30px;
    padding: 0 8px;
  }

  .municipios-header h2{
    font-size: 30px;
    line-height: 1.15;
    margin-bottom: 10px;
  }

  .municipios-header p{
    font-size: 15px;
    line-height: 1.5;
    max-width: 360px;
  }

  /* GRID */

  .municipios-grid{
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }

  /* COLIMA + MANZANILLO */

  .municipio-card.large{
    grid-column: span 2;
    height: 220px;
  }

  /* RESTO DE MUNICIPIOS */

  .municipio-card{
    height: 165px;
    border-radius: 20px;
    box-shadow: 0 12px 28px rgba(0,0,0,.24);
  }

  .municipio-card.large{
    border-radius: 24px;
  }

  /* IMÁGENES */

  .municipio-card img{
    object-position: center;
  }

  /* OVERLAY */

  .municipio-overlay{
    background:
      linear-gradient(
        to top,
        rgba(2,6,23,.92),
        rgba(2,6,23,.08)
      );
  }

  /* NOMBRE */

  .municipio-info{
    left: 15px;
    right: 10px;
    bottom: 14px;
  }

  .municipio-info h3{
    font-size: 20px;
    line-height: 1.05;
    margin: 0;
  }

  .municipio-card.large .municipio-info{
    left: 20px;
    bottom: 18px;
  }

  .municipio-card.large .municipio-info h3{
    font-size: 28px;
  }

  /* EVITAR HOVER EN TOUCH */

  .municipio-card:hover{
    transform: none;
  }

  .municipio-card:hover img{
    transform: none;
  }

  /* BORDE */

  .municipio-card::after{
    border-radius: inherit;
  }

}


/* =========================================================
   TELÉFONOS PEQUEÑOS
========================================================= */

@media (max-width: 380px){

  .municipios-section{
    padding: 50px 10px 58px;
  }

  .municipios-header{
    margin-bottom: 26px;
  }

  .municipios-header h2{
    font-size: 27px;
  }

  .municipios-header p{
    font-size: 14px;
  }

  .municipios-grid{
    gap: 10px;
  }

  .municipio-card.large{
    height: 200px;
  }

  .municipio-card{
    height: 150px;
    border-radius: 18px;
  }

  .municipio-info{
    left: 12px;
    bottom: 12px;
  }

  .municipio-info h3{
    font-size: 18px;
  }

  .municipio-card.large .municipio-info{
    left: 16px;
    bottom: 15px;
  }

  .municipio-card.large .municipio-info h3{
    font-size: 25px;
  }

}
