﻿:root {
  --bg: #f2f6fb;
  --card: #ffffff;
  --line: #dfe7f1;
  --text: #102a43;
  --muted: #6c7a89;
  --primary: #0b70f0;
  --primary-soft: #e8f2ff;
  --danger: #e63a3a;
  --warn: #f29f05;
  --ok: #1f9d55;
  --shadow: 0 8px 24px rgba(16, 42, 67, 0.08);
  --monitor-plan-panel-width: 220px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Noto Sans SC", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 85% 5%, #dfefff 0%, transparent 35%),
    radial-gradient(circle at 15% 95%, #f0f8ff 0%, transparent 40%),
    var(--bg);
}

.app {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 260px 1fr;
}

.sidebar {
  background: linear-gradient(180deg, #062044 0%, #0a3267 100%);
  color: #fff;
  padding: 22px 16px;
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.brand {
  display: flex;
  gap: 10px;
  align-items: center;
}

.brand-logo {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: linear-gradient(145deg, #26a0ff, #1c71ff);
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 22px;
}

.brand h1 {
  margin: 0;
  font-size: 20px;
}

.brand p {
  margin: 2px 0 0;
  font-size: 12px;
  opacity: 0.8;
}

.menu {
  display: grid;
  gap: 8px;
}

.menu button {
  background: transparent;
  border: 0;
  color: #cfe3ff;
  text-align: left;
  padding: 11px 12px;
  border-radius: 10px;
  font-size: 14px;
  cursor: pointer;
}

.menu button.active,
.menu button:hover {
  background: rgba(255, 255, 255, 0.13);
  color: #fff;
}

.sidebar-footer {
  margin-top: auto;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 12px;
  padding: 12px;
}

.sidebar-footer p {
  margin: 0 0 4px;
  font-size: 12px;
  opacity: 0.8;
}

.main {
  padding: 22px;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-bottom: 16px;
}

.topbar h2 {
  margin: 0;
  font-size: 26px;
}

.topbar p {
  margin: 6px 0 0;
  color: var(--muted);
}

.top-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.badge {
  background: #e3f0ff;
  color: #10427f;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
}

.badge.light {
  background: #eef4fb;
  color: #46607b;
}

input,
select,
button {
  font: inherit;
}

input,
select {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 10px 12px;
  background: #fff;
}

input[type="search"] {
  width: 260px;
}

button {
  border-radius: 10px;
  border: 1px solid #bfd9ff;
  background: #eff6ff;
  color: #11427f;
  padding: 10px 14px;
  cursor: pointer;
}

button.primary {
  background: linear-gradient(135deg, #f2f8ff 0%, #e6f2ff 100%);
  border-color: #87bcff;
  color: #1354a1;
  box-shadow:
    0 5px 12px rgba(89, 142, 207, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.86);
  font-weight: 600;
  transition:
    transform 0.14s ease,
    box-shadow 0.2s ease,
    background 0.2s ease,
    border-color 0.2s ease;
}

button.primary:hover:not(:disabled) {
  transform: translateY(-1px);
  background: linear-gradient(135deg, #ecf5ff 0%, #d8ebff 100%);
  border-color: #69abf5;
  box-shadow:
    0 8px 16px rgba(89, 142, 207, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

button.primary:active:not(:disabled) {
  transform: translateY(0);
  background: linear-gradient(135deg, #e1efff 0%, #d0e6ff 100%);
  border-color: #5a9be5;
  box-shadow:
    0 3px 8px rgba(89, 142, 207, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

button.primary:focus-visible {
  outline: none;
  box-shadow:
    0 0 0 3px rgba(128, 180, 245, 0.34),
    0 6px 14px rgba(89, 142, 207, 0.22);
}

button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

button.is-loading {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

button .btn-inline-spinner {
  width: 12px;
  height: 12px;
  border-radius: 999px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  animation: btn-inline-spin 0.8s linear infinite;
  opacity: 0.85;
}

@keyframes btn-inline-spin {
  to {
    transform: rotate(360deg);
  }
}

.page {
  display: none;
  gap: 16px;
}

.page.active {
  display: grid;
}

.cards {
  display: grid;
  grid-template-columns: repeat(4, minmax(160px, 1fr));
  gap: 12px;
}

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px;
  box-shadow: var(--shadow);
}

.card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.card strong {
  display: block;
  font-size: 26px;
  margin: 6px 0;
}

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

.positive {
  color: var(--ok);
}

.negative {
  color: var(--danger);
}

.panel-grid {
  display: grid;
  gap: 12px;
}

.panel-grid.two {
  grid-template-columns: 2fr 1fr;
}

.panel {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--shadow);
  padding: 16px;
}

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

.panel h3 {
  margin: 0;
  font-size: 17px;
}

.panel-head span {
  color: var(--muted);
  font-size: 12px;
}
.seg-tabs {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.seg-tabs button {
  padding: 7px 10px;
  border-radius: 999px;
}
.seg-tabs button.active {
  background: #24c0c8;
  border-color: #24c0c8;
  color: #fff;
}

.source-row,
.sentiment-row {
  margin: 10px 0;
}

.row-head {
  display: flex;
  justify-content: space-between;
  margin-bottom: 6px;
  font-size: 13px;
}

.bar {
  height: 10px;
  border-radius: 999px;
  background: #eef3fa;
  overflow: hidden;
}

.bar i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #22a7ff, #0b70f0);
}

.table-wrap {
  overflow: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  text-align: left;
  padding: 10px 8px;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}

th {
  color: #3d5873;
  font-weight: 600;
}

.source-action-cell {
  width: 96px;
}

.source-action-icon-btn {
  width: 40px;
  height: 40px;
  padding: 0 !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  vertical-align: middle;
}

.source-action-icon-btn svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

.risk {
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 12px;
  display: inline-block;
}

.risk.high {
  background: #ffe8e8;
  color: var(--danger);
}

.risk.mid {
  background: #fff4dd;
  color: #a86600;
}

.risk.low {
  background: #e9f9ef;
  color: var(--ok);
}

.task-form {
  display: grid;
  grid-template-columns: 1fr 1fr 140px 90px;
  gap: 8px;
  margin-bottom: 12px;
}
.monitor-filter {
  grid-template-columns: 2fr 1fr 1fr 1fr 100px;
}
.report-form {
  grid-template-columns: 1fr 140px;
}
.brief-filter {
  grid-template-columns: 1fr 180px 100px;
}
.source-form {
  grid-template-columns: minmax(180px, 1fr) minmax(180px, 1fr) 180px 130px 120px;
}

.source-add-feedback {
  grid-column: 1 / -1;
  min-height: 18px;
  margin: -4px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.source-add-feedback.error {
  color: var(--danger);
}

.source-add-feedback.success {
  color: var(--ok);
}

.source-form input.field-invalid {
  border-color: var(--danger);
  box-shadow: 0 0 0 2px rgba(230, 58, 58, 0.1);
}

.tenant-user-form {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) minmax(140px, 1fr) minmax(180px, 1fr) 140px 110px;
  gap: 8px;
  margin-bottom: 12px;
}

.tenant-user-name-input,
.tenant-user-role-select {
  width: 100%;
  height: 38px;
  min-height: 38px;
  box-sizing: border-box;
  padding: 0 12px;
  font-size: 13px;
  line-height: 36px;
}

.tenant-user-role-select {
  padding-right: 32px;
}

.tenant-user-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.tenant-user-actions button {
  min-height: 34px;
  padding: 0 10px;
  margin-right: 0;
  line-height: 32px;
}

.tenant-user-actions button.danger {
  border-color: #f2b8b8;
  background: #fff5f5;
  color: var(--danger);
}

.role-permission-matrix {
  display: grid;
  gap: 10px;
}

.role-permission-row {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}

.role-permission-row:last-child {
  border-bottom: 0;
}

.role-permission-role {
  color: #233f5d;
  font-size: 14px;
  line-height: 28px;
}

.role-permission-items {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 8px 12px;
}

.role-permission-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 28px;
  color: #314563;
  font-size: 13px;
}

#adminPage .panel-head h3,
#adminPage table th {
  color: #314563 !important;
  font-size: 13px !important;
  font-weight: 400 !important;
  letter-spacing: 0 !important;
}

#adminPage .tenant-user-form input,
#adminPage .tenant-user-form input::placeholder,
#adminPage .tenant-user-form select,
#adminPage .tenant-user-form select option,
#adminPage .tenant-user-form button,
#adminPage .tenant-user-name-input,
#adminPage .tenant-user-role-select {
  color: #314563 !important;
  font-size: 13px !important;
  font-weight: 400 !important;
  letter-spacing: 0 !important;
}

#adminPage .tenant-user-form input,
#adminPage .tenant-user-form select,
#adminPage .tenant-user-form button {
  min-height: 42px;
  box-sizing: border-box;
  line-height: 20px;
}

.account-security-form {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) minmax(160px, 1fr) minmax(160px, 1fr) 110px;
  gap: 8px;
  align-items: start;
}

.account-security-form input,
.account-security-form input::placeholder,
.account-security-form button {
  font-size: 13px !important;
  font-weight: 400 !important;
  letter-spacing: 0 !important;
}

.account-security-feedback {
  grid-column: 1 / -1;
  min-height: 18px;
  margin: -2px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.account-security-feedback.error {
  color: var(--danger);
}

.account-security-feedback.success {
  color: var(--ok);
}
.warning-form {
  grid-template-columns: 120px 120px 1fr 1fr 100px;
}
.warning-log-filter {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin: 8px 0 10px;
}
.warning-log-filter-label {
  font-size: 13px;
  color: #5c6f83;
  white-space: nowrap;
}
.warning-log-filter-sep {
  color: #8da0b4;
  line-height: 34px;
}
.warning-log-filter input,
.warning-log-filter select {
  height: 34px;
  border-radius: 4px;
}
#warningLogStartAt,
#warningLogEndAt {
  width: 186px;
  min-width: 186px;
}
#warningLogPlan,
#warningLogSource {
  width: 150px;
  min-width: 150px;
}
#warningLogKeyword {
  flex: 1 1 260px;
  min-width: 180px;
  max-width: 420px;
}
#warningLogQueryBtn {
  height: 34px;
  border-radius: 4px;
  padding: 0 16px;
}
.warning-log-empty {
  text-align: center;
  color: #8395a8;
}
.plan-form {
  grid-template-columns: 1fr 180px 1fr 100px;
}
.plan-workspace {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 14px;
  padding: 10px;
}
.plan-sidebar {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #f8fbff;
  padding: 10px;
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 10px;
  min-height: 760px;
}
.plan-sidebar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.plan-sidebar-head h3 {
  margin: 0;
  font-size: 16px;
}
.icon-btn {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  padding: 0;
  font-size: 20px;
  line-height: 1;
  display: grid;
  place-items: center;
}
.plan-sidebar-list {
  display: grid;
  align-content: start;
  gap: 8px;
  overflow: auto;
}
.plan-item {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 10px;
  padding: 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  cursor: pointer;
}
.plan-item .plan-item-name {
  display: block;
  font-weight: 600;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.plan-item small {
  color: var(--muted);
}
.plan-item.active {
  border-color: #6dc9ff;
  background: #e9f7ff;
}
.plan-item-tools {
  display: flex;
  align-items: center;
  gap: 4px;
}
.plan-status-btn {
  min-width: 24px;
  width: 24px;
  height: 24px;
  padding: 0;
  border-radius: 999px;
  border: 1px solid #b8d0e8;
  background: #eef7ff;
  color: #245a8d;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  line-height: 1;
  white-space: nowrap;
}
.plan-status-btn.status-running {
  border-color: #8ad3a0;
  background: #f0fff4;
  color: #256b3e;
}
.plan-status-btn.status-paused {
  border-color: #d7c58a;
  background: #fff8e8;
  color: #8a6a12;
}
.plan-status-btn.is-pending:disabled {
  opacity: 0.65;
  cursor: wait;
}
.plan-status-btn.status-ended {
  min-width: 72px;
  width: auto;
  height: 26px;
  padding: 0 12px;
  border-radius: 8px;
  border-color: #c3ced9;
  background: #eef2f6;
  color: #4b5d70;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.5px;
  cursor: default;
}
.plan-status-icon {
  display: inline-block;
}
.plan-status-icon-running {
  width: 12px;
  height: 12px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: plan-status-spin 0.9s linear infinite;
}
.plan-status-icon-running-idle {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
}
.plan-status-icon-queued {
  width: 12px;
  height: 12px;
  border: 2px solid currentColor;
  border-radius: 50%;
  position: relative;
}
.plan-status-icon-queued::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: currentColor;
  transform: translate(-50%, -50%);
}
.plan-status-icon-paused {
  width: 10px;
  height: 12px;
  position: relative;
}
.plan-status-icon-paused::before,
.plan-status-icon-paused::after {
  content: "";
  position: absolute;
  top: 0;
  width: 3px;
  height: 12px;
  border-radius: 1px;
  background: currentColor;
}
.plan-status-icon-paused::before {
  left: 1px;
}
.plan-status-icon-paused::after {
  right: 1px;
}
@keyframes plan-status-spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}
.plan-action-btn {
  width: 22px;
  height: 22px;
  padding: 0;
  border-radius: 6px;
  border: 1px solid #b8d0e8;
  background: #f4f9ff;
  color: #245a8d;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  line-height: 1;
}
.plan-action-btn.danger {
  border-color: #e1b7b7;
  background: #fff5f5;
  color: #a64646;
}
.plan-action-btn.plan-pull-now-btn {
  width: 24px;
  min-width: 24px;
  height: 24px;
  padding: 0;
  border-color: #82bcff;
  background: #f0f7ff;
  color: #075fc1;
  font-weight: 700;
  font-size: 16px;
  line-height: 1;
}
.plan-action-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
.plan-main {
  min-width: 0;
}
.plan-main-head {
  border-bottom: 1px solid var(--line);
  padding-bottom: 10px;
}
.monitor-plan-modal {
  width: min(760px, calc(100% - 24px));
}
.monitor-plan-form-modal {
  display: grid;
  grid-template-columns: 1fr 220px;
  gap: 8px;
}
.monitor-plan-form-modal textarea {
  grid-column: 1 / -1;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 10px 12px;
  min-height: 120px;
  resize: vertical;
  font: inherit;
}
.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}
.channel-checks {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 8px 10px;
  background: #fff;
}
.channel-checks label {
  font-size: 13px;
  color: #2e4a68;
}
.monitor-layout {
  align-items: start;
}
#keywordTree .group {
  margin-bottom: 10px;
}
#keywordTree .group-title {
  font-weight: 600;
  margin-bottom: 6px;
}
#keywordTree button {
  width: 100%;
  text-align: left;
  margin-bottom: 6px;
}

