/* ==========================================================================
   ESTILOS PRINCIPALES: MARCA PERSONAL INVERSOR (MODO CLARO PROFESIONAL)
   ========================================================================== */

:root {
  /* Paleta de Colores: Limpio, luminoso y financiero */
  --bg-primary: #ffffff;
  --bg-secondary: #f8fafc;
  --bg-tertiary: #f1f5f9;
  --bg-card: #ffffff;
  --border-color: #e2e8f0;
  --border-subtle: #cbd5e1;

  /* Tipografías & Textos */
  --text-main: #0f172a;       /* Slate 900 */
  --text-body: #334155;       /* Slate 700 */
  --text-muted: #64748b;      /* Slate 500 */
  --text-light: #94a3b8;      /* Slate 400 */

  /* Acentos de Marca & Finanzas */
  --primary: #1e40af;         /* Navy azul financiero */
  --primary-hover: #1d4ed8;
  --primary-light: #eff6ff;
  --success: #059669;         /* Verde rentabilidad */
  --success-bg: #ecfdf5;
  --success-border: #a7f3d0;
  --danger: #dc2626;          /* Rojo drawdown */
  --danger-bg: #fef2f2;
  --purple: #6d28d9;
  --purple-bg: #f5f3ff;

  /* Sombras elegantes */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.07), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -4px rgba(0, 0, 0, 0.04);
  --shadow-hover: 0 20px 25px -5px rgba(0, 0, 0, 0.08), 0 8px 10px -6px rgba(0, 0, 0, 0.03);

  /* Fuentes Modernas Financieras */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-display: 'Plus Jakarta Sans', var(--font-sans);
  --font-num: 'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

  /* Espaciado & Bordes */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Reset básico */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 112px;
  font-size: 16px;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-primary);
  color: var(--text-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* Contenedor central */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Secciones */
.section {
  padding: 88px 0;
  position: relative;
}

.bg-soft {
  background-color: #f8fafc;
}

/* Divisor horizontal visible y elegante entre apartados de la web */
.section-divider {
  width: 100%;
  max-width: 1140px;
  margin: 0 auto;
  border: none;
  height: 1.5px;
  background: linear-gradient(90deg, transparent 0%, #cbd5e1 15%, #94a3b8 50%, #cbd5e1 85%, transparent 100%);
  display: block;
  opacity: 0.85;
}

.section-header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 56px auto;
}

.section-tag {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  background-color: var(--primary-light);
  padding: 4px 12px;
  border-radius: 9999px;
  margin-bottom: 12px;
}

.section-title {
  font-size: 2.25rem;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: -0.025em;
  margin-bottom: 16px;
}

.section-subtitle {
  font-size: 1.1rem;
  color: var(--text-muted);
}

/* ==========================================================================
   MARKET & THESES LIVE TICKER TAPE
   ========================================================================== */
.market-ticker-bar {
  position: sticky;
  top: 0;
  left: 0;
  width: 100%;
  height: 34px;
  background: #070d17;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  z-index: 105;
  display: flex;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  color: #cbd5e1;
  user-select: none;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
}

.ticker-badge-live {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0 14px;
  height: 100%;
  background: #070d17;
  z-index: 3;
  font-weight: 700;
  letter-spacing: 0.08em;
  font-size: 0.68rem;
  color: #f8fafc;
  border-right: 1px solid rgba(255, 255, 255, 0.09);
  flex-shrink: 0;
  box-shadow: 6px 0 12px -2px rgba(0, 0, 0, 0.5);
}

.ticker-live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
  animation: livePulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes livePulse {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.4;
    transform: scale(0.85);
  }
}

.ticker-track-wrap {
  flex: 1;
  height: 100%;
  overflow: hidden;
  position: relative;
  display: flex;
  align-items: center;
  mask-image: linear-gradient(90deg, transparent 0%, black 14px, black calc(100% - 14px), transparent 100%);
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, black 14px, black calc(100% - 14px), transparent 100%);
}

.ticker-track {
  display: flex;
  align-items: center;
  white-space: nowrap;
  animation: tickerScroll 40s linear infinite;
  will-change: transform;
}

.ticker-track-wrap:hover .ticker-track {
  animation-play-state: paused;
}

