/* ================= GLOBAL ================= */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;


}

 html, body {
  max-width: 100%;
  overflow-x: hidden;
}
/* ================= TYPOGRAPHY ================= */

body {
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 16px;
  line-height: 1.85;
  color: #1f2d3d;
  background: #f9fbfd;
}

/* Headings */
h1, h2, h3, h4 {
  font-family: 'Merriweather', Georgia, serif;
  font-weight: 700;
  line-height: 1.3;
  color: #0b1f3b;
}

h1 {
  font-size: 2.3rem;
  margin-bottom: 20px;
}

h2 {
  font-size: 1.7rem;
  margin-top: 60px;
  margin-bottom: 20px;
}

p {
  margin-bottom: 22px;
  font-size: 1.05rem;
}

/* Links editoriales */
a {
  color: #1f3c88;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* ================= HEADER ================= */
.header {
  position: fixed;
  top: 0;
  width: 100%;
  background: #ffffff;
  border-bottom: 1px solid #e6e9f0;
  z-index: 1000;
}

.container {
  max-width: 1200px;
  margin: auto;
  padding: 14px 20px;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo img {
  height: 42px;
}

/* NAV LINKS */
.nav-links {
  display: flex;
  gap: 24px;
}

.nav-links a {
  font-size: 0.9rem;
  font-weight: 600;
}

/* ACTIONS */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 18px;
}

/* LOGIN (institucional) */
.btn-login {
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
}

.btn-login:hover {
  text-decoration: underline;
}

/* LANG */
.lang-switch button {
  background: none;
  border: none;
  font-size: 0.75rem;
  cursor: pointer;
  margin-right: 4px;
  opacity: 0.6;
}

.lang-switch button.active {
  opacity: 1;
  text-decoration: underline;
}

/* MOBILE MENU */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 24px;
}

/* ================= HERO EDITORIAL ================= */

.hero-editorial {
  margin-top: 90px;
  padding: 40px 20px 0;
}

.hero-wrapper {
  max-width: 900px;
  margin: 0 auto;
}

/* Imagen editorial alineada al contenido */
/* HERO IMAGE – HORIZONTAL BANNER */
.hero-figure {
  max-height: 420px;          /* controla la altura del hero */
  overflow: hidden;
}

.hero-figure img {
  width: 100%;
  height: 400px;              /* misma altura que el contenedor */
  object-fit: cover;          /* 🔥 clave: recorta sin deformar */
  border-radius: 4px;


}


/* Texto del hero */
.hero-content {
  margin-top: 40px;
}

.hero-content h1 {
  font-size: 2.2rem;
  margin-bottom: 20px;
}

.hero-content p {
  font-size: 1.05rem;
  line-height: 1.8;
  color: #42526e;
}

/* ================= CONTENT ================= */

.content {
  padding: 80px 20px;
}

.content-wrapper {
  max-width: 900px;
  margin: auto;
  padding-bottom: 40px;
}

/* ================= UNIVERSITIES EDITORIAL ================= */

.universities-editorial {
  padding: 60px 20px;
  background: #ffffff;
}

.universities-editorial h2 {
  font-size: 1.6rem;
  margin-bottom: 20px;
}

.universities-intro {
  max-width: 700px;
  margin-bottom: 40px;
  color: #42526e;
}

.universities-list {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  align-items: center;
}

.universities-list a {
  display: inline-flex;
  align-items: center;
}

.universities-list img {
  height: 48px;
  width: auto;
  opacity: 0.75;
  transition: opacity 0.2s ease;
}

.universities-list img:hover {
  opacity: 1;
}

/* ================= SERVICES ================= */

.services {
  padding: 90px 20px;
  background: #ffffff;
}

.services h2 {
  text-align: center;
  margin-bottom: 50px;
}

.services-grid {
  max-width: 1100px;
  margin: auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
}

.service-card {
  background: #f9fbfd;
  padding: 36px;
  border: 1px solid #e6e9f0;
  border-radius: 6px;
}


/* ================= FOOTER ================= */

.site-footer {
  background: #0b1f3b;
  color: #cbd6e2;
  margin-top: 80px;
}

.footer-container {
  max-width: 1200px;
  margin: auto;
  padding: 60px 20px;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 40px;
}

.footer-brand img {
  height: 38px;
  margin-bottom: 15px;
}

.footer-links a {
  display: block;
  margin-bottom: 8px;
}

.footer-bottom {
  text-align: center;
  padding: 15px;
  font-size: 0.8rem;
  border-top: 1px solid rgba(255,255,255,0.1);
}

/* ================= MOBILE ================= */