.alert-list {
  display: grid;
  gap: 10px;
}

.alert-item {
  border: 1px solid var(--line);
  border-left: 4px solid var(--warn);
  border-radius: 10px;
  padding: 12px;
  background: #fffdf8;
}

.alert-item.high {
  border-left-color: var(--danger);
  background: #fff7f7;
}

.alert-item p {
  margin: 6px 0 0;
  color: var(--muted);
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.tag-cloud span {
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--primary-soft);
  color: #0a4b9b;
}

.insight-list {
  margin: 0;
  padding-left: 18px;
  color: #1d3f66;
  line-height: 1.7;
}
.brief-text {
  width: 100%;
  min-height: 240px;
  margin: 10px 0;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 10px;
  resize: vertical;
  font: inherit;
}
.brief-layout {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 12px;
}
.brief-side {
  border-right: 1px solid var(--line);
  padding-right: 10px;
  display: grid;
  gap: 8px;
  align-content: start;
}
.brief-side .brief-tab {
  text-align: left;
}
.brief-side .brief-tab.active {
  background: #e8f2ff;
  color: #1d5ea8;
  border-color: #8fc2ff;
}
.brief-main {
  min-width: 0;
}
.placeholder-card {
  border: 1px dashed #bad3ef;
  border-radius: 10px;
  padding: 28px;
  color: var(--muted);
  background: #f8fcff;
}

.ai-assistant-box {
  display: grid;
  gap: 10px;
}

.ai-panel-head {
  justify-content: flex-start;
}

.ai-input,
.ai-result {
  width: 100%;
  border: 1px dashed #bad3ef;
  border-radius: 10px;
  padding: 12px;
  background: #f8fcff;
  color: #36567a;
  font: inherit;
  resize: vertical;
}

.ai-input {
  min-height: 92px;
}

.ai-result {
  min-height: 170px;
}

.ai-result-hidden {
  display: none;
}

.ai-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.ai-plan-selector {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 0 0 10px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.ai-plan-label {
  flex: 0 0 auto;
  color: #486681;
  font-size: 13px;
  line-height: 30px;
}

.ai-plan-options {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  min-width: 0;
}

.ai-plan-chip {
  max-width: 180px;
  height: 30px !important;
  padding: 0 12px !important;
  border-radius: 999px !important;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  background: #fff !important;
  border-color: #9bc8ff !important;
  color: #0b5cad !important;
  font-size: 12px !important;
  font-weight: 400 !important;
}

.ai-plan-chip.active {
  background: #0b70f0 !important;
  border-color: #0b70f0 !important;
  color: #fff !important;
}

.ai-document-shell {
  border: 1px solid #d7e5f3;
  border-radius: 8px;
  background: #fff;
  overflow: hidden;
}

.ai-document-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border-bottom: 1px solid #e5eef8;
  background: #f8fbff;
}

.ai-document-toolbar h4 {
  margin: 0 0 3px;
  color: #17365c;
  font-size: 14px;
  font-weight: 400;
}

.ai-document-toolbar span {
  color: #6d829b;
  font-size: 12px;
}

.ai-document-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.ai-document-actions .ai-document-icon-btn {
  width: 38px !important;
  min-width: 38px !important;
  height: 34px !important;
  padding: 0 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  border-radius: 8px !important;
}

.ai-document-icon-btn svg {
  width: 17px;
  height: 17px;
  fill: currentColor;
  display: block;
}

.ai-document {
  min-height: 170px;
  max-height: 360px;
  overflow: auto;
  padding: 18px 22px;
  color: #17365c;
  background: #ffffff;
  line-height: 1.85;
}

.ai-document-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  color: #6d829b;
  text-align: center;
  border: 0;
  margin: 0;
  border-radius: 0;
  background: transparent;
}

.ai-document-title {
  margin: 0 0 6px;
  color: #082f58;
  font-size: 20px;
  font-weight: 400;
}

.ai-document-meta-line {
  margin-bottom: 14px;
  color: #6d829b;
  font-size: 12px;
}

.ai-document pre {
  margin: 0;
  white-space: pre-wrap;
  word-break: break-word;
  color: #17365c;
  font: inherit;
}

.ai-kpi-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(120px, 1fr));
  gap: 10px;
  margin-bottom: 10px;
}

.ai-kpi-card {
  border: 1px solid #dbe8f5;
  border-radius: 8px;
  background: #f8fbff;
  padding: 10px 12px;
  display: grid;
  gap: 6px;
}

.ai-kpi-card span {
  color: #6a7f96;
  font-size: 12px;
}

.ai-kpi-card strong {
  color: #1e3f64;
  font-size: 22px;
  line-height: 1;
}

.ai-chart-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 10px;
}

.ai-chart-card {
  border: 1px solid #dbe8f5;
  border-radius: 8px;
  background: #fff;
  padding: 10px;
}

.ai-chart-card h4 {
  margin: 0 0 8px;
  font-size: 14px;
  color: #214264;
}

.ai-chart-card canvas {
  width: 100%;
  height: auto;
  display: block;
}

@media (max-width: 980px) {
  .ai-kpi-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ai-chart-grid {
    grid-template-columns: 1fr;
  }
}

.login-mask {
  position: fixed;
  inset: 0;
  background: rgba(6, 21, 43, 0.45);
  backdrop-filter: blur(6px);
  display: grid;
  place-items: center;
  z-index: 10;
}

.login-card {
  width: min(420px, calc(100% - 28px));
  background: #fff;
  border-radius: 14px;
  border: 1px solid #dbe8f6;
  box-shadow: var(--shadow);
  padding: 18px;
  display: grid;
  gap: 10px;
}

.login-card h3 {
  margin: 0;
  text-align: center;
  color: #314563;
  font-size: 17px;
  font-weight: 400;
  letter-spacing: 0;
}

.login-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

#loginError {
  min-height: 18px;
  color: var(--danger);
}

.hidden {
  display: none !important;
}

