/* Centro de Control — Sprint UX-2 (hero ejecutivo + compresión) */

/* —— Hero ejecutivo —— */
#pg-exec .exec-hub-xhero {
  position: relative;
  overflow: hidden;
  margin-bottom: 12px;
  padding: 16px 16px 14px;
  border-radius: 14px;
  border: 1px solid #475569;
  background: linear-gradient(155deg, #0b1220 0%, #1e293b 38%, #334155 72%, #1e293b 100%);
  color: #f8fafc;
  box-shadow:
    0 12px 32px rgba(15, 23, 42, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

#pg-exec .exec-hub-xhero__glow {
  position: absolute;
  inset: -40% -20% auto -20%;
  height: 70%;
  background: radial-gradient(ellipse at 50% 0%, rgba(148, 163, 184, 0.22) 0%, transparent 68%);
  pointer-events: none;
}

#pg-exec .exec-hub-xhero__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 4px;
}

#pg-exec .exec-hub-xhero__kicker {
  margin: 0;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.82;
}

#pg-exec .exec-hub-xhero__plan {
  font-size: 10px;
  font-weight: 800;
  padding: 3px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.1);
  letter-spacing: 0.06em;
}

#pg-exec .exec-hub-xhero__brand {
  margin: 0 0 12px;
  font-size: 17px;
  font-weight: 900;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

#pg-exec .exec-hub-xhero__core {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 12px;
}

#pg-exec .exec-hub-xhero__ring-wrap {
  position: relative;
  width: 108px;
  height: 108px;
  flex-shrink: 0;
}

#pg-exec .exec-hub-xhero__ring-svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

#pg-exec .exec-hub-xhero__ring-track {
  fill: none;
  stroke: rgba(255, 255, 255, 0.12);
  stroke-width: 9;
}

#pg-exec .exec-hub-xhero__ring-fill {
  fill: none;
  stroke: #e2e8f0;
  stroke-width: 9;
  stroke-linecap: round;
  stroke-dasharray: 0 326.7;
  transition: stroke-dasharray 0.5s ease;
}

#pg-exec .exec-hub-xhero__score {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

#pg-exec .exec-hub-xhero__score-num {
  font-size: 34px;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

#pg-exec .exec-hub-xhero__score-max {
  font-size: 12px;
  font-weight: 700;
  opacity: 0.75;
}

#pg-exec .exec-hub-xhero__meta {
  flex: 1;
  min-width: 0;
}

#pg-exec .exec-hub-xhero__level {
  display: inline-block;
  font-size: 13px;
  font-weight: 800;
  padding: 5px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.1);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

#pg-exec .exec-hub-xhero__level--diamante {
  background: linear-gradient(135deg, rgba(224, 242, 254, 0.35) 0%, rgba(248, 250, 252, 0.15) 100%);
  color: #e0f2fe;
}
#pg-exec .exec-hub-xhero__level--oro {
  background: linear-gradient(135deg, rgba(254, 243, 199, 0.4) 0%, rgba(255, 251, 235, 0.12) 100%);
  color: #fef3c7;
}
#pg-exec .exec-hub-xhero__level--plata {
  background: linear-gradient(135deg, rgba(241, 245, 249, 0.35) 0%, rgba(255, 255, 255, 0.1) 100%);
  color: #f1f5f9;
}
#pg-exec .exec-hub-xhero__level--bronce {
  background: linear-gradient(135deg, rgba(255, 237, 213, 0.35) 0%, rgba(255, 247, 237, 0.1) 100%);
  color: #ffedd5;
}
#pg-exec .exec-hub-xhero__level--mejora {
  background: rgba(254, 226, 226, 0.2);
  color: #fecaca;
}

#pg-exec .exec-hub-xhero__trend {
  margin: 8px 0 0;
  font-size: 12px;
  font-weight: 700;
  opacity: 0.9;
}

#pg-exec .exec-hub-xhero__trend--up {
  color: #bbf7d0;
}
#pg-exec .exec-hub-xhero__trend--down {
  color: #fecaca;
}

#pg-exec .exec-hub-xhero__story {
  margin-bottom: 12px;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

#pg-exec .exec-hub-xhero__story-lbl {
  margin: 0 0 2px;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  opacity: 0.75;
}

#pg-exec .exec-hub-xhero__story-val {
  margin: 0 0 4px;
  font-size: 15px;
  font-weight: 800;
}

