/* Global CSS Reset & Fonts */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Microsoft YaHei", sans-serif;
  background-color: #0b0f19;
  color: #e2e8f0;
  line-height: 1.5;
  overflow: hidden;
}

/* Scrollbars styling */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: rgba(15, 23, 42, 0.3);
}
::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, 0.3);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(148, 163, 184, 0.5);
}

/* Large Font Readability Standards (大字号办公可读标准) */
h1, .hero-title {
  font-size: 28px;
  line-height: 1.3;
  font-weight: 700;
  color: #ffffff;
}

h2, .panel-title-text {
  font-size: 20px;
  line-height: 1.4;
  font-weight: 600;
  color: #f1f5f9;
}

h3, .subpanel-title {
  font-size: 18px;
  line-height: 1.4;
  font-weight: 600;
  color: #f1f5f9;
}

p, span, div, label, input, select, textarea, button, td, th {
  font-size: 16px;
  line-height: 1.5;
}

/* Small labels, secondary notes, legends, metrics units */
.small-label, .field-desc, .chart-tick, .status-tag, .legend-text, .metric-unit {
  font-size: 14px;
  line-height: 1.4;
  color: #94a3b8;
}

.num-badge {
  font-size: 12px;
  line-height: 1;
}

/* Global utility classes */
.scrollable {
  overflow-y: auto;
  scrollbar-gutter: stable;
}

.primary-button {
  background-color: #0ea5e9;
  color: #ffffff;
  border: none;
  padding: 10px 20px;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.2s ease;
  min-height: 44px;
}
.primary-button:hover {
  background-color: #0284c7;
  transform: translateY(-1px);
}
.primary-button:active {
  transform: translateY(0);
}

.ghost-button {
  background-color: transparent;
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.4);
  padding: 8px 16px;
  border-radius: 6px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  min-height: 40px;
}
.ghost-button:hover {
  background-color: rgba(56, 189, 248, 0.1);
  border-color: #38bdf8;
}

/* LOGIN PAGE STYLING */
.login-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background: radial-gradient(circle at 70% 30%, #1e1b4b 0%, #090514 100%);
  overflow: auto;
}

.login-shell {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  width: 1100px;
  max-width: 95vw;
  height: 600px;
  max-height: 90vh;
  background: rgba(15, 23, 42, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(12px);
}

@media (max-width: 900px) {
  .login-shell {
    grid-template-columns: 1fr;
    height: auto;
    max-height: none;
  }
  .login-visual {
    display: none;
  }
}

.login-visual {
  position: relative;
  background: linear-gradient(135deg, #1e3a8a 0%, #0f172a 100%);
  padding: 48px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-right: 1px solid rgba(255, 255, 255, 0.05);
  overflow: hidden;
}

.login-visual::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at 30% 70%, rgba(14, 165, 233, 0.15) 0%, transparent 60%);
  pointer-events: none;
}

.login-visual .eyebrow {
  color: #38bdf8;
  font-weight: 600;
  letter-spacing: 0.1em;
}

.login-visual h1 {
  font-size: 32px;
  margin-top: 16px;
  margin-bottom: 24px;
}

.login-visual p {
  color: #94a3b8;
  max-width: 420px;
}

.signal-board {
  display: flex;
  gap: 12px;
  margin-top: auto;
  flex-wrap: wrap;
}

.signal-board span {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 14px;
  color: #cbd5e1;
}

.visual-grid-bg {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
                    linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
  background-size: 30px 30px;
  pointer-events: none;
}

.login-card {
  padding: 48px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: rgba(15, 23, 42, 0.4);
}

.login-heading {
  margin-bottom: 32px;
}

.login-heading span {
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-size: 14px;
}

.login-heading h2 {
  font-size: 24px;
  color: #ffffff;
  margin-top: 4px;
}

#login-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.field-label {
  font-weight: 500;
  color: #cbd5e1;
}

#login-form input {
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #ffffff;
  padding: 12px 16px;
  border-radius: 8px;
  outline: none;
  transition: all 0.2s ease;
  min-height: 48px;
}

#login-form input:focus {
  border-color: #38bdf8;
  box-shadow: 0 0 0 2px rgba(56, 189, 248, 0.2);
}

.captcha-row {
  display: grid;
  grid-template-columns: 1fr 120px;
  gap: 12px;
}

.captcha-button {
  background: none;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  transition: border-color 0.2s;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #f8fafc;
}
.captcha-button img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.captcha-button:hover {
  border-color: #38bdf8;
}

.form-error {
  color: #f43f5e;
  background: rgba(244, 63, 94, 0.1);
  border: 1px solid rgba(244, 63, 94, 0.2);
  padding: 10px 14px;
  border-radius: 6px;
  font-size: 14px;
}

.submit-btn {
  width: 100%;
  min-height: 48px;
  margin-top: 10px;
}


/* WORKSPACE PAGE STYLING */
.workspace-page {
  display: flex;
  flex-direction: column;
  height: 100vh;
  background-color: #070a13;
  position: relative;
  overflow: hidden;
}

/* Watermark styles */
.watermark-container {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
  z-index: 9999;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(4, 1fr);
  opacity: 0.035;
  user-select: none;
}

.watermark-text {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: bold;
  color: #ffffff;
  transform: rotate(-30deg);
  white-space: nowrap;
}

/* Top Command Banner */
.top-command-banner {
  height: 72px;
  background-color: #0f172a;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  flex-shrink: 0;
  z-index: 10;
}

.banner-brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.brand-badge {
  background: linear-gradient(135deg, #0ea5e9 0%, #2563eb 100%);
  color: #ffffff;
  font-weight: 800;
  font-size: 18px;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.brand-text h2 {
  font-size: 20px;
  color: #ffffff;
}

.brand-text .subtitle {
  font-size: 12px;
  color: #64748b;
  margin-top: 2px;
}

.banner-status-hub {
  display: flex;
  align-items: center;
  gap: 24px;
  background: rgba(15, 23, 42, 0.6);
  padding: 10px 20px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.status-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
}

.status-item .label {
  color: #94a3b8;
}

.status-item strong {
  color: #38bdf8;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}
.pulse-green {
  background-color: #10b981;
  box-shadow: 0 0 8px #10b981;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
  70% { transform: scale(1); box-shadow: 0 0 0 6px rgba(16, 185, 129, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.banner-user {
  display: flex;
  align-items: center;
  gap: 12px;
}

.user-avatar {
  font-size: 20px;
  background: rgba(255, 255, 255, 0.08);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.user-info {
  display: flex;
  flex-direction: column;
}

.user-info strong {
  font-size: 14px;
  color: #f1f5f9;
}

.user-info span {
  font-size: 12px;
  color: #94a3b8;
}

.logout-btn {
  background: none;
  border: 1px solid rgba(244, 63, 94, 0.4);
  color: #fb7185;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.logout-btn:hover {
  background: rgba(244, 63, 94, 0.1);
  border-color: #fb7185;
}

/* Global Toast Alert */
.toast-alert {
  position: absolute;
  top: 84px;
  left: 50%;
  transform: translateX(-50%);
  background-color: #0f172a;
  border: 1px solid #0ea5e9;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.5), 0 0 12px rgba(14, 165, 233, 0.2);
  color: #ffffff;
  padding: 12px 24px;
  border-radius: 8px;
  z-index: 1000;
  animation: slideDown 0.3s ease-out;
  font-weight: 500;
}

@keyframes slideDown {
  from { top: 60px; opacity: 0; }
  to { top: 84px; opacity: 1; }
}

.action-feedback-overlay {
  position: fixed;
  inset: 0;
  z-index: 1300;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(2, 8, 23, 0.62);
  backdrop-filter: blur(6px);
}

.action-feedback-card {
  width: min(620px, calc(100vw - 32px));
  display: grid;
  gap: 16px;
  padding: 24px;
  border: 1px solid rgba(56, 189, 248, 0.35);
  border-radius: 14px;
  background: linear-gradient(145deg, rgba(8, 15, 31, 0.98), rgba(17, 24, 39, 0.98));
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.45);
}

.action-feedback-card header,
.action-feedback-card footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.action-feedback-kicker {
  display: block;
  color: #38bdf8;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.action-feedback-card h2 {
  margin: 6px 0 0;
  color: #f8fafc;
  font-size: 22px;
  line-height: 1.3;
}

.action-feedback-message {
  margin: 0;
  color: #cbd5e1;
  font-size: 16px;
  line-height: 1.75;
}

.action-feedback-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.action-feedback-grid article {
  min-height: 80px;
  display: grid;
  gap: 8px;
  padding: 12px 14px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.76);
}

.action-feedback-grid span {
  color: #94a3b8;
  font-size: 14px;
}

.action-feedback-grid strong {
  color: #f8fafc;
  font-size: 16px;
  line-height: 1.5;
}

.action-feedback-close {
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.72);
  color: #e2e8f0;
  font-size: 14px;
  cursor: pointer;
}

.action-feedback-confirm {
  min-height: 42px;
  min-width: 96px;
}


/* Split-Screen Workstation Layout */
.split-workstation {
  display: flex;
  flex: 1;
  overflow: hidden;
  height: calc(100vh - 72px - 90px); /* Subtract top bar and bottom dock spacing */
}

.pane {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: width 0.25s ease, flex 0.25s ease;
  background-color: #0b0f19;
}

.explorer-pane {
  width: 420px; /* Default left pane width */
  flex-shrink: 0;
  border-right: 1px solid rgba(255, 255, 255, 0.05);
}

.details-pane {
  flex: 1;
  background-color: #090c15;
}

/* Pane Header & Inner Layout */
.pane-header {
  min-height: 72px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 10px 16px;
  padding: 12px 20px 10px;
  background-color: rgba(15, 23, 42, 0.4);
  flex-shrink: 0;
}

/* 场景模板分发 */
.distributors-spec-action-btn {
  min-height: 44px;
  padding: 0 16px;
  font-size: 16px;
  line-height: 1.35;
}

.distributors-spec-filter-row {
  display: grid;
  grid-template-columns: minmax(140px, 0.8fr) minmax(140px, 0.8fr) minmax(220px, 1.4fr);
  gap: 12px;
  align-items: end;
}

.distributors-spec-filter,
.distributors-spec-console-grid label,
.distributors-spec-parameter-list label,
.distributors-spec-rate-grid label {
  display: grid;
  gap: 8px;
  color: #cbd5e1;
  font-size: 14px;
}

.distributors-spec-filter span,
.distributors-spec-console-grid span,
.distributors-spec-parameter-list span,
.distributors-spec-rate-grid span {
  font-size: 14px;
  color: #94a3b8;
}

.distributors-spec-filter select,
.distributors-spec-filter input,
.distributors-spec-console-grid input,
.distributors-spec-parameter-list input,
.distributors-spec-rate-grid input {
  width: 100%;
  min-height: 44px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.92);
  color: #f8fafc;
  font-size: 16px;
  line-height: 1.45;
  padding: 10px 12px;
  outline: none;
}

.distributors-spec-filter input:focus,
.distributors-spec-filter select:focus,
.distributors-spec-console-grid input:focus,
.distributors-spec-parameter-list input:focus,
.distributors-spec-rate-grid input:focus {
  border-color: rgba(14, 165, 233, 0.72);
  box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.14);
}

.distributors-spec-template-list {
  display: grid;
  gap: 12px;
  padding-right: 4px;
}

.distributors-spec-template {
  width: 100%;
  min-height: 128px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(14, 165, 233, 0.12), transparent 38%),
    rgba(17, 24, 39, 0.9);
  color: #e5e7eb;
  display: grid;
  gap: 8px;
  text-align: left;
  cursor: pointer;
}

.distributors-spec-template.active {
  border-color: rgba(14, 165, 233, 0.72);
  box-shadow: 0 0 0 1px rgba(14, 165, 233, 0.18), 0 14px 32px rgba(14, 165, 233, 0.12);
}

.distributors-spec-template strong {
  font-size: 18px;
  line-height: 1.35;
  color: #f8fafc;
}

.distributors-spec-template em,
.distributors-spec-template small {
  font-style: normal;
  font-size: 14px;
  line-height: 1.45;
  color: #94a3b8;
}

.distributors-spec-tag,
.distributors-spec-pill {
  width: fit-content;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  color: #7dd3fc;
  background: rgba(14, 165, 233, 0.14);
  border: 1px solid rgba(14, 165, 233, 0.22);
  font-size: 12px;
  line-height: 1.2;
}

.distributors-spec-workbench {
  display: grid;
  grid-template-columns: minmax(360px, 1.15fr) minmax(320px, 0.85fr);
  gap: 14px;
  align-items: start;
}

.distributors-spec-summary {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.distributors-spec-summary article {
  min-height: 94px;
  padding: 14px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  background: #111827;
  display: grid;
  align-content: center;
  gap: 8px;
}

.distributors-spec-summary span {
  color: #94a3b8;
  font-size: 14px;
}

.distributors-spec-summary strong {
  color: #e0f2fe;
  font-size: 28px;
  line-height: 1.1;
}

.distributors-spec-console,
.distributors-spec-rate-card,
.distributors-spec-monitor,
.distributors-spec-records,
.distributors-spec-call-log {
  padding: 16px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  background: #111827;
}

.distributors-spec-console {
  grid-row: span 2;
}

.distributors-spec-section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 14px;
}

.distributors-spec-section-head strong {
  color: #f8fafc;
  font-size: 20px;
  line-height: 1.3;
}

.distributors-spec-section-head p {
  margin-top: 4px;
  color: #94a3b8;
  font-size: 14px;
  line-height: 1.45;
}

.distributors-spec-console-grid,
.distributors-spec-rate-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.distributors-spec-parameter-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.distributors-spec-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.distributors-spec-monitor-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
}

.distributors-spec-monitor-grid article {
  min-height: 112px;
  padding: 10px;
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.05);
  display: grid;
  align-content: space-between;
  gap: 8px;
}

.distributors-spec-monitor-grid span,
.distributors-spec-monitor-grid small {
  color: #94a3b8;
  font-size: 12px;
  line-height: 1.35;
}

.distributors-spec-monitor-grid strong {
  color: #10b981;
  font-size: 24px;
  line-height: 1.1;
}

.distributors-spec-record-list {
  display: grid;
  gap: 10px;
  max-height: 300px;
  overflow-y: auto;
  scrollbar-gutter: stable;
}

.distributors-spec-record {
  min-height: 82px;
  padding: 12px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(15, 23, 42, 0.78);
  color: #e2e8f0;
  display: grid;
  gap: 6px;
  text-align: left;
  cursor: pointer;
}

.distributors-spec-record.active {
  border-color: rgba(16, 185, 129, 0.68);
  box-shadow: 0 0 0 1px rgba(16, 185, 129, 0.16);
}

.distributors-spec-record strong {
  font-size: 16px;
  line-height: 1.35;
}

.distributors-spec-record span,
.distributors-spec-record small {
  color: #94a3b8;
  font-size: 14px;
  line-height: 1.35;
}

.distributors-spec-call-log {
  grid-column: 1 / -1;
}

.distributors-spec-log-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(220px, 1fr));
  gap: 10px;
  max-height: 260px;
  overflow: auto;
  scrollbar-gutter: stable;
}

.distributors-spec-log-list article {
  min-height: 120px;
  padding: 12px;
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.05);
  display: grid;
  gap: 6px;
}

.distributors-spec-log-list time,
.distributors-spec-log-list small {
  color: #94a3b8;
  font-size: 12px;
  line-height: 1.35;
}

.distributors-spec-log-list strong {
  color: #f8fafc;
  font-size: 16px;
  line-height: 1.35;
}

.distributors-spec-log-list p {
  color: #cbd5e1;
  font-size: 14px;
  line-height: 1.45;
}

@media (max-width: 1380px) {
  .distributors-spec-workbench {
    grid-template-columns: 1fr;
  }

  .distributors-spec-console {
    grid-row: auto;
  }

  .distributors-spec-log-list {
    grid-template-columns: repeat(2, minmax(220px, 1fr));
  }
}

@media (max-width: 980px) {
  .distributors-spec-filter-row,
  .distributors-spec-summary,
  .distributors-spec-console-grid,
  .distributors-spec-rate-grid,
  .distributors-spec-parameter-list,
  .distributors-spec-monitor-grid,
  .distributors-spec-log-list {
    grid-template-columns: 1fr;
  }
}

.pane-header h3 {
  color: #ffffff;
  min-width: 0;
  font-size: 22px;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.explorer-pane .pane-header {
  grid-template-columns: minmax(0, 1fr);
  align-items: start;
}

.explorer-pane .pane-header h3 {
  white-space: normal;
  overflow: hidden;
  text-overflow: clip;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  line-height: 1.25;
}

.explorer-pane .pane-actions {
  justify-content: flex-start;
}

.pane-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
  min-width: 0;
  max-width: 100%;
}

.pane-actions > .primary-button,
.pane-actions > .ghost-button {
  flex: 0 0 auto;
  white-space: nowrap;
}

.pane-filters {
  padding: 12px 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  background-color: rgba(15, 23, 42, 0.2);
  flex-shrink: 0;
}

.pane-content-scroll {
  flex: 1;
  min-height: 0;
  padding: 20px;
}