.app-toast {
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%) scale(0.98);
  opacity: 0;
  z-index: 3000;
  pointer-events: none;
  padding: 12px 18px;
  border-radius: 8px;
  background: rgba(22, 32, 45, 0.92);
  color: #fff;
  font-size: 14px;
  line-height: 1.5;
  text-align: center;
  max-width: min(90vw, 520px);
  box-shadow: 0 12px 28px rgba(11, 30, 54, 0.28);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.app-toast.visible {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

@media (max-width: 1100px) {
  .cards {
    grid-template-columns: repeat(2, minmax(140px, 1fr));
  }

  .panel-grid.two {
    grid-template-columns: 1fr;
  }

  .tenant-user-form {
    grid-template-columns: 1fr 1fr;
  }

  .account-security-form {
    grid-template-columns: 1fr 1fr;
  }

  .role-permission-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 820px) {
  .app {
    grid-template-columns: 1fr;
  }

  .tenant-user-form {
    grid-template-columns: 1fr;
  }

  .account-security-form {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: sticky;
    top: 0;
    z-index: 2;
  }

  .topbar {
    flex-direction: column;
    align-items: flex-start;
  }

  .top-actions {
    width: 100%;
  }

  input[type="search"] {
    width: 100%;
  }

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

  .brief-layout {
    grid-template-columns: 1fr;
  }

  .plan-workspace {
    grid-template-columns: 1fr;
  }

  .plan-sidebar {
    min-height: auto;
  }

  .monitor-plan-form-modal {
    grid-template-columns: 1fr;
  }

  .brief-side {
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding-bottom: 10px;
    padding-right: 0;
  }
}

/* Reference-style overrides (match 新浪舆情界面风格) */
body {
  background: #f4f6f9;
}

.app {
  display: block;
}

.sidebar {
  position: sticky;
  top: 0;
  z-index: 5;
  background: #1f3553;
  height: 64px;
  padding: 0 14px;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 14px;
}

.brand {
  min-width: 166px;
}

.brand-logo {
  width: 58px;
  height: 24px;
  border-radius: 4px;
  background: transparent;
  color: #ff4a4a;
  font-style: italic;
  font-size: 18px;
}

.brand h1 {
  font-size: 17px;
}

.brand p {
  font-size: 11px;
  margin-top: 0;
}

.menu {
  display: flex;
  flex: 1;
  gap: 0;
  align-items: stretch;
  height: 100%;
}

.menu button {
  height: 100%;
  border-radius: 0;
  padding: 0 16px;
  color: #d4e3f5;
  border-bottom: 2px solid transparent;
}

.menu button.active,
.menu button:hover {
  background: rgba(45, 202, 216, 0.22);
  border-bottom-color: #2dcad8;
}

.sidebar-footer {
  margin-left: auto;
  margin-top: 0;
  border: 0;
  background: transparent;
  padding: 0;
  white-space: nowrap;
  color: #bdd0e5;
  display: flex;
  align-items: center;
  gap: 12px;
}

.sidebar-footer p {
  margin: 0;
}

.nav-user-tools {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav-user-tools a[href="/saas-admin"],
.nav-user-tools a[href$="/saas-admin"],
.nav-user-tools button:not(#logoutBtn) {
  display: none !important;
}

.sidebar-footer .util-user {
  color: #d8e4f4;
  font-size: 12px;
}

.sidebar-footer .util-logout {
  padding: 2px 10px;
  border-radius: 999px;
  border: 1px solid #7e95af;
  background: transparent;
  color: #d8e4f4;
  font-size: 12px;
  line-height: 1.4;
}

.main {
  padding: 10px 12px 12px;
}

.topbar {
  margin-bottom: 10px;
  background: #fff;
  border: 1px solid #e3e8ef;
  border-radius: 8px;
  padding: 8px 12px;
}

.topbar h2 {
  font-size: 18px;
}

.topbar p {
  margin-top: 2px;
  font-size: 12px;
}

.panel {
  border-radius: 8px;
  box-shadow: none;
  padding: 12px;
}

.panel-head h3 {
  font-size: 15px;
}

.monitor-advanced-filter {
  border: 1px solid #e5eaf1;
  border-radius: 8px;
  padding: 10px;
  background: #fbfdff;
  margin-bottom: 12px;
}

.monitor-row {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.monitor-row:last-child {
  margin-bottom: 0;
}

.monitor-label {
  color: #5c6f83;
  font-size: 13px;
}

.monitor-spacer {
  width: 18px;
}

.chip {
  border: 1px solid #d8e6ef;
  background: #fff;
  color: #4f647a;
  border-radius: 4px;
  padding: 4px 8px;
  font-size: 12px;
}

.chip.active {
  border-color: #56d2de;
  background: #ecfbfd;
  color: #1f93a1;
}

.monitor-multi-hint {
  color: #8da0b4;
  font-size: 12px;
  line-height: 1;
}

.monitor-row-form input,
.monitor-row-form select {
  height: 34px;
  border-radius: 4px;
  min-width: 0;
  width: 100%;
  font-size: 14px;
}

.monitor-row-form input {
  padding: 0 12px;
  line-height: 34px;
}

.monitor-row.monitor-row-form {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 8px;
}

.monitor-row.monitor-row-form .monitor-label {
  white-space: nowrap;
  flex: 0 0 auto;
  line-height: 32px;
}

#monitorKeyword {
  flex: 0 1 320px;
  min-width: 220px;
  max-width: 360px;
}

.monitor-row.monitor-row-form select {
  padding: 0 34px 0 12px;
  line-height: 1.4;
  appearance: auto;
  flex: 1 1 162px;
  min-width: 150px;
  max-width: 220px;
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;
}

#monitorPublishSort {
  flex: 0 0 170px;
  width: 170px;
  min-width: 170px;
  max-width: 170px;
}

#monitorSource {
  flex: 0 0 170px;
  width: 170px;
  min-width: 170px;
  max-width: 170px;
}

#monitorQueryBtn {
  flex: 0 0 auto;
  height: 34px;
  padding: 0 18px;
  border-radius: 10px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

#monitorQueryBtn.is-loading:disabled {
  opacity: 0.9;
}

.monitor-row.monitor-row-form button {
  white-space: nowrap;
}

.monitor-row-custom-time {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
}

.monitor-row-custom-time input {
  height: 34px;
  border-radius: 4px;
  border: 1px solid #d7e4f2;
  padding: 0 10px;
  color: #345370;
  min-width: 220px;
  max-width: 260px;
}

.report-hub {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 10px;
}

.report-hub-tabs {
  display: grid;
  gap: 6px;
  align-content: start;
}

.report-hub-tabs button {
  text-align: left;
  background: #fff;
}

.report-hub-tabs button.active {
  background: #eaf8fb;
  border-color: #69d6e1;
  color: #1f8f9b;
}

.report-event-cards {
  display: grid;
  grid-template-columns: repeat(4, minmax(180px, 1fr));
  gap: 10px;
}

.report-event-card {
  border: 1px solid #dce5ef;
  border-radius: 8px;
  background: #fff;
  overflow: hidden;
}

.report-event-card h4 {
  margin: 0;
  padding: 8px 10px;
  background: linear-gradient(90deg, #27c8d4, #6adbe4);
  color: #fff;
  font-size: 14px;
}

.report-event-card p {
  margin: 0;
  padding: 10px;
  font-size: 13px;
  color: #586b7f;
  line-height: 1.5;
  min-height: 132px;
}

.report-event-card small {
  display: block;
  padding: 0 10px 10px;
  color: #7f90a4;
}

.float-tools {
  position: fixed;
  right: 8px;
  top: 54%;
  transform: translateY(-50%);
  display: grid;
  gap: 8px;
  z-index: 8;
}

.float-tools button {
  width: 34px;
  height: 34px;
  border-radius: 6px;
  border: 1px solid #d4dce6;
  background: rgba(255, 255, 255, 0.96);
  color: #5f6f81;
  padding: 0;
}

@media (max-width: 980px) {
  .sidebar {
    height: auto;
    min-height: 58px;
    flex-wrap: wrap;
    padding: 8px;
  }

  .menu {
    width: 100%;
    overflow-x: auto;
    height: 40px;
  }

  .menu button {
    flex: 0 0 auto;
    padding: 0 12px;
  }

  .sidebar-footer {
    display: none;
  }

  .float-tools {
    right: 4px;
  }

  .report-hub {
    grid-template-columns: 1fr;
  }

  .report-event-cards {
    grid-template-columns: repeat(2, minmax(140px, 1fr));
  }
}

/* Refinements for video-like layout */
.utility-strip {
  position: sticky;
  top: 0;
  z-index: 7;
  height: 32px;
  background: #fff;
  border-bottom: 1px solid #e5eaf0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 12px 0 16px;
}

.utility-left,
.utility-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.service-note {
  color: #f08fa1;
  font-size: 12px;
}

.trial-pill {
  padding: 3px 8px;
  border-radius: 999px;
  border: 1px solid #ff9daf;
  background: #fff5f7;
  color: #db4d68;
  font-size: 11px;
}

.util-icon {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 1px solid #d9e1ea;
  display: grid;
  place-items: center;
  font-size: 11px;
  color: #7e8d9f;
}

.util-user {
  color: #55697f;
  font-size: 12px;
}

.util-logout {
  padding: 4px 10px;
  border-radius: 999px;
  background: #f6f8fb;
  border: 1px solid #d7e2ef;
  color: #4e647a;
  font-size: 12px;
}

.sidebar {
  top: 32px;
  height: 52px;
  z-index: 6;
}

.brand {
  min-width: 182px;
}

.brand-logo {
  font-size: 16px;
}

.menu button {
  font-size: 13px;
}

.topbar {
  padding: 8px 10px;
}

.top-actions button,
.top-actions input[type="search"] {
  height: 32px;
}

#monitorPage.page.active {
  grid-template-columns: var(--monitor-plan-panel-width, 220px) 8px minmax(0, 1fr);
  align-items: start;
}

body.limited-monitor-user #monitorPage.page.active {
  grid-template-columns: minmax(0, 1fr);
}

.monitor-plan-panel {
  border: 1px solid #dce4ef;
  border-radius: 8px;
  background: #f8fbff;
  padding: 10px;
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 10px;
  min-height: 0;
  height: calc(100vh - 132px);
  max-height: calc(100vh - 132px);
  position: sticky;
  top: 0;
  overflow: hidden;
}

.monitor-plan-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.monitor-plan-head h3 {
  margin: 0;
  font-size: 15px;
}

.monitor-plan-list {
  display: grid;
  align-content: start;
  gap: 8px;
  overflow: auto;
  min-height: 0;
}

.monitor-plan-resize-handle {
  position: relative;
  width: 8px;
  min-width: 8px;
  align-self: stretch;
  min-height: 100%;
  border-radius: 999px;
  cursor: col-resize;
  user-select: none;
  touch-action: none;
  background: transparent;
}

.monitor-plan-resize-handle::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 6px;
  bottom: 6px;
  width: 2px;
  transform: translateX(-50%);
  border-radius: 999px;
  background: #d9e4ef;
}

.monitor-plan-resize-handle:hover::before,
body.is-resizing-monitor-plan .monitor-plan-resize-handle::before {
  background: #9fc2e5;
}

body.is-resizing-monitor-plan {
  cursor: col-resize;
  user-select: none;
}

#monitorInfoPanel {
  max-height: calc(100vh - 132px);
  overflow-y: auto;
}

.monitor-panel-head {
  position: sticky;
  top: -12px;
  z-index: 3;
  background: #fff;
  border-bottom: 1px solid #e5edf5;
  margin: -12px -12px 12px;
  padding: 12px;
}

.monitor-head-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.monitor-head-left {
  display: flex;
  align-items: center;
  gap: 6px;
}

.monitor-head-actions .tiny-btn {
  padding: 4px 10px;
}

body.monitor-list-fullscreen {
  overflow: hidden;
}

body.monitor-list-fullscreen .utility-strip,
body.monitor-list-fullscreen .sidebar,
body.monitor-list-fullscreen .topbar {
  display: none;
}

body.monitor-list-fullscreen .app {
  grid-template-columns: 1fr;
}

body.monitor-list-fullscreen .main {
  padding: 0;
}

body.monitor-list-fullscreen #monitorPage.page.active {
  grid-template-columns: 1fr;
  gap: 0;
}

body.monitor-list-fullscreen #monitorPage .monitor-plan-panel {
  display: none;
}

body.monitor-list-fullscreen #monitorPage .monitor-plan-resize-handle {
  display: none;
}

body.monitor-list-fullscreen #monitorInfoPanel {
  position: fixed;
  inset: 10px;
  z-index: 80;
  margin: 0;
  height: auto;
  max-height: none;
  overflow-y: auto;
  border-radius: 10px;
}

.monitor-plan-list .plan-item {
  border-radius: 6px;
  padding: 8px;
}

.monitor-list-tools {
  display: flex;
  align-items: center;
  gap: 6px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #f9fbfe;
  padding: 6px 8px;
  margin-bottom: 10px;
}

