/* MC Mallas de Protección - Estilos principales - V2.0 - HEADER MOBILE FIX */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Montserrat', sans-serif;
  line-height: 1.6;
  color: #333;
  overflow-x: hidden;
}

/* Encabezado superior */
.top-header {
  background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
  color: white;
  padding: 15px 0;
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 1000;
  box-shadow: 0 2px 10px rgba(0,0,0,0.3);
  animation: headerSlideDown 1s ease-out;
}

@keyframes headerSlideDown {
  0% {
    transform: translateY(-100%);
    opacity: 0;
  }
  100% {
    transform: translateY(0);
    opacity: 1;
  }
}

.header-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 50px;
}

.company-name {
  text-align: center;
  flex: 0 1 auto;
}

.company-name h1 {
  font-size: 3em;
  font-weight: 900;
  font-family: 'Cinzel', serif;
  margin: 0;
  line-height: 1;
  animation: logoBounce 1.5s ease-out 0.5s both;
  letter-spacing: 2px;
}

@keyframes logoBounce {
  0% {
    opacity: 0;
    transform: scale(0.5) rotate(-10deg);
  }
  50% {
    opacity: 0.8;
    transform: scale(1.1) rotate(2deg);
  }
  100% {
    opacity: 1;
    transform: scale(1) rotate(0deg);
  }
}

@keyframes subtleRotate {
  0%, 100% {
    transform: rotate(-1deg);
  }
  50% {
    transform: rotate(1deg);
  }
}

.mc-highlight {
  color: #4CAF50;
  text-shadow: 0 0 10px rgba(76, 175, 80, 0.3);
  animation: glowPulse 3s ease-in-out infinite, subtleRotate 8s ease-in-out infinite;
  display: inline-block;
  transform-origin: center;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
  position: relative;
}

.mc-highlight::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, transparent 30%, rgba(76, 175, 80, 0.1) 50%, transparent 70%);
  animation: shimmer 4s ease-in-out infinite;
  pointer-events: none;
}

@keyframes shimmer {
  0%, 100% {
    transform: translateX(-100%);
  }
  50% {
    transform: translateX(100%);
  }
}

@keyframes glowPulse {
  0%, 100% {
    text-shadow: 0 0 10px rgba(76, 175, 80, 0.3), 0 0 20px rgba(76, 175, 80, 0.1);
  }
  50% {
    text-shadow: 0 0 20px rgba(76, 175, 80, 0.6), 0 0 30px rgba(76, 175, 80, 0.4), 0 0 40px rgba(76, 175, 80, 0.2);
  }
}

.proteccion-title {
  font-size: 1em;
  font-weight: 600;
  font-family: 'Playfair Display', serif;
  letter-spacing: 3px;
  margin-top: -5px;
  opacity: 0;
  animation: titleSlideIn 1s ease-out 1s forwards;
  text-transform: uppercase;
  color: #e0e0e0;
}

@keyframes titleSlideIn {
  0% {
    opacity: 0;
    transform: translateX(-20px);
  }
  100% {
    opacity: 0.9;
    transform: translateX(0);
  }
}

.nav-social {
  display: flex;
  align-items: center;
  justify-content: center;
}

.main-nav {
  display: flex;
  gap: 25px;
  justify-content: center;
}

.main-nav a {
  color: #4CAF50;
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  letter-spacing: 1px;
  transition: all 0.3s ease;
  padding: 8px 12px;
  border-radius: 4px;
  opacity: 0;
  animation: navFadeIn 0.8s ease-out forwards;
}

.main-nav a:nth-child(1) { animation-delay: 0.2s; }
.main-nav a:nth-child(2) { animation-delay: 0.4s; }
.main-nav a:nth-child(3) { animation-delay: 0.6s; }
.main-nav a:nth-child(4) { animation-delay: 0.8s; }

@keyframes navFadeIn {
  0% {
    opacity: 0;
    transform: translateY(-10px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.main-nav a:hover {
  background-color: #4CAF50;
  color: white;
  transform: translateY(-2px);
}

/* Sección Principal */
.hero-section {
  position: relative;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  margin-top: 80px;
  overflow: hidden;
}

.hero-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -2;
}

.hero-background img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(0,0,0,0.6) 0%, rgba(0,0,0,0.3) 100%);
  z-index: -1;
  animation: overlayFade 2s ease-out;
}

@keyframes overlayFade {
  0% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}

