/* ==============================================================================
   DR. JUAN MANUEL CLAROS - NEUMÓLOGO (SANTA CRUZ, BOLIVIA)
   Hoja de Estilos Principal (Sistema de Diseño Clínico Modernizado)
   Basado en Bootstrap 5.3, Outfit, Inter, BoxIcons y Glassmorphism
   ============================================================================== */

:root {
  /* Paleta Cromática Extraída y Elevada */
  --primary-color: #175C63;        /* Deep Teal / Azul Petróleo Neumología */
  --primary-dark: #0E3E43;
  --primary-light: #21838D;
  --primary-gradient: linear-gradient(135deg, #175C63 0%, #0E3E43 100%);
  --hero-gradient: linear-gradient(135deg, rgba(23, 92, 99, 0.95) 0%, rgba(14, 62, 67, 0.98) 100%);

  --accent-color: #01CAB8;         /* Turquesa Neumológico Vibrante */
  --accent-hover: #00B3A2;
  --accent-light: #E0F9F6;
  --accent-gradient: linear-gradient(135deg, #01CAB8 0%, #00B3A2 100%);

  --whatsapp-color: #25D366;       /* Conversión WhatsApp Oficial */
  --whatsapp-hover: #1EBE5D;
  --whatsapp-light: #E8F9EE;

  /* Neutros y Superficies */
  --bg-body: #FFFFFF;
  --bg-subtle: #F6FAFA;           /* Ice Aqua Tint */
  --dark-text: #1E293B;           /* Slate 800 */
  --muted-text: #64748B;          /* Slate 500 */
  --light-border: #E2E8F0;
  --glass-border: rgba(23, 92, 99, 0.1);

  /* Sombras y Elevaciones */
  --shadow-sm: 0 4px 12px rgba(23, 92, 99, 0.05);
  --shadow-md: 0 10px 25px rgba(23, 92, 99, 0.08);
  --shadow-lg: 0 20px 40px rgba(23, 92, 99, 0.12);
  --shadow-card-hover: 0 15px 35px rgba(1, 202, 184, 0.15);

  /* Tipografías */
  /* Sobrescritura de colores utilitarios para eliminar el azul default de Bootstrap */
  --bs-primary: #175C63;
  --bs-primary-rgb: 23, 92, 99;
  --bs-info: #01CAB8;
  --bs-info-rgb: 1, 202, 184;

  --accent-text: #0d8a7d;         /* Turquesa enriquecido para textos con alto contraste WCAG */
  --font-body: 'Inter', sans-serif;

  /* Bordes */
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-pill: 50px;
}

/* ==============================================================================
   1. RESET Y ESTILOS BASE
   ============================================================================== */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  color: var(--dark-text);
  background-color: var(--bg-body);
  line-height: 1.65;
  overflow-x: hidden;
  padding-top: 155px; /* Espacio para barra de navegación fija y logo ampliado */
}

h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--primary-color);
  letter-spacing: -0.02em;
  line-height: 1.25;
}

p {
  margin-bottom: 1.1rem;
}

a {
  color: var(--primary-color);
  text-decoration: none;
  transition: all 0.25s ease;
}

a:hover {
  color: var(--accent-hover);
}

/* ==============================================================================
   SOBRESCRITURA DE UTILIDADES BOOTSTRAP (SIN AZUL ELÉCTRICO)
   ============================================================================== */
.text-primary {
  color: var(--primary-color) !important;
}

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

.border-primary {
  border-color: var(--primary-color) !important;
}

.text-accent, .text-teal {
  color: var(--accent-text) !important;
}

.bg-accent, .bg-teal {
  background-color: var(--accent-color) !important;
  color: #0E3E43 !important;
}

.badge-param {
  background-color: var(--accent-light);
  color: var(--primary-dark);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.8rem;
  padding: 5px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(1, 202, 184, 0.3);
}

.param-card {
  background: #FFFFFF;
  border: 1px solid var(--light-border);
  border-radius: var(--radius-md);
  padding: 20px;
  transition: all 0.25s ease;
}

.param-card:hover {
  border-color: var(--accent-color);
  box-shadow: 0 8px 20px rgba(1, 202, 184, 0.12);
  transform: translateY(-3px);
}

/* ==============================================================================
   2. TOPBAR DE CONTACTO RÁPIDO
   ============================================================================== */
.top-bar {
  background-color: var(--primary-dark);
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.85rem;
  padding: 6px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1031;
}

.top-bar a {
  color: rgba(255, 255, 255, 0.88);
}