.monitor-list-tools label {
  font-size: 12px;
  color: #5a6f83;
  margin-right: 4px;
}

.monitor-selected-count {
  font-size: 12px;
  color: #5a6f83;
  margin-right: 6px;
}

.monitor-list-tools button {
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 12px;
}

.monitor-plan-update-time {
  margin-left: auto;
  display: grid;
  grid-template-columns: 1fr;
  justify-content: flex-end;
  justify-items: end;
  gap: 4px;
  color: #52677d;
  font-size: 12px;
  white-space: normal;
}

.monitor-plan-update-row {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 4px 12px;
}

.monitor-plan-update-row span {
  white-space: nowrap;
}

.monitor-plan-update-time strong {
  color: #1f3c59;
  font-weight: 600;
}

.monitor-feed-list {
  display: grid;
  gap: 10px;
}

.monitor-loading-card {
  min-height: 148px;
  border: 1px dashed #c9dff7;
  border-radius: 10px;
  background: #f8fbff;
  color: #4f6480;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-size: 14px;
}

.monitor-loading-spinner {
  width: 18px;
  height: 18px;
  border-radius: 999px;
  border: 2px solid #5f95dc;
  border-right-color: transparent;
  animation: monitor-list-spin 0.8s linear infinite;
}

.monitor-loading-text {
  line-height: 1.4;
}

@keyframes monitor-list-spin {
  to {
    transform: rotate(360deg);
  }
}

.monitor-query-loading-mask {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(15, 32, 56, 0.32);
  backdrop-filter: blur(3px);
  z-index: 3200;
}

.monitor-query-loading-dialog {
  width: min(360px, calc(100% - 32px));
  background: #fff;
  border: 1px solid #d7e3f2;
  border-radius: 14px;
  box-shadow: 0 14px 36px rgba(11, 30, 54, 0.2);
  padding: 22px 18px;
  display: grid;
  justify-items: center;
  gap: 12px;
}

.monitor-query-loading-spinner {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  border: 3px solid #b5d0f2;
  border-top-color: #1663d5;
  animation: monitor-query-loading-spin 0.85s linear infinite;
}

.monitor-query-loading-text {
  margin: 0;
  color: #284866;
  font-size: 14px;
  line-height: 1.5;
  text-align: center;
}

@keyframes monitor-query-loading-spin {
  to {
    transform: rotate(360deg);
  }
}

.monitor-feed-item {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #fff;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  align-items: stretch;
}

.monitor-feed-item[data-link] {
  cursor: pointer;
}

.monitor-feed-item.high {
  border-left: 4px solid #e35757;
}

.monitor-feed-item.mid {
  border-left: 4px solid #f1b24f;
}

.monitor-feed-item.low {
  border-left: 4px solid #54be7d;
}

.monitor-feed-main {
  padding: 10px 12px;
  min-width: 0;
}

.monitor-feed-select {
  display: flex;
  align-items: center;
  justify-content: center;
}

.monitor-feed-titleline {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.monitor-item-check {
  display: inline-flex;
  align-items: center;
}

.monitor-item-check input {
  width: 14px;
  height: 14px;
}

.monitor-feed-titleline strong {
  font-size: 14px;
  color: #182e46;
}

.monitor-feed-title-link {
  font-size: 14px;
  color: #182e46;
  text-decoration: none;
  font-weight: 700;
}

.monitor-feed-title-link:hover {
  color: #0b70f0;
  text-decoration: underline;
}

.feed-tag {
  border: 1px solid #d7e4f2;
  border-radius: 3px;
  background: #f8fbff;
  color: #5f7387;
  padding: 2px 6px;
  font-size: 11px;
}

.feed-tag.risk-high {
  border-color: #f5c1c1;
  color: #c24040;
  background: #fff3f3;
}

.feed-tag.risk-mid {
  border-color: #f7dfab;
  color: #b37d1e;
  background: #fff8ea;
}

.feed-tag.risk-low {
  border-color: #bfead0;
  color: #2f9460;
  background: #effbf4;
}

.feed-tag.monitor-favorite-tag {
  border-color: #ffe1a9;
  background: #fff6e6;
  color: #a36a04;
}

.monitor-sensitivity-select {
  height: 24px;
  border: 1px solid #d7e4f2;
  border-radius: 4px;
  background: #fff;
  color: #33536f;
  font-size: 12px;
  padding: 0 6px;
}

.monitor-sensitivity-badge {
  border: 1px solid #d7e4f2;
  border-radius: 4px;
  background: #f8fbff;
  color: #536a82;
  font-size: 12px;
  line-height: 22px;
  padding: 0 6px;
}

.monitor-feed-side-tools {
  border-left: 1px solid #ebf0f5;
  padding: 0 10px 0 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.monitor-item-icon-btn {
  width: 24px;
  height: 24px;
  border: 1px solid #d2deec;
  background: #f7fbff;
  color: #55708a;
  border-radius: 4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  font-size: 13px;
  padding: 0;
  cursor: pointer;
}

.monitor-item-icon-btn:hover {
  border-color: #9ebde0;
  color: #2d5f91;
  background: #edf6ff;
}

.monitor-item-icon-btn svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.monitor-item-delete-btn {
  color: #55708a;
  font-size: 14px;
}

.monitor-item-delete-btn:hover {
  color: #2d5f91;
}

.monitor-fav-toggle {
  color: #9bb0c5;
  font-size: 15px;
  line-height: 1;
}

.monitor-fav-toggle.active {
  color: #f2b635;
  border-color: #f0cf83;
  background: #fff8e8;
}

.monitor-fav-toggle:hover {
  color: #f2b635;
  border-color: #f0cf83;
  background: #fff8e8;
}

.monitor-feed-body {
  margin-top: 8px;
}

.monitor-feed-body.with-thumb {
  width: 130px;
}

.monitor-feed-thumb {
  border-radius: 6px;
  border: 1px solid #dce4ef;
  background: #eef3f9;
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.monitor-feed-thumb-image {
  width: 100%;
  height: 100%;
  min-height: 74px;
  object-fit: cover;
  display: block;
}

.monitor-feed-meta {
  margin-top: 8px;
  color: #4b647f;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.5;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.monitor-feed-meta-text {
  min-width: 0;
  color: #3f5a75;
}

.monitor-item-copy-link {
  font-size: 13px;
}

.monitor-item-copy-link:hover {
  border-color: #8cb6e2;
  color: #1f5f97;
  background: #eef6ff;
}

.monitor-item-copy-link:disabled {
  cursor: not-allowed;
  color: #9aaab9;
  border-color: #dde6ef;
  background: #f7f9fb;
}

.monitor-feed-actions {
  margin-top: 8px;
  color: #8192a5;
  font-size: 12px;
}

.monitor-feed-actions {
  display: flex;
  gap: 12px;
}

.monitor-feed-side {
  border-left: 1px solid #ebf0f5;
  background: #fafcff;
  display: grid;
  align-content: center;
  gap: 10px;
  padding: 10px;
}

.monitor-feed-side div {
  display: grid;
  gap: 2px;
}

.monitor-feed-side small {
  color: #8193a7;
  font-size: 11px;
}

.monitor-feed-side strong {
  color: #2e475f;
  font-size: 13px;
}

.monitor-bottom-tools {
  margin-top: 10px;
  border: 1px solid #e3e8f0;
  border-radius: 8px;
  background: #f9fbfd;
  padding: 8px 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.monitor-bottom-left,
.monitor-bottom-right {
  display: flex;
  align-items: center;
  gap: 6px;
}

.monitor-page-number-list {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.monitor-page-number-list button {
  min-width: 34px;
}

#monitorPagePrevBtn,
#monitorPageNextBtn,
.monitor-page-number-list button,
#monitorPageJumpBtn {
  height: 30px;
  min-height: 30px;
  box-sizing: border-box;
  padding-top: 0;
  padding-bottom: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.monitor-page-ellipsis {
  color: #8aa0b6;
  font-size: 12px;
  line-height: 1;
}

.monitor-bottom-tools span {
  font-size: 12px;
  color: #637a91;
}

.monitor-bottom-right input {
  width: 52px;
  height: 30px;
  border-radius: 4px;
  padding: 4px 6px;
}

.monitor-layout-secondary {
  margin-top: 12px;
}

.report-hub-main {
  display: grid;
  gap: 10px;
}

.report-hub-filter {
  display: grid;
  grid-template-columns: 150px 150px 1fr 88px;
  gap: 8px;
}

.report-hub-filter input {
  height: 34px;
  border-radius: 6px;
}

.report-event-card h4 {
  min-height: 66px;
  display: flex;
  align-items: center;
}

.brief-layout {
  grid-template-columns: 110px 1fr;
}

.brief-side {
  border-right: 1px solid #e3ebf4;
  padding-right: 10px;
  gap: 10px;
}

.brief-side .brief-tab {
  min-height: 86px;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 6px;
  text-align: center;
  font-size: 13px;
  border-radius: 6px;
}

.brief-side .brief-tab::before {
  content: attr(data-icon);
  width: 28px;
  height: 28px;
  border-radius: 6px;
  border: 1px solid #8adbe4;
  color: #2aaeb9;
  display: grid;
  place-items: center;
  font-weight: 700;
  background: #ecfcfd;
}

.float-tools button {
  font-size: 11px;
  font-weight: 600;
}

.float-tools .primary-float {
  background: linear-gradient(135deg, #8666ff, #c38cf6);
  border-color: #8d76f5;
  color: #fff;
}

@media (max-width: 980px) {
  .utility-strip {
    height: auto;
    padding: 6px 8px;
    flex-wrap: wrap;
    gap: 6px;
  }

  .service-note {
    display: none;
  }

  .sidebar {
    top: 0;
  }

  #monitorPage.page.active {
    grid-template-columns: 1fr;
  }

  .monitor-plan-resize-handle {
    display: none;
  }

  .monitor-plan-panel {
    min-height: auto;
    height: auto;
    max-height: none;
    position: static;
  }

  #monitorInfoPanel {
    max-height: none;
    overflow: visible;
  }

  .monitor-panel-head {
    position: static;
    margin: 0 0 12px;
    padding: 0 0 8px;
  }

  .monitor-feed-item {
    grid-template-columns: 34px minmax(0, 1fr) auto;
  }

  .monitor-row.monitor-row-form {
    align-items: stretch;
  }

  .monitor-row.monitor-row-form .monitor-label {
    margin-bottom: -2px;
    line-height: 1.4;
    flex-basis: 100%;
  }

  #monitorKeyword,
  .monitor-row.monitor-row-form select {
    flex-basis: 100%;
    min-width: 0;
    max-width: none;
  }

  #monitorSource,
  #monitorPublishSort {
    width: 100%;
    min-width: 0;
    max-width: none;
    flex: 1 1 100%;
  }

  #warningLogStartAt,
  #warningLogEndAt,
  #warningLogPlan,
  #warningLogSource,
  #warningLogKeyword {
    width: 100%;
    min-width: 0;
    max-width: none;
    flex: 1 1 100%;
  }

  .warning-log-filter-sep {
    display: none;
  }

  .monitor-feed-side {
    border-left: 0;
    border-top: 1px solid #ebf0f5;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .monitor-bottom-tools {
    flex-wrap: wrap;
    gap: 8px;
  }

  .report-hub-filter {
    grid-template-columns: 1fr 1fr;
  }

  .brief-layout {
    grid-template-columns: 1fr;
  }

  .brief-side {
    border-right: 0;
    border-bottom: 1px solid #e3ebf4;
    padding-right: 0;
    padding-bottom: 8px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .brief-side .brief-tab {
    min-height: 64px;
  }
}

/* Create monitor plan: layout like reference image 2 */
#monitorPlanModal {
  z-index: 2600;
  padding: 18px;
  place-items: center;
}

#monitorPlanModal .monitor-plan-sheet {
  width: min(1120px, calc(100% - 56px));
  max-height: calc(100vh - 36px);
  overflow: auto;
  background: #fff;
  border: 1px solid #dce6f1;
  border-radius: 10px;
  padding: 20px 24px 18px;
  box-shadow: 0 18px 48px rgba(15, 34, 56, 0.2);
}

.monitor-plan-title {
  margin: 0;
  font-size: 30px;
  font-weight: 600;
  color: #1f3c59;
}

.monitor-plan-editor {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid #e6edf5;
  display: grid;
  gap: 10px;
}

.monitor-plan-row {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 10px;
  align-items: center;
}

.monitor-plan-row.align-top {
  align-items: start;
}

.monitor-plan-row > label {
  font-size: 14px;
  color: #2a465f;
  text-align: right;
}

.monitor-plan-cell {
  min-width: 0;
}

.monitor-plan-cell.inline {
  display: grid;
  grid-template-columns: 1fr 100px;
  gap: 8px;
  max-width: 920px;
}

.monitor-plan-cell input,
.monitor-plan-cell select,
.monitor-plan-cell textarea {
  width: 100%;
  border: 1px solid #d3e1ee;
  border-radius: 4px;
  background: #fff;
  padding: 10px 12px;
  color: #27415b;
  font-size: 14px;
}

.monitor-plan-cell textarea {
  min-height: 116px;
  resize: vertical;
}
.monitor-plan-time-range {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 8px;
}
.monitor-plan-time-range > span {
  color: #6a7f95;
  font-size: 13px;
}

#monitorPlanKeywords {
  min-height: 140px;
}

