/* RANKHOUSE Suite v10.6.0 – Operations & Reliability Center */
body.rankhouse-dashboard-v10 .rh-operations-page {
  --ops-good: 62, 211, 137;
  --ops-warn: 247, 181, 54;
  --ops-bad: 255, 78, 102;
}

body.rankhouse-dashboard-v10 .rh-operations-header {
  border-color: rgba(var(--rh-accent-rgb), .18);
  background:
    radial-gradient(circle at 75% 0%, rgba(var(--rh-accent-rgb), .12), transparent 24rem),
    linear-gradient(145deg, rgba(19,19,27,.96), rgba(10,10,15,.96));
}

.rh-operations-overview {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
  margin: 0 0 18px;
}

.rh-operation-kpi {
  position: relative;
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 17px;
  padding: 16px;
  background: linear-gradient(145deg, rgba(21,21,30,.94), rgba(11,11,16,.94));
  box-shadow: inset 0 1px rgba(255,255,255,.035), 0 18px 34px rgba(0,0,0,.16);
}

.rh-operation-kpi::before {
  content: '';
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
  background: rgba(255,255,255,.18);
}

.rh-operation-kpi::after {
  content: '';
  position: absolute;
  right: -32px;
  bottom: -42px;
  width: 110px;
  height: 110px;
  border-radius: 50%;
  background: rgba(255,255,255,.025);
  filter: blur(2px);
}

.rh-operation-kpi.is-healthy::before { background: rgb(var(--ops-good)); box-shadow: 0 0 18px rgba(var(--ops-good), .45); }
.rh-operation-kpi.is-warning::before { background: rgb(var(--ops-warn)); box-shadow: 0 0 18px rgba(var(--ops-warn), .45); }
.rh-operation-kpi.is-error::before { background: rgb(var(--ops-bad)); box-shadow: 0 0 18px rgba(var(--ops-bad), .45); }
.rh-operation-kpi > span { display: block; color: #8f8fa0; font-size: 9px; font-weight: 900; letter-spacing: .13em; text-transform: uppercase; }
.rh-operation-kpi > strong { display: block; margin: 8px 0 5px; color: #fff; font-size: 18px; line-height: 1.1; }
.rh-operation-kpi > small { display: block; color: #777787; font-size: 9px; line-height: 1.45; }

.rh-operations-primary-grid { align-items: stretch; }
.rh-operations-primary-grid > .panel { height: 100%; }

.rh-operation-actions { display: grid; gap: 10px; }
.rh-operation-actions > form,
.rh-operation-action-link {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  min-height: 70px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 14px;
  padding: 12px 14px;
  background: rgba(255,255,255,.018);
}
.rh-operation-action-link { color: inherit; text-decoration: none; transition: border-color .18s ease, background .18s ease, transform .18s ease; }
.rh-operation-action-link:hover { border-color: rgba(var(--rh-accent-rgb), .24); background: rgba(var(--rh-accent-rgb), .07); transform: translateX(2px); }
.rh-operation-actions strong { display: block; color: #eeeef4; font-size: 11px; }
.rh-operation-actions small { display: block; margin-top: 4px; color: #818190; font-size: 9px; line-height: 1.45; }
.rh-operation-action-link > span { color: var(--rh-accent-bright); font-size: 24px; }

.table-subline { display: block; margin-top: 3px; color: #747483; font-size: 8px; }
tr.is-problem-row td { background: rgba(var(--ops-bad), .025); }

.rh-error-event-list { display: grid; gap: 11px; }
.rh-error-event {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 15px;
  padding: 14px 15px;
  background: linear-gradient(145deg, rgba(20,20,28,.88), rgba(11,11,16,.88));
}
.rh-error-event::before { content: ''; position: absolute; inset: 0 auto 0 0; width: 3px; background: rgba(var(--ops-bad), .85); }
.rh-error-event.is-warning::before { background: rgba(var(--ops-warn), .9); }
.rh-error-event.is-info::before { background: rgba(var(--rh-accent-rgb), .9); }
.rh-error-event-head { display: grid; grid-template-columns: auto minmax(0,1fr) auto auto; align-items: center; gap: 10px; }
.rh-error-event-head strong { color: #f5f5f8; font-size: 11px; }
.rh-error-event-head > span:not(.rh-error-severity), .rh-error-event-head time { color: #858594; font-size: 8px; }
.rh-error-severity { border: 1px solid rgba(var(--ops-bad), .28); border-radius: 999px; padding: 4px 7px; background: rgba(var(--ops-bad), .09); color: rgb(var(--ops-bad)); font-size: 7px; font-weight: 900; letter-spacing: .11em; text-transform: uppercase; }
.rh-error-event p { margin: 11px 0; color: #c8c8d1; font-size: 10px; line-height: 1.55; white-space: pre-wrap; word-break: break-word; }
.rh-error-event-meta { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 10px; }
.rh-error-event-meta span { border: 1px solid rgba(255,255,255,.06); border-radius: 999px; padding: 4px 7px; background: rgba(255,255,255,.02); color: #818190; font-size: 8px; }

.rh-module-runtime-list { display: grid; gap: 8px; }
.rh-module-runtime-entry { display: grid; grid-template-columns: auto minmax(0,1fr) auto auto; align-items: center; gap: 12px; border: 1px solid rgba(255,255,255,.065); border-radius: 13px; padding: 11px 13px; color: inherit; text-decoration: none; background: rgba(255,255,255,.018); }
.rh-module-runtime-entry:hover { border-color: rgba(var(--rh-accent-rgb), .22); background: rgba(var(--rh-accent-rgb), .06); }
.rh-module-runtime-entry strong { display: block; color: #eeeef3; font-size: 10px; }
.rh-module-runtime-entry small { display: block; margin-top: 3px; color: #7b7b8a; font-size: 8px; }
.rh-module-runtime-entry > span:nth-last-child(2) { color: #858594; font-size: 8px; }
.rh-module-runtime-entry > span:last-child { color: var(--rh-accent-bright); font-size: 18px; }

@media (max-width: 1450px) {
  .rh-operations-overview { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 840px) {
  .rh-operations-overview { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rh-error-event-head { grid-template-columns: auto minmax(0,1fr); }
  .rh-error-event-head time { grid-column: 2; }
}
@media (max-width: 520px) {
  .rh-operations-overview { grid-template-columns: 1fr; }
  .rh-operation-actions > form, .rh-operation-action-link { grid-template-columns: 1fr; }
}