.explorer-pane .distributors-spec-filter-row {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.explorer-pane .distributors-spec-filter-row > :last-child {
  grid-column: 1 / -1;
}

.explorer-pane .archives-spec-filter-row {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.explorer-pane .archives-spec-filter-row > :first-child {
  grid-column: 1 / -1;
}

.explorer-pane .archives-spec-filter-btn {
  width: 100%;
}

.explorer-pane .archives-spec-summary-grid,
.explorer-pane .report-preview-spec-summary-grid,
.explorer-pane .task-spec-summary-grid,
.explorer-pane .appr-spec-summary-grid,
.explorer-pane .anm-spec-summary-grid,
.explorer-pane .anomaly-stats-spec-summary-grid,
.explorer-pane .anomaly-stats-spec-overview-grid,
.explorer-pane .trules-spec-summary-grid,
.explorer-pane .scene-spec-archive-metrics {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.explorer-pane .archives-spec-cabinet-grid {
  grid-template-columns: 1fr;
}

/* Interactive Splitter Bar */
.pane-splitter {
  width: 16px;
  background-color: #0b0f19;
  position: relative;
  cursor: col-resize;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-shrink: 0;
}

.splitter-line {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 2px;
  background-color: rgba(255, 255, 255, 0.05);
  pointer-events: none;
}

.pane-splitter:hover .splitter-line {
  background-color: #0ea5e9;
}

.splitter-toggle-btn {
  width: 20px;
  height: 20px;
  background-color: #1e293b;
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #94a3b8;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 5;
  transition: all 0.2s;
  padding-bottom: 2px;
}

.splitter-toggle-btn:hover {
  background-color: #0ea5e9;
  color: #ffffff;
  border-color: #0ea5e9;
}

/* Floating macOS Bottom Dock Navigation */
.orbit-dock {
  height: 90px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-bottom: 16px;
  background: linear-gradient(to top, #070a13 50%, transparent);
  pointer-events: none;
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 100;
}

.dock-container {
  display: flex;
  align-items: flex-end;
  gap: 10px;
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 8px 16px;
  border-radius: 20px;
  backdrop-filter: blur(20px);
  pointer-events: auto;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.1);
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.dock-container:hover {
  border-color: rgba(14, 165, 233, 0.4);
  box-shadow: 0 20px 45px rgba(14, 165, 233, 0.15);
}

.dock-item {
  background: none;
  border: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 58px;
  cursor: pointer;
  position: relative;
  transition: all 0.2s cubic-bezier(0.25, 0.8, 0.25, 1);
  border-radius: 12px;
  color: #94a3b8;
}

.dock-item .dock-icon {
  font-size: 26px;
  transition: transform 0.2s;
}

.dock-item .dock-label {
  position: absolute;
  bottom: 64px;
  background-color: #0f172a;
  color: #ffffff;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 14px;
  white-space: nowrap;
  opacity: 0;
  transform: translateY(10px);
  transition: all 0.25s ease;
  pointer-events: none;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
  font-weight: 500;
}

.dock-item:hover {
  transform: translateY(-8px) scale(1.15);
  color: #38bdf8;
}

.dock-item:hover .dock-icon {
  transform: scale(1.05);
}

.dock-item:hover .dock-label {
  opacity: 1;
  transform: translateY(0);
}

.dock-item.active {
  color: #0ea5e9;
  background: rgba(14, 165, 233, 0.1);
  border: 1px solid rgba(14, 165, 233, 0.2);
}

.dock-item.active::after {
  content: "";
  position: absolute;
  bottom: -4px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: #0ea5e9;
  box-shadow: 0 0 6px #0ea5e9;
}

.dock-separator {
  width: 1px;
  height: 36px;
  background-color: rgba(255, 255, 255, 0.12);
  align-self: center;
  margin: 0 6px;
}

/* Dashboard Cockpit Cards */
.metrics-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}

.metric-card {
  background-color: #111827;
  border: 1px solid rgba(255, 255, 255, 0.05);
  padding: 20px;
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 120px;
  transition: border-color 0.2s;
}
.metric-card:hover {
  border-color: rgba(14, 165, 233, 0.3);
}

.metric-card .small-label {
  color: #94a3b8;
  margin-bottom: 8px;
}

.metric-card .value {
  font-size: 32px;
  font-weight: 700;
  color: #ffffff;
}

.metric-card.alert-card {
  border-left: 4px solid #ef4444;
}
.metric-card.warning-card {
  border-left: 4px solid #f59e0b;
}

.dashboard-sections {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

@media (max-width: 1200px) {
  .dashboard-sections {
    grid-template-columns: 1fr;
  }

  .dashboard-summary-strip,
  .dashboard-inline-scene-grid,
  .dashboard-foot-grid {
    grid-template-columns: 1fr;
  }

  .dashboard-focus-grid,
  .dashboard-action-grid,
  .dashboard-scene-grid {
    grid-template-columns: 1fr;
  }
}

.dashboard-panel {
  background-color: #111827;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.dashboard-panel .panel-head {
  padding: 16px 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  background-color: rgba(255, 255, 255, 0.02);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.dashboard-panel .panel-body {
  padding: 20px;
}

.dashboard-summary-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}

.dashboard-summary-strip article {
  padding: 16px 18px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.96), rgba(15, 23, 42, 0.9));
  display: grid;
  gap: 4px;
  min-height: 112px;
}

.dashboard-summary-strip span,
.dashboard-summary-strip small {
  color: #94a3b8;
  font-size: 14px;
}

.dashboard-summary-strip strong {
  font-size: 30px;
  line-height: 1.1;
  color: #ffffff;
}

.dashboard-summary-strip article:nth-child(1) strong { color: #38bdf8; }
.dashboard-summary-strip article:nth-child(2) strong { color: #10b981; }
.dashboard-summary-strip article:nth-child(3) strong { color: #f59e0b; }
.dashboard-summary-strip article:nth-child(4) strong { color: #f472b6; }

.dashboard-inline-scene-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.dashboard-inline-scene-card {
  display: grid;
  gap: 4px;
  padding: 14px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(15, 23, 42, 0.6);
}

.dashboard-inline-scene-card span {
  color: #94a3b8;
  font-size: 14px;
}

.dashboard-inline-scene-card strong {
  color: #ffffff;
  font-size: 24px;
  line-height: 1.1;
}

.dashboard-inline-scene-card em {
  color: #38bdf8;
  font-style: normal;
  font-size: 14px;
}

.dashboard-focus-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.dashboard-focus-card {
  padding: 14px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(15, 23, 42, 0.66);
  display: grid;
  gap: 6px;
}

.dashboard-focus-card span {
  color: #94a3b8;
  font-size: 14px;
}

.dashboard-focus-card strong {
  color: #ffffff;
  font-size: 26px;
  line-height: 1.1;
}

.dashboard-focus-card p {
  color: #cbd5e1;
  font-size: 14px;
}

.dashboard-focus-card.warning { border-left: 4px solid #f59e0b; }
.dashboard-focus-card.danger { border-left: 4px solid #ef4444; }
.dashboard-focus-card.info { border-left: 4px solid #38bdf8; }
.dashboard-focus-card.success { border-left: 4px solid #10b981; }

.dashboard-foot-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 20px;
  margin-top: 20px;
}

/* Timeline Activity list */
.activity-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.activity-item {
  border-left: 2px solid #334155;
  padding-left: 16px;
  position: relative;
}

.activity-item::before {
  content: "";
  position: absolute;
  left: -5px;
  top: 4px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: #64748b;
}

.activity-item.alert-activity::before {
  background-color: #ef4444;
  box-shadow: 0 0 6px #ef4444;
}

.activity-item.warn-activity::before {
  background-color: #f59e0b;
}

.activity-item .time {
  font-size: 14px;
  color: #94a3b8;
  display: block;
  margin-bottom: 2px;
}

.activity-item .text {
  color: #cbd5e1;
}

/* Explorer Pane list view styles */
.explorer-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.explorer-item {
  background-color: #111827;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  padding: 16px;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.explorer-item:hover {
  border-color: rgba(14, 165, 233, 0.3);
  background-color: #1f2937;
}

.explorer-item.selected {
  border-color: #0ea5e9;
  background-color: rgba(14, 165, 233, 0.08);
}

.explorer-item-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.explorer-item-title {
  font-weight: 600;
  color: #ffffff;
}

.status-badge {
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 500;
}
.status-badge.green { background-color: rgba(16, 185, 129, 0.15); color: #10b981; }
.status-badge.yellow { background-color: rgba(245, 158, 11, 0.15); color: #f59e0b; }
.status-badge.red { background-color: rgba(239, 68, 68, 0.15); color: #ef4444; }
.status-badge.blue { background-color: rgba(14, 165, 233, 0.15); color: #38bdf8; }

.explorer-item-details {
  display: flex;
  justify-content: space-between;
  color: #94a3b8;
  font-size: 14px;
}

/* Detail Pane sections */
.detail-section {
  background-color: #111827;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 20px;
}

.detail-section-title {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 16px;
  color: #f1f5f9;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  padding-bottom: 8px;
}

.dashboard-scene-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.dashboard-scene-card {
  display: grid;
  gap: 10px;
  padding: 14px;
  text-align: left;
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.62);
  border: 1px solid rgba(255, 255, 255, 0.05);
  cursor: pointer;
}

.dashboard-scene-card.blue { border-left: 4px solid #38bdf8; }
.dashboard-scene-card.green { border-left: 4px solid #10b981; }
.dashboard-scene-card.cyan { border-left: 4px solid #22d3ee; }
.dashboard-scene-card.amber { border-left: 4px solid #f59e0b; }

.dashboard-scene-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}

.dashboard-scene-head strong {
  color: #ffffff;
  font-size: 17px;
}

.dashboard-scene-card p {
  color: #cbd5e1;
  font-size: 14px;
}

.dashboard-scene-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.dashboard-scene-metrics article {
  display: grid;
  gap: 4px;
  padding: 10px;
  border-radius: 8px;
  background: rgba(11, 15, 25, 0.72);
}

.dashboard-scene-metrics span,
.dashboard-scene-foot span {
  color: #94a3b8;
  font-size: 14px;
}

.dashboard-scene-metrics b {
  color: #ffffff;
  font-size: 22px;
  line-height: 1.1;
}

.dashboard-scene-foot {
  display: flex;
  justify-content: space-between;
  gap: 8px;
}

.dashboard-reminder-list {
  display: grid;
  gap: 12px;
}

.dashboard-reminder-item {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  padding: 14px;
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.62);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.dashboard-reminder-item strong,
.dashboard-ledger-main strong {
  color: #ffffff;
}

.dashboard-reminder-item p {
  color: #cbd5e1;
  font-size: 14px;
  margin-top: 4px;
}

.dashboard-reminder-item b {
  color: #ffffff;
  font-size: 22px;
  line-height: 1.1;
  white-space: nowrap;
}

.dashboard-reminder-item.warning { border-left: 4px solid #f59e0b; }
.dashboard-reminder-item.danger { border-left: 4px solid #ef4444; }
.dashboard-reminder-item.info { border-left: 4px solid #38bdf8; }
.dashboard-reminder-item.success { border-left: 4px solid #10b981; }

.dashboard-ledger-list {
  display: grid;
  gap: 12px;
}

.dashboard-ledger-row {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 16px;
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.58);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.dashboard-ledger-main {
  display: grid;
  gap: 4px;
}

.dashboard-ledger-main p {
  color: #94a3b8;
  font-size: 14px;
}

.dashboard-ledger-metrics {
  display: grid;
  justify-items: end;
  gap: 4px;
  min-width: 120px;
}

.dashboard-ledger-metrics span {
  color: #94a3b8;
  font-size: 14px;
}

.dashboard-ledger-metrics b {
  color: #ffffff;
  font-size: 20px;
}

.dashboard-action-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.dashboard-action-card {
  display: grid;
  gap: 6px;
  min-height: 118px;
  padding: 14px;
  border-radius: 10px;
  text-align: left;
  background: rgba(15, 23, 42, 0.62);
  border: 1px solid rgba(255, 255, 255, 0.05);
  cursor: pointer;
}

.dashboard-action-card strong {
  color: #ffffff;
  font-size: 18px;
}

.dashboard-action-card p {
  color: #cbd5e1;
  font-size: 14px;
}

.dashboard-action-card.info { border-left: 4px solid #38bdf8; }
.dashboard-action-card.warning { border-left: 4px solid #f59e0b; }
.dashboard-action-card.danger { border-left: 4px solid #ef4444; }
.dashboard-action-card.success { border-left: 4px solid #10b981; }

/* Filter controls */
.filter-group {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.filter-input {
  background: #1e293b;
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #ffffff;
  padding: 8px 12px;
  border-radius: 6px;
  outline: none;
  min-height: 40px;
  flex: 1;
}

.filter-select {
  background: #1e293b;
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #ffffff;
  padding: 8px 12px;
  border-radius: 6px;
  outline: none;
  min-height: 40px;
}

/* Table styles */
.data-table-container {
  width: 100%;
  overflow-x: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

.data-table th, .data-table td {
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.data-table th {
  background-color: rgba(255, 255, 255, 0.02);
  color: #f1f5f9;
  font-weight: 600;
}

.data-table tbody tr:hover {
  background-color: rgba(255, 255, 255, 0.01);
}

/* Timeline history display */
.history-timeline {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 14px;
}

.history-node {
  background-color: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  padding: 12px 16px;
  font-size: 14px;
  color: #cbd5e1;
}

/* Form Styles */
.form-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}

.form-row label {
  font-weight: 500;
  color: #cbd5e1;
}

.form-row input, .form-row select, .form-row textarea {
  background: #1e293b;
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #ffffff;
  padding: 10px 14px;
  border-radius: 6px;
  outline: none;
  min-height: 44px;
}

.form-row textarea {
  min-height: 100px;
  resize: vertical;
}

.form-row input:focus, .form-row select:focus, .form-row textarea:focus {
  border-color: #0ea5e9;
}

/* Loading and empty placeholders */
.loading-placeholder, .empty-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 200px;
  color: #64748b;
  text-align: center;
  font-style: italic;
  font-size: 16px;
}

/* Orbit orbit-track visualizer */
.orbit-track {
  display: flex;
  justify-content: space-between;
  position: relative;
  margin: 30px 0;
  padding: 0 40px;
}

.orbit-track::before {
  content: "";
  position: absolute;
  top: 12px;
  left: 40px;
  right: 40px;
  height: 4px;
  background-color: #334155;
  z-index: 1;
}

.orbit-track-progress {
  position: absolute;
  top: 12px;
  left: 40px;
  height: 4px;
  background: linear-gradient(90deg, #0ea5e9, #10b981);
  z-index: 2;
  transition: width 0.3s;
}

.orbit-node {
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: 3;
  cursor: pointer;
}

.orbit-node-circle {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background-color: #1e293b;
  border: 4px solid #334155;
  transition: all 0.2s;
}

.orbit-node.active .orbit-node-circle {
  border-color: #0ea5e9;
  background-color: #0b0f19;
  box-shadow: 0 0 10px rgba(14, 165, 233, 0.6);
}

.orbit-node.completed .orbit-node-circle {
  border-color: #10b981;
  background-color: #10b981;
}

.orbit-node-label {
  margin-top: 8px;
  font-size: 14px;
  font-weight: 500;
  color: #94a3b8;
}

.orbit-node.active .orbit-node-label {
  color: #0ea5e9;
  font-weight: 600;
}

.orbit-node.completed .orbit-node-label {
  color: #10b981;
}

/* Visualization of 7-day trend chart via divs */
.bar-chart-container {
  display: flex;
  align-items: flex-end;
  height: 180px;
  gap: 12px;
  padding-top: 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  margin-bottom: 12px;
}

.bar-column {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  height: 100%;
  justify-content: flex-end;
}

.bar-pill {
  width: 100%;
  border-radius: 4px 4px 0 0;
  background: linear-gradient(180deg, #0ea5e9 0%, rgba(14, 165, 233, 0.2) 100%);
  position: relative;
  min-height: 8px;
  transition: height 0.4s ease;
}

.bar-column:nth-child(even) .bar-pill {
  background: linear-gradient(180deg, #10b981 0%, rgba(16, 185, 129, 0.2) 100%);
}

.bar-column:hover .bar-pill {
  filter: brightness(1.2);
}

.bar-pill::after {
  content: attr(data-value);
  position: absolute;
  top: -24px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 12px;
  color: #ffffff;
  font-weight: 600;
  white-space: nowrap;
}

.bar-labels {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
}

.bar-labels span {
  flex: 1;
  text-align: center;
  font-size: 12px;
  color: #94a3b8;
}

/* Grid themes mapping */
.theme-matrix-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

.theme-matrix-card {
  background-color: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  padding: 16px;
  cursor: pointer;
  transition: all 0.2s;
  text-align: center;
}

.theme-matrix-card:hover, .theme-matrix-card.active {
  background-color: rgba(14, 165, 233, 0.08);
  border-color: #0ea5e9;
}

.theme-matrix-card h4 {
  font-size: 16px;
  margin-bottom: 4px;
  color: #ffffff;
}

.theme-matrix-card p {
  font-size: 14px;
  color: #94a3b8;
}

/* Threshold Rules Module */
.trules-spec-shell,
.trules-spec-detail-shell {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.trules-spec-hero {
  display: flex;
  align-items: center;
  min-height: 52px;
}

.trules-spec-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.trules-spec-summary-card {
  text-align: left;
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.96), rgba(15, 23, 42, 0.92));
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 10px;
  padding: 16px 18px;
  min-height: 92px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  cursor: pointer;
  color: #e2e8f0;
}

.trules-spec-summary-card span {
  color: #94a3b8;
  font-size: 14px;
}

.trules-spec-summary-card strong {
  font-size: 24px;
  color: #f8fafc;
}

.trules-spec-summary-card.active,
.trules-spec-summary-card:hover {
  border-color: rgba(14, 165, 233, 0.55);
  box-shadow: 0 0 0 1px rgba(14, 165, 233, 0.15), 0 12px 24px rgba(2, 132, 199, 0.14);
}

.trules-spec-group-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.trules-spec-group-block {
  background: rgba(17, 24, 39, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  padding: 16px;
}

.trules-spec-group-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.trules-spec-group-head strong {
  display: block;
  font-size: 18px;
  color: #f8fafc;
}

.trules-spec-group-head span,
.trules-spec-group-head em {
  display: block;
  margin-top: 4px;
  color: #94a3b8;
  font-size: 14px;
  font-style: normal;
}

.trules-spec-rule-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.trules-spec-rule-card {
  text-align: left;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.98), rgba(17, 24, 39, 0.92));
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  padding: 14px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 168px;
}

.trules-spec-rule-card.active {
  border-color: rgba(14, 165, 233, 0.6);
  box-shadow: 0 0 0 1px rgba(14, 165, 233, 0.18), 0 12px 28px rgba(14, 165, 233, 0.14);
}

.trules-spec-rule-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.trules-spec-rule-head strong {
  display: block;
  font-size: 16px;
  color: #f8fafc;
}

.trules-spec-rule-head span {
  display: block;
  margin-top: 4px;
  font-size: 12px;
  color: #94a3b8;
}

.trules-spec-rule-meta,
.trules-spec-rule-foot {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  color: #94a3b8;
  font-size: 12px;
}

.trules-spec-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}

.trules-spec-status.status-normal {
  color: #10b981;
  background: rgba(16, 185, 129, 0.12);
}

.trules-spec-status.status-warning {
  color: #eab308;
  background: rgba(234, 179, 8, 0.12);
}

.trules-spec-status.status-critical {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.12);
}

.trules-spec-status.status-off {
  color: #94a3b8;
  background: rgba(148, 163, 184, 0.12);
}

.trules-spec-band {
  position: relative;
  height: 16px;
  border-radius: 999px;
  overflow: hidden;
  background: #1e293b;
}

.trules-spec-band.upper {
  background: linear-gradient(90deg,
    #10b981 0%,
    #10b981 var(--warning-stop),
    #eab308 var(--warning-stop),
    #eab308 var(--critical-stop),
    #ef4444 var(--critical-stop),
    #ef4444 100%);
}

.trules-spec-band.lower {
  background: linear-gradient(90deg,
    #ef4444 0%,
    #ef4444 var(--critical-stop),
    #eab308 var(--critical-stop),
    #eab308 var(--warning-stop),
    #10b981 var(--warning-stop),
    #10b981 100%);
}

.trules-spec-band.large {
  height: 22px;
}

.trules-spec-band-marker {
  position: absolute;
  top: -5px;
  left: var(--value-stop);
  width: 2px;
  height: 32px;
  background: #f8fafc;
  box-shadow: 0 0 12px rgba(248, 250, 252, 0.8);
  transform: translateX(-50%);
}

.trules-spec-band-value {
  position: absolute;
  top: -30px;
  left: var(--value-stop);
  transform: translateX(-50%);
  font-size: 12px;
  color: #f8fafc;
  white-space: nowrap;
}

.trules-spec-detail-shell {
  gap: 16px;
}

.trules-spec-detail-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  padding: 18px 20px;
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.96), rgba(15, 23, 42, 0.92));
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 12px;
}

.trules-spec-detail-id {
  display: block;
  color: #38bdf8;
  font-size: 12px;
  letter-spacing: 0.04em;
  margin-bottom: 6px;
}

.trules-spec-detail-head h2 {
  font-size: 20px;
  color: #f8fafc;
}

.trules-spec-detail-head p,
.trules-spec-detail-status span {
  margin-top: 8px;
  color: #94a3b8;
  font-size: 14px;
}

.trules-spec-band-panel,
.trules-spec-form-panel,
.trules-spec-strategy-panel,
.trules-spec-validation-panel,
.trules-spec-history-panel,
.trules-spec-activity-panel {
  background: rgba(17, 24, 39, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  padding: 16px;
}

.trules-spec-panel-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-bottom: 12px;
}

.trules-spec-panel-head h4 {
  font-size: 18px;
  color: #f8fafc;
}

.trules-spec-panel-head span {
  color: #94a3b8;
  font-size: 12px;
}

.trules-spec-band-caption,
.trules-spec-band-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.trules-spec-band-caption span,
.trules-spec-band-summary span {
  display: block;
  color: #94a3b8;
  font-size: 12px;
}

.trules-spec-band-summary strong {
  display: block;
  margin-top: 4px;
  color: #f8fafc;
  font-size: 16px;
}

.trules-spec-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.trules-spec-form-grid label {
  display: flex;
  flex-direction: column;
  gap: 8px;
  color: #cbd5e1;
}

.trules-spec-form-grid label span {
  font-size: 14px;
  color: #94a3b8;
}

.trules-spec-form-grid input,
.trules-spec-form-grid select {
  background: #0f172a;
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #f8fafc;
  border-radius: 8px;
  min-height: 44px;
  padding: 10px 12px;
  outline: none;
}

.trules-spec-form-grid input:focus,
.trules-spec-form-grid select:focus {
  border-color: rgba(14, 165, 233, 0.7);
  box-shadow: 0 0 0 2px rgba(14, 165, 233, 0.18);
}

.trules-spec-strategy-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.trules-spec-strategy-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(15, 23, 42, 0.72);
  cursor: pointer;
}

.trules-spec-strategy-item input {
  width: 16px;
  height: 16px;
  accent-color: #0ea5e9;
}

.trules-spec-validation-summary {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.trules-spec-validation-flag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}

.trules-spec-validation-flag.ok {
  color: #10b981;
  background: rgba(16, 185, 129, 0.12);
}

.trules-spec-validation-flag.warn {
  color: #eab308;
  background: rgba(234, 179, 8, 0.12);
}

.trules-spec-validation-list {
  display: grid;
  gap: 10px;
}

.trules-spec-validation-row {
  display: grid;
  grid-template-columns: 96px 64px 1fr;
  gap: 10px;
  align-items: start;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(15, 23, 42, 0.72);
}

.trules-spec-validation-row.ok {
  border-color: rgba(16, 185, 129, 0.22);
}

.trules-spec-validation-row.error {
  border-color: rgba(239, 68, 68, 0.22);
}

.trules-spec-validation-row span {
  color: #f8fafc;
  font-size: 14px;
}

.trules-spec-validation-row b {
  color: #f8fafc;
  font-size: 14px;
}

.trules-spec-validation-row p {
  color: #94a3b8;
  font-size: 14px;
}

.trules-spec-history-list,
.trules-spec-activity-list {
  display: grid;
  gap: 10px;
  max-height: 240px;
}

.trules-spec-history-item,
.trules-spec-activity-item {
  padding: 12px 14px;
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.trules-spec-history-item span,
.trules-spec-activity-item span {
  display: block;
  color: #94a3b8;
  font-size: 12px;
  margin-bottom: 4px;
}

.trules-spec-history-item p,
.trules-spec-activity-item p {
  color: #e2e8f0;
  font-size: 14px;
}

.trules-spec-modal {
  position: fixed;
  inset: 0;
  background: rgba(2, 6, 23, 0.72);
  backdrop-filter: blur(8px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.trules-spec-modal-card {
  width: min(1000px, 100%);
  max-height: 92vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, #0f172a, #111827);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.45);
}

.trules-spec-modal-head,
.trules-spec-modal-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 18px 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.trules-spec-modal-foot {
  border-bottom: 0;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  justify-content: flex-end;
}

.trules-spec-modal-head h2 {
  font-size: 20px;
  color: #f8fafc;
}

.trules-spec-modal-head p {
  margin-top: 4px;
  color: #94a3b8;
  font-size: 14px;
}

.trules-spec-modal-close {
  width: 36px;
  height: 36px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(15, 23, 42, 0.72);
  color: #cbd5e1;
  border-radius: 8px;
  cursor: pointer;
}

.trules-spec-modal-body {
  padding: 20px;
  overflow: auto;
}

.trules-spec-modal .modal-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (max-width: 1280px) {
  .trules-spec-summary-grid,
  .trules-spec-band-caption,
  .trules-spec-band-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 1100px) {
  .trules-spec-rule-grid,
  .trules-spec-form-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .trules-spec-summary-grid {
    grid-template-columns: 1fr;
  }
  .trules-spec-validation-row {
    grid-template-columns: 1fr;
  }
}

/* Metrics Config Module */
.mconfig-spec-filter-row {
  display: grid;
  grid-template-columns: minmax(180px, 220px) minmax(0, 1fr);
  gap: 12px;
  width: 100%;
}

.mconfig-spec-filter {
  display: grid;
  gap: 8px;
}

.mconfig-spec-filter span {
  font-size: 14px;
  color: #90aec4;
}

.mconfig-spec-filter select,
.mconfig-spec-filter input {
  height: 44px;
  padding: 0 14px;
  border-radius: 8px;
  border: 1px solid rgba(74, 189, 240, 0.22);
  background: #10202f;
  color: #eef7fd;
  font-size: 16px;
  outline: none;
}

.mconfig-spec-search {
  min-width: 0;
}

.mconfig-spec-shell {
  display: grid;
  gap: 12px;
  min-height: 100%;
}

.mconfig-spec-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  padding: 2px 2px 0;
}

.mconfig-spec-legend span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: #97b1c6;
}

.mconfig-spec-legend .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
}

.mconfig-spec-legend .dot-live {
  background: #10b981;
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.35);
}

.mconfig-spec-legend .dot-warn {
  background: #eab308;
  box-shadow: 0 0 10px rgba(234, 179, 8, 0.3);
}

.mconfig-spec-legend .dot-draft {
  background: #0ea5e9;
  box-shadow: 0 0 10px rgba(14, 165, 233, 0.3);
}

.mconfig-spec-list {
  display: grid;
  gap: 10px;
  min-height: 0;
}

.mconfig-spec-card {
  display: grid;
  gap: 10px;
  text-align: left;
  padding: 14px;
  border-radius: 10px;
  border: 1px solid rgba(80, 190, 239, 0.14);
  background: linear-gradient(160deg, #111827 0%, #0f1e2d 100%);
  cursor: pointer;
  transition: border-color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.mconfig-spec-card:hover,
.mconfig-spec-card.active {
  border-color: rgba(14, 165, 233, 0.75);
  box-shadow: 0 0 0 1px rgba(14, 165, 233, 0.14), 0 16px 30px rgba(0, 0, 0, 0.18);
  transform: translateY(-1px);
}

.mconfig-spec-card-top,
.mconfig-spec-card-meta,
.mconfig-spec-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.mconfig-spec-card-top strong {
  font-size: 16px;
  color: #f4fbff;
}

.mconfig-spec-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}

.mconfig-spec-status-ok {
  color: #10b981;
  background: rgba(16, 185, 129, 0.12);
}

.mconfig-spec-status-warn {
  color: #eab308;
  background: rgba(234, 179, 8, 0.12);
}

.mconfig-spec-status-draft {
  color: #38bdf8;
  background: rgba(14, 165, 233, 0.12);
}

.mconfig-spec-card-meta,
.mconfig-spec-card-footer,
.mconfig-spec-card-desc,
.mconfig-spec-formula-snippet {
  font-size: 14px;
  color: #9db7c9;
}

.mconfig-spec-card-meta span {
  font-size: 12px;
}

.mconfig-spec-card-desc {
  line-height: 1.55;
}

.mconfig-spec-card-footer b {
  color: #d9f4ff;
}

.mconfig-spec-card-footer i {
  font-style: normal;
  font-size: 12px;
}

.mconfig-spec-formula-snippet {
  padding: 10px 12px;
  border-radius: 8px;
  background: rgba(7, 19, 31, 0.9);
  border: 1px solid rgba(71, 174, 218, 0.12);
  font-family: Consolas, "Courier New", monospace;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mconfig-spec-action-btn {
  min-height: 44px;
}

.mconfig-spec-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.mconfig-spec-summary div {
  min-height: 82px;
  padding: 14px;
  border-radius: 10px;
  background: linear-gradient(180deg, rgba(18, 29, 45, 0.98), rgba(12, 23, 37, 0.98));
  border: 1px solid rgba(87, 198, 241, 0.12);
}

.mconfig-spec-summary span {
  display: block;
  margin-bottom: 10px;
  font-size: 12px;
  color: #8ba8bc;
}

.mconfig-spec-summary strong {
  display: block;
  font-size: 16px;
  color: #f3fbff;
  line-height: 1.45;
}

.mconfig-spec-editor-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(280px, 0.9fr);
  gap: 12px;
  min-height: 0;
}

.mconfig-spec-editor-panel,
.mconfig-spec-config-panel {
  display: grid;
  gap: 12px;
  padding: 16px;
  border-radius: 10px;
  border: 1px solid rgba(86, 194, 237, 0.14);
  background: linear-gradient(160deg, #111827 0%, #0b1726 100%);
  min-height: 0;
}

.mconfig-spec-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.mconfig-spec-panel-head h4 {
  font-size: 18px;
  color: #f4fbff;
}

.mconfig-spec-light {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 0 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}

.mconfig-spec-light.wait {
  color: #eab308;
  background: rgba(234, 179, 8, 0.12);
}

.mconfig-spec-light.ok {
  color: #10b981;
  background: rgba(16, 185, 129, 0.12);
}

.mconfig-spec-light.error {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.12);
}

.mconfig-spec-editor-panel textarea {
  width: 100%;
  min-height: 332px;
  resize: vertical;
  border-radius: 10px;
  border: 1px solid rgba(79, 188, 236, 0.18);
  padding: 14px;
  background: #09121d;
  color: #f2fbff;
  font-size: 16px;
  line-height: 1.6;
  font-family: Consolas, "Courier New", monospace;
  outline: none;
}

.mconfig-spec-editor-note {
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid rgba(16, 185, 129, 0.16);
  background: rgba(16, 185, 129, 0.08);
  color: #c7f7e8;
  font-size: 14px;
  line-height: 1.45;
}

.mconfig-spec-editor-note-muted {
  border-color: rgba(87, 198, 241, 0.12);
  background: rgba(87, 198, 241, 0.08);
  color: #d9f4ff;
}

.mconfig-spec-config-list {
  display: grid;
  gap: 10px;
}

.mconfig-spec-config-list div {
  display: grid;
  gap: 4px;
  padding: 12px 14px;
  border-radius: 8px;
  background: rgba(9, 18, 28, 0.88);
  border: 1px solid rgba(87, 198, 241, 0.1);
}

.mconfig-spec-config-list span {
  font-size: 12px;
  color: #8aa6b8;
}

.mconfig-spec-config-list b {
  font-size: 15px;
  color: #f4fbff;
  word-break: break-word;
}

.mconfig-spec-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.mconfig-spec-tags span {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 12px;
  color: #8fdcff;
  background: rgba(14, 165, 233, 0.12);
  border: 1px solid rgba(14, 165, 233, 0.2);
}

@media (max-width: 1280px) {
  .mconfig-spec-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .mconfig-spec-editor-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 1024px) {
  .mconfig-spec-filter-row {
    grid-template-columns: 1fr;
  }

  .mconfig-spec-summary {
    grid-template-columns: 1fr;
  }
}

.rmonitor-spec-gauge-wall {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  padding-bottom: 16px;
}

.rmonitor-spec-gauge-card,
.rmonitor-spec-snapshot article,
.rmonitor-spec-detail-card,
.rmonitor-spec-trend-panel,
.rmonitor-spec-log-panel {
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  background: #111827;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.rmonitor-spec-gauge-card {
  min-height: 190px;
  display: grid;
  grid-template-columns: 126px 1fr;
  align-items: center;
  gap: 16px;
  padding: 18px;
}

.rmonitor-spec-gauge-ring {
  width: 126px;
  height: 126px;
  position: relative;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background:
    radial-gradient(circle at center, #111827 0 54%, transparent 56%),
    conic-gradient(var(--ring-color) var(--value), rgba(148, 163, 184, 0.15) 0);
  box-shadow: 0 0 32px rgba(14, 165, 233, 0.18);
}

.rmonitor-spec-gauge-ring span {
  display: block;
  color: #f8fafc;
  font-size: 32px;
  font-weight: 800;
  line-height: 1;
  text-shadow: 0 0 18px var(--ring-glow);
}

.rmonitor-spec-gauge-ring small {
  margin-top: -24px;
  color: #94a3b8;
  font-size: 12px;
}

.rmonitor-spec-gauge-card h2 {
  margin: 0 0 8px;
  color: #f8fafc;
  font-size: 20px;
  line-height: 1.35;
}

.rmonitor-spec-gauge-card p {
  color: #94a3b8;
  font-size: 14px;
  line-height: 1.5;
}

.rmonitor-spec-green {
  --ring-color: #10b981;
  --ring-glow: rgba(16, 185, 129, 0.75);
}

.rmonitor-spec-yellow {
  --ring-color: #eab308;
  --ring-glow: rgba(234, 179, 8, 0.75);
}

.rmonitor-spec-red {
  --ring-color: #ef4444;
  --ring-glow: rgba(239, 68, 68, 0.75);
}

.rmonitor-spec-blue {
  --ring-color: #0ea5e9;
  --ring-glow: rgba(14, 165, 233, 0.75);
}

.rmonitor-spec-snapshot {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}

.rmonitor-spec-snapshot article {
  min-height: 92px;
  display: grid;
  align-content: center;
  gap: 6px;
  padding: 16px;
}

.rmonitor-spec-snapshot span {
  color: #94a3b8;
  font-size: 14px;
}

.rmonitor-spec-snapshot b {
  color: #e2e8f0;
  font-size: 30px;
  line-height: 1;
}

.rmonitor-spec-detail-card {
  padding: 18px;
}

.rmonitor-spec-detail-card h2,
.rmonitor-spec-panel-head h2 {
  margin: 0;
  color: #f8fafc;
  font-size: 20px;
  line-height: 1.35;
}

.rmonitor-spec-detail-card dl {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.rmonitor-spec-detail-card div {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.rmonitor-spec-detail-card dt,
.rmonitor-spec-detail-card dd {
  margin: 0;
}

.rmonitor-spec-detail-card dt {
  color: #94a3b8;
  font-size: 14px;
}

.rmonitor-spec-detail-card dd {
  color: #e2e8f0;
  font-size: 16px;
  line-height: 1.5;
}

.rmonitor-spec-sensor-board {
  display: grid;
  grid-template-columns: repeat(4, minmax(150px, 1fr));
  gap: 12px;
  max-height: 340px;
  padding: 2px 2px 14px;
  overflow-y: auto;
  scrollbar-gutter: stable;
}

.rmonitor-spec-sensor {
  min-height: 102px;
  position: relative;
  display: grid;
  grid-template-columns: 26px 1fr;
  grid-template-rows: auto auto;
  align-items: center;
  gap: 4px 10px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  background: #111827;
  color: #e2e8f0;
  text-align: left;
}

.rmonitor-spec-sensor.active {
  border-color: rgba(14, 165, 233, 0.72);
  box-shadow: 0 0 26px rgba(14, 165, 233, 0.22);
}

.rmonitor-spec-light {
  width: 18px;
  height: 18px;
  grid-row: 1 / 3;
  border-radius: 50%;
  background: var(--light-color);
  box-shadow: 0 0 18px var(--light-color);
  animation: rmonitorSpecBreath 1.6s ease-in-out infinite;
}

.rmonitor-spec-sensor strong {
  color: #f8fafc;
  font-size: 15px;
  line-height: 1.35;
}

.rmonitor-spec-sensor small {
  color: #94a3b8;
  font-size: 12px;
  line-height: 1.4;
}

.rmonitor-spec-normal {
  --light-color: #10b981;
}

.rmonitor-spec-warning {
  --light-color: #eab308;
}

.rmonitor-spec-critical {
  --light-color: #ef4444;
}

@keyframes rmonitorSpecBreath {
  0%, 100% {
    opacity: 0.55;
    transform: scale(0.88);
  }
  50% {
    opacity: 1;
    transform: scale(1.12);
  }
}

.rmonitor-spec-trend-panel,
.rmonitor-spec-log-panel {
  margin-top: 16px;
  padding: 16px;
}

.rmonitor-spec-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.rmonitor-spec-panel-head span {
  color: #94a3b8;
  font-size: 14px;
}

.rmonitor-spec-micro-chart {
  height: 180px;
  display: flex;
  align-items: flex-end;
  gap: 6px;
  padding-top: 22px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.22);
}

.rmonitor-spec-bar {
  flex: 1;
  min-height: 18px;
  min-width: 14px;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  border: 0;
  border-radius: 8px 8px 0 0;
  background: linear-gradient(180deg, #10b981, rgba(16, 185, 129, 0.22));
}

.rmonitor-spec-bar.warn {
  background: linear-gradient(180deg, #eab308, rgba(234, 179, 8, 0.24));
}

.rmonitor-spec-bar.danger {
  background: linear-gradient(180deg, #ef4444, rgba(239, 68, 68, 0.24));
}

.rmonitor-spec-bar span {
  margin-top: -22px;
  color: #cbd5e1;
  font-size: 12px;
  line-height: 1;
}

.rmonitor-spec-chart-labels {
  display: grid;
  grid-template-columns: repeat(24, minmax(14px, 1fr));
  gap: 6px;
  margin-top: 8px;
}

.rmonitor-spec-chart-labels span {
  color: #94a3b8;
  font-size: 12px;
  white-space: nowrap;
}

.rmonitor-spec-log-panel {
  max-height: 280px;
}

.rmonitor-spec-log-list {
  display: grid;
  gap: 10px;
  max-height: 206px;
  overflow-y: auto;
  scrollbar-gutter: stable;
}

.rmonitor-spec-log-list article {
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  background: rgba(11, 15, 25, 0.62);
}

.rmonitor-spec-log-list time,
.rmonitor-spec-log-list span {
  color: #94a3b8;
  font-size: 12px;
}

.rmonitor-spec-log-list strong {
  display: block;
  margin-top: 4px;
  color: #f8fafc;
  font-size: 15px;
}

.rmonitor-spec-log-list p {
  margin: 4px 0;
  color: #cbd5e1;
  font-size: 14px;
}

.rmonitor-spec-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(2, 6, 23, 0.72);
  backdrop-filter: blur(10px);
}

.rmonitor-spec-modal-card {
  width: min(560px, 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  background: #111827;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.42);
  overflow: hidden;
}

.rmonitor-spec-modal-card header,
.rmonitor-spec-modal-card footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.rmonitor-spec-modal-card footer {
  justify-content: flex-end;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  border-bottom: 0;
}

.rmonitor-spec-modal-card h2 {
  margin: 0;
  color: #f8fafc;
  font-size: 20px;
}

.rmonitor-spec-modal-close {
  width: 40px;
  height: 40px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.82);
  color: #e2e8f0;
  font-size: 24px;
}

.rmonitor-spec-modal-body {
  padding: 18px;
}

.rmonitor-spec-modal-body p {
  margin-bottom: 14px;
  color: #cbd5e1;
  font-size: 16px;
}

.rmonitor-spec-reset-reason {
  width: 100%;
  min-height: 128px;
  padding: 12px 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: #0b0f19;
  color: #f8fafc;
  font-size: 16px;
  resize: vertical;
}

@media (max-width: 1440px) {
  .rmonitor-spec-gauge-wall,
  .rmonitor-spec-sensor-board {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .rmonitor-spec-gauge-wall,
  .rmonitor-spec-snapshot,
  .rmonitor-spec-sensor-board {
    grid-template-columns: 1fr;
  }

  .rmonitor-spec-gauge-card {
    grid-template-columns: 112px 1fr;
  }
}

.dassets-spec-filter-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.dassets-spec-filter {
  display: grid;
  gap: 8px;
}

.dassets-spec-filter span {
  color: #94a3b8;
  font-size: 14px;
  line-height: 1.4;
}

.dassets-spec-filter select,
.dassets-spec-filter input {
  width: 100%;
  min-height: 44px;
  padding: 11px 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.88);
  color: #f8fafc;
  font-size: 16px;
  line-height: 1.4;
  outline: none;
}

.dassets-spec-filter select:focus,
.dassets-spec-filter input:focus {
  border-color: rgba(14, 165, 233, 0.7);
  box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.14);
}

.dassets-spec-overview {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.dassets-spec-source-card {
  min-height: 108px;
  display: grid;
  align-content: start;
  gap: 8px;
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 10px;
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.96), rgba(11, 15, 25, 0.9));
  color: #e2e8f0;
  text-align: left;
  cursor: pointer;
}

.dassets-spec-source-card:hover {
  border-color: rgba(14, 165, 233, 0.48);
  box-shadow: 0 0 22px rgba(14, 165, 233, 0.12);
}

.dassets-spec-source-card b {
  color: #f8fafc;
  font-size: 18px;
  line-height: 1.35;
}

.dassets-spec-source-card span {
  color: #94a3b8;
  font-size: 14px;
  line-height: 1.5;
}

.dassets-spec-metric-strip {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
  padding: 4px 0 2px;
}

.dassets-spec-metric-strip div {
  min-height: 92px;
  display: grid;
  align-content: space-between;
  gap: 10px;
  padding: 14px 16px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.78);
}

.dassets-spec-metric-strip span {
  color: #94a3b8;
  font-size: 14px;
  line-height: 1.35;
}

.dassets-spec-metric-strip b {
  color: #f8fafc;
  font-size: 28px;
  line-height: 1;
  text-shadow: 0 0 14px rgba(14, 165, 233, 0.18);
}

.dassets-spec-record-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  max-height: 46vh;
  overflow-y: auto;
  scrollbar-gutter: stable;
  padding-right: 4px;
}

.dassets-spec-record {
  min-height: 168px;
  position: relative;
  display: grid;
  align-content: start;
  gap: 8px;
  padding: 16px 16px 14px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.88);
  color: #e2e8f0;
  text-align: left;
  cursor: pointer;
}

.dassets-spec-record:hover,
.dassets-spec-record.active {
  border-color: rgba(14, 165, 233, 0.55);
  box-shadow: 0 0 24px rgba(14, 165, 233, 0.12);
}

.dassets-spec-record.critical {
  border-color: rgba(239, 68, 68, 0.34);
}

.dassets-spec-record.warning {
  border-color: rgba(234, 179, 8, 0.34);
}

.dassets-spec-record .protocol {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 12px;
  line-height: 1;
  letter-spacing: 0;
}

.dassets-spec-record .protocol.mqtt {
  background: rgba(16, 185, 129, 0.16);
  color: #6ee7b7;
}

.dassets-spec-record .protocol.rest {
  background: rgba(14, 165, 233, 0.16);
  color: #7dd3fc;
}

.dassets-spec-record .protocol.opc {
  background: rgba(168, 85, 247, 0.16);
  color: #d8b4fe;
}

.dassets-spec-record b {
  color: #f8fafc;
  font-size: 18px;
  line-height: 1.35;
}

.dassets-spec-record em {
  color: #7dd3fc;
  font-style: normal;
  font-size: 14px;
}

.dassets-spec-record p {
  margin: 0;
  color: #cbd5e1;
  font-size: 14px;
  line-height: 1.5;
}

.dassets-spec-record .record-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  color: #94a3b8;
  font-size: 12px;
}

.dassets-spec-record i {
  position: absolute;
  top: 14px;
  right: 14px;
  color: rgba(148, 163, 184, 0.75);
  font-size: 12px;
  font-style: normal;
}

.dassets-spec-detail {
  display: grid;
  gap: 16px;
}

.dassets-spec-detail .detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.dassets-spec-detail .detail-head span,
.dassets-spec-detail .detail-section-title,
.dassets-spec-lineage span {
  color: #94a3b8;
  font-size: 14px;
}

.dassets-spec-detail .detail-head h3 {
  margin: 6px 0 0;
  color: #f8fafc;
  font-size: 22px;
  line-height: 1.3;
}

.dassets-spec-detail .status-chip {
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}

.dassets-spec-detail .status-chip.normal {
  background: rgba(16, 185, 129, 0.16);
  color: #6ee7b7;
}

.dassets-spec-detail .status-chip.warning {
  background: rgba(234, 179, 8, 0.16);
  color: #facc15;
}

.dassets-spec-detail .status-chip.critical {
  background: rgba(239, 68, 68, 0.16);
  color: #fca5a5;
}

.dassets-spec-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 12px;
}

.dassets-spec-detail-grid p {
  margin: 0;
  padding: 12px 14px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.72);
}

.dassets-spec-detail-grid span {
  display: block;
  color: #94a3b8;
  font-size: 12px;
  line-height: 1.35;
}

.dassets-spec-detail-grid b {
  display: block;
  margin-top: 6px;
  color: #f8fafc;
  font-size: 16px;
  line-height: 1.45;
}

.dassets-spec-lineage {
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  background: rgba(11, 15, 25, 0.76);
}

.dassets-spec-lineage b {
  color: #7dd3fc;
  font-size: 16px;
  line-height: 1.5;
}

.dassets-spec-trajectory,
.dassets-spec-keywords {
  padding-top: 2px;
}

.dassets-spec-timeline {
  display: grid;
  gap: 10px;
  max-height: 280px;
  overflow-y: auto;
  scrollbar-gutter: stable;
}

.dassets-spec-timeline article {
  display: grid;
  gap: 4px;
  padding: 12px 14px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.72);
}

.dassets-spec-timeline span {
  color: #94a3b8;
  font-size: 12px;
  line-height: 1.4;
}

.dassets-spec-timeline b {
  color: #f8fafc;
  font-size: 15px;
  line-height: 1.35;
}

.dassets-spec-timeline p {
  margin: 0;
  color: #cbd5e1;
  font-size: 14px;
  line-height: 1.45;
}

.dassets-spec-keywords .tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.dassets-spec-keywords .tag-pill {
  min-height: 30px;
  padding: 0 12px;
  border: 1px solid rgba(14, 165, 233, 0.25);
  border-radius: 999px;
  background: rgba(14, 165, 233, 0.1);
  color: #bae6fd;
  font-size: 12px;
}

.dassets-spec-search {
  grid-column: span 1;
}

@media (max-width: 1500px) {
  .dassets-spec-metric-strip {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 1200px) {
  .dassets-spec-filter-row,
  .dassets-spec-overview,
  .dassets-spec-detail-grid {
    grid-template-columns: 1fr 1fr;
  }

  .dassets-spec-record-grid {
    max-height: 42vh;
  }
}

@media (max-width: 900px) {
  .dassets-spec-filter-row,
  .dassets-spec-overview,
  .dassets-spec-metric-strip,
  .dassets-spec-record-grid,
  .dassets-spec-detail-grid {
    grid-template-columns: 1fr;
  }

  .dassets-spec-record-grid {
    max-height: none;
  }
}

.scene-spec-filter-row {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 12px;
}

.scene-spec-filter-note {
  margin-top: 10px;
  color: #94a3b8;
  font-size: 14px;
}

.scene-spec-tab-group {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.scene-spec-tab {
  min-height: 44px;
  padding: 0 16px;
  border: 1px solid rgba(56, 189, 248, 0.25);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.9);
  color: #cbd5e1;
  cursor: pointer;
}

.scene-spec-tab.active {
  border-color: #0ea5e9;
  background: rgba(14, 165, 233, 0.16);
  color: #e0f2fe;
}

.scene-spec-summary-strip,
.scene-spec-archive-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.scene-spec-summary-strip article,
.scene-spec-archive-metrics article,
.scene-spec-mini-panel,
.scene-spec-graph-panel,
.scene-spec-archive-main {
  background: #111827;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 12px;
}

.scene-spec-summary-strip article,
.scene-spec-archive-metrics article {
  padding: 14px 16px;
  display: grid;
  gap: 6px;
}

.scene-spec-summary-strip span,
.scene-spec-archive-metrics span,
.scene-spec-section-title,
.scene-spec-eyebrow,
.scene-spec-graph-subtitle,
.scene-spec-card-meta,
.scene-spec-field-meta,
.scene-spec-field-desc,
.scene-spec-request-list span,
.scene-spec-trail-list time {
  color: #94a3b8;
  font-size: 14px;
}

.scene-spec-summary-strip strong,
.scene-spec-archive-metrics strong {
  color: #ffffff;
  font-size: 28px;
  line-height: 1.1;
}

.scene-spec-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  max-height: 56vh;
  overflow: auto;
  scrollbar-gutter: stable;
}

.scene-spec-card,
.scene-spec-hot-item,
.scene-spec-field-item,
.scene-spec-favorite-item,
.scene-spec-note {
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.72);
  color: #e2e8f0;
}

.scene-spec-card {
  min-height: 182px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-align: left;
  cursor: pointer;
}

.scene-spec-card:hover,
.scene-spec-hot-item:hover,
.scene-spec-field-item:hover,
.scene-spec-favorite-item:hover,
.scene-spec-note:hover {
  border-color: rgba(14, 165, 233, 0.35);
  background: rgba(15, 23, 42, 0.95);
}

.scene-spec-card.selected,
.scene-spec-field-item.selected {
  border-color: #0ea5e9;
  box-shadow: 0 0 0 1px rgba(14, 165, 233, 0.15), 0 0 18px rgba(14, 165, 233, 0.12);
  background: rgba(14, 165, 233, 0.1);
}

.scene-spec-card-head,
.scene-spec-graph-head,
.scene-spec-archive-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.scene-spec-kind,
.scene-spec-status,
.scene-spec-favorite {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 12px;
}

.scene-spec-kind {
  background: rgba(14, 165, 233, 0.12);
  color: #7dd3fc;
}

.scene-spec-status.success,
.scene-spec-favorite.active {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
}

.scene-spec-status.warn {
  background: rgba(234, 179, 8, 0.15);
  color: #fbbf24;
}

.scene-spec-status.danger {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
}

.scene-spec-card h3 {
  color: #ffffff;
  font-size: 18px;
  line-height: 1.35;
}

.scene-spec-card p {
  color: #cbd5e1;
  font-size: 14px;
}

.scene-spec-card-meta,
.scene-spec-card-mini {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.scene-spec-card-meta span,
.scene-spec-card-mini span {
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.05);
  display: inline-flex;
  align-items: center;
}

.scene-spec-favorite {
  margin-top: auto;
  align-self: flex-start;
  cursor: pointer;
}

.scene-spec-hot-rank,
.scene-spec-activity-strip {
  margin-top: 16px;
  display: grid;
  gap: 12px;
}

.scene-spec-section-title {
  color: #e2e8f0;
  font-size: 18px;
  font-weight: 600;
}

.scene-spec-hot-list {
  display: grid;
  gap: 10px;
}

.scene-spec-hot-item {
  min-height: 44px;
  padding: 10px 12px;
  display: grid;
  grid-template-columns: 28px 1fr auto;
  gap: 12px;
  align-items: center;
  text-align: left;
  cursor: pointer;
}

.scene-spec-hot-item .rank {
  color: #7dd3fc;
  font-weight: 700;
  font-size: 12px;
}

.scene-spec-hot-item .name {
  color: #f8fafc;
}

.scene-spec-hot-item strong {
  color: #bae6fd;
}

.scene-spec-activity-list {
  display: grid;
  gap: 10px;
}

.scene-spec-activity-list article,
.scene-spec-request-list article,
.scene-spec-trail-list article,
.scene-spec-reference-list article {
  padding: 12px 14px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.72);
}

.scene-spec-activity-list time,
.scene-spec-trail-list time {
  display: block;
  margin-bottom: 4px;
}

.scene-spec-activity-list p,
.scene-spec-trail-list p,
.scene-spec-request-list p {
  color: #cbd5e1;
  font-size: 14px;
}

.scene-spec-archive {
  display: grid;
  gap: 16px;
}

.scene-spec-archive-main {
  padding: 16px;
}

.scene-spec-archive-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.scene-spec-archive-tags span {
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(14, 165, 233, 0.12);
  color: #7dd3fc;
  display: inline-flex;
  align-items: center;
  font-size: 12px;
}

.scene-spec-graph-panel,
.scene-spec-mini-panel {
  padding: 16px;
}

.scene-spec-graph-head {
  margin-bottom: 12px;
}

.scene-spec-graph-flow {
  display: flex;
  gap: 10px;
  align-items: stretch;
  overflow-x: auto;
  padding-bottom: 8px;
  scrollbar-gutter: stable;
}

.scene-spec-flow-node {
  min-width: 160px;
  flex: 0 0 160px;
  min-height: 104px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.9);
  display: flex;
  flex-direction: column;
  gap: 6px;
  text-align: left;
  cursor: pointer;
}

.scene-spec-flow-node span,
.scene-spec-flow-node strong {
  display: block;
}

.scene-spec-flow-node span {
  color: #94a3b8;
  font-size: 12px;
}

.scene-spec-flow-node strong {
  color: #f8fafc;
  font-size: 16px;
  line-height: 1.35;
}

.scene-spec-flow-link {
  width: 42px;
  flex: 0 0 42px;
  align-self: center;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(14, 165, 233, 0.15), rgba(14, 165, 233, 0.85));
}

.scene-spec-flow-node.blue {
  border-color: rgba(56, 189, 248, 0.35);
}

.scene-spec-flow-node.green {
  border-color: rgba(16, 185, 129, 0.35);
}

.scene-spec-flow-node.yellow {
  border-color: rgba(234, 179, 8, 0.35);
}

.scene-spec-flow-node.red {
  border-color: rgba(239, 68, 68, 0.35);
}

.scene-spec-graph-notes {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.scene-spec-note {
  min-height: 40px;
  padding: 8px 12px;
  cursor: pointer;
}

.scene-spec-field-toolbar {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-bottom: 12px;
}

.scene-spec-field-list {
  display: grid;
  gap: 10px;
  max-height: 42vh;
  overflow: auto;
  scrollbar-gutter: stable;
}

.scene-spec-field-item {
  min-height: 94px;
  padding: 12px 14px;
  display: grid;
  gap: 4px;
  text-align: left;
  cursor: pointer;
}

.scene-spec-field-name {
  color: #ffffff;
  font-size: 16px;
  font-weight: 600;
}

.scene-spec-field-meta,
.scene-spec-field-desc {
  color: #94a3b8;
  font-size: 14px;
}

.scene-spec-info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.scene-spec-request-list,
.scene-spec-favorite-list,
.scene-spec-trail-list {
  display: grid;
  gap: 10px;
}

.scene-spec-favorite-item {
  min-height: 72px;
  padding: 12px 14px;
  display: grid;
  gap: 4px;
  text-align: left;
  cursor: pointer;
}

.scene-spec-favorite-item strong,
.scene-spec-request-list strong,
.scene-spec-trail-list strong,
.scene-spec-reference-list strong {
  color: #f8fafc;
}

.scene-spec-trail-panel {
  margin-top: 12px;
}

.scene-spec-empty {
  padding: 24px;
  border: 1px dashed rgba(148, 163, 184, 0.35);
  border-radius: 12px;
  color: #94a3b8;
  text-align: center;
  background: rgba(15, 23, 42, 0.5);
}

.scene-spec-modal {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(2, 6, 23, 0.74);
  backdrop-filter: blur(8px);
}

.scene-spec-modal-card {
  width: min(720px, 96vw);
  display: grid;
  gap: 14px;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  background: #111827;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.45);
}

.scene-spec-modal-card header,
.scene-spec-modal-card footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.scene-spec-modal-body {
  display: grid;
  gap: 12px;
}

.scene-spec-modal-flow,
.scene-spec-reference-list {
  display: grid;
  gap: 10px;
}

.scene-spec-modal-flow {
  grid-template-columns: auto 1fr;
  align-items: center;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.72);
}

.scene-spec-modal-flow span {
  color: #94a3b8;
  font-size: 14px;
}

.scene-spec-modal-flow strong {
  color: #f8fafc;
  font-size: 16px;
}

.scene-spec-modal label {
  display: grid;
  gap: 8px;
  color: #e2e8f0;
  font-size: 16px;
}

.scene-spec-modal-input,
.scene-spec-modal-textarea {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: #0f172a;
  color: #ffffff;
}

.scene-spec-modal-textarea {
  min-height: 120px;
  resize: vertical;
}

.scene-spec-reference-list article {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

@media (max-width: 1400px) {
  .scene-spec-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .scene-spec-info-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 1100px) {
  .scene-spec-summary-strip,
  .scene-spec-archive-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .scene-spec-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .scene-spec-filter-row,
  .scene-spec-archive-head,
  .scene-spec-graph-head {
    display: grid;
    grid-template-columns: 1fr;
  }

  .scene-spec-flow-node {
    min-width: 140px;
    flex-basis: 140px;
  }
}

.task-spec-action-btn {
  min-height: 44px;
  padding: 0 16px;
  border-radius: 8px;
  font-size: 16px;
  line-height: 1.25;
}

.task-spec-filter-row {
  display: grid;
  grid-template-columns: minmax(150px, 0.8fr) minmax(150px, 0.8fr) minmax(260px, 1.5fr);
  gap: 12px;
  width: 100%;
}

.task-spec-filter {
  display: grid;
  gap: 6px;
  min-width: 0;
  color: #cbd5e1;
  font-size: 14px;
}

.task-spec-filter span {
  font-size: 14px;
  color: #94a3b8;
}

.task-spec-filter select,
.task-spec-filter input {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.82);
  color: #f8fafc;
  font-size: 16px;
  outline: none;
}

.task-spec-shell {
  display: grid;
  gap: 16px;
}

.task-spec-summary-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(110px, 1fr));
  gap: 10px;
}

.task-spec-summary-grid article {
  min-height: 82px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  background: rgba(17, 24, 39, 0.76);
}

.task-spec-summary-grid span {
  display: block;
  margin-bottom: 8px;
  color: #94a3b8;
  font-size: 14px;
}

.task-spec-summary-grid strong {
  color: #f8fafc;
  font-size: 22px;
  line-height: 1.2;
}

.task-spec-track-board {
  display: grid;
  gap: 12px;
  max-height: calc(100vh - 318px);
  overflow-y: auto;
  padding-right: 4px;
  scrollbar-gutter: stable;
}

.task-spec-track-row {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  background: rgba(17, 24, 39, 0.72);
  cursor: pointer;
  transition: border-color 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

.task-spec-track-row:hover,
.task-spec-track-row.active {
  border-color: rgba(14, 165, 233, 0.56);
  background: rgba(14, 165, 233, 0.1);
  transform: translateY(-1px);
}

.task-spec-track-head,
.task-spec-track-meta,
.task-spec-track-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
}

.task-spec-track-head h3 {
  margin: 4px 0 0;
  color: #f8fafc;
  font-size: 18px;
  line-height: 1.35;
}

.task-spec-task-id {
  color: #38bdf8;
  font-size: 12px;
  letter-spacing: 0;
}

.task-spec-status {
  flex: none;
  min-width: 72px;
  padding: 5px 9px;
  border-radius: 999px;
  text-align: center;
  font-size: 12px;
  line-height: 1.2;
}

.task-spec-status.active {
  border: 1px solid rgba(16, 185, 129, 0.35);
  color: #86efac;
  background: rgba(16, 185, 129, 0.12);
}

.task-spec-status.archived {
  border: 1px solid rgba(148, 163, 184, 0.3);
  color: #cbd5e1;
  background: rgba(148, 163, 184, 0.12);
}

.task-spec-track-meta {
  flex-wrap: wrap;
  color: #cbd5e1;
  font-size: 14px;
}

.task-spec-track-foot {
  color: #94a3b8;
  font-size: 14px;
}

.task-spec-track-foot strong {
  color: #22d3ee;
  font-size: 18px;
}

.task-spec-stage-rail {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, minmax(92px, 1fr));
  gap: 10px;
  padding-top: 10px;
  overflow-x: auto;
}

.task-spec-stage-rail::before {
  position: absolute;
  top: 26px;
  left: 28px;
  right: 28px;
  height: 2px;
  content: "";
  background: rgba(148, 163, 184, 0.2);
}

.task-spec-stage-rail::after {
  position: absolute;
  top: 26px;
  left: 28px;
  width: calc((100% - 56px) * var(--progress) / 100);
  height: 2px;
  content: "";
  background: #0ea5e9;
  box-shadow: 0 0 14px rgba(14, 165, 233, 0.65);
}

.task-spec-stage-node {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  gap: 6px;
  min-height: 62px;
  border: 0;
  background: transparent;
  color: #94a3b8;
  font-size: 12px;
  cursor: pointer;
}

.task-spec-stage-node i {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border: 1px solid rgba(148, 163, 184, 0.3);
  border-radius: 50%;
  background: #0b0f19;
  color: #cbd5e1;
  font-style: normal;
  font-size: 12px;
}

.task-spec-stage-node.done i {
  border-color: rgba(16, 185, 129, 0.55);
  background: rgba(16, 185, 129, 0.22);
  color: #bbf7d0;
}

.task-spec-stage-node.current i {
  border-color: rgba(14, 165, 233, 0.75);
  background: rgba(14, 165, 233, 0.22);
  color: #e0f2fe;
  box-shadow: 0 0 16px rgba(14, 165, 233, 0.45);
}

.task-spec-detail-shell {
  display: grid;
  gap: 16px;
}

.task-spec-detail-hero,
.task-spec-note-board,
.task-spec-attachment-panel,
.task-spec-timeline-panel,
.task-spec-file-preview {
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  background: rgba(17, 24, 39, 0.76);
}

.task-spec-detail-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 118px;
  align-items: center;
  gap: 16px;
  padding: 16px;
}

.task-spec-detail-hero h2 {
  margin: 4px 0 8px;
  color: #f8fafc;
  font-size: 20px;
  line-height: 1.35;
}

.task-spec-detail-hero p {
  margin: 0;
  color: #cbd5e1;
  font-size: 14px;
  line-height: 1.5;
}

.task-spec-progress-dial {
  display: grid;
  place-items: center;
  width: 108px;
  height: 108px;
  border-radius: 50%;
  background:
    radial-gradient(circle at center, #111827 55%, transparent 56%),
    conic-gradient(#0ea5e9 calc(var(--progress) * 1%), rgba(148, 163, 184, 0.18) 0);
}

.task-spec-progress-dial strong {
  color: #f8fafc;
  font-size: 24px;
  line-height: 1.1;
}

.task-spec-progress-dial span {
  color: #bae6fd;
  font-size: 12px;
}

.task-spec-detail-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.task-spec-detail-grid article {
  min-height: 72px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.74);
}

.task-spec-detail-grid span,
.task-spec-panel-head span,
.task-spec-file-preview dt {
  color: #94a3b8;
  font-size: 14px;
}

.task-spec-detail-grid strong,
.task-spec-file-preview dd {
  color: #f8fafc;
  font-size: 16px;
}

.task-spec-node-path {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.task-spec-node-path span {
  min-height: 44px;
  padding: 10px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 8px;
  color: #94a3b8;
  text-align: center;
  font-size: 14px;
}

.task-spec-node-path .done {
  color: #bbf7d0;
  background: rgba(16, 185, 129, 0.12);
}

.task-spec-node-path .current {
  color: #e0f2fe;
  background: rgba(14, 165, 233, 0.16);
}

.task-spec-panel-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 14px 0;
}

.task-spec-panel-head h3 {
  margin: 0;
  color: #f8fafc;
  font-size: 18px;
  line-height: 1.3;
}

.task-spec-note-board textarea {
  width: calc(100% - 28px);
  min-height: 104px;
  margin: 14px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(11, 15, 25, 0.84);
  color: #f8fafc;
  font-size: 16px;
  line-height: 1.55;
  resize: vertical;
}

.task-spec-note-actions {
  display: flex;
  justify-content: flex-end;
  padding: 0 14px 14px;
}

.task-spec-attachment-panel {
  padding-bottom: 14px;
}

.task-spec-attachment-grid {
  display: grid;
  grid-template-columns: minmax(220px, 0.9fr) minmax(250px, 1fr);
  gap: 12px;
  padding: 14px;
}

.task-spec-attachment-list {
  display: grid;
  gap: 8px;
  max-height: 220px;
  overflow-y: auto;
  scrollbar-gutter: stable;
}

.task-spec-attachment-item {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) 70px;
  align-items: center;
  gap: 8px;
  min-height: 54px;
  padding: 9px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.75);
  color: #f8fafc;
  text-align: left;
  cursor: pointer;
}

.task-spec-attachment-item.active,
.task-spec-attachment-item:hover {
  border-color: rgba(14, 165, 233, 0.5);
  background: rgba(14, 165, 233, 0.12);
}

.task-spec-attachment-item span,
.task-spec-file-preview span {
  color: #38bdf8;
  font-size: 12px;
}

.task-spec-attachment-item strong {
  overflow: hidden;
  color: #f8fafc;
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.task-spec-attachment-item em {
  color: #94a3b8;
  font-style: normal;
  font-size: 12px;
}

.task-spec-file-preview {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.task-spec-file-preview strong {
  color: #f8fafc;
  font-size: 18px;
  line-height: 1.35;
}

.task-spec-file-preview p {
  margin: 0;
  color: #cbd5e1;
  font-size: 14px;
  line-height: 1.5;
}

.task-spec-file-preview dl {
  display: grid;
  gap: 8px;
  margin: 0;
}

.task-spec-file-preview dl div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.task-spec-timeline-list {
  display: grid;
  gap: 10px;
  max-height: 300px;
  overflow-y: auto;
  padding: 14px;
  scrollbar-gutter: stable;
}

.task-spec-timeline-list article {
  display: grid;
  gap: 6px;
  padding: 12px;
  border-left: 3px solid #0ea5e9;
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.78);
}

.task-spec-timeline-list time,
.task-spec-timeline-list strong {
  color: #e0f2fe;
  font-size: 14px;
}

.task-spec-timeline-list p {
  margin: 0;
  color: #cbd5e1;
  font-size: 14px;
  line-height: 1.5;
}

.task-spec-empty {
  min-height: 160px;
  display: grid;
  place-items: center;
  border: 1px dashed rgba(148, 163, 184, 0.3);
  border-radius: 8px;
  color: #94a3b8;
  font-size: 16px;
}

.task-spec-empty-detail {
  min-height: 360px;
}

.task-spec-modal {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(3, 7, 18, 0.72);
  backdrop-filter: blur(12px);
}

.task-spec-modal-card {
  width: min(720px, 100%);
  max-height: min(780px, calc(100vh - 48px));
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  border: 1px solid rgba(14, 165, 233, 0.28);
  border-radius: 8px;
  background: #111827;
  box-shadow: 0 24px 72px rgba(0, 0, 0, 0.45);
}

.task-spec-modal-card header,
.task-spec-modal-card footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.task-spec-modal-card footer {
  justify-content: flex-end;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  border-bottom: 0;
}

.task-spec-modal-card h2 {
  margin: 0;
  color: #f8fafc;
  font-size: 20px;
}

.task-spec-modal-card p {
  margin: 6px 0 0;
  color: #94a3b8;
  font-size: 14px;
}

.task-spec-modal-close {
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.85);
  color: #cbd5e1;
  font-size: 16px;
  cursor: pointer;
}

.task-spec-modal-body {
  display: grid;
  gap: 14px;
  overflow-y: auto;
  padding: 16px;
}

.task-spec-modal-body label {
  display: grid;
  gap: 8px;
  color: #cbd5e1;
  font-size: 16px;
}

.task-spec-modal-body input,
.task-spec-modal-body select,
.task-spec-modal-body textarea {
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(11, 15, 25, 0.88);
  color: #f8fafc;
  font-size: 16px;
}

.task-spec-modal-body textarea {
  min-height: 110px;
  resize: vertical;
}

.task-spec-file-meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.task-spec-file-meta div {
  display: grid;
  gap: 6px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.78);
}

.task-spec-file-meta .wide {
  grid-column: 1 / -1;
}

.task-spec-file-meta span {
  color: #94a3b8;
  font-size: 14px;
}

.task-spec-file-meta strong,
.task-spec-file-meta p {
  margin: 0;
  color: #f8fafc;
  font-size: 16px;
  line-height: 1.5;
}

@media (max-width: 1280px) {
  .task-spec-summary-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .task-spec-detail-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .task-spec-attachment-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .task-spec-filter-row,
  .task-spec-detail-hero,
  .task-spec-file-meta {
    grid-template-columns: 1fr;
  }

  .task-spec-summary-grid,
  .task-spec-detail-grid,
  .task-spec-node-path {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .task-spec-track-head,
  .task-spec-track-meta,
  .task-spec-track-foot {
    align-items: flex-start;
    flex-direction: column;
  }
}

/* Trends Module */
.trends-spec-filter-row {
  display: grid;
  grid-template-columns: minmax(140px, 180px) minmax(180px, 1fr) minmax(180px, 1fr) minmax(140px, 170px);
  gap: 12px;
  width: 100%;
}

.trends-spec-filter {
  display: grid;
  gap: 8px;
}

.trends-spec-filter > span {
  font-size: 14px;
  line-height: 1.35;
  color: #94adc0;
}

.trends-spec-filter select {
  min-height: 44px;
  padding: 0 14px;
  border-radius: 8px;
  border: 1px solid rgba(72, 189, 238, 0.22);
  background: #102131;
  color: #eef7fd;
  font-size: 16px;
  outline: none;
}

.trends-spec-segment {
  display: flex;
  gap: 8px;
  align-items: center;
  min-height: 44px;
}

.trends-spec-segment button,
.trends-spec-switch button,
.trends-spec-action-btn {
  min-height: 44px;
  padding: 0 14px;
  border-radius: 8px;
  border: 1px solid rgba(72, 189, 238, 0.24);
  background: #102131;
  color: #ecf8ff;
  font-size: 16px;
  cursor: pointer;
}

.trends-spec-segment button.active,
.trends-spec-switch button.active {
  border-color: rgba(14, 165, 233, 0.72);
  background: linear-gradient(135deg, rgba(16, 145, 225, 0.94), rgba(69, 94, 225, 0.92));
}

.trends-spec-switch {
  align-content: end;
}

.trends-spec-summary-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.trends-spec-stat,
.trends-spec-conclusion,
.trends-spec-tip,
.trends-spec-chart-card,
.trends-spec-record-card {
  border: 1px solid rgba(88, 193, 240, 0.14);
  border-radius: 10px;
  background: linear-gradient(160deg, #111827 0%, #0f1e2d 100%);
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.18);
}

.trends-spec-stat {
  min-height: 88px;
  padding: 14px;
  display: grid;
  gap: 8px;
  align-content: center;
}

.trends-spec-stat span {
  font-size: 14px;
  line-height: 1.35;
  color: #9db7c9;
}

.trends-spec-stat strong {
  font-size: 22px;
  line-height: 1.2;
  color: #f6fbff;
}

.trends-spec-stat.up strong { color: #7cf4cf; }
.trends-spec-stat.down strong { color: #ffb39a; }
.trends-spec-stat.warn strong { color: #ffd582; }
.trends-spec-stat.calm strong { color: #7deaff; }
.trends-spec-stat.peak strong { color: #b9a6ff; }

.trends-spec-conclusion,
.trends-spec-tip {
  margin-top: 12px;
  padding: 16px;
}

.trends-spec-conclusion header,
.trends-spec-chart-head,
.trends-spec-record-card header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.trends-spec-conclusion h3,
.trends-spec-tip h3,
.trends-spec-chart-head h3,
.trends-spec-record-card h3 {
  margin: 0;
  font-size: 18px;
  line-height: 1.35;
  color: #f7fbff;
}

.trends-spec-conclusion header span,
.trends-spec-chart-head p,
.trends-spec-record-card header span {
  font-size: 14px;
  line-height: 1.45;
  color: #93afc2;
}

.trends-spec-conclusion p {
  margin: 12px 0 0;
  font-size: 16px;
  line-height: 1.65;
  color: #dff2fb;
}

.trends-spec-conclusion-list {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.trends-spec-conclusion-list article {
  display: grid;
  gap: 4px;
  padding: 12px 14px;
  border-radius: 8px;
  border: 1px solid rgba(72, 189, 238, 0.12);
  background: rgba(9, 22, 35, 0.9);
}

.trends-spec-conclusion-list b {
  font-size: 14px;
  line-height: 1.35;
  color: #f4fbff;
}

.trends-spec-conclusion-list span,
.trends-spec-tip span {
  font-size: 14px;
  line-height: 1.55;
  color: #9eb8ca;
}

.trends-spec-tip div {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.trends-spec-workspace {
  display: grid;
  gap: 12px;
}

.trends-spec-chart-card,
.trends-spec-record-card {
  padding: 16px;
}

.trends-spec-chart {
  width: 100%;
  height: 340px;
  display: block;
  margin-top: 10px;
  background:
    linear-gradient(180deg, rgba(12, 25, 41, 0.9), rgba(8, 18, 31, 0.92)),
    repeating-linear-gradient(90deg, rgba(85, 191, 239, 0.05) 0 1px, transparent 1px 68px);
  border-radius: 10px;
  overflow: hidden;
}

.trends-spec-grid-line {
  stroke: rgba(127, 177, 202, 0.14);
  stroke-width: 1;
}

.trends-spec-fill.primary {
  fill: url(#trends-primary-fill);
}

.trends-spec-line {
  fill: none;
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.trends-spec-line.primary {
  stroke: #38bdf8;
  filter: drop-shadow(0 0 10px rgba(56, 189, 248, 0.35));
}

.trends-spec-line.secondary {
  stroke: #a78bfa;
  filter: drop-shadow(0 0 10px rgba(167, 139, 250, 0.35));
}

.trends-spec-point {
  cursor: pointer;
}

.trends-spec-point.primary {
  fill: #38bdf8;
  stroke: rgba(255, 255, 255, 0.72);
  stroke-width: 1.5;
}

.trends-spec-point.secondary {
  fill: #a78bfa;
  stroke: rgba(255, 255, 255, 0.72);
  stroke-width: 1.5;
}

.trends-spec-point.peak {
  stroke: #fef08a;
  stroke-width: 2;
  filter: drop-shadow(0 0 10px rgba(254, 240, 138, 0.4));
}

.trends-spec-axis-title,
.trends-spec-axis-label {
  fill: #8eaac0;
  font-size: 12px;
}

.trends-spec-axis-title.right,
.trends-spec-axis-label.right {
  text-anchor: end;
}

.trends-spec-axis-row {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 8px;
  margin-top: 10px;
}

.trends-spec-axis-row span {
  font-size: 12px;
  line-height: 1.35;
  color: #90a9bb;
  text-align: center;
}

.trends-spec-record-list {
  display: grid;
  gap: 8px;
  max-height: 520px;
  overflow-y: auto;
  scrollbar-gutter: stable;
  margin-top: 12px;
}

.trends-spec-record {
  display: grid;
  grid-template-columns: 128px 84px 92px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  min-height: 58px;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid rgba(88, 193, 240, 0.12);
  background: rgba(10, 24, 38, 0.84);
  color: #eef8ff;
  text-align: left;
  cursor: pointer;
}

.trends-spec-record.active,
.trends-spec-record:hover {
  border-color: rgba(14, 165, 233, 0.74);
  background: rgba(16, 45, 70, 0.92);
}

.trends-spec-record span,
.trends-spec-record strong,
.trends-spec-record em,
.trends-spec-record b {
  font-style: normal;
  font-size: 14px;
  line-height: 1.35;
}

.trends-spec-record span,
.trends-spec-record em {
  color: #9eb8ca;
}

.trends-spec-record strong {
  color: #7cf4cf;
}

.trends-spec-modal {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(2, 8, 20, 0.72);
  backdrop-filter: blur(8px);
}

.trends-spec-modal-card {
  width: min(740px, 100%);
  border-radius: 10px;
  border: 1px solid rgba(88, 193, 240, 0.24);
  background: linear-gradient(160deg, #111827 0%, #0f1e2d 100%);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.44);
  padding: 16px;
}

.trends-spec-modal-card header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.trends-spec-modal-close {
  min-height: 40px;
  padding: 0 14px;
  border-radius: 8px;
  border: 1px solid rgba(88, 193, 240, 0.18);
  background: #102131;
  color: #eef7fd;
  font-size: 14px;
  cursor: pointer;
}

.trends-spec-modal-body {
  display: grid;
  gap: 12px;
  margin-top: 14px;
}

.trends-spec-modal-info {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
}

.trends-spec-modal-info span {
  font-size: 14px;
  line-height: 1.45;
  color: #8ba8bc;
}

.trends-spec-modal-info strong {
  font-size: 16px;
  line-height: 1.45;
  color: #f6fbff;
  word-break: break-word;
}

.trends-spec-modal-packet {
  margin: 0;
  padding: 14px;
  border-radius: 8px;
  border: 1px solid rgba(88, 193, 240, 0.12);
  background: rgba(9, 18, 28, 0.94);
  color: #dff2fb;
  font-size: 14px;
  line-height: 1.6;
  overflow: auto;
  max-height: 300px;
}

@media (max-width: 1280px) {
  .trends-spec-filter-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .trends-spec-summary-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 980px) {
  .trends-spec-filter-row {
    grid-template-columns: 1fr;
  }

  .trends-spec-summary-strip {
    grid-template-columns: 1fr;
  }

  .trends-spec-record {
    grid-template-columns: 1fr;
    gap: 6px;
  }
}

.topo-spec-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.topo-spec-strip article,
.topo-spec-hero,
.topo-spec-detail-shell {
  background: #111827;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 12px;
}

.topo-spec-strip article {
  padding: 14px 16px;
  display: grid;
  gap: 6px;
}

.topo-spec-strip span,
.topo-spec-eyebrow,
.topo-spec-detail-grid span,
.topo-spec-detail-grid p,
.topo-spec-lane-grid time,
.topo-spec-lane-grid p,
.topo-spec-chart-head span {
  color: #94a3b8;
  font-size: 14px;
}

.topo-spec-strip strong {
  color: #f8fafc;
  font-size: 28px;
  line-height: 1.1;
}

.topo-spec-hero {
  padding: 16px;
  display: grid;
  gap: 16px;
}

.topo-spec-hero-copy h2,
.topo-spec-detail-head h2 {
  color: #ffffff;
  font-size: 22px;
  line-height: 1.3;
}

.topo-spec-hero-copy p {
  margin-top: 8px;
  color: #cbd5e1;
  font-size: 14px;
}

.topo-spec-hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.topo-spec-hero-stats article {
  min-height: 78px;
  padding: 12px 14px;
  display: grid;
  gap: 6px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.72);
}

.topo-spec-hero-stats strong {
  color: #e0f2fe;
  font-size: 24px;
}

.topo-spec-canvas {
  position: relative;
  min-height: 520px;
  padding: 14px;
  margin-top: 16px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  background:
    linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px),
    #0f172a;
  background-size: 36px 36px;
  overflow: hidden;
}

.topo-spec-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.topo-spec-node-layer {
  position: relative;
  z-index: 2;
  min-height: 490px;
}

.topo-spec-node {
  position: absolute;
  width: 190px;
  min-height: 122px;
  padding: 14px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(17, 24, 39, 0.9);
  display: grid;
  gap: 6px;
  text-align: left;
  cursor: pointer;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.25);
}

.topo-spec-node.active {
  border-color: #0ea5e9;
  box-shadow: 0 0 0 1px rgba(14, 165, 233, 0.2), 0 0 20px rgba(14, 165, 233, 0.15);
}

.topo-spec-node:nth-child(1) { left: 2%; top: 46%; }
.topo-spec-node:nth-child(2) { left: 25%; top: 22%; }
.topo-spec-node:nth-child(3) { left: 54%; top: 40%; }
.topo-spec-node:nth-child(4) { left: 79%; top: 18%; }

.topo-spec-node-type {
  color: #7dd3fc;
  font-size: 12px;
}

.topo-spec-node strong {
  color: #ffffff;
  font-size: 18px;
  line-height: 1.3;
}

.topo-spec-node em {
  color: #34d399;
  font-size: 12px;
  font-style: normal;
}

.topo-spec-node small {
  color: #cbd5e1;
  font-size: 14px;
  line-height: 1.45;
}

.topo-spec-detail-shell {
  padding: 16px;
  display: grid;
  gap: 14px;
  min-height: 100%;
}

.topo-spec-detail-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.topo-spec-node-status {
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  font-size: 12px;
}

.topo-spec-node-status.green {
  background: rgba(16, 185, 129, 0.16);
  color: #34d399;
}

.topo-spec-node-status.orange {
  background: rgba(245, 158, 11, 0.16);
  color: #fbbf24;
}

.topo-spec-detail-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.topo-spec-detail-metrics article,
.topo-spec-detail-grid article {
  padding: 12px 14px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.72);
  display: grid;
  gap: 6px;
}

.topo-spec-detail-metrics strong {
  color: #e0f2fe;
  font-size: 24px;
  line-height: 1.1;
}

.topo-spec-detail-chart {
  padding: 14px;
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.topo-spec-chart-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.topo-spec-chart-head strong {
  color: #f8fafc;
  font-size: 16px;
}

.topo-spec-bars {
  display: grid;
  grid-template-columns: repeat(24, minmax(0, 1fr));
  gap: 6px;
  align-items: end;
  min-height: 180px;
}

.topo-spec-bar {
  display: grid;
  gap: 8px;
  align-items: end;
  justify-items: center;
  min-height: 180px;
  background: transparent;
  border: none;
  color: #94a3b8;
  cursor: pointer;
}

.topo-spec-bar span {
  width: 100%;
  min-height: 26px;
  border-radius: 8px 8px 4px 4px;
  background: linear-gradient(180deg, rgba(14, 165, 233, 0.28), rgba(14, 165, 233, 0.88));
  box-shadow: 0 0 16px rgba(14, 165, 233, 0.2);
}

.topo-spec-bar.active span {
  background: linear-gradient(180deg, rgba(16, 185, 129, 0.3), rgba(16, 185, 129, 0.98));
}

.topo-spec-bar em {
  font-style: normal;
  font-size: 12px;
  line-height: 1;
}

.topo-spec-chart-labels {
  display: grid;
  grid-template-columns: repeat(24, minmax(0, 1fr));
  gap: 6px;
  margin-top: 10px;
}

.topo-spec-chart-labels span {
  min-height: 18px;
  color: #64748b;
  font-size: 12px;
  text-align: center;
}

.topo-spec-detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.topo-spec-detail-grid p {
  color: #cbd5e1;
  font-size: 14px;
}

.topo-spec-detail-activity {
  display: grid;
  gap: 10px;
}

.topo-spec-log-list,
.topo-spec-lane-grid {
  display: grid;
  gap: 10px;
}

.topo-spec-log-list {
  max-height: 220px;
  overflow-y: auto;
  scrollbar-gutter: stable;
}

.topo-spec-log-list article,
.topo-spec-lane-grid article {
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(15, 23, 42, 0.72);
}

.topo-spec-log-list time,
.topo-spec-lane-grid time {
  display: block;
  margin-bottom: 4px;
}

.topo-spec-log-list p,
.topo-spec-lane-grid p {
  color: #cbd5e1;
  font-size: 14px;
}

.topo-spec-modal {
  position: fixed;
  inset: 0;
  z-index: 2100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(2, 6, 23, 0.74);
  backdrop-filter: blur(8px);
}

.topo-spec-modal-card {
  width: min(680px, 96vw);
  padding: 18px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: #111827;
  display: grid;
  gap: 14px;
}

.topo-spec-modal-card header,
.topo-spec-modal-card footer {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.topo-spec-modal-card pre {
  margin: 0;
  padding: 14px;
  border-radius: 12px;
  background: #0f172a;
  color: #cbd5e1;
  font-size: 14px;
  overflow: auto;
}

@media (max-width: 1400px) {
  .topo-spec-strip,
  .topo-spec-detail-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .topo-spec-detail-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 1100px) {
  .topo-spec-node {
    position: relative;
    left: auto !important;
    top: auto !important;
    width: 100%;
  }

  .topo-spec-node-layer {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }

  .topo-spec-canvas {
    min-height: auto;
  }

  .topo-spec-svg {
    display: none;
  }

  .topo-spec-bars {
    grid-template-columns: repeat(12, minmax(0, 1fr));
  }

  .topo-spec-chart-labels {
    grid-template-columns: repeat(12, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .topo-spec-strip,
  .topo-spec-detail-metrics,
  .topo-spec-hero-stats,
  .topo-spec-node-layer {
    grid-template-columns: 1fr;
  }

  .topo-spec-bars {
    grid-template-columns: repeat(8, minmax(0, 1fr));
  }

  .topo-spec-chart-labels {
    grid-template-columns: repeat(8, minmax(0, 1fr));
  }
}

.reports-spec-filter-row {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 12px;
}

.reports-spec-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.reports-spec-summary article,
.reports-spec-template-card,
.reports-spec-report-card,
.reports-spec-preview-paper,
.reports-spec-assembly-panel,
.reports-spec-compare-shell {
  background: #111827;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 12px;
}

.reports-spec-summary article {
  padding: 14px 16px;
  display: grid;
  gap: 6px;
}

.reports-spec-summary span,
.reports-spec-template-card span,
.reports-spec-template-card p,
.reports-spec-card-meta span,
.reports-spec-card-head span,
.reports-spec-preview-paper header span,
.reports-spec-preview-paper header p,
.reports-spec-assembly-panel dt,
.reports-spec-compare-toolbar span,
.reports-spec-compare-grid header span,
.reports-spec-compare-grid header p,
.reports-spec-diff-panel span {
  color: #94a3b8;
  font-size: 14px;
}

.reports-spec-summary strong {
  color: #ffffff;
  font-size: 28px;
  line-height: 1.1;
}

.reports-spec-section-title {
  color: #f8fafc;
  font-size: 18px;
  line-height: 1.35;
  font-weight: 700;
}

.reports-spec-template-shelf,
.reports-spec-library {
  margin-top: 16px;
  display: grid;
  gap: 12px;
}

.reports-spec-template-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.reports-spec-template-card,
.reports-spec-report-card {
  padding: 14px;
  display: grid;
  gap: 8px;
  text-align: left;
  color: #e2e8f0;
  cursor: pointer;
}

.reports-spec-template-card {
  min-height: 146px;
}

.reports-spec-template-card.active,
.reports-spec-report-card.active {
  border-color: #0ea5e9;
  background: rgba(14, 165, 233, 0.1);
  box-shadow: 0 0 18px rgba(14, 165, 233, 0.12);
}

.reports-spec-template-card strong,
.reports-spec-report-card strong {
  color: #ffffff;
  font-size: 17px;
  line-height: 1.35;
}

.reports-spec-report-list {
  max-height: 48vh;
  overflow-y: auto;
  scrollbar-gutter: stable;
  display: grid;
  gap: 10px;
}

.reports-spec-card-head,
.reports-spec-card-meta,
.reports-spec-mode-tabs,
.reports-spec-preview-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.reports-spec-card-head {
  justify-content: space-between;
}

.reports-spec-card-head em {
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(14, 165, 233, 0.12);
  color: #7dd3fc;
  font-size: 12px;
  font-style: normal;
  display: inline-flex;
  align-items: center;
}

.reports-spec-report-card p {
  color: #cbd5e1;
  font-size: 14px;
  line-height: 1.45;
}

.reports-spec-card-meta span,
.reports-spec-preview-tags span,
.reports-spec-modal-sections span {
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.05);
  display: inline-flex;
  align-items: center;
}

.reports-spec-mode-tabs {
  padding: 4px;
  border: 1px solid rgba(56, 189, 248, 0.24);
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.72);
}

.reports-spec-mode-tabs button {
  min-height: 36px;
  padding: 0 14px;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: #cbd5e1;
  cursor: pointer;
}

.reports-spec-mode-tabs button.active {
  background: rgba(14, 165, 233, 0.18);
  color: #e0f2fe;
}

.reports-spec-preview-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(260px, 0.55fr);
  gap: 16px;
  align-items: start;
}

.reports-spec-preview-paper {
  padding: 22px;
  min-height: 680px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.035), transparent 170px),
    #111827;
}

.reports-spec-preview-paper header {
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.reports-spec-preview-paper header h2,
.reports-spec-compare-grid h2,
.reports-spec-modal-card h2 {
  color: #ffffff;
  font-size: 22px;
  line-height: 1.35;
}

.reports-spec-preview-score {
  margin-top: 18px;
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 18px;
  align-items: center;
}

.reports-spec-score-ring {
  width: 132px;
  aspect-ratio: 1;
  border-radius: 50%;
  background: conic-gradient(#0ea5e9 var(--score), rgba(255,255,255,0.07) 0);
  display: grid;
  place-items: center;
  position: relative;
}

.reports-spec-score-ring::after {
  content: "";
  position: absolute;
  inset: 12px;
  border-radius: 50%;
  background: #111827;
}

.reports-spec-score-ring strong,
.reports-spec-score-ring span {
  position: relative;
  z-index: 1;
}

.reports-spec-score-ring strong {
  color: #ffffff;
  font-size: 30px;
  line-height: 1;
}

.reports-spec-score-ring span {
  color: #94a3b8;
  font-size: 12px;
}

.reports-spec-preview-score h3 {
  color: #f8fafc;
  font-size: 20px;
  margin-bottom: 8px;
}

.reports-spec-preview-score p,
.reports-spec-outline p,
.reports-spec-compare-grid p {
  color: #cbd5e1;
  font-size: 16px;
  line-height: 1.65;
}

.reports-spec-preview-tags {
  margin-top: 16px;
}

.reports-spec-outline {
  margin-top: 20px;
  display: grid;
  gap: 14px;
}

.reports-spec-outline article {
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 14px;
  padding: 14px;
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.reports-spec-outline article > span {
  color: #7dd3fc;
  font-size: 18px;
  font-weight: 700;
}

.reports-spec-outline strong {
  color: #ffffff;
  font-size: 18px;
}

.reports-spec-assembly-panel {
  padding: 16px;
  display: grid;
  gap: 14px;
  position: sticky;
  top: 0;
}

.reports-spec-assembly-panel dl {
  display: grid;
  gap: 10px;
}

.reports-spec-assembly-panel dl div {
  padding: 12px;
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.72);
  display: grid;
  gap: 4px;
}

.reports-spec-assembly-panel dd {
  color: #f8fafc;
  font-size: 16px;
}

.reports-spec-compare-shell {
  padding: 16px;
  display: grid;
  gap: 16px;
}

.reports-spec-compare-toolbar {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 12px;
  align-items: center;
}

.reports-spec-compare-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.reports-spec-compare-grid article {
  padding: 16px;
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.05);
  display: grid;
  gap: 14px;
}

.reports-spec-compare-score {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
  align-items: center;
}

.reports-spec-compare-score strong {
  color: #e0f2fe;
  font-size: 32px;
}

.reports-spec-diff-panel {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.reports-spec-diff-panel article {
  padding: 14px;
  border-radius: 10px;
  background: rgba(14, 165, 233, 0.09);
  border: 1px solid rgba(14, 165, 233, 0.22);
  display: grid;
  gap: 6px;
}

.reports-spec-diff-panel strong {
  color: #ffffff;
  font-size: 24px;
}

.reports-spec-modal {
  position: fixed;
  inset: 0;
  z-index: 2200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(2, 6, 23, 0.74);
  backdrop-filter: blur(8px);
}

.reports-spec-modal-card {
  width: min(760px, 96vw);
  padding: 18px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: #111827;
  display: grid;
  gap: 14px;
}

.reports-spec-modal-card header,
.reports-spec-modal-card footer {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.reports-spec-modal-body {
  display: grid;
  gap: 12px;
}

.reports-spec-modal-body label {
  display: grid;
  gap: 8px;
  color: #e2e8f0;
  font-size: 16px;
}

.reports-spec-modal-body input,
.reports-spec-modal-body select,
.reports-spec-modal-body textarea {
  min-height: 44px;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: #0f172a;
  color: #ffffff;
  font-size: 16px;
}

.reports-spec-modal-body textarea {
  min-height: 130px;
  resize: vertical;
}

.reports-spec-modal-sections {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.reports-spec-empty {
  padding: 28px;
  border: 1px dashed rgba(148, 163, 184, 0.35);
  border-radius: 12px;
  color: #94a3b8;
  text-align: center;
  background: rgba(15, 23, 42, 0.5);
}

@media (max-width: 1400px) {
  .reports-spec-preview-shell,
  .reports-spec-compare-grid {
    grid-template-columns: 1fr;
  }

  .reports-spec-assembly-panel {
    position: static;
  }
}

@media (max-width: 1000px) {
  .reports-spec-filter-row,
  .reports-spec-summary,
  .reports-spec-template-grid,
  .reports-spec-diff-panel,
  .reports-spec-compare-toolbar {
    grid-template-columns: 1fr;
  }

  .reports-spec-preview-score {
    grid-template-columns: 1fr;
  }
}

.anm-spec-filter-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.anm-spec-filter {
  display: grid;
  gap: 8px;
}

.anm-spec-filter span {
  color: #94a3b8;
  font-size: 14px;
  line-height: 1.4;
}

.anm-spec-filter select,
.anm-spec-filter input,
.anm-spec-modal-field select,
.anm-spec-modal-field textarea {
  width: 100%;
  min-height: 44px;
  padding: 11px 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.88);
  color: #f8fafc;
  font-size: 16px;
  line-height: 1.4;
  outline: none;
}

.anm-spec-filter input:focus,
.anm-spec-filter select:focus,
.anm-spec-modal-field select:focus,
.anm-spec-modal-field textarea:focus {
  border-color: rgba(14, 165, 233, 0.7);
  box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.14);
}

.anm-spec-summary-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.anm-spec-summary-grid article {
  min-height: 92px;
  display: grid;
  align-content: space-between;
  gap: 10px;
  padding: 14px 16px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.78);
}

.anm-spec-summary-grid span {
  color: #94a3b8;
  font-size: 14px;
  line-height: 1.35;
}

.anm-spec-summary-grid b {
  color: #f8fafc;
  font-size: 28px;
  line-height: 1;
}

.anm-spec-level-rail {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.anm-spec-level-chip {
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.76);
  color: #cbd5e1;
  font-size: 14px;
}

.anm-spec-level-chip.active {
  border-color: rgba(14, 165, 233, 0.75);
  background: rgba(14, 165, 233, 0.14);
  color: #e0f2fe;
  box-shadow: 0 0 20px rgba(14, 165, 233, 0.16);
}

.anm-spec-event-stream {
  display: grid;
  gap: 12px;
  max-height: 50vh;
  overflow-y: auto;
  scrollbar-gutter: stable;
  margin-top: 14px;
  padding-right: 4px;
}

.anm-spec-event-card,
.anm-spec-detail,
.anm-spec-snapshot,
.anm-spec-timeline,
.anm-spec-recent-actions {
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.86);
  box-shadow: 0 16px 42px rgba(0, 0, 0, 0.22);
}

.anm-spec-event-card {
  position: relative;
  display: grid;
  gap: 8px;
  padding: 16px 16px 14px;
  cursor: pointer;
}

.anm-spec-event-card.active {
  border-color: rgba(14, 165, 233, 0.7);
  box-shadow: 0 0 24px rgba(14, 165, 233, 0.14);
}

.anm-spec-event-card.critical {
  border-color: rgba(239, 68, 68, 0.28);
}

.anm-spec-event-card.warning {
  border-color: rgba(234, 179, 8, 0.28);
}

.anm-spec-event-head,
.anm-spec-detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.anm-spec-code {
  color: #94a3b8;
  font-size: 12px;
  line-height: 1.3;
}

.anm-spec-badge,
.anm-spec-status-chip {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}

.anm-spec-badge.critical,
.anm-spec-status-chip.critical {
  background: rgba(239, 68, 68, 0.16);
  color: #fca5a5;
}

.anm-spec-badge.warning,
.anm-spec-status-chip.warning {
  background: rgba(234, 179, 8, 0.16);
  color: #facc15;
}

.anm-spec-badge.normal,
.anm-spec-status-chip.normal {
  background: rgba(16, 185, 129, 0.16);
  color: #6ee7b7;
}

.anm-spec-event-card h3,
.anm-spec-detail h3 {
  margin: 0;
  color: #f8fafc;
  font-size: 20px;
  line-height: 1.35;
}

.anm-spec-event-card p,
.anm-spec-detail p {
  margin: 0;
  color: #cbd5e1;
  font-size: 14px;
  line-height: 1.5;
}

.anm-spec-event-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  color: #94a3b8;
  font-size: 12px;
}

.anm-spec-event-action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.anm-spec-event-action-row .ghost-button,
.anm-spec-panel-head .ghost-button {
  min-height: 40px;
}

.anm-spec-event-notes {
  display: grid;
  gap: 8px;
}

.anm-spec-event-notes article,
.anm-spec-timeline article,
.anm-spec-recent-actions article {
  padding: 12px 14px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  background: rgba(11, 15, 25, 0.72);
}

.anm-spec-event-notes span,
.anm-spec-timeline time,
.anm-spec-recent-actions time {
  color: #94a3b8;
  font-size: 12px;
}

.anm-spec-event-notes b,
.anm-spec-timeline b,
.anm-spec-recent-actions b {
  display: block;
  margin-top: 4px;
  color: #f8fafc;
  font-size: 15px;
  line-height: 1.35;
}

.anm-spec-event-notes p,
.anm-spec-timeline p,
.anm-spec-recent-actions p {
  margin-top: 4px;
  color: #cbd5e1;
  font-size: 14px;
}

.anm-spec-event-card i {
  position: absolute;
  top: 14px;
  right: 14px;
  color: rgba(148, 163, 184, 0.75);
  font-size: 12px;
  font-style: normal;
}

.anm-spec-detail {
  display: grid;
  gap: 16px;
  padding: 18px;
}

.anm-spec-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 12px;
}

.anm-spec-detail-grid p {
  margin: 0;
  padding: 12px 14px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  background: rgba(11, 15, 25, 0.72);
}

.anm-spec-detail-grid span {
  display: block;
  color: #94a3b8;
  font-size: 12px;
  line-height: 1.35;
}

.anm-spec-detail-grid b {
  display: block;
  margin-top: 6px;
  color: #f8fafc;
  font-size: 16px;
  line-height: 1.45;
}

.anm-spec-snapshot,
.anm-spec-timeline,
.anm-spec-recent-actions {
  padding: 16px;
}

.anm-spec-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.anm-spec-panel-head h2 {
  margin: 0;
  color: #f8fafc;
  font-size: 20px;
  line-height: 1.35;
}

.anm-spec-panel-head span {
  color: #94a3b8;
  font-size: 14px;
}

.anm-spec-snapshot-wall {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.anm-spec-gauge {
  min-height: 94px;
  display: grid;
  align-content: space-between;
  gap: 8px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 10px;
}

.anm-spec-gauge span {
  color: #94a3b8;
  font-size: 12px;
  line-height: 1.35;
}

.anm-spec-gauge b {
  color: #f8fafc;
  font-size: 30px;
  line-height: 1;
}

.anm-spec-gauge small {
  color: #94a3b8;
  font-size: 12px;
}

.anm-spec-red {
  box-shadow: 0 0 22px rgba(239, 68, 68, 0.14);
}

.anm-spec-yellow {
  box-shadow: 0 0 22px rgba(234, 179, 8, 0.14);
}

.anm-spec-green {
  box-shadow: 0 0 22px rgba(16, 185, 129, 0.14);
}

.anm-spec-blue {
  box-shadow: 0 0 22px rgba(14, 165, 233, 0.14);
}

.anm-spec-signal-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 14px 0 12px;
}

.anm-spec-signal-strip span {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border: 1px solid rgba(14, 165, 233, 0.22);
  border-radius: 999px;
  background: rgba(14, 165, 233, 0.08);
  color: #bae6fd;
  font-size: 12px;
}

.anm-spec-mini-chart {
  height: 170px;
  display: flex;
  align-items: flex-end;
  gap: 6px;
  padding-top: 18px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.22);
}

.anm-spec-mini-bar {
  flex: 1;
  min-width: 12px;
  min-height: 18px;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  border: 0;
  border-radius: 8px 8px 0 0;
  background: linear-gradient(180deg, #10b981, rgba(16, 185, 129, 0.22));
}

.anm-spec-mini-bar.warn {
  background: linear-gradient(180deg, #eab308, rgba(234, 179, 8, 0.24));
}

.anm-spec-mini-bar.danger {
  background: linear-gradient(180deg, #ef4444, rgba(239, 68, 68, 0.24));
}

.anm-spec-mini-bar span {
  margin-top: -22px;
  color: #cbd5e1;
  font-size: 12px;
  line-height: 1;
}

.anm-spec-timeline,
.anm-spec-recent-actions {
  display: grid;
  gap: 10px;
}

.anm-spec-timeline {
  max-height: 260px;
  overflow-y: auto;
  scrollbar-gutter: stable;
}

.anm-spec-recent-actions {
  max-height: 220px;
  overflow-y: auto;
  scrollbar-gutter: stable;
}

.anm-spec-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(2, 6, 23, 0.74);
  backdrop-filter: blur(10px);
}

.anm-spec-modal-card {
  width: min(620px, 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  background: #111827;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.42);
  overflow: hidden;
}

.anm-spec-modal-card header,
.anm-spec-modal-card footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.anm-spec-modal-card footer {
  justify-content: flex-end;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  border-bottom: 0;
}

.anm-spec-modal-card h2 {
  margin: 4px 0 0;
  color: #f8fafc;
  font-size: 20px;
}

.anm-spec-modal-card header span {
  color: #94a3b8;
  font-size: 14px;
}

.anm-spec-close {
  width: 40px;
  height: 40px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.82);
  color: #e2e8f0;
  font-size: 24px;
}

.anm-spec-modal-body {
  display: grid;
  gap: 14px;
  padding: 18px;
}

.anm-spec-modal-summary {
  display: grid;
  gap: 6px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.72);
}

.anm-spec-modal-summary p {
  margin: 0;
  color: #cbd5e1;
  font-size: 14px;
  line-height: 1.5;
}

.anm-spec-modal-summary b {
  color: #f8fafc;
  font-size: 16px;
}

.anm-spec-modal-field {
  display: grid;
  gap: 8px;
}

.anm-spec-modal-field span {
  color: #94a3b8;
  font-size: 14px;
}

.anm-spec-modal-field textarea {
  min-height: 132px;
  resize: vertical;
}

@media (max-width: 1400px) {
  .anm-spec-summary-grid,
  .anm-spec-snapshot-wall {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 1100px) {
  .anm-spec-filter-row,
  .anm-spec-summary-grid,
  .anm-spec-detail-grid,
  .anm-spec-snapshot-wall {
    grid-template-columns: 1fr;
  }

  .anm-spec-event-stream {
    max-height: none;
  }
}

@media (max-width: 900px) {
  .anm-spec-filter-row {
    grid-template-columns: 1fr;
  }
}

.appr-spec-action-btn {
  min-height: 44px;
  padding: 0 16px;
  border-radius: 8px;
  font-size: 16px;
  white-space: nowrap;
}

.appr-spec-filter-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  width: 100%;
}

.appr-spec-search {
  grid-column: 1 / -1;
}

.appr-spec-filter {
  display: grid;
  gap: 6px;
  color: #cbd5e1;
  font-size: 14px;
}

.appr-spec-filter span {
  color: #94a3b8;
  font-size: 14px;
}

.appr-spec-filter select,
.appr-spec-filter input {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.82);
  color: #f8fafc;
  font-size: 16px;
}

.appr-spec-switch-inline {
  align-content: end;
}

.appr-spec-switch-inline input,
.appr-spec-switch input {
  width: 18px;
  height: 18px;
  accent-color: #0ea5e9;
}

.appr-spec-shell {
  display: grid;
  gap: 16px;
}

.appr-spec-summary-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(110px, 1fr));
  gap: 10px;
}

.appr-spec-summary-grid article,
.appr-spec-card,
.appr-spec-sheet,
.appr-spec-history-panel,
.appr-spec-log-panel,
.appr-spec-history-card,
.appr-spec-paper-block,
.appr-spec-signer-card,
.appr-spec-modal-card {
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  background: rgba(17, 24, 39, 0.78);
}

.appr-spec-summary-grid article {
  min-height: 82px;
  padding: 12px;
}

.appr-spec-summary-grid span,
.appr-spec-card-head span,
.appr-spec-paper-code,
.appr-spec-history-head span,
.appr-spec-signer-card span,
.appr-spec-log-list time,
.appr-spec-log-list strong,
.appr-spec-sheet-grid span,
.appr-spec-switch span {
  color: #94a3b8;
  font-size: 14px;
}

.appr-spec-summary-grid strong {
  color: #f8fafc;
  font-size: 22px;
  line-height: 1.2;
}

.appr-spec-card-list {
  display: grid;
  gap: 12px;
  max-height: calc(100vh - 320px);
  overflow-y: auto;
  padding-right: 4px;
  scrollbar-gutter: stable;
}

.appr-spec-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  text-align: left;
  cursor: pointer;
  transition: border-color 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

.appr-spec-card:hover,
.appr-spec-card.active {
  border-color: rgba(14, 165, 233, 0.56);
  background: rgba(14, 165, 233, 0.1);
  transform: translateY(-1px);
}

.appr-spec-card-head,
.appr-spec-card-meta,
.appr-spec-card-foot,
.appr-spec-sheet-head,
.appr-spec-history-head,
.appr-spec-history-meta,
.appr-spec-panel-head,
.appr-spec-modal-card header,
.appr-spec-modal-card footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.appr-spec-card-head strong,
.appr-spec-history-head strong,
.appr-spec-sheet-head h2,
.appr-spec-signer-card strong,
.appr-spec-panel-head h3,
.appr-spec-modal-card h2 {
  margin: 4px 0 0;
  color: #f8fafc;
  font-size: 18px;
  line-height: 1.35;
}

.appr-spec-card-meta,
.appr-spec-history-meta,
.appr-spec-card p,
.appr-spec-paper-block p,
.appr-spec-signer-card p,
.appr-spec-log-list p,
.appr-spec-modal-card p {
  color: #cbd5e1;
  font-size: 14px;
  line-height: 1.55;
}

.appr-spec-card-foot strong,
.appr-spec-stamp strong,
.appr-spec-sheet-grid strong {
  color: #f8fafc;
  font-size: 18px;
}

.appr-spec-status {
  min-width: 86px;
  padding: 6px 10px;
  border-radius: 999px;
  text-align: center;
  font-size: 12px;
  line-height: 1.2;
}

.appr-spec-status.pending {
  border: 1px solid rgba(234, 179, 8, 0.35);
  background: rgba(234, 179, 8, 0.12);
  color: #fde68a;
}

.appr-spec-status.archived,
.appr-spec-status.finished {
  border: 1px solid rgba(16, 185, 129, 0.35);
  background: rgba(16, 185, 129, 0.12);
  color: #bbf7d0;
}

.appr-spec-status.returned {
  border: 1px solid rgba(239, 68, 68, 0.35);
  background: rgba(239, 68, 68, 0.12);
  color: #fecaca;
}

.appr-spec-sheet,
.appr-spec-history-panel,
.appr-spec-log-panel {
  padding: 16px;
}

.appr-spec-sheet-head {
  align-items: flex-start;
}

.appr-spec-sheet-head h2 {
  font-size: 22px;
}

.appr-spec-sheet-head p,
.appr-spec-stamp em {
  margin: 6px 0 0;
  color: #94a3b8;
  font-size: 14px;
}

.appr-spec-stamp {
  min-width: 180px;
  padding: 14px;
  border: 1px solid rgba(14, 165, 233, 0.18);
  border-radius: 8px;
  background: linear-gradient(160deg, rgba(248, 250, 252, 0.96), rgba(226, 232, 240, 0.9));
  color: #0f172a;
}

.appr-spec-stamp span,
.appr-spec-stamp em {
  color: #334155;
}

.appr-spec-stamp strong {
  color: #0f172a;
  font-size: 20px;
}

.appr-spec-sheet-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 16px;
}

.appr-spec-sheet-grid article {
  display: grid;
  gap: 6px;
  padding: 12px;
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.64);
}

.appr-spec-paper-grid,
.appr-spec-sign-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.appr-spec-paper-block,
.appr-spec-signer-card,
.appr-spec-history-card {
  padding: 14px;
}

.appr-spec-note-list,
.appr-spec-attachment-mini {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.appr-spec-note-list div,
.appr-spec-attachment-mini span {
  padding: 8px 10px;
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.7);
  color: #cbd5e1;
  font-size: 14px;
}

.appr-spec-signer-card {
  display: grid;
  gap: 8px;
}

.appr-spec-signer-card em {
  color: #94a3b8;
  font-size: 12px;
}

.appr-spec-signer-card b {
  justify-self: start;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
}

.appr-spec-signer-card b.signed {
  background: rgba(16, 185, 129, 0.14);
  color: #bbf7d0;
}

.appr-spec-signer-card b.pending {
  background: rgba(234, 179, 8, 0.14);
  color: #fde68a;
}

.appr-spec-history-panel select,
.appr-spec-modal-body input,
.appr-spec-modal-body select,
.appr-spec-modal-body textarea {
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(11, 15, 25, 0.88);
  color: #f8fafc;
  font-size: 16px;
}

.appr-spec-history-panel select {
  min-width: 240px;
}

.appr-spec-switch {
  display: flex;
  align-items: center;
  gap: 10px;
}

.appr-spec-log-list {
  display: grid;
  gap: 10px;
  max-height: 280px;
  overflow-y: auto;
  margin-top: 12px;
  padding-right: 4px;
}

.appr-spec-log-list article {
  display: grid;
  gap: 4px;
  padding: 10px 12px;
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.62);
}

.appr-spec-empty {
  min-height: 160px;
  display: grid;
  place-items: center;
  border: 1px dashed rgba(148, 163, 184, 0.3);
  border-radius: 8px;
  color: #94a3b8;
  font-size: 16px;
}

.appr-spec-modal {
  position: fixed;
  inset: 0;
  z-index: 1300;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(3, 7, 18, 0.72);
  backdrop-filter: blur(12px);
}

.appr-spec-modal-card {
  width: min(720px, 100%);
  max-height: min(780px, calc(100vh - 48px));
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  border-color: rgba(14, 165, 233, 0.28);
  background: #111827;
  box-shadow: 0 24px 72px rgba(0, 0, 0, 0.45);
}

.appr-spec-modal-card header,
.appr-spec-modal-card footer {
  padding: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.appr-spec-modal-card footer {
  justify-content: flex-end;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  border-bottom: 0;
}

.appr-spec-modal-close {
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.85);
  color: #cbd5e1;
  font-size: 16px;
  cursor: pointer;
}

.appr-spec-modal-body {
  display: grid;
  gap: 14px;
  overflow-y: auto;
  padding: 16px;
}

.appr-spec-modal-body label {
  display: grid;
  gap: 8px;
  color: #cbd5e1;
  font-size: 16px;
}

.appr-spec-modal-body textarea {
  min-height: 120px;
  resize: vertical;
}

@media (max-width: 1400px) {
  .appr-spec-summary-grid,
  .appr-spec-sheet-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 1100px) {
  .appr-spec-filter-row,
  .appr-spec-summary-grid,
  .appr-spec-sheet-grid,
  .appr-spec-paper-grid,
  .appr-spec-sign-grid {
    grid-template-columns: 1fr;
  }

  .appr-spec-card-list {
    max-height: none;
  }

  .appr-spec-sheet-head,
  .appr-spec-panel-head,
  .appr-spec-history-head,
  .appr-spec-history-meta {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 900px) {
  .appr-spec-filter-row {
    grid-template-columns: 1fr;
  }

  .appr-spec-history-panel select {
    width: 100%;
    min-width: 0;
  }
}

.archives-spec-action-btn {
  min-height: 44px;
  padding: 0 16px;
}

.archives-spec-filter-row {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) auto minmax(180px, 0.8fr) minmax(180px, 0.8fr) minmax(180px, 0.8fr);
  gap: 12px;
  align-items: end;
}

.archives-spec-filter {
  display: grid;
  gap: 8px;
}

.archives-spec-filter span,
.archives-spec-panel-head span,
.archives-spec-drawer-card p,
.archives-spec-record-card p,
.archives-spec-file-list p,
.archives-spec-bar-foot span,
.archives-spec-bar-foot em,
.archives-spec-detail-grid span,
.archives-spec-detail-grid p,
.archives-spec-modal-summary p {
  color: #94a3b8;
  font-size: 12px;
}

.archives-spec-filter input,
.archives-spec-filter select,
.archives-spec-modal-body input,
.archives-spec-modal-body textarea {
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(11, 15, 25, 0.88);
  color: #f8fafc;
  font-size: 16px;
}

.archives-spec-filter-btn {
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid rgba(56, 189, 248, 0.2);
  border-radius: 8px;
  background: rgba(8, 47, 73, 0.72);
  color: #dbeafe;
  font-size: 16px;
  cursor: pointer;
}

.archives-spec-shell {
  display: grid;
  gap: 16px;
}

.archives-spec-summary-grid,
.archives-spec-detail-grid,
.archives-spec-hash-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
}

.archives-spec-summary-grid article,
.archives-spec-detail-grid article,
.archives-spec-hash-grid article,
.archives-spec-drawer-card,
.archives-spec-record-card,
.archives-spec-history-chip,
.archives-spec-file-list article,
.archives-spec-bar-row,
.archives-spec-detail-hero,
.archives-spec-block,
.archives-spec-modal-card {
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.7);
}

.archives-spec-summary-grid article,
.archives-spec-detail-grid article,
.archives-spec-hash-grid article {
  display: grid;
  gap: 6px;
  padding: 12px;
}

.archives-spec-summary-grid span,
.archives-spec-summary-grid strong,
.archives-spec-detail-grid strong,
.archives-spec-hash-grid strong {
  line-height: 1.35;
}

.archives-spec-summary-grid strong {
  color: #f8fafc;
  font-size: 20px;
}

.archives-spec-cabinet-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr);
  gap: 14px;
}