.ticker-content {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.ticker-item {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0 12px;
  height: 34px;
  color: #cbd5e1;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.ticker-item a.ticker-item-link {
  color: inherit;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 100%;
  padding: 0 4px;
  border-radius: 4px;
  transition: all 0.2s ease;
}

.ticker-item a.ticker-item-link:hover {
  color: #38bdf8;
  background: rgba(255, 255, 255, 0.08);
}

.ticker-item-inner {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.ticker-item-badge {
  font-size: 0.62rem;
  font-weight: 700;
  padding: 1px 5px;
  border-radius: 3px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  line-height: 1.3;
}

.badge-index {
  background: rgba(59, 130, 246, 0.18);
  color: #93c5fd;
  border: 1px solid rgba(96, 165, 250, 0.35);
}

.badge-thesis {
  background: rgba(16, 185, 129, 0.18);
  color: #6ee7b7;
  border: 1px solid rgba(52, 211, 153, 0.35);
}

.badge-closed {
  background: rgba(148, 163, 184, 0.18);
  color: #cbd5e1;
  border: 1px solid rgba(148, 163, 184, 0.35);
}

.ticker-item-name {
  font-weight: 600;
  color: #f1f5f9;
  font-size: 0.72rem;
}

.ticker-item-price {
  font-weight: 500;
  color: #e2e8f0;
  font-size: 0.72rem;
  margin-left: 2px;
}

.ticker-item-chg {
  font-weight: 700;
  font-size: 0.70rem;
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 1px 4px;
  border-radius: 3px;
}

.ticker-item-chg.chg-up {
  color: #34d399;
  background: rgba(16, 185, 129, 0.12);
}

.ticker-item-chg.chg-down {
  color: #f87171;
  background: rgba(239, 68, 68, 0.12);
}

.ticker-arrow {
  font-size: 0.60rem;
  line-height: 1;
}

.ticker-item-separator {
  color: rgba(255, 255, 255, 0.18);
  margin: 0 4px;
  font-weight: 300;
  font-size: 0.75rem;
}

@keyframes tickerScroll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

/* ==========================================================================
   NAVBAR
   ========================================================================== */
.navbar {
  position: sticky;
  top: 34px;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  z-index: 100;
  height: 72px;
  display: flex;
  align-items: center;
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.nav-left {
  display: flex;
  align-items: center;
  gap: 14px;
  position: relative;
}

/* Desplegable de navegación superior izquierda */
.nav-dropdown {
  position: relative;
}

.nav-dropdown-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: var(--radius-sm);
  color: var(--text-main);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  user-select: none;
}

.nav-dropdown-btn:hover,
.nav-dropdown-btn.active {
  background: #eff6ff;
  border-color: #bfdbfe;
  color: var(--primary);
  box-shadow: 0 2px 6px rgba(30, 64, 175, 0.08);
}

.nav-dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  width: 260px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  box-shadow: 0 16px 36px -6px rgba(15, 23, 42, 0.14), 0 6px 14px -3px rgba(15, 23, 42, 0.06);
  padding: 8px;
  display: none;
  flex-direction: column;
  gap: 2px;
  z-index: 1100;
  animation: dropdownFadeIn 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-dropdown-menu.open {
  display: flex;
}

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

.dropdown-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  color: var(--text-main);
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 600;
  border-radius: 6px;
  transition: background-color 0.15s ease, color 0.15s ease, transform 0.15s ease;
}

.dropdown-item:hover {
  background: #f1f5f9;
  color: var(--primary);
  transform: translateX(2px);
}

.dropdown-item-icon {
  font-size: 1.05rem;
  width: 22px;
  text-align: center;
  flex-shrink: 0;
}

.dropdown-item-text {
  flex-grow: 1;
}

.dropdown-divider {
  height: 1px;
  background: #e2e8f0;
  margin: 6px 4px;
}

.dropdown-divider-subtle {
  height: 1px;
  background: #f1f5f9;
  margin: 2px 6px;
}

.dropdown-item-external {
  color: var(--primary);
  background: #eff6ff;
  border: 1px solid #dbeafe;
}

.dropdown-item-external:hover {
  background: #dbeafe;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text-main);
  font-weight: 700;
  font-size: 1.15rem;
}

.logo-badge {
  background: var(--primary);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  font-weight: 700;
  letter-spacing: 0.05em;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 20px;
}

.nav-links a {
  text-decoration: none;
  color: var(--text-muted);
  font-size: 0.95rem;
  font-weight: 500;
  transition: var(--transition);
}

.nav-links a:hover {
  color: var(--primary);
}

.mobile-menu-btn {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}

.mobile-menu-btn span {
  width: 22px;
  height: 2px;
  background-color: var(--text-main);
  transition: var(--transition);
}

.mobile-drawer {
  display: none;
  background: #fff;
  border-bottom: 1px solid var(--border-color);
  padding: 16px 24px;
  flex-direction: column;
  gap: 16px;
}

.mobile-drawer.open {
  display: flex;
}

.mobile-link {
  text-decoration: none;
  color: var(--text-main);
  font-weight: 500;
  font-size: 1.05rem;
}

/* ==========================================================================
   BOTONES
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  transition: var(--transition);
}

.btn-primary {
  background-color: var(--primary);
  color: #ffffff;
  box-shadow: 0 1px 2px rgba(30, 64, 175, 0.2);
}

.btn-primary:hover {
  background-color: var(--primary-hover);
  box-shadow: 0 4px 12px rgba(30, 64, 175, 0.3);
  transform: translateY(-1px);
}

.btn-secondary {
  background-color: var(--bg-card);
  color: var(--text-main);
  border-color: var(--border-subtle);
  box-shadow: var(--shadow-sm);
}

.btn-secondary:hover {
  background-color: var(--bg-secondary);
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-1px);
}

.btn-outline-sm {
  padding: 8px 16px;
  border: 1px solid var(--border-subtle);
  background: transparent;
  color: var(--text-main);
  font-size: 0.85rem;
  border-radius: var(--radius-sm);
}

.btn-outline-sm:hover {
  border-color: var(--primary);
  color: var(--primary);
  background-color: var(--primary-light);
}

/* ==========================================================================
   HERO SECTION
   ========================================================================== */
.hero-section {
  padding: 80px 0 100px 0;
  background: radial-gradient(circle at 80% 20%, #eff6ff 0%, #ffffff 50%);
  border-bottom: 1px solid var(--border-color);
}

.hero-container {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 64px;
  align-items: center;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background-color: #ffffff;
  border: 1px solid var(--border-color);
  padding: 6px 14px;
  border-radius: 9999px;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-muted);
  box-shadow: var(--shadow-sm);
  margin-bottom: 24px;
}

.pulse-dot {
  width: 8px;
  height: 8px;
  background-color: var(--success);
  border-radius: 50%;
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
}

.hero-title {
  font-size: 3.35rem;
  line-height: 1.12;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: -0.035em;
  margin-bottom: 28px;
}

.text-highlight {
  color: var(--primary);
  background: linear-gradient(120deg, var(--primary) 0%, #3b82f6 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: 1.18rem;
  color: var(--text-body);
  margin-bottom: 36px;
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  gap: 16px;
  margin-bottom: 0;
}

.hero-stats {
  display: flex;
  gap: 32px;
  padding-top: 28px;
  border-top: 1px solid var(--border-color);
}

.hero-stat-card {
  display: flex;
  flex-direction: column;
}

.stat-value {
  font-size: 1.85rem;
  font-weight: 800;
  font-family: var(--font-num);
  font-variant-numeric: tabular-nums lining-nums;
  letter-spacing: -0.025em;
  color: var(--text-main);
}

.stat-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
}

.text-success {
  color: var(--success) !important;
}

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

/* Tarjeta preview de la derecha */
.hero-card-preview {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 0;
  overflow: hidden;
  box-shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.05), 0 4px 6px -2px rgba(15, 23, 42, 0.02);
  position: relative;
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.hero-card-preview:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 30px -8px rgba(15, 23, 42, 0.08), 0 4px 10px -2px rgba(15, 23, 42, 0.03);
}

