@tailwind base;
@tailwind components;
@tailwind utilities;

/* estilos base de toda la pagina */
@layer base {
  html {
    scroll-behavior: smooth;
  }
  body {
    margin: 0;
    background: #ffffff;
    color: #172b3a;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  }
}

@layer components {

  /* contenedor central que limita el ancho del contenido */
  .site-shell {
    width: min(100% - 2.5rem, 1280px);
    margin-inline: auto;
  }

  /* header general, queda fijo arriba al hacer scroll */
  .site-header { 
    --header-ink: #12334a; 
    position: sticky; 
    top: 0; 
    z-index: 50; 
  }

  /* barra superior azul con accesos institucionales */
  .site-header__topbar { 
    min-height: 34px; 
    background: #00665E; 
    border-bottom: 1px solid rgba(255,255,255,.12); 
  }
  .site-header__topbar .site-shell { 
    display: flex; 
    align-items: center; 
    justify-content: center; 
  }
  .site-header__topbar-nav { 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    gap: .35rem; 
  }

  /* enlaces de la barra superior y del menu principal */
  .site-header__topbar-link, .site-header__link {
    display: inline-flex; 
    align-items: center; 
    gap: .4rem; 
    color: inherit; 
    text-decoration: none;
    transition: color .2s ease, background-color .2s ease, transform .2s ease;
  }
  .site-header__topbar-link { 
    padding: .35rem .65rem; 
    color: rgba(255,255,255,.88); 
    font-size: .75rem; 
  }
  .site-header__topbar-link:hover, .site-header__topbar-link:focus-visible { 
    color: #fff; 
    background: rgba(255,255,255,.12); 
    border-radius: 999px; 
  }
  .site-header__topbar-icon { 
    width: 15px; 
    height: 15px; 
  }

  /* separador entre grupos de la barra superior */
  .site-header__topbar-divider { 
    width: 1px; 
    height: 18px; 
    margin-inline: .25rem; 
    background: rgba(255,255,255,.26); 
  }

  /* dropdowns de la barra superior y del menu principal */
  .site-header__topbar-item, .site-header__item { 
    position: relative; 
  }
  .site-header__topbar-dropdown, .site-header__dropdown {
    position: absolute; 
    left: 50%; 
    z-index: 10; 
    min-width: 210px; 
    padding: .45rem;
    background: #176b58; 
    border: 1px solid rgba(255,255,255,.2); 
    border-radius: 10px;
    box-shadow: 0 18px 45px rgba(15,57,82,.18); 
    opacity: 0; 
    pointer-events: none;
    transform: translate(-50%,8px); 
    transition: opacity .2s ease, transform .2s ease;
  }
  .site-header__topbar-dropdown { top: calc(100% + .35rem); }
  .site-header__dropdown { top: calc(100% + .7rem); }
  .site-header__topbar-item:hover .site-header__topbar-dropdown,
  .site-header__topbar-item:focus-within .site-header__topbar-dropdown,
  .site-header__item:hover .site-header__dropdown,
  .site-header__item:focus-within .site-header__dropdown {
    opacity: 1; 
    pointer-events: auto; 
    transform: translate(-50%,0);
  }
  .site-header__dropdown-link, .site-header__topbar-dropdown-link {
    display: flex; 
    align-items: center; 
    gap: .65rem; 
    padding: .7rem .8rem; 
    color: #fff;
    font-size: .8rem; 
    text-decoration: none; 
    border-radius: 7px;
  }
  .site-header__dropdown-link:hover, .site-header__dropdown-link:focus-visible,
  .site-header__topbar-dropdown-link:hover, .site-header__topbar-dropdown-link:focus-visible {
    color: #fff; 
    background: #0c473b;
  }
  .site-header__dropdown-icon { 
    display: inline-flex; 
    color: #ffff33; 
  }
  .site-header__dropdown-icon svg { 
    width: 19px; 
    height: 19px; 
  }

  /* fila blanca del header donde va el logo y el menu principal - Liquid Glass Effect */
  .site-header__nav {
    position: relative; 
    min-height: 135px; 
    color: #263d50; 
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(10px) saturate(100%);
    -webkit-backdrop-filter: blur(10px) saturate(100%);
    border-bottom: 1px solid rgba(255, 255, 255, 0.6);
    border-top: 1px solid rgba(255, 255, 255, 0.8);
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.1);
  }

  /* distribucion flexible para alineacion correcta: logo a la izquierda, menu al centro, redes a la derecha */
  .site-header__nav > .site-shell {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 135px;
  }

  /* logo del instituto */
  .site-header__brand { 
    display: flex; 
    align-items: center; 
    flex-shrink: 0;
    margin-right: 2rem;
    margin-left: 0;
    padding-left: 0;
  }
  .site-header__logo-link { 
    display: inline-flex; 
    align-items: center; 
    margin-left: 0;
  }
  .site-header__logo-img { 
    display: block; 
    width: auto; 
    height: 115px; 
    max-height: 115px; 
    object-fit: contain; 
  }

  /* menu principal centrado, solo visible en pantallas grandes */
  .site-header__menu { 
    display: none; 
    align-items: center; 
    justify-content: center; 
    gap: 1.8rem; 
    flex: 1; 
    text-align: center; 
    margin: 0;
  }
  @media (min-width: 1024px) { 
    .site-header__menu { display: flex; } 
  }
  .site-header__link {
    padding: .5rem .25rem; 
    color: #2d3748; 
    font-size: 1.05rem; 
    font-weight: 600;
    white-space: nowrap; 
    border-radius: 0; 
    display: inline-flex; 
    align-items: center; 
    justify-content: center;
    text-align: center;
  }
  .site-header__link:hover, .site-header__link:focus-visible, .site-header__link--active { 
    color: #176b58; 
    background: transparent; 
  }

  /* contorno de accesibilidad al enfocar con teclado */
  .site-header__link:focus-visible, .site-header__topbar-link:focus-visible, .site-header__dropdown-link:focus-visible,
  .site-header__topbar-dropdown-link:focus-visible, .site-header__icon:focus-visible, .site-header__toggle:focus-visible {
    outline: 3px solid rgba(23,107,88,.35); 
    outline-offset: 3px;
  }

  /* flechitas de los menus desplegables */
  .site-header__chevron, .site-header__topbar-chevron { 
    width: 13px; 
    height: 13px; 
    transition: transform .2s ease; 
  }
  .site-header__link:hover .site-header__chevron, .site-header__link:focus-visible .site-header__chevron { 
    transform: rotate(180deg); 
  }

  /* zona derecha con la barra verde y los iconos sociales */
  .site-header__actions { 
    display: flex; 
    align-items: center; 
    gap: 1rem; 
    flex-shrink: 0;
    margin-left: 1.5rem;
    margin-right: 0;
    padding-right: 0;
  }

  /* barra verde que separa el menu de los iconos sociales */
  .site-header__accent-line {
    display: block;
    width: 2px;
    height: 50px;
    background: #176b58;
    border-radius: 1px;
  }

  /* iconos de redes sociales, solo visibles en pantallas grandes */
  .site-header__socials { 
    display: none; 
    align-items: center; 
    gap: .85rem; 
  }
  @media (min-width: 1024px) { 
    .site-header__socials { display: flex; } 
  }
  .site-header__icon { 
    display: inline-flex; 
    align-items: center; 
    justify-content: center; 
    width: 44px;
    height: 44px;
    color: #4a5568; 
    border-radius: 50%; 
    transition: color .2s ease, transform .2s ease; 
  }
  .site-header__icon:hover, .site-header__icon:focus-visible { 
    color: #176b58; 
    transform: translateY(-1px); 
  }
  .site-header__icon svg { 
    width: 24px; 
    height: 24px; 
  }

  /* checkbox oculto que controla el menu movil */
  .site-header__menu-checkbox { 
    position: absolute; 
    opacity: 0; 
    pointer-events: none; 
  }

  /* boton hamburguesa para pantallas chicas */
  .site-header__toggle {
    display: none; 
    align-items: center; 
    justify-content: center;
    width: 42px; 
    height: 42px; 
    color: var(--header-ink);
    background: #f3f5f8; 
    border: 1px solid #dbe4eb; 
    border-radius: 50%; 
    cursor: pointer;
  }
  @media (max-width: 1023px) { 
    .site-header__toggle { display: inline-flex; } 
  }

  /* panel del menu movil */
  .site-header__mobile-menu { 
    display: none; 
    background: #fff; 
    border-bottom: 1px solid #dbe4eb; 
  }
  .site-header__menu-checkbox:checked ~ .site-header__mobile-menu { 
    display: block; 
  }
  .site-header__mobile-nav { 
    display: grid; 
    gap: .2rem; 
    padding-block: .7rem 1rem; 
  }
  .site-header__mobile-link { 
    padding: .8rem .65rem; 
    color: var(--header-ink); 
    font-size: .92rem; 
    font-weight: 600; 
    text-decoration: none; 
    border-bottom: 1px solid #e5edf2; 
  }
  .site-header__mobile-socials { 
    display: flex; 
    align-items: center; 
    gap: .55rem; 
    padding-top: .6rem; 
  }

  /* carrusel grande de imagenes al inicio de la pagina */
  .hero-showcase { 
    position: relative; 
    width: 100%;
    height: 650px;
    overflow: hidden; 
    background: #1a202c; 
    isolation: isolate; 
  }
  .hero-slide { 
    position: absolute; 
    inset: 0; 
    opacity: 0; 
    pointer-events: none;
    transition: opacity 0.8s ease-in-out;
  }
  .hero-slide.is-active {
    opacity: 1;
    pointer-events: auto;
  }
  .hero-slide__image { 
    display: block; 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
    object-position: center; 
  }

  /* seccion de introduccion con texto y galeria de fotos */
  .home-intro {
    padding-block: 4rem;
    background: #ffffff;
  }
  
  .home-intro__layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3.5rem;
    align-items: center;
  }

  /* galeria de 3 fotos: 1 grande vertical a la izquierda y 2 apiladas a la derecha */
  .home-intro__gallery {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: .85rem;
    height: 420px;
  }

  .home-intro__gallery figure {
    margin: 0;
    overflow: hidden;
    border-radius: 4px;
  }

  .home-intro__gallery figure.figure--main,
  .home-intro__gallery .figure--main {
    grid-row: span 2;
    height: 100%;
  }

  .home-intro__gallery img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .4s ease;
  }

  .home-intro__gallery figure:hover img {
    transform: scale(1.03);
  }

  /* texto descriptivo al lado de la galeria */
  .home-intro__text {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
  }

  .home-intro__eyebrow {
    margin: 0 0 .5rem 0;
    font-size: .75rem;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: #176b58;
  }

  .home-intro__title {
    margin: 0 0 1.25rem 0;
    font-size: clamp(2rem, 3.2vw, 2.75rem);
    font-weight: 800;
    line-height: 1.1;
    color: #0f172a;
    letter-spacing: -.02em;
  }

  .home-intro__desc {
    margin: 0 0 1rem 0;
    font-size: .95rem;
    line-height: 1.65;
    color: #4a5568;
  }

  .home-intro__link {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    margin-top: 1.5rem;
    padding-bottom: .25rem;
    border-bottom: 2px solid #176b58;
    font-size: .85rem;
    font-weight: 800;
    color: #0f172a;
    text-decoration: none;
    transition: color .2s ease;
  }

  .home-intro__link:hover {
    color: #176b58;
  }

  /* espaciados y textos genericos usados en varias secciones */
  .section-space { padding-block: 5.5rem 6.5rem; }
  .eyebrow { margin: 0 0 .35rem; font-size: .74rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: #176b58; }
  .eyebrow--yellow { color: #b58900; }
  .subtitle { max-width: 380px; margin: 0; color: #536879; line-height: 1.65; }

  /* seccion de noticias */
  .news-section { background: #fff; }
  .section-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 2rem; margin-bottom: 2.0rem; }
  @media (max-width: 760px) { .section-heading { display: block; } }
  .section-heading h2 { margin: .5rem 0 0; font-size: clamp(1.9rem, 3.5vw, 3rem); font-weight: 800; line-height: .98; letter-spacing: -.02em; color: #0f172a; }

  /* botones generales usados en la pagina */
  .btn { display: inline-flex; align-items: center; justify-content: center; gap: .55rem; min-height: 44px; padding-inline: 1rem; font-size: .85rem; font-weight: 700; text-decoration: none; transition: transform .18s ease, color .18s ease, background-color .18s ease, box-shadow .18s ease; }
  .btn--pill { padding: .75rem 1.15rem; border-radius: 999px; }
  .btn--primary { color: #fff; background: #176b58; box-shadow: 0 5px 14px rgba(23,107,88,.2); }
  .btn--primary:hover, .btn--primary:focus-visible { color: #fff; background: #0c473b; box-shadow: 0 8px 20px rgba(23,107,88,.28); transform: translateY(-1px); }
  .btn--primary:active { box-shadow: 0 2px 7px rgba(23,107,88,.2); transform: scale(.98); }
  .btn--link { padding: .5rem 0; color: #176b58; }
  .btn--link:hover, .btn--link:focus-visible { color: #0c473b; }
  .btn__chevron { width: 14px; height: 14px; transition: transform .2s ease; }
  .btn--link:hover .btn__chevron, .btn--link:focus-visible .btn__chevron { transform: translateX(3px); }
  .btn__icon { width: 18px; height: 18px; flex-shrink: 0; transition: transform .2s ease; }
  .btn--primary:hover .btn__icon, .btn--primary:focus-visible .btn__icon { transform: translateX(3px); }

  /* tarjetas de noticias, una grande y una lista chica */
  .news-editorial { display: grid; grid-template-columns: minmax(0,1.2fr) minmax(360px,.8fr); gap: 1.25rem; max-width: 1320px; margin-inline: auto; }
  .news-editorial__feature, .news-editorial__item { overflow: hidden; background: #fff; border: 1px solid #dbe7ea; border-radius: 12px; box-shadow: 0 8px 24px rgba(19,35,55,.06); transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease; }
  .news-editorial__feature { display: grid; grid-template-columns: minmax(0,1.05fr) minmax(250px,.95fr); }
  .news-editorial__feature:hover, .news-editorial__item:hover { border-color: #b8d8cc; box-shadow: 0 16px 34px rgba(19,35,55,.12); transform: translateY(-3px); }
  .news-editorial__feature:focus-within, .news-editorial__item:focus-within { border-color: #176b58; box-shadow: 0 0 0 3px rgba(23,107,88,.16), 0 12px 28px rgba(19,35,55,.1); }
  .news-editorial__feature-image { min-height: 390px; overflow: hidden; background: #dbe8eb; }
  .news-editorial__feature-image img, .news-editorial__item-image img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .45s ease; }
  .news-editorial__feature:hover img, .news-editorial__item:hover img { transform: scale(1.04); }
  .news-editorial__feature-body, .news-editorial__item-body { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; padding: 1.7rem; }
  .news-editorial__date { margin: 0 0 .7rem; color: #176b58; font-size: .68rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
  .news-editorial h3 { margin: 0 0 .8rem; color: #132337; font-size: clamp(1.25rem,2.3vw,2rem); line-height: 1.12; }
  .news-editorial h3 a { color: inherit; text-decoration: none; }
  .news-editorial__feature-body > p:not(.news-editorial__date) { margin: 0 0 1.5rem; color: #536879; line-height: 1.7; }
  .news-editorial__link { display: inline-flex; align-items: center; gap: .5rem; color: #176b58; font-size: .8rem; font-weight: 800; text-decoration: none; }
  .news-editorial__list { display: grid; gap: .85rem; }
  .news-editorial__item { display: grid; grid-template-columns: 150px minmax(0,1fr); min-height: 125px; }
  .news-editorial__item-image { min-height: 125px; overflow: hidden; background: #dbe8eb; }
  .news-editorial__item-body { padding: 1rem 1.15rem; }
  .news-editorial__item-body .news-editorial__date { margin-bottom: .45rem; font-size: .6rem; }
  .news-editorial__item h3 { margin-bottom: .7rem; font-size: 1rem; }

  /* pestañas de niveles academicos, con radios ocultos */
  .tab-radio { position: absolute; opacity: 0; pointer-events: none; }
  .academic-tabs-wrap { display: flex; justify-content: center; }
  .academic-tabs {
    display: flex; justify-content: center; align-items: center; gap: 0.3rem; width: max-content; max-width: 100%;
    padding: 0.35rem 0.6rem; margin: 0 auto 2.2rem; background: transparent; border: none;
    border-radius: 6px; box-shadow: none;
    backdrop-filter: none;
  }
  .academic-tab {
    position: relative; z-index: 1; min-width: auto; min-height: 36px; padding: 0.45rem 1.1rem;
    color: #526477; background: transparent; border: 0; border-radius: 6px; cursor: pointer;
    font-size: 1.3rem; font-weight: 600; white-space: nowrap; transition: all .15s ease, box-shadow .15s ease;
  }
  .academic-tab:hover, .academic-tab:focus-visible { color: #176b58; background: transparent; outline: none; }
  .academic-tab:active { transform: scale(.95); }

  /* seccion completa de niveles academicos */
  .academic-section { padding-block: 5.5rem 9rem; background: #f7fafb; }
  .academic-section .section-heading { max-width: 900px; margin-inline: auto; }
  .academic-section .eyebrow { margin: 0 0 .35rem; color: #176b58; font-size: .74rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
  .academic-section .subtitle { max-width: 380px; color: #536879; line-height: 1.65; }
  .academic-layout { display: grid; grid-template-columns: minmax(0,1.1fr) minmax(280px,.75fr); gap: 1.75rem; max-width: 1080px; margin: 2.5rem auto 0; }
  .academic-panel { display: none; position: relative; grid-template-columns: minmax(0,1.1fr) minmax(0,.9fr); gap: 1.35rem; padding: 1.4rem; background: #fff; border: 1px solid #e1e9ef; border-top: 4px solid #fff; border-radius: 14px; box-shadow: 0 12px 30px rgba(24,57,70,.07); }
  .academic-panel__image-wrap { position: relative; min-width: 0; min-height: 360px; overflow: visible; border-radius: 9px; }
  .academic-panel__image-wrap img { display: block; width: 100%; height: 100%; min-height: 360px; object-fit: cover; border-radius: 9px; }
  .academic-panel__content { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; padding: .2rem .15rem .35rem; }
  .academic-panel__content h3 { margin: .5rem 0 .8rem; color: #132337; font-size: clamp(1.55rem,3vw,2.25rem); line-height: 1.08; }
  .academic-panel__content .panel-text { margin-bottom: 1.5rem; color: #536879; line-height: 1.7; }
  .academic-panel__square { position: absolute; width: 30px; height: 30px; background: #176b58; border-radius: 4px; z-index: 2; }
  .academic-panel__square--top { top: -12px; left: -12px; }
  .academic-panel__square--bottom { bottom: -12px; left: -12px; }
  .academic-panel .btn--primary { min-height: auto; padding: 0.5rem 0; color: #176b58; background: transparent; border: none; border-radius: 0; cursor: pointer; font-weight: 700; transition: all .18s ease; box-shadow: none; text-decoration: none; display: inline-flex; align-items: center; gap: 0.5rem; }
  .academic-panel .btn--primary:hover, .academic-panel .btn--primary:focus-visible { color: #0d4a3a; text-decoration: underline; transform: none; outline: none; }
  .academic-panel .btn--primary:active { transform: scale(.98); }

  /* logica que muestra el panel segun la pestaña activa */
  #tab-continuada:checked ~ .academic-tabs-wrap .academic-tab--continuada {
    color: #176b58; background: transparent; border-bottom: 2px solid #176b58; box-shadow: none;
  }
  #tab-primaria:checked ~ .academic-tabs-wrap .academic-tab--primaria { 
    color: #ffff33; background: transparent; border-bottom: 2px solid #ffff33; box-shadow: none;
  }
  #tab-secundaria:checked ~ .academic-tabs-wrap .academic-tab--secundaria { 
    color: #1825aa; background: transparent; border-bottom: 2px solid #1825aa; box-shadow: none;
  }
  #tab-superior:checked ~ .academic-tabs-wrap .academic-tab--superior { 
    color: #718096; background: transparent; border-bottom: 2px solid #718096; box-shadow: none;
  }
  #tab-continuada:checked ~ .academic-layout .academic-panel--continuada,
  #tab-primaria:checked ~ .academic-layout .academic-panel--primaria,
  #tab-secundaria:checked ~ .academic-layout .academic-panel--secundaria,
  #tab-superior:checked ~ .academic-layout .academic-panel--superior {
    display: grid;
  }

  /* cambiar color de los cuadrados según la tab activa */
  #tab-primaria:checked ~ .academic-layout .academic-panel--primaria .academic-panel__square { background: #ffff33; }
  #tab-secundaria:checked ~ .academic-layout .academic-panel--secundaria .academic-panel__square { background: #1825aa; }
  #tab-superior:checked ~ .academic-layout .academic-panel--superior .academic-panel__square { background: #718096; }

  /* tarjeta de descargas al lado de cada panel academico */
  .downloads-card {
    padding: 1.8rem; background: #fff; border: 1px solid #e1e9ef; border-radius: 14px; box-shadow: 0 12px 30px rgba(24,57,70,.07);
  }
  .downloads-card__header { display: flex; align-items: center; gap: .7rem; margin-bottom: 1.4rem; }
  .downloads-card__icon { display: inline-flex; align-items: center; justify-content: center; width: 48px; height: 48px; color: #fff; background: linear-gradient(135deg, #176b58 0%, #0d4a3a 100%); border: none; border-radius: 50%; }
  .downloads-card__icon svg { width: 24px; height: 24px; }
  .downloads-card__title { margin: 0; color: #132337; font-size: 1.2rem; font-weight: 800; }
  .downloads-card__subtitle { margin: .15rem 0 0; color: #536879; font-size: .72rem; }
  .downloads-panel { display: none; flex-direction: column; gap: .75rem; }
  #tab-continuada:checked ~ .academic-layout .downloads-panel--continuada,
  #tab-primaria:checked ~ .academic-layout .downloads-panel--primaria,
  #tab-secundaria:checked ~ .academic-layout .downloads-panel--secundaria,
  #tab-superior:checked ~ .academic-layout .downloads-panel--superior {
    display: flex;
  }
  .downloads-item { display: flex; align-items: center; justify-content: space-between; gap: .8rem; padding: 1.1rem; background: #f8fafc; border: 1px solid #e2ebf0; border-radius: 10px; }
  .downloads-item__name, .downloads-item__meta { display: block; }
  .downloads-item__name { color: #132337; font-size: .82rem; font-weight: 700; }
  .downloads-item__meta { margin-top: .25rem; color: #536879; font-size: .68rem; }
  .downloads-item__actions { display: flex; gap: .45rem; flex-shrink: 0; }
  .icon-btn--glass { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; color: #176b58; text-decoration: none; border: 1px solid #b8d8cc; border-radius: 50%; transition: color .18s ease, background-color .18s ease, transform .18s ease; }
  .icon-btn--glass:hover, .icon-btn--glass:focus-visible { color: #fff; background: #176b58; outline: none; transform: scale(1.04); }
  .icon-btn--glass:active { transform: scale(.96); }
  .icon-btn--glass svg { width: 16px; height: 16px; }

  /* pie de pagina */
  .site-footer { padding: 4rem 0 1.4rem; color: rgba(255,255,255,.78); background: #176b58; }
  .site-footer .site-shell { max-width: 1180px; }
  .site-footer__main { display: grid; grid-template-columns: minmax(240px,1.35fr) repeat(3,minmax(140px,1fr)); gap: 2.5rem; padding: 1rem 0 3.5rem; }
  .site-footer__brand { display: flex; flex-direction: column; align-items: flex-start; max-width: 285px; gap: 1rem; }
  .site-footer__logo img { display: block; width: auto; max-width: 300px; max-height: 175px; object-fit: contain; }
  .site-footer__brand > p { margin: 0; font-size: 1.15rem; line-height: 1.8; }
  .site-footer__social { display: flex; gap: .65rem; margin-top: .5rem; }
  .site-footer__social a { display: inline-flex; align-items: center; justify-content: center; width: 45px; height: 45px; color: #fff; border: 1px solid rgba(255,255,255,.28); border-radius: 50%; }
  .site-footer__social a:hover, .site-footer__social a:focus-visible { color: #176b58; background: #ffff33; }
  .site-footer__social svg { width: 22px; height: 22px; }
  .site-footer__label { display: inline-block; margin-bottom: 1.25rem; color: #ffff33; font-size: .98rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
  .site-footer__list { display: grid; gap: .8rem; }
  .site-footer__list a, .site-footer__contact a { color: rgba(255,255,255,.78); font-size: 1.05rem; text-decoration: none; }
  .site-footer__list a:hover, .site-footer__contact a:hover { color: #ffff33; }
  .site-footer__contact { margin: 0; }
  .site-footer__contact p { margin: 0 0 .8rem; font-size: 1.05rem; line-height: 1.6; }
  .site-footer__copyright { padding-top: 1.4rem; color: rgba(255,255,255,.58); font-size: .74rem; text-align: center; border-top: 1px solid rgba(255,255,255,.16); }
  .site-footer__copyright p { margin: 0; }

  /* adaptabilidad responsive para pantallas medianas y tablets */
  @media (max-width: 1180px) {
    .site-header__menu { gap: 1rem; }
    .site-header__link { font-size: .98rem; }
    .home-intro__layout,
    .news-editorial,
    .academic-panel,
    .academic-layout {
      grid-template-columns: 1fr;
    }
  }

  /* header pasa a modo movil: se oculta el menu y aparece la hamburguesa */
  @media (max-width: 1023px) {
    .site-header__menu,
    .site-header__socials,
    .site-header__accent-line {
      display: none;
    }
    .site-header__toggle { display: inline-flex; }
    .site-header__nav {
      min-height: 110px;
    }
    .site-header__nav > .site-shell {
      min-height: 110px;
    }
    .site-header__logo-img { height: 90px; }
    .site-header__brand { margin-right: 1.5rem; }
    .site-header__actions { margin-left: 1rem; gap: 0.8rem; }
    .hero-showcase { height: 380px; }
    .site-footer__main { grid-template-columns: repeat(2,minmax(0,1fr)); }
  }

  /* ajustes para pantallas de celular */
  @media (max-width: 760px) {
    .site-shell { width: min(100% - 1.5rem, 1280px); }
    .site-header__topbar-nav { flex-wrap: wrap; justify-content: center; gap: .2rem; }
    .site-header__logo-img { height: 80px; }
    .site-header__nav {
      min-height: 100px;
    }
    .site-header__nav > .site-shell {
      min-height: 100px;
    }
    .site-header__brand { margin-right: 1.2rem; }
    .site-header__actions { margin-left: 0.8rem; gap: 0.6rem; }
    .home-intro__layout { gap: 2.5rem; grid-template-columns: 1fr; }
    .home-intro__gallery { height: 320px; }
    .home-intro__title { font-size: 1.8rem; }
    .news-editorial__feature,
    .news-editorial__item,
    .academic-panel {
      grid-template-columns: 1fr;
    }
    .academic-tabs { width: 100%; overflow-x: auto; justify-content: flex-start; }
    .site-footer__main { grid-template-columns: 1fr; gap: 2rem; }
    .site-footer__brand { grid-column: auto; }
    .hero-showcase { height: 340px; }
  }

  /* celulares chicos */
  @media (max-width: 560px) {
    .site-header__topbar-divider,
    .site-header__topbar-item { display: none; }
    .site-header__topbar-link { padding: 0.3rem 0.4rem; font-size: 0.65rem; }
    .site-header__logo-img { height: 75px; }
    .site-header__nav {
      min-height: 85px;
    }
    .site-header__nav > .site-shell {
      min-height: 85px;
    }
    .site-header__brand { margin-right: 1rem; }
    .site-header__actions { margin-left: 0.6rem; gap: 0.4rem; }
    .site-header__icon { width: 32px; height: 32px; }
    .site-header__icon svg { width: 18px; height: 18px; }
    .home-intro__gallery {
      grid-template-columns: 1fr;
      height: auto;
    }
    .home-intro__gallery figure.figure--main,
    .home-intro__gallery .figure--main {
      grid-row: auto;
      height: 220px;
    }
    .home-intro__gallery figure {
      height: 160px;
    }
    .home-intro__title { font-size: 1.85rem; }
    .hero-showcase { height: 280px; }
    .news-editorial { grid-template-columns: 1fr; }
    .news-editorial__feature { grid-template-columns: 1fr; }
    .news-editorial__feature-image { min-height: 200px; }
    .news-editorial__item { grid-template-columns: 1fr; min-height: auto; }
    .news-editorial__item-image { min-height: 180px; }
    .section-heading h2 { font-size: 1.5rem; }
    .academic-tab { min-width: 80px; padding: 0.5rem 0.8rem; font-size: 0.7rem; }
  }

  /* si el usuario prefiere menos movimiento, se quitan todas las transiciones */
  @media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; }
  }
}
