:root {
  --primary-color: #257f42;
  --gradient-color: #0a1f44;
  --secondary-color: #a0d3b1;
  --light-bg: #fdfefd;
  --nav-height-desktop: 70px;
  --nav-height-mobile: 80px;
  --logo-green-dark: #287e48;
  --logo-green-light: #85b997;
}

/* Header fijo por encima */
#mainNav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 9999;
  background: transparent;
  transition: background .3s;
}
#mainNav.scrolled {
  background: #fff;
}

body {
   font-family: 'Poppins', sans-serif;
 background: linear-gradient(
    135deg,
    var(--logo-green-dark) 10%,
    var(--logo-green-light) 90%
  );
  background-attachment: fixed;
  margin: 0;
 
  
}
h1, h2, h3 {
  font-family: 'Poppins', sans-serif;
  font-weight: 600; /* o 700 */
}
h2 {
  color: var(--logo-green-dark);   /* tu verde #287e48 */
}
.hero-gradient h2 {
  color: #fff;
  text-shadow: 1px 1px 3px rgba(0,0,0,0.3);
}
  .hero-section {
  margin-top: 60px; /* igual a la altura de #mainNav en desktop */
}

/* Efecto slide-in para el párrafo de “Sobre mí” */
#about p {
  opacity: 0;
  transform: translateX(-50px);
  transition: opacity 2.5s ease-out,
              transform 2.5s ease-out;
}

#about.reveal p {
  opacity: 1;
  transform: translateX(0);
}


/* Texto claro sobre el degradado de #about */
#about { color: #ffffff; }

/* Título principal */
#about h2 {
  color: #ffffff;
  font-weight: 700;
  font-size: 2rem;       /* ~32px */
  line-height: 1.2;
  margin-bottom: 1.25rem;
  text-shadow: 1px 1px 3px rgba(0,0,0,0.35);
}

/* Párrafos y listas */
#about p,
#about li {
  color: #ffffff;
  font-size: 1.0625rem;  /* 17px */
  line-height: 1.7;
  letter-spacing: 0.2px;
  margin-bottom: 1rem;
}

/* Neutraliza el salto de tamaño de .lead dentro de #about */
#about .lead {
  font-size: 1.0625rem;  /* igual que el resto */
  font-weight: 400;
}

/* Subtítulos dentro de las tarjetas */
#about h5 {
  font-size: 1.125rem;   /* 18px */
  font-weight: 600;
  margin-bottom: 0.75rem;
}

/* Tarjetas blancas: texto oscuro y legible */
#about .bg-white,
#about .bg-white * {
  color: #212529;
}

/* Estilo de cita para la filosofía */
#about blockquote {
  margin: 0;
  padding-left: 0.75rem;
  border-left: 4px solid #257f42; /* tu verde */
  color: #212529;
}



/* ===== Animación drop-in para servicios ===== */
@keyframes dropIn {
  0% {
    opacity: 0;
    transform: translateY(-100px) scale(0.9);
  }
  80% {
    opacity: 1;
    transform: translateY(10px) scale(1.02);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Estado inicial: oculto y desplazado arriba */
#services .card {
  opacity: 0;
}

/* Al revelar: dispara la animación con delay */
#services.reveal .card {
  animation: dropIn 0.8s ease-out forwards;
  animation-delay: var(--delay);
}

/* Card de perfil */
.profile-card {
  transition: transform .4s ease, box-shadow .4s ease;
}
.profile-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 25px 40px rgba(0, 0, 0, 0.15);
}

/* Botón degradado */
.btn-gradient {
  background-image: linear-gradient(135deg, var(--primary-color), var(--gradient-color));
  border: none;
  color: #fff;
  border-radius: 2rem;
  transition: background 0.4s ease, transform 0.3s ease;
}
.btn-gradient:hover {
  background-image: linear-gradient(135deg, var(--gradient-color), var(--primary-color));
  transform: scale(1.05);
}

/* Hero */
.photo-hero {
  height: 80vh;
  overflow: hidden;
  position: relative;
}

/* Fondo con imagen + degradado verde → azul oscuro */
.photo-hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    linear-gradient(
      135deg,
      rgba(37,127,66,0.8) 0%,
      rgba(10,31,68,0.8) 100%
    ),
    url('../img/doctor-bg.webp') center center / cover no-repeat;
  z-index: 0;
}

.photo-hero .overlay {
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 0 1rem;
}

/* Contenedor del video (si se usa) */
.video-container {
  position: absolute;
  top: 30%;
  left: 50%;
  transform: translate(-50%, -30%);
  width: 80%;
  z-index: 0;
  margin: 0 auto;
}

.small-video {
  width: 100%;
  height: auto;
  object-fit: contain;
}

/* Botones primarios con degradado */
.btn-primary {
  background: linear-gradient(
    135deg,
    var(--primary-color),
    var(--gradient-color)
  );
  border: none;
  color: #fff;
}
.btn-primary:hover {
  background-color: var(--secondary-color);
  border-color: var(--secondary-color);
}

/* Titulares y textos con color primario */
.card-title,
.text-primary {
  color: var(--primary-color) !important;
}