.hero-card-cover {
  width: 100%;
  height: 190px;
  position: relative;
  overflow: hidden;
  background-color: #0f172a;
}

.hero-card-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 55%;
  display: block;
  transition: transform 0.4s ease;
}

.hero-card-preview:hover .hero-card-cover img {
  transform: scale(1.04);
}

.hero-cover-tag {
  position: absolute;
  top: 14px;
  right: 14px;
  background: rgba(15, 23, 42, 0.82);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  color: #ffffff;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 4px 12px;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.preview-card-inner {
  padding: 24px 28px 24px 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.preview-card-header {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-color);
}

.author-avatar-wrapper {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--bg-tertiary);
  border: 2px solid var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
}

.author-avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  display: block;
}

.author-avatar-fallback {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--primary);
  font-size: 1.2rem;
}

.author-header-meta h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-main);
}

.author-header-meta p {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.preview-card-body {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.metric-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.9rem;
  padding: 8px 12px;
  background-color: var(--bg-secondary);
  border-radius: var(--radius-sm);
}

.metric-row-label {
  color: var(--text-muted);
  font-weight: 500;
}

.metric-row-val {
  color: var(--text-main);
  font-weight: 600;
}

.preview-card-footer {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  color: var(--text-muted);
  padding-top: 14px;
  border-top: 1px dashed var(--border-color);
}

.status-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--success);
}

/* ==========================================================================
   FILOSOFÍA / PRINCIPIOS
   ========================================================================== */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 32px 28px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--border-subtle);
}

.feature-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}

.icon-blue {
  background-color: var(--primary-light);
  color: var(--primary);
}

.icon-green {
  background-color: var(--success-bg);
  color: var(--success);
}

.icon-purple {
  background-color: var(--purple-bg);
  color: var(--purple);
}

.feature-card h3 {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 12px;
}

.feature-card p {
  color: var(--text-body);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* ==========================================================================
   TRACK RECORD (KPIS + GRÁFICO + TABLA)
   ========================================================================== */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 36px;
}

.kpi-card {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 24px;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.kpi-card:hover {
  border-color: var(--border-subtle);
  transform: translateY(-2px);
}

/* Banner de Aclaración Metodológica (Sin Benchmark Oficial) */
.methodology-note-banner {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-left: 4px solid var(--primary);
  border-radius: var(--radius-md);
  padding: 18px 22px;
  margin-bottom: 32px;
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--text-body);
  box-shadow: var(--shadow-sm);
}

.methodology-note-banner .note-icon {
  color: var(--primary);
  flex-shrink: 0;
  margin-top: 2px;
}

.methodology-note-banner strong {
  color: var(--text-main);
  font-weight: 700;
}

.kpi-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 600;
  margin-bottom: 8px;
}

.kpi-value {
  font-family: var(--font-num);
  font-size: 2.15rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums lining-nums;
  letter-spacing: -0.03em;
  color: var(--text-main);
  line-height: 1.1;
  margin-bottom: 8px;
}

.kpi-benchmark {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* Gráfico */
.chart-container-card {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 36px;
}

.chart-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 16px;
}

