/* =======================
   VARIABLES / RESET
======================== */
:root{
  --color-azul:#00609C;
  --color-naranja:#F47D30;
  --color-celeste:#00a8e8;
}

*{
  margin:0;
  padding:0;
  box-sizing:border-box;
  font-family:'Segoe UI', sans-serif;
}

html{ scroll-behavior: smooth; }

body{
  background:#fff;
}

/* =======================
   HEADER
======================== */
.top-header{
  display:flex;
  justify-content:space-between;
  align-items:center;
  padding:10px 5%;
  background:white;
  height:80px;
  box-shadow:0 2px 5px rgba(0,0,0,0.1);
  position:sticky;
  top:0;
  z-index:100;
}

.header-left{ display:flex; align-items:center; gap:20px; }
.logo{ height:50px; }
.separator{ width:1px; height:30px; background:#ccc; }

.menu-trigger{
  background:none;
  border:none;
  color:var(--color-azul);
  cursor:pointer;
  display:flex;
  align-items:center;
  gap:8px;
  font-size:18px;
  font-weight:500;
}

.email-box{
  color:var(--color-azul);
  font-weight:bold;
  display:flex;
  align-items:center;
  gap:8px;
}

.email-box a{ text-decoration:none; color:inherit; }
.email-box i{ color:var(--color-celeste); font-size:20px; }

/* =======================
   SIDEBAR + BACKDROP
======================== */
.sidebar-backdrop{
  position:fixed;
  inset:0;
  background:rgba(0,0,0,0.35);
  z-index:1000;
  opacity:0;
  pointer-events:none;
  transition:0.25s ease;
}

.sidebar-backdrop.show{
  opacity:1;
  pointer-events:auto;
}

.sidebar{
  position:fixed;
  top:0; left:0;
  width:300px;
  height:100vh;
  background:white;
  z-index:1001;
  padding:40px 20px;
  transform:translateX(-100%);
  transition:0.35s ease;
  box-shadow:5px 0 15px rgba(0,0,0,0.12);
}

.sidebar.active{ transform:translateX(0); }

.close-btn{
  position:absolute;
  top:20px;
  right:20px;
  background:none;
  border:none;
  font-size:24px;
  cursor:pointer;
  color:#666;
}

.sidebar-logo{ width:80%; margin-bottom:30px; }

.social-icons{
  display:flex;
  gap:10px;
  justify-content:center;
  margin-bottom:30px;
}

.social-icons a{
  background:var(--color-azul);
  color:white;
  width:35px;
  height:35px;
  display:flex;
  justify-content:center;
  align-items:center;
  border-radius:4px;
  text-decoration:none;
}

/* NAV */
.nav-links ul{ list-style:none; }
.nav-links li{ margin-bottom:15px; }
.nav-links a{
  text-decoration:none;
  color:var(--color-azul);
  font-weight:500;
  display:flex;
  align-items:center;
  justify-content:space-between;
}

.nav-links a.is-active{
  color: var(--color-naranja);
}

/* SUBMENU */
.submenu{
  max-height:0;
  overflow:hidden;
  transition:0.3s;
  background:#f9f9f9;
  padding-left:15px;
}
.submenu.show{
  max-height:300px;
  padding-top:10px;
}
.submenu li a{
  font-size:14px;
  color:#666;
}

/* =======================
   HERO PROYECTOS (relato.png)
======================== */
.proyecto-hero{
  position:relative;
  width:100%;
  height:320px;
  background-image:url("relato.png");
  background-size:cover;
  background-position:center;
  overflow:hidden;
}

.proyecto-hero__overlay{
  position:absolute;
  inset:0;
  background:rgba(0,96,156,0.70);
  z-index:1;
}

.proyecto-hero__content{
  position:relative;
  z-index:2;
  height:100%;
  display:flex;
  flex-direction:column;
  justify-content:center;
  align-items:center;
  text-align:center;
  padding:0 5%;
}

.proyecto-hero__title{
  color:#fff;
  font-size:36px;
  font-weight:800;
  letter-spacing:1px;
  text-transform:uppercase;
}

.proyecto-hero__line{
  width:90px;
  height:4px;
  background:var(--color-naranja);
  margin-top:12px;
  border-radius:2px;
}

@media (max-width:600px){
  .proyecto-hero{ height:240px; }
  .proyecto-hero__title{ font-size:28px; }
}

/* =======================
   GALERÍA
======================== */
.proyectos-main{
  background:#fff;
}

.proyectos-galeria{
  padding:70px 5%;
}

.proyectos-wrap{
  max-width:1200px;
  margin:0 auto;
}

.proyectos-grid{
  display:grid;
  grid-template-columns:repeat(4, 1fr);
  grid-auto-rows:220px;
  gap:18px;
}

/* Celdas */
.proy-cell,
.proy-tile{
  position:relative;
  width:100%;
  height:100%;
  border:0;
  padding:0;
  background:#f2f2f2;
  overflow:hidden;
  cursor:pointer;
  display:block;
}

.proy-cell img,
.proy-tile img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
  transform:scale(1);
  transition: transform .35s ease;
}

