/* ========================================
   GLOBAL RESET & TYPOGRAPHY
======================================== */
* { margin:0; padding:0; box-sizing:border-box; }
body {
    font-family:'Montserrat',sans-serif;
    line-height:1.6;
    color:#333;
    text-align:center;
    min-height:100vh;
    display:flex;
    flex-direction:column;
    background:#f4f4f4;
}

:root {
  --primary: #134866;
  --secondary: #ff6600;
  --accent: #ff4f5a;
}

/* ========================================
   HEADER
======================================== */
header {
    background:var(--primary);
    color:white;
    padding:50px 15px;
    position:relative;
    z-index:2;
}

header .logo {
    max-width: 220px;
    margin: 0 auto 28px auto;     /* ← ESTO ES LO IMPORTANTE */
    display: block;               /* ← y esto también */
    
    /* Tus animaciones bonitas (pégalas aquí debajo) */
    animation: logoFloat 5s infinite ease-in-out;
    filter: drop-shadow(0 6px 20px rgba(19,72,102,0.25));
    transition: all 0.6s ease;
    position: relative;           /* sí lo dejamos para el efecto ::after */
}

/* El resto de tu animación (flotación + brillo) */
@keyframes logoFloat {
    0%, 100% { transform: translateY(0) scale(1); }
    50%      { transform: translateY(-10px) scale(1.03); }
}

header:hover .logo {
    transform: translateY(-12px) scale(1.08);
    filter: drop-shadow(0 15px 40px rgba(19,72,102,0.4));
}

header .logo::after {
    content: '';
    position: absolute;
    top: 0; left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
}

header:hover .logo::after {
    animation: logoShine 1s ease-in-out;
}

@keyframes logoShine {
    0%   { left: -100%; }
    100% { left: 100%; }
}

header:hover .logo { transform:scale(1.05); }

header h1 { font-size:2.1em; margin:0 0 12px 0; font-weight:600; }
header p { font-size:1.15em; max-width:90%; margin:0 auto; opacity:.95; }

.background-wrapper {
    flex:1;
    background:#fff;
    padding:120px 15px 80px;
    display:flex;
    flex-direction:column;
    justify-content:center;
}
/* ========================================
   SERVICES GRID – VERSIÓN 2025 CORREGIDA PARA TABLETS
======================================== */
.services-grid {
  display: flex;
  flex-wrap: wrap;                    /* siempre wrap, nunca scroll horizontal feo */
  justify-content: center;
  gap: 40px;
  max-width: 1600px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Móviles – 1 columna */
@media (max-width: 767px) {
  .services-grid {
    gap: 35px;
    padding: 0 15px;
  }
  .service-card {
    flex: 0 0 100%;
    max-width: 420px;
    height: 520px;
  }
}

/* Tablets – 2 columnas (el rango crítico que tenías roto) */
@media (min-width: 768px) and (max-width: 1120px) {
  .services-grid {
    gap: 40px;
    padding: 0 30px;
  }
  .service-card {
    flex: 0 0 calc(50% - 20px);   /* dos tarjetas por fila */
    max-width: 460px;
    height: 560px;
  }
}

/* Escritorio grande – 3 columnas (solo cuando realmente cabe) */
@media (min-width: 1121px) {
  .services-grid {
    gap: 50px;
  }
  .service-card {
    flex: 0 0 460px;
    height: 580px;
  }
}

/* Aseguramos que nunca haya scroll horizontal en ningún dispositivo */
.services-grid {
  overflow-x: hidden !important;
}

.service-card {
  position: relative;
  width: 100%;
  flex: 0 0 460px;
  max-width: 460px;
  height: 580px;
  border-radius: 32px;
  overflow: hidden;
  background: #ffffff;
  transition: all 0.7s cubic-bezier(0.25, 0.8, 0.25, 1);
  opacity: 0;
  transform: translateY(40px);
  animation: fadeUp 1s ease-out forwards;
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
  border: 1px solid rgba(255, 255, 255, 0.4);
  background: linear-gradient(145deg, #ffffff, #f8f9fb);
}

.service-card:nth-child(1) { animation-delay: 0.2s; }
.service-card:nth-child(2) { animation-delay: 0.4s; }
.service-card:nth-child(3) { animation-delay: 0.6s; }

@keyframes fadeUp {
  to { opacity: 1; transform: translateY(0); }
}

.service-card:hover {
  transform: translateY(-18px);
  box-shadow: 0 16px 40px rgba(0,0,0,0.12);  /* ← Cambio: elevación natural sin exagerar */
}

.service-image {
  position: relative;
  height: 100%;
}

.service-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  aspect-ratio: 460 / 580;
  background: #f0f0f0;   
}

.service-card:hover .service-image img {
  transform: scale(1.08);
}

.service-info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, 
              rgba(0,0,0,0.82) 0%, 
              rgba(0,0,0,0.65) 60%, 
              rgba(0,0,0,0.55) 100%);
  padding: 36px 28px 32px;
  text-align: center;
  transition: all 0.6s cubic-bezier(0.25, 0.8, 0.25, 1);
  transform: translateY(120px);
  
}
.service-card:hover .service-info {
  transform: translateY(0);
}

