/* ========= Layout contenedor ========= */
:where(.fondo):where(div) {
    min-width: 100vw;
    height: auto !important;
    min-height: unset !important;
    max-height: unset !important;
    background-size: cover;
    background-repeat: no-repeat;
    background-position: 50% 100%;
    width: 100vw;
  }
  
  :where(.contenedor-header):where(.d-flex) {
    width: 100%;
    height: 100%;
  
    display: flex;
    flex-direction: column;
  }
  
  :where(.contenedor-texto) {
    padding: 0.5% 5% 2.5% 0;
  }
  
  /* ========= Tipografías / títulos ========= */
  :where(.d-flex):where(.titulo-header):where(.hide-mobile) {
    color: #fff !important;
    font-family: 'Roboto-Black';
    display: block !important;
  }
  
  .titulo150 {
    margin-top: 2vh;
    margin-bottom: -0.8rem;
    font-size: 120px;
    font-weight: 700;
    text-shadow: 2px 2px 2px #000;
    text-align: left;
    transition: text-shadow 0.3s, scale 0.3s;
  }
  
  .titulo150:hover {
    scale: 1.005;
  }
  
  .home {
    text-decoration: none;
    color: #fff;
  }
  
  .home:hover,
  .home:visited {
    text-decoration: none;
  }
  
  .subtitulo150 {
    font-size: 51px;
    margin: .5vh 0 0;
    color: var(--sub-tittle-color);
    text-align: left;
  }
  
  
  /* ========= Slider ========= */
  /* Wrapper del slider */
  .header-slider {
    position: relative;
    width: 100%;
    margin: 0;
    margin-bottom: 0 !important;
    padding-bottom: 0 !important;
    overflow: hidden;
    flex: 1 1 100%;
  }
  
  /* Cada slide ocupa todo el wrapper */
  .header-slider .slide {
    position: relative;
    inset: 0;
    width: 100%;
    height: auto;
    display: none; 
  }
  
  .header-slider .slide.active {
    display: block;
    z-index: 1;
  }
  
  /* Imagen del slide */
  .header-slider img {
    width: 100%;
    height: auto;
    display: block;
    /* evita gaps por inline-block */
  
  }
  
  /* Texto sobre el slider (chip con fondo sólo detrás del texto) */
  .header-slider .slider-text {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.5);
    color: #fff;
    z-index: 5;
    padding: 0.5rem 1rem;
    white-space: nowrap;
    display: flex;
    align-items: center;
    text-align: center;
    justify-content: center;
  }
  
  .header-slider .slider-text h2 {
    margin: 0;
    font-weight: 500;
    font-size: clamp(2rem, 4vw, 3.5rem);
    text-align: center;
  
  }
  
  .header-menu {
    position: fixed;
    width: 100%;
    top: 0;
    left: 0;
    items-align: center;
    z-index: 6;
    display: flex;
    gap: 80px;
    padding: 1rem 0.5rem;
    background: #1E4370;
    background: linear-gradient(90deg,rgba(30, 67, 112, 1) 31%, rgba(30, 67, 112, 0.56) 100%);
    justify-content: center;
    align-items: center;
  }
  
  .header-menu a {
    display: flex;
    align-items: center;
    color: #fff;
    text-decoration: none;
    font-weight: 400;
    font-size: clamp(1.1rem, 2vw, 1.5rem);
    line-height: 1;
    padding: .3rem .45rem;
    border-radius: 0;
  }
  
  .header-menu a:hover,
  .header-menu a:focus {
    background: rgba(255, 255, 255, .15);
    outline: none;
  }
  
  .redes {
    display: flex;
    gap: 8px;
    align-items: center;
    justify-content: center;
  }
  
  .redes img {
    width: 28px;
    height: 28px;
    display: block;
  }
  
  .header-slider .header-menu .redes a.redesredes {
    width: 2.5rem;
    height: 2.5;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
  
  .header-slider .header-menu .redes a.redesredes img {
    width: 100% !important;
    height: 100% !important;
    display: block;
  }
  
  .header-slider .header-menu .logo-mdp {
    width: 40px;
    height: auto;
  }
  .menu-toggle {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 28px;
    color: #fff;
    display: none;
  }
  
  /* Enlaces agrupados */
  .nav-links {
    display: flex;
    gap: 32px;
    align-items: center;
  }
  
  /* Desktop mediano */
  @media (max-width: 1439px) and (min-width: 1200px) {
    .header-menu {
      gap: 48px;
    }
    .titulo150 {
      font-size: 70px;
    }
    .subtitulo150 {
      font-size: 36px;
    }
  }
  
  /* Tablet */
  @media (max-width: 1199px) and (min-width: 768px) {
    .header-menu {
      gap: 24px;
      padding: 0.5rem 0.5rem;
    }
    .titulo150 {
      font-size: 48px;
    }
    .subtitulo150 {
      font-size: 24px;
    }
  }
  
  /* Mobile */
  @media (max-width: 767px) {
    .fondo,
    .contenedor-header,
    .header-slider,
    .header-slider > div {
      width: 100vw !important;
      min-width: 100vw !important;
      max-width: 100vw !important;
      margin: 0 !important;
      padding: 0 !important;
    }
  
    .header-menu {
      gap: 8px;
      flex-wrap: nowrap;
      flex-direction: row;
      align-items: center;
      justify-content: space-between; /* <-- Esto alinea logo a izq y hamburguesa a der */
      padding: 0.5rem 0.5rem;
      font-size: 1rem;
      position: relative;
    }
    .header-menu > a {
      order: 1;
    }
    .menu-toggle {
      display: block;
      margin-left: 8px;
      z-index: 10;
      order: 2;
      margin-right: 0;
      margin-left: auto;
    }
    .nav-links {
      display: none;
      flex-direction: column;
      width: 100%;
      background: #1E4370;
      position: absolute;
      top: 100%;
      left: 0;
      z-index: 9;
      gap: 0;
      padding: 0.5rem 0;
    }
    .nav-links.open {
      display: flex;
    }
    .logo-mdp {
      width: 28px !important;
    }
    .titulo150 {
      font-size: 28px;
      text-align: left;
      margin-top: 1vh;
    }
    .subtitulo150 {
      font-size: 16px;
      text-align: left;
    }
    .header-slider .slide {
      display: none !important;
    }
    .header-slider .slide-mobile-img {
      display: block !important;
      width: 100%;
      height: auto;
    }
    .header-slider .slide.slide-mobile {
      display: block !important;
      aspect-ratio: 4/3;
      width: 100vw !important;
      max-width: 100vw !important;
    }
    .menu-toggle {
      display: block;
      margin-left: 8px;
      margin-right: 12px;
      z-index: 10;
      order: 2;
    }
    .nav-links {
      display: none;
      flex-direction: column;
      width: 100%;
      background: #1E4370;
      position: absolute;
      top: 100%;
      left: 0;
      z-index: 9;
      gap: 0;
      padding: 0.5rem 0;
    }
    .nav-links.open {
      display: flex;
    }
    .nav-links a {
      padding: 0.2rem 0;
      margin: 0;
      font-size: 1rem;
    }
    .nav-links a:last-child {
      border-bottom: none;
    }
    .nav-links .redes {
      border-bottom: none;
      margin-top: 0.5rem;
      padding-bottom: 0;
    }
    
      .redes img {
        width: 20px;
        height: 20px;
      }
      .header-slider .header-menu .redes a.redesredes {
        width: 20px;
        height: 20px;
      }
    
  }