/* ==========================================================================
   Estilos FRALU - Diseño original completo y limpio
   ========================================================================== */

:root {
  --fralu-green: #95AD2E;
  --fralu-dark: #3a3a3a;
  --fralu-light: #f5f6f4;
}

body {
  font-family: 'Roboto', sans-serif;
  color: #555;
}

/* Tipografía según WordPress */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Lato', sans-serif;
  font-weight: 700;
}
h1 { font-size: 3.5rem; line-height: 1.1; }
h2 { font-size: 3rem; line-height: 1.1; }
h3 { font-size: 2.5rem; line-height: 1.1; }
h4 { font-size: 2rem; line-height: 1.1; }
h5 { font-size: 1.5rem; line-height: 1.2; }
h6 { font-family: 'Heebo', sans-serif; font-size: 0.875rem; font-weight: 600; text-transform: uppercase; letter-spacing: 2px; }

/* --- Barra superior verde --- */
.container-topbar{
  padding: 0px 50px;
}

.fr-topbar { 
  background-color: var(--fralu-green); 
  font-size: 0.85rem; 
  padding: 0.5rem 0;
}
.fr-topbar a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 27px;
  height: 27px;
  background-color: #5a6e28;
  border-radius: 5px;
  transition: all 0.3s ease;
  text-decoration: none;
}
.fr-topbar a:hover {
  background-color: #4a5a20;
  transform: translateY(-1px);
}
.fr-topbar a i {
  font-size: 0.95rem;
  color: white;
}

/* --- Navegación --- */
.navbar {
  transition: all 0.3s ease;
  background-color: white !important;
  box-shadow: none !important;
 /* padding-top: 1.75rem !important;
  padding-bottom: 1.75rem !important;*/
}
/* Padding del navbar comentado por el usuario */
.navbar-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0rem 2rem;
}
@media (min-width: 992px) {
  .navbar-container {
    padding-left: 3rem;
    padding-right: 3rem;
  }
}
@media (min-width: 1200px) {
  .navbar-container {
    padding-left: 4rem;
    padding-right: 4rem;
  }
}
@media (min-width: 1400px) {
  .navbar-container {
    padding-left: 5rem;
    padding-right: 5rem;
  }
}
.navbar.scrolled {
  box-shadow: 0 2px 8px rgba(0,0,0,0.1) !important;
  padding-top: 0.75rem !important;
  padding-bottom: 0.75rem !important;
}
.navbar.scrolled .navbar-brand img {
  height: 60px;
}
@media (min-width: 992px) {
  .navbar.scrolled .navbar-brand img {
    height: 70px;
  }
}
.navbar-brand img { 
  height: 80px; 
  width: auto;
  transition: height 0.3s ease;
}
@media (min-width: 992px) {
  .navbar-brand img {
    height: 90px;
  }
}
.navbar-nav {
  gap: 0 !important;
  align-items: center;
}
.nav-link { 
  color: #728621 !important; 
  font-weight: 700; 
  text-transform: capitalize;
  font-family: 'Roboto', sans-serif;
  font-size: 1rem;
  letter-spacing: 0.5px;
  transition: color 0.3s ease;
  padding: 0.75rem 0 !important;
  padding-left: 0 !important;
  margin-left: 0 !important;
}
@media (min-width: 992px) {
  .nav-link {
    font-size: 1.05rem;
    letter-spacing: 0.8px;
  }
}
@media (min-width: 1200px) {
  .nav-link {
    font-size: 1.1rem;
  }
}
.navbar-nav .nav-item {
  margin-left: 0 !important;
  margin-right: 0 !important;
  padding-left: 40px !important;
}
.navbar-nav .nav-item:first-child {
  padding-left: 0 !important;
}
@media (min-width: 1200px) {
  .navbar-nav .nav-item {
    padding-left: 50px !important;
  }
}
@media (min-width: 992px) {
  .nav-link {
    padding: 1rem 0 !important;
  }
}
.nav-link:hover { 
  color: #728621 !important; 
  opacity: 0.8;
}
.nav-link.active { 
  color: var(--fralu-dark) !important; 
  font-weight: 700;
}

