/* =========================
   EliteKPI – KPI Summary (Traffic Light)
   Clean + No Duplicate Rules
   ========================= */

:root{
  --ekpi-bg: rgba(10,16,30,.92);
  --ekpi-border: rgba(255,255,255,.08);
  --ekpi-soft: rgba(255,255,255,.06);

  --ekpi-green: var(--green, #22c55e);
  --ekpi-yellow: var(--yellow, #f59e0b);
  --ekpi-red: var(--red, #ef4444);
}

/* Layout ringkasan */
.ekpi-summary{
  grid-column: span 12;
}

.ekpi-summary__body{
  margin-top: 14px;
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 18px;
  align-items: center;
}

/* Donut */
.ekpi-donutWrap{
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:10px;
}

.ekpi-donut{
  width:220px;
  height:220px;
  border-radius:999px;
  position:relative;

  /* Track + depth: premium (tetap bagus walau 100% satu warna) */
  box-shadow:
    inset 0 0 0 10px rgba(255,255,255,.04),
    0 16px 40px rgba(0,0,0,.35);
}

.ekpi-donut::before{
  content:"";
  position:absolute;
  inset:0;
  border-radius:999px;
  box-shadow: inset 0 0 0 16px rgba(255,255,255,.05);
  pointer-events:none;
}

.ekpi-donutSvg{
  width: 100%;
  height: 100%;
  display: block;
  /* start from top */
  transform: rotate(-90deg);
  overflow: visible;
}

.ekpi-donutTrack{
  fill: none;
  stroke: rgba(255,255,255,.10);
}

.ekpi-donutSeg{
  fill: none;
  stroke-linecap: round;
}

.ekpi-donutGreen{ stroke: var(--ekpi-green); }
.ekpi-donutYellow{ stroke: var(--ekpi-yellow); }
.ekpi-donutRed{ stroke: var(--ekpi-red); }

/* Center circle should NOT rotate with the donut visually */
.ekpi-donutCenter{
  fill: var(--ekpi-bg);
  stroke: rgba(255,255,255,.10);
  stroke-width: 1;
  transform: rotate(90deg);      /* cancel parent rotate(-90deg) */
  transform-origin: 50% 50%;
}

/* Text should be readable (cancel rotate) */
.ekpi-donutValue,
.ekpi-donutSub{
  transform: rotate(90deg);
  transform-origin: 50% 50%;
  fill: rgba(255,255,255,.92);
}

.ekpi-donutValue{
  font-size: 26px;
  font-weight: 800;
  letter-spacing: .2px;
}

.ekpi-donutSub{
  font-size: 11px;
  opacity: .75;
}

.ekpi-donutLabel{
  font-size: 13px;
  opacity: .85;
}

/* Bars */
.ekpi-bars{
  width:100%;
  display:flex;
  flex-direction:column;
  gap:10px;
}

.ekpi-barRow{
  display:grid;
  grid-template-columns: 70px 1fr 52px;
  gap:10px;
  align-items:center;
  padding:6px 0;
}

.ekpi-barLabel{
  font-size:13px;
  opacity:.90;
}

.ekpi-bar{
  height:10px;
  border-radius:999px;
  overflow:hidden;
}

.ekpi-barSvg{
  width:100%;
  height:10px;
  display:block;
}

.ekpi-barTrack{
  fill: rgba(255,255,255,.06);
  stroke: rgba(255,255,255,.10);
  stroke-width: 1;
}

.ekpi-barFill--g{ fill: var(--ekpi-green); }
.ekpi-barFill--y{ fill: var(--ekpi-yellow); }
.ekpi-barFill--r{ fill: var(--ekpi-red); }

.ekpi-barPct{
  font-size:13px;
  text-align:right;
  opacity:.85;
}

.ekpi-barsFoot{
  margin-top:6px;
  font-size:13px;
  opacity:.75;
}

/* Responsive */
@media (max-width: 860px){
  .ekpi-summary__body{
    grid-template-columns: 1fr;
  }
  .ekpi-summary__pills{
    flex-wrap: wrap;
    justify-content: flex-end;
  }
  .ekpi-donut{
    width:200px;
    height:200px;
  }
  .ekpi-barRow{
    grid-template-columns: 62px 1fr 48px;
  }
}

.ekpi-summary { outline: 4px solid #00ff66 !important; }