.hero-content {
  max-width: 800px;
  padding: 40px;
  z-index: 1;
  background: rgba(0, 0, 0, 0.25);
  border-radius: 15px;
  backdrop-filter: blur(6px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.hero-content h2 {
  font-size: 4.2em;
  font-weight: 800;
  font-family: 'Montserrat', sans-serif;
  color: white;
  margin-bottom: 20px;
  text-shadow: 
    3px 3px 6px rgba(0,0,0,0.8),
    0 0 20px rgba(0,0,0,0.6),
    0 0 40px rgba(0,0,0,0.4);
  opacity: 0;
  transform: translateY(30px);
  animation: fadeInUp 1.2s ease-out 0.3s forwards;
  line-height: 1.1;
  letter-spacing: -1px;
}

.hero-content p {
  font-size: 1.3em;
  color: white;
  margin-bottom: 30px;
  text-shadow: 
    2px 2px 4px rgba(0,0,0,0.8),
    0 0 15px rgba(0,0,0,0.5);
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 1.2s ease-out 0.6s forwards;
  font-weight: 500;
}

.cta-button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: linear-gradient(135deg, #4CAF50 0%, #45a049 100%);
  color: white;
  text-decoration: none;
  padding: 15px 30px;
  border-radius: 50px;
  font-weight: 600;
  font-size: 1.1em;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(76, 175, 80, 0.3);
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 1.2s ease-out 0.9s forwards;
}

.cta-button:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(76, 175, 80, 0.4);
  background: linear-gradient(135deg, #45a049 0%, #4CAF50 100%);
}

.hero-subtitle {
  margin-top: 20px;
  font-size: 1.1em;
  color: #e0e0e0;
  font-weight: 500;
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 1.2s ease-out 1.2s forwards;
  text-shadow: 
    1px 1px 3px rgba(0,0,0,0.7),
    0 0 10px rgba(0,0,0,0.4);
}

/* Sección Trabajos */
#trabajos {
  padding: 80px 20px;
  background: #f8f9fa;
}

#trabajos h2 {
  text-align: center;
  font-size: 2.5em;
  font-weight: 700;
  margin-bottom: 50px;
  color: #333;
}

.trabajos-gallery {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  padding: 0 20px;
}

.trabajo-item {
  background: white;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0,0,0,0.1);
  transition: all 0.3s ease;
  opacity: 0;
  transform: translateY(20px);
}

.trabajo-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.trabajo-item img {
  width: 100%;
  height: 250px;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.trabajo-item:hover img {
  transform: scale(1.05);
}

/* Sección Servicios */
#servicios {
  padding: 80px 20px;
  background: white;
}

#servicios h2 {
  text-align: center;
  font-size: 2.5em;
  font-weight: 700;
  margin-bottom: 50px;
  color: #333;
}

#servicios ul {
  max-width: 800px;
  margin: 0 auto;
  list-style: none;
}

#servicios li {
  padding: 15px 0;
  font-size: 1.2em;
  border-bottom: 1px solid #e0e0e0;
  position: relative;
  padding-left: 30px;
  text-align: center;
}

#servicios li:before {
  content: "✓";
  position: absolute;
  left: 0;
  color: #4CAF50;
  font-weight: bold;
  font-size: 1.2em;
}

/* Sección Beneficios */
#beneficios {
  padding: 80px 20px;
  background: #f8f9fa;
}

#beneficios h2 {
  text-align: center;
  font-size: 2.5em;
  font-weight: 700;
  margin-bottom: 50px;
  color: #333;
}

#beneficios ul {
  max-width: 800px;
  margin: 0 auto;
  list-style: none;
}

#beneficios li {
  padding: 15px 0;
  font-size: 1.2em;
  border-bottom: 1px solid #e0e0e0;
  position: relative;
  padding-left: 30px;
  text-align: center;
}

#beneficios li:before {
  content: "★";
  position: absolute;
  left: 0;
  color: #4CAF50;
  font-weight: bold;
  font-size: 1.2em;
}

/* Sección Contacto */
#contacto {
  padding: 80px 20px;
  background: white;
}

#contacto h2 {
  text-align: center;
  font-size: 2.5em;
  font-weight: 700;
  margin-bottom: 50px;
  color: #333;
}

.contacto-info {
  max-width: 600px;
  margin: 0 auto 50px;
  display: grid;
  gap: 20px;
}

