/* Sección de Contacto */
#via-contacto {
  padding: 80px 0;
  background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
  position: relative;
  overflow: hidden;
}

#via-contacto::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.1) 1px, transparent 1px);
  background-size: 50px 50px;
  opacity: 0.5;
  animation: backgroundMove 20s linear infinite;
}

@keyframes backgroundMove {
  0% {
    transform: translate(0, 0);
  }
  100% {
    transform: translate(50px, 50px);
  }
}

/* Títulos */
.contacto-title {
  font-size: 1.5em;
  font-weight: 700;
  color: #EC6618;
  text-transform: uppercase;
  margin-bottom: 1.5em;
}

.contacto-subtitle {
  font-size: 1.1rem;
  color: #555;
  line-height: 1.8;
  margin-top: 25px;
}

/* Tarjetas de Contacto */
.contact-card {
  background: #ffffff;
  border-radius: 15px;
  padding: 40px 30px;
  text-align: center;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  position: relative;
  overflow: hidden;
  height: 100%;
  border: 1px solid rgba(0, 0, 0, 0.05);
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  min-height: 340px;
}

.contact-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.5s;
}

.contact-card:hover::before {
  left: 100%;
}

.contact-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

/* Iconos */
.contact-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto 25px;
  background: linear-gradient(145deg, #EC6618 0%, #d35400 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.4s ease;
  position: relative;
}

.contact-icon::after {
  content: '';
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 2px solid #EC6618;
  opacity: 0;
  transform: scale(1);
  transition: all 0.4s ease;
}

.contact-card:hover .contact-icon::after {
  opacity: 1;
  transform: scale(1.2);
}

.contact-card:hover .contact-icon {
  transform: rotateY(360deg);
}

.contact-icon i {
  font-size: 2.2rem;
  color: #ffffff;
}

/* Iconos específicos por tipo (unificados a la paleta de marca) */
.whatsapp-icon, .phone-icon { background: linear-gradient(145deg, #EC6618 0%, #d35400 100%); }
.whatsapp-icon::after, .phone-icon::after { border-color: #EC6618; }

/* Títulos de tarjetas */
.contact-title {
  font-size: 1.4rem;
  font-weight: 600;
  color: #2c3e50;
  margin-bottom: 15px;
  transition: color 0.3s ease;
}

.contact-card:hover .contact-title {
  color: #EC6618;
}

/* Descripción */
.contact-description {
  font-size: 0.95rem;
  color: #7f8c8d;
  margin-bottom: 20px;
  line-height: 1.6;
}

/* Enlaces */
.contact-link {
  display: inline-block;
  font-size: 1rem;
  font-weight: 600;
  color: #EC6618;
  text-decoration: none;
  padding: 12px 30px;
  border: 2px solid #EC6618;
  border-radius: 50px;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  z-index: 1;
  margin-top: auto; /* Empuja el botón al fondo de la tarjeta */
}

.contact-link::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 100%;
  background: linear-gradient(145deg, #EC6618 0%, #d35400 100%);
  transition: width 0.4s ease;
  z-index: -1;
}

.contact-link:hover::before {
  width: 100%;
}

.contact-link:hover {
  color: #ffffff;
  text-decoration: none;
  transform: scale(1.05);
}

/* Responsive */
@media (max-width: 991px) {
  #via-contacto {
    padding: 60px 0;
  }

  .contacto-title {
    font-size: 2rem;
  }

  .contact-card {
    padding: 35px 25px;
    margin-bottom: 20px;
  }
}

@media (max-width: 767px) {
  #via-contacto {
    padding: 50px 0;
  }

  .contacto-title {
    font-size: 1.8rem;
  }

  .contacto-subtitle {
    font-size: 1rem;
    padding: 0 15px;
  }

  .contact-card {
    padding: 30px 20px;
    min-height: 280px; /* Ajuste para pantallas medianas */
  }

  .contact-icon {
    width: 70px;
    height: 70px;
  }

  .contact-icon i {
    font-size: 2rem;
  }

  .contact-title {
    font-size: 1.3rem;
  }

  .contact-description {
    font-size: 0.9rem;
  }

  .contact-link {
    font-size: 0.95rem;
    padding: 10px 25px;
  }
}

@media (max-width: 575px) {
  .contacto-title {
    font-size: 1.6rem;
  }

  .contacto-subtitle {
    font-size: 0.95rem;
  }

  .contact-card {
    padding: 25px 15px;
    min-height: auto; /* Quita altura mínima en móviles pequeños */
  }

  .contact-icon {
    width: 65px;
    height: 65px;
  }

  .contact-icon i {
    font-size: 1.8rem;
  }
}
