/* Merctel Legal - Estilos personalizados */

body {
  font-family: 'Roboto', sans-serif;
  scroll-behavior: smooth;
}

h1, h2, h3, h4, .serif {
  font-family: 'Playfair Display', serif;
}

.hero {
  background-image: linear-gradient(rgba(10, 46, 74, 0.8), rgba(10, 46, 74, 0.8)), url('https://cdn.pixabay.com/photo/2016/11/29/09/41/adult-1868982_1280.jpg');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
}

.service-card {
  transition: all 0.3s ease;
}

.service-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.team-member img {
  transition: all 0.3s ease;
}

.team-member:hover img {
  transform: scale(1.05);
}

.button-primary {
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.button-primary::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background-color: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width 0.5s, height 0.5s;
}

.button-primary:hover::after {
  width: 300px;
  height: 300px;
}

.navbar {
  transition: all 0.3s ease;
}

.navbar.scrolled {
  background-color: rgba(10, 46, 74, 0.95) !important;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.nav-link {
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: #d4af37;
  transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

.swiper {
  width: 100%;
  padding-bottom: 50px;
}

.testimonial-card {
  opacity: 0.7;
  transform: scale(0.9);
  transition: all 0.3s ease;
}

.swiper-slide-active .testimonial-card {
  opacity: 1;
  transform: scale(1);
}

.progress-bar {
  height: 4px;
  background-color: #d4af37;
  transition: width 0.3s ease;
}

/* Responsive Design */
@media (max-width: 768px) {
  .mobile-menu {
    transform: translateX(-100%);
    transition: transform 0.3s ease;
  }
  
  .mobile-menu.open {
    transform: translateX(0);
  }
  
  .hero h1 {
    font-size: 2.5rem;
    line-height: 1.2;
  }
  
  .hero p {
    font-size: 1.1rem;
  }
  
  .service-card {
    margin-bottom: 1rem;
  }
  
  .team-member img {
    height: 200px;
    width: 200px;
  }
  
  .testimonial-card {
    margin: 0 1rem;
  }
  
  .contact-form {
    padding: 1.5rem;
  }
  
  .grid-cols-1.md\\:grid-cols-2 {
    grid-template-columns: 1fr;
  }
  
  .text-4xl.md\\:text-6xl {
    font-size: 2.5rem;
  }
  
  .text-3xl.md\\:text-4xl {
    font-size: 2rem;
  }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 2rem;
  }
  
  .hero p {
    font-size: 1rem;
  }
  
  .container {
    padding-left: 1rem;
    padding-right: 1rem;
  }
  
  .py-20 {
    padding-top: 3rem;
    padding-bottom: 3rem;
  }
  
  .team-member img {
    height: 150px;
    width: 150px;
  }
}

/* Animaciones adicionales */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in-up {
  animation: fadeInUp 0.6s ease-out;
}

/* Estilos para formularios */
.form-input:focus {
  border-color: #0a2e4a;
  box-shadow: 0 0 0 3px rgba(10, 46, 74, 0.1);
}

.form-error {
  border-color: #dc2626;
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.1);
}

/* Estilos para mensajes */
.message-success {
  background-color: #d1fae5;
  border: 1px solid #10b981;
  color: #065f46;
}

.message-error {
  background-color: #fee2e2;
  border: 1px solid #ef4444;
  color: #991b1b;
}

/* Botón flotante de WhatsApp */
.whatsapp-float {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 1000;
}

.whatsapp-button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 60px;
  height: 60px;
  background-color: #25d366;
  color: white;
  border-radius: 50%;
  text-decoration: none;
  box-shadow: 0 4px 12px rgba(37, 211, 102, 0.4);
  transition: all 0.3s ease;
  animation: pulse 2s infinite;
}

.whatsapp-button:hover {
  background-color: #128c7e;
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.6);
  color: white;
}

.whatsapp-button i {
  font-size: 30px;
}

/* Animación de pulso para el botón */
@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(37, 211, 102, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(37, 211, 102, 0);
  }
}

/* Responsive para el botón de WhatsApp */
@media (max-width: 768px) {
  .whatsapp-float {
    bottom: 15px;
    right: 15px;
  }
  
  .whatsapp-button {
    width: 50px;
    height: 50px;
  }
  
  .whatsapp-button i {
    font-size: 24px;
  }
}

/* Tooltip para el botón de WhatsApp */
.whatsapp-button::before {
  content: "Chatear por WhatsApp";
  position: absolute;
  right: 70px;
  top: 50%;
  transform: translateY(-50%);
  background-color: #333;
  color: white;
  padding: 8px 12px;
  border-radius: 6px;
  font-size: 14px;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  z-index: 1001;
}

.whatsapp-button::after {
  content: "";
  position: absolute;
  right: 60px;
  top: 50%;
  transform: translateY(-50%);
  border: 6px solid transparent;
  border-left-color: #333;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  z-index: 1001;
}

.whatsapp-button:hover::before,
.whatsapp-button:hover::after {
  opacity: 1;
  visibility: visible;
}

/* Ocultar tooltip en móviles */
@media (max-width: 768px) {
  .whatsapp-button::before,
  .whatsapp-button::after {
    display: none;
  }
}
