/* ================================
   REFORMAS CANOVELLES
   Estilos Globales
   ================================ */

/* Importar Fuentes Modernas */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;700;800;900&family=Open+Sans:wght@400;600&display=swap');

:root {
  /* Colores principales */
  --primary-color: #F4B400;
  --primary-dark: #D69C00;
  --secondary-color: #1a2530;
  /* Un poco más oscuro y azulado para toque moderno */
  --accent-color: #3498DB;
  --text-dark: #1a2530;
  --text-light: #5a6570;
  --bg-light: #F4F6F8;
  --bg-white: #FFFFFF;
  --border-color: #E0E0E0;
  --success-color: #27AE60;

  /* Tipografía Actualizada */
  --font-primary: 'Open Sans', sans-serif;
  --font-heading: 'Montserrat', sans-serif;
  /* Fuente más geométrica y moderna */

  /* Espaciado */
  --spacing-xs: 0.5rem;
  --spacing-sm: 1rem;
  --spacing-md: 2rem;
  --spacing-lg: 3rem;
  --spacing-xl: 5rem;
  /* Más aire */

  /* Sombras */
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 15px 30px rgba(0, 0, 0, 0.12);

  /* Transiciones */
  --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* Reset y Base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-primary);
  color: var(--text-dark);
  line-height: 1.7;
  background-color: var(--bg-white);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Tipografía */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  font-weight: 800;
  /* Más peso */
  line-height: 1.1;
  margin-bottom: var(--spacing-sm);
  color: var(--secondary-color);
  letter-spacing: -0.5px;
}

h1 {
  font-size: clamp(2.5rem, 6vw, 4rem);
  text-transform: uppercase;
}

h2 {
  font-size: clamp(2rem, 4vw, 3rem);
}

h3 {
  font-size: clamp(1.5rem, 3vw, 2rem);
}

h4 {
  font-size: 1.5rem;
}

h5 {
  font-size: 1.25rem;
}

h6 {
  font-size: 1rem;
}

p {
  margin-bottom: var(--spacing-sm);
  color: var(--text-light);
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Contenedores */
.container {
  max-width: 1240px;
  /* Un poco más ancho */
  margin: 0 auto;
  padding: 0 var(--spacing-sm);
}

.container-fluid {
  width: 100%;
  padding: 0 var(--spacing-sm);
}

/* Header */
.header {
  background-color: rgba(0, 0, 0, 0.1);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  transition: var(--transition);
}

.header-top {
  background-color: transparent;
  color: white;
  padding: 8px 0;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.5px;
}

/* Ocultar header-top en móvil */
@media (max-width: 768px) {
  .header-top {
    display: none !important;
  }
}

.header-top .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--spacing-sm);
}

.header-top a {
  color: white;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  opacity: 0.9;
}

.header-top a:hover {
  color: var(--primary-color);
  opacity: 1;
}

.header-main {
  padding: 1rem 0;
  background-color: transparent;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--spacing-md);
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: transform 0.3s ease;
}

.logo:hover {
  transform: scale(1.02);
}

.logo-image {
  max-height: 65px;
  width: auto;
}

/* Navegación */
.nav-menu {
  display: flex;
  list-style: none;
  gap: 2rem;
  align-items: center;
}

.nav-menu a {
  color: white;
  font-weight: 600;
  font-family: var(--font-heading);
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 0.5rem 0;
  position: relative;
}

.nav-menu a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 3px;
  background-color: var(--primary-color);
  transition: var(--transition);
}

.nav-menu a:hover::after,
.nav-menu a.active::after {
  width: 100%;
}

/* Eliminar subrayado del dropdown-toggle */
.nav-dropdown .dropdown-toggle::after {
  display: none !important;
  content: none !important;
}

.nav-dropdown .dropdown-toggle:hover::after,
.nav-dropdown .dropdown-toggle.active::after {
  display: none !important;
  width: 0 !important;
}

/* Menú desplegable */
.nav-dropdown {
  position: relative;
}

.dropdown-toggle {
  cursor: pointer;
}

.dropdown-arrow {
  font-size: 0.7rem;
  margin-left: 0.3rem;
  transition: transform 0.3s ease;
  display: inline-block;
}

.nav-dropdown:hover .dropdown-arrow {
  transform: rotate(180deg);
}

.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  background-color: white;
  list-style: none;
  padding: 0.5rem 0;
  margin: 0;
  min-width: 220px;
  box-shadow: var(--shadow-lg);
  border-radius: 4px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all 0.3s ease;
  z-index: 1000;
  margin-top: 0.5rem;
}

.nav-dropdown:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-menu li {
  margin: 0;
}

.dropdown-menu a {
  display: block;
  padding: 0.75rem 1.5rem;
  color: var(--text-dark);
  font-weight: 600;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: var(--transition);
  position: relative;
}

.dropdown-menu a::after {
  display: none;
}

.dropdown-menu a:hover {
  background-color: var(--bg-light);
  color: var(--primary-color);
  padding-left: 2rem;
}

.dropdown-menu a.active {
  background-color: var(--primary-color);
  color: white;
}

