:root {
  --operator-bg: #f5f6f8;
  --operator-surface: #ffffff;
  --operator-border: rgba(18, 20, 23, 0.12);
  --operator-border-width: 3px;
  --operator-text: #121417;
  --operator-muted: #5d6670;
  --operator-primary: #1f6feb;
  --operator-warning: #f3b540;
  --operator-danger: #dc3545;
  --operator-success: #198754;
  --operator-info: #0dcaf0;
  --operator-secondary: #6c757d;
  --operator-dark: #121417;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scrollbar-gutter: stable;
}

@supports not (scrollbar-gutter: stable) {
  html {
    overflow-y: scroll;
  }
}

body {
  margin: 0;
  font-family:
    ui-sans-serif,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  line-height: 1.5;
}

.operator-login-card,
.operator-bootstrap-card,
.operator-mfa-card,
.operator-reset-card {
  border: var(--operator-border-width) solid rgba(18, 20, 23, 0.12);
}

.operator-topbar-main {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.operator-topbar-brand {
  flex: 0 0 auto;
  color: #ffffff;
  font-size: 1.1rem;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
}

.operator-topbar-brand span {
  color: #ffc107;
}

.operator-main-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.5rem;
  flex: 1 1 auto;
}

.operator-main-nav .btn {
  min-height: 2.25rem;
}

@media (max-width: 767.98px) {
  .operator-topbar-main {
    display: grid;
  }

  .operator-main-nav {
    justify-content: flex-start;
  }
}

a {
  color: var(--operator-primary);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

button,
input,
select,
textarea {
  font: inherit;
}

.container-fluid {
  width: 100%;
  margin: 0 auto;
}

.row {
  display: flex;
  flex-wrap: wrap;
  margin: -0.5rem;
}

.row > [class*="col-"],
.row > [class^="col-"] {
  width: 100%;
  min-width: 0;
  padding: 0.5rem;
  flex: 0 0 auto;
}

.col-12 { width: 100%; }
.col-8 { width: 66.6667%; }
.col-7 { width: 58.3333%; }
.col-6 { width: 50%; }
.col-5 { width: 41.6667%; }
.col-4 { width: 33.3333%; }
.col-3 { width: 25%; }

@media (min-width: 768px) {
  .col-md-2 { width: 16.6667%; }
  .col-md-3 { width: 25%; }
  .col-md-4 { width: 33.3333%; }
  .col-md-5 { width: 41.6667%; }
  .col-md-6 { width: 50%; }
  .col-md-7 { width: 58.3333%; }
  .col-md-8 { width: 66.6667%; }
}

@media (min-width: 992px) {
  .col-lg-1 { width: 8.3333%; }
  .col-lg-2 { width: 16.6667%; }
  .col-lg-3 { width: 25%; }
  .col-lg-4 { width: 33.3333%; }
  .col-lg-6 { width: 50%; }
  .col-lg-7 { width: 58.3333%; }
  .col-lg-12 { width: 100%; }
  .justify-content-lg-end { justify-content: flex-end; }
}

@media (min-width: 1200px) {
  .col-xl-3 { width: 25%; }
  .col-xl-4 { width: 33.3333%; }
  .col-xl-5 { width: 41.6667%; }
  .col-xl-7 { width: 58.3333%; }
  .col-xl-8 { width: 66.6667%; }
}

.d-flex { display: flex; }
.d-grid { display: grid; }
.d-inline { display: inline; }
.d-block { display: block; }
.d-none { display: none !important; }
.flex-wrap { flex-wrap: wrap; }

.align-items-center { align-items: center; }
.align-items-start { align-items: flex-start; }
.align-items-end { align-items: flex-end; }
.align-middle { vertical-align: middle; }

.justify-content-between { justify-content: space-between; }
.justify-content-center { justify-content: center; }
.justify-content-end { justify-content: flex-end; }

.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 1rem; }
.g-2 > * { padding: 0.5rem; }
.g-3 > * { padding: 0.75rem; }
.g-4 > * { padding: 1rem; }

.p-2 { padding: 0.5rem; }
.p-3 { padding: 1rem; }
.p-4 { padding: 1.5rem; }
.px-3 { padding-left: 1rem; padding-right: 1rem; }
.px-4 { padding-left: 1.5rem; padding-right: 1.5rem; }
.py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.py-3 { padding-top: 1rem; padding-bottom: 1rem; }
.py-4 { padding-top: 1.5rem; padding-bottom: 1.5rem; }
.ps-3 { padding-left: 1rem; }
.pt-0 { padding-top: 0; }