.domain-picker {
  position: relative;
}

.domain-input-wrap {
  min-height: 40px;
  border: 1px solid #d3e1ee;
  border-radius: 4px;
  background: #fff;
  padding: 4px 6px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.domain-input-wrap:focus-within {
  border-color: #64c5df;
  box-shadow: 0 0 0 2px rgba(67, 186, 214, 0.1);
}

.domain-input-wrap.loading {
  border-color: #4fb7d3;
}

.domain-tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.domain-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #edf8fd;
  border: 1px solid #bfe2ee;
  color: #2d5f79;
  border-radius: 3px;
  padding: 3px 8px;
  font-size: 12px;
  line-height: 1;
}

.domain-tag button {
  border: 0;
  background: transparent;
  color: #6f8aa0;
  padding: 0;
  font-size: 12px;
  line-height: 1;
}

#monitorPlanDomainsInput {
  border: 0;
  outline: 0;
  padding: 6px 4px;
  min-width: 180px;
  flex: 1;
}

.domain-suggest {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 4px);
  z-index: 16;
  border: 1px solid #cddae8;
  border-radius: 4px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(21, 43, 68, 0.12);
  max-height: 240px;
  overflow: auto;
}

.domain-suggest button {
  width: 100%;
  border: 0;
  border-radius: 0;
  background: #fff;
  color: #29455f;
  text-align: left;
  padding: 8px 10px;
  font-size: 13px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
}

.domain-main {
  color: #264863;
}

.domain-hierarchy {
  color: #7e95ab;
  font-size: 12px;
}

.domain-suggest button:hover,
.domain-suggest button.active {
  background: #ebf9fd;
}

.domain-empty {
  padding: 10px;
  color: #7a8ea4;
  font-size: 12px;
}

.domain-loading {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #5d7f9f;
}

.domain-inline-spinner {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid #c8dced;
  border-top-color: #2f8fcb;
  display: inline-block;
  animation: domainSpin 0.8s linear infinite;
}

@keyframes domainSpin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

.plan-source-selector {
  min-height: 42px;
  border: 1px solid #d3e1ee;
  border-radius: 4px;
  background: #fff;
  padding: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.plan-source-selector.readonly {
  opacity: 0.65;
  pointer-events: none;
}

.plan-source-chip {
  border: 1px solid #cfdceb;
  border-radius: 14px;
  background: #fff;
  color: #3d5a74;
  font-size: 12px;
  padding: 4px 10px;
}

.plan-source-chip.active {
  border-color: #6ab6ff;
  background: #e8f5ff;
  color: #1f5f9e;
}

.plan-source-selector .plan-source-inline-input {
  min-width: 220px;
  flex: 1;
  width: auto;
  border: 0;
  outline: 0;
  box-shadow: none;
  border-radius: 0;
  padding: 4px 2px;
  color: #2a4762;
  font-size: 13px;
  background: transparent;
}

.plan-source-selector .plan-source-inline-input::placeholder {
  color: #8aa1b8;
}

.plan-source-empty {
  color: #7a8ea4;
  font-size: 12px;
  padding: 2px 4px;
}

.plan-source-hint {
  margin: 6px 0 0;
  color: #6ea6cc;
  font-size: 12px;
}

.plan-source-custom {
  margin-top: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}

#monitorPlanSourceCount {
  color: #6f86a1;
}

#monitorPlanCustomSourceInput {
  min-width: 260px;
  flex: 1;
  border: 1px solid #cbdced;
  border-radius: 6px;
  background: #fff;
  color: #1f3c59;
  font-size: 13px;
  padding: 8px 10px;
}

#monitorPlanCustomSourceInput::placeholder {
  color: #8aa1b8;
}

.monitor-plan-hint {
  margin: -2px 0 0 130px;
  color: #54b8d4;
  font-size: 12px;
}

.ai-tag {
  display: inline-grid;
  place-items: center;
  width: 20px;
  height: 16px;
  border-radius: 4px;
  font-size: 11px;
  background: #efe8ff;
  color: #6e4cd6;
}

.inline-keyword-tools {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #4f6580;
  font-size: 13px;
}

.link-btn {
  border: 0;
  background: transparent;
  color: #46b9d7;
  padding: 0;
  font-size: 13px;
}

.link-btn.strong {
  font-weight: 600;
}

.tiny-btn {
  border: 1px solid #c9d9ea;
  background: #f7fafd;
  color: #4b6077;
  border-radius: 4px;
  padding: 5px 10px;
  font-size: 12px;
}

.field-tools {
  margin-top: 6px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  color: #87a0ba;
  font-size: 12px;
}

.field-tools > div {
  display: flex;
  gap: 6px;
}

.plan-logic-hint {
  margin: 4px 0 0;
  color: #6ea6cc;
  font-size: 12px;
}

.plan-logic-example-panel {
  margin-top: 6px;
  border: 1px dashed #c9deef;
  border-radius: 6px;
  background: #f7fbff;
  padding: 8px 10px;
  color: #55748f;
  font-size: 12px;
  line-height: 1.6;
}

.plan-logic-example-panel p {
  margin: 0 0 4px;
  color: #3d5c78;
}

.plan-logic-example-panel ul {
  margin: 0;
  padding-left: 16px;
}

.plan-keyword-library {
  margin-top: 8px;
  border: 1px solid #d9e5f1;
  border-radius: 6px;
  background: #fbfdff;
  padding: 10px;
  display: grid;
  gap: 8px;
}

.plan-keyword-head {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  color: #4a627b;
  font-size: 13px;
}

.plan-keyword-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.plan-keyword-tabs button {
  border: 1px solid #cddbeb;
  border-radius: 14px;
  background: #fff;
  color: #3a5872;
  font-size: 12px;
  padding: 4px 10px;
}

.plan-keyword-tabs button.active {
  background: #e9f4ff;
  border-color: #8fc2ff;
  color: #1d5ea8;
}

#planKeywordLibrarySearchInput {
  margin-left: auto;
  min-width: 260px;
  border: 1px solid #cddbeb;
  border-radius: 8px;
  background: #fff;
  color: #1f3c59;
  font-size: 13px;
  padding: 8px 10px;
}

#planKeywordLibrarySearchInput::placeholder {
  color: #89a0b8;
}

.plan-keyword-list {
  display: grid;
  gap: 10px;
  min-height: 80px;
  align-content: flex-start;
}

.plan-keyword-group {
  border: 1px solid #d8e4f1;
  border-radius: 8px;
  background: #ffffff;
  padding: 10px;
  display: grid;
  gap: 8px;
}

.plan-keyword-group-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.plan-keyword-group-head strong {
  color: #23435f;
  font-size: 13px;
}

.plan-keyword-group-select-btn {
  border: 1px solid #cfe0f1;
  border-radius: 10px;
  padding: 2px 8px;
  font-size: 11px;
  color: #4e6a86;
  background: #f6fbff;
  cursor: pointer;
}

.plan-keyword-group-select-btn:hover {
  border-color: #9fc3e8;
  color: #2f5f8a;
  background: #eef6ff;
}

.plan-keyword-group-select-btn.active {
  border-color: #6ab6ff;
  color: #1f5f9e;
  background: #e8f5ff;
}

.plan-keyword-group-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.plan-keyword-group-list button {
  border: 1px solid #d0dce9;
  border-radius: 14px;
  background: #fff;
  color: #3d5a74;
  font-size: 12px;
  padding: 4px 10px;
}

.plan-keyword-group-list button.active {
  border-color: #6ab6ff;
  background: #e8f5ff;
  color: #1f5f9e;
}

.plan-keyword-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  color: #6f86a1;
  font-size: 12px;
}

.plan-keyword-actions > div {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

#planKeywordLibraryDialog {
  z-index: 18;
}

#monitorSourceLibraryDialog {
  z-index: 19;
}

#reportSnapshotModeDialog {
  z-index: 20;
}

#reportSnapshotModeDialog .confirm-dialog-card {
  width: min(680px, calc(100% - 28px));
}

#reportSnapshotModeDialog .modal-actions {
  justify-content: flex-end;
}

#reportSnapshotModeDialog .modal-actions button {
  min-width: 120px;
  border-radius: 8px;
}

#reportSnapshotHistoryDialog {
  z-index: 21;
}

.plan-keyword-dialog {
  width: min(1220px, calc(100% - 28px));
  max-height: calc(100vh - 34px);
  overflow: auto;
  background: #fff;
  border: 1px solid #d8e4f0;
  border-radius: 10px;
  box-shadow: 0 20px 54px rgba(16, 34, 58, 0.24);
  padding: 18px 20px;
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 10px;
}

.plan-keyword-dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.plan-keyword-dialog-tools {
  display: flex;
  align-items: center;
  gap: 8px;
}

.plan-keyword-dialog-head h3 {
  margin: 0;
  font-size: 26px;
  color: #1f3c59;
}

#toggleKeywordLibraryFullscreenBtn {
  min-width: 72px;
}

.plan-keyword-dialog .plan-keyword-library {
  margin-top: 0;
  min-height: 560px;
}