/* Estilo especial para el botón de WhatsApp en header */
.header-whatsapp {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem;
  border-radius: 50%;
  background-color: #25D366;
  transition: all 0.3s ease;
  width: 44px;
  height: 44px;
  min-width: 44px;
}

.header-whatsapp:hover {
  transform: scale(1.1);
  background-color: #128C7E;
  box-shadow: 0 4px 12px rgba(37, 211, 102, 0.4);
}

.header-whatsapp svg {
  width: 24px;
  height: 24px;
  fill: white;
}

/* Estilo especial para el botón del header */
.nav-menu .btn-primary {
  padding: 0.6rem 1.5rem !important;
  font-size: 0.9rem !important;
  border-radius: 4px !important;
  /* Cuadrado */
  background-color: var(--primary-color);
  color: var(--secondary-color);
  text-transform: uppercase;
  box-shadow: none;
}

.nav-menu .btn-primary:hover {
  background-color: var(--text-dark);
  color: var(--primary-color);
  transform: translateY(-1px);
}

.menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  color: white;
  cursor: pointer;
}

/* Botones Modernos - Menos Redondos */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 2.5rem;
  border: none;
  border-radius: 6px;
  /* Borde sutil, no redondo */
  font-weight: 700;
  font-family: var(--font-heading);
  font-size: 1rem;
  cursor: pointer;
  transition: var(--transition);
  text-align: center;
  justify-content: center;
  text-decoration: none;
  white-space: nowrap;
  letter-spacing: 0.5px;
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.btn-primary {
  background-color: var(--primary-color);
  color: var(--secondary-color);
  box-shadow: 0 4px 15px rgba(244, 180, 0, 0.3);
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 100%;
  background-color: var(--secondary-color);
  transition: var(--transition);
  z-index: -1;
}

.btn-primary:hover {
  color: white;
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(244, 180, 0, 0.4);
}

.btn-primary:hover::before {
  width: 100%;
}

.btn-secondary {
  background-color: transparent;
  color: var(--secondary-color);
  border: 2px solid var(--secondary-color);
}

.btn-secondary:hover {
  background-color: var(--secondary-color);
  color: white;
  transform: translateY(-3px);
}

.btn-whatsapp {
  background: #25D366;
  color: white;
  border: 1px solid #25D366;
  font-weight: 800;
}

.btn-whatsapp:hover {
  background: #128C7E;
  border-color: #128C7E;
  color: white;
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(37, 211, 102, 0.3);
}

.btn-whatsapp svg {
  fill: currentColor;
  margin-right: 8px;
}

.btn-large {
  padding: 1.25rem 3rem;
  font-size: 1.1rem;
  text-transform: uppercase;
}

.btn-icon {
  font-size: 1.2rem;
}

/* Botón flotante de llamada */
.floating-call-btn {
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 999;
  background-color: #25D366;
  /* WhatsApp Green */
  color: white;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  /* Rounded for WhatsApp style */
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  animation: float 3s ease-in-out infinite;
  text-decoration: none;
  border: none;
  /* Removed white border */
  transition: all 0.3s ease;
}

.floating-call-btn:hover {
  transform: scale(1.1);
  background-color: #128C7E;
  /* Darker green on hover */
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.4);
}

.floating-call-btn svg {
  width: 35px;
  height: 35px;
  fill: white;
}

@keyframes float {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-10px);
  }
}

/* Secciones */
.section {
  padding: var(--spacing-xl) 0;
}

.section-title {
  text-align: center;
  margin-bottom: var(--spacing-xl);
  position: relative;
}

.section-title h2 {
  font-size: 2.5rem;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.section-title h2::after {
  content: '';
  display: block;
  width: 60px;
  height: 4px;
  background-color: var(--primary-color);
  margin: 1rem auto 0;
}

.section-subtitle {
  color: var(--text-light);
  font-size: 1.2rem;
  max-width: 700px;
  margin: 0 auto;
}

.section-bg {
  background-color: var(--bg-light);
}

/* Grid de tarjetas Modernas */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: var(--spacing-md);
}

.card {
  background-color: white;
  border-radius: 8px;
  /* Menos radio */
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  border: none;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.card:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-lg);
}

.card-image {
  width: 100%;
  height: 240px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  transition: transform 0.5s ease;
}

.card:hover .card-image {
  transform: scale(1.05);
}