.chart-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-main);
}

.chart-subtitle {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.chart-legend-custom {
  display: flex;
  gap: 20px;
  font-size: 0.85rem;
  font-weight: 600;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 8px;
}

.legend-dot {
  width: 12px;
  height: 12px;
  border-radius: 3px;
}

.dot-portfolio {
  background-color: #1e40af;
}

.dot-benchmark {
  background-color: #94a3b8;
}

.canvas-wrapper {
  position: relative;
  height: 380px;
  width: 100%;
}

/* Tabla de Rentabilidades */
.table-card {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 28px 32px;
  box-shadow: var(--shadow-sm);
}

.table-card-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 16px;
}

.table-responsive {
  overflow-x: auto;
}

.returns-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.95rem;
}

.returns-table th {
  padding: 14px 16px;
  border-bottom: 2px solid var(--border-color);
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.returns-table td {
  padding: 13px 16px;
  border-bottom: 1px solid var(--border-color);
  font-family: var(--font-num);
  font-variant-numeric: tabular-nums lining-nums;
  letter-spacing: -0.015em;
  font-size: 0.92rem;
}

.returns-table tr:hover {
  background-color: var(--bg-secondary);
}

.badge-alpha-pos {
  color: var(--success);
  font-weight: 600;
}

.badge-alpha-neg {
  color: var(--danger);
  font-weight: 600;
}

/* ==========================================================================
   PESTAÑAS INSTITUCIONALES (TRACK RECORD & CARTERA)
   ========================================================================== */
.track-tabs-container {
  margin-top: 10px;
}

.track-tabs-nav {
  display: inline-flex;
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 4px;
  gap: 6px;
  margin-bottom: 24px;
}

.track-tab-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: transparent;
  border: none;
  padding: 9px 20px;
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition);
}

.track-tab-btn:hover {
  color: var(--text-main);
}

.track-tab-btn.active {
  background: #ffffff;
  color: var(--text-main);
  box-shadow: var(--shadow-sm);
}

.track-tab-pane {
  display: none;
}

.track-tab-pane.active {
  display: block;
  animation: tabFadeIn 0.28s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

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

/* Tablas con estética de terminal financiero sobrio */
.financial-dense-table {
  font-size: 0.88rem;
}

.financial-dense-table th {
  padding: 10px 14px;
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  background-color: var(--bg-secondary);
}

.financial-dense-table td {
  padding: 12px 14px;
  font-size: 0.88rem;
}

.portfolio-meta-pills {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.meta-pill {
  font-size: 0.78rem;
  font-family: var(--font-mono);
  padding: 4px 10px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--text-body);
}

.meta-pill-primary {
  background: var(--primary-light);
  border-color: #bfdbfe;
  color: var(--primary);
  font-weight: 700;
}

.contact-btn-linkedin {
  background-color: #0a66c2 !important;
  color: #ffffff !important;
  border-color: #0a66c2 !important;
  padding: 14px 28px !important;
  font-size: 1.05rem !important;
  box-shadow: 0 4px 14px rgba(10, 102, 194, 0.25) !important;
}

.contact-btn-linkedin:hover {
  background-color: #004182 !important;
  color: #ffffff !important;
  border-color: #004182 !important;
  transform: translateY(-2px) !important;
}

/* ==========================================================================
   TESIS DE INVERSIÓN (TARJETAS + FILTROS)
   ========================================================================== */
.theses-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 36px;
  gap: 20px;
  flex-wrap: wrap;
}

.filter-pills {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.filter-pill {
  background: #ffffff;
  border: 1px solid var(--border-color);
  padding: 8px 16px;
  border-radius: 9999px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition);
}

.filter-pill:hover,
.filter-pill.active {
  background-color: var(--primary);
  color: #ffffff;
  border-color: var(--primary);
  box-shadow: 0 2px 4px rgba(30, 64, 175, 0.2);
}

.search-box {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #ffffff;
  border: 1px solid var(--border-color);
  padding: 8px 16px;
  border-radius: var(--radius-md);
  min-width: 320px;
  box-shadow: var(--shadow-sm);
}

.search-box input {
  border: none;
  outline: none;
  font-size: 0.9rem;
  width: 100%;
  color: var(--text-main);
}

.search-box svg {
  color: var(--text-muted);
}

/* Grid de tesis */
.theses-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.thesis-card {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: var(--shadow-sm);
  transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.28s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.2s ease;
  position: relative;
}

.thesis-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 16px 32px -8px rgba(15, 23, 42, 0.08), 0 4px 12px -2px rgba(15, 23, 42, 0.04);
  border-color: rgba(30, 64, 175, 0.28);
}

.thesis-card-img-wrap {
  width: 100%;
  height: 180px;
  overflow: hidden;
  position: relative;
  background-color: var(--bg-tertiary);
}

.thesis-card-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.thesis-card:hover .thesis-card-img-wrap img {
  transform: scale(1.05);
}

.thesis-card-rating-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(4px);
  color: #ffffff;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 9999px;
  letter-spacing: 0.03em;
}

.thesis-card-body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.card-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.ticker-badge {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--primary);
  background-color: var(--primary-light);
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  letter-spacing: 0.05em;
}