.plan-keyword-dialog .plan-keyword-list {
  max-height: 520px;
  overflow: auto;
  align-content: flex-start;
}

.plan-keyword-dialog .modal-actions {
  justify-content: flex-end;
}

.source-library-dialog {
  width: min(980px, calc(100% - 28px));
}

.source-library-panel {
  border: 1px solid #d9e5f1;
  border-radius: 6px;
  background: #fbfdff;
  padding: 10px;
  display: grid;
  gap: 10px;
}

.source-library-categories {
  display: flex;
  align-items: center;
  gap: 8px;
}

.source-library-categories > span {
  color: #55718c;
  font-size: 13px;
  white-space: nowrap;
}

#monitorSourceLibraryTabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.source-library-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.source-library-head input[type="search"] {
  flex: 1;
  min-width: 220px;
  border: 1px solid #ccdaea;
  border-radius: 6px;
  padding: 8px 10px;
  background: #fff;
  color: #29445f;
  font-size: 13px;
}

.source-library-head > div {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.source-library-maintain {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 200px auto;
  gap: 8px;
  align-items: center;
}

.source-library-maintain input {
  border: 1px solid #ccdaea;
  border-radius: 6px;
  padding: 8px 10px;
  background: #fff;
  color: #29445f;
  font-size: 13px;
}

.source-library-list {
  max-height: 420px;
  overflow: auto;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-content: flex-start;
}

.source-library-chip {
  border: 1px solid #cfdceb;
  border-radius: 14px;
  background: #fff;
  color: #3d5a74;
  font-size: 12px;
  padding: 4px 10px;
}

.source-library-chip.active {
  border-color: #6ab6ff;
  background: #e8f5ff;
  color: #1f5f9e;
}

.source-library-empty {
  color: #7a8ea4;
  font-size: 12px;
  padding: 6px 4px;
}

.source-library-loading {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #5d7f9f;
}

.report-snapshot-history-list {
  max-height: 420px;
  overflow: auto;
  display: grid;
  gap: 8px;
}

.report-snapshot-history-item {
  width: 100%;
  text-align: left;
  border: 1px solid #d4e0ed;
  border-radius: 8px;
  background: #fff;
  color: #2f4a64;
  padding: 10px 12px;
  display: grid;
  gap: 6px;
}

.report-snapshot-history-item strong {
  font-size: 13px;
  color: #1f3c59;
}

.report-snapshot-history-item small {
  color: #6f86a1;
  font-size: 12px;
}

.report-snapshot-latest-card {
  border: 1px solid #d9e5f1;
  border-radius: 8px;
  background: #f8fbff;
  padding: 10px 12px;
  display: grid;
  gap: 6px;
}

.report-snapshot-latest-line {
  margin: 0;
  color: #385775;
  font-size: 13px;
  line-height: 1.5;
}

.report-snapshot-inline-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 2px;
}

.report-snapshot-icon-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid #bfd3e7;
  border-radius: 999px;
  background: #fff;
  color: #1f5f9e;
  font-size: 12px;
  padding: 4px 10px;
  cursor: pointer;
}

.report-snapshot-icon-btn:hover:not(:disabled) {
  border-color: #7eb8f3;
  background: #eef7ff;
}

.report-snapshot-icon-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.report-snapshot-icon {
  display: inline-flex;
  width: 14px;
  height: 14px;
}

.report-snapshot-icon svg {
  width: 14px;
  height: 14px;
  display: block;
  fill: currentColor;
}

.plan-keyword-dialog.is-fullscreen {
  width: calc(100vw - 12px);
  max-width: none;
  height: calc(100vh - 12px);
  max-height: none;
  border-radius: 8px;
  padding: 14px 16px;
  overflow: hidden;
}

.plan-keyword-dialog.is-fullscreen .plan-keyword-library {
  min-height: 0;
}

.plan-keyword-dialog.is-fullscreen .plan-keyword-list {
  max-height: none;
  height: 100%;
}

#monitorPlanModal .modal-actions {
  margin-top: 6px;
  justify-content: flex-end;
}

#monitorPlanModal .modal-actions button {
  min-width: 90px;
  border-radius: 8px;
}

#monitorWarningModal {
  z-index: 3200;
}

.monitor-warning-sheet {
  width: min(560px, calc(100% - 24px));
  max-height: calc(100vh - 32px);
  overflow: auto;
  background: #fff;
  border: 1px solid #d8e4f0;
  border-radius: 10px;
  box-shadow: 0 20px 54px rgba(16, 34, 58, 0.24);
  padding: 18px 20px 16px;
  display: grid;
  gap: 10px;
}

.monitor-warning-title {
  margin: 0;
  font-size: 24px;
  color: #1f3c59;
}

.monitor-warning-subtitle {
  margin: 0;
  font-size: 13px;
  color: #5d738a;
}

.monitor-warning-intro {
  margin: 0;
  padding: 8px 10px;
  border: 1px solid #d8e9ff;
  border-radius: 8px;
  background: #f3f8ff;
  color: #4f6f8d;
  font-size: 12px;
  line-height: 1.6;
}

.monitor-warning-intro p {
  margin: 0;
}

.monitor-warning-intro p + p {
  margin-top: 5px;
}

.monitor-warning-form {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 12px;
  align-items: start;
}

.monitor-warning-form > label {
  color: #415d78;
  font-size: 14px;
  line-height: 38px;
}

.monitor-warning-field {
  display: grid;
  gap: 5px;
}

.monitor-warning-field p {
  margin: 0;
  color: #6b7f95;
  font-size: 12px;
  line-height: 1.5;
}

.monitor-warning-form input {
  border-radius: 8px;
}

.monitor-warning-range {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 8px;
}

.monitor-warning-range > span {
  color: #5d738a;
  font-size: 13px;
}

.monitor-warning-channels {
  min-height: 40px;
}

#monitorWarningModal .modal-actions {
  margin-top: 4px;
}

#monitorWarningModal .modal-actions button {
  min-width: 96px;
  border-radius: 8px;
}

#confirmDialog {
  z-index: 22;
}

.confirm-dialog-card {
  width: min(520px, calc(100% - 28px));
  background: #fff;
  border: 1px solid #d8e4f0;
  border-radius: 12px;
  box-shadow: 0 20px 54px rgba(16, 34, 58, 0.24);
  padding: 18px 20px;
  display: grid;
  gap: 10px;
}

.confirm-dialog-card h3 {
  margin: 0;
  font-size: 22px;
  color: #1f3c59;
}

.confirm-dialog-card p {
  margin: 0;
  color: #385775;
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-word;
}

#confirmDialog .modal-actions {
  margin-top: 4px;
}

#confirmDialog .modal-actions button {
  min-width: 90px;
  border-radius: 8px;
}

@media (max-width: 980px) {
  #monitorPlanModal .monitor-plan-sheet {
    width: calc(100% - 14px);
    max-height: calc(100vh - 20px);
    padding: 14px;
  }

  .monitor-plan-title {
    font-size: 22px;
  }

  .monitor-plan-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .monitor-plan-row > label {
    text-align: left;
  }

  .monitor-plan-cell.inline {
    grid-template-columns: 1fr;
  }
  .monitor-plan-time-range {
    grid-template-columns: 1fr;
    gap: 6px;
  }
  .monitor-plan-time-range > span {
    display: none;
  }

  .monitor-plan-hint {
    margin-left: 0;
  }

  .inline-keyword-tools {
    flex-wrap: wrap;
  }

  .plan-source-custom {
    flex-direction: column;
    align-items: stretch;
  }

  #monitorPlanCustomSourceInput {
    min-width: 0;
    width: 100%;
  }

  .plan-keyword-dialog {
    width: calc(100% - 14px);
    max-height: calc(100vh - 20px);
    padding: 12px;
  }

  .source-library-head {
    flex-direction: column;
    align-items: stretch;
  }

  .source-library-head input[type="search"] {
    min-width: 0;
    width: 100%;
  }

  .source-library-categories {
    flex-direction: column;
    align-items: flex-start;
  }

  .source-library-maintain {
    grid-template-columns: 1fr;
  }

  .plan-keyword-dialog-head h3 {
    font-size: 20px;
  }

  #planKeywordLibrarySearchInput {
    margin-left: 0;
    min-width: 0;
    width: 100%;
  }

  .monitor-warning-sheet {
    width: calc(100% - 14px);
    padding: 12px;
  }

  .monitor-warning-title {
    font-size: 20px;
  }

  .monitor-warning-form {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .monitor-warning-form > label {
    line-height: 1.4;
  }
}

/* Prewarning list style like reference */
#tasksPage.page.active {
  display: block;
}

#tasksPage .plan-workspace {
  grid-template-columns: 1fr;
  padding: 0;
  border-radius: 6px;
  box-shadow: none;
}

#tasksPage .plan-sidebar,
#tasksPage .plan-main-head,
#tasksPage #preTabInfo,
#tasksPage #preTabChart,
#tasksPage #preTabPlan {
  display: none !important;
}

#tasksPage #preTabWarning {
  display: block !important;
}

#tasksPage #preTabWarning > .task-form.warning-form,
#tasksPage #warningSummary,
#tasksPage #preTabWarning > article:not(.prewarning-log-panel) {
  display: none;
}

#tasksPage .prewarning-log-panel {
  border: 0;
  background: transparent;
  box-shadow: none;
  padding: 8px 12px 12px;
}

#tasksPage .prewarning-log-panel > .panel-head {
  display: none;
}

#tasksPage .warning-log-filter-compact {
  display: grid;
  grid-template-columns: minmax(420px, 1.45fr) minmax(180px, 0.85fr) minmax(170px, 0.8fr) minmax(260px, 1.1fr) auto;
  align-items: end;
  gap: 10px 12px;
  margin: 0 0 12px;
  padding: 12px 14px;
  border: 1px solid #d4e1ef;
  border-radius: 12px;
  background: linear-gradient(180deg, #fbfdff 0%, #f4f8fe 100%);
  box-shadow: 0 6px 16px rgba(24, 52, 86, 0.06);
}

#tasksPage .warning-log-filter-date-group,
#tasksPage .warning-log-filter-field {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

#tasksPage .warning-log-filter-date-range {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

#tasksPage .warning-log-date-field {
  position: relative;
  min-width: 0;
}

#tasksPage .warning-log-date-format-tip {
  color: #6b839b;
  font-size: 11px;
  line-height: 1;
  letter-spacing: 0.2px;
  padding-left: 4px;
}

#tasksPage .warning-log-readable-tip {
  margin: -2px 0 10px;
  padding: 8px 10px;
  border: 1px solid #d7e6f5;
  border-radius: 10px;
  background: #f6faff;
  color: #4f6881;
  font-size: 12px;
  line-height: 1.5;
}

#tasksPage .warning-log-filter-actions {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 40px;
}

#tasksPage .warning-log-filter-compact .warning-log-filter-label {
  white-space: nowrap;
  color: #4f667f;
  font-size: 12px;
  line-height: 1;
  letter-spacing: 0.3px;
  font-weight: 600;
}

#tasksPage .warning-log-filter-compact input:not(.warning-log-date-picker-native),
#tasksPage .warning-log-filter-compact select,
#tasksPage .warning-log-filter-compact button:not(.warning-log-date-picker-btn) {
  height: 40px;
  border-radius: 10px;
  flex: 0 0 auto;
  border: 1px solid #c8d7e8;
  background: #fff;
  color: #2b4561;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease, transform 0.15s ease;
}