@media (max-width: 900px) {

  .hero-figure img {
    height: 260px;   /* más bajo en móvil */
  }
  .menu-toggle {
    display: block;
  }

  .nav-links {
    display: none;
    flex-direction: column;
    position: fixed;
    top: 70px;
    left: 0;
    width: 100%;
    background: #ffffff;
    padding: 20px;
    z-index: 2000;
    box-shadow: 0 8px 30px rgba(0,0,0,0.08);
  }

  .nav-links.active {
    display: flex;
  }

  /* ✅ SERVICIOS: UNO DEBAJO DEL OTRO */
  .services-grid {
    display: block;      /* 🔥 CLAVE */
  }

  .service-card {
    width: 100%;
    margin-bottom: 24px;
  }

  .footer-container {
    grid-template-columns: 1fr;
    text-align: center;
  }
}




/* ================= EDITORIAL SEPARATORS ================= */

.section-divider {
  border: none;
  border-top: 1px solid #e6e9f0;
  margin: 70px 0;
}


/* ================= FOOTER SOCIAL ================= */

.footer-social h4 {
  font-size: 1rem;
  margin-bottom: 12px;
  color: #ffffff;
}

.social-icons {
  display: flex;
  gap: 14px;
}

.social-icons a {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
}

.social-icons img {
  width: 18px;
  height: 18px;
  object-fit: contain;
}

.social-icons a:hover {
  background: rgba(255,255,255,0.18);
}


/* ================= CONTACT MAP ================= */

.map-wrapper {
  margin: 40px 0;
  border: 1px solid #e6e9f0;
}

.map-wrapper iframe {
  width: 100%;
  height: 320px;
  border: none;
}

/* ================= CONTACT SOCIAL ================= */

.contact-social {
  display: flex;
  gap: 16px;
  margin-top: 16px;
}

.contact-social img {
  width: 28px;
  height: 28px;
  opacity: 0.7;
  transition: opacity 0.2s ease;
}

.contact-social img:hover {
  opacity: 1;
}

/* ================= AUTH (LOGIN / REGISTER) ================= */

.auth-section {
  padding: 140px 20px 80px;
  background: #f9fbfd;
}

.auth-wrapper {
  max-width: 420px;
  margin: auto;
  background: #ffffff;
  padding: 50px;
  border: 1px solid #e6e9f0;
}

.auth-wrapper h1 {
  font-size: 1.9rem;
  margin-bottom: 12px;
}

.auth-wrapper .lead {
  font-size: 0.95rem;
  color: #42526e;
  margin-bottom: 30px;
}

/* FORM */
.auth-form label {
  display: block;
  font-size: 0.85rem;
  margin-bottom: 6px;
  margin-top: 18px;
}

.auth-form input {
  width: 100%;
  padding: 10px 12px;
  font-size: 0.9rem;
  border: 1px solid #ccd5e0;
  border-radius: 2px;
}

.auth-form input:focus {
  outline: none;
  border-color: #1f3c88;
}

/* PRIMARY BUTTON */
.btn-primary {
  width: 100%;
  margin-top: 30px;
  padding: 12px;
  background: #1f3c88;
  color: #ffffff;
  border: none;
  font-size: 0.9rem;
  cursor: pointer;
}

.btn-primary:hover {
  background: #18306b;
}

/* DIVIDER */
.auth-divider {
  display: flex;
  align-items: center;
  margin: 30px 0;
}

.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: #e6e9f0;
}

.auth-divider span {
  padding: 0 12px;
  font-size: 0.8rem;
  color: #6b778c;
}

/* GOOGLE */
.btn-google {
  display: block;
  text-align: center;
  padding: 10px;
  border: 1px solid #ccd5e0;
  font-size: 0.9rem;
  margin-bottom: 20px;
}

.btn-google:hover {
  background: #f4f6f8;
}

/* FOOTER TEXT */
.auth-footer {
  font-size: 0.85rem;
  text-align: center;
}


/* ================= ALERT MESSAGES ================= */

.alert {
  padding: 12px 14px;
  margin-bottom: 20px;
  font-size: 0.85rem;
  border-left: 4px solid;
  background: #f9fbfd;
}

.alert-error {
  border-color: #c0392b;
  color: #7a1f16;
}

.alert-success {
  border-color: #1e8449;
  color: #145a32;
}


/* ================= INFORMATION BLOCKS ================= */

.info-block {
  max-width: 900px;
  margin: auto;
  padding: 70px 20px;
}

.info-block h2 {
  margin-top: 0;
}

.info-block p {
  color: #42526e;
}



/* ================= EDITORIAL SECTIONS (FIX) ================= */

.editorial-section {
  padding: 110px 20px;
  background: #f9fbfd;
}

.editorial-section.alt {
  background: #ffffff;
}

/* Layout real editorial */
.editorial-wrapper {
  max-width: 1200px;
  margin: auto;
  display: grid;
  grid-template-columns: 42% 58%;
  gap: 80px;
  align-items: center;
}

