/* ============================================================
   UNIDAD GASTROENTEROLÓGICA DUITAMA
   style.css
   Organización:
   1. Variables y reset
   2. Navegación
   3. Secciones (show/hide)
   4. Presentación → Hero
   5. Presentación → Location bar
   6. Presentación → Contenido central
   7. Presentación → Misión
   8. Presentación → Tarjeta doctor
   9. Presentación → Diferenciales
  10. Servicios → Hero
  11. Servicios → Cuadrícula
  12. Servicios → Enfermedades
  13. Agendamiento → Hero
  14. Agendamiento → Formulario
  15. Agendamiento → Info de contacto
  16. Footer
  17. Responsive (móvil)
============================================================ */


/* ============================================================
   1. VARIABLES Y RESET
============================================================ */

:root {
  /* Paleta principal */
  --color-navy:      #0F2A4A;   /* azul marino  — fondos hero y nav   */
  --color-navy-dark: #0a1f36;   /* azul más oscuro — location bar      */
  --color-green:     #1A7A5E;   /* verde salud  — acentos y botones    */
  --color-green-lt:  #E1F5EE;   /* verde claro  — fondos de íconos     */
  --color-gold:      #C9A84C;   /* dorado       — highlights           */
  --color-gold-lt:   #FAF3E0;   /* dorado claro — fondo ícono balón    */
  --color-blue-lt:   #E6EDF4;   /* azul claro   — fondo íconos navy    */
  --color-wa:        #25D366;   /* verde WhatsApp                      */

  /* Grises y neutros */
  --color-bg:        #F5F7FA;   /* fondo general de la página          */
  --color-white:     #ffffff;
  --color-text:      #1a1a1a;   /* texto principal                     */
  --color-muted:     #555555;   /* texto secundario / párrafos         */
  --color-subtle:    #999999;   /* texto muy tenue / disclaimer        */
  --color-border:    #e8e8e8;   /* bordes de tarjetas                  */
  --color-border-md: #d0d5dd;   /* bordes de inputs                    */
  --color-input-bg:  #f2f4f7;   /* fondo pills / schedule-info         */

  /* Tipografías */
  --font-serif: 'Playfair Display', serif;
  --font-sans:  'Inter', sans-serif;

  /* Radios */
  --radius-sm:  6px;
  --radius-md:  10px;
  --radius-lg:  14px;
  --radius-xl:  20px;

  /* Espaciados frecuentes */
  --gap-xs: 6px;
  --gap-sm: 10px;
  --gap-md: 1.25rem;
  --gap-lg: 2rem;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-sans);
  background: var(--color-bg);
  color: var(--color-text);
  min-height: 100vh;
}


/* ============================================================
   2. NAVEGACIÓN
============================================================ */

/* ============================================================
   2. NAVEGACIÓN
============================================================ */

.nav {
  background: var(--color-navy);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--gap-lg);
  height: 64px;
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-logo {
  font-family: var(--font-serif);
  color: var(--color-white);
  font-size: 17px;
  font-weight: 600;
  line-height: 1.2;
  flex-shrink: 0;
}

.nav-logo span  { color: var(--color-gold); }

.nav-logo small {
  display: block;
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.45);
}

.nav-tabs {
  display: flex;
  gap: 4px;
}

.nav-tab {
  background: none;
  border: none;
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.65);
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
  white-space: nowrap;
}

.nav-tab:hover  { background: rgba(255,255,255,0.08); color: var(--color-white); }
.nav-tab.active { background: rgba(201,168,76,0.18);  color: var(--color-gold);  }


/* ============================================================
   3. SECCIONES (show / hide)
============================================================ */

.section {
  display: none;
}

.section.active {
  display: block;
}


/* ============================================================
   4. PRESENTACIÓN → HERO
============================================================ */

.hero {
  background:
    linear-gradient(to bottom, rgba(15, 42, 74, 0.97) 0%, transparent 30%),
    linear-gradient(to top,    rgba(15, 42, 74, 0.97) 0%, transparent 30%),
    linear-gradient(to right,  rgba(15, 42, 74, 0.85) 0%, transparent 25%),
    linear-gradient(to left,   rgba(15, 42, 74, 0.85) 0%, transparent 25%),
    linear-gradient(rgba(15, 42, 74, 0.45) 0%, rgba(15, 42, 74, 0.45) 100%),
    url('../assets/img/foto_doctor.jpg') center 20% / cover no-repeat;
  background-color: var(--color-navy);
  padding: 4rem var(--gap-lg) 3.5rem;
  text-align: center;
  position: relative;
  overflow: hidden;
  min-height: 480px;              /* ← altura mínima */
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

/* SVG de fondo anatómico */
.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.06;
  pointer-events: none;
}