.archives-spec-drawer-panel,
.archives-spec-record-panel,
.archives-spec-history-panel,
.archives-spec-detail-shell {
  display: grid;
  gap: 12px;
}

.archives-spec-panel-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.archives-spec-panel-head h3 {
  margin: 0;
  color: #f8fafc;
  font-size: 20px;
}

.archives-spec-drawer-rail,
.archives-spec-record-list,
.archives-spec-history-row,
.archives-spec-timeline {
  display: grid;
  gap: 10px;
}

.archives-spec-drawer-rail {
  max-height: 340px;
  overflow-y: auto;
  padding-right: 4px;
}

.archives-spec-drawer-card,
.archives-spec-record-card,
.archives-spec-history-chip {
  width: 100%;
  padding: 14px;
  text-align: left;
  color: #e2e8f0;
  cursor: pointer;
}

.archives-spec-drawer-card:hover,
.archives-spec-record-card:hover,
.archives-spec-history-chip:hover {
  border-color: rgba(14, 165, 233, 0.28);
  background: rgba(15, 23, 42, 0.82);
}

.archives-spec-drawer-card.active,
.archives-spec-record-card.active {
  border-color: rgba(14, 165, 233, 0.55);
  box-shadow: 0 0 0 1px rgba(14, 165, 233, 0.18) inset;
}

