.ipe-grid {
  display: grid;
  grid-template-columns: 1.8fr repeat(3, 1fr);
  background: rgba(0, 0, 0, .16);
  border: 1px solid rgba(255, 255, 255, .045);
  border-radius: 14px;
  overflow: hidden;
}

.ipe {
  position: relative;
  padding: 10px 12px;
  border-right: 1px solid rgba(255, 255, 255, .035);
  border-bottom: 1px solid rgba(255, 255, 255, .03);
  font-size: 14px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  font-variant-numeric: tabular-nums;
  transition: background .12s ease;
}

.ipe:nth-child(4n) {
  border-right: none;
}

.ipe.head {
  background: linear-gradient(180deg, rgba(255, 255, 255, .06), rgba(255, 255, 255, .02));
  color: #d7d7d7;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .09em;
  border-bottom: 1px solid rgba(255, 255, 255, .05);
}

.ipe:not(.head):hover,
.ipe-toggle:hover {
  background: rgba(255, 255, 255, .04);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .06);
}

.ipe.name {
  position: relative;
  font-weight: 600;
  padding-left: 22px;
  padding-right: 36px;
}

.ipe.name::before {
  content: "";
  position: absolute;
  left: 10px;
  top: 14px;
  bottom: 14px;
  width: 2px;
  border-radius: 2px;
  background: rgba(0, 255, 168, .45);
}

.ipe.val {
  font-weight: 800;
}

.ipe-meta {
  font-size: 11px;
  color: var(--muted);
  margin-top: 4px;
  font-weight: 400;
  letter-spacing: .02em;
  text-transform: uppercase;
}

.ipe-toggle {
  cursor: pointer;
}

.ipe-toggle:focus {
  outline: 2px solid rgba(242, 201, 76, .35);
  outline-offset: -2px;
}

.ipe.sub {
  display: none;
}

.ipe-grid[data-open="inflacion"] .ipe.sub[data-parent="inflacion"],
.ipe-grid[data-open="pobreza"] .ipe.sub[data-parent="pobreza"],
.ipe-grid[data-open="icg"] .ipe.sub[data-parent="icg"],
.ipe-grid[data-open="actividad"] .ipe.sub[data-parent="actividad"],
.ipe-grid[data-open="desempleo"] .ipe.sub[data-parent="desempleo"],
.ipe-grid[data-open="reservas"] .ipe.sub[data-parent="reservas"] {
  display: flex;
}

.ipe.sub.name {
  padding-left: 34px;
  padding-right: 36px;
}

.ipe.sub.name::before {
  left: 18px;
  background: rgba(242, 201, 76, .55);
}

.ipe.sub .ipe-meta {
  opacity: .85;
}

.ipe-grid .ipe-row-alt {
  background: rgba(255, 255, 255, .03);
}

.ipe-grid .ipe-row-base,
.ipe-grid .ipe.zebra-base {
  background: transparent;
}

.ipe-grid .ipe.zebra-alt {
  background: rgba(255, 255, 255, .035);
}

.info {
  margin-left: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  font-size: 11px;
  line-height: 1;
  border: 1px solid rgba(255, 255, 255, .25);
  color: rgba(255, 255, 255, .55);
  background: transparent;
  position: relative;
  user-select: none;
  flex: 0 0 auto;
  cursor: help;
  transition: all .15s ease;
}

.info:hover,
.info:focus,
.ipe.name .info:hover,
.ipe.name .info:focus {
  color: rgba(255, 255, 255, .85);
  border-color: rgba(255, 255, 255, .55);
  background: rgba(255, 255, 255, .05);
}

.ipe.name .info {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  margin-left: 0;
}

.info::after {
  content: attr(data-tip);
  position: absolute;
  left: 130%;
  top: 50%;
  transform: translateY(-50%);
  min-width: 240px;
  max-width: 320px;
  padding: 10px 12px;
  border-radius: 10px;
  background: #111;
  color: #fff;
  font-size: 12px;
  line-height: 1.4;
  box-shadow: 0 10px 30px rgba(0, 0, 0, .6);
  opacity: 0;
  pointer-events: none;
  transition: opacity .15s ease;
  z-index: 9999;
  white-space: normal;
}

.info:hover::after,
.info:focus::after {
  opacity: 1;
}

#globalTooltip {
  position: fixed;
  left: 0;
  top: 0;
  transform: translate(-9999px, -9999px);
  min-width: 240px;
  max-width: 340px;
  padding: 10px 12px;
  border-radius: 10px;
  background: #111;
  color: #fff;
  font-size: 12px;
  line-height: 1.4;
  box-shadow: 0 10px 30px rgba(0, 0, 0, .6);
  z-index: 99999;
  opacity: 0;
  transition: opacity .10s ease;
  pointer-events: none;
}

body.js-tooltips #globalTooltip {
  opacity: 1;
}

body.js-tooltips .info::after {
  display: none;
}

.ipe-toggle .expander {
  position: absolute;
  right: 34px;
  top: 50%;
  transform: translateY(-50%);
  color: rgba(245, 196, 0, .65);
  font-size: 14px;
  line-height: 1;
  transition: transform .12s ease, color .12s ease;
  pointer-events: none;
}

.ipe-toggle:hover .expander {
  color: rgba(245, 196, 0, .9);
}

.ipe-toggle[aria-expanded="true"] .expander {
  transform: translateY(-50%) rotate(90deg);
  color: var(--brand-yellow);
}

@keyframes dhPulse {
  0%, 100% { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0); }
  50% { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .10); }
}

.ipe-toggle.dh-hint {
  animation: dhPulse 1.4s ease-in-out 2;
}

.indicators-card {
  height: 100% !important;
  min-height: 0 !important;
}

.indicators-card .content {
  display: flex;
  flex-direction: column;
  min-height: 0 !important;
}

.indicators-card .ipe-grid {
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
}

.indicators-card .ipe-ad-slot {
  flex: 0 0 auto;
  margin-top: 10px;
}