.status-pill {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 9999px;
  text-transform: uppercase;
}

.status-active {
  background-color: var(--success-bg);
  color: var(--success);
  border: 1px solid var(--success-border);
}

.status-closed {
  background-color: var(--bg-tertiary);
  color: var(--text-muted);
  border: 1px solid var(--border-color);
}

.thesis-title {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 4px;
  line-height: 1.25;
}

.thesis-sector {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 14px;
}

.thesis-summary {
  font-size: 0.92rem;
  color: var(--text-body);
  line-height: 1.55;
  margin-bottom: 20px;
  flex-grow: 1;
}

.thesis-metrics {
  background-color: var(--bg-secondary);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  margin-bottom: 20px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.thesis-metric-item {
  display: flex;
  flex-direction: column;
}

.thesis-metric-item .lbl {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 500;
}

.thesis-metric-item .val {
  font-family: var(--font-num);
  font-variant-numeric: tabular-nums lining-nums;
  letter-spacing: -0.015em;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-main);
}

.card-footer {
  border-top: 1px solid var(--border-color);
  padding: 18px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  background-color: #ffffff;
}

.btn-word-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  color: #1e40af;
  background: var(--primary-light);
  border: 1px solid #bfdbfe;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  transition: var(--transition);
}

.btn-word-pill:hover {
  background-color: #dbeafe;
  border-color: #93c5fd;
  color: #1d4ed8;
  transform: translateY(-1px);
}

.btn-read-thesis {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--primary);
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 6px 0;
  transition: var(--transition);
}

.btn-read-thesis svg {
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-read-thesis:hover {
  color: var(--primary-hover);
}

.thesis-card:hover .btn-read-thesis svg {
  transform: translateX(3px);
}

/* Gráficos dentro del modal */
.modal-chart-item {
  margin: 24px 0;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 16px;
  text-align: center;
}

.modal-chart-item img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
}