.archives-spec-drawer-head,
.archives-spec-record-head,
.archives-spec-bar-head,
.archives-spec-bar-foot,
.archives-spec-file-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
}

.archives-spec-drawer-head strong,
.archives-spec-record-head h3 {
  color: #f8fafc;
  font-size: 18px;
}

.archives-spec-drawer-head span,
.archives-spec-code,
.archives-spec-status {
  font-size: 12px;
}

.archives-spec-code {
  color: #7dd3fc;
}

.archives-spec-status {
  padding: 4px 10px;
  border-radius: 999px;
}

.archives-spec-status.success {
  background: rgba(16, 185, 129, 0.14);
  color: #bbf7d0;
}

.archives-spec-status.warning {
  background: rgba(234, 179, 8, 0.14);
  color: #fde68a;
}

.archives-spec-status.danger {
  background: rgba(239, 68, 68, 0.14);
  color: #fecaca;
}

.archives-spec-status.normal {
  background: rgba(56, 189, 248, 0.14);
  color: #bae6fd;
}

.archives-spec-drawer-card p,
.archives-spec-record-card p {
  margin: 10px 0 0;
  min-height: 40px;
  line-height: 1.45;
}

.archives-spec-drawer-foot,
.archives-spec-record-meta,
.archives-spec-tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.archives-spec-tag-row span,
.archives-spec-history-chip {
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(8, 15, 30, 0.86);
  color: #cbd5e1;
  font-size: 12px;
}