.card-content {
  padding: 2rem;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.card-title {
  font-size: 1.4rem;
  margin-bottom: 1rem;
  color: var(--secondary-color);
  padding: 0;
}

.card-text {
  color: var(--text-light);
  margin-bottom: 1.5rem;
  padding: 0;
  flex-grow: 1;
}

.card .btn {
  margin: 0;
  align-self: flex-start;
  padding: 0.75rem 1.5rem;
  font-size: 0.9rem;
}

/* Footer */
.footer {
  background-color: #111820;
  color: white;
  padding: var(--spacing-xl) 0 2rem;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer-section h3 {
  color: white;
  margin-bottom: 1.5rem;
  font-size: 1.1rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  border-left: 3px solid var(--primary-color);
  padding-left: 1rem;
}

.footer-section p,
.footer-section a {
  color: #a0aab5;
  margin-bottom: 0.75rem;
  display: block;
  font-size: 0.95rem;
}

.footer-section a:hover {
  color: var(--primary-color);
  padding-left: 5px;
}

.footer-map {
  border-top: 1px solid #2c3540;
  padding-top: 3rem;
}

.map-container-footer iframe {
  border-radius: 8px;
  filter: grayscale(100%);
  transition: filter 0.3s;
}

.map-container-footer iframe:hover {
  filter: grayscale(0%);
}

.footer-bottom {
  border-top: 1px solid #2c3540;
  padding-top: 2rem;
  margin-top: 3rem;
  text-align: center;
  color: #6c757d;
  font-size: 0.85rem;
}

/* Social Links */
.social-links {
  display: flex;
  flex-direction: row;
  /* Cambiado a fila */
  flex-wrap: wrap;
  gap: 0.75rem;
}

.social-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem 1rem;
  background-color: rgba(255, 255, 255, 0.05);
  border-radius: 4px;
  font-size: 0.9rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.social-links a:hover {
  background-color: var(--primary-color);
  color: var(--text-dark);
  border-color: var(--primary-color);
  transform: translateY(-3px);
  padding-left: 1rem;
  /* Override del padding genérico */
}

/* Formularios Modernos */
.form-control {
  width: 100%;
  padding: 1rem;
  background-color: #f8f9fa;
  border: 2px solid transparent;
  border-radius: 6px;
  font-size: 1rem;
  font-family: var(--font-primary);
  transition: var(--transition);
}

.form-control:focus {
  outline: none;
  background-color: white;
  border-color: var(--primary-color);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
}

/* Responsive */
@media (max-width: 768px) {

  /* Ocultar header-top completamente en móvil */
  .header-top {
    display: none !important;
  }

  .header-top .container {
    justify-content: center;
    text-align: center;
  }

  .nav-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background-color: rgba(0, 0, 0, 0.8);
    flex-direction: column;
    padding: 2rem;
    box-shadow: var(--shadow-lg);
    gap: 1rem;
    display: none;
  }

  .nav-menu.active {
    display: flex;
  }

  .menu-toggle {
    display: block;
  }

  .nav-menu .btn-primary {
    width: 100%;
    text-align: center;
  }

  /* Menú desplegable en móvil */
  .nav-dropdown {
    width: 100%;
  }

  .dropdown-toggle {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background: transparent;
    color: var(--text-dark);
    border-radius: 6px;
    font-weight: 700;
    font-size: 1rem;
    margin: 0.5rem 0;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    position: relative;
  }

  /* Eliminar el subrayado amarillo del dropdown-toggle en móvil */
  .dropdown-toggle::after {
    display: none !important;
  }

  .dropdown-toggle:hover,
  .dropdown-toggle:active {
    background-color: var(--bg-light);
    color: var(--text-dark);
  }

  .dropdown-toggle:hover::after,
  .dropdown-toggle.active::after {
    display: none !important;
  }

  .dropdown-arrow {
    font-size: 0.75rem;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-left: 0.5rem;
    width: 24px;
    height: 24px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: var(--secondary-color);
    border-radius: 50%;
    font-weight: 900;
    box-shadow: 0 2px 6px rgba(244, 180, 0, 0.3);
  }

  .nav-dropdown.active .dropdown-toggle .dropdown-arrow {
    background: linear-gradient(135deg, var(--text-dark) 0%, #2c3540 100%);
    color: var(--primary-color);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  }

  .nav-dropdown.active .dropdown-arrow {
    transform: rotate(180deg);
  }

  .nav-dropdown.active .dropdown-toggle {
    background-color: var(--bg-light);
    color: var(--text-dark);
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
  }

  .dropdown-menu {
    position: static;
    opacity: 1;
    visibility: visible;
    transform: none;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    background-color: transparent;
    margin-top: 0;
    margin-left: 0;
    margin-right: 0;
    border: 2px solid var(--primary-color);
    border-top: none;
    border-radius: 0 0 8px 8px;
    display: none;
    padding: 0.5rem 0;
    overflow: hidden;
  }

  .nav-dropdown.active .dropdown-menu {
    display: block;
    animation: slideDown 0.3s ease-out;
  }

  @keyframes slideDown {
    from {
      opacity: 0;
      max-height: 0;
      transform: translateY(-10px);
    }

    to {
      opacity: 1;
      max-height: 500px;
      transform: translateY(0);
    }
  }

  .dropdown-menu a {
    padding: 0.85rem 1.5rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    font-weight: 600;
    display: flex;
    align-items: center;
    transition: all 0.2s ease;
  }

  .dropdown-menu a:last-child {
    border-bottom: none;
  }

  .dropdown-menu a:hover {
    background-color: var(--bg-light);
    padding-left: 2rem;
    color: var(--primary-color);
    transform: translateX(5px);
  }

  .dropdown-menu a.active {
    background: linear-gradient(90deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    font-weight: 700;
    border-left: 4px solid var(--secondary-color);
  }
}