/* --- Variables y Estilos Globales --- */
html {
  scroll-behavior: smooth;
}

:root {
  --dark-blue: #111827;
  --off-white: #fdfaf6;
  --light-cream: #ffffff;
  --gold: #d9a44e;
  --text-primary: #111827;
  --text-secondary: #4b5563;
  --hero-subtitle-blue: #3b82f6;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Montserrat", sans-serif;
  color: var(--text-secondary);
  line-height: 1.6;
  background-color: var(--light-cream);
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}

.text-center {
  text-align: center;
}

h1,
h2,
h3 {
  color: var(--text-primary);
  font-weight: 700;
}

section,
footer {
  padding: 80px 0;
}

.section-title {
  font-size: 2.5rem;
  margin-bottom: 20px;
  position: relative;
  display: inline-block;
}

.section-title::after {
  content: "";
  display: block;
  width: 60px;
  height: 3px;
  background-color: var(--gold);
  margin: 15px auto 0;
}

.hero {
  background-color: #112436;
  color: #e5e7eb;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 40px 20px;
  position: relative;
  overflow: hidden;
}
.hero-logo {
  display: block;
  margin: 0 auto 40px;
  max-width: 200px;
  height: auto;
}

/* Contenedor del texto y botones, para ponerlo encima del mapa */
.hero .container {
  position: relative;
  z-index: 2;
}

/* Estilos para el mapa SVG de fondo */
.hero-background-map {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 120%;
  height: 120%;
  object-fit: cover;
  z-index: 1;
  opacity: 0.55;
}

/* Estilos para el trazo del mapa y su animación */
.hero-background-map path {
  fill: none;
  stroke: #d9a44e;
  stroke-width: 2px;
  stroke-opacity: 0.5;
  animation: pulse-glow 6s ease-in-out infinite;
}

/* Animación de pulso de luz para el mapa */
@keyframes pulse-glow {
  0% {
    stroke-opacity: 0.2;
  }
  50% {
    stroke-opacity: 0.6;
  }
  100% {
    stroke-opacity: 0.2;
  }
}

.hero-title {
  font-size: clamp(2.8rem, 5vw, 4rem);
  color: #ffffff; /* Blanco */
  margin-bottom: 10px;
}

.hero-subtitle {
  font-size: clamp(1.4rem, 2.5vw, 1.75rem);
  color: #60a5fa;
  font-weight: 600;
  margin-bottom: 25px;
}

.hero-tagline {
  font-size: 1.1rem;
  color: #d1d5db; /* Gris claro */
  margin-bottom: 40px;
}

.hero-buttons {
  display: flex;
  justify-content: center;
  gap: 15px;
  flex-wrap: wrap;
}

.btn {
  display: inline-block;
  padding: 14px 32px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  transition: all 0.3s ease;
  border: 1px solid transparent;
}

/* Botón principal invertido */
.btn-primary {
  background-color: #ffffff;
  color: #112436;
}

.btn-primary:hover {
  background-color: #e5e7eb;
  transform: translateY(-3px);
}

/* Botón secundario con borde claro */
.btn-secondary {
  background-color: transparent;
  color: #ffffff;
  border: 1px solid #6b7280; /* Borde gris sutil */
}

.btn-secondary:hover {
  background-color: rgba(255, 255, 255, 0.1);
  border-color: #ffffff;
  transform: translateY(-3px);
}

/* --- Icono y animación del Mouse --- */
.mouse-scroll-icon {
  position: absolute;
  align-items: center;
  bottom: 30px;
  opacity: 0.7;
  z-index: 2;
}

.mouse-scroll-icon .scroll-wheel {
  animation-name: mouse-wheel-anim;
  animation-duration: 2s;
  animation-timing-function: ease-out;
  animation-iteration-count: infinite;
}

@keyframes mouse-wheel-anim {
  0% {
    transform: translateY(0);
    opacity: 1;
  }
  50% {
    transform: translateY(8px);
    opacity: 1;
  }
  100% {
    transform: translateY(12px);
    opacity: 0;
  }
}

