/* Shared TrueOps UI refinement. Loaded after style.css so module templates retain their behavior. */
:root {
  --ui-ink: #17233b;
  --ui-muted: #64748b;
  --ui-border: #dce5ef;
  --ui-surface: #fff;
  --ui-soft: #f6f9fc;
  --ui-ring: #2563eb;
}
body { color: var(--ui-ink); background: #f3f6fa; }
a, button, input, select, textarea { -webkit-tap-highlight-color: transparent; }
:where(a, button, summary, input, select, textarea):focus-visible {
  outline: 3px solid var(--ui-ring);
  outline-offset: 2px;
}
:where(button, input, select, textarea) { font: inherit; }
:where(button, select) { cursor: pointer; }
:where(button, input, select, textarea):disabled { cursor: not-allowed; opacity: .55; }
:where(.page-content, .main-content) { min-width: 0; }
.page-content {
  width: min(100%, 1600px);
  margin-inline: auto;
  padding: clamp(16px, 2.2vw, 30px);
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.topbar {
  position: relative;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 72px;
  margin: 0 0 12px;
  padding: 11px 16px 11px 22px;
  color: var(--ui-ink);
  background: #fff;
  border: 1px solid #dbe5f0;
  border-radius: 16px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, .07);
}
.topbar-left {
  width: auto;
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 14px;
  min-width: 0;
}
.topbar-right {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  min-width: 0;
}
.topbar-title-block { flex: 1 1 auto; min-width: 0; }
.topbar-eyebrow {
  display: block;
  margin-bottom: 3px;
  color: #2463b9;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: .15em;
  text-transform: uppercase;
}
.topbar-title-block h2 {
  margin: 0;
  color: #5e6d82 !important;
  font-size: 13px;
  font-weight: 750;
  line-height: 1.08;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sidebar { background: #fff; border-right: 1px solid var(--ui-border); }
.sidebar .brand { min-width: 0; }
.sidebar .brand h1 { overflow-wrap: anywhere; }
.sidebar .nav a { min-height: 40px; }
.sidebar .nav a.active { color: #174a9b; }
.sidebar .nav-section-label-spaced {
  margin-top: 16px;
  padding-top: 13px;
  border-top: 1px solid var(--ui-border);
}
.desktop-sidebar-pin { color: #315480; background: #edf4fc; border-color: #d5e2f2; }
.desktop-sidebar-pin:hover, .desktop-sidebar-pin.is-pinned { background: #dcecff; border-color: #aac9ee; }
.desktop-sidebar-pin:focus-visible { outline: 3px solid var(--ui-ring); }
.topbar .mobile-nav-toggle {
  flex: 0 0 auto;
  min-width: 0;
  min-height: 40px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 1px solid #d7e1ed;
  border-radius: 11px;
  background: #fff;
  color: #34445b;
  font-size: 12px;
  font-weight: 800;
  box-shadow: none;
}
.topbar .mobile-nav-toggle:hover, .topbar .mobile-nav-toggle[aria-expanded="true"] {
  background: #edf5ff;
  border-color: #aac9ee;
  color: #174a9b;
}
.topbar-status-group {
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
}
.topbar-status-chip {
  height: 38px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border: 1px solid #d7e1ed;
  border-radius: 999px;
  background: #f8fafc;
  color: #3c4d64;
  font-size: 11px;
  font-weight: 850;
  white-space: nowrap;
}
.topbar-company-pill {
  flex: 0 0 auto;
  max-width: 165px;
  padding: 8px 11px;
  overflow: hidden;
  border: 1px solid rgba(125, 211, 252, .16);
  border-radius: 999px;
  background: rgba(14, 116, 144, .13);
  color: #d9f3ff;
  font-size: 11px;
  font-weight: 850;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.topbar-company-switcher .company-switcher-select {
  width: 170px;
  min-width: 0;
  max-width: 170px;
  height: 40px;
  padding: 0 32px 0 11px;
  border-color: rgba(125, 211, 252, .20);
  border-radius: 11px;
  background: #142840;
  color: #eaf6ff;
  font-size: 12px;
  font-weight: 800;
}
.topbar-company-switcher { flex: 0 0 auto; }
.topbar-command-search {
  position: relative;
  flex: 0 1 250px;
  min-width: 180px;
  margin-left: 0;
}
.topbar-command-icon {
  position: absolute;
  z-index: 1;
  left: 12px;
  top: 50%;
  color: #8fa3bd;
  font-size: 18px;
  line-height: 1;
  transform: translateY(-52%);
  pointer-events: none;
}
.topbar-command-search input {
  width: 100%;
  height: 40px;
  padding: 0 13px 0 36px;
  border: 1px solid #d7e1ed;
  border-radius: 11px;
  background: #f8fafc;
  color: #17233b;
  box-shadow: none;
}
.topbar-command-search input::placeholder { color: #8a9ab0; }
.topbar-command-search input:focus {
  border-color: #8eb8e8;
  background: #fff;
}
.topbar-command-results {
  position: absolute;
  z-index: 80;
  top: calc(100% + 8px);
  right: 0;
  left: 0;
  padding: 6px;
  border: 1px solid var(--ui-border);
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 18px 40px rgba(15, 23, 42, .14);
}
.topbar-command-results[hidden] { display: none; }
.topbar-command-results a,
.topbar-command-empty {
  display: block;
  padding: 9px 10px;
  border-radius: 8px;
  color: #334155;
  font-size: 13px;
  font-weight: 750;
}
.topbar-command-results a:hover,
.topbar-command-results a[aria-selected="true"] {
  background: #edf5ff;
  color: #174a9b;
}
.topbar-command-empty { color: var(--ui-muted); font-weight: 650; }
.topbar .admin-gear-menu { margin: 0; }
.topbar .admin-gear-menu summary {
  width: 40px;
  height: 40px;
  border-color: #d7e1ed;
  border-radius: 11px;
  background: #fff;
  color: #34445b;
  box-shadow: none;
}
.topbar .admin-gear-menu summary:hover {
  background: #edf5ff;
  border-color: #aac9ee;
}
.topbar-user-pill {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
  padding: 5px 10px 5px 5px;
  border: 1px solid #d7e1ed;
  border-radius: 999px;
  background: #fff;
}
.topbar-avatar {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  flex: 0 0 30px;
  border: 1px solid #bfd8ef;
  border-radius: 999px;
  background: #e7f4fb;
  color: #176080;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}
.topbar-user-meta {
  display: grid;
  min-width: 0;
  line-height: 1.1;
}
.topbar-user-meta strong {
  max-width: 120px;
  overflow: hidden;
  color: #17233b;
  font-size: 12px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.topbar-user-meta small {
  margin-top: 2px;
  color: #75859a;
  font-size: 9px;
  font-weight: 850;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.topbar .topbar-logout-btn {
  height: 40px;
  min-width: auto;
  padding: 0 12px;
  border-color: #f1caca;
  border-radius: 11px;
  background: #fff8f8;
  color: #a52a2a;
  box-shadow: none;
}
.topbar .topbar-logout-btn:hover {
  border-color: #e8aaaa;
  background: #fff0f0;
  color: #861f1f;
}
.account-company-switcher { padding: 0 3px 6px; }
.account-company-switcher .company-switcher-select { width: 100%; min-width: 210px; }
.account-company-name { padding: 7px 10px 10px; color: #475569; font-size: 12px; font-weight: 800; }
.admin-gear-separator {
  height: 1px;
  margin: 7px 3px;
  background: var(--ui-border);
}
.admin-gear-dropdown .account-logout-link {
  color: #b42318;
  background: #fff7f6;
}
.admin-gear-dropdown .account-logout-link:hover {
  color: #912018;
  background: #fee4e2;
  border-color: #fecdca;
}
.login-help-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.login-help-row a {
  color: #1d4ed8;
  font-weight: 800;
  white-space: nowrap;
}
.login-help-row a:hover { color: #1e40af; text-decoration: underline; }
.panel, .premium-panel {
  min-width: 0;
  background: var(--ui-surface);
  border: 1px solid var(--ui-border);
  box-shadow: 0 5px 20px rgba(28,47,76,.045);
}
.panel-head { gap: 12px; }
.panel-head h3, .panel h3 { line-height: 1.25; }
:where(.page-content) :where(h1, h2, h3) { overflow-wrap: anywhere; }
:where(.page-content) :where(.area-subtitle, .muted, .helper-text, small) { color: var(--ui-muted); }
:where(.page-content) :where(input:not([type="checkbox"]):not([type="radio"]), select, textarea) {
  max-width: 100%;
  min-height: 40px;
  border-color: #cbd8e8;
  border-radius: 9px;
  background: #fff;
  color: var(--ui-ink);
}
:where(.page-content) textarea { min-height: 92px; resize: vertical; }
:where(.page-content) :where(input, select, textarea)::placeholder { color: #8391a5; }
:where(.page-content) :where(label, .form-group label) { line-height: 1.35; }
:where(.page-content) :where(.btn, .button, .action-btn) { min-height: 40px; }
:where(.page-content) :where(.table-wrap, .premium-table-wrap) {
  max-width: 100%;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  border-radius: 12px;
}
:where(.page-content) :where(.data-table, .premium-table) {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-variant-numeric: tabular-nums;
}
:where(.page-content) :where(.data-table, .premium-table) th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #f4f7fb;
  color: #43536a;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
}
:where(.page-content) :where(.data-table, .premium-table) :where(th, td) {
  padding: 11px 12px;
  vertical-align: middle;
  border-bottom: 1px solid #e9eef5;
}
:where(.page-content) :where(.data-table, .premium-table) tbody tr:hover { background: #f7faff; }
:where(.page-content) :where(.data-table, .premium-table) tbody tr:last-child td { border-bottom: 0; }
.flash-wrap { max-width: 1600px; margin-inline: auto; }
.flash { border-radius: 10px; }
/* Dashboard: a compact overview with room for the actual store data. */
.command-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 22px;
  margin-bottom: 16px !important;
  background: linear-gradient(120deg, #fff, #f5f9ff);
}
.command-title { margin: 3px 0; font-size: clamp(21px, 2vw, 29px); line-height: 1.16; }
.command-eyebrow { color: #2463b9; letter-spacing: .11em; }
.command-subtitle { max-width: 78ch; margin: 4px 0 0; color: #5a6b81; line-height: 1.4; }
.command-bar-right { gap: 7px; }
.command-chip { white-space: nowrap; border: 1px solid #d6e4f4; background: #edf5ff; color: #275184; }
#last-refresh-chip { background: #fff; color: #53677f; }
.ops-flow-panel, .heatmap-panel { margin-bottom: 16px !important; }
.ops-flow-panel { padding: 16px 18px; }
.ops-flow-toggle { width: 100%; }
.ops-flow-grid { gap: 10px; }
.ops-stage-card { min-width: 0; }
.heatmap-panel { padding: 18px; }
.heatmap-grid { gap: 10px; }
.heatmap-tile { min-width: 0; transition: border-color .15s, box-shadow .15s; }
.heatmap-link:hover .heatmap-tile, .heatmap-link:focus-visible .heatmap-tile {
  box-shadow: 0 0 0 2px #77aeea;
}
.area-panel { margin-bottom: 16px; }
.area-header-right { flex-wrap: wrap; }
.premium-table-wrap { margin-top: 10px; }
:where(.page-content) .ops-empty-state { color: #65758b; }
@media (min-width: 801px) {
  .topbar .mobile-nav-toggle { display: inline-flex !important; align-items: center; justify-content: center; }
  body.desktop-sidebar-pinned .topbar .mobile-nav-toggle { background: #e5f1ff; border-color: #aac9ee; color: #174a9b; }
}
@media (min-width: 981px) and (max-width: 1350px) {
  .topbar-status-chip:first-child { display: none; }
  .topbar-command-search { flex-basis: 220px; }
}
@media (max-width: 980px) {
  .page-content { padding: 16px; }
  .topbar { min-height: 68px; padding: 10px 12px; border-radius: 15px; }
  .topbar-left { gap: 10px; }
  .topbar-right { flex: 0 0 auto; }
  .topbar-command-search { display: none; }
  .topbar-status-group,
  .topbar-user-pill,
  .topbar-logout-btn { display: none; }
  .command-bar { flex-direction: column; align-items: stretch; padding: 16px; }
  .command-bar-right { flex-wrap: wrap; }
  .panel, .premium-panel { border-radius: 14px; }
}
@media (max-width: 600px) {
  .page-content { padding: 12px 12px 82px; }
  .topbar { margin-bottom: 12px; padding: 9px 10px; }
  .topbar .mobile-nav-toggle {
    width: 40px;
    height: 40px;
    padding: 0;
  }
  .topbar .mobile-nav-toggle span { display: none; }
  .topbar-eyebrow { font-size: 8px; }
  .topbar-title-block h2 {
    font-size: 17px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .login-help-row { align-items: flex-start; flex-direction: column; gap: 5px; }
  .command-subtitle { font-size: 12px; }
  .heatmap-panel { padding: 13px; }
  .panel-head { flex-wrap: wrap; }
  :where(.page-content) :where(.data-table, .premium-table) :where(th, td) { padding: 9px 10px; }
}
@media (prefers-reduced-motion: reduce) {
  .heatmap-tile, .desktop-sidebar-pin { transition: none; }
}