/* Etiqueta superior dorada */
.hero-badge {
  display: inline-block;
  background: rgba(201, 168, 76, 0.18);
  color: var(--color-gold);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 5px 14px;
  border-radius: var(--radius-xl);
  margin-bottom: var(--gap-md);
  border: 1px solid rgba(201, 168, 76, 0.3);
  position: relative; /* queda sobre el SVG */
}

/* Título principal */
.hero h1 {
  font-family: var(--font-serif);
  color: var(--color-white);
  font-size: 38px;
  font-weight: 600;
  line-height: 1.2;
  margin-bottom: 0.75rem;
  position: relative;
}

.hero h1 em {
  color: var(--color-gold);
  font-style: normal;
}

/* Subtítulo */
.hero-sub {
  color: rgba(255, 255, 255, 0.65);
  font-size: 15px;
  max-width: 480px;
  margin: 0 auto var(--gap-lg);
  line-height: 1.7;
  position: relative;
}

/* Botón CTA */
.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--color-green);
  color: var(--color-white);
  border: none;
  border-radius: 8px;
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 500;
  padding: 12px 24px;
  cursor: pointer;
  transition: background 0.2s;
  position: relative;
}

.hero-cta:hover {
  background: #15654e;
}


/* ============================================================
   5. PRESENTACIÓN → LOCATION BAR
============================================================ */

.location-bar {
  background: var(--color-navy-dark);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--gap-lg);
  padding: 0.9rem var(--gap-lg);
  flex-wrap: wrap;
}

.loc-item {
  display: flex;
  align-items: center;
  gap: var(--gap-xs);
  color: rgba(255, 255, 255, 0.6);
  font-size: 12px;
}

.loc-item i {
  color: var(--color-gold);
  font-size: 15px;
}


/* ============================================================
   6. PRESENTACIÓN → CONTENIDO CENTRAL
============================================================ */

.content-section {
  padding: 3rem var(--gap-lg);
  max-width: 760px;
  margin: 0 auto;
}

/* Etiqueta verde pequeña ("Quiénes somos") */
.section-label {
  color: var(--color-green);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

/* Título serif de cada bloque */
.section-title {
  font-family: var(--font-serif);
  font-size: 26px;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 1rem;
  line-height: 1.25;
}

/* Variante más pequeña */
.section-title--sm {
  font-size: 20px;
}

/* Párrafo de texto */
.section-body {
  color: var(--color-muted);
  font-size: 14.5px;
  line-height: 1.75;
  margin-bottom: 1.5rem;
}

/* Línea decorativa dorada */
.divider {
  width: 48px;
  height: 3px;
  background: var(--color-gold);
  border-radius: 2px;
  margin: var(--gap-md) 0 var(--gap-lg);
}


/* ============================================================
   7. PRESENTACIÓN → MISIÓN
============================================================ */

.mission-block {
  background: var(--color-white);
  border-left: 4px solid var(--color-green);
  border-top: 1px solid var(--color-border);
  border-right: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  padding: var(--gap-md) 1.5rem;
  margin: 1.5rem 0;
}

.mission-block p {
  font-size: 14.5px;
  color: var(--color-muted);
  line-height: 1.75;
  font-style: italic;
}


/* ============================================================
   8. PRESENTACIÓN → TARJETA DOCTOR
============================================================ */

.doctor-card {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  display: flex;
  gap: var(--gap-md);
  align-items: flex-start;
  margin-bottom: var(--gap-lg);
}

/* Círculo con iniciales */
.doctor-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  overflow: hidden;        /* recorta la imagen en círculo */
  flex-shrink: 0;
}

.doctor-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;       /* llena el círculo sin deformar */
  object-position: top;    /* muestra la parte de arriba (cara) */
}

/* Nombre */
.doctor-info h3 {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 4px;
}

/* Especialidades */
.doctor-info .title-tag {
  font-size: 12px;
  color: var(--color-green);
  font-weight: 500;
  margin-bottom: var(--gap-sm);
}