/* --- 2. Vision & Mission Section --- */
.vision-mission {
  background-color: var(--dark-blue);
  color: #e5e7eb;
}

.vision-mission h2 {
  color: white;
  font-size: 2rem;
  margin-bottom: 15px;
}

.vision-mission-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  margin-bottom: 60px;
}

.section-label {
  color: var(--gold);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 1px;
  margin-bottom: 15px;
  position: relative;
  padding-bottom: 8px;
}

.section-label::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 30px;
  height: 2px;
  background-color: var(--gold);
}

.quote {
  font-size: 2rem;
  font-style: italic;
  color: var(--gold);
  text-align: center;
  border: none;
  padding: 0;
  margin: 0;
}

/* --- 3. What We Do Section --- */
.what-we-do {
  background-color: var(--off-white);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 30px;
  margin-top: 50px;
}

.service-card {
  background-color: var(--light-cream);
  padding: 30px;
  border-radius: 12px;
  text-align: left;
  border: 2px solid transparent;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.service-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
  border-color: #d79c42;
}

.icon-wrapper {
  background-color: #fbf5ed; /* Un color crema/amarillo claro */
  width: 60px;
  height: 60px;
  border-radius: 10%;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 20px;
}
.icon-wrapper svg {
  color: var(--gold);
}

.service-card h3 {
  font-size: 1.25rem;
  margin-bottom: 10px;
}

/* --- 4. Strategic Intelligence Section --- */
.strategic-intelligence {
  background-color: var(--light-cream);
}
.strategic-intelligence p {
  max-width: 800px;
  margin: 20px auto;
  font-size: 1.1rem;
  line-height: 1.7;
}
.highlight {
  color: var(--gold);
  font-weight: 600;
}

/* --- 5. Footer --- */
footer {
  background-color: var(--light-cream);
  border-top: 1px solid #e5e7eb;
}

.footer-logo {
  font-size: 2rem;
  font-weight: 700;
  color: var(--dark-blue);
  margin-bottom: 10px;
}

.footer-tagline {
  margin-bottom: 20px;
}

.footer-contact {
  margin-bottom: 20px;
}

.footer-contact a {
  color: var(--text-secondary);
  text-decoration: none;
  margin: 0 15px;
  transition: color 0.3s ease;
}

.footer-contact a:hover {
  color: var(--dark-blue);
}

.footer-copyright {
  font-size: 0.9rem;
  color: #9ca3af;
}

.footer-cta-btn {
  background-color: var(--dark-blue);
  color: white;
  margin: 20px auto 30px;
  display: inline-block;
  padding: 14px 32px;
}
.footer-cta-btn:hover {
  background-color: #374151;
  transform: translateY(-3px);
}

.footer-contact {
  margin-bottom: 20px;
}

/* --- Responsive Design --- */
@media (max-width: 768px) {
  h1 {
    font-size: 2.5rem;
  }
  h2 {
    font-size: 2rem;
  }
  .hero-title {
    font-size: 2.8rem;
  }
  .hero-subtitle {
    font-size: 1.4rem;
  }

  section,
  footer {
    padding: 60px 0;
  }

  .vision-mission-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .services-grid {
    grid-template-columns: 1fr;
  }

  .hero-buttons {
    flex-direction: column;
    align-items: center;
  }

  .btn {
    width: 80%;
    text-align: center;
  }
}

.mouse-scroll-icon .scroll-wheel {
  /*  animación */
  animation-name: mouse-wheel-anim;
  animation-duration: 2s;
  animation-timing-function: ease-out;
  animation-iteration-count: infinite;
}

@keyframes mouse-wheel-anim {
  /* Estado inicial: visible en la parte superior */
  0% {
    transform: translateY(0);
    opacity: 1;
  }
  /* A la mitad, se ha movido hacia abajo */
  50% {
    transform: translateY(8px);
    opacity: 1;
  }
  /* Estado final: se mueve un poco más y desaparece */
  100% {
    transform: translateY(12px);
    opacity: 0;
  }
}