.modal-chart-caption {
  margin-top: 10px;
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* ==========================================================================
   CONTACTO Y NEWSLETTER
   ========================================================================== */
.contact-card {
  background: linear-gradient(135deg, #ffffff 0%, var(--primary-light) 100%);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 56px 48px;
  box-shadow: var(--shadow-sm);
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.contact-content h2 {
  font-size: 2rem;
  font-weight: 800;
  color: var(--text-main);
  margin: 16px 0;
  line-height: 1.25;
}

.contact-content p {
  font-size: 1.05rem;
  color: var(--text-body);
  max-width: 600px;
  margin: 0 auto 36px auto;
}

.contact-links {
  display: flex;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}

.contact-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: #ffffff;
  border: 1px solid var(--border-color);
  padding: 12px 20px;
  border-radius: var(--radius-md);
  text-decoration: none;
  color: var(--text-main);
  font-weight: 600;
  font-size: 0.9rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.contact-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* ==========================================================================
   MODAL DE TESIS
   ========================================================================== */
.modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
  transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.25s ease;
}

.modal-backdrop.open {
  opacity: 1;
  pointer-events: auto;
  visibility: visible;
}

.modal-dialog {
  background: #ffffff;
  width: 100%;
  max-width: 800px;
  max-height: 90vh;
  border-radius: var(--radius-lg);
  box-shadow: 0 25px 50px -12px rgba(15, 23, 42, 0.25);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transform: scale(0.96) translateY(8px);
  transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-backdrop.open .modal-dialog {
  transform: scale(1) translateY(0);
}

.modal-close {
  position: absolute;
  top: 20px;
  right: 24px;
  font-size: 2rem;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-muted);
  line-height: 1;
}

.modal-close:hover {
  color: var(--text-main);
}

.modal-header {
  padding: 32px 36px 20px 36px;
  border-bottom: 1px solid var(--border-color);
}

.modal-badge-row {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

.badge {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.85rem;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  background-color: var(--primary-light);
  color: var(--primary);
}

.badge-category {
  font-size: 0.85rem;
  color: var(--text-muted);
  padding: 4px 10px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-sm);
}

.modal-header h2 {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 16px;
}

.modal-meta {
  display: flex;
  gap: 24px;
  font-size: 0.9rem;
  color: var(--text-muted);
  flex-wrap: wrap;
}

.modal-meta strong {
  color: var(--text-main);
}

.modal-body {
  padding: 32px 36px;
  overflow-y: auto;
  line-height: 1.7;
  color: var(--text-body);
}

.modal-body h4 {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-main);
  margin: 24px 0 10px 0;
}

.modal-body h4:first-child {
  margin-top: 0;
}

.modal-body p {
  margin-bottom: 16px;
}

.modal-body ul {
  padding-left: 20px;
  margin-bottom: 16px;
}

.modal-body li {
  margin-bottom: 8px;
}

.callout-box {
  background-color: var(--bg-secondary);
  border-left: 4px solid var(--primary);
  padding: 16px 20px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin: 20px 0;
  font-size: 0.95rem;
}

.modal-footer {
  padding: 20px 36px;
  border-top: 1px solid var(--border-color);
  background-color: var(--bg-secondary);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* ==========================================================================
   FOOTER Y DISCLAIMER
   ========================================================================== */
.footer {
  background: #ffffff;
  border-top: 1px solid var(--border-color);
  padding: 64px 0 32px 0;
}

.footer-top {
  display: flex;
  justify-content: space-between;
  margin-bottom: 40px;
  gap: 40px;
  flex-wrap: wrap;
}

.footer-brand {
  max-width: 400px;
}

.footer-desc {
  margin-top: 12px;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.footer-nav {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-nav h4 {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-main);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}

.footer-nav a {
  text-decoration: none;
  color: var(--text-muted);
  font-size: 0.9rem;
  transition: var(--transition);
}

.footer-nav a:hover {
  color: var(--primary);
}

.footer-disclaimer {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 20px 24px;
  font-size: 0.8rem;
  line-height: 1.6;
  color: var(--text-muted);
  margin-bottom: 32px;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
  color: var(--text-light);
  border-top: 1px solid var(--border-color);
  padding-top: 24px;
  flex-wrap: wrap;
  gap: 12px;
}

/* ==========================================================================
   VIÑETA INTERACTIVA COMPACTA: SOBRE MÍ
   ========================================================================== */
.vignette-section {
  padding: 16px 0 28px 0;
  background: var(--bg-primary);
}

.about-vignette-pill {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 14px 22px;
  display: flex;
  align-items: center;
  gap: 18px;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
}

.about-vignette-pill::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(180deg, var(--primary) 0%, #38bdf8 100%);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.about-vignette-pill:hover {
  border-color: var(--primary);
  box-shadow: 0 6px 16px rgba(30, 64, 175, 0.08);
  transform: translateY(-2px);
}

.about-vignette-pill:hover::before {
  opacity: 1;
}

.vignette-badge {
  position: relative;
  flex-shrink: 0;
}

.vignette-avatar {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--primary) 0%, #1e3a8a 100%);
  color: #ffffff;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.05rem;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(30, 64, 175, 0.2);
}

.vignette-status-dot {
  position: absolute;
  bottom: -2px;
  right: -2px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #10b981;
  border: 2px solid #ffffff;
}

.vignette-body {
  flex-grow: 1;
  min-width: 0;
}

.vignette-meta-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-bottom: 3px;
}

.vignette-category {
  font-weight: 700;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-size: 0.72rem;
}

.vignette-divider {
  color: var(--border-subtle);
}

.vignette-headline {
  font-size: 0.92rem;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.vignette-headline strong {
  color: var(--text-main);
  font-weight: 700;
}

.vignette-btn-action {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--primary);
  background: var(--primary-light);
  border: 1px solid rgba(30, 64, 175, 0.15);
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
  transition: var(--transition);
}

.vignette-btn-action svg {
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.about-vignette-pill:hover .vignette-btn-action {
  background: var(--primary);
  color: #ffffff;
}

.about-vignette-pill:hover .vignette-btn-action svg {
  transform: translateX(3px);
}

.preview-about-link {
  background: transparent;
  border: none;
  color: var(--primary);
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  margin-left: auto;
  text-decoration: underline;
  padding: 0;
}

/* ==========================================================================
   MODAL DIALOG: SOBRE MÍ
   ========================================================================== */
.about-modal-dialog {
  max-width: 780px;
}

.about-modal-header-profile {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 14px;
}

.about-avatar-monogram {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--primary) 0%, #1e3a8a 100%);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  box-shadow: 0 4px 12px rgba(30, 64, 175, 0.22);
  flex-shrink: 0;
}

.about-modal-subtitle {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.about-modal-kpis {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}

.about-kpi-pill {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.about-kpi-pill svg {
  color: var(--primary);
  flex-shrink: 0;
  margin-top: 2px;
}

.about-kpi-pill strong {
  display: block;
  font-size: 0.86rem;
  color: var(--text-main);
  font-weight: 700;
}

.about-kpi-pill span {
  display: block;
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 2px;
  line-height: 1.35;
}

.about-modal-blocks {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.about-modal-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 18px 20px;
}

.about-modal-item .about-block-num {
  font-size: 0.75rem;
  font-family: var(--font-num);
  font-weight: 800;
  color: var(--primary);
  background-color: var(--primary-light);
  border: 1px solid rgba(30, 64, 175, 0.15);
  padding: 3px 8px;
  border-radius: 6px;
  flex-shrink: 0;
  margin-top: 2px;
}

.about-block-content h4 {
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 6px;
}

.about-block-content p {
  font-size: 0.88rem;
  color: var(--text-body);
  line-height: 1.6;
  margin: 0;
}

/* ==========================================================================
   RESPONSIVE DESIGN (TABLETS & MÓVILES)
   ========================================================================== */
@media (max-width: 1024px) {
  .hero-container {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .theses-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .kpi-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .grid-3 {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .nav-links {
    display: none;
  }
}

@media (max-width: 768px) {

  .ticker-badge-live {
    padding: 0 9px;
  }

  .ticker-live-text {
    display: none;
  }

  .ticker-item {
    padding: 0 8px;
    gap: 5px;
  }

  .about-vignette-pill {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .vignette-headline {
    white-space: normal;
  }

  .about-modal-kpis {
    grid-template-columns: 1fr;
  }

  .hero-title {
    font-size: 2.3rem;
  }

  .hero-stats {
    flex-wrap: wrap;
    gap: 20px;
  }

  .theses-grid {
    grid-template-columns: 1fr;
  }

  .kpi-grid {
    grid-template-columns: 1fr;
  }

  .theses-controls {
    flex-direction: column;
    align-items: stretch;
  }

  .search-box {
    min-width: 100%;
  }

  .chart-card-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .canvas-wrapper {
    height: 280px;
  }

  .modal-dialog {
    max-height: 95vh;
  }

  .modal-header, .modal-body, .modal-footer {
    padding-left: 20px;
    padding-right: 20px;
  }
}

/* ==========================================================================
   SCROLL REVEAL & ANIMACIONES DE ENTRADA
   ========================================================================== */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.65s cubic-bezier(0.16, 1, 0.3, 1), transform 0.65s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-delay-1 {
  transition-delay: 0.1s;
}

.reveal-delay-2 {
  transition-delay: 0.2s;
}

.reveal-delay-3 {
  transition-delay: 0.3s;
}

.reveal-delay-4 {
  transition-delay: 0.4s;
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}

/* ==========================================================================
   COTIZACIONES EN VIVO Y BADGE DE MERCADO DINÁMICO
   ========================================================================== */
.live-dot-pulse {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: #10b981;
  margin-right: 6px;
  vertical-align: middle;
  box-shadow: 0 0 0 rgba(16, 185, 129, 0.4);
  animation: livePulse 2s infinite ease-in-out;
}

@keyframes livePulse {
  0% {
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
  }
  70% {
    box-shadow: 0 0 0 7px rgba(16, 185, 129, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
  }
}

.modal-live-badge {
  display: inline-flex;
  align-items: center;
  background-color: #ecfdf5;
  color: #065f46;
  border: 1px solid #a7f3d0;
  padding: 1px 7px;
  border-radius: 6px;
  font-size: 0.88rem;
  font-weight: 700;
  margin-left: 2px;
}

.live-metric-item .lbl {
  color: #059669 !important;
  font-weight: 600 !important;
}

.live-metric-item .val {
  color: #0f172a;
}

/* ==========================================================================
   SECCIÓN SIMPLIFICADA EN EL MODAL (ACCESIBLE PARA TODOS)
   ========================================================================== */
.simplified-thesis-section {
  background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
  border: 1px solid #e2e8f0;
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 24px;
}

.simplified-banner {
  margin-bottom: 20px;
}

.simplified-badge {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  background: #eff6ff;
  color: var(--primary);
  border: 1px solid #bfdbfe;
  padding: 4px 10px;
  border-radius: 9999px;
  margin-bottom: 10px;
}

.simplified-heading {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 6px;
}

.simplified-sub {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.5;
  margin: 0;
}

.simplified-pillars-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.simplified-pillar-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: var(--radius-md);
  padding: 18px 16px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.simplified-pillar-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
  border-color: #cbd5e1;
}

.pillar-icon {
  font-size: 1.5rem;
  margin-bottom: 10px;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: #f8fafc;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #f1f5f9;
}

.pillar-content h5 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 8px;
  line-height: 1.35;
}

.pillar-content p {
  font-size: 0.88rem;
  color: var(--text-body);
  line-height: 1.55;
  margin: 0;
}

/* ==========================================================================
   BOTÓN INTERACTIVO PARA PROFUNDIZAR EN LA TESIS TÉCNICA
   ========================================================================== */
.deep-dive-trigger-wrap {
  margin: 24px 0;
}

.btn-deep-dive {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 22px;
  background: #ffffff;
  border: 2px solid var(--primary);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 2px 8px rgba(30, 64, 175, 0.08);
  text-align: left;
}

.btn-deep-dive:hover {
  background-color: #f0f7ff;
  border-color: #1d4ed8;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(30, 64, 175, 0.14);
}

.btn-deep-dive.active {
  background-color: #eff6ff;
  border-color: var(--primary);
}

.btn-deep-dive-inner {
  display: flex;
  align-items: center;
  gap: 14px;
}

.btn-deep-dive-icon {
  font-size: 1.6rem;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: var(--primary-light);
  flex-shrink: 0;
}

.btn-deep-dive-text {
  display: flex;
  flex-direction: column;
}

.btn-deep-dive-text strong {
  font-size: 0.98rem;
  color: var(--text-main);
  font-weight: 700;
  line-height: 1.3;
}

.btn-deep-dive-text span {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.35;
  margin-top: 2px;
}

.btn-deep-dive-arrow {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--primary);
  font-weight: 700;
  font-size: 0.88rem;
  flex-shrink: 0;
}

.chevron-toggle {
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-deep-dive.active .chevron-toggle {
  transform: rotate(180deg);
}

/* ==========================================================================
   PANEL COLAPSABLE DE ANÁLISIS TÉCNICO E INSTITUCIONAL
   ========================================================================== */
.deep-dive-panel {
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

.deep-dive-panel.collapsed {
  display: none;
  max-height: 0;
  opacity: 0;
  margin-top: 0;
  pointer-events: none;
}

.deep-dive-panel:not(.collapsed) {
  display: block;
  max-height: 8000px;
  opacity: 1;
  margin-top: 24px;
  padding-top: 20px;
  border-top: 2px dashed #cbd5e1;
  animation: panelExpand 0.35s ease forwards;
}

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

.deep-dive-header-notice {
  background: #f8fafc;
  border-left: 4px solid #0284c7;
  padding: 14px 18px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin-bottom: 24px;
}

.tech-badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: #0369a1;
  margin-bottom: 4px;
}

.deep-dive-header-notice p {
  font-size: 0.86rem;
  color: var(--text-body);
  margin: 0;
  line-height: 1.5;
}

/* Responsive para los 3 pilares simplificados */
@media (max-width: 768px) {
  .simplified-pillars-grid {
    grid-template-columns: 1fr;
  }
  
  .btn-deep-dive {
    padding: 14px 16px;
  }
  
  .btn-deep-dive-inner {
    gap: 10px;
  }
  
  .btn-deep-dive-icon {
    width: 36px;
    height: 36px;
    font-size: 1.3rem;
  }
  
  .btn-deep-dive-text strong {
    font-size: 0.9rem;
  }
  
  .btn-deep-dive-text span {
    font-size: 0.76rem;
  }
}

/* ==========================================================================
   ACTUALIDAD & COBERTURA DE MERCADO (NOTICIAS & SEGUIMIENTO FORENSE)
   ========================================================================== */
.news-controls-wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 32px;
  flex-wrap: wrap;
  gap: 16px;
}

.news-tabs-nav {
  display: flex;
  gap: 8px;
  background: #ffffff;
  padding: 6px;
  border-radius: 9999px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
}

.news-tab-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  border-radius: 9999px;
  border: none;
  background: transparent;
  cursor: pointer;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-muted);
  transition: var(--transition);
}

.news-tab-btn:hover {
  color: var(--text-main);
  background-color: var(--bg-secondary);
}

.news-tab-btn.active {
  background-color: var(--primary);
  color: #ffffff;
  box-shadow: 0 2px 6px rgba(30, 64, 175, 0.25);
}

.news-tab-icon {
  font-size: 1rem;
}

.news-tab-count {
  background: rgba(15, 23, 42, 0.08);
  font-size: 0.74rem;
  padding: 2px 8px;
  border-radius: 9999px;
  font-weight: 700;
  font-family: var(--font-num);
}

.news-tab-btn.active .news-tab-count {
  background: rgba(255, 255, 255, 0.25);
  color: #ffffff;
}

.news-last-updated {
  font-size: 0.85rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
}

.news-last-updated strong {
  color: var(--text-main);
}

/* ==========================================================================
   SEPARADOR DESTACADO ENTRE APARTADOS INDEPENDIENTES
   ========================================================================== */
.apartado-divider-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  max-width: 1140px;
  margin: 0 auto;
  padding: 44px 24px;
}

.apartado-divider-line {
  flex-grow: 1;
  height: 2px;
  background: linear-gradient(90deg, transparent 0%, #cbd5e1 100%);
}

.apartado-divider-wrap .apartado-divider-line:last-child {
  background: linear-gradient(90deg, #cbd5e1 0%, transparent 100%);
}

.apartado-divider-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 22px;
  background: #ffffff;
  border: 1.5px solid #cbd5e1;
  border-radius: 9999px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.05);
  white-space: nowrap;
}

.divider-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary);
}