.top-bar a:hover {
  color: var(--accent-color);
}

.top-bar i {
  color: var(--accent-color);
  vertical-align: middle;
  margin-right: 4px;
}

/* ==============================================================================
   3. BARRA DE NAVEGACIÓN PRINCIPAL (GLASSMORPHISM)
   ============================================================================== */
.main-navbar {
  position: fixed;
  top: 36px;
  left: 0;
  right: 0;
  z-index: 1030;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(23, 92, 99, 0.08);
  transition: all 0.3s ease;
  padding: 12px 0;
}

.main-navbar.scrolled {
  top: 0;
  padding: 8px 0;
  box-shadow: var(--shadow-md);
  background: rgba(255, 255, 255, 0.98);
}

.navbar-brand img {
  height: 94px; /* Ampliado 80% desde 52px */
  width: auto;
  transition: all 0.3s ease;
}

.main-navbar.scrolled .navbar-brand img {
  height: 72px;
}

.navbar-brand:hover img {
  transform: scale(1.02);
}

.nav-link {
  font-family: var(--font-heading);
  font-weight: 500;
  font-size: 1rem;
  color: var(--primary-color) !important;
  padding: 8px 16px !important;
  border-radius: var(--radius-sm);
  transition: all 0.25s ease;
}

.nav-link:hover, .nav-link.active {
  color: var(--accent-color) !important;
  background-color: var(--accent-light);
}

/* Menú Desplegable con Glassmorphism */
.dropdown-menu {
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-lg);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(16px);
  padding: 12px;
  margin-top: 10px;
  animation: fadeInDown 0.25s ease;
}

.dropdown-item {
  font-size: 0.92rem;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  color: var(--dark-text);
  font-weight: 500;
  transition: all 0.2s ease;
}

.dropdown-item:hover {
  background-color: var(--accent-light);
  color: var(--primary-color);
  transform: translateX(4px);
}

.dropdown-item i {
  color: var(--accent-color);
  margin-right: 6px;
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ==============================================================================
   4. BOTONES Y LLAMADAS A LA ACCIÓN (CTA)
   ============================================================================== */
.btn {
  font-family: var(--font-heading);
  font-weight: 600;
  padding: 10px 24px;
  border-radius: var(--radius-pill);
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: none;
}

.btn-primary {
  background: var(--primary-gradient);
  color: #FFFFFF !important;
  box-shadow: 0 4px 15px rgba(23, 92, 99, 0.25);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #21838D 0%, #175C63 100%);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(23, 92, 99, 0.35);
}

.btn-accent {
  background: var(--accent-gradient);
  color: #0E3E43 !important;
  font-weight: 700;
  box-shadow: 0 4px 15px rgba(1, 202, 184, 0.3);
}

.btn-accent:hover {
  background: linear-gradient(135deg, #00B3A2 0%, #01CAB8 100%);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(1, 202, 184, 0.45);
}

.btn-whatsapp {
  background-color: var(--whatsapp-color);
  color: #FFFFFF !important;
  box-shadow: 0 4px 15px rgba(37, 211, 102, 0.35);
}

.btn-whatsapp:hover {
  background-color: var(--whatsapp-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(37, 211, 102, 0.45);
}

.btn-outline-primary {
  border: 2px solid var(--primary-color);
  color: var(--primary-color) !important;
  background: transparent;
}

.btn-outline-primary:hover {
  background: var(--primary-color);
  color: #FFFFFF !important;
  transform: translateY(-2px);
}

/* ==============================================================================
   5. COMPONENTES CLÍNICOS Y HERO BANNER
   ============================================================================== */
.service-hero {
  background: var(--hero-gradient);
  color: #FFFFFF;
  padding: 60px 0 50px 0;
  position: relative;
  overflow: hidden;
}

.service-hero::after {
  content: "";
  position: absolute;
  top: -50%;
  right: -10%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(1, 202, 184, 0.15) 0%, rgba(1, 202, 184, 0) 70%);
  pointer-events: none;
}

.service-hero h1 {
  color: #FFFFFF;
  font-size: 2.5rem;
}

.service-hero .lead {
  color: rgba(255, 255, 255, 0.9);
  font-size: 1.15rem;
  max-width: 720px;
}

/* Breadcrumbs Clínicos */
.breadcrumb {
  margin-bottom: 12px;
}

.breadcrumb-item, .breadcrumb-item a {
  color: rgba(255, 255, 255, 0.75);
  font-size: 0.9rem;
}

.breadcrumb-item.active {
  color: var(--accent-color);
}

.breadcrumb-item + .breadcrumb-item::before {
  color: rgba(255, 255, 255, 0.5);
}

/* Badges Médicos */
.badge-medical {
  background-color: var(--accent-light);
  color: var(--primary-color);
  font-weight: 700;
  font-size: 0.85rem;
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid rgba(1, 202, 184, 0.25);
}

.badge-medical-white {
  background-color: rgba(255, 255, 255, 0.15);
  color: #FFFFFF;
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  font-size: 0.85rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

/* ==============================================================================
   6. TARJETAS GLASSMORPHISM Y SIDEBAR DE AGENDAMIENTO
   ============================================================================== */
.glass-card {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  padding: 30px;
  box-shadow: var(--shadow-sm);
  transition: all 0.3s ease;
}

.glass-card:hover {
  box-shadow: var(--shadow-md);
  border-color: rgba(1, 202, 184, 0.3);
}

.sidebar-sticky {
  position: -webkit-sticky;
  position: sticky;
  top: 100px;
}

.booking-card {
  background: #FFFFFF;
  border: 2px solid var(--accent-light);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-md);
  position: relative;
  overflow: hidden;
}

.booking-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 5px;
  background: var(--accent-gradient);
}

.doctor-badge {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--light-border);
  margin-bottom: 20px;
}

.doctor-badge .avatar-icon {
  width: 54px;
  height: 54px;
  background: var(--accent-light);
  color: var(--primary-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  flex-shrink: 0;
}

.doctor-badge h5 {
  margin: 0;
  font-size: 1.05rem;
}

.doctor-badge span {
  font-size: 0.85rem;
  color: var(--muted-text);
}

/* Lista de Beneficios con Checkmarks */
.clinical-checklist {
  list-style: none;
  padding: 0;
  margin: 0 0 24px 0;
}

.clinical-checklist li {
  position: relative;
  padding-left: 32px;
  margin-bottom: 12px;
  font-size: 0.95rem;
}

.clinical-checklist li i {
  position: absolute;
  left: 0;
  top: 3px;
  color: var(--accent-color);
  font-size: 1.25rem;
}

/* ==============================================================================
   7. SECCIÓN DE INDICACIONES Y FAQ ACCORDION
   ============================================================================== */
.info-box {
  background-color: var(--bg-subtle);
  border-left: 4px solid var(--accent-color);
  border-radius: var(--radius-sm);
  padding: 20px 24px;
  margin: 24px 0;
}

.accordion-item {
  border: 1px solid var(--light-border);
  border-radius: var(--radius-md) !important;
  margin-bottom: 14px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.accordion-button {
  font-family: var(--font-heading);
  font-weight: 600;
  color: var(--primary-color);
  background-color: #FFFFFF;
  padding: 16px 20px;
  box-shadow: none !important;
}

.accordion-button:not(.collapsed) {
  background-color: var(--accent-light);
  color: var(--primary-dark);
}

.accordion-body {
  padding: 20px;
  color: var(--dark-text);
  background: #FFFFFF;
  line-height: 1.7;
}

/* ==============================================================================
   8. BOTÓN FLOTANTE DE WHATSAPP
   ============================================================================== */
.whatsapp-floating {
  position: fixed;
  bottom: 25px;
  right: 25px;
  z-index: 1040;
  display: flex;
  align-items: center;
  background-color: var(--whatsapp-color);
  color: #FFFFFF !important;
  padding: 12px 20px 12px 16px;
  border-radius: var(--radius-pill);
  box-shadow: 0 8px 25px rgba(37, 211, 102, 0.4);
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.95rem;
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.whatsapp-floating i {
  font-size: 1.7rem;
  margin-right: 8px;
}

.whatsapp-floating:hover {
  background-color: var(--whatsapp-hover);
  transform: translateY(-4px) scale(1.03);
  box-shadow: 0 12px 30px rgba(37, 211, 102, 0.55);
}

/* ==============================================================================
   9. PIE DE PÁGINA (FOOTER CLÍNICO)
   ============================================================================== */
.main-footer {
  background-color: var(--primary-dark);
  color: rgba(255, 255, 255, 0.8);
  padding: 70px 0 25px 0;
  border-top: 4px solid var(--accent-color);
  margin-top: 60px;
}

.main-footer h4, .main-footer h5 {
  color: #FFFFFF;
  margin-bottom: 20px;
  font-size: 1.15rem;
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 10px;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.75);
  font-size: 0.92rem;
}

.footer-links a:hover {
  color: var(--accent-color);
  padding-left: 5px;
}

.footer-contact li {
  margin-bottom: 12px;
  font-size: 0.92rem;
  display: flex;
  gap: 10px;
}

.footer-contact i {
  color: var(--accent-color);
  font-size: 1.2rem;
  margin-top: 3px;
}

.footer-bottom {
  margin-top: 45px;
  padding-top: 25px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.6);
}

/* ==============================================================================
   10. COMPONENTES DE LA LANDING PAGE PRINCIPAL (INDEX)
   ============================================================================== */
.index-hero {
  position: relative;
  background: url('../img/pulmones.jpg') center right / cover no-repeat;
  color: #FFFFFF;
  padding: 130px 0 115px 0;
  min-height: 85vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.index-hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, rgba(8, 32, 36, 0.94) 0%, rgba(14, 62, 67, 0.88) 45%, rgba(14, 62, 67, 0.60) 100%);
  z-index: 1;
}

.index-hero::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at 75% 50%, rgba(1, 202, 184, 0.20) 0%, transparent 60%);
  z-index: 1;
  pointer-events: none;
}

.index-hero .container {
  position: relative;
  z-index: 2;
}

.hero-main-title {
  font-family: var(--font-heading);
  font-size: 3.8rem;
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.03em;
  text-shadow: 0 4px 25px rgba(0, 0, 0, 0.5);
}

.hero-main-lead {
  font-size: 1.25rem;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.92);
  max-width: 760px;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.4);
}

.hero-trust-bar {
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  padding-top: 25px;
  margin-top: 40px;
}

/* Tarjetas de Síntomas */
.symptom-card {
  background: #FFFFFF;
  border: 1px solid var(--light-border);
  border-radius: var(--radius-md);
  padding: 24px;
  transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
  display: block;
  text-decoration: none;
  height: 100%;
}

.symptom-card:hover {
  transform: translateY(-5px);
  border-color: var(--accent-color);
  box-shadow: var(--shadow-card-hover);
}

.symptom-icon {
  width: 54px;
  height: 54px;
  border-radius: var(--radius-md);
  background: var(--accent-light);
  color: var(--accent-text);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  margin-bottom: 16px;
  transition: all 0.3s ease;
}

.symptom-card:hover .symptom-icon {
  background: var(--accent-color);
  color: #0E3E43;
}

.symptom-icon img {
  width: 36px;
  height: 36px;
  object-fit: contain;
  transition: transform 0.3s ease;
}

.symptom-card:hover .symptom-icon img {
  transform: scale(1.12);
}

.doctor-photo-circle {
  width: 140px;
  height: 140px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--accent-color);
  box-shadow: 0 12px 28px rgba(23, 92, 99, 0.2);
  transition: transform 0.3s ease;
}

.doctor-photo-circle:hover {
  transform: scale(1.04);
}

.doctor-badge .avatar-img {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--accent-color);
  flex-shrink: 0;
}

/* Tarjetas de Especialidad */
.specialty-card {
  background: #FFFFFF;
  border: 1px solid var(--light-border);
  border-radius: var(--radius-lg);
  padding: 30px;
  transition: all 0.3s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.specialty-card:hover {
  border-color: rgba(1, 202, 184, 0.5);
  box-shadow: 0 16px 36px rgba(23, 92, 99, 0.08);
  transform: translateY(-4px);
}

/* Tarjetas de Testimonios */
.testimonial-card {
  background: #FFFFFF;
  border: 1px solid var(--light-border);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-sm);
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.stars-rating {
  color: #FFB800;
  font-size: 1.1rem;
  margin-bottom: 14px;
}

/* ==============================================================================
   11. RESPONSIVE MEDIA QUERIES
   ============================================================================== */
@media (max-width: 991.98px) {
  body {
    padding-top: 100px;
  }
  .navbar-brand img {
    height: 70px;
  }
  .top-bar {
    display: none;
  }
  .main-navbar {
    top: 0;
  }
  .service-hero h1 {
    font-size: 2rem;
  }
  .sidebar-sticky {
    position: static;
    margin-top: 30px;
  }
  .whatsapp-floating span {
    display: none;
  }
  .whatsapp-floating {
    width: 56px;
    height: 56px;
    padding: 0;
    justify-content: center;
    border-radius: 50%;
  }
  .whatsapp-floating i {
    margin: 0;
    font-size: 2rem;
  }
}