.proy-cell:hover img,
.proy-tile:hover img{
  transform: scale(1.04);
}

/* Alto (2 filas) */
.proy-cell--tall{ grid-row: span 2; }

/* Split: 2 imágenes en la misma celda (dos columnas) */
.proy-cell--split{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:18px;
  background:transparent;
  overflow:visible;
  cursor:default;
}

/* Hover (lupa) */
.proy-hover{
  position:absolute;
  inset:0;
  background:rgba(0,0,0,0.45);
  opacity:0;
  transition:0.25s ease;
  display:flex;
  align-items:flex-start;
  justify-content:flex-start;
  padding:14px;
}

.proy-cell:hover .proy-hover,
.proy-tile:hover .proy-hover{
  opacity:1;
}

.proy-icon{
  width:44px;
  height:44px;
  border-radius:50%;
  background:#fff;
  color:#111;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:16px;
}

/* Hover con borde + texto */
.proy-hover--boxed{
  align-items:stretch;
  justify-content:stretch;
  padding:18px;
}

.proy-hover--boxed::after{
  content:"";
  position:absolute;
  inset:18px;
  border:2px solid rgba(255,255,255,0.65);
}

.proy-icon--white{
  position:relative;
  z-index:2;
}

.proy-caption{
  position:absolute;
  left:26px;
  bottom:26px;
  color:#fff;
  font-size:18px;
  z-index:2;
  font-weight:700;
}

/* Responsive galería */
@media (max-width:1100px){
  .proyectos-grid{
    grid-template-columns:repeat(2, 1fr);
    grid-auto-rows:220px;
  }
  .proy-cell--tall{ grid-row: span 1; }
}

@media (max-width:650px){
  .proyectos-grid{
    grid-template-columns:1fr;
    grid-auto-rows:220px;
  }
  .proy-cell--split{ grid-template-columns:1fr; }
}

/* =======================
   LIGHTBOX
======================== */
.proy-lightbox{
  position:fixed;
  inset:0;
  display:none;
  z-index:3000;
}

.proy-lightbox.show{ display:block; }

.proy-lightbox__backdrop{
  position:absolute;
  inset:0;
  background:rgba(0,0,0,0.75);
}

.proy-lightbox__panel{
  position:absolute;
  left:50%;
  top:50%;
  transform:translate(-50%, -50%);
  width:min(980px, 92vw);
  background:#111;
  padding:14px;
  box-shadow:0 20px 60px rgba(0,0,0,0.45);
}

.proy-lightbox__img{
  width:100%;
  height:auto;
  display:block;
}

.proy-lightbox__caption{
  margin-top:10px;
  color:#eaeaea;
  font-size:14px;
  line-height:1.5;
}