/* ===== Gallery Section CSS ===== */
#gallery {
  padding: 3rem 0;
  background-color: var(--light-bg);
}

#gallery .container h2 {
  margin-bottom: 1.5rem;
}

#gallery .row {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.gallery-item {
  position: relative;
  overflow: hidden;
  cursor: pointer;
  flex: 0 0 48%;  /* dos columnas en móvil por defecto */
  max-width: 48%;
  aspect-ratio: 1 / 1;
  border-radius: 0.5rem;
  background-color: #fff;
  animation: float 6s ease-in-out infinite;
  transition: transform .5s ease, box-shadow .5s ease;
}

@media (min-width: 768px) {
  .gallery-item {
    flex: 0 0 23%;
    max-width: 23%;
  }
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .5s ease;
}

.gallery-item .overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.5);
  opacity: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1rem;
  transition: opacity .3s ease;
}

.gallery-item:hover img {
  transform: scale(1.1);
}
.gallery-item:hover .overlay {
  opacity: 1;
}
.gallery-item:hover {
  animation-play-state: paused;
  transform: translateY(-5px) scale(1.05);
  box-shadow: 0 15px 25px rgba(0,0,0,0.2);
}

@keyframes float {
  0%,100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

/* Quitar sombra del foco en acordeón */
.accordion-button:focus {
  box-shadow: none;
}

/* Animación de entrada Hero */
@keyframes fadeInUp {
  0% { opacity: 0; transform: translateY(20px); }
  100% { opacity: 1; transform: translateY(0); }
}
.photo-hero .overlay h1,
.photo-hero .overlay p,
.photo-hero .overlay .btn {
  opacity: 0;
  animation: fadeInUp 1s ease-out forwards;
}
.photo-hero .overlay h1 { animation-delay: 0.5s; }
.photo-hero .overlay p { animation-delay: 1s; }
.photo-hero .overlay .btn { animation-delay: 1.5s; }

/* Footer degradado azul */
footer {
  background: linear-gradient(
    135deg,
    #0a1f44 0%,
    #194262 100%
  );
  color: #fff;
  padding: 2rem 0;
}
footer a,footer .bi {
  color: #fff;
  transition: color .3s ease;
}
footer a:hover,footer .bi:hover {
  color: var(--secondary-color);
}
/* ===== Botón flotante WhatsApp ===== */
.whatsapp-float {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background-color: #25D366;
  color: #fff;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
  z-index: 10000;
  transition: transform .3s ease;
}

.whatsapp-float:hover {
  transform: scale(1.1);
  text-decoration: none;
  color: #fff;
}

.offcanvas-header {
  padding-bottom: 0.25rem;    /* antes era 1rem por defecto */
}
.offcanvas-title {
  margin-bottom: 0;           /* elimina el margen inferior */
}

/* Ajusta el padding de la lista */
.offcanvas-body {
  padding-top: 0.5rem;        /* antes era 1rem */
}

/* Opcional: más compacto entre items */
.offcanvas-body .nav-link {
  padding-top: 0.25rem !important;
  padding-bottom: 0.25rem !important;
}
/* ===== Responsive: Tablets y móviles ===== */
@media (max-width: 767.98px) {
	.offcanvas.offcanvas-end {
    top: var(--nav-height-mobile);               /* empuja hacia abajo */
    height: calc(100% - var(--nav-height-mobile)); /* ajusta la altura */
  }
  body { padding-top: var(--nav-height-mobile); }
  #mainNav { padding: .5rem 1rem; }
  .photo-hero { height: 60vh; }
  .photo-hero .overlay h1 { font-size: 2rem; }
  .photo-hero .overlay p { font-size: 1rem; }
  .video-container { top: 35%; width: 90%; }
  .btn-primary { padding: .5rem 1rem; font-size: .9rem; }
  /* Galería en móvil: un item por fila */
  .gallery-item { flex: 0 0 100%; max-width: 100%; }
  footer { padding: 1.5rem 0; font-size: .9rem; }
   #about h2 { font-size: 1.75rem; }      /* 28px */
  #about p, #about li, #about .lead { font-size: 1rem; } /* 16px */
}

@media (max-width: 479.98px) {
	.offcanvas.offcanvas-end {
    top: 100px;                         /* igual a la altura real de tu navbar móvil */
    height: calc(100% - 100px);         /* ocupa el resto de la pantalla */
  }
  body {
    padding-top: 60px;                 /* empuja el contenido bajo el navbar */
  }
  .photo-hero { height: 50vh; }
  .photo-hero .overlay h1 { font-size: 1.5rem; }
  .photo-hero .overlay p { font-size: .9rem; }
  .video-container { top: 40%; width: 100%; }
  .btn-primary { width: 100%; padding: .6rem 0; }
  /* Galería en muy pequeño: mantiene 1 por fila */
  .gallery-item { flex: 0 0 100%; max-width: 100%; }
  footer { padding: 1rem 0; font-size: .8rem; }
    #about h2 { font-size: 1.5rem; }       /* 24px */
  #about p, #about li, #about .lead { font-size: 0.95rem; } /* ~15px */
}
/* Ajustes para pantallas super pequeñas (<400px) */
 