#tasksPage .warning-log-filter-compact select {
  padding: 0 34px 0 12px;
  line-height: 38px;
  font-size: 14px;
}

#tasksPage .warning-log-filter-compact input:not(.warning-log-date-picker-native) {
  padding: 0 12px;
  line-height: 38px;
}

#tasksPage .warning-log-filter-compact input:not(.warning-log-date-picker-native):focus,
#tasksPage .warning-log-filter-compact select:focus {
  border-color: #4da3d6;
  box-shadow: 0 0 0 3px rgba(77, 163, 214, 0.15);
  outline: none;
}

#tasksPage .warning-log-filter-sep {
  color: #5d7691;
  font-size: 11px;
  line-height: 1;
  padding: 2px 8px;
  font-weight: 600;
  user-select: none;
  border-radius: 999px;
  background: #edf4fc;
  border: 1px solid #d5e2f1;
}

#tasksPage #warningLogStartAt,
#tasksPage #warningLogEndAt,
#tasksPage #warningLogPlan,
#tasksPage #warningLogSource,
#tasksPage #warningLogKeyword {
  width: 100%;
  min-width: 0;
}

#tasksPage #warningLogStartAt,
#tasksPage #warningLogEndAt {
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.1px;
  font-size: 14px;
  min-width: 0;
  max-width: none;
  height: 34px;
  border-radius: 4px;
  border: 1px solid #d7e4f2;
  padding: 0 36px 0 10px;
  color: #345370;
  background: #f8fbff;
  width: 100%;
  line-height: 34px;
}

#tasksPage .warning-log-date-input {
  box-shadow: none;
  font-family: inherit;
  font-weight: 500;
  color: #345370;
}

#tasksPage .warning-log-date-input::placeholder {
  color: #6f8aa3;
  letter-spacing: 0.2px;
}

#tasksPage .warning-log-filter-compact .warning-log-date-picker-btn {
  position: absolute;
  right: 6px;
  top: 50%;
  width: 22px;
  height: 22px;
  transform: translateY(-50%);
  border: 0;
  border-radius: 4px;
  background: transparent;
  padding: 0;
  min-width: 0;
  line-height: 1;
  box-shadow: none;
  cursor: pointer;
}

#tasksPage .warning-log-filter-compact .warning-log-date-picker-btn::before {
  content: "";
  position: absolute;
  left: 5px;
  top: 4px;
  width: 10px;
  height: 10px;
  border: 1.4px solid #5a738d;
  border-top-width: 4px;
  border-radius: 2px;
}

#tasksPage .warning-log-filter-compact .warning-log-date-picker-btn:hover {
  background: rgba(76, 122, 170, 0.1);
}

#tasksPage .warning-log-filter-compact .warning-log-date-picker-btn:focus {
  outline: none;
  box-shadow: 0 0 0 2px rgba(77, 163, 214, 0.15);
}

#tasksPage .warning-log-filter-compact .warning-log-date-picker-native {
  position: absolute;
  right: 0;
  top: 0;
  width: 1px;
  height: 1px;
  opacity: 0;
  border: 0;
  padding: 0;
  pointer-events: none;
}

#tasksPage #warningLogPlan {
  max-width: 280px;
}

#tasksPage #warningLogSource {
  max-width: 260px;
}

#tasksPage #warningLogKeyword {
  max-width: none;
  font-size: 14px;
}

#tasksPage #warningLogQueryBtn {
  min-width: 76px;
  padding: 0 16px;
  border-radius: 10px;
  background: linear-gradient(180deg, #2bc8cf 0%, #1fb2ba 100%);
  border-color: #1fb2ba;
  color: #fff;
  font-weight: 600;
  box-shadow: 0 4px 10px rgba(31, 178, 186, 0.25);
}

#tasksPage #warningLogQueryBtn:hover {
  background: linear-gradient(180deg, #24bcc4 0%, #1ca4ab 100%);
  border-color: #1ca4ab;
  transform: translateY(-1px);
}

#tasksPage #warningLogResetBtn {
  min-width: 76px;
  padding: 0 14px;
  border-radius: 10px;
  color: #566f89;
  border: 1px solid #c7d7e8;
  background: linear-gradient(180deg, #f7faff 0%, #edf3fb 100%);
}

#tasksPage #warningLogResetBtn:hover {
  background: linear-gradient(180deg, #f1f6fd 0%, #e7eef8 100%);
  border-color: #b6c9dd;
  transform: translateY(-1px);
}

#tasksPage .prewarning-table-wrap {
  border: 1px solid #dce6f2;
  border-radius: 10px;
  background: #fff;
  min-height: 520px;
  box-shadow: 0 6px 18px rgba(21, 43, 74, 0.06);
  overflow: hidden;
}

#tasksPage .prewarning-log-table thead th {
  background: #edf3fa;
  color: #4e637a;
  font-weight: 600;
  padding: 11px 12px;
}

#tasksPage .prewarning-log-table {
  table-layout: fixed;
  border-collapse: separate;
  border-spacing: 0;
}

#tasksPage .prewarning-log-table th:first-child {
  width: 52%;
}

#tasksPage .prewarning-log-table tbody td {
  padding: 12px;
  color: #2e4964;
  border-bottom: 1px solid #edf2f7;
}

#tasksPage .prewarning-log-table tbody tr:nth-child(even) {
  background: #fbfdff;
}

#tasksPage .prewarning-log-table tbody tr:hover {
  background: #f3f8ff;
}

#tasksPage .warning-log-content {
  width: 100%;
  line-height: 1.45;
  white-space: normal;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.warning-level-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 58px;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 12px;
  border: 1px solid #d9e3ef;
  color: #5e738c;
  background: #f6f9fc;
}

.warning-level-tag.high {
  background: #ffecee;
  border-color: #ffccd2;
  color: #c33a46;
}

.warning-level-tag.mid {
  background: #fff7e8;
  border-color: #ffe2ae;
  color: #b67809;
}

.warning-level-tag.low {
  background: #ebf8ef;
  border-color: #cdebd8;
  color: #208056;
}

.warning-log-empty-cell {
  border-bottom: 0;
}

.warning-log-empty-state {
  min-height: 320px;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 10px;
  color: #73869c;
  font-size: 22px;
}

.warning-log-empty-icon {
  width: 50px;
  height: 36px;
  border: 2px solid #d1d8e3;
  border-radius: 6px;
  position: relative;
}

.warning-log-empty-icon::before {
  content: "";
  position: absolute;
  left: 12px;
  top: -8px;
  width: 22px;
  height: 10px;
  border: 2px solid #d1d8e3;
  border-bottom: 0;
  border-radius: 8px 8px 0 0;
  background: #fff;
}

@media (max-width: 980px) {
  #tasksPage .prewarning-log-panel {
    padding: 4px 0 6px;
  }

  #tasksPage .warning-log-filter-compact {
    grid-template-columns: 1fr;
    overflow: visible;
  }

  #tasksPage #warningLogStartAt,
  #tasksPage #warningLogEndAt,
  #tasksPage #warningLogPlan,
  #tasksPage #warningLogSource,
  #tasksPage #warningLogKeyword {
    width: 100%;
    min-width: 0;
    max-width: none;
    flex: 1 1 100%;
  }

  #tasksPage .warning-log-filter-actions {
    width: 100%;
    justify-content: flex-end;
  }
}

/* Hide title/search strip in monitor + prewarning pages */
body[data-active-page="tasks"] .topbar,
body[data-active-page="monitor"] .topbar,
body[data-active-page="admin"] .topbar,
body[data-active-page="ai"] .topbar,
body[data-active-page="settings"] .topbar {
  display: none;
}

body[data-active-page="tasks"] .main,
body[data-active-page="monitor"] .main,
body[data-active-page="admin"] .main,
body[data-active-page="ai"] .main,
body[data-active-page="settings"] .main {
  padding-top: 10px;
}

/* Knowledge-base style top navigation */
.utility-strip {
  display: none;
}

.sidebar {
  top: 0;
  z-index: 20;
  height: 48px;
  min-height: 48px;
  padding: 0 20px 0 28px;
  gap: 0;
  background: #fff;
  color: #12284a;
  border-bottom: 1px solid #e3ebf5;
  box-shadow: 0 1px 0 rgba(17, 42, 78, 0.03);
}

.brand {
  min-width: 176px;
  height: 100%;
  padding-right: 24px;
  border-right: 1px solid #d8e1ec;
  gap: 9px;
}

.brand h1 {
  margin: 0;
  padding-right: 0;
  color: #061936;
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
}

.brand h1::after {
  content: none;
}

.brand-loach {
  width: 34px;
  height: 22px;
  flex: 0 0 34px;
  display: block;
  filter: drop-shadow(0 3px 6px rgba(47, 128, 255, 0.22));
}

.menu {
  flex: 0 1 auto;
  height: 100%;
  align-items: center;
  gap: 10px;
  padding-left: clamp(118px, 11.9vw, 166px);
}

.menu button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 38px;
  padding: 0 15px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  box-shadow: none;
  color: #314563;
  font-size: 14px;
  font-weight: 500;
  line-height: 1;
  white-space: nowrap;
  transition:
    background 0.18s ease,
    border-color 0.18s ease,
    box-shadow 0.18s ease,
    color 0.18s ease;
}

.menu button.active {
  background: #0b70f0;
  border-color: #0b70f0;
  color: #fff;
  box-shadow: 0 10px 20px rgba(11, 112, 240, 0.18);
}

.menu button:hover:not(.active) {
  background: #eef5ff;
  border-color: #d9e8fb;
  color: #0b62d6;
}

.menu-icon {
  position: relative;
  display: inline-block;
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  color: currentColor;
}

.menu-icon-monitor {
  border-bottom: 2px solid currentColor;
  border-radius: 1px;
}

.menu-icon-monitor::before {
  content: "";
  position: absolute;
  left: 7px;
  top: 3px;
  width: 2px;
  height: 8px;
  border-radius: 2px;
  background: currentColor;
}

.menu-icon-monitor::after {
  content: "";
  position: absolute;
  left: 4px;
  top: 2px;
  width: 6px;
  height: 6px;
  border-left: 2px solid currentColor;
  border-top: 2px solid currentColor;
  transform: rotate(45deg);
}

.menu-icon-tasks::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 2px;
  width: 4px;
  height: 4px;
  border-radius: 1px;
  background: currentColor;
  box-shadow:
    8px 0 0 currentColor,
    0 8px 0 currentColor,
    8px 8px 0 currentColor;
}

.menu-icon-ai::before {
  content: "";
  position: absolute;
  left: 1px;
  top: 7px;
  width: 14px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  transform: rotate(-45deg);
}

.menu-icon-ai::after {
  content: "";
  position: absolute;
  left: 11px;
  top: 1px;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: -8px 11px 0 currentColor;
}

.menu-icon-settings::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 2px;
  width: 12px;
  height: 12px;
  border: 2px solid currentColor;
  border-radius: 50%;
}

.menu-icon-settings::after {
  content: "";
  position: absolute;
  left: 6px;
  top: 6px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: currentColor;
}