#pg-exec .exec-hub-xhero__benefit {
  margin: 0;
  font-size: 13px;
  font-weight: 700;
  color: #e2e8f0;
}

#pg-exec .exec-hub-xhero__kpis {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  margin-bottom: 12px;
}

@media (min-width: 520px) {
  #pg-exec .exec-hub-xhero__kpis {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

#pg-exec .exec-hub-xhero__kpi {
  padding: 7px 8px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

#pg-exec .exec-hub-xhero__kpi-lbl {
  display: block;
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  opacity: 0.78;
  margin-bottom: 2px;
}

#pg-exec .exec-hub-xhero__kpi-val {
  font-size: 14px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

#pg-exec .exec-hub-xhero__acts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

#pg-exec .exec-hub-xhero__btn {
  height: 40px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 800;
  font-family: inherit;
  cursor: pointer;
  border: 1px solid transparent;
}

#pg-exec .exec-hub-xhero__btn--pri {
  background: linear-gradient(180deg, #f8fafc 0%, #cbd5e1 100%);
  color: #0f172a;
  border-color: #e2e8f0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

#pg-exec .exec-hub-xhero__btn--sec {
  background: rgba(255, 255, 255, 0.08);
  color: #f8fafc;
  border-color: rgba(255, 255, 255, 0.22);
}

/* —— Top 3 insights —— */
#pg-exec .exec-hub-insights-preview {
  margin-bottom: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  background: var(--gris-0, #fff);
  border: var(--manto-serio-panel-borde, 1px solid #cbd5e1);
}

#pg-exec .exec-hub-insights-preview__tit {
  margin: 0 0 8px;
  font-size: 13px;
  font-weight: 900;
  color: var(--texto-fuerte, #0f172a);
}

#pg-exec .exec-hub-insights-preview__list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

#pg-exec .exec-hub-insight-preview {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 8px 10px;
  border-radius: 8px;
  border-left: 3px solid #94a3b8;
  background: var(--gris-50, #f8fafc);
  text-align: left;
  cursor: pointer;
  font-family: inherit;
  width: 100%;
}

#pg-exec .exec-hub-insight-preview--alta,
#pg-exec .exec-hub-insight-preview--high {
  border-left-color: #b91c1c;
  background: #fef2f2;
}
#pg-exec .exec-hub-insight-preview--media,
#pg-exec .exec-hub-insight-preview--medium {
  border-left-color: #d97706;
  background: #fffbeb;
}

#pg-exec .exec-hub-insight-preview__tipo {
  font-size: 9px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--texto-suave, #64748b);
}

#pg-exec .exec-hub-insight-preview__txt {
  font-size: 12px;
  font-weight: 600;
  color: var(--texto-base, #334155);
  line-height: 1.35;
}

/* —— Toolbar compacto —— */
#pg-exec .exec-hub-toolbar--compact {
  margin: 0 0 8px;
}

#pg-exec .exec-hub-toolbar--compact .btn {
  flex: 1 1 0;
  min-height: 40px;
}

#pg-exec .exec-hub-metrics-line {
  font-size: 11px;
  color: var(--texto-suave, #64748b);
  margin: 0 0 8px;
}

/* —— Análisis profundo colapsable —— */
#pg-exec .exec-hub-deep-wrap {
  margin-top: 10px;
}

#pg-exec .exec-hub-deep-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 40px;
  padding: 8px 14px;
  border-radius: 10px;
  border: 1px solid var(--gris-300, #cbd5e1);
  background: var(--gris-100, #f1f5f9);
  color: var(--texto-base, #334155);
  font-size: 13px;
  font-weight: 800;
  font-family: inherit;
  cursor: pointer;
}

#pg-exec .exec-hub-deep-toggle:hover {
  border-color: var(--gris-400, #94a3b8);
}

#pg-exec .exec-hub-deep-panel {
  margin-top: 8px;
}

#pg-exec .exec-hub-deep-wrap--collapsed .exec-hub-deep-panel[hidden] {
  display: none;
}

/* Bandas profundas: ocultas hasta expandir análisis completo */
#pg-exec.exec-ux2-on.exec-hub-deep-collapsed #exec-hub-deep-panel [id$="-band"] {
  display: none !important;
}

