/* ============================================================
   THEME — Azul marino + Dorado
   CV Dr. José Alfonso Aguilar-Calderón
   ============================================================ */

:root {
  --navy-900: #0A2540;
  --navy-800: #0F3257;
  --navy-700: #16406B;
  --navy-600: #1B4F8C;
  --gold-500: #C9A84C;
  --gold-400: #D9BD6E;
  --gold-100: #F5EBD2;
  --bg-soft: #F7F8FA;
  --text-muted: #6B7480;
  --border-soft: #E7E9ED;
  --success: #1E8449;
}

* { box-sizing: border-box; }

body {
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  color: #1A1F29;
  background: var(--bg-soft);
  padding-top: 70px;
}

a { text-decoration: none; }

/* ---------- NAVBAR ---------- */
.navbar-cv {
  background: var(--navy-900);
  padding: 0.85rem 0;
}

.navbar-cv .navbar-brand {
  color: #fff;
  font-weight: 600;
  font-size: 1.05rem;
  letter-spacing: 0.2px;
}

.navbar-foto {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--gold-400);
}

.navbar-iniciales {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--gold-500);
  color: var(--navy-900);
  font-weight: 700;
  font-size: 0.95rem;
}

.navbar-cv .nav-link {
  color: rgba(255,255,255,0.78);
  font-size: 0.92rem;
  padding: 0.5rem 0.9rem !important;
  transition: color 0.15s;
}

.navbar-cv .nav-link:hover,
.navbar-cv .nav-link.active {
  color: var(--gold-400);
}

.navbar-cv .btn-en {
  border: 1px solid rgba(255,255,255,0.25);
  color: #fff;
  font-size: 0.85rem;
  padding: 0.3rem 0.8rem;
  border-radius: 6px;
}

.navbar-cv .btn-en:hover {
  border-color: var(--gold-400);
  color: var(--gold-400);
}

/* ---------- HERO ---------- */
.hero {
  background: linear-gradient(135deg, var(--navy-900) 0%, var(--navy-700) 100%);
  color: #fff;
  padding: 4.5rem 0 5rem;
  position: relative;
  overflow: hidden;
  scroll-margin-top: 75px;
}

.hero::after {
  content: '';
  position: absolute;
  top: -50%;
  right: -10%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(201,168,76,0.10) 0%, transparent 70%);
  border-radius: 50%;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(201,168,76,0.15);
  border: 1px solid rgba(201,168,76,0.35);
  color: var(--gold-400);
  font-size: 0.8rem;
  padding: 5px 14px;
  border-radius: 20px;
  margin-bottom: 1.2rem;
}

.hero h1 {
  font-size: 2.6rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
  line-height: 1.15;
}

.hero .lead-role {
  font-size: 1.15rem;
  color: rgba(255,255,255,0.85);
  margin-bottom: 1.6rem;
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 2rem;
}

.hero-tag {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.14);
  color: rgba(255,255,255,0.92);
  font-size: 0.82rem;
  padding: 5px 13px;
  border-radius: 16px;
}

.hero-photo {
  width: 200px !important;
  height: 200px !important;
  max-width: 200px;
  min-width: 200px;
  border-radius: 50%;
  border: 4px solid rgba(201,168,76,0.5);
  object-fit: cover;
  object-position: center top;
  background: var(--navy-600);
  display: inline-block;
}

.hero-social {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin-top: 8px;
}

.hero-social a {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
  width: 70px;
  color: rgba(255,255,255,0.85);
  font-size: 1.2rem;
  transition: 0.15s;
  text-decoration: none;
  text-align: center;
}

.hero-social a span {
  font-size: 0.68rem;
  letter-spacing: 0.2px;
  color: rgba(255,255,255,0.6);
  line-height: 1.2;
  white-space: nowrap;
}

.hero-social a .bi {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
  flex-shrink: 0;
}

.hero-social a:hover { color: var(--gold-400); }
.hero-social a:hover .bi { background: var(--gold-500); color: var(--navy-900); }
.hero-social a:hover span { color: var(--gold-400); }