.menu-icon-admin::before {
  content: "";
  position: absolute;
  left: 5px;
  top: 2px;
  width: 6px;
  height: 6px;
  border: 2px solid currentColor;
  border-radius: 50%;
}

.menu-icon-admin::after {
  content: "";
  position: absolute;
  left: 2px;
  bottom: 1px;
  width: 12px;
  height: 7px;
  border: 2px solid currentColor;
  border-bottom: 0;
  border-radius: 9px 9px 0 0;
}

.sidebar-footer {
  height: 100%;
  margin-left: auto;
  color: #314563;
}

.nav-user-tools {
  height: 100%;
}

.sidebar-footer .util-user {
  color: #314563;
  font-size: 12px;
  font-weight: 600;
}

.sidebar-footer .util-logout {
  position: relative;
  width: 40px;
  height: 34px;
  padding: 0;
  border: 1px solid #c8d7ea;
  border-radius: 6px;
  background: #f7fbff;
  color: #0b70f0;
  font-size: 0;
}

.sidebar-footer .util-logout::before {
  content: "";
  position: absolute;
  left: 11px;
  top: 9px;
  width: 12px;
  height: 15px;
  border: 2px solid currentColor;
  border-right: 0;
  border-radius: 2px 0 0 2px;
}

.sidebar-footer .util-logout::after {
  content: "";
  position: absolute;
  left: 18px;
  top: 11px;
  width: 16px;
  height: 12px;
  background: currentColor;
  clip-path: polygon(0 42%, 9px 42%, 9px 18%, 100% 50%, 9px 82%, 9px 58%, 0 58%);
}

.sidebar-footer .util-logout:hover {
  background: #eaf3ff;
  border-color: #a9caf5;
}

.main {
  padding: 14px 20px 20px;
}

body[data-active-page="tasks"] .main,
body[data-active-page="monitor"] .main,
body[data-active-page="admin"] .main,
body[data-active-page="ai"] .main,
body[data-active-page="settings"] .main {
  padding-top: 14px;
}

#monitorPage.page.active {
  grid-template-columns: var(--monitor-plan-panel-width, 220px) 8px minmax(0, 1fr);
}

body.limited-monitor-user #monitorPage.page.active {
  grid-template-columns: minmax(0, 1fr);
}

.monitor-plan-panel {
  height: calc(100vh - 82px);
  max-height: calc(100vh - 82px);
}

#monitorInfoPanel {
  max-height: calc(100vh - 82px);
}

@media (max-width: 980px) {
  .sidebar {
    height: auto;
    min-height: 48px;
    padding: 0 12px 8px;
    flex-wrap: wrap;
  }

  .brand {
    min-width: 156px;
    height: 48px;
    padding-right: 18px;
  }

  .menu {
    order: 3;
    width: 100%;
    height: auto;
    gap: 8px;
    padding: 0 0 2px;
    overflow-x: auto;
  }

  .menu button {
    flex: 0 0 auto;
    height: 36px;
    padding: 0 13px;
  }

  .sidebar-footer {
    display: flex;
    height: 48px;
  }

  .sidebar-footer .util-user {
    display: none;
  }

  .main {
    padding: 12px;
  }
}

/* Unified compact button style */
button,
button.primary,
.tiny-btn,
.chip,
.chip.active,
.menu button,
.menu button.active,
.menu button:hover,
.seg-tabs button,
.seg-tabs button.active,
.top-actions button,
.monitor-head-actions .tiny-btn,
.monitor-list-tools button,
.plan-action-btn,
.plan-action-btn.danger,
.plan-action-btn.plan-pull-now-btn,
.plan-status-btn,
.icon-btn,
.float-tools button,
.float-tools .primary-float,
.report-hub-tabs button,
.report-hub-tabs button.active,
.plan-keyword-tabs button,
.plan-keyword-tabs button.active,
.plan-keyword-group-list button,
.plan-keyword-group-list button.active,
.source-library-chip,
.source-library-chip.active,
.domain-suggest button,
.domain-suggest button:hover,
.domain-suggest button.active,
.report-snapshot-icon-btn,
.monitor-item-icon-btn,
.monitor-page-number-list button,
#monitorPlanModal .modal-actions button,
#monitorWarningModal .modal-actions button,
#confirmDialog .modal-actions button,
#tasksPage .warning-log-filter-compact button:not(.warning-log-date-picker-btn) {
  background: #eaf4ff !important;
  background-image: none !important;
  border-color: #9bc8ff !important;
  color: #0b5cad !important;
  font-size: 12px !important;
  font-weight: 400 !important;
  letter-spacing: 0 !important;
  box-shadow: none;
}

button:hover:not(:disabled),
button.primary:hover:not(:disabled),
.tiny-btn:hover:not(:disabled),
.chip:hover,
.menu button:hover,
.seg-tabs button:hover,
.plan-action-btn:hover:not(:disabled),
.plan-status-btn:hover:not(:disabled),
.icon-btn:hover:not(:disabled),
.monitor-item-icon-btn:hover:not(:disabled),
.report-snapshot-icon-btn:hover:not(:disabled) {
  background: #ddecff !important;
  border-color: #7fb8ff !important;
  color: #084f9f !important;
}

button:disabled,
.plan-action-btn:disabled,
.plan-status-btn:disabled,
.monitor-item-icon-btn:disabled {
  background: #f2f7ff !important;
  border-color: #c9d9ee !important;
  color: #86a2c2 !important;
  font-weight: 400 !important;
}

/* Top navigation follows the reference tab style. */
.menu {
  gap: 12px;
}

.menu button {
  height: 38px !important;
  padding: 0 18px !important;
  border: 1px solid transparent !important;
  border-radius: 999px !important;
  background: transparent !important;
  background-image: none !important;
  color: #314563 !important;
  font-size: 13px !important;
  font-weight: 400 !important;
  box-shadow: none !important;
}

.menu button.active {
  background: #0b70f0 !important;
  border-color: #0b70f0 !important;
  color: #fff !important;
  box-shadow: 0 10px 22px rgba(11, 112, 240, 0.18) !important;
}

.menu button:hover:not(.active) {
  background: transparent !important;
  border-color: transparent !important;
  color: #0b62d6 !important;
  box-shadow: none !important;
}

.menu-icon {
  width: 15px;
  height: 15px;
  flex-basis: 15px;
}

/* Compact regular-weight text for the main monitor view. */
.brand h1,
.monitor-plan-head h3,
.plan-item .plan-item-name,
.monitor-label,
.monitor-row-form input,
.monitor-row-form select,
.monitor-plan-update-time,
.monitor-plan-update-time strong,
.monitor-feed-titleline strong,
.monitor-feed-title-link,
.monitor-feed-meta,
.monitor-feed-meta-text,
.monitor-sensitivity-select {
  font-size: 13px !important;
  font-weight: 400 !important;
  letter-spacing: 0 !important;
}

.monitor-feed-title-link,
.monitor-feed-titleline strong {
  color: #163154 !important;
}

.monitor-feed-meta {
  color: #21476c;
}

/* Toggle buttons: active matches the top selected tab, inactive stays white. */
#monitorAllItemsBtn,
#monitorOnlyFavoritesBtn,
#monitorPage .chip,
#monitorPage .chip.active {
  background: #fff !important;
  border-color: #9bc8ff !important;
  color: #0b5cad !important;
  font-size: 12px !important;
  font-weight: 400 !important;
}

#monitorAllItemsBtn.active,
#monitorOnlyFavoritesBtn.active,
#monitorPage .chip.active {
  background: #0b70f0 !important;
  border-color: #0b70f0 !important;
  color: #fff !important;
}

#monitorAllItemsBtn:hover:not(.active):not(:disabled),
#monitorOnlyFavoritesBtn:hover:not(.active):not(:disabled),
#monitorPage .chip:hover:not(.active) {
  background: #f3f8ff !important;
  border-color: #7fb8ff !important;
  color: #084f9f !important;
}

#openMonitorPlanFromMonitor {
  width: 34px !important;
  height: 34px !important;
  font-size: 22px !important;
  line-height: 1 !important;
}

.sidebar-footer .util-logout {
  font-size: 0 !important;
  color: #0b70f0 !important;
  background: transparent !important;
  border-color: transparent !important;
  box-shadow: none !important;
}

/* Prewarning log text should stay light and close to the top nav scale. */
#tasksPage .warning-log-filter-compact .warning-log-filter-label,
#tasksPage .warning-log-filter-sep,
#tasksPage .warning-log-filter-compact input:not(.warning-log-date-picker-native),
#tasksPage .warning-log-filter-compact select,
#tasksPage .warning-log-filter-compact button:not(.warning-log-date-picker-btn),
#tasksPage .warning-log-date-input,
#tasksPage .prewarning-log-table thead th,
#tasksPage .prewarning-log-table tbody td,
.nav-user-tools .util-user,
.sidebar-footer .util-user {
  font-weight: 400 !important;
  color: #314563 !important;
}

#tasksPage .warning-log-filter-compact .warning-log-filter-label,
#tasksPage .warning-log-filter-sep,
#tasksPage .prewarning-log-table thead th,
#tasksPage .prewarning-log-table tbody td,
#tasksPage .warning-log-empty-state,
.nav-user-tools .util-user,
.sidebar-footer .util-user {
  font-size: 13px !important;
}

#tasksPage .warning-log-empty-state {
  color: #6d829b !important;
  font-weight: 400 !important;
}

.sidebar-footer .util-logout:hover,
.sidebar-footer .util-logout:focus-visible {
  background: transparent !important;
  border-color: transparent !important;
  box-shadow: none !important;
  color: #0b70f0 !important;
}

#tasksPage .prewarning-log-table thead th,
#tasksPage .warning-log-empty-state {
  font-size: 12px !important;
  font-weight: 400 !important;
  color: #5f7590 !important;
}

#aiPage .ai-panel-head h3 {
  color: #314563 !important;
  font-size: 13px !important;
  font-weight: 400 !important;
}

#aiPage .ai-input,
#aiPage .ai-input::placeholder,
#aiPage .ai-document-empty {
  color: #6d829b !important;
  font-size: 13px !important;
  font-weight: 400 !important;
}

#aiPage .panel-head h3,
#aiPage .ai-kpi-card span,
#aiPage .ai-kpi-card strong,
#aiPage .ai-chart-card h4 {
  font-weight: 400 !important;
  color: #314563 !important;
}

#aiPage .ai-kpi-card strong {
  font-size: 18px !important;
}

#aiPage .ai-chart-card h4 {
  font-size: 13px !important;
}

#aiPage .ai-timeline-panel .panel-head h3,
#aiPage .ai-timeline-panel .panel-head span,
#aiPage .ai-timeline-table th,
#aiPage .ai-timeline-table td {
  color: #5f7590 !important;
  font-size: 12px !important;
  font-weight: 400 !important;
}

/* Settings source management follows the compact top navigation type scale. */
#settingsPage .panel-head h3,
#settingsPage table th {
  color: #314563 !important;
  font-size: 13px !important;
  font-weight: 400 !important;
  letter-spacing: 0 !important;
}

#settingsPage .source-form select,
#settingsPage .source-form select option {
  color: #314563 !important;
  font-size: 13px !important;
  font-weight: 400 !important;
  letter-spacing: 0 !important;
}