/* Bio */
.doctor-info p {
  font-size: 13.5px;
  color: var(--color-muted);
  line-height: 1.65;
}

/* Contenedor de pills */
.pill-list {
  display: flex;
  flex-wrap: wrap;
  gap: var(--gap-xs);
  margin-top: var(--gap-sm);
}

/* Cada pill */
.pill {
  background: var(--color-input-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  font-size: 11.5px;
  color: var(--color-muted);
  padding: 4px var(--gap-sm);
}


/* ============================================================
   9. PRESENTACIÓN → DIFERENCIALES
============================================================ */

.diff-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--gap-sm);
  margin-top: 1.5rem;
}

.diff-item {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 14px;
  display: flex;
  align-items: flex-start;
  gap: var(--gap-sm);
}

.diff-icon {
  width: 32px;
  height: 32px;
  background: var(--color-green-lt);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.diff-icon i {
  color: var(--color-green);
  font-size: 16px;
}

.diff-item p {
  font-size: 12.5px;
  color: var(--color-muted);
  line-height: 1.5;
}


/* ============================================================
   10. SERVICIOS → HERO
============================================================ */

.services-hero {
  background:
    linear-gradient(to bottom, rgba(15, 42, 74, 0.97) 0%, transparent 30%),
    linear-gradient(to top,    rgba(15, 42, 74, 0.97) 0%, transparent 30%),
    linear-gradient(to right,  rgba(15, 42, 74, 0.97) 0%, transparent 20%),
    linear-gradient(to left,   rgba(15, 42, 74, 0.97) 0%, transparent 20%),
    linear-gradient(rgba(15, 42, 74, 0.70) 0%, rgba(15, 42, 74, 0.70) 100%),
    url('../assets/img/Foto procedimientos.JPG') center 40% / cover no-repeat;
  background-color: var(--color-navy);
  padding: 3rem var(--gap-lg) 2.5rem;
  text-align: center;
}

.services-hero h2 {
  font-family: var(--font-serif);
  color: var(--color-white);
  font-size: 30px;
  margin-bottom: 0.5rem;
}

.services-hero p {
  color: rgba(255, 255, 255, 0.6);
  font-size: 14px;
  max-width: 420px;
  margin: 0 auto;
  line-height: 1.6;
}


/* ============================================================
   11. SERVICIOS → FILTROS
============================================================ */

.srv-filtros {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 1.5rem var(--gap-lg) 0;
  flex-wrap: wrap;
}

.srv-filtro {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 500;
  color: var(--color-muted);
  padding: 6px 16px;
  cursor: pointer;
  transition: all 0.2s;
}

.srv-filtro:hover {
  border-color: var(--color-green);
  color: var(--color-green);
}

.srv-filtro.active {
  background: var(--color-green);
  border-color: var(--color-green);
  color: var(--color-white);
}


/* ============================================================
   12. SERVICIOS → CUADRÍCULA DE TARJETAS
============================================================ */

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--gap-sm);
  max-width: 860px;
  margin: 1.25rem auto;
  padding: 0 var(--gap-lg);
}

.service-card {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--gap-md);
  cursor: pointer;
  transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

/* Brillo verde sutil al hacer hover */
.service-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(26, 122, 94, 0.06) 0%, transparent 60%);
  opacity: 0;
  transition: opacity 0.2s;
}

.service-card:hover {
  transform: translateY(-4px);
  border-color: var(--color-green);
  box-shadow: 0 8px 24px rgba(26, 122, 94, 0.12);
}

.service-card:hover::before {
  opacity: 1;
}

/* Tarjeta destacada con borde dorado */
.service-card--highlight {
  border-top: 2px solid var(--color-gold);
}

.service-card--highlight .service-card-tag {
  color: var(--color-gold);
}

/* Ícono */
.service-icon-wrap {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--gap-sm);
}

.service-icon-wrap--teal { background: var(--color-green-lt); }
.service-icon-wrap--teal i { color: var(--color-green); font-size: 20px; }

.service-icon-wrap--navy { background: var(--color-blue-lt); }
.service-icon-wrap--navy i { color: var(--color-navy); font-size: 20px; }

.service-icon-wrap--gold { background: var(--color-gold-lt); }
.service-icon-wrap--gold i { color: var(--color-gold); font-size: 20px; }

/* Etiqueta de categoría */
.service-card-tag {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-green);
  margin-bottom: 4px;
}