/* Imagen grande y protagonista */
.editorial-image {
  width: 100%;
}

.editorial-image img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 6px;
  box-shadow: 0 18px 40px rgba(0,0,0,0.1);
}

/* Texto balanceado */
.editorial-text h2 {
  margin-top: 0;
  margin-bottom: 24px;
}

.editorial-text p {
  font-size: 1.06rem;
  line-height: 1.9;
  color: #42526e;
}

.editorial-section.alt .editorial-wrapper {
  grid-template-columns: 58% 42%;
}

@media (max-width: 900px) {
  .editorial-wrapper {
    grid-template-columns: 1fr;
    gap: 45px;
  }

  .editorial-section {
    padding: 80px 20px;
  }
}



/* ================= CONTENT LISTS ================= */

.content ul {
  padding-left: 20px;
}

.content li {
  margin-bottom: 12px;
}

/* ===== INLINE CMS ICON FIX ===== */

/* ===== CMS INLINE ICON FIX FINAL ===== */

.hero-figure,
.editorial-image{
  position:relative;
}

/* Icono sobre imágenes */
.hero-figure .edit-icon,
.editorial-image .edit-icon{
  position:absolute;
  top:12px;
  right:12px;
  background:#ffffff;
  padding:6px 8px;
  border-radius:6px;
  box-shadow:0 4px 14px rgba(0,0,0,.18);
  font-size:14px;
  z-index:10000;
}

/* Texto */
.edit-icon{
  display:inline-block;
  margin-left:6px;
  opacity:.65;
  transition:.2s;
}

.edit-icon:hover{
  opacity:1;
  transform:scale(1.1);
}


/* Para imágenes */
figure, .editorial-image, .hero-figure{
  position:relative;
}

figure .edit-icon,
.editorial-image .edit-icon,
.hero-figure .edit-icon{
  position:absolute;
  top:8px;
  right:8px;
  background:#fff;
  padding:4px 6px;
  border-radius:4px;
  box-shadow:0 2px 8px rgba(0,0,0,.15);
}

.delete-icon{
  margin-left:6px;
  font-size:14px;
  opacity:.6;
  cursor:pointer;
}

.delete-icon:hover{
  opacity:1;
  color:#c0392b;
}

/* ===== CMS MODERN ICONS ===== */

.cms-btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:30px;
  height:30px;
  margin-left:6px;
  border-radius:50%;
  font-size:15px;
  font-weight:600;
  text-decoration:none;
  box-shadow:0 4px 12px rgba(0,0,0,.15);
  transition:.2s ease;
}

/* EDIT */
.edit-btn{
  background:#1f3c88;
  color:white;
}

.edit-btn:hover{
  transform:scale(1.1);
  background:#16306b;
}

/* DELETE */
.delete-btn{
  background:#e74c3c;
  color:white;
}

.delete-btn:hover{
  transform:scale(1.1);
  background:#c0392b;
}

/* dropdown */

.dropdown {
position: relative;
display: inline-block;
}

.dropbtn {
cursor: pointer;
}

.dropdown-content {

display: none;
position: absolute;
background: white;
min-width: 220px;
box-shadow: 0 8px 20px rgba(0,0,0,0.15);
border-radius: 6px;
z-index: 999;
}

.dropdown-content a {

display: block;
padding: 12px 16px;
color: #1f2d3d;
text-decoration: none;
font-size: 14px;
}

.dropdown-content a:hover {

background: #f5f5f5;

}

.dropdown:hover .dropdown-content {

display: block;

}


/* ================= RESEARCH ================= */

.research-section{

max-width:1200px;
margin:140px auto 80px;
padding:0 20px;

}

.research-title{

font-family:"Merriweather",serif;
font-size:34px;
margin-bottom:50px;
text-align:center;

}

.research-grid{

display:grid;
grid-template-columns:repeat(auto-fit,minmax(240px,1fr));
gap:40px;

}

.research-card{

background:white;
border-radius:8px;
box-shadow:0 8px 25px rgba(0,0,0,0.08);
padding:18px;
text-align:center;
transition:0.25s;

}

.research-card:hover{

transform:translateY(-6px);

}

.research-card img{

width:100%;
height:300px;
object-fit:cover;
border-radius:4px;
margin-bottom:15px;

}

.research-card h3{

font-family:"Merriweather",serif;
font-size:18px;
margin-bottom:10px;

}

.research-meta{

font-family:"Inter",sans-serif;
font-size:14px;
color:#666;
margin-bottom:16px;

}

.research-btn{

display:inline-block;
background:#1f3c88;
color:white;
padding:8px 14px;
border-radius:6px;
font-size:13px;
text-decoration:none;

}

.research-btn:hover{

background:#162f66;

}