.m-0 { margin: 0; }
.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 1rem; }
.mb-4 { margin-bottom: 1.5rem; }
.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 1rem; }
.mt-4 { margin-top: 1.5rem; }
.me-2 { margin-right: 0.5rem; }
.me-3 { margin-right: 1rem; }
.my-3 { margin-top: 1rem; margin-bottom: 1rem; }

.w-100 { width: 100%; }
.h-100 { height: 100%; }

.small,
small {
  font-size: 0.875rem;
}

.h3,
.h4,
.h5,
.h6 {
  margin: 0;
  font-weight: 700;
  line-height: 1.2;
  color: var(--operator-text);
}

.h3 { font-size: 1.75rem; }
.h4 { font-size: 1.5rem; }
.h5 { font-size: 1.25rem; }
.h6 { font-size: 1rem; }

.fw-semibold { font-weight: 600; }
.font-monospace {
  font-family:
    ui-monospace,
    SFMono-Regular,
    SFMono-Regular,
    Menlo,
    Monaco,
    Consolas,
    "Liberation Mono",
    monospace;
}

.text-uppercase { text-transform: uppercase; }
.text-center { text-align: center; }
.text-end,
.text-right { text-align: right; }
.text-dark { color: var(--operator-text) !important; }
.text-muted { color: var(--operator-muted) !important; }
.text-danger { color: var(--operator-danger) !important; }
.text-success { color: var(--operator-success) !important; }
.text-warning { color: #9a6700 !important; }
.opacity-75 { opacity: 0.75; }

.bg-light { background: #f8f9fa; }
.bg-white { background: #ffffff; }

.border {
  border: var(--operator-border-width) solid var(--operator-border);
}

.border-0 { border: 0 !important; }

.border-warning-subtle {
  border-color: #ffecb5 !important;
}

.rounded {
  border-radius: 0.5rem;
}

.rounded-3 {
  border-radius: 1rem;
}

.card {
  background: var(--operator-surface);
  border: var(--operator-border-width) solid var(--operator-border);
  border-radius: 1rem;
}

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.35rem 0.6rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1;
}

.text-bg-light {
  background: #f8f9fa;
  color: var(--operator-text);
}

.text-bg-dark {
  background: var(--operator-dark);
  color: #ffffff;
}

.text-bg-primary {
  background: #cfe2ff;
  color: #084298;
}

.text-bg-secondary {
  background: #e2e3e5;
  color: #41464b;
}

.text-bg-success {
  background: #d1e7dd;
  color: #0f5132;
}

.text-bg-warning {
  background: #fff3cd;
  color: #664d03;
}

.text-bg-danger {
  background: #f8d7da;
  color: #842029;
}

.text-bg-info {
  background: #cff4fc;
  color: #055160;
}

.operator-page-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.operator-page-title {
  margin: 0;
  color: var(--operator-text);
  font-size: 1.45rem;
  line-height: 1.2;
}

.operator-page-subtitle,
.operator-section-subtitle,
.operator-help {
  color: var(--operator-muted);
  font-size: 0.875rem;
}

.operator-eyebrow,
.operator-label {
  color: var(--operator-muted);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

.operator-page-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.5rem;
}

.operator-panel {
  background: var(--operator-surface);
  border: var(--operator-border-width) solid var(--operator-border);
  border-radius: 0.5rem;
  padding: 1rem;
}

.operator-section-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1rem;
}

.operator-section-title {
  margin: 0;
  color: var(--operator-text);
  font-size: 1.05rem;
  line-height: 1.25;
}

.operator-kpi-panel {
  min-height: 100%;
}

.operator-kpi-value {
  margin-top: 0.35rem;
  color: var(--operator-text);
  font-size: 1.65rem;
  font-weight: 750;
  line-height: 1;
}

.operator-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1rem;
  padding: 0.35rem;
  border: var(--operator-border-width) solid var(--operator-border);
  border-radius: 0.6rem;
  background: #ffffff;
}

.operator-tab {
  display: inline-flex;
  align-items: center;
  min-height: 2rem;
  padding: 0.38rem 0.7rem;
  border: var(--operator-border-width) solid transparent;
  border-radius: 0.45rem;
  background: transparent;
  color: var(--operator-muted);
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 700;
  text-decoration: none;
}