.contacto-item {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 20px;
  background: #f8f9fa;
  border-radius: 10px;
  transition: all 0.3s ease;
}

.contacto-item:hover {
  background: #e9ecef;
  transform: translateX(5px);
}

.contacto-item i {
  color: #4CAF50;
  font-size: 1.5em;
  min-width: 30px;
}

.contacto-item a {
  color: #333;
  text-decoration: none;
  font-weight: 500;
}

.contacto-item a:hover {
  color: #4CAF50;
}

/* Formulario de contacto */
#form-contacto {
  max-width: 600px;
  margin: 0 auto;
  display: grid;
  gap: 20px;
}

#form-contacto label {
  font-weight: 600;
  color: #333;
  margin-bottom: 5px;
}

#form-contacto input,
#form-contacto textarea {
  padding: 15px;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  font-size: 16px;
  transition: border-color 0.3s ease;
  font-family: inherit;
}

#form-contacto input:focus,
#form-contacto textarea:focus {
  outline: none;
  border-color: #4CAF50;
  box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.1);
}

#form-contacto textarea {
  min-height: 120px;
  resize: vertical;
}

#form-contacto button {
  background: linear-gradient(135deg, #4CAF50 0%, #45a049 100%);
  color: white;
  border: none;
  padding: 15px 30px;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

#form-contacto button:hover {
  background: linear-gradient(135deg, #45a049 0%, #4CAF50 100%);
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(76, 175, 80, 0.3);
}

/* Footer */
footer {
  background: #1a1a1a;
  color: white;
  text-align: center;
  padding: 30px 20px;
  margin-top: 50px;
}

/* Diseño Responsivo */
@media (max-width: 768px) {
  /* Header responsivo */
  .header-content {
    flex-direction: column;
    gap: 15px;
    padding: 15px 20px;
    justify-content: center;
  }
  
  .company-name {
    margin: 5px 0;
  }
  
  .company-name h1 {
    font-size: 2.2em;
    margin-bottom: 5px;
  }
  
  .proteccion-title {
    font-size: 0.8em;
    letter-spacing: 2px;
  }
  
  .main-nav {
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
    width: 100%;
  }
  
  .main-nav a {
    font-size: 12px;
    padding: 6px 10px;
  }
  
  /* Hero section responsivo */
  .hero-section {
    height: 80vh;
    margin-top: 140px;
  }
  
  .hero-content {
    padding: 25px 20px;
    margin: 0 10px;
  }
  
  .hero-content h2 {
    font-size: 2.2em;
    line-height: 1.2;
    margin-bottom: 15px;
    text-shadow: 
      2px 2px 4px rgba(0,0,0,0.8),
      0 0 15px rgba(0,0,0,0.6);
  }
  
  .hero-content p {
    font-size: 1.1em;
    margin-bottom: 20px;
    text-shadow: 
      1px 1px 3px rgba(0,0,0,0.8),
      0 0 10px rgba(0,0,0,0.5);
  }
  
  .cta-button {
    padding: 12px 24px;
    font-size: 1em;
  }
  
  .hero-subtitle {
    font-size: 1em;
  }
  
  /* Secciones responsivas */
  #trabajos,
  #servicios,
  #beneficios,
  #contacto {
    padding: 60px 15px;
  }
  
  #trabajos h2,
  #servicios h2,
  #beneficios h2,
  #contacto h2 {
    font-size: 2em;
    margin-bottom: 30px;
  }
  
  .trabajos-gallery {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 15px;
    padding: 0 10px;
  }
  
  /* Listas responsivas */
  #servicios ul,
  #beneficios ul {
    padding: 0 15px;
    text-align: center;
  }
  
  #servicios li,
  #beneficios li {
    font-size: 1.1em;
    padding: 12px 0;
    text-align: center;
    padding-left: 0;
  }
  
  #servicios li:before,
  #beneficios li:before {
    position: relative;
    left: auto;
    margin-right: 10px;
  }
  
  /* Formulario responsivo */
  #form-contacto {
    padding: 0 15px;
  }
  
  #form-contacto input,
  #form-contacto textarea {
    font-size: 16px; /* Evita zoom en iOS */
  }
  
  #form-contacto button {
    width: 100%;
    padding: 15px;
  }
}