/* --- Modal Form Styles --- */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(17, 24, 39, 0.8);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
  padding: 20px;
  overflow-y: auto;
}

.modal-content {
  background-color: #fdfaf6;
  padding: 32px;
  border-radius: 24px;
  max-width: 600px;
  width: 100%;
  position: relative;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
  max-height: calc(100vh - 40px);
  overflow-y: auto;
  /* Animación de entrada */
  transform: scale(0.95);
  opacity: 0;
  transition: transform 0.2s ease-out, opacity 0.2s ease-out;
}

.modal-overlay.visible .modal-content {
  transform: scale(1);
  opacity: 1;
}

.modal-close-btn {
  position: absolute;
  top: 20px;
  right: 20px;
  background: none;
  border: none;
  font-size: 2rem;
  color: #9ca3af;
  cursor: pointer;
  line-height: 1;
}

.modal-content h2 {
  color: var(--dark-blue);
  margin-bottom: 10px;
}

.modal-content p {
  color: var(--text-secondary);
  margin-bottom: 30px;
}

.modal-content form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.modal-content label {
  font-weight: 600;
  color: var(--dark-blue);
  font-size: 0.9rem;
  margin-bottom: -12px;
}

.modal-content input,
.modal-content select,
.modal-content textarea {
  width: 100%;
  padding: 12px 18px;
  border: 1px solid #d1d5db;
  border-radius: 12px;
  background-color: #ffffff;
  font-family: "Montserrat", sans-serif;
  font-size: 1rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.modal-content input:focus,
.modal-content select:focus,
.modal-content textarea:focus {
  outline: none;
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.2);
}

.modal-content select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
  background-position: right 0.7rem center;
  background-repeat: no-repeat;
  background-size: 1.5em 1.5em;
}

.btn-submit {
  background-color: var(--dark-blue);
  color: #ffffff;
  padding: 16px;
  border: none;
  border-radius: 12px;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: background-color 0.2s;
  margin-top: 10px;
}

.btn-submit:hover {
  background-color: #374151;
}

/* --- Custom Select Dropdown Styles --- */
.custom-select-wrapper {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 8px; /* Espacio entre el label y el select */
}

.custom-select {
  position: relative;
  cursor: pointer;
}

.custom-select__trigger {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 18px;
  border: 1px solid #d1d5db;
  border-radius: 12px;
  background-color: #ffffff;
  font-size: 1rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.custom-select__trigger span {
  color: #6b7280; /* Color del placeholder */
}

.custom-select.open .custom-select__trigger {
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.2);
}

.arrow {
  width: 10px;
  height: 10px;
  border-left: 2px solid #6b7280;
  border-bottom: 2px solid #6b7280;
  transform: rotate(-45deg);
  transition: transform 0.3s ease;
}

.custom-select.open .arrow {
  transform: rotate(135deg);
}
.custom-options {
  position: absolute;
  bottom: calc(100% + 8px); /* <-- CAMBIADO DE 'top' A 'bottom' */
  left: 5%; /* <-- CAMBIADO */
  right: -5%; /* <-- CAMBIADO */
  background-color: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
  z-index: 10;
  max-height: 300px; /* Puedes ajustar esto si necesitas más o menos altura */
  overflow-y: auto;
  display: none;
}

.custom-select.open .custom-options {
  display: block;
}

.custom-option {
  padding: 15px 20px;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.custom-option:hover {
  background-color: #fef3c7; /* Color crema/dorado claro para el hover */
}

.custom-option.selected {
  background-color: #d9a44e; /* Color dorado de la imagen */
  color: var(--dark-blue);
}

.custom-option.selected strong,
.custom-option.selected small {
  color: var(--dark-blue);
}

.custom-option strong {
  display: block;
  font-weight: 600;
  color: var(--dark-blue);
}

.custom-option small {
  color: var(--text-secondary);
  font-size: 0.9rem;
  display: block;
  margin-top: 4px;
}