.news-cards-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.news-card {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px 26px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.2s ease;
  position: relative;
}

.news-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 28px -6px rgba(15, 23, 42, 0.08);
  border-color: rgba(30, 64, 175, 0.25);
}

.news-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 12px;
}

.news-header-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.news-ticker-pill {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.78rem;
  background: var(--primary-light);
  color: var(--primary);
  padding: 3px 8px;
  border-radius: var(--radius-sm);
  border: 1px solid #bfdbfe;
}

.news-source-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 500;
}

.news-status-badge {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 9999px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.badge-positive {
  background: #ecfdf5;
  color: #065f46;
  border: 1px solid #a7f3d0;
}

.badge-macro {
  background: #eff6ff;
  color: #1e40af;
  border: 1px solid #bfdbfe;
}

.badge-neutral {
  background: #f8fafc;
  color: #475569;
  border: 1px solid #e2e8f0;
}

.news-card-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 10px;
  line-height: 1.35;
}

.news-card-summary {
  font-size: 0.9rem;
  color: var(--text-body);
  line-height: 1.6;
  margin-bottom: 0;
}

.news-takeaway-box {
  background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
  border-left: 3.5px solid var(--primary);
  padding: 12px 16px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin-top: auto;
}

.news-takeaway-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.news-takeaway-text {
  font-size: 0.86rem;
  color: var(--text-main);
  line-height: 1.5;
  margin: 0;
  font-weight: 500;
}

@media (max-width: 900px) {
  .news-cards-grid {
    grid-template-columns: 1fr;
  }
  
  .news-controls-wrap {
    flex-direction: column;
    align-items: flex-start;
  }
}