.service-card h3 {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 6px;
  line-height: 1.3;
}

.service-card p {
  font-size: 12px;
  color: var(--color-muted);
  line-height: 1.55;
  margin-bottom: 0.75rem;
  flex: 1;
}

/* Footer de la tarjeta */
.service-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
}

.service-card-dur {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  color: var(--color-subtle);
}

.service-card-dur i { font-size: 13px; }

.service-card-more {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 600;
  color: var(--color-green);
  background: none;
  border: none;
  cursor: pointer;
  font-family: var(--font-sans);
  padding: 0;
}

.service-card-more i { font-size: 13px; }


/* ============================================================
   13. SERVICIOS → ENFERMEDADES
============================================================ */

.diseases-section {
  max-width: 860px;
  margin: 0 auto 2.5rem;
  padding: 0 var(--gap-lg);
}

.disease-title {
  font-family: var(--font-serif);
  font-size: 20px;
  color: var(--color-text);
  margin-bottom: 1rem;
}

.disease-pills { display: flex; flex-wrap: wrap; gap: 7px; }

.disease-pill {
  background: var(--color-input-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  font-size: 12.5px;
  color: var(--color-muted);
  padding: 6px 14px;
}


/* ============================================================
   18. MODAL DE SERVICIOS
============================================================ */

.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(10, 20, 35, 0.65);
  backdrop-filter: blur(4px);
  z-index: 200;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

.modal-overlay.active {
  display: flex;
}

.modal-card {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 460px;
  overflow: hidden;
  animation: modalIn 0.2s ease;
}

@keyframes modalIn {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0);    }
}

/* Cabecera azul del modal */
.modal-header {
  background: var(--color-navy);
  padding: 1.25rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 12px;
}

.modal-header-icon {
  width: 46px;
  height: 46px;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.modal-header-icon i {
  color: var(--color-gold);
  font-size: 22px;
}

.modal-header-text {
  flex: 1;
}

.modal-header-tag {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
  display: block;
  margin-bottom: 3px;
}

.modal-title {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 600;
  color: var(--color-white);
  line-height: 1.2;
}

.modal-close {
  background: rgba(255, 255, 255, 0.1);
  border: none;
  border-radius: 50%;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.7);
  flex-shrink: 0;
  transition: background 0.2s;
}

.modal-close:hover { background: rgba(255, 255, 255, 0.2); }

/* Cuerpo del modal */
.modal-body { padding: 1.25rem 1.5rem; }

.modal-desc {
  font-size: 13.5px;
  color: var(--color-muted);
  line-height: 1.75;
  margin-bottom: 1rem;
}

.modal-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 1.1rem;
}

.meta-item {
  background: var(--color-input-bg);
  border-radius: 8px;
  padding: 0.6rem 0.75rem;
  display: flex;
  align-items: center;
  gap: 7px;
}

.meta-item i {
  color: var(--color-green);
  font-size: 16px;
  flex-shrink: 0;
}

.meta-item span {
  font-size: 11.5px;
  color: var(--color-muted);
  line-height: 1.4;
}

/* Botón agendar del modal */
.modal-cta {
  width: 100%;
  background: var(--color-green);
  color: var(--color-white);
  border: none;
  border-radius: 9px;
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 600;
  padding: 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: background 0.2s;
}

.modal-cta:hover { background: #15654e; }
.modal-cta i { font-size: 18px; }


/* Responsive modal */
@media (max-width: 600px) {
  .modal-meta { grid-template-columns: 1fr; }
  .modal-card { border-radius: var(--radius-md); }
}


/* ============================================================
   13. AGENDAMIENTO → HERO
============================================================ */

.schedule-hero {
  background: var(--color-navy);
  padding: 3rem var(--gap-lg) 2.5rem;
  text-align: center;
}

.schedule-hero h2 {
  font-family: var(--font-serif);
  color: var(--color-white);
  font-size: 30px;
  margin-bottom: 0.5rem;
}

.schedule-hero p {
  color: rgba(255, 255, 255, 0.6);
  font-size: 14px;
  max-width: 400px;
  margin: 0 auto;
  line-height: 1.6;
}


/* ============================================================
   14. AGENDAMIENTO → FORMULARIO
============================================================ */

.schedule-content {
  max-width: 600px;
  margin: 0 auto;
  padding: var(--gap-lg);
}

.form-group {
  margin-bottom: 1rem;
}

.form-label {
  display: block;
  font-size: 12.5px;
  font-weight: 500;
  color: #444;
  margin-bottom: var(--gap-xs);
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  font-family: var(--font-sans);
  font-size: 14px;
  color: var(--color-text);
  background: var(--color-white);
  border: 1px solid var(--color-border-md);
  border-radius: 8px;
  padding: 10px 13px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  appearance: none;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  border-color: var(--color-green);
  box-shadow: 0 0 0 3px rgba(26, 122, 94, 0.1);
}

.form-textarea {
  min-height: 90px;
  resize: vertical;
}

/* Fila de 2 columnas */
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--gap-sm);
}