.archives-spec-history-chip {
  border: 1px solid rgba(148, 163, 184, 0.18);
}

.archives-spec-empty {
  min-height: 160px;
  display: grid;
  place-items: center;
  border: 1px dashed rgba(148, 163, 184, 0.3);
  border-radius: 8px;
  color: #94a3b8;
  font-size: 16px;
}

.archives-spec-detail-shell {
  gap: 14px;
}

.archives-spec-detail-hero {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 16px;
  align-items: flex-start;
  background: linear-gradient(145deg, rgba(15, 23, 42, 0.92), rgba(11, 15, 25, 0.96));
}

.archives-spec-detail-hero h2 {
  margin: 4px 0 8px;
  color: #f8fafc;
  font-size: 22px;
}

.archives-spec-detail-hero p {
  margin: 0;
  color: #cbd5e1;
  line-height: 1.6;
}

.archives-spec-eyebrow {
  color: #7dd3fc;
  font-size: 12px;
}

.archives-spec-hero-stamp {
  min-width: 180px;
  padding: 14px;
  border: 1px solid rgba(14, 165, 233, 0.2);
  border-radius: 8px;
  background: rgba(3, 7, 18, 0.72);
}

.archives-spec-hero-stamp strong {
  display: block;
  color: #f8fafc;
  font-size: 20px;
}