.service-info h3 {
  color: white;
  font-size: 2rem;
  font-weight: 700;
  margin: 0 0 12px 0;
  letter-spacing: -0.5px;
}

.service-desc {
  color: white;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.6s ease;
}

.service-card:hover .service-desc {
  opacity: 1;
  transform: translateY(0);
}

.service-desc p {
  margin: 0 0 20px 0;
  line-height: 1.7;
  font-size: 1.05rem;
}

.btn-explore {
  display: inline-block;
  background: var(--secondary);
  color: white;
  padding: 12px 32px;
  border-radius: 50px;
  font-weight: 600;
  text-decoration: none;
  box-shadow: 0 8px 25px rgba(255,102,0,0.4);
  transition: all 0.3s ease;
}

.btn-explore:hover {
  transform: translateY(-3px);
  box-shadow: 0 15px 35px rgba(255,102,0,0.5);
}

/* Coming Soon */
.coming-soon .service-info {
  transform: translateY(0); /* siempre visible el título */
}

.coming-soon:hover .service-info {
  transform: translateY(0); /* no se mueve */
}

.watermark {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 4.8rem;
  font-weight: 900;
  color: rgba(255,255,255,0.9);
  text-transform: uppercase;
  letter-spacing: 12px;
  text-shadow: 0 12px 40px rgba(0,0,0,0.8);
  pointer-events: none;
  animation: pulseFade 3s infinite ease-in-out;
  z-index: 2;
}

@keyframes pulseFade {
  0%, 100% { opacity: 0.9; transform: translate(-50%, -50%) scale(1); }
  50% { opacity: 0.6; transform: translate(-50%, -50%) scale(0.96); }
}

.service-image {
  overflow: hidden;
  position: relative;
}

.service-image::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(45deg, 
              transparent 30%, 
              rgba(255,255,255,0.08) 50%, 
              transparent 70%);
  transform: translateX(-100%);
  transition: transform 1.2s ease;
  pointer-events: none;
  z-index: 2;
}

.service-image img {
  transition: all 1.6s cubic-bezier(0.25, 0.8, 0.25, 1);
  transform: scale(1.02);
  filter: brightness(1) contrast(1.05);
}

.service-card:hover .service-image img {
  transform: scale(1.11);
  filter: brightness(1.08) contrast(1.00);
}

