.overview-orbs {
  grid-template-columns: repeat(4, minmax(105px, 140px));
  justify-content: center;
  gap: 16px;
}
.overview-orb {
  --overview-color: var(--ok);
  aspect-ratio: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 10px;
  text-align: center;
  border: 4px solid var(--overview-color);
  border-radius: 50%;
  box-shadow: 0 0 20px color-mix(in srgb, var(--overview-color) 25%, transparent);
}
.overview-orb b {
  color: var(--overview-color);
  font-size: 27px;
}
.overview-green { --overview-color: var(--ok); }
.overview-orange { --overview-color: var(--warn); }
.overview-red { --overview-color: var(--bad); }

.store-grid {
  grid-template-columns: repeat(auto-fit, minmax(370px, 1fr));
  gap: 20px;
}
.store {
  --status-color: var(--ok);
  --status-glow: rgba(34, 197, 94, .25);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  min-width: 0;
  padding: 18px;
  border-color: color-mix(in srgb, var(--status-color) 45%, var(--line));
  box-shadow: 0 12px 32px rgba(0, 0, 0, .22);
}
.store-orange {
  --status-color: var(--warn);
  --status-glow: rgba(245, 158, 11, .28);
}
.store-red {
  --status-color: var(--bad);
  --status-glow: rgba(239, 68, 68, .3);
}
.store h2 {
  margin-bottom: 12px;
  overflow: hidden;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 17px;
}
.status-orb {
  width: min(230px, 78vw);
  aspect-ratio: 1;
  align-self: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  border: 7px solid var(--status-color);
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 42%, color-mix(in srgb, var(--status-color) 10%, transparent), transparent 55%),
    #070b13;
  box-shadow:
    0 0 0 4px rgba(255, 255, 255, .025),
    0 0 28px var(--status-glow),
    inset 0 0 28px rgba(0, 0, 0, .45);
}
.orb-wifi {
  width: 64px;
  height: 64px;
  margin-bottom: 4px;
  fill: none;
  stroke: #fff;
  stroke-width: 2.6;
  stroke-linecap: round;
}
.orb-wifi circle { fill: #fff; stroke: none; }
.orb-count {
  font-size: 44px;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.orb-label {
  color: var(--status-color);
  font-size: 21px;
  font-weight: 800;
}
.status-orb small { color: var(--muted); font-size: 12px; }
.metric-orbs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  justify-items: center;
  gap: 10px;
  margin-top: 20px;
}
.metric-orb {
  --metric-color: #64748b;
  width: 100%;
  max-width: 112px;
  aspect-ratio: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 7px;
  text-align: center;
  background:
    radial-gradient(circle, color-mix(in srgb, var(--metric-color) 10%, transparent), transparent 63%),
    #090e18;
  border: 3px solid var(--metric-color);
  border-radius: 50%;
  box-shadow: 0 0 14px color-mix(in srgb, var(--metric-color) 23%, transparent);
  overflow: hidden;
}
.metric-green { --metric-color: var(--ok); }
.metric-orange { --metric-color: var(--warn); }
.metric-red { --metric-color: var(--bad); }
.metric-icon {
  height: 18px;
  color: #fff;
  font-size: 17px;
  line-height: 1;
}
.metric-orb b {
  max-width: 100%;
  color: var(--metric-color);
  font-size: 15px;
  line-height: 1.1;
  overflow-wrap: anywhere;
}
.metric-orb > span:last-child {
  color: var(--muted);
  font-size: 10px;
  line-height: 1.15;
}
.store-chart {
  margin-top: 18px;
  padding: 11px;
  background: var(--panel2);
  border: 1px solid color-mix(in srgb, var(--status-color) 35%, var(--line));
  border-radius: 12px;
}
.store-chart h3 {
  margin: 0 0 8px;
  color: var(--muted);
  text-align: center;
  font-size: 12px;
}
.ridgechart { position: relative; }
.ridgechart svg {
  display: block;
  width: 100%;
  height: 84px;
  overflow: visible;
}
.ridge-band { fill-opacity: .42; }
.ridge-max {
  position: absolute;
  inset-inline-end: 2px;
  top: -5px;
  color: var(--muted);
  font-size: 10px;
}
.ridge-axis {
  display: flex;
  justify-content: space-between;
  direction: ltr;
  margin-top: 3px;
  color: var(--muted);
  font-size: 9px;
}
.ridge-legend {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px 10px;
  margin-top: 7px;
  font-size: 10px;
}
.ridge-legend span {
  display: flex;
  align-items: center;
  gap: 4px;
  color: var(--muted);
}
.ridge-legend span::before {
  content: '';
  width: 9px;
  height: 9px;
  border-radius: 3px;
  background: var(--series-color);
}

.event {
  display: grid;
  grid-template-columns: 150px 85px 1fr;
  gap: 10px;
  padding: 9px;
  border-bottom: 1px solid var(--line);
}
.event.critical { border-inline-start: 3px solid var(--bad); }
.event.warning { border-inline-start: 3px solid var(--warn); }
.hist {
  height: 70px;
  display: flex;
  align-items: flex-end;
  gap: 2px;
  direction: ltr;
}
.hcol {
  height: 100%;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
}
.hbar { width: 100%; max-width: 15px; background: #38bdf8; }
.hval { font-size: 9px; color: #7dd3fc; }
.watch-group { border-bottom: 1px solid var(--line); padding: 12px 0; }
.watch-head { display: flex; justify-content: space-between; gap: 10px; }
.watch-body { margin-top: 10px; }
.add-form { background: var(--panel2); padding: 12px; border-radius: 8px; }
.add-form textarea { width: 100%; min-height: 60px; }

@media (max-width: 850px) {
  .event { grid-template-columns: 1fr; }
  .overview-orbs { grid-template-columns: repeat(2, minmax(105px, 135px)); }
  .store-grid { grid-template-columns: 1fr; }
  .store { padding: 14px; }
  .status-orb { width: min(220px, 70vw); }
}

@media (max-width: 560px) {
  .store-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
  .status-orb { width: min(230px, 72vw); }
  .orb-count { font-size: 40px; }
  .orb-label { font-size: 19px; }
  .metric-orbs { gap: 7px; }
  .metric-orb { max-width: 104px; padding: 5px; }
  .metric-orb b { font-size: 14px; }
}