/* Botón WhatsApp */
.wa-btn {
  width: 100%;
  background: var(--color-wa);
  color: var(--color-white);
  border: none;
  border-radius: var(--radius-md);
  font-family: var(--font-sans);
  font-size: 15px;
  font-weight: 600;
  padding: 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--gap-sm);
  margin-top: var(--gap-md);
  transition: background 0.2s;
}

.wa-btn:hover {
  background: #1fb955;
}

.wa-btn i {
  font-size: 20px;
}


/* ============================================================
   15. AGENDAMIENTO → INFO DE CONTACTO
============================================================ */

.schedule-info {
  background: var(--color-input-bg);
  border-radius: var(--radius-md);
  padding: 1rem var(--gap-md);
  margin-top: 1.5rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.sched-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  color: var(--color-muted);
}

.sched-item i {
  color: var(--color-green);
  font-size: 16px;
}

/* Texto de aviso final */
.disclaimer {
  font-size: 11.5px;
  color: var(--color-subtle);
  text-align: center;
  margin-top: 1rem;
  line-height: 1.5;
}


/* ============================================================
   16. FOOTER
============================================================ */

.footer {
  background: var(--color-navy);
  text-align: center;
  padding: 1.5rem var(--gap-lg);
  margin-top: var(--gap-lg);
}

.footer p {
  color: rgba(255, 255, 255, 0.4);
  font-size: 12px;
}

.footer span {
  color: var(--color-gold);
}


/* ============================================================
   17. RESPONSIVE — MÓVIL (≤ 600px)
============================================================ */

@media (max-width: 600px) {

  /* Nav */
  .nav            { padding: 0 1rem; }
  .nav-logo       { font-size: 14px; }
  .nav-tab        { font-size: 11px; padding: 7px 10px; }

  /* Hero */
  .hero h1        { font-size: 26px; }

  /* Cuadrículas → 1 columna */
  .services-grid  { grid-template-columns: 1fr; }
  .diff-grid      { grid-template-columns: 1fr; }
  .form-row       { grid-template-columns: 1fr; }
  .schedule-info  { grid-template-columns: 1fr; }

  /* Location bar */
  .location-bar   { gap: 1rem; }

  /* Doctor card en columna */
  .doctor-card    { flex-direction: column; }
}

/* ============================================================
   18. MODAL DE SERVICIOS
============================================================ */

/* Fondo oscuro detrás del modal */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(10, 20, 35, 0.75);
  backdrop-filter: blur(4px);
  z-index: 200;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

.modal-overlay.active {
  display: flex;
}

/* Tarjeta del modal */
.modal-card {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  padding: 2rem;
  max-width: 480px;
  width: 100%;
  position: relative;
  animation: modalIn 0.2s ease;
}

@keyframes modalIn {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0);    }
}

/* Botón cerrar */
.modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: var(--color-input-bg);
  border: none;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--color-muted);
  transition: background 0.2s;
}

.modal-close:hover {
  background: var(--color-border);
}

/* Ícono del servicio */
.modal-icon-wrap {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  background: var(--color-green-lt);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
}

.modal-icon-wrap i {
  color: var(--color-green);
  font-size: 24px;
}

/* Título */
.modal-title {
  font-family: var(--font-serif);
  font-size: 20px;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 0.75rem;
  line-height: 1.3;
}

/* Descripción */
.modal-body {
  font-size: 14px;
  color: var(--color-muted);
  line-height: 1.75;
  margin-bottom: 1.5rem;
}

/* Botón agendar */
.modal-cta {
  width: 100%;
  background: var(--color-green);
  color: var(--color-white);
  border: none;
  border-radius: 8px;
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 600;
  padding: 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: background 0.2s;
}