/* --- Banner Principal (Hero con Doctor) --- */
.fr-hero {
  position: relative;
  background-size: cover;
  background-position: center;
  min-height: 85vh;
  display: flex;
  align-items: center;
  padding: 60px 0;
}
@media (min-width: 992px) {
  .fr-hero {
    padding: 80px 0;
  }
}
.fr-hero::before {
  content: "";
  position: absolute;
  top: 0; left: 0; width: 50%; height: 100%;
  background: linear-gradient(90deg, rgba(255,255,255,0.98) 0%, rgba(255,255,255,0.9) 30%, rgba(255,255,255,0.7) 50%, rgba(255,255,255,0) 100%);
  z-index: 1;
}
.fr-hero-content { 
  position: relative; 
  z-index: 2; 
  padding-top: 2rem;
  padding-bottom: 2rem;
}
.fr-hero h1 { 
  font-weight: 700; 
  color: var(--fralu-dark); 
  font-size: 3.5rem; 
  line-height: 1.2; 
  margin-bottom: 1.25rem;
  font-family: 'Lato', sans-serif;
}
@media (min-width: 992px) {
  .fr-hero h1 {
    font-size: 4rem;
  }
}
.fr-hero .lead {
  color: #555;
  font-size: 1.125rem;
  line-height: 1.7;
  font-weight: 400;
  margin-bottom: 2.5rem;
  max-width: 90%;
}

/* --- Botones --- */
.btn-fralu {
  background-color: var(--fralu-green);
  color: white; 
  font-weight: 600; 
  border-radius: 3px; 
  padding: 12px 30px; 
  border: none;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
}
.btn-fralu:hover { 
  background-color: #7a973a; 
  color: white; 
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}
.btn-outline-fralu { 
  color: var(--fralu-dark); 
  font-weight: 600; 
  border: 2px solid var(--fralu-dark);
  background: transparent;
  border-radius: 3px;
  padding: 10px 28px;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
}
.btn-outline-fralu:hover { 
  color: var(--fralu-green); 
  border-color: var(--fralu-green);
  background: transparent;
  transform: translateY(-2px);
}

/* --- Estadísticas (Caja blanca superpuesta y animada) --- */
.fr-stats-box {
  background: white; border-top: 5px solid var(--fralu-green); box-shadow: 0 10px 30px rgba(0,0,0,0.1);
  border-radius: 5px; padding: 30px; margin-top: -60px; position: relative; z-index: 10;
  transform: translateY(-150px); opacity: 0; transition: transform 1.5s ease-out, opacity 1.5s ease-out;
}
.fr-stats-box.slide-down-show { transform: translateY(0); opacity: 1; }
.fr-stats-box h2 { font-size: 3rem; font-weight: 700; color: var(--fralu-dark); }
.fr-stats-box .text-plus { color: var(--fralu-green); font-size: 2rem; vertical-align: top; }