.operator-tab:hover {
  background: #f1f3f5;
  border-color: rgba(18, 20, 23, 0.14);
  text-decoration: none;
}

.operator-tab.active,
.operator-tab[aria-current="page"] {
  background: var(--operator-dark);
  border-color: var(--operator-dark);
  color: #ffffff;
}

.operator-grid {
  display: grid;
  gap: 1rem;
}

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

.operator-grid-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.operator-grid-4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.operator-stack {
  display: grid;
  gap: 1rem;
}

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

.operator-summary-strip > [class*="col-"] {
  width: auto;
  padding: 0;
}

.operator-signal-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.85rem;
}

.operator-signal-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 0.75rem;
  min-height: 100%;
  padding: 0.85rem 0.9rem;
  color: var(--operator-text);
  background: var(--operator-surface);
  border: var(--operator-border-width) solid var(--operator-border);
  border-radius: 0.5rem;
  box-shadow: 0 10px 24px rgba(18, 20, 23, 0.06);
}

.operator-signal-card:hover,
.operator-signal-card:focus {
  color: var(--operator-text);
  border-color: color-mix(in srgb, var(--operator-primary) 55%, var(--operator-border));
  background: #fbfcff;
  text-decoration: none;
}

.operator-signal-icon {
  display: inline-block;
  width: 0.55rem;
  min-width: 0.55rem;
  height: 2.45rem;
  border-radius: 999px;
  background: var(--operator-success);
}

.operator-signal-icon--ai {
  background: var(--operator-primary);
}

.operator-signal-icon--feedback {
  background: var(--operator-warning);
}

.operator-signal-icon--fax {
  background: var(--operator-danger);
}

.operator-signal-icon--mobile {
  background: var(--operator-info);
}

.operator-signal-value {
  margin-top: 0.15rem;
  color: var(--operator-text);
  font-size: 1.05rem;
  font-weight: 800;
  line-height: 1.15;
}

.operator-table th {
  color: var(--operator-muted);
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
  white-space: nowrap;
}

.operator-table tbody tr:hover {
  background: rgba(18, 20, 23, 0.025);
}

.operator-sortable-th {
  cursor: pointer;
  user-select: none;
}

.operator-action-list {
  display: grid;
  gap: 0.65rem;
}

.operator-action-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  padding: 0.75rem;
  border: var(--operator-border-width) solid rgba(18, 20, 23, 0.1);
  border-radius: 0.5rem;
  background: #ffffff;
}

.operator-empty-state {
  padding: 1.25rem;
  border: var(--operator-border-width) dashed rgba(18, 20, 23, 0.18);
  border-radius: 0.5rem;
  background: #fafbfc;
  color: var(--operator-text);
}

.operator-tab-panel[hidden] {
  display: none !important;
}

.operator-instance-tab-panel {
  scroll-margin-top: 1rem;
}

@media (max-width: 1399.98px) {
  .operator-signal-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 991.98px) {
  .operator-page-header,
  .operator-section-header,
  .operator-action-row {
    display: grid;
  }

  .operator-page-actions {
    justify-content: flex-start;
  }

  .operator-summary-strip,
  .operator-signal-grid,
  .operator-grid-2,
  .operator-grid-3,
  .operator-grid-4 {
    grid-template-columns: 1fr;
  }
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  min-height: 2.5rem;
  padding: 0.6rem 1rem;
  border-radius: 0.7rem;
  border: var(--operator-border-width) solid transparent;
  background: transparent;
  color: var(--operator-text);
  cursor: pointer;
  text-decoration: none;
  font-weight: 600;
  transition: background-color 120ms ease, border-color 120ms ease, color 120ms ease;
}

.btn:hover {
  text-decoration: none;
}

.btn-sm {
  min-height: 2rem;
  padding: 0.4rem 0.75rem;
  font-size: 0.9rem;
}

.btn-dark {
  background: var(--operator-dark);
  border-color: var(--operator-dark);
  color: #ffffff;
}

.btn-primary {
  background: var(--operator-primary);
  border-color: var(--operator-primary);
  color: #ffffff;
}

.btn-warning {
  background: var(--operator-warning);
  border-color: var(--operator-warning);
  color: var(--operator-text);
}

.btn-outline-dark {
  border-color: rgba(18, 20, 23, 0.2);
  color: var(--operator-text);
}