.archives-spec-hero-stamp span,
.archives-spec-hero-stamp em {
  display: block;
  margin-top: 4px;
  color: #94a3b8;
  font-size: 12px;
}

.archives-spec-block {
  padding: 14px;
}

.archives-spec-block h3 {
  margin: 0;
  color: #f8fafc;
  font-size: 18px;
}

.archives-spec-hash-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 12px;
}

.archives-spec-file-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.archives-spec-file-list article {
  display: grid;
  gap: 8px;
  padding: 12px;
}

.archives-spec-file-list strong {
  color: #f8fafc;
  font-size: 16px;
}

.archives-spec-bar-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.archives-spec-bar-row {
  padding: 12px;
}

.archives-spec-bar-track {
  height: 12px;
  margin: 8px 0;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.92);
  overflow: hidden;
}

.archives-spec-bar-track i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #0ea5e9, #10b981);
}

.archives-spec-timeline {
  max-height: 280px;
  overflow-y: auto;
  padding-right: 4px;
}

.archives-spec-timeline article {
  display: grid;
  gap: 4px;
  padding: 10px 12px;
  border-radius: 8px;
  background: rgba(8, 15, 30, 0.9);
}

.archives-spec-timeline time {
  color: #7dd3fc;
  font-size: 12px;
}