/* —— UX-2.3: storytelling Gemelo Digital —— */
#pg-exec .exec-hub-xhero--v23 {
  padding: 18px 16px 14px;
  background: linear-gradient(165deg, #060d18 0%, #0f172a 28%, #1e293b 55%, #0f172a 100%);
  box-shadow:
    0 16px 40px rgba(2, 6, 23, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

#pg-exec .exec-hub-xhero__radial {
  position: absolute;
  inset: auto -30% -50% -30%;
  height: 85%;
  background: radial-gradient(ellipse at 50% 100%, rgba(148, 163, 184, 0.28) 0%, transparent 62%);
  pointer-events: none;
}

#pg-exec .exec-hub-xhero--v23 .exec-hub-xhero__glow {
  inset: -50% -30% auto -30%;
  height: 80%;
  background: radial-gradient(ellipse at 40% 0%, rgba(226, 232, 240, 0.18) 0%, transparent 70%);
}

#pg-exec .exec-hub-xhero__plan--subtle {
  font-size: 9px;
  font-weight: 700;
  padding: 2px 8px;
  opacity: 0.72;
  letter-spacing: 0.04em;
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.06);
}

#pg-exec .exec-hub-xhero__intro {
  margin-bottom: 14px;
}

#pg-exec .exec-hub-xhero--v23 .exec-hub-xhero__brand {
  margin: 0 0 4px;
  font-size: 19px;
  line-height: 1.15;
}

#pg-exec .exec-hub-xhero__tagline {
  margin: 0 0 6px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.02em;
  color: #cbd5e1;
}

#pg-exec .exec-hub-xhero__desc {
  margin: 0 0 10px;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.45;
  color: rgba(248, 250, 252, 0.82);
  max-width: 42em;
}

#pg-exec .exec-hub-xhero__help {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.08);
  color: #e2e8f0;
  font-size: 11px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
}

#pg-exec .exec-hub-xhero__help:hover {
  background: rgba(255, 255, 255, 0.14);
}

#pg-exec .exec-hub-xhero-help-panel {
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(0, 0, 0, 0.28);
}

#pg-exec .exec-hub-xhero-help-panel p {
  margin: 0 0 6px;
  font-size: 12px;
  line-height: 1.45;
  color: rgba(248, 250, 252, 0.9);
}

#pg-exec .exec-hub-xhero-help-panel p:last-child {
  margin-bottom: 0;
}

#pg-exec .exec-hub-xhero-help-panel__lead {
  font-weight: 800;
  color: #f8fafc;
}

#pg-exec .exec-hub-xhero--v23 .exec-hub-xhero__core {
  align-items: stretch;
  gap: 12px;
}

#pg-exec .exec-hub-xhero__score-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex-shrink: 0;
  width: 132px;
  text-align: center;
}

#pg-exec .exec-hub-xhero--v23 .exec-hub-xhero__ring-wrap {
  width: 124px;
  height: 124px;
}

#pg-exec .exec-hub-xhero__ring-halo {
  position: absolute;
  inset: -8px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(248, 250, 252, 0.22) 0%, transparent 68%);
  pointer-events: none;
}

#pg-exec .exec-hub-xhero--v23 .exec-hub-xhero__score-num {
  font-size: 42px;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
}

#pg-exec .exec-hub-xhero--v23 .exec-hub-xhero__score-max {
  font-size: 13px;
}

#pg-exec .exec-hub-xhero__score-col .exec-hub-xhero__level {
  margin-top: 8px;
  font-size: 11px;
  padding: 4px 10px;
}

#pg-exec .exec-hub-xhero__level-hint {
  margin: 6px 0 0;
  font-size: 10px;
  font-weight: 600;
  line-height: 1.35;
  color: rgba(248, 250, 252, 0.72);
  max-width: 128px;
}

#pg-exec .exec-hub-xhero__score-col .exec-hub-xhero__trend {
  margin-top: 6px;
  font-size: 11px;
  font-weight: 800;
}

#pg-exec .exec-hub-xhero__trend-sub {
  margin: 4px 0 0;
  font-size: 10px;
  font-weight: 600;
  opacity: 0.78;
}

#pg-exec .exec-hub-xhero__story--side {
  flex: 1;
  min-width: 0;
  margin-bottom: 0;
  align-self: stretch;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

@media (max-width: 380px) {
  #pg-exec .exec-hub-xhero--v23 .exec-hub-xhero__core {
    flex-direction: column;
    align-items: stretch;
  }
  #pg-exec .exec-hub-xhero__score-col {
    width: 100%;
  }
  #pg-exec .exec-hub-xhero__level-hint {
    max-width: none;
  }
}