.btn-outline-secondary {
  border-color: rgba(108, 117, 125, 0.35);
  color: #495057;
}

.btn-outline-danger {
  border-color: rgba(220, 53, 69, 0.35);
  color: var(--operator-danger);
}

.btn-outline-warning {
  border-color: rgba(243, 181, 64, 0.55);
  color: #664d03;
}

.btn-outline-light {
  border-color: rgba(255, 255, 255, 0.28);
  color: #ffffff;
}

.btn-danger {
  background: var(--operator-danger);
  border-color: var(--operator-danger);
  color: #ffffff;
}

.btn-outline-dark:hover,
.btn-outline-secondary:hover,
.btn-outline-danger:hover,
.btn-outline-warning:hover,
.btn-outline-light:hover {
  background: rgba(18, 20, 23, 0.06);
}

.btn.active,
.btn[aria-pressed="true"] {
  background: var(--operator-dark);
  border-color: var(--operator-dark);
  color: #ffffff;
}

.form-label {
  display: inline-block;
  margin-bottom: 0.35rem;
  font-weight: 600;
  color: var(--operator-text);
}

.form-label-sm {
  font-size: 0.875rem;
}

.form-control,
.form-select {
  display: block;
  width: 100%;
  min-height: 2.5rem;
  padding: 0.6rem 0.75rem;
  border: var(--operator-border-width) solid rgba(18, 20, 23, 0.16);
  border-radius: 0.7rem;
  background: #ffffff;
  color: var(--operator-text);
}

.form-control-sm,
.form-select-sm {
  min-height: 2.1rem;
  padding: 0.45rem 0.6rem;
  font-size: 0.92rem;
}

.form-text {
  margin-top: 0.35rem;
  font-size: 0.875rem;
  color: var(--operator-muted);
}

.form-check {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
}

.form-check-input {
  margin-top: 0.2rem;
}

.form-check-label {
  color: var(--operator-text);
}

.input-group {
  display: flex;
  align-items: stretch;
  width: 100%;
}

.input-group > .form-control,
.input-group > .form-select {
  flex: 1 1 auto;
}

.alert {
  padding: 0.85rem 1rem;
  border: var(--operator-border-width) solid transparent;
  border-radius: 0.85rem;
}

.alert-light {
  background: #f8f9fa;
  border-color: rgba(18, 20, 23, 0.08);
  color: var(--operator-text);
}

.alert-secondary {
  background: #eef1f3;
  border-color: rgba(108, 117, 125, 0.18);
  color: #364049;
}

.alert-success {
  background: #d1e7dd;
  border-color: #badbcc;
  color: #0f5132;
}

.alert-warning {
  background: #fff3cd;
  border-color: #ffecb5;
  color: #664d03;
}

.alert-danger {
  background: #f8d7da;
  border-color: #f5c2c7;
  color: #842029;
}

.table-responsive {
  width: 100%;
  overflow-x: auto;
}

.table {
  width: 100%;
  border-collapse: collapse;
  color: var(--operator-text);
  background: transparent;
}

.table th,
.table td {
  padding: 0.75rem;
  text-align: left;
  border-bottom: var(--operator-border-width) solid rgba(18, 20, 23, 0.08);
}

.table-sm th,
.table-sm td {
  padding: 0.5rem 0.6rem;
}

.operator-log-scroll {
  max-height: 620px;
  overflow-y: auto;
  padding-right: 0.35rem;
}

.operator-log-scroll-sm {
  max-height: 340px;
}

.operator-disclosure {
  background: transparent;
  border: var(--operator-border-width) solid rgba(18, 20, 23, 0.1);
  border-radius: 14px;
  box-shadow: none;
}

.operator-disclosure > summary {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
  cursor: pointer;
  list-style: none;
  padding: 1rem;
  font-weight: 700;
}

.operator-disclosure > summary::-webkit-details-marker {
  display: none;
}

.operator-disclosure > summary::after {
  content: "+";
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.6rem;
  height: 1.6rem;
  border-radius: 999px;
  background: #f1f3f5;
  color: var(--operator-text);
  flex: 0 0 auto;
}

.operator-disclosure[open] > summary {
  border-bottom: var(--operator-border-width) solid rgba(18, 20, 23, 0.08);
}

.operator-disclosure[open] > summary::after {
  content: "-";
}

.operator-disclosure-body {
  padding: 1rem;
}