.archives-spec-modal {
  position: fixed;
  inset: 0;
  z-index: 1300;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(3, 7, 18, 0.72);
  backdrop-filter: blur(12px);
}

.archives-spec-modal-card {
  width: min(760px, 100%);
  max-height: min(780px, calc(100vh - 48px));
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  background: #111827;
  box-shadow: 0 24px 72px rgba(0, 0, 0, 0.45);
}

.archives-spec-modal-card header,
.archives-spec-modal-card footer {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.archives-spec-modal-card footer {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  border-bottom: 0;
  justify-content: flex-end;
}

.archives-spec-modal-card h2 {
  margin: 0;
  color: #f8fafc;
  font-size: 22px;
}

.archives-spec-modal-card p {
  margin: 6px 0 0;
  color: #94a3b8;
  font-size: 14px;
}

.archives-spec-modal-close {
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.85);
  color: #cbd5e1;
  font-size: 16px;
  cursor: pointer;
}

.archives-spec-modal-body {
  display: grid;
  gap: 14px;
  overflow-y: auto;
  padding: 16px;
}

.archives-spec-modal-summary {
  display: grid;
  gap: 8px;
}

.archives-spec-modal-field {
  display: grid;
  gap: 8px;
  color: #cbd5e1;
  font-size: 16px;
}