/* --- Tarjetas de Líneas (Efecto Animado Slide Up) --- */
.fr-line-card { border: none; border-radius: 0; overflow: hidden; height: 400px; position: relative; }
.fr-line-card img { width: 100%; height: 100%; object-fit: cover; }
.fr-line-card-front {
  position: absolute; top: 0; left: 0; width: 100%; height: 100%;
  background-color: rgba(144, 176, 70, 0.75); display: flex; align-items: center; justify-content: center;
  transition: opacity 0.4s ease; z-index: 1;
}
.fr-line-card-front h3 { color: white; font-weight: 700; text-align: center; font-size: 1.6rem; margin: 0; }
.fr-line-card-back {
  position: absolute; top: 0; left: 0; width: 100%; height: 100%;
  background-color: #90b046; display: flex; flex-direction: column; align-items: flex-start; text-align: left;
  justify-content: center; padding: 40px; transform: translateY(100%); transition: transform 0.4s ease-in-out; z-index: 2;
}
.fr-line-card-back h3 { color: white; font-weight: 700; font-size: 1.5rem; margin-bottom: 15px; }
.fr-line-card-back p { color: white; font-size: 1rem; margin-bottom: 25px; }
.fr-line-card-back .btn { border: 2px solid white; color: white; font-weight: 600; border-radius: 0; padding: 8px 20px; }
.fr-line-card-back .btn:hover { background-color: white; color: #90b046; }
.fr-line-card:hover .fr-line-card-back { transform: translateY(0); }
.fr-line-card:hover .fr-line-card-front { opacity: 0; }

/* --- Cajas de Fabricantes (Estilo WordPress) --- */
.fr-brands-section{
  /* Fondo tipo plantilla: franja verde claro arriba y blanco abajo */
  background: linear-gradient(to bottom, rgba(197,212,159,0.20) 0%, rgba(197,212,159,0.20) 65%, #ffffff 65%, #ffffff 100%);
}
.fr-container-wide{
  max-width: 1400px;
  margin: 0 auto;
  padding-left: 20px;
  padding-right: 20px;
}
@media (min-width: 992px){
  .fr-container-wide{
    padding-left: 30px;
    padding-right: 30px;
  }
}

.fr-brand-box {
  background: white; 
  padding: 20px; 
  border: none;
  border-bottom: 5px solid var(--fralu-green);
  box-shadow: 0px 5px 10px 0px rgba(0, 0, 0, 0.25); 
  display: flex; 
  align-items: center; 
  justify-content: center; 
  min-height: 220px;
  height: 100%;
  border-radius: 0;
  transition: box-shadow 0.3s ease;
  margin-bottom: 0;
}
.fr-brand-box:hover {
  box-shadow: 0px 10px 30px 0px rgba(0, 0, 0, 0.25);
}
.fr-brand-box img { 
  max-width: 85%; 
  max-height: 120px; 
  width: auto;
  height: auto;
  object-fit: contain;
  filter: grayscale(0);
}
@media (min-width: 992px) {
  .fr-brand-box {
    min-height: 260px;
    padding: 20px;
  }
  .fr-brand-box img {
    max-width: 85%;
    max-height: 140px;
  }
}

/* --- Formulario de Contacto --- */
.fr-form-wrapper { background: white; padding: 40px; box-shadow: 0 10px 30px rgba(0,0,0,0.08); }
.fr-form-wrapper input, .fr-form-wrapper textarea { background-color: #f1f4ea; border: 1px solid #e0e5d5; border-radius: 0; }
.form-label { color: var(--fralu-green); font-weight: 600; font-size: 0.9rem; }

/* --- Pie de Página --- */
.fr-footer { background-color: var(--fralu-dark); color: white; }
.fr-footer .fr-footer-menu li { margin-bottom: 10px; }
.fr-footer .fr-footer-menu li::before { content: "•"; color: var(--fralu-green); font-weight: bold; display: inline-block; width: 1em; }
.fr-footer a { color: white; text-decoration: none; }

/* ==========================================================================
   NUEVO: ANIMACIONES AL HACER SCROLL
   ========================================================================== */
.reveal-on-scroll {
  opacity: 0;
  transform: translateY(80px); /* El elemento empieza escondido más abajo */
  transition: all 0.8s ease-out; /* Duración y suavidad de la animación */
}

/* Esta clase se añade con JavaScript cuando el usuario hace scroll hasta el elemento */
.reveal-on-scroll.is-visible {
  opacity: 1;
  transform: translateY(0); /* Sube a su posición original */
}

/* Retrasos en cascada para que los fabricantes aparezcan uno tras otro */
.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }
.delay-3 { transition-delay: 0.3s; }
.delay-4 { transition-delay: 0.4s; }
.delay-5 { transition-delay: 0.5s; }

/* ==========================================================================
   NUEVO: DROPDOWN MENU AL HACER HOVER
   ========================================================================== */
@media all and (min-width: 992px) {
  .fr-dropdown-hover:hover .dropdown-menu {
    display: block;
    margin-top: 0;
  }
}
.dropdown-item:hover {
  background-color: #f1f4ea;
  color: var(--fralu-green);
}

/* ==========================================================================
   ESTILO PARA ENLACE DE NAVEGACIÓN ACTIVO (Highlight current page)
   ========================================================================== */
/* Targets the <a> tag itself when active */
.navbar-nav .nav-link.active,
.navbar-nav .nav-item.active .nav-link {
    color: var(--fralu-dark) !important; /* Color negro para el link activo */
    font-weight: 700; /* Make it bold for emphasis */
}
.navbar-nav .dropdown-item.active {
    color: var(--fralu-green) !important; /* Verde para items del dropdown activos */
    font-weight: 700;
}