.service-card:hover .service-image::after {
  transform: translateX(100%);   /* efecto de “brillo que pasa” */
}
/* ========================================
   CEO MESSAGE
======================================== */
.ceo-section { background:#f4f4f4; padding:60px 15px 0; }
.ceo-message {
    flex:1 1 100%;
    max-width:800px;
    background:linear-gradient(145deg,#e6e6e6,#f5f5f5);
    border-radius:22px;
    padding:35px;
    margin:30px auto;
    box-shadow:0 10px 30px rgba(0,0,0,.12),0 4px 15px rgba(0,0,0,.08),inset 0 1px 0 rgba(255,255,255,.6);
    border:1px solid #d0d0d0;
    position:relative;
    overflow:hidden;
    opacity:0;
    transform:translateY(60px);
    animation:slideUpBlock 1.2s cubic-bezier(.34,1.56,.64,1) .3s forwards;
}
@keyframes slideUpBlock {
    0%   { opacity:0; transform:translateY(60px) scale(.95); }
    70%  { opacity:1; transform:translateY(-10px) scale(1.02); }
    100% { opacity:1; transform:translateY(0) scale(1); }
}
.ceo-message::before, .ceo-message::after {
    content:'';
    position:absolute;
    left:0; right:0; height:5px;
    background:linear-gradient(90deg,var(--primary),#1a7ba3,var(--primary));
}
.ceo-message::before { top:0; border-radius:22px 22px 0 0; transform:scaleX(0); transform-origin:left; animation:lineExpand 1.5s ease-out 1s forwards; }
.ceo-message::after  { bottom:0; border-radius:0 0 22px 22px; opacity:.8; transform:scaleX(0); transform-origin:right; animation:lineExpand 1.5s ease-out 1.2s forwards; }
@keyframes lineExpand { 0% { transform:scaleX(0); } 100% { transform:scaleX(1); } }

.ceo-message h2 {
    font-size:1.9em;
    margin-bottom:22px;
    color:var(--primary);
    font-weight:600;
    display:flex;
    align-items:center;
    justify-content:center;
    gap:12px;
}
.ceo-message h2 span { opacity:0; transform:translateX(-20px); animation:typeWriter 1.8s steps(30) 1.4s forwards; }
@keyframes typeWriter { to { opacity:1; transform:translateX(0); } }
.ceo-message h2 i { color:#1a7ba3; font-size:1.3em; opacity:0; animation:fadeInIcon .8s ease-out 1.2s forwards; }
@keyframes fadeInIcon { to { opacity:.9; } }

.ceo-message .quote-text {
    text-align:left;
    font-size:1.02em;
    line-height:1.75;
    color:#444;
    max-width:640px;
    margin:0 auto;
    font-family:'Georgia',serif;
}
.ceo-message .quote-text p {
    margin-bottom:18px;
    padding-left:28px;
    position:relative;
    opacity:0;
    transform:translateX(-30px);
    animation:revealLine .8s ease-out forwards;
}
.ceo-message .quote-text p:nth-child(1) { animation-delay:1.8s; }
.ceo-message .quote-text p:nth-child(2) { animation-delay:2.1s; }
.ceo-message .quote-text p:nth-child(3) { animation-delay:2.4s; }
@keyframes revealLine { to { opacity:1; transform:translateX(0); } }
.ceo-message .quote-text p::before {
    content:'“';
    position:absolute;
    left:0;
    top:-2px;
    font-size:2.8em;
    color:var(--primary);
    opacity:.25;
    transform:scale(0);
    animation:popQuote .6s ease-out forwards;
}
.ceo-message .quote-text p:nth-child(1)::before { animation-delay:1.9s; }
.ceo-message .quote-text p:nth-child(2)::before { animation-delay:2.2s; }
.ceo-message .quote-text p:nth-child(3)::before { animation-delay:2.5s; }
@keyframes popQuote { 0% { transform:scale(0) rotate(-20deg); opacity:0; } 70% { transform:scale(1.3) rotate(10deg); } 100% { transform:scale(1) rotate(0); opacity:.25; } }

/* ========================================
   FOOTER INFO - ESTILO ORIGINAL (como antes)
======================================== */
/* styles.css (updated footer styles: elegant, clean, organized) */
.footer-info {
  background: var(--primary);
  color: white;
  padding: 4rem 5%;
  text-align: center;
}

.footer-columns {
  display: flex;
  justify-content: center;
  gap: 4rem;
  flex-wrap: wrap;
  max-width: 1200px; /* Slightly wider for better organization */
  margin: 0 auto;
}

.footer-column {
  flex: 1;
  min-width: 220px;
  max-width: 320px; /* Balanced width for elegance */
  padding: 1.5rem;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05); /* Subtle background for depth */
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.footer-column:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.footer-column h3 {
  font-size: 1.3rem;
  text-transform: uppercase;
  margin-bottom: 1.2rem;
  position: relative;
  padding-bottom: 0.6rem;
  letter-spacing: 1px;
}

.footer-column h3::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 50px; /* Slightly wider underline */
  height: 2px;
  background: var(--accent);
}

.footer-column p {
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 0.8rem;
  opacity: 0.9; /* Softer opacity for clean look */
}

.footer-address, .footer-phone, .footer-email {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 0.6rem;
  font-size: 0.95rem;
}

.footer-address i, .footer-phone i, .footer-email i {
  color: var(--accent);
  font-size: 1.1rem;
}

.footer-column a {
  color: white;
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-column a:hover {
  color: var(--accent);
}

/* ========================================
   FOOTER FINAL - FONDO BLANCO + TEXTO NEGRO
======================================== */
footer {
    background: #ffffff;
    color: #000000;
    text-align: center;
    padding: 20px 15px;
    font-size: 0.9em;
    font-weight: 700;
    border-top: 1px solid #e0e0e0;
}

footer {
    font-weight: 700 !important;
    letter-spacing: 0.5px;
    font-size: 1rem !important;
}

.social-icons {
  display: flex;
  justify-content: center;
  gap: 1.4rem;
  margin-top: 1.2rem;
}

.social-icons a {
  font-size: 1.8rem; /* Slightly larger icons */
  color: white;
  transition: color 0.3s ease, transform 0.3s ease;
}

.social-icons a:hover {
  color: var(--accent);
  transform: scale(1.15);
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .footer-columns {
    flex-direction: column;
    gap: 2.5rem;
  }

  .footer-column {
    max-width: 100%;
    padding: 1rem;
  }
}

.contact-item{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:.5rem;
  margin:.5rem 0
}

.contact-item i{color:var(--accent)}

.social-icons{
  display:flex;
  justify-content:center;
  gap:1.2rem;
  margin-top:1rem
}

.social-icons a{
  font-size:1.6rem;
  color:#fff;
  transition:color .3s
}

.social-icons a:hover{color:var(--accent)}

footer{
  text-align:center;
  padding:2rem;
  background:var(--light);
  color:var(--dark);
  font-size:.9rem
}

/* ========================================
   FOOTER FINAL - FONDO BLANCO + TEXTO NEGRO
======================================== */
footer {
    background: #ffffff;
    color: #000000;
    text-align: center;
    padding: 20px 15px;
    font-size: 0.9em;
    font-weight: 500;
    border-top: 1px solid #e0e0e0;
}

/* ========================================
   REDES SOCIALES FLOTANTES
======================================== */
.social-float-bar {
    position:fixed;
    left:15px;
    top:50%;
    transform:translateY(-50%);
    display:flex;
    flex-direction:column;
    gap:14px;
    background:rgba(255,255,255,0.05);
    padding:12px 8px;
    border-radius:50px;
    box-shadow:0 8px 25px rgba(0,0,0,.15);
    backdrop-filter:blur(10px);
    border:1px solid rgba(255,255,255,.3);
    z-index:999;
    animation:slideInLeft .6s ease-out forwards;
    opacity:0;
}
@keyframes slideInLeft { from { opacity:0; transform:translateX(-50px) translateY(-50%); } to { opacity:1; transform:translateX(0) translateY(-50%); } }

.social-btn {
    width:50px; height:50px;
    background:white;
    color:#fff;
    display:flex;
    align-items:center;
    justify-content:center;
    border-radius:50%;
    font-size:1.5rem;
    box-shadow:0 4px 12px rgba(0,0,0,.1);
    transition:all .3s cubic-bezier(.4,0,.2,1);
    position:relative;
    overflow:hidden;
}
.social-btn::before {
    content:'';
    position:absolute;
    top:50%; left:50%;
    width:0; height:0;
    background:rgba(255,255,255,.3);
    border-radius:50%;
    transform:translate(-50%,-50%);
    transition:width .6s,height .6s;
}
.social-btn:hover::before { width:300px; height:300px; }
.social-btn i { position:relative; z-index:1; transition:transform .3s; }
.social-btn:hover i { transform:scale(1.2); }

.social-btn.facebook { background:#1877F2; }
.social-btn.instagram { background:linear-gradient(135deg,#405DE6,#5851DB,#833AB4,#C13584,#E1306C,#FD1D1D); }
.social-btn.whatsapp { background:#25D366; }
.social-btn.whatsapp::after {
    content:'';
    position:absolute;
    width:100%; height:100%;
    border-radius:50%;
    background:rgba(37,211,102,.3);
    animation:pulse 2s infinite;
}
@keyframes pulse { 0% { transform:scale(1); opacity:1; } 100% { transform:scale(1.5); opacity:0; } }

/* ======================================== */
/* RESPONSIVE CONSOLIDADO – TODO PERFECTO EN MÓVIL (barra flotante visible, Follow Us funcional) */
/* ======================================== */

/* 1 – Header y logo */
@media (max-width: 768px) {
  header {
    padding: 30px 15px;
  }
  header .logo {
    max-width: 180px;
    margin-bottom: 20px;
  }
  header h1 {
    font-size: 1.8rem;
    line-height: 1.3;
  }
  header p {
    font-size: 1.05rem;
  }
}

/* 2 – Recuadros principales (full-width, sin desbordes) */
@media (max-width: 768px) {
  .background-wrapper {
    padding: 50px 10px 70px;
  }

  .services-grid {
    flex-direction: column !important;
    flex-wrap: nowrap !important;
    align-items: center;
    gap: 40px;
    padding: 0 10px;
    overflow-x: hidden;
    width: 100%;
    max-width: 100vw;
  }

  .service-card {
    flex: 0 0 auto !important;
    max-width: 100% !important;
    width: 100% !important;
    min-width: 0 !important;
    height: 520px;
    margin: 0 auto;
    overflow: hidden !important;
  }

  .service-image img {
    object-fit: cover !important;
    max-width: 100% !important;
    width: 100%;
    height: 100%;
  }

  .service-info {
    padding: 30px 20px;
  }

  .service-info h3 {
    font-size: 1.9rem;
  }

  .service-desc p {
    font-size: 1.05rem;
  }

  .btn-explore {
    padding: 14px 36px;
    font-size: 1rem;
  }
}

/* 3 – CEO Message */
@media (max-width: 768px) {
  .ceo-section {
    padding: 50px 15px 0;
  }
  .ceo-message {
    padding: 28px 20px;
    margin: 20px auto;
    max-width: 100%;
    overflow: hidden;
  }
  .ceo-message h2 {
    font-size: 1.7rem;
  }
  .ceo-message .quote-text {
    font-size: 1rem;
    line-height: 1.7;
  }
}

/* 4 – Footer */
@media (max-width: 768px) {
  .footer-columns {
    flex-direction: column;
    gap: 30px;
    text-align: center;
    padding: 0 15px;
  }
  .footer-column {
    max-width: 100%;
  }
  .social-icons {
    justify-content: center;
  }
}

/* 6 – Follow Us (social-icons en footer): funcional y con "animación" al tap en móvil */
.social-icons a {
  font-size: 1.8rem;
  color: white;
  transition: color 0.3s ease, transform 0.3s ease;
}

.social-icons a:hover, 
.social-icons a:active {  /* :active para tap en móvil */
  color: var(--accent);
  transform: scale(1.15);
}

/* 7 – Tipografía en móvil pequeño */
@media (max-width: 480px) {
  header h1 { font-size: 1.65rem; }
  header .logo { max-width: 160px; }
  .service-card { height: 480px; }
  .service-info h3 { font-size: 1.75rem; }
  .service-info { padding: 28px 20px; }
}

/* 8 – Global anti-desbordes */
html, body {
  overflow-x: hidden !important;
  scroll-behavior: smooth;
  max-width: 100vw;
}

img {
  display: block;
  width: 100%;
  height: auto;
  max-width: 100%;
}