.proy-lightbox__close{
  position:absolute;
  top:10px;
  right:10px;
  width:42px;
  height:42px;
  border:0;
  background:rgba(255,255,255,0.12);
  color:#fff;
  cursor:pointer;
}

.proy-lightbox__nav{
  position:absolute;
  top:50%;
  transform:translateY(-50%);
  width:46px;
  height:46px;
  border:0;
  cursor:pointer;
  color:#fff;
  background:rgba(255,255,255,0.12);
}

.proy-lightbox__prev{ left:10px; }
.proy-lightbox__next{ right:10px; }

/* =======================
   FOOTER
======================== */
.main-footer{
  background-color:#003354;
  color:white;
  padding:60px 5% 40px;
  position:relative;
}

.footer-container{
  display:grid;
  grid-template-columns:1.5fr 1fr 1fr;
  gap:40px;
  max-width:1200px;
  margin:0 auto;
}

.footer-col h3{
  font-size:1.3rem;
  margin-bottom:10px;
}

.footer-line{
  width:40px;
  height:3px;
  background-color:var(--color-naranja);
  margin-bottom:25px;
}

.footer-description{
  font-size:0.9rem;
  line-height:1.7;
  margin:20px 0;
  color:#cbd5e0;
}

.footer-social{
  display:flex;
  gap:15px;
}

.footer-social a{
  background:white;
  color:#003354;
  width:35px;
  height:35px;
  border-radius:50%;
  display:flex;
  justify-content:center;
  align-items:center;
  text-decoration:none;
  transition:0.3s;
}

.footer-social a:hover{
  background:var(--color-naranja);
  color:white;
}

.footer-col ul{ list-style:none; }
.footer-col ul li{ margin-bottom:12px; }

.footer-col ul li a{
  color:#cbd5e0;
  text-decoration:none;
  font-size:0.9rem;
  transition:0.3s;
}

.footer-col ul li a:hover{
  color:white;
  padding-left:5px;
}

.contact-item{
  display:flex;
  align-items:flex-start;
  gap:15px;
  margin-bottom:20px;
}

.contact-item i{
  font-size:1.5rem;
  color:#00a8e8;
}

.contact-item .info span{
  display:block;
  font-size:0.8rem;
  color:#00a8e8;
  text-transform:uppercase;
  font-weight:bold;
}

.contact-item .info p{
  font-size:0.95rem;
  margin-top:3px;
}

/* Botón subir (mejorado) */
.scroll-top-btn{
  position:absolute;
  bottom:20px;
  left:50%;
  transform:translateX(-50%);
  background:white;
  color:#003354;
  border:none;
  width:45px;
  height:45px;
  border-radius:50%;
  cursor:pointer;
  box-shadow:0 4px 10px rgba(0,0,0,0.3);
  opacity:0;
  pointer-events:none;
  transition:0.25s ease;
}

.scroll-top-btn.show{
  opacity:1;
  pointer-events:auto;
}

@media (max-width:900px){
  .footer-container{
    grid-template-columns:1fr;
    text-align:left;
  }
}

/* WhatsApp (si ya lo tenías, queda igual) */
.whatsapp-fixed{
  position:fixed;
  bottom:30px;
  right:30px;
  width:60px;
  height:60px;
  background-color:#25D366;
  color:white;
  border-radius:50%;
  display:flex;
  justify-content:center;
  align-items:center;
  font-size:35px;
  text-decoration:none;
  z-index:9999;
  box-shadow:0 4px 12px rgba(0,0,0,0.3);
  transition:all 0.3s ease;
}

.whatsapp-fixed:hover{
  transform:scale(1.1);
  background-color:#20ba5a;
  box-shadow:0 6px 16px rgba(0,0,0,0.4);
}

@media (max-width:600px){
  .whatsapp-fixed{
    bottom:20px;
    right:20px;
    width:50px;
    height:50px;
    font-size:30px;
  }
}