.archives-spec-modal-field textarea {
  min-height: 120px;
  resize: vertical;
}

@media (max-width: 1400px) {
  .archives-spec-summary-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .archives-spec-detail-grid,
  .archives-spec-hash-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 1100px) {
  .archives-spec-filter-row,
  .archives-spec-cabinet-grid,
  .archives-spec-summary-grid,
  .archives-spec-detail-grid,
  .archives-spec-hash-grid {
    grid-template-columns: 1fr;
  }

  .archives-spec-detail-hero {
    flex-direction: column;
  }

  .archives-spec-drawer-rail,
  .archives-spec-record-list,
  .archives-spec-timeline {
    max-height: none;
  }
}

@media (max-width: 900px) {
  .archives-spec-filter-row {
    grid-template-columns: 1fr;
  }

  .archives-spec-filter-btn {
    width: 100%;
  }

  .archives-spec-modal-card {
    width: 100%;
  }
}

.report-preview-spec-action-btn {
  min-height: 44px;
  padding: 0 16px;
  border-radius: 8px;
  font-size: 16px;
}

.report-preview-spec-filter-row {
  display: grid;
  grid-template-columns: minmax(260px, 1.5fr) minmax(180px, 0.8fr);
  gap: 12px;
  width: 100%;
}

.report-preview-spec-filter {
  display: grid;
  gap: 6px;
  color: #cbd5e1;
  font-size: 14px;
}

.report-preview-spec-filter span,
.report-preview-spec-kicker,
.report-preview-spec-card-head span,
.report-preview-spec-card-meta span,
.report-preview-spec-side-head span,
.report-preview-spec-outline span,
.report-preview-spec-compare-toolbar span,
.report-preview-spec-diff-grid span,
.report-preview-spec-security-grid span {
  color: #94a3b8;
  font-size: 14px;
}

.report-preview-spec-filter input,
.report-preview-spec-filter select,
.report-preview-spec-compare-select {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.82);
  color: #f8fafc;
  font-size: 16px;
}

.report-preview-spec-shell,
.report-preview-spec-workspace,
.report-preview-spec-side-shell {
  display: grid;
  gap: 16px;
}

.report-preview-spec-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(120px, 1fr));
  gap: 10px;
}

.report-preview-spec-summary-grid article,
.report-preview-spec-card,
.report-preview-spec-paper,
.report-preview-spec-side-card,
.report-preview-spec-compare-grid article,
.report-preview-spec-diff-grid article {
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  background: rgba(17, 24, 39, 0.78);
}

.report-preview-spec-summary-grid article {
  min-height: 82px;
  padding: 12px;
}

.report-preview-spec-summary-grid strong,
.report-preview-spec-card strong,
.report-preview-spec-paper header h2,
.report-preview-spec-outline strong,
.report-preview-spec-side-head h3,
.report-preview-spec-compare-grid h3,
.report-preview-spec-security-grid strong,
.report-preview-spec-paper-meta strong,
.report-preview-spec-diff-grid strong {
  color: #f8fafc;
}

.report-preview-spec-summary-grid strong {
  font-size: 22px;
  line-height: 1.2;
}

.report-preview-spec-list {
  display: grid;
  gap: 12px;
  max-height: calc(100vh - 320px);
  overflow-y: auto;
  padding-right: 4px;
  scrollbar-gutter: stable;
}

.report-preview-spec-card {
  display: grid;
  gap: 10px;
  padding: 14px;
  text-align: left;
  cursor: pointer;
  transition: border-color 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

.report-preview-spec-card:hover,
.report-preview-spec-card.active {
  border-color: rgba(14, 165, 233, 0.54);
  background: rgba(14, 165, 233, 0.1);
  transform: translateY(-1px);
}

.report-preview-spec-card-head,
.report-preview-spec-card-meta,
.report-preview-spec-paper header,
.report-preview-spec-side-head,
.report-preview-spec-compare-toolbar,
.report-preview-spec-compare-grid header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.report-preview-spec-card p,
.report-preview-spec-paper header p,
.report-preview-spec-abstract p,
.report-preview-spec-outline p,
.report-preview-spec-side-note,
.report-preview-spec-compare-grid p {
  margin: 0;
  color: #cbd5e1;
  font-size: 14px;
  line-height: 1.55;
}

.report-preview-spec-workspace {
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, 0.85fr);
  align-items: start;
}

.report-preview-spec-paper {
  position: relative;
  padding: 22px;
  background: linear-gradient(180deg, rgba(248, 250, 252, 0.96), rgba(226, 232, 240, 0.94));
  color: #0f172a;
  overflow: hidden;
}

.report-preview-spec-paper header span,
.report-preview-spec-paper header p,
.report-preview-spec-kicker,
.report-preview-spec-watermark,
.report-preview-spec-paper-meta strong {
  color: #475569;
}

.report-preview-spec-paper header h2,
.report-preview-spec-abstract p,
.report-preview-spec-outline strong,
.report-preview-spec-outline p {
  color: #0f172a;
}

.report-preview-spec-paper header h2 {
  margin: 6px 0;
  font-size: 24px;
  line-height: 1.25;
}

.report-preview-spec-paper-meta {
  display: grid;
  justify-items: end;
  gap: 10px;
}

.report-preview-spec-paper-meta strong {
  font-size: 28px;
}

.report-preview-spec-watermark {
  position: absolute;
  inset: 42% 0 auto;
  text-align: center;
  font-size: 36px;
  opacity: 0.08;
  letter-spacing: 2px;
  transform: rotate(-18deg);
  pointer-events: none;
}

.report-preview-spec-abstract,
.report-preview-spec-tag-row,
.report-preview-spec-outline {
  margin-top: 18px;
}

.report-preview-spec-tag-row,
.report-preview-spec-compare-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.report-preview-spec-tag-row span,
.report-preview-spec-compare-tags span,
.report-preview-spec-security {
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
}

.report-preview-spec-tag-row span,
.report-preview-spec-compare-tags span {
  background: rgba(15, 23, 42, 0.08);
  color: #334155;
}

.report-preview-spec-security.secure-base {
  background: rgba(14, 165, 233, 0.12);
  color: #0c4a6e;
}

.report-preview-spec-security.secure-mid {
  background: rgba(234, 179, 8, 0.18);
  color: #854d0e;
}

.report-preview-spec-security.secure-high {
  background: rgba(239, 68, 68, 0.16);
  color: #991b1b;
}

.report-preview-spec-outline {
  display: grid;
  gap: 12px;
}

.report-preview-spec-outline article {
  display: grid;
  grid-template-columns: 36px 1fr;
  gap: 12px;
  padding: 12px 0;
  border-top: 1px solid rgba(15, 23, 42, 0.08);
}

.report-preview-spec-side-card {
  padding: 16px;
}

.report-preview-spec-security-grid,
.report-preview-spec-diff-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.report-preview-spec-security-grid article,
.report-preview-spec-diff-grid article {
  display: grid;
  gap: 6px;
  padding: 12px;
}

.report-preview-spec-version-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.report-preview-spec-version-item {
  display: grid;
  gap: 4px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.64);
  color: #e2e8f0;
  text-align: left;
  cursor: pointer;
}

.report-preview-spec-version-item.active {
  border-color: rgba(14, 165, 233, 0.54);
  background: rgba(14, 165, 233, 0.12);
}

.report-preview-spec-version-item span,
.report-preview-spec-version-item em {
  color: #94a3b8;
  font-size: 14px;
}

.report-preview-spec-compare-shell,
.report-preview-spec-compare-grid {
  display: grid;
  gap: 12px;
}

.report-preview-spec-compare-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.report-preview-spec-compare-grid article {
  display: grid;
  gap: 12px;
  padding: 14px;
}

.report-preview-spec-compare-grid strong {
  font-size: 28px;
}

.report-preview-spec-empty {
  min-height: 180px;
  display: grid;
  place-items: center;
  border: 1px dashed rgba(148, 163, 184, 0.3);
  border-radius: 8px;
  color: #94a3b8;
  font-size: 16px;
}

@media (max-width: 1400px) {
  .report-preview-spec-summary-grid,
  .report-preview-spec-security-grid,
  .report-preview-spec-diff-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 1100px) {
  .report-preview-spec-filter-row,
  .report-preview-spec-workspace,
  .report-preview-spec-compare-grid,
  .report-preview-spec-security-grid,
  .report-preview-spec-diff-grid {
    grid-template-columns: 1fr;
  }

  .report-preview-spec-list {
    max-height: none;
  }

  .report-preview-spec-paper header,
  .report-preview-spec-side-head,
  .report-preview-spec-compare-toolbar,
  .report-preview-spec-compare-grid header,
  .report-preview-spec-card-head,
  .report-preview-spec-card-meta {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 900px) {
  .report-preview-spec-summary-grid {
    grid-template-columns: 1fr;
  }
}

.anomaly-stats-spec-shell,
.anomaly-stats-spec-detail-shell {
  display: grid;
  gap: 16px;
}

.anomaly-stats-spec-hero {
  padding: 6px 0 2px;
}

.anomaly-stats-spec-filter-row,
.anomaly-stats-spec-overview-grid,
.anomaly-stats-spec-bottom-grid,
.anomaly-stats-spec-detail-grid,
.anomaly-stats-spec-summary-grid,
.anomaly-stats-spec-detail-metrics {
  display: grid;
  gap: 14px;
}

.anomaly-stats-spec-filter-row {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.anomaly-stats-spec-filter {
  display: grid;
  gap: 8px;
  color: #cbd5e1;
  font-size: 14px;
}

.anomaly-stats-spec-filter span,
.anomaly-stats-spec-panel-head span,
.anomaly-stats-spec-summary-card em,
.anomaly-stats-spec-replay-meta,
.anomaly-stats-spec-ranking-main em,
.anomaly-stats-spec-detail-head p,
.anomaly-stats-spec-detail-copy p,
.anomaly-stats-spec-timeline p,
.anomaly-stats-spec-log-list p,
.anomaly-stats-spec-bar-meta,
.anomaly-stats-spec-detail-tags span {
  color: #94a3b8;
}

.anomaly-stats-spec-filter select,
.anomaly-stats-spec-filter input,
.anomaly-stats-spec-action {
  min-height: 44px;
  font-size: 16px;
}

.anomaly-stats-spec-summary-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.anomaly-stats-spec-summary-card,
.anomaly-stats-spec-panel,
.anomaly-stats-spec-detail-card {
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.96), rgba(9, 14, 26, 0.96));
  border-radius: 8px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.anomaly-stats-spec-summary-card {
  padding: 16px 18px;
  display: grid;
  gap: 8px;
  text-align: left;
  cursor: pointer;
}

.anomaly-stats-spec-summary-card.static {
  cursor: default;
}

.anomaly-stats-spec-summary-card strong {
  font-size: 30px;
  line-height: 1.1;
  color: #f8fafc;
}

.anomaly-stats-spec-summary-card strong small {
  font-size: 16px;
  margin-left: 4px;
  color: #94a3b8;
}

.anomaly-stats-spec-summary-card span,
.anomaly-stats-spec-panel-head h3,
.anomaly-stats-spec-detail-head h2,
.anomaly-stats-spec-detail-metrics strong,
.anomaly-stats-spec-ring-center strong {
  color: #f8fafc;
}

.anomaly-stats-spec-overview-grid {
  grid-template-columns: minmax(340px, 0.95fr) minmax(360px, 1.05fr);
}

.anomaly-stats-spec-bottom-grid,
.anomaly-stats-spec-detail-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.anomaly-stats-spec-panel,
.anomaly-stats-spec-detail-card {
  padding: 16px;
}

.anomaly-stats-spec-panel-head,
.anomaly-stats-spec-detail-head,
.anomaly-stats-spec-replay-head,
.anomaly-stats-spec-ranking-main,
.anomaly-stats-spec-detail-tags,
.anomaly-stats-spec-bar-item,
.anomaly-stats-spec-level-item,
.anomaly-stats-spec-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.anomaly-stats-spec-panel-head {
  margin-bottom: 14px;
}

.anomaly-stats-spec-panel-head h3,
.anomaly-stats-spec-detail-head h2 {
  margin: 0;
  font-size: 20px;
  line-height: 1.3;
}

.anomaly-stats-spec-ring-panel {
  display: grid;
  gap: 14px;
}

.anomaly-stats-spec-ring-wrap {
  position: relative;
  width: min(260px, 100%);
  margin: 0 auto;
}

.anomaly-stats-spec-ring-chart {
  width: 100%;
  display: block;
  transform: rotate(-90deg);
}

.anomaly-stats-spec-ring-track,
.anomaly-stats-spec-ring-segment {
  fill: none;
  stroke-width: 4;
}

.anomaly-stats-spec-ring-track {
  stroke: rgba(148, 163, 184, 0.14);
}

.anomaly-stats-spec-ring-segment.critical {
  stroke: #ef4444;
}

.anomaly-stats-spec-ring-segment.warning {
  stroke: #eab308;
}

.anomaly-stats-spec-ring-segment.normal {
  stroke: #10b981;
}

.anomaly-stats-spec-ring-center {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  text-align: center;
}

.anomaly-stats-spec-ring-center strong {
  font-size: 34px;
  line-height: 1.05;
}

.anomaly-stats-spec-ring-center span {
  font-size: 14px;
  color: #94a3b8;
}

.anomaly-stats-spec-level-list,
.anomaly-stats-spec-ranking-list,
.anomaly-stats-spec-replay-list,
.anomaly-stats-spec-timeline,
.anomaly-stats-spec-log-list {
  display: grid;
  gap: 10px;
}

.anomaly-stats-spec-level-item,
.anomaly-stats-spec-ranking-item,
.anomaly-stats-spec-replay-card,
.anomaly-stats-spec-bar-item {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(15, 23, 42, 0.88);
  border-radius: 8px;
  cursor: pointer;
}

.anomaly-stats-spec-level-item {
  padding: 12px 14px;
  justify-content: flex-start;
}

.anomaly-stats-spec-level-item.active,
.anomaly-stats-spec-replay-card.active,
.anomaly-stats-spec-bar-item.active,
.anomaly-stats-spec-ranking-item:hover,
.anomaly-stats-spec-level-item:hover,
.anomaly-stats-spec-replay-card:hover,
.anomaly-stats-spec-bar-item:hover,
.anomaly-stats-spec-summary-card:hover {
  border-color: rgba(14, 165, 233, 0.46);
  background: rgba(14, 165, 233, 0.1);
}

.anomaly-stats-spec-level-item .dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  flex: none;
}

.anomaly-stats-spec-level-item .dot.critical,
.anomaly-stats-spec-detail-tags .tone-critical,
.anomaly-stats-spec-replay-head .tone-critical {
  background: #ef4444;
}

.anomaly-stats-spec-level-item .dot.warning,
.anomaly-stats-spec-detail-tags .tone-warning,
.anomaly-stats-spec-replay-head .tone-warning {
  background: #eab308;
}

.anomaly-stats-spec-level-item .dot.normal,
.anomaly-stats-spec-detail-tags .tone-normal,
.anomaly-stats-spec-replay-head .tone-normal {
  background: #10b981;
}

.anomaly-stats-spec-level-item b,
.anomaly-stats-spec-level-item strong,
.anomaly-stats-spec-ranking-item strong,
.anomaly-stats-spec-replay-card strong,
.anomaly-stats-spec-bar-item strong,
.anomaly-stats-spec-detail-tags b,
.anomaly-stats-spec-timeline strong,
.anomaly-stats-spec-log-list strong {
  color: #f8fafc;
}

.anomaly-stats-spec-bar-chart {
  min-height: 280px;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  align-items: end;
  gap: 12px;
}

.anomaly-stats-spec-bar-item {
  min-height: 240px;
  padding: 12px 10px 10px;
  display: grid;
  align-content: end;
  gap: 10px;
}

.anomaly-stats-spec-bar-item .bar {
  display: block;
  width: 100%;
  min-height: 18px;
  border-radius: 6px 6px 4px 4px;
  background: linear-gradient(180deg, rgba(14, 165, 233, 0.92), rgba(14, 165, 233, 0.28));
  box-shadow: 0 10px 24px rgba(14, 165, 233, 0.2);
}

.anomaly-stats-spec-bar-item em {
  font-size: 14px;
  color: #cbd5e1;
  font-style: normal;
}

.anomaly-stats-spec-bar-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  font-size: 14px;
  line-height: 1.5;
}

.anomaly-stats-spec-ranking-item,
.anomaly-stats-spec-replay-card {
  padding: 14px;
  display: grid;
  gap: 10px;
  text-align: left;
}

.anomaly-stats-spec-ranking-main {
  align-items: flex-start;
}

.anomaly-stats-spec-ranking-main span {
  min-width: 28px;
  font-size: 22px;
  color: #475569;
}

.anomaly-stats-spec-ranking-main em,
.anomaly-stats-spec-replay-meta span {
  font-size: 14px;
}

.anomaly-stats-spec-ranking-bar {
  height: 8px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.14);
  overflow: hidden;
}

.anomaly-stats-spec-ranking-bar i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(14, 165, 233, 0.42), rgba(14, 165, 233, 0.96));
}

.anomaly-stats-spec-replay-head span,
.anomaly-stats-spec-detail-head span,
.anomaly-stats-spec-timeline span,
.anomaly-stats-spec-log-list span {
  font-size: 14px;
  color: #94a3b8;
}

.anomaly-stats-spec-replay-head b,
.anomaly-stats-spec-detail-tags b {
  min-width: 56px;
  padding: 4px 10px;
  border-radius: 999px;
  text-align: center;
  font-size: 12px;
  color: #08111f;
}

.anomaly-stats-spec-detail-head {
  align-items: flex-start;
}

.anomaly-stats-spec-detail-tags {
  flex-wrap: wrap;
  justify-content: flex-end;
}

.anomaly-stats-spec-detail-tags span {
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  background: rgba(148, 163, 184, 0.08);
  font-size: 14px;
}

.anomaly-stats-spec-detail-metrics {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.anomaly-stats-spec-detail-metrics article {
  padding: 14px 16px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(15, 23, 42, 0.9);
  display: grid;
  gap: 8px;
}

.anomaly-stats-spec-detail-metrics span {
  color: #94a3b8;
  font-size: 14px;
}

.anomaly-stats-spec-detail-metrics strong {
  font-size: 32px;
  line-height: 1.05;
}

.anomaly-stats-spec-detail-copy {
  display: grid;
  gap: 10px;
  font-size: 16px;
  line-height: 1.65;
}

.anomaly-stats-spec-detail-copy p,
.anomaly-stats-spec-timeline p,
.anomaly-stats-spec-log-list p {
  margin: 0;
}

.anomaly-stats-spec-timeline article,
.anomaly-stats-spec-log-list article {
  padding-left: 16px;
  border-left: 2px solid rgba(14, 165, 233, 0.34);
  display: grid;
  gap: 4px;
}

@media (max-width: 1400px) {
  .anomaly-stats-spec-summary-grid,
  .anomaly-stats-spec-detail-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 1180px) {
  .anomaly-stats-spec-filter-row,
  .anomaly-stats-spec-overview-grid,
  .anomaly-stats-spec-bottom-grid,
  .anomaly-stats-spec-detail-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .anomaly-stats-spec-summary-grid,
  .anomaly-stats-spec-detail-metrics {
    grid-template-columns: 1fr;
  }

  .anomaly-stats-spec-bar-chart {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