/* ---------- BUTTONS ---------- */
.btn-gold {
  background: var(--gold-500);
  border: none;
  color: var(--navy-900);
  font-weight: 600;
  padding: 0.55rem 1.4rem;
  border-radius: 8px;
}

.btn-gold:hover {
  background: var(--gold-400);
  color: var(--navy-900);
}

.btn-outline-light-cv {
  border: 1px solid rgba(255,255,255,0.35);
  color: #fff;
  padding: 0.55rem 1.4rem;
  border-radius: 8px;
}

.btn-outline-light-cv:hover {
  border-color: var(--gold-400);
  color: var(--gold-400);
}

/* ---------- METRIC CARDS ---------- */
.metrics-strip {
  background: var(--navy-800);
  padding: 1.8rem 0;
  border-top: 1px solid rgba(255,255,255,0.08);
}

.metric-card { text-align: center; color: #fff; }
.metric-card .num { font-size: 2rem; font-weight: 700; color: var(--gold-400); }
.metric-card .lbl {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.65);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ---------- SECTIONS ---------- */
.section { padding: 4rem 0; scroll-margin-top: 75px; }
.section-light { background: #fff; }

.section-tag {
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--gold-500);
  margin-bottom: 0.4rem;
}

.section-title {
  font-size: 1.85rem;
  font-weight: 700;
  color: var(--navy-900);
  margin-bottom: 1rem;
}

.section-desc {
  color: var(--text-muted);
  max-width: 700px;
  margin-bottom: 2.2rem;
}

/* ---------- CARDS ---------- */
.cv-card {
  background: #fff;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  padding: 1.4rem 1.5rem;
  height: 100%;
  transition: 0.18s;
}

.cv-card:hover {
  border-color: var(--gold-500);
  box-shadow: 0 6px 24px rgba(10,37,64,0.08);
  transform: translateY(-2px);
}

.cv-card .icon-circle {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: var(--navy-900);
  color: var(--gold-400);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  margin-bottom: 1rem;
}

.cv-card h6 {
  font-weight: 600;
  color: var(--navy-900);
  margin-bottom: 0.5rem;
}

.cv-card p {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-bottom: 0;
}

/* ---------- PUBLICATIONS CARDS ---------- */
.pub-filters .btn {
  font-size: 0.82rem;
  border-radius: 18px;
  padding: 5px 16px;
  border: 1px solid var(--border-soft);
  color: var(--navy-800);
  background: #fff;
}

.pub-filters .btn.active,
.pub-filters .btn:hover {
  background: var(--navy-900);
  color: #fff;
  border-color: var(--navy-900);
}

.pub-card {
  background: #fff;
  border: 1px solid var(--border-soft);
  border-left: 3px solid var(--gold-500);
  border-radius: 10px;
  padding: 1.1rem 1.3rem;
  margin-bottom: 0.9rem;
}

.pub-card .pub-badge {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  padding: 3px 9px;
  border-radius: 5px;
  margin-right: 6px;
}

.badge-jcr { background: var(--gold-100); color: #8A6D1F; }
.badge-revista { background: #E6F1FB; color: #185FA5; }
.badge-capitulo { background: #EAF3DE; color: #3B6D11; }
.badge-libro { background: #FAECE7; color: #993C1D; }

.pub-card .pub-title {
  font-weight: 600;
  color: var(--navy-900);
  font-size: 0.95rem;
  margin: 6px 0 4px;
}

.pub-card .pub-meta {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.pub-card .pub-year {
  font-size: 0.78rem;
  color: var(--gold-500);
  font-weight: 600;
}

/* ---------- TIMELINE (tesis, formación, experiencia) ---------- */
.timeline-item {
  position: relative;
  padding-left: 28px;
  padding-bottom: 1.6rem;
  border-left: 2px solid var(--border-soft);
  margin-left: 8px;
}

.timeline-item:last-child {
  border-left-color: transparent;
  padding-bottom: 0;
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: -7px;
  top: 2px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--gold-500);
  border: 2px solid #fff;
  box-shadow: 0 0 0 2px var(--gold-500);
}

.timeline-item .ti-title {
  font-weight: 600;
  color: var(--navy-900);
  font-size: 0.95rem;
}

.timeline-item .ti-meta {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.timeline-item .ti-badge {
  font-size: 0.7rem;
  background: var(--gold-100);
  color: #8A6D1F;
  padding: 2px 9px;
  border-radius: 5px;
  font-weight: 600;
}

/* ---------- PROJECT CARDS ---------- */
.project-card {
  background: #fff;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  overflow: hidden;
  height: 100%;
}

.project-card .project-img {
  height: 150px;
  background: linear-gradient(135deg, var(--navy-800), var(--navy-600));
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold-400);
  font-size: 2rem;
}

.project-card .project-body {
  padding: 1.2rem 1.3rem;
}

.project-card .status-pill {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 12px;
}

.status-en_curso { background: #E6F1FB; color: #185FA5; }
.status-finalizado { background: #EAF3DE; color: #3B6D11; }

/* ---------- BLOG CARDS (ANOVA LAB MX) ---------- */
.blog-card {
  display: block;
  background: #fff;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  overflow: hidden;
  height: 100%;
  text-decoration: none;
  transition: 0.18s;
}

.blog-card:hover {
  border-color: var(--gold-500);
  box-shadow: 0 6px 24px rgba(10,37,64,0.08);
  transform: translateY(-3px);
}

.blog-card__img {
  height: 150px;
  background-size: cover;
  background-position: center;
  background-color: var(--navy-700);
}

.blog-card__img--placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--navy-800), var(--navy-600));
  color: var(--gold-400);
  font-size: 2.2rem;
}

.blog-card__body { padding: 1.1rem 1.2rem; }

.blog-card__date {
  font-size: 0.72rem;
  color: var(--gold-500);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.blog-card__title {
  font-weight: 600;
  color: var(--navy-900);
  font-size: 0.95rem;
  margin: 6px 0 8px;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.blog-card__excerpt {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 10px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.blog-card__link {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--navy-700);
}

.blog-card:hover .blog-card__link { color: var(--gold-500); }

/* ---------- CONFERENCE CARDS ---------- */
.conf-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #fff;
  border: 1px solid var(--border-soft);
  border-radius: 10px;
  padding: 1rem 1.3rem;
  margin-bottom: 0.8rem;
}

.conf-type-badge {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 12px;
}

.type-congreso_internacional { background: var(--gold-100); color: #8A6D1F; }
.type-iniciativa_privada { background: #FBEAF0; color: #993556; }
.type-congreso_nacional { background: #E6F1FB; color: #185FA5; }
.type-institucional { background: #EAF3DE; color: #3B6D11; }

/* ---------- FOOTER ---------- */
.footer-cv {
  background: var(--navy-900);
  color: rgba(255,255,255,0.65);
  padding: 2.5rem 0;
  font-size: 0.88rem;
}

.footer-cv a { color: rgba(255,255,255,0.85); }
.footer-cv a:hover { color: var(--gold-400); }

/* ---------- ADMIN ---------- */
.admin-sidebar {
  background: var(--navy-900);
  min-height: 100vh;
  padding: 1.5rem 1rem;
}

.admin-sidebar .brand {
  color: #fff;
  font-weight: 600;
  font-size: 1rem;
  margin-bottom: 2rem;
  display: block;
}

.admin-sidebar .nav-link {
  color: rgba(255,255,255,0.7);
  font-size: 0.88rem;
  padding: 0.55rem 0.8rem;
  border-radius: 8px;
  margin-bottom: 2px;
}

.admin-sidebar .nav-link i {
  width: 20px;
  display: inline-block;
}

.admin-sidebar .nav-link:hover {
  background: rgba(255,255,255,0.06);
  color: #fff;
}

.admin-sidebar .nav-link.active {
  background: var(--gold-500);
  color: var(--navy-900);
  font-weight: 600;
}

/*
  FIX ADMIN:
  Se elimina el layout flex del contenido administrativo porque margin-top:auto
  en el footer provocaba que visualmente se montara sobre las tablas/cards.
*/
.admin-content {
  background: var(--bg-soft);
  min-height: 100vh;
  padding: 2rem;
  overflow-x: hidden;
  width: 100%;
  display: block;
}

.admin-page-body {
  width: 100%;
  padding-bottom: 2rem;
}

.admin-footer {
  clear: both;
  position: relative;
  z-index: 20;
  margin-top: 2rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border-soft);
  width: 100%;
  background: var(--bg-soft);
}

.admin-content .row {
  position: relative;
  z-index: 1;
}

.admin-content canvas {
  max-width: 100%;
}

/* Las tarjetas del admin no deben comportarse como cards públicas */
.admin-content .cv-card {
  height: auto !important;
  min-height: auto !important;
  margin-bottom: 2rem;
  transform: none !important;
}

.admin-content .cv-card:hover {
  transform: none !important;
  box-shadow: 0 6px 24px rgba(10,37,64,0.08);
}

.admin-content .table {
  margin-bottom: 0;
}

.admin-content .table-admin {
  position: relative;
  z-index: 1;
  margin-bottom: 0;
}

.admin-content .table-admin tbody tr,
.admin-content .table-admin tbody tr:hover {
  position: relative;
  z-index: 1;
}

.admin-content .table-responsive {
  overflow-x: auto;
  overflow-y: visible;
}

.admin-stat-card {
  background: #fff;
  border-radius: 12px;
  padding: 1.3rem 1.4rem;
  border: 1px solid var(--border-soft);
}

.admin-stat-card .num {
  font-size: 1.7rem;
  font-weight: 700;
  color: var(--navy-900);
}

.admin-stat-card .lbl {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.login-badge {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: var(--navy-900);
  color: var(--gold-400);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
}

.admin-sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}

@media (max-width: 991.98px) {
  body > .d-flex { flex-direction: column; }

  .admin-sidebar {
    position: relative;
    width: 100% !important;
    height: auto;
    min-height: auto;
  }

  .admin-content {
    padding: 1.25rem;
  }
}

.table-admin th {
  font-size: 0.78rem;
  text-transform: uppercase;
  color: var(--text-muted);
  border-bottom-width: 1px;
}

.table-admin td {
  font-size: 0.88rem;
  vertical-align: middle;
}

.badge-rol-director { background: var(--gold-100); color: #8A6D1F; }
.badge-rol-codirector { background: #E6F1FB; color: #185FA5; }

/* ============================================================
   CONFIGURACIÓN COMERCIAL 1.0
   Tema claro/oscuro e identidad institucional configurable
   ============================================================ */
.navbar-logo-institucional {
  max-height: 38px;
  max-width: 150px;
  object-fit: contain;
  background: rgba(255,255,255,0.95);
  padding: 4px 8px;
  border-radius: 8px;
}

.hero-institutional-logo img {
  max-height: 76px;
  max-width: 260px;
  object-fit: contain;
  background: rgba(255,255,255,0.96);
  padding: 10px 14px;
  border-radius: 14px;
  box-shadow: 0 12px 30px rgba(0,0,0,0.12);
}

/* ============================================================
   FIX PROFESIONAL TEMA CLARO / OSCURO
   Compatibilidad con clases: theme-light/theme-dark y theme-claro/theme-oscuro
   ============================================================ */

/* ---------- Tema claro: variables base ---------- */
body.theme-light,
body.theme-claro {
  --navy-900: #0A2540;
  --navy-800: #0F3257;
  --navy-700: #16406B;
  --navy-600: #1B4F8C;
  --bg-soft: #F6F8FB;
  --text-muted: #5E6A78;
  --border-soft: #E1E7EF;
  background: #F6F8FB !important;
  color: #162033 !important;
}

/* ---------- Fondo de secciones ---------- */
body.theme-light .section,
body.theme-claro .section {
  background: #F6F8FB;
}

body.theme-light .section-light,
body.theme-claro .section-light {
  background: #FFFFFF !important;
}

/* ---------- Encabezados y textos principales ---------- */
body.theme-light .section-title,
body.theme-light h1,
body.theme-light h2,
body.theme-light h3,
body.theme-light h4,
body.theme-light h5,
body.theme-light h6,
body.theme-claro .section-title,
body.theme-claro h1,
body.theme-claro h2,
body.theme-claro h3,
body.theme-claro h4,
body.theme-claro h5,
body.theme-claro h6 {
  color: #0A2540 !important;
}

body.theme-light .section-tag,
body.theme-claro .section-tag {
  color: #B68A1D !important;
}

body.theme-light .section-desc,
body.theme-light p,
body.theme-light li,
body.theme-light .small,
body.theme-light small,
body.theme-light .text-muted,
body.theme-claro .section-desc,
body.theme-claro p,
body.theme-claro li,
body.theme-claro .small,
body.theme-claro small,
body.theme-claro .text-muted {
  color: #475569 !important;
}

/* Evita textos blancos heredados del tema oscuro */
body.theme-light .text-white,
body.theme-light .text-light,
body.theme-claro .text-white,
body.theme-claro .text-light {
  color: #162033 !important;
}

/* ---------- Navbar claro ---------- */
body.theme-light .navbar-cv,
body.theme-claro .navbar-cv {
  background: rgba(255, 255, 255, 0.97) !important;
  border-bottom: 1px solid #E1E7EF;
  box-shadow: 0 8px 24px rgba(15, 35, 65, 0.08);
}

body.theme-light .navbar-cv .navbar-brand,
body.theme-light .navbar-cv .nav-link,
body.theme-claro .navbar-cv .navbar-brand,
body.theme-claro .navbar-cv .nav-link {
  color: #243044 !important;
}

body.theme-light .navbar-cv .nav-link:hover,
body.theme-light .navbar-cv .nav-link.active,
body.theme-claro .navbar-cv .nav-link:hover,
body.theme-claro .navbar-cv .nav-link.active {
  color: var(--gold-500) !important;
}

body.theme-light .navbar-toggler,
body.theme-claro .navbar-toggler {
  filter: none !important;
}

/* ---------- Hero claro ---------- */
body.theme-light .hero,
body.theme-claro .hero {
  background: linear-gradient(135deg, #FFFFFF 0%, #EDF3FA 100%) !important;
  color: #162033 !important;
  border-bottom: 1px solid #E1E7EF;
}

body.theme-light .hero h1,
body.theme-claro .hero h1 {
  color: #0A2540 !important;
}

body.theme-light .hero .lead-role,
body.theme-light .hero-social a,
body.theme-light .hero-social a span,
body.theme-claro .hero .lead-role,
body.theme-claro .hero-social a,
body.theme-claro .hero-social a span {
  color: #526174 !important;
}

body.theme-light .hero-tag,
body.theme-claro .hero-tag {
  background: #FFFFFF !important;
  border-color: #E3E8EF !important;
  color: #263348 !important;
}

body.theme-light .hero-social a .bi,
body.theme-claro .hero-social a .bi {
  background: #FFFFFF !important;
  border: 1px solid #E3E8EF;
  color: #0A2540;
}

body.theme-light .hero-social a:hover,
body.theme-light .hero-social a:hover span,
body.theme-claro .hero-social a:hover,
body.theme-claro .hero-social a:hover span {
  color: var(--gold-500) !important;
}

body.theme-light .hero-social a:hover .bi,
body.theme-claro .hero-social a:hover .bi {
  background: var(--gold-500) !important;
  color: #0A2540 !important;
}

/* ---------- Métricas ---------- */
body.theme-light .metrics-strip,
body.theme-claro .metrics-strip {
  background: #FFFFFF !important;
  border-top: 1px solid #E1E7EF;
  border-bottom: 1px solid #E1E7EF;
}

body.theme-light .metric-card,
body.theme-claro .metric-card {
  color: #162033 !important;
}

body.theme-light .metric-card .lbl,
body.theme-claro .metric-card .lbl {
  color: #64748B !important;
}

/* ---------- Cards generales ---------- */
body.theme-light .cv-card,
body.theme-light .pub-card,
body.theme-light .project-card,
body.theme-light .blog-card,
body.theme-light .conf-card,
body.theme-light .admin-stat-card,
body.theme-claro .cv-card,
body.theme-claro .pub-card,
body.theme-claro .project-card,
body.theme-claro .blog-card,
body.theme-claro .conf-card,
body.theme-claro .admin-stat-card {
  background: #FFFFFF !important;
  color: #162033 !important;
  border-color: #E1E7EF !important;
}

body.theme-light .cv-card h6,
body.theme-light .pub-card .pub-title,
body.theme-light .blog-card__title,
body.theme-light .admin-stat-card .num,
body.theme-claro .cv-card h6,
body.theme-claro .pub-card .pub-title,
body.theme-claro .blog-card__title,
body.theme-claro .admin-stat-card .num {
  color: #0A2540 !important;
}

body.theme-light .cv-card p,
body.theme-light .pub-card .pub-meta,
body.theme-light .blog-card__excerpt,
body.theme-light .admin-stat-card .lbl,
body.theme-claro .cv-card p,
body.theme-claro .pub-card .pub-meta,
body.theme-claro .blog-card__excerpt,
body.theme-claro .admin-stat-card .lbl {
  color: #64748B !important;
}

/* ---------- Timeline ---------- */
body.theme-light .timeline-item,
body.theme-claro .timeline-item {
  border-left-color: #DDE5EF !important;
}

body.theme-light .timeline-item .ti-title,
body.theme-claro .timeline-item .ti-title {
  color: #0A2540 !important;
}

body.theme-light .timeline-item .ti-meta,
body.theme-claro .timeline-item .ti-meta {
  color: #64748B !important;
}

/* ---------- Conferencias / listas / detalles ---------- */
body.theme-light .conf-card strong,
body.theme-light .conf-card .fw-semibold,
body.theme-claro .conf-card strong,
body.theme-claro .conf-card .fw-semibold {
  color: #0A2540 !important;
}

/* ---------- Dropdown ---------- */
body.theme-light .dropdown-menu,
body.theme-claro .dropdown-menu {
  background: #FFFFFF !important;
  border-color: #E1E7EF !important;
  box-shadow: 0 14px 32px rgba(15, 35, 65, 0.12);
}

body.theme-light .dropdown-item,
body.theme-claro .dropdown-item {
  color: #243044 !important;
}

body.theme-light .dropdown-item:active,
body.theme-light .dropdown-item:hover,
body.theme-claro .dropdown-item:active,
body.theme-claro .dropdown-item:hover {
  background: #F3F6FA !important;
  color: var(--gold-500) !important;
}

/* ---------- Footer claro ---------- */
body.theme-light .footer-cv,
body.theme-claro .footer-cv {
  background: #FFFFFF !important;
  color: #526174 !important;
  border-top: 1px solid #E1E7EF;
}

body.theme-light .footer-cv a,
body.theme-claro .footer-cv a {
  color: #0A2540 !important;
}

body.theme-light .footer-cv a:hover,
body.theme-claro .footer-cv a:hover {
  color: var(--gold-500) !important;
}

/* ---------- Admin en claro ---------- */
body.theme-light .admin-content,
body.theme-claro .admin-content {
  background: #F6F8FB !important;
  color: #162033 !important;
}

/* ---------- Compatibilidad tema oscuro explícito ---------- */
body.theme-dark,
body.theme-oscuro {
  background: var(--bg-soft);
  color: #1A1F29;
}

/* Footer público oscuro al final para asegurar consistencia */
.footer-cv {
  background: #071426;
  color: #fff;
}

.footer-cv .border {
  border-color: rgba(255,255,255,.10) !important;
}

.footer-cv img {
  filter: drop-shadow(0 0 10px rgba(0,123,255,.20));
}

/* Ajustes Asistente IA */
.ai-saved-card {
  max-height: 520px;
  overflow-y: auto;
}

.ai-textarea {
  min-height: 420px;
  resize: vertical;
}

@media (max-width: 991.98px) {
  .ai-saved-card { max-height: none; }
  .ai-textarea { min-height: 320px; }
}

/* FIX: quitar espacio superior en panel admin */

body:has(.admin-sidebar) {

  padding-top: 0 !important;

}