:root {
  --primary: #211261;
  --secondary: #E16C02;
  --white: #FFFFFF;
  --light-gray: #f8f9fa;
  --dark-gray: #343a40;
}

body {
  font-family: 'Roboto', 'Helvetica Neue', sans-serif;
  overflow-x: hidden;
}

.text-primary-custom {
  color: var(--primary);
}

.text-secondary-custom {
  color: var(--secondary);
}

.bg-primary-custom {
  background-color: var(--primary);
}

.bg-secondary-custom {
  background-color: var(--secondary);
}

.btn-primary-custom {
  background-color: var(--primary);
  border-color: var(--primary);
  color: white;
  transition: all 0.3s ease;
}

.btn-primary-custom:hover {
  color: rgb(196, 196, 196);
  background-color: #002b52;
  border-color: #002b52;
}

.btn-secondary-custom {
  background-color: var(--secondary);
  border-color: var(--secondary);
  color: white;
  transition: all 0.3s ease;
}

.btn-secondary-custom:hover {
  color: rgb(196, 196, 196);
  background-color: #c35a00;
  border-color: #c35a00;
}

.logoNavbar {
  width: 120px;
  height: 35px;
  background-image: url("../img/logoCreditia.png");
  background-repeat: no-repeat;
  background-size: contain;
  background-position: left center;
  display: block;
}

.logoNavbarBlanco {
  filter: drop-shadow(1px 0px 3px rgba(255, 255, 255, 0.6));
  width: 240px;
  height: 105px;
  background-image: url("../img/logoBlanco.png");
  background-repeat: no-repeat;
  background-size: contain;
  background-position: left center;
  display: block;
}

.logoCreditia {
  height: 200px;
}

.hero-overlay {
  background: rgba(0, 0, 0, 0.4); /* Oscurece la imagen de fondo */
  width: 100%;
  height: 100%;
  padding: 40px 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-section.hero-banner {
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  min-height: 500px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-section.hero-banner::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0, 0, 0, 0.4); /* sombra uniforme */
  z-index: 1;
}

.hero-section.hero-banner .container {
  z-index: 2;
}

.hero-section .container.hero-text {
  padding-top: 80px; /* Ajusta según la altura real del navbar */
}

.hero-section .hero-overlay {
  padding-top: 80px;
}

/* Solo en index.html: ocupa toda la altura */
.hero-section.hero-full {
  min-height: 100vh;
  padding-top: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-image: url("../img/fondoPrincipal2.png");
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  position: relative;
}

.hero-section.hero-simple {
  background-image: none !important;
  background-color: var(--primary); /* Gris azulado oscuro */
  min-height: auto !important;
  padding: 30px 0 !important;
  position: relative;
}

.hero-section.hero-simple .hero-overlay {
  background: transparent !important;
  position: relative;
  height: auto;
  padding: 4rem 0 0;
}

.hero-section.hero-full .hero-overlay {
  padding-top: 0 !important;
}

.img-autogestionarme {
  height: 100%;           /* Altura fija del contenedor */
  width: 100%;           /* Ancho al 100% para forzar el recorte */
  object-fit: cover;      /* Cubre el espacio sin deformarse */
  object-position: 50% 50%; /* Centrado exacto (horizontal y vertical) */
  position: relative;     /* Necesario para ajustes finos */
  left: 50%;             /* Desplazamiento inicial del 50% */
  transform: translateX(-50%); /* Centrado preciso */
  max-width: none;        /* Ignora límites de ancho */
  display: block;        /* Elimina espacios fantasma (inline-block) */
}

/* Color de texto */
.navbar .nav-link,
.navbar .navbar-brand,
.navbar .dropdown-item {
  color: #211261 !important;
}

/* Fondo blanco fijo */
.navbar {
  background-color: white !important;
  transition: all 0.4s ease;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05); /* opcional: sombra sutil siempre */
}

.floating-button {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 1000;
  display: flex;
  flex-direction: row;
  gap: 10px;
  align-items: center;
}

.whatsapp-button {
  background-color: #25D366;
  color: white;
  border-radius: 50%;
  width: 60px;
  height: 60px;
  display: flex;
  justify-content: center;
  align-items: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transition: all 0.3s ease;
}

.whatsapp-button:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
  color: white;
}

.negotiate-button {
  background-color: var(--secondary);
  color: white;
  border-radius: 30px;
  padding: 10px 20px;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transition: all 0.3s ease;
  text-decoration: none;
  white-space: nowrap;
}

.negotiate-button:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
  color: white;
}

.section {
  padding: 60px 0;
}

.section-title {
  margin-bottom: 40px;
  font-weight: 700;
  color: var(--primary);
}

.card {
  transition: all 0.3s ease;
  border: none;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.testimonial-card {
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  margin: 15px;
  background-color: white;
}

.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.footer-links a {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-links a:hover {
  color: white;
}

.social-icons a {
  color: white;
  font-size: 1.5rem;
  margin-right: 15px;
  transition: transform 0.3s ease;
}

.social-icons a:hover {
  transform: translateY(-3px);
}

/* Swiper styles */
.testimonials-slider {
  padding: 30px 0;
}

.swiper-button-next,
.swiper-button-prev {
  color: var(--primary);
}

.swiper-pagination-bullet-active {
  background-color: var(--primary);
}

.mensajeRad {
  /* white-space: pre-wrap; */
  word-wrap: break-word;
  overflow-wrap: break-word;
  padding: 12px;
  font-size: 0.95rem;
  background-color: #f8f9fa;
  border-radius: 10px;
}

.chat-container .logoRespuesta {
  width: 36px;
  height: 36px;
  object-fit: contain;
}


/* Para móvil (menor o igual a 992px) */
@media (max-width: 992px) {
  @media (max-width: 992px) {
    #mainNav,
    .navbar-collapse {
      background: white !important;
    }
  }
  
  .dropdown-menu {
    background-color: rgba(0, 0, 0, 0.2) !important;
  }
  .dropdown-item {
    color: var(--bs-nav-link-color);
  }
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .hero-section.hero-full {
    min-height: 100vh;
  }
  .hero-section.hero-banner {
    min-height: 400px;
  }
  .hero-overlay {
    padding: 61px 0 4rem;
  }

  .hero-section .display-4 {
    font-size: 2rem;
    line-height: 1.3;
  }

  .hero-section .lead {
    font-size: 1.1rem;
  }

  .section {
    padding: 40px 0;
  }

  .floating-button {
    bottom: 10px;
    right: 10px;
  }

  .negotiate-button {
    font-size: 14px;
    padding: 8px 16px;
  }

  .whatsapp-button {
    width: 50px;
    height: 50px;
  }

  .mensajeRad {
    font-size: 0.9rem;
  }

  .chat-container .logoRespuesta {
    width: 30px;
    height: 30px;
  }

  .chat-container .form-control {
    font-size: 0.9rem;
  }

  .chat-container .d-flex.align-self-end,
  .chat-container .d-flex.align-self-center {
    align-items: flex-start !important;
  }

  .chat-container .col-12.col-sm-9.d-flex {
    flex-direction: column;
    align-items: flex-start;
  }
  .logoCreditia {
    height: 125px;
  }
}

@media (max-width: 576px) {
  .logoCreditia {
    height: 90px;
  }
  .hero-section.hero-full {
    min-height: 100vh;
  }
  .hero-section.hero-banner {
    min-height: 400px;
  }
  .hero-overlay {
    padding: 61px 0 3rem;
  }

  .hero-section .display-4 {
    font-size: 1.75rem;
  }
}