/* ════════════════════════════════════════════════════════════════════════
   perfil2.css — Rediseño de /perfil según manual de marca (2026-07-03).
   Depende de design-system.css (tokens [data-brand=rava] + componentes:
   .tabla-cotizaciones, .topic-pill, .feature, .cta-*, .icon, fuentes).
   Scope: todo bajo .p2 para no tocar navbar/footer/materialize.
   Dark: la view setea data-brand="rava" en <html>, así el bridge
   html.dark[data-brand=rava] del design-system activa los tokens dark.
   ════════════════════════════════════════════════════════════════════════ */

.p2 {
  max-width: 1280px;
  margin: 0 auto;
  padding: 20px 20px 48px;
  font-family: 'Lora', Georgia, serif;
  font-size: 15px;
  line-height: 1.55;
  color: var(--text-body, #1D1D1B);
  -webkit-font-smoothing: antialiased;
}

/* ── Hero ─────────────────────────────────────────────────────────────── */
/* Hero en 2 columnas: identidad+precio a la izquierda, stats 4×2 a la derecha */
.p2-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px 28px;
  align-items: center;
  padding: 6px 2px 18px;
}
.p2-hero-id {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}
.p2-logo {
  flex-shrink: 0;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 800;
  border: 1px solid var(--border-color, #e3e3e3);
  overflow: hidden;
}
/* Los logos (admin/contenidos/logoperfil/*.svg) traen su propio fondo cuadrado
   de color: la imagen llena el círculo completo y el overflow la recorta
   redonda y nítida (SVG). Antes iba a 34px sobre el fondo → cuadrado flotando. */
.p2-logo img { width: 100%; height: 100%; object-fit: cover; }
.p2-hero-pills { grid-column: 1 / -1; margin-bottom: -2px; }
.p2-hero-pills .topic-pill { margin: 0 4px 0 0; }
.p2 .p2-h1 {
  font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
  font-size: 26px;
  font-weight: 800;
  line-height: 1.15;
  margin: 0;
  color: var(--brand-secundario, #1C2E4A);
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 10px;
}
.p2-ticker { color: var(--brand-primario, #005685); letter-spacing: 0.5px; }
.p2-nombre { font-weight: 600; font-size: 20px; color: var(--text-body); opacity: 0.85; }

.p2-quote {
  display: flex;
  align-items: baseline;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: flex-start;
  margin-top: 8px;
  font-variant-numeric: tabular-nums lining-nums;
}
.p2-price {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 40px;
  font-weight: 800;
  line-height: 1;
  color: var(--text-body);
  letter-spacing: -0.5px;
}
.p2-var {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 16px;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: 50px;
}
.p2-var--up   { color: var(--positivo, #15803d); background: color-mix(in srgb, var(--positivo, #15803d) 12%, transparent); }
.p2-var--down { color: var(--negativo, #b91c1c); background: color-mix(in srgb, var(--negativo, #b91c1c) 12%, transparent); }
.p2-var--flat { color: var(--text-secondary, #666); background: var(--bg-card-elevated, #F5F5F5); }
.p2-time {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 13px;
  color: var(--text-secondary, #666);
  white-space: nowrap;
}

.p2-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(112px, 1fr));
  gap: 6px;
  margin: 0;
  padding: 0;
  align-self: center;
}
.p2-stat {
  background: var(--bg-card, #FAFAFA);
  border: 1px solid var(--border-color, #e3e3e3);
  border-radius: 8px;
  padding: 5px 10px;
  min-width: 0;
}
.p2-stat dt {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 9.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-secondary, #666);
  margin: 0 0 1px;
}
.p2-stat dd {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-variant-numeric: tabular-nums lining-nums;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-body);
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── Grid principal ───────────────────────────────────────────────────── */
.p2-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 20px;
  align-items: start;
}
.p2-main, .p2-aside {
  display: flex;
  flex-direction: column;
  gap: 20px;
  min-width: 0;
}

/* ── Cards ────────────────────────────────────────────────────────────── */
.p2-card {
  background: var(--bg-card, #FAFAFA);
  border: 1px solid var(--border-color, #e3e3e3);
  border-radius: 12px;
  padding: 16px 18px 18px;
}
.p2-card--flush { padding: 16px 0 0; overflow: hidden; }
.p2-card--flush .p2-card-head { padding: 0 18px 12px; }
.p2-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px 16px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.p2-card--flush .p2-card-head { margin-bottom: 0; }
.p2 .p2-card-title {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 16px;
  font-weight: 800;
  margin: 0;
  /* Azul primario (pedido Juan): en dark el token resuelve a azul claro */
  color: var(--brand-primario, #005685);
}
.p2-card-title .icon { color: var(--brand-acento, #84683F); }
.p2 .p2-head-link { font-size: 13px; }

/* iframes de mercado */
.p2-frame-wrap { line-height: 0; }
.p2-frame-wrap iframe { width: 100%; height: 500px; border: 0; display: block; background: #fff; }
html.dark .p2-frame-wrap iframe { background: #111; }
.p2-aside .p2-frame-wrap iframe { height: 340px; }

/* ── Cuadro técnico ───────────────────────────────────────────────────── */
/* 7 columnas: Precio, %Día, %Mes, %Año, P/E, Beta y SST en una sola fila */
.p2-ct-returns {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
  margin-bottom: 14px;
}
.p2-ret {
  background: var(--bg-card-elevated, #F5F5F5);
  border-radius: 8px;
  padding: 6px 6px;
  text-align: center;
}
.p2-ret--pos { background: color-mix(in srgb, var(--positivo, #15803d) 10%, transparent); }
.p2-ret--neg { background: color-mix(in srgb, var(--negativo, #b91c1c) 10%, transparent); }
.p2-ret-label {
  display: block;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 9.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  color: var(--text-secondary, #666);
}
.p2-ret-val {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-variant-numeric: tabular-nums;
  font-size: 13.5px;
  font-weight: 800;
  color: var(--text-body);
  white-space: nowrap;
}
.p2-ret--pos .p2-ret-val { color: var(--positivo, #15803d); }
.p2-ret--neg .p2-ret-val { color: var(--negativo, #b91c1c); }

.p2-signals {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 14px;
}
.p2-signal {
  background: var(--bg-card-elevated, #F5F5F5);
  border-radius: 10px;
  padding: 12px 14px;
}
.p2-signal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.p2-signal-name {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 14px;
  font-weight: 800;
  color: var(--brand-secundario, #1C2E4A);
}
.p2-badge {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 3px 12px;
  border-radius: 50px;
}
.p2-badge--pos { color: #fff; background: var(--positivo, #15803d); }
.p2-badge--neg { color: #fff; background: var(--negativo, #b91c1c); }
html.dark .p2-badge--pos, html.dark .p2-badge--neg { color: #0A0A0A; }

.p2-kv { list-style: none; margin: 0; padding: 0; }
.p2-kv li {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 3px 0;
  font-size: 13.5px;
}
.p2-kv li span { color: var(--text-secondary, #666); font-family: 'Lora', serif; }
.p2-kv li strong {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  color: var(--text-body);
}
.p2-kv .p2-kv-sep {
  margin-top: 6px;
  padding-top: 6px;
  border-top: 1px dashed var(--border-color, #e3e3e3);
}
.p2-kv .p2-kv-sep span {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
}

/* ── Tablas (sobre .tabla-cotizaciones del design-system) ─────────────── */
/* min-height: 0 anula el anti-CLS global de head.php (min-height 200/500px
   sobre .tabla-cotizaciones), que acá dejaría vacío enorme en tablas cortas. */
.p2 .p2-tabla { background: transparent; border-radius: 8px; overflow-x: auto; min-height: 0; border: 0; }
.p2 .p2-tabla table { table-layout: auto; }
.p2 .p2-tabla thead th { position: sticky; top: 0; }
.p2 .p2-tabla tbody tr:hover { cursor: default; }
.p2-estimado { color: var(--text-secondary, #888); font-style: italic; }
.p2-footnote {
  margin: 10px 2px 0;
  font-size: 12.5px;
  color: var(--text-secondary, #666);
}
.p2-next-balance {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
  align-items: center;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 13px;
  color: var(--text-secondary, #666);
  background: var(--bg-card-elevated, #F5F5F5);
  border-radius: 8px;
  padding: 8px 12px;
  margin-bottom: 12px;
}
.p2-next-balance strong { color: var(--text-body); font-weight: 700; }
.p2-next-balance-label {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-weight: 800;
  color: var(--brand-secundario, #1C2E4A);
}

/* Cotizaciones históricas (aside): alto contenido con scroll y tipografía
   compacta para que las 6 columnas entren en los ~380px del aside. */
.p2-coti-hist { max-height: 420px; overflow-y: auto; }
.p2 .p2-coti-hist table { font-size: 12px; }
.p2 .p2-coti-hist thead th { padding: 4px 4px; font-size: 10.5px; letter-spacing: 0.3px; }
.p2 .p2-coti-hist tbody td { padding: 3px 4px; }
.p2-download { text-align: right; margin-top: 10px; }
/* Botón utilitario discreto (Juan: el CTA bronce era demasiado destaque) */
.p2 .p2-btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--brand-primario, #005685);
  background: transparent;
  border: 1px solid var(--border-color, #e3e3e3);
  border-radius: 50px;
  padding: 6px 14px;
  cursor: pointer;
  transition: background .15s, border-color .15s;
}
.p2 .p2-btn-ghost:hover {
  background: var(--bg-card-elevated, #F5F5F5);
  border-color: var(--brand-primario, #005685);
}
.p2 .p2-btn-ghost:disabled { opacity: 0.5; cursor: wait; }
.p2 a.p2-btn-ghost { text-decoration: none !important; }
/* Pie de card con acción utilitaria (mismo patrón que Descargar Excel) */
.p2-card-foot { text-align: right; margin-top: 10px; }

/* ── Card Comunidad Rava: identidad LMM (la comunidad vive en lmm.rava.com) ── */
.p2-comunidad-card {
  --lmm-acc: #007153;
  --lmm-vivo: #00BD8B;
  border-top: 3px solid var(--lmm-vivo);
}
html.dark .p2-comunidad-card { --lmm-acc: #00BD8B; }
.p2 .p2-comunidad-card .p2-card-title { color: var(--lmm-acc); }
.p2-comunidad-card .p2-card-title .icon { color: var(--lmm-acc); }
.p2 .p2-comunidad-card .p2-head-link { color: var(--lmm-acc); }
.p2-comunidad-card .p2-msg-user { color: var(--lmm-acc); }
.p2-comunidad-card .p2-msg {
  background: color-mix(in srgb, var(--lmm-vivo) 6%, var(--bg-card-elevated, #F5F5F5));
}
.p2 .p2-comunidad-card .p2-btn-ghost { color: var(--lmm-acc); }
.p2 .p2-comunidad-card .p2-btn-ghost:hover { border-color: var(--lmm-acc); }

/* ── Artículos ────────────────────────────────────────────────────────── */
.p2-art-list { display: flex; flex-direction: column; }
.p2-art {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  gap: 12px;
  padding: 10px 2px;
  border-top: 1px solid var(--border-color, #e3e3e3);
}
.p2-art:first-child { border-top: 0; padding-top: 2px; }
.p2-art-date {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary, #666);
  white-space: nowrap;
  padding-top: 2px;
}
.p2 .p2-art-link {
  font-family: 'Lora', serif;
  font-size: 15.5px;
  font-weight: 600;
  line-height: 1.35;
  color: var(--link-color, #003D5C);
  text-decoration: none;
}
.p2 .p2-art-link:hover { text-decoration: underline; text-underline-offset: 3px; }
.p2-art-desc { margin: 3px 0 0; font-size: 13.5px; color: var(--text-secondary, #666); }

/* ── Feature (info relevante) ─────────────────────────────────────────── */
.p2 .p2-feature { margin: 0; border-radius: 0 10px 10px 0; }
.p2 .p2-feature .title { display: inline-flex; align-items: center; gap: 6px; }

/* ── La mañana del mercado (sub-marca verde del manual, §2 LMM) ────────── */
.p2-lmm {
  --lmm-acc: #007153;        /* verde LMM legible sobre claro */
  --lmm-vivo: #00BD8B;       /* verde marca (acento/borde) */
  border-top: 3px solid var(--lmm-vivo);
}
html.dark .p2-lmm { --lmm-acc: #00BD8B; }
.p2 .p2-lmm-title { color: var(--lmm-acc); }
.p2 .p2-lmm-title .icon { color: var(--lmm-acc); }
.p2-lmm-live {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.5px;
  color: #fff !important;
  background: #e53935;
  border-radius: 50px;
  padding: 4px 12px;
  text-decoration: none !important;
  white-space: nowrap;
}
.p2-lmm-live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #fff;
  animation: p2-lmm-pulse 1.4s ease-in-out infinite;
}
@keyframes p2-lmm-pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.25; } }
@media (prefers-reduced-motion: reduce) { .p2-lmm-live-dot { animation: none; } }
.p2-lmm-sub {
  margin: 0 0 8px;
  font-size: 13px;
  color: var(--text-secondary, #666);
}
.p2-lmm-list { display: flex; flex-direction: column; }
.p2-lmm-item {
  display: flex;
  gap: 10px;
  padding: 9px 2px;
  border-top: 1px solid var(--border-color, #e3e3e3);
}
.p2-lmm-item:first-child { border-top: 0; padding-top: 2px; }
.p2-lmm-thumb { flex-shrink: 0; }
.p2-lmm-thumb img {
  width: 92px;
  height: 52px;
  object-fit: cover;
  border-radius: 6px;
  display: block;
}
.p2-lmm-body { min-width: 0; }
.p2-lmm-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 3px 10px;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 11px;
  color: var(--text-secondary, #666);
  margin-bottom: 2px;
}
.p2 .p2-lmm-menciones {
  font-weight: 700;
  color: var(--lmm-acc);
  text-decoration: none;
  background: color-mix(in srgb, var(--lmm-vivo) 12%, transparent);
  border-radius: 50px;
  padding: 1px 8px;
  white-space: nowrap;
}
.p2 a.p2-lmm-menciones:hover { text-decoration: underline; text-underline-offset: 2px; }
.p2 .p2-lmm-t {
  font-family: 'Lora', serif;
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.35;
  color: var(--link-color, #003D5C);
  text-decoration: none;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.p2 .p2-lmm-t:hover { text-decoration: underline; text-underline-offset: 3px; }
.p2-lmm-resumen {
  margin-top: 10px;
  background: var(--bg-card-elevated, #F5F5F5);
  border-radius: 8px;
  padding: 8px 12px;
}
.p2-lmm-resumen summary {
  cursor: pointer;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--lmm-acc);
}
.p2-lmm-resumen-cap {
  margin: 8px 0 0;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-secondary, #666);
}
.p2 .p2-lmm-resumen-link { display: inline-block; margin-top: 8px; font-size: 12.5px; color: var(--lmm-acc); }

/* Línea de tiempo de menciones (un punto por mención, clickeable al minuto) */
.p2-lmm-tl { position: relative; height: 16px; margin-top: 7px; }
.p2-lmm-tl::before {
  content: '';
  position: absolute;
  left: 0; right: 0; top: 50%;
  height: 3px;
  transform: translateY(-50%);
  background: color-mix(in srgb, var(--lmm-vivo) 22%, transparent);
  border-radius: 2px;
}
.p2-lmm-tl-dot {
  position: absolute;
  top: 50%;
  width: 9px; height: 9px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: var(--lmm-vivo);
  border: 1.5px solid var(--bg-card, #FAFAFA);
  transition: transform .1s;
}
.p2-lmm-tl-dot:hover { transform: translate(-50%, -50%) scale(1.55); }
.p2-lmm-tl-dot:focus-visible { outline: 2px solid var(--lmm-acc); outline-offset: 1px; }
@media (prefers-reduced-motion: reduce) { .p2-lmm-tl-dot { transition: none; } }
.p2-lmm-resumen p {
  margin: 8px 0 2px;
  font-size: 13px;
  line-height: 1.5;
  white-space: pre-line;
}
.p2 .p2-lmm-more { display: inline-block; margin-top: 12px; font-size: 13.5px; }

/* En la columna ancha (main): programas en 2 columnas y thumbs más grandes */
.p2-main .p2-lmm-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 22px;
}
.p2-main .p2-lmm-item:nth-child(2) { border-top: 0; padding-top: 2px; }
.p2-main .p2-lmm-thumb img { width: 112px; height: 63px; }
@media (max-width: 767px) {
  .p2-main .p2-lmm-list { grid-template-columns: 1fr; }
  .p2-main .p2-lmm-item:nth-child(2) { border-top: 1px solid var(--border-color, #e3e3e3); padding-top: 9px; }
}

/* ── Comunidad Rava ─────────────────────────────────────────────────────────────── */
.p2-comunidad { max-height: 460px; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; padding-right: 4px; }
.p2-msg {
  background: var(--bg-card-elevated, #F5F5F5);
  border-radius: 10px;
  padding: 8px 12px;
}
.p2-msg-meta {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 2px;
}
.p2-msg-user {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 13px;
  font-weight: 800;
  color: var(--brand-primario, #005685);
}
.p2-msg-time { font-family: 'Plus Jakarta Sans', sans-serif; font-size: 11px; color: var(--text-secondary, #666); white-space: nowrap; }
.p2-msg-text { margin: 0; font-size: 13.5px; line-height: 1.45; overflow-wrap: break-word; }
.p2 .p2-comunidad-cta { display: inline-block; margin-top: 12px; font-size: 13.5px; }

/* ── Perfil texto / más info ──────────────────────────────────────────── */
.p2-perfil-text { font-size: 14.5px; line-height: 1.6; }
.p2-perfil-text p { margin: 0 0 10px; }
.p2-masinfo { list-style: none; margin: 0; padding: 0; }
.p2-masinfo li { padding: 8px 0; border-top: 1px solid var(--border-color, #e3e3e3); }
.p2-masinfo li:first-child { border-top: 0; padding-top: 0; }
.p2-masinfo li a { display: inline-flex; align-items: center; gap: 5px; font-size: 14.5px; }
.p2-masinfo li p { margin: 3px 0 0; font-size: 13px; color: var(--text-secondary, #666); }

/* ── Noticias ─────────────────────────────────────────────────────────── */
.p2-news-list { display: flex; flex-direction: column; }
.p2-news {
  display: flex;
  gap: 12px;
  padding: 11px 2px;
  border-top: 1px solid var(--border-color, #e3e3e3);
}
.p2-news:first-child { border-top: 0; padding-top: 2px; }
.p2-news-img { flex-shrink: 0; }
.p2-news-img img {
  width: 72px;
  height: 54px;
  object-fit: cover;
  border-radius: 8px;
  display: block;
}
.p2-news-body { min-width: 0; }
.p2-news-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 8px;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 11.5px;
  color: var(--text-secondary, #666);
  margin-bottom: 2px;
}
.p2-news-src { font-weight: 700; }
.p2-news-lang {
  font-size: 10px;
  font-weight: 700;
  border: 1px solid var(--border-color, #e3e3e3);
  border-radius: 4px;
  padding: 0 4px;
}
.p2 .p2-news-title {
  font-family: 'Lora', serif;
  font-size: 14.5px;
  font-weight: 600;
  line-height: 1.35;
  color: var(--link-color, #003D5C);
  text-decoration: none;
  display: block;
}
.p2 .p2-news-title:hover { text-decoration: underline; text-underline-offset: 3px; }
.p2-news-desc {
  margin: 3px 0 0;
  font-size: 12.5px;
  line-height: 1.4;
  color: var(--text-secondary, #666);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.p2 .p2-news-more { display: inline-block; margin-top: 12px; font-size: 13.5px; }

/* ── Controles del fallback amCharts ──────────────────────────────────── */
.p2-chart-controls { display: flex; align-items: center; gap: 8px; }
.p2-select {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 13px;
  color: var(--text-body);
  background: var(--bg-card-elevated, #F5F5F5);
  border: 1px solid var(--border-color, #e3e3e3);
  border-radius: 8px;
  padding: 6px 10px;
  display: inline-block;
  width: auto;
  height: auto;
}
.p2-btn-sm {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 13px;
  font-weight: 700;
  color: var(--brand-primario-text, #fff);
  background: var(--brand-primario, #005685);
  border: 0;
  border-radius: 50px;
  padding: 7px 16px;
  cursor: pointer;
}
.p2-btn-sm:hover { filter: brightness(1.08); }
.p2-btn-sm:disabled { opacity: 0.5; cursor: wait; }

/* ── Sin datos ────────────────────────────────────────────────────────── */
.p2-sin-datos {
  text-align: center;
  padding: 80px 20px;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 17px;
  color: var(--text-secondary, #666);
}

/* ── Responsive ───────────────────────────────────────────────────────── */
@media (max-width: 1180px) {
  /* Sin espacio a la derecha: las stats vuelven abajo del bloque identidad */
  .p2-hero { grid-template-columns: 1fr; }
  .p2-stats { grid-column: 1 / -1; grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .p2-ct-returns { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 991px) {
  .p2 { padding: 14px 12px 40px; }
  .p2-grid { grid-template-columns: 1fr; }
  .p2-hero { grid-template-columns: 1fr; }
  .p2-quote { justify-content: flex-start; }
  .p2-price { font-size: 34px; }
  .p2-signals { grid-template-columns: 1fr; }
  .p2-frame-wrap iframe { height: 440px; }
  .p2-aside .p2-frame-wrap iframe { height: 340px; }
}
@media (max-width: 560px) {
  .p2-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .p2-ct-returns { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .p2 .p2-h1 { font-size: 22px; }
  .p2-nombre { font-size: 17px; }
  .p2-price { font-size: 30px; }
  .p2-news-img img { width: 60px; height: 45px; }
}

/* ── Noticias: 3 visibles + "Ver más" que expande el resto (2026-07-17) ── */
.p2-news--oculta { display: none !important; }
.p2-news-vermas {
  display: block; margin: 12px auto 4px; padding: 6px 14px;
  background: none; border: 0; cursor: pointer;
  font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 700; font-size: 14px;
  color: var(--link-color, #003D5C);
  text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 2px;
}
.p2-news-vermas:hover { color: var(--link-color-hover, #001E2E); text-decoration-thickness: 3px; }
.p2-news-vermas:focus-visible { outline: 2px solid var(--brand-acento, #84683F); outline-offset: 2px; }