@media (max-width: 480px) {
  /* Header muy pequeño */
  .top-header {
    padding: 10px 0;
  }
  
  .header-content {
    padding: 8px 15px;
    gap: 12px;
    justify-content: center;
  }
  
  .company-name {
    margin: 3px 0;
  }
  
  .company-name h1 {
    font-size: 1.8em;
    margin-bottom: 4px;
  }
  
  .proteccion-title {
    font-size: 0.7em;
    letter-spacing: 1px;
  }
  
  .main-nav {
    gap: 8px;
    justify-content: center;
    width: 100%;
  }
  
  .main-nav a {
    font-size: 11px;
    padding: 5px 8px;
  }
  
  /* Hero section muy pequeño */
  .hero-section {
    height: 70vh;
    margin-top: 130px;
  }
  
  .hero-content h2 {
    font-size: 1.6em;
    line-height: 1.3;
    text-shadow: 
      2px 2px 4px rgba(0,0,0,0.8),
      0 0 12px rgba(0,0,0,0.6);
  }
  
  .hero-content p {
    font-size: 0.95em;
    text-shadow: 
      1px 1px 2px rgba(0,0,0,0.8),
      0 0 8px rgba(0,0,0,0.5);
  }
  
  .cta-button {
    padding: 10px 20px;
    font-size: 0.9em;
  }
  
  .hero-subtitle {
    font-size: 0.9em;
  }
  
  /* Secciones muy pequeñas */
  #trabajos,
  #servicios,
  #beneficios,
  #contacto {
    padding: 40px 10px;
  }
  
  #trabajos h2,
  #servicios h2,
  #beneficios h2,
  #contacto h2 {
    font-size: 1.6em;
    margin-bottom: 25px;
  }
  
  .trabajos-gallery {
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 0 5px;
  }
  
  .trabajo-item img {
    height: 200px;
  }
  
  /* Listas muy pequeñas */
  #servicios ul,
  #beneficios ul {
    padding: 0 10px;
    text-align: center;
  }
  
  #servicios li,
  #beneficios li {
    font-size: 1em;
    padding: 10px 0;
    text-align: center;
    padding-left: 0;
  }
  
  #servicios li:before,
  #beneficios li:before {
    position: relative;
    left: auto;
    margin-right: 8px;
  }
  
  /* Contacto muy pequeño */
  .contacto-info {
    gap: 15px;
  }
  
  .contacto-item {
    padding: 15px;
    font-size: 0.9em;
  }
  
  /* Formulario muy pequeño */
  #form-contacto {
    padding: 0 10px;
  }
  
  #form-contacto label {
    font-size: 0.9em;
  }
  
  #form-contacto input,
  #form-contacto textarea {
    padding: 12px;
    font-size: 16px;
  }
  
  #form-contacto button {
    padding: 12px;
    font-size: 0.9em;
  }
}

/* Ajustes para pantallas muy pequeñas */
@media (max-width: 360px) {
  .header-content {
    gap: 10px;
    padding: 6px 12px;
    justify-content: center;
  }
  
  .company-name {
    margin: 2px 0;
  }
  
  .company-name h1 {
    font-size: 1.6em;
    margin-bottom: 3px;
  }
  
  /* Hero section para pantallas muy pequeñas */
  .hero-section {
    height: 70vh;
    margin-top: 150px;
  }
  
  .hero-content h2 {
    font-size: 1.4em;
    text-shadow: 
      1px 1px 3px rgba(0,0,0,0.8),
      0 0 10px rgba(0,0,0,0.6);
  }
  
  .hero-content p {
    font-size: 0.9em;
    text-shadow: 
      1px 1px 2px rgba(0,0,0,0.8),
      0 0 6px rgba(0,0,0,0.5);
  }
  
  .main-nav {
    justify-content: center;
    width: 100%;
  }
  
  .main-nav a {
    font-size: 10px;
    padding: 4px 6px;
  }
}

/* Animaciones adicionales */
@keyframes fadeInUp {
  0% {
    opacity: 0;
    transform: translateY(40px) scale(0.95);
  }
  50% {
    opacity: 0.7;
    transform: translateY(10px) scale(0.98);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.fade-in-up {
  animation: fadeInUp 0.6s ease forwards;
}

/* Desplazamiento suave */
html {
  scroll-behavior: smooth;
}

/* Estilos para el mensaje de éxito */
#mensaje-exito {
  margin-top: 20px;
  padding: 15px;
  border-radius: 8px;
  text-align: center;
  font-weight: 600;
} 