.modal-cta:hover {
  background: #15654e;
}

/* Cursor pointer en tarjetas */
.service-card {
  cursor: pointer;
}

/* Responsive */
@media (max-width: 600px) {
  .modal-card {
    padding: 1.5rem;
  }
}
/* ============================================================
   19. REDES SOCIALES
============================================================ */

/* Link en la location bar */
.loc-item--link {
  text-decoration: none;
  transition: color 0.2s;
}

.loc-item--link:hover {
  color: var(--color-gold);
}

.loc-item--link i {
  color: var(--color-gold);
}

/* Íconos en el footer */
.footer-redes {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-top: 0.75rem;
}

.footer-redes a {
  color: rgba(255, 255, 255, 0.4);
  font-size: 20px;
  text-decoration: none;
  transition: color 0.2s;
}

.footer-redes a:hover {
  color: var(--color-gold);
}

/* ============================================================
   20. EQUIPO MÉDICO
============================================================ */

/* Hero */
.equipo-hero {
  background: var(--color-navy);
  padding: 3rem var(--gap-lg) 2.5rem;
  text-align: center;
}

.equipo-hero h2 {
  font-family: var(--font-serif);
  color: var(--color-white);
  font-size: 30px;
  margin-bottom: 0.5rem;
}

.equipo-hero p {
  color: rgba(255, 255, 255, 0.6);
  font-size: 14px;
  max-width: 460px;
  margin: 0 auto;
  line-height: 1.6;
}

/* Contenedor general */
.equipo-content {
  max-width: 860px;
  margin: 0 auto;
  padding: 3rem var(--gap-lg);
}

/* Separador entre médicos */
.equipo-separador {
  width: 100%;
  height: 1px;
  background: var(--color-border);
  margin: 3rem 0;
}

/* ── Tarjeta de cada médico ── */
.medico-card {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 2.5rem;
  align-items: start;
}

/* Versión invertida para la doctora */
.medico-card--reverse {
  grid-template-columns: 1fr 280px;
}

.medico-card--reverse .medico-foto-wrap {
  order: 2;
}

.medico-card--reverse .medico-info {
  order: 1;
}

/* Foto */
.medico-foto-wrap {
  position: sticky;
  top: 80px;
  text-align: center;
}

.medico-foto {
  width: 100%;
  max-width: 260px;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: top;
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border);
  display: block;
  margin: 0 auto;
}

.medico-badge-foto {
  display: inline-block;
  background: var(--color-navy);
  color: var(--color-gold);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  padding: 5px 12px;
  border-radius: var(--radius-xl);
  margin-top: 0.75rem;
}

/* Info del médico */
.medico-nombre {
  font-family: var(--font-serif);
  font-size: 24px;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 0.5rem;
  line-height: 1.2;
}

.medico-divider {
  width: 40px;
  height: 3px;
  background: var(--color-gold);
  border-radius: 2px;
  margin: 0.75rem 0 1rem;
}

.medico-bio {
  font-size: 14.5px;
  color: var(--color-muted);
  line-height: 1.75;
  margin-bottom: 1.5rem;
}

/* Bloques internos (formación, experiencia, intereses) */
.medico-bloque {
  margin-bottom: 1.5rem;
}

.medico-bloque-titulo {
  font-size: 13px;
  font-weight: 600;
  color: var(--color-text);
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.medico-bloque-titulo i {
  color: var(--color-green);
  font-size: 16px;
}

/* ── Timeline ── */
.timeline {
  display: flex;
  flex-direction: column;
  gap: 0;
  border-left: 2px solid var(--color-border);
  padding-left: 1.25rem;
  margin-left: 0.5rem;
}

.timeline-item {
  position: relative;
  padding-bottom: 1.25rem;
}

.timeline-item:last-child {
  padding-bottom: 0;
}

/* Punto en la línea */
.timeline-punto {
  position: absolute;
  left: -1.5rem;
  top: 4px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--color-green);
  border: 2px solid var(--color-white);
  outline: 2px solid var(--color-green);
}

.timeline-contenido {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.timeline-year {
  display: inline-block;
  background: var(--color-green-lt);
  color: var(--color-green);
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: var(--radius-xl);
  margin-bottom: 3px;
  width: fit-content;
}

.timeline-contenido strong {
  font-size: 13.5px;
  color: var(--color-text);
  font-weight: 600;
}

.timeline-contenido p {
  font-size: 12.5px;
  color: var(--color-muted);
  line-height: 1.5;
}

/* ── Equipo de apoyo ── */
.apoyo-section {
  text-align: center;
}

.apoyo-titulo {
  font-family: var(--font-serif);
  font-size: 24px;
  color: var(--color-text);
  margin-bottom: 0.5rem;
}

.apoyo-sub {
  font-size: 14px;
  color: var(--color-muted);
  max-width: 520px;
  margin: 0 auto 2rem;
  line-height: 1.7;
}

.apoyo-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--gap-sm);
}

.apoyo-card {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  text-align: left;
  transition: border-color 0.2s;
}

.apoyo-card:hover {
  border-color: var(--color-green);
}

.apoyo-icon {
  width: 44px;
  height: 44px;
  background: var(--color-green-lt);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0.75rem;
}

.apoyo-icon i {
  color: var(--color-green);
  font-size: 22px;
}

.apoyo-card h4 {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 6px;
}

.apoyo-card p {
  font-size: 12.5px;
  color: var(--color-muted);
  line-height: 1.6;
}

/* ============================================================
   17. RESPONSIVE
============================================================ */

/* ── Tablet (≤ 768px) ── */
@media (max-width: 768px) {

  /* Nav: logo más pequeño, pestañas más compactas */
  .nav           { padding: 0 1rem; gap: 0.5rem; }
  .nav-logo      { font-size: 14px; }
  .nav-logo small{ display: none; }   /* oculta "Duitama · Boyacá" */
  .nav-tab       { font-size: 12px; padding: 7px 10px; }

  /* Hero */
  .hero          { min-height: 420px; padding: 3rem 1.25rem; }
  .hero h1       { font-size: 30px; }
  .hero-sub      { font-size: 14px; }

  /* Cuadrículas a 2 columnas */
  .services-grid { grid-template-columns: 1fr 1fr; }
  .diff-grid     { grid-template-columns: 1fr 1fr; }
  .apoyo-grid    { grid-template-columns: 1fr 1fr; }

  /* Doctor card */
  .medico-card,
  .medico-card--reverse {
    grid-template-columns: 1fr;
  }
  .medico-card--reverse .medico-foto-wrap,
  .medico-card--reverse .medico-info { order: unset; }
  .medico-foto-wrap { position: static; }
}


/* ── Móvil (≤ 480px) ── */
@media (max-width: 480px) {

  /* Nav: se parte en dos filas */
  .nav {
    height: auto;
    flex-direction: column;
    align-items: flex-start;
    padding: 0.6rem 1rem;
    gap: 0.5rem;
  }

  .nav-tabs {
    width: 100%;
    overflow-x: auto;             /* scroll horizontal si no caben */
    padding-bottom: 0.4rem;
    gap: 4px;
    scrollbar-width: none;        /* oculta scrollbar en Firefox */
  }

  .nav-tabs::-webkit-scrollbar { display: none; }

  .nav-tab {
    font-size: 11.5px;
    padding: 6px 12px;
    flex-shrink: 0;               /* evita que se compriman */
  }

  /* Hero */
  .hero {
    min-height: 380px;
    padding: 2.5rem 1rem;
    background-size: cover;
    background-position: center top;
  }

  .hero h1       { font-size: 24px; }
  .hero-sub      { font-size: 13px; }
  .hero-badge    { font-size: 10px; }

  /* Location bar en columna */
  .location-bar  {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.6rem;
    padding: 1rem;
  }

  /* Todo a 1 columna */
  .services-grid  { grid-template-columns: 1fr; }
  .diff-grid      { grid-template-columns: 1fr; }
  .form-row       { grid-template-columns: 1fr; }
  .schedule-info  { grid-template-columns: 1fr; }
  .apoyo-grid     { grid-template-columns: 1fr; }
  .modal-meta     { grid-template-columns: 1fr; }

  /* Doctor card */
  .doctor-card   { flex-direction: column; }
  .medico-foto   { max-width: 160px; aspect-ratio: 1/1; }

  /* Contenido central */
  .content-section { padding: 2rem 1rem; }
  .section-title   { font-size: 22px; }
  .schedule-content{ padding: 1.5rem 1rem; }

  /* Modal */
  .modal-card    { border-radius: var(--radius-md); }
  .modal-overlay { padding: 0.75rem; }
}