/* EmpireConnections focused representative workspace.
   This file loads last and changes presentation only. Existing IDs and event
   handlers continue to own calling, campaigns, dispositions, DNC, and notes. */

body.empire-focused-advisor {
  --focus-page: #f3f6fb;
  --focus-surface: #ffffff;
  --focus-surface-soft: #eef3fb;
  --focus-surface-blue: #eaf2ff;
  --focus-ink: #13213d;
  --focus-muted: #66738b;
  --focus-line: #d9e1ee;
  --focus-blue: #1261e8;
  --focus-blue-strong: #084ec6;
  --focus-green: #137b4a;
  --focus-green-soft: #e5f7ed;
  --focus-red: #bb3243;
  --focus-red-soft: #fff0f2;
  --focus-shadow: 0 16px 36px rgba(18, 38, 74, .11);
  background: var(--focus-page) !important;
  color: var(--focus-ink) !important;
}

body.empire-focused-advisor .topbar.empireos-unified-header {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 18px !important;
  min-height: 64px !important;
  padding: 9px 18px !important;
  border-bottom: 1px solid #223450 !important;
  background: #0f1d31 !important;
  box-shadow: none !important;
}

body.empire-focused-advisor .topbar .empireos-header-copy,
body.empire-focused-advisor .topbar .empireos-header-mark,
body.empire-focused-advisor .topbar [data-empireos-updated],
body.empire-focused-advisor .topbar #power-goal-live {
  display: none !important;
}

body.empire-focused-advisor .topbar #workspace-brand {
  position: static !important;
  display: flex !important;
  align-items: center !important;
  width: auto !important;
  min-width: 0 !important;
  margin: 0 !important;
  transform: none !important;
}

body.empire-focused-advisor .topbar #workspace-brand-logo {
  width: auto !important;
  height: 42px !important;
  max-width: 220px !important;
  object-fit: contain !important;
}

body.empire-focused-advisor .topbar .top-actions {
  display: flex !important;
  align-items: center !important;
  justify-content: flex-end !important;
  gap: 10px !important;
  margin-left: auto !important;
}

body.empire-focused-advisor .topbar :is(#system-health, #customer-data-custody) {
  border-color: #314663 !important;
  background: #172840 !important;
  color: #dce7f7 !important;
}

body.empire-focused-advisor .topbar .text-button {
  color: #dce7f7 !important;
}

/* Campaign choice now lives in the compact context bar. */
body.empire-focused-advisor #advisor-panel > .campaign-membership-panel {
  display: none !important;
}

body.empire-focused-advisor main.shell {
  width: 100% !important;
  max-width: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

body.empire-focused-advisor #app-view.app-layout {
  display: block !important;
  width: 100% !important;
  max-width: none !important;
  min-height: calc(100vh - 64px) !important;
  margin: 0 !important;
  padding: 0 !important;
}

body.empire-focused-advisor #app-view > .sidebar,
body.empire-focused-advisor #workspace > .content-heading {
  display: none !important;
}

body.empire-focused-advisor #workspace.content {
  width: 100% !important;
  max-width: none !important;
  min-width: 0 !important;
  margin: 0 !important;
  padding: 16px !important;
  background: var(--focus-page) !important;
}

body.empire-focused-advisor #advisor-panel,
body.empire-focused-advisor #empire-mode-workspace-root {
  width: 100% !important;
  max-width: none !important;
  min-width: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
}

.empire-focused-context {
  display: grid;
  grid-template-columns: auto minmax(220px, 1fr) minmax(180px, auto) auto;
  align-items: center;
  gap: 14px;
  min-height: 76px;
  padding: 12px 16px;
  border: 1px solid var(--focus-line);
  border-radius: 14px 14px 0 0;
  background: var(--focus-surface);
}

.empire-focused-person-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: var(--focus-surface-blue);
  color: var(--focus-blue);
  font-size: 16px;
}

.empire-focused-person { min-width: 0; }
.empire-focused-person > span,
.empire-focused-campaign > span {
  display: block;
  margin-bottom: 3px;
  color: var(--focus-blue);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .09em;
}

.empire-focused-person h2 {
  margin: 0 !important;
  overflow: hidden;
  color: var(--focus-ink) !important;
  font-size: 20px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.empire-focused-person p {
  margin: 3px 0 0 !important;
  overflow: hidden;
  color: var(--focus-muted) !important;
  font-size: 12px !important;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.empire-focused-campaign {
  min-width: 0;
  padding-left: 14px;
  border-left: 1px solid var(--focus-line);
  text-align: right;
}

.empire-focused-campaign strong {
  display: block;
  max-width: 250px;
  overflow: hidden;
  color: var(--focus-ink);
  font-size: 13px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.empire-focused-live-state {
  display: grid;
  grid-template-columns: auto auto;
  align-items: center;
  gap: 2px 7px;
  min-width: 118px;
  min-height: 42px;
  padding: 7px 11px;
  border: 1px solid rgba(19, 123, 74, .28);
  border-radius: 999px;
  background: var(--focus-green-soft);
  color: var(--focus-green);
}

.empire-focused-live-state[data-tone="wrap"] {
  border-color: rgba(187, 50, 67, .22);
  background: var(--focus-red-soft);
  color: var(--focus-red);
}

.empire-focused-live-state i {
  grid-row: 1 / 3;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
}

.empire-focused-live-state span {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .06em;
}

.empire-focused-live-state strong {
  color: currentColor;
  font-size: 11px;
  font-weight: 700;
}

.empire-focused-navigation {
  position: relative;
  z-index: 12;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 52px;
  margin: 0 0 14px;
  padding: 0 14px;
  border: 1px solid var(--focus-line);
  border-top: 0;
  border-radius: 0 0 14px 14px;
  background: var(--focus-surface);
  box-shadow: 0 9px 22px rgba(18, 38, 74, .07);
}

.empire-focused-primary-nav,
.empire-focused-utility-nav {
  display: flex;
  align-items: center;
  gap: 5px;
}

.empire-focused-navigation button,
.empire-focused-navigation summary {
  min-height: 36px;
  padding: 8px 11px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--focus-muted);
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  list-style: none;
  cursor: pointer;
}

.empire-focused-navigation summary::-webkit-details-marker { display: none; }

.empire-focused-navigation button:hover,
.empire-focused-navigation summary:hover,
.empire-focused-navigation button.is-active {
  background: var(--focus-surface-blue);
  color: var(--focus-blue);
}

.empire-focused-navigation button:focus-visible,
.empire-focused-navigation summary:focus-visible,
.empire-focused-ready button:focus-visible {
  outline: 3px solid rgba(18, 97, 232, .28);
  outline-offset: 2px;
}

#empire-focused-more { position: relative; }
.empire-focused-more-menu {
  position: absolute;
  z-index: 20;
  top: calc(100% + 7px);
  right: 0;
  display: grid;
  gap: 4px;
  width: 220px;
  padding: 7px;
  border: 1px solid var(--focus-line);
  border-radius: 11px;
  background: var(--focus-surface);
  box-shadow: var(--focus-shadow);
}

.empire-focused-more-menu button {
  width: 100%;
  justify-content: flex-start;
  text-align: left;
}

body.empire-focused-advisor #empire-mode-workspace-root > .empire-mode-kpis,
body.empire-focused-advisor #empire-mode-workspace-root > .empire-mode-lower,
body.empire-focused-advisor #empire-mode-workspace-root > .empire-mode-tools-lower {
  display: none !important;
}

body.empire-focused-advisor #empire-mode-workspace-root > .empire-mode-grid {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) 292px !important;
  grid-auto-flow: row !important;
  gap: 14px !important;
  align-items: start !important;
  width: 100% !important;
  margin: 0 !important;
}

body.empire-focused-advisor #empire-mode-workspace-root > .empire-mode-grid > * {
  display: none !important;
}

body.empire-focused-advisor #empire-mode-workspace-root :is(.panel, #call-history, #advisor-messages, #mason-ai) {
  border: 1px solid var(--focus-line) !important;
  border-radius: 13px !important;
  background: var(--focus-surface) !important;
  color: var(--focus-ink) !important;
  box-shadow: var(--focus-shadow) !important;
}

body.empire-focused-advisor #empire-mode-workspace-root :is(.panel, #call-history, #advisor-messages, #mason-ai) :is(h2, h3, strong) {
  color: var(--focus-ink) !important;
}

body.empire-focused-advisor #empire-mode-workspace-root :is(.panel, #call-history, #advisor-messages, #mason-ai) :is(p, small) {
  color: var(--focus-muted) !important;
}

body.empire-focused-advisor #empire-mode-workspace-root .eyebrow {
  color: var(--focus-blue) !important;
}

.empire-focused-ready {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  min-height: 250px;
  padding: 32px;
  border: 1px solid var(--focus-line);
  border-radius: 14px;
  background: var(--focus-surface);
  box-shadow: var(--focus-shadow);
}

.empire-focused-ready-icon {
  display: grid;
  place-items: center;
  width: 72px;
  height: 72px;
  border-radius: 22px;
  background: var(--focus-surface-blue);
  color: var(--focus-blue);
  font-size: 32px;
}

.empire-focused-ready-copy > span {
  color: var(--focus-blue);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .1em;
}

.empire-focused-ready-copy h2 {
  margin: 6px 0 8px !important;
  color: var(--focus-ink) !important;
  font-size: 24px !important;
}

.empire-focused-ready-copy p {
  max-width: 620px;
  margin: 0 0 12px !important;
  color: var(--focus-muted) !important;
}

.empire-focused-ready-copy strong { color: var(--focus-green); }

.empire-focused-ready-actions {
  display: grid;
  gap: 9px;
  min-width: 210px;
}

.empire-focused-ready-actions button {
  min-height: 44px;
  border-radius: 9px;
  font-weight: 700;
}

.empire-focused-ready-actions .primary {
  border-color: var(--focus-blue) !important;
  background: var(--focus-blue) !important;
  color: #ffffff !important;
}

.empire-focused-ready-actions .secondary {
  border-color: var(--focus-line) !important;
  background: var(--focus-page) !important;
  color: var(--focus-ink) !important;
}

.empire-focused-last-call {
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--focus-muted);
  font-size: 11px;
}

body.empire-focused-advisor[data-empire-focus-view="work"][data-empire-call-phase="ready"] #empire-focused-ready {
  display: grid !important;
}

body.empire-focused-advisor[data-empire-focus-view="work"][data-empire-call-phase="connected"] #empire-mode-workspace-root > .empire-mode-grid > .script-panel:not([hidden]) {
  display: block !important;
  grid-column: 1 !important;
  grid-row: 1 !important;
  width: 100% !important;
  min-height: 330px !important;
  max-height: none !important;
  overflow: hidden !important;
}

body.empire-focused-advisor[data-empire-focus-view="work"][data-empire-call-phase="connected"] #empire-mode-workspace-root > .empire-mode-grid > .empire-mode-contact {
  display: block !important;
  grid-column: 2 !important;
  grid-row: 1 !important;
}

body.empire-focused-advisor[data-empire-focus-view="work"][data-empire-call-phase="connected"] .empire-mode-contact > :not(#customer-card) {
  display: none !important;
}

body.empire-focused-advisor[data-empire-focus-view="work"][data-empire-call-phase="wrap"] #empire-mode-workspace-root > .empire-mode-grid > .empire-mode-contact {
  display: grid !important;
  grid-column: 1 / -1 !important;
  grid-row: 1 !important;
  grid-template-columns: minmax(0, 1fr) 292px !important;
  gap: 14px !important;
}

body.empire-focused-advisor[data-empire-focus-view="work"][data-empire-call-phase="wrap"] .empire-mode-contact > #disposition-center {
  display: block !important;
  grid-column: 1 !important;
  grid-row: 1 !important;
}

body.empire-focused-advisor[data-empire-focus-view="work"][data-empire-call-phase="wrap"] .empire-mode-contact > #customer-card {
  display: block !important;
  grid-column: 2 !important;
  grid-row: 1 !important;
}

body.empire-focused-advisor[data-empire-focus-view="work"][data-empire-call-phase="wrap"] .empire-mode-contact > :not(#disposition-center):not(#customer-card) {
  display: none !important;
}

body.empire-focused-advisor[data-empire-focus-view="work"][data-empire-call-phase="wrap"] #empire-mode-workspace-root > .empire-mode-tools-lower {
  display: grid !important;
  grid-template-columns: 1fr !important;
  margin-top: 14px !important;
}

body.empire-focused-advisor[data-empire-focus-view="work"][data-empire-call-phase="wrap"] .empire-mode-mason-column {
  display: none !important;
}

body.empire-focused-advisor[data-empire-focus-view="work"][data-empire-call-phase="wrap"] .empire-mode-notes-column {
  display: block !important;
}

body.empire-focused-advisor[data-empire-focus-view="customer"] #empire-mode-workspace-root > .empire-mode-grid > .empire-mode-contact {
  display: block !important;
  grid-column: 1 / -1 !important;
  grid-row: 1 !important;
}

body.empire-focused-advisor[data-empire-focus-view="customer"] .empire-mode-contact > #customer-card {
  display: block !important;
}

body.empire-focused-advisor[data-empire-focus-view="customer"] .empire-mode-contact > #disposition-center {
  display: none !important;
}

body.empire-focused-advisor[data-empire-focus-view="offers"] #empire-mode-workspace-root > .empire-mode-grid > .empire-mode-knowledge {
  display: block !important;
  grid-column: 1 / -1 !important;
  grid-row: 1 !important;
  width: 100% !important;
  height: auto !important;
  overflow: visible !important;
}

body.empire-focused-advisor[data-empire-focus-view="offers"] #campaign-workspace {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 14px !important;
}

body.empire-focused-advisor[data-empire-focus-view="history"] #empire-mode-workspace-root > .empire-mode-lower {
  display: block !important;
  margin: 0 0 14px !important;
}

body.empire-focused-advisor[data-empire-focus-view="history"] .empire-mode-lower-right,
body.empire-focused-advisor[data-empire-focus-view="history"] #advisor-messages {
  display: none !important;
}

body.empire-focused-advisor[data-empire-focus-view="history"] .empire-mode-lower-left,
body.empire-focused-advisor[data-empire-focus-view="history"] #call-history:not([hidden]),
body.empire-focused-advisor[data-empire-focus-view="history"] #call-history .empire-call-history-results {
  display: block !important;
  width: 100% !important;
  max-height: none !important;
  opacity: 1 !important;
}

body.empire-focused-advisor[data-empire-focus-view="inbox"] #empire-mode-workspace-root > .empire-mode-lower {
  display: block !important;
  margin: 0 0 14px !important;
}

body.empire-focused-advisor[data-empire-focus-view="inbox"] .empire-mode-lower-left,
body.empire-focused-advisor[data-empire-focus-view="inbox"] #call-history {
  display: none !important;
}

body.empire-focused-advisor[data-empire-focus-view="inbox"] .empire-mode-lower-right,
body.empire-focused-advisor[data-empire-focus-view="inbox"] #advisor-messages:not([hidden]) {
  display: block !important;
  width: 100% !important;
}

body.empire-focused-advisor[data-empire-focus-view="performance"] #empire-mode-workspace-root > .empire-mode-kpis {
  display: grid !important;
  margin: 0 0 14px !important;
}

body.empire-focused-advisor[data-empire-focus-view="mason"] #empire-mode-workspace-root > .empire-mode-tools-lower {
  display: grid !important;
  grid-template-columns: 1fr !important;
  margin: 0 0 14px !important;
}

body.empire-focused-advisor[data-empire-focus-view="mason"] .empire-mode-mason-column,
body.empire-focused-advisor[data-empire-focus-view="mason"] #mason-ai:not([hidden]) {
  display: block !important;
  width: 100% !important;
  max-height: none !important;
}

body.empire-focused-advisor[data-empire-focus-view="mason"] .empire-mode-notes-column {
  display: none !important;
}

/* The live telephone remains a compact dock in every workspace view. */
body.empire-focused-advisor #empire-mode-workspace-root > .empire-mode-grid > .empire-mode-phone {
  display: block !important;
  grid-column: 1 / -1 !important;
  grid-row: 20 !important;
  width: 100% !important;
}

body.empire-focused-advisor .empire-mode-phone > .phone-panel {
  width: 100% !important;
  margin: 0 !important;
  padding: 11px 14px !important;
  overflow: visible !important;
}

body.empire-focused-advisor .empire-mode-phone .phone-panel > .panel-heading {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 12px !important;
  margin: 0 0 9px !important;
  padding: 0 !important;
}

body.empire-focused-advisor .empire-mode-phone .phone-panel > .panel-heading > div:first-child .eyebrow,
body.empire-focused-advisor .empire-mode-phone .phone-panel > .panel-heading > div:first-child p,
body.empire-focused-advisor .empire-mode-phone #phone-dialer-toggle {
  display: none !important;
}

body.empire-focused-advisor .empire-mode-phone .phone-panel > .panel-heading h2 {
  margin: 0 !important;
  color: #ffffff !important;
  font-size: 15px !important;
}

body.empire-focused-advisor .empire-mode-phone .phone-panel-heading-actions {
  display: flex !important;
  align-items: center !important;
  justify-content: flex-end !important;
  gap: 8px !important;
  width: auto !important;
}

body.empire-focused-advisor .empire-mode-phone #phone-status,
body.empire-focused-advisor .empire-mode-phone #phone-campaign-command {
  width: auto !important;
  min-width: 0 !important;
  min-height: 34px !important;
  padding: 7px 10px !important;
  border: 1px solid var(--focus-line) !important;
  border-radius: 999px !important;
  background: var(--focus-surface-soft) !important;
  color: var(--focus-muted) !important;
  box-shadow: none !important;
  font-size: 10px !important;
}

body.empire-focused-advisor .empire-mode-phone #phone-status[data-tone="active"],
body.empire-focused-advisor .empire-mode-phone #phone-status[data-tone="online"] {
  border-color: rgba(19, 123, 74, .25) !important;
  background: var(--focus-green-soft) !important;
  color: var(--focus-green) !important;
}

body.empire-focused-advisor .empire-mode-phone #phone-dialer-body {
  display: block !important;
  width: 100% !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.empire-focused-advisor .empire-mode-phone .phone-screen,
body.empire-focused-advisor .empire-mode-phone .dial-pad,
body.empire-focused-advisor .empire-mode-phone #power-dial-terminal,
body.empire-focused-advisor .empire-mode-phone #empire-phone-alert-center,
body.empire-focused-advisor .empire-mode-phone #dial-mode-panel {
  display: none !important;
}

body.empire-focused-advisor .empire-mode-phone .phone-deck {
  display: block !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
}

body.empire-focused-advisor .empire-mode-phone .phone-action-stack {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex-wrap: wrap !important;
  gap: 8px !important;
  width: 100% !important;
}

body.empire-focused-advisor .empire-mode-phone .phone-action-stack > button {
  flex: 1 1 118px !important;
  width: auto !important;
  min-width: 118px !important;
  min-height: 42px !important;
  margin: 0 !important;
  padding: 8px 13px !important;
  border: 1px solid var(--focus-line) !important;
  border-radius: 10px !important;
  background: var(--focus-page) !important;
  color: var(--focus-ink) !important;
  box-shadow: none !important;
  font-size: 13px !important;
}

body.empire-focused-advisor .empire-mode-phone .phone-action-stack > #call-button:not(:disabled) {
  border-color: var(--focus-blue) !important;
  background: var(--focus-blue) !important;
  color: #ffffff !important;
}

body.empire-focused-advisor .empire-mode-phone .phone-action-stack > #hangup-button:not(:disabled) {
  border-color: rgba(187, 50, 67, .28) !important;
  background: var(--focus-red-soft) !important;
  color: var(--focus-red) !important;
}

body.empire-focused-advisor .empire-mode-phone .phone-action-stack > button:disabled {
  opacity: .42 !important;
}

body.empire-focused-advisor .empire-mode-phone #to-panel:not([hidden]) {
  order: 10 !important;
  flex: 1 1 100% !important;
  width: 100% !important;
  border-color: var(--focus-line) !important;
  background: var(--focus-surface-soft) !important;
  color: var(--focus-ink) !important;
}

body.empire-focused-advisor.empire-focused-phone-tools-open .empire-mode-phone .phone-screen,
body.empire-focused-advisor.empire-focused-phone-tools-open .empire-mode-phone .dial-pad,
body.empire-focused-advisor.empire-focused-phone-tools-open .empire-mode-phone #empire-phone-alert-center,
body.empire-focused-advisor.empire-focused-phone-tools-open .empire-mode-phone #dial-mode-panel {
  display: grid !important;
}

body.empire-focused-advisor.empire-focused-phone-tools-open .empire-mode-phone .phone-deck {
  display: grid !important;
  grid-template-columns: minmax(240px, .72fr) minmax(300px, 1.28fr) !important;
  gap: 14px !important;
}

body.empire-focused-advisor.empire-focused-phone-tools-open .empire-mode-phone .phone-screen {
  margin-bottom: 14px !important;
  border-color: var(--focus-line) !important;
  background: var(--focus-page) !important;
  color: var(--focus-ink) !important;
}

body.empire-focused-advisor.empire-focused-phone-tools-open .empire-mode-phone .phone-action-stack {
  align-content: center !important;
}

/* Connected call: show only a useful customer snapshot beside the script. */
body.empire-focused-advisor[data-empire-focus-view="work"] #customer-card {
  min-height: 330px !important;
  padding: 15px !important;
  overflow: hidden !important;
}

body.empire-focused-advisor[data-empire-focus-view="work"] #customer-card .section-title {
  margin: 0 0 10px !important;
}

body.empire-focused-advisor[data-empire-focus-view="work"] #customer-card .section-title p,
body.empire-focused-advisor[data-empire-focus-view="work"] #customer-card .lead-controls,
body.empire-focused-advisor[data-empire-focus-view="work"] #tenant-customer-search-form,
body.empire-focused-advisor[data-empire-focus-view="work"] .empire-customer-sheet-toggle,
body.empire-focused-advisor[data-empire-focus-view="work"] .empire-customer-sheet-page,
body.empire-focused-advisor[data-empire-focus-view="work"] .empire-customer-sheet-secondary {
  display: none !important;
}

body.empire-focused-advisor[data-empire-focus-view="work"] #customer-grid.empire-customer-sheet-shell,
body.empire-focused-advisor[data-empire-focus-view="work"] .empire-customer-sheet-viewport,
body.empire-focused-advisor[data-empire-focus-view="work"] .empire-customer-sheet-track {
  display: block !important;
  width: 100% !important;
  height: auto !important;
  min-height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  transform: none !important;
  border: 0 !important;
  background: transparent !important;
}

body.empire-focused-advisor[data-empire-focus-view="work"] .empire-customer-sheet-primary {
  display: grid !important;
  grid-template-columns: 1fr !important;
  gap: 0 !important;
  width: 100% !important;
  height: auto !important;
  padding: 0 !important;
  background: transparent !important;
}

body.empire-focused-advisor[data-empire-focus-view="work"] .empire-customer-sheet-primary .empire-customer-field {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 10px !important;
  min-height: 39px !important;
  padding: 8px 0 !important;
  border-bottom: 1px solid var(--focus-line) !important;
  background: transparent !important;
}

body.empire-focused-advisor[data-empire-focus-view="work"] .empire-customer-sheet-primary .empire-customer-field:nth-child(n+7) {
  display: none !important;
}

body.empire-focused-advisor[data-empire-focus-view="work"] .empire-customer-field small {
  margin: 0 !important;
  color: var(--focus-muted) !important;
  font-size: 10px !important;
}

body.empire-focused-advisor[data-empire-focus-view="work"] .empire-customer-field strong {
  max-width: 58% !important;
  color: var(--focus-ink) !important;
  font-size: 11px !important;
  text-align: right !important;
}

body.empire-focused-advisor .script-panel {
  padding: 18px !important;
}

body.empire-focused-advisor .script-panel .section-title {
  margin-bottom: 12px !important;
}

body.empire-focused-advisor .script-panel .script-copy {
  max-height: 250px !important;
  padding: 16px !important;
  overflow-y: auto !important;
  border: 0 !important;
  border-radius: 10px !important;
  background: var(--focus-surface-blue) !important;
  color: var(--focus-ink) !important;
}

body.empire-focused-advisor .script-panel .script-copy p {
  color: var(--focus-ink) !important;
  font-size: 14px !important;
  line-height: 1.55 !important;
}

body.empire-focused-advisor #disposition-center {
  min-height: 330px !important;
  padding: 18px !important;
}

body.empire-focused-advisor #disposition-center #disposition-rail {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 8px !important;
}

body.empire-focused-advisor #disposition-center .disp {
  min-height: 46px !important;
  border-color: var(--focus-line) !important;
  border-radius: 9px !important;
  background: var(--focus-page) !important;
  color: var(--focus-ink) !important;
  box-shadow: none !important;
}

body.empire-focused-advisor #disposition-center .disp[data-disposition-id="dnc"],
body.empire-focused-advisor #disposition-center .disp.dnc {
  border-color: rgba(187, 50, 67, .28) !important;
  background: var(--focus-red-soft) !important;
  color: var(--focus-red) !important;
}

body.empire-focused-advisor :is(input, select, textarea) {
  border-color: var(--focus-line) !important;
  background: var(--focus-page) !important;
  color: var(--focus-ink) !important;
}

body.empire-focused-advisor #call-history.empire-call-history-drawer .section-title::after {
  display: none !important;
}

body.empire-focused-advisor #call-history.empire-call-history-drawer .call-history-toolbar {
  position: static !important;
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) 150px !important;
}

body.empire-focused-advisor #advisor-messages > summary {
  min-height: 66px !important;
  color: var(--focus-ink) !important;
}

@media (max-width: 860px) {
  body.empire-focused-advisor .topbar #customer-data-custody,
  body.empire-focused-advisor .topbar #system-health {
    display: none !important;
  }

  .empire-focused-context {
    grid-template-columns: auto minmax(0, 1fr) auto;
  }

  .empire-focused-campaign { display: none; }

  .empire-focused-navigation {
    align-items: stretch;
    flex-direction: column;
    gap: 6px;
    padding: 8px;
  }

  .empire-focused-primary-nav,
  .empire-focused-utility-nav {
    width: 100%;
    justify-content: center;
    flex-wrap: wrap;
  }

  body.empire-focused-advisor #empire-mode-workspace-root > .empire-mode-grid,
  body.empire-focused-advisor[data-empire-focus-view="work"][data-empire-call-phase="wrap"] #empire-mode-workspace-root > .empire-mode-grid > .empire-mode-contact {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  body.empire-focused-advisor[data-empire-focus-view="work"][data-empire-call-phase="connected"] #empire-mode-workspace-root > .empire-mode-grid > .script-panel,
  body.empire-focused-advisor[data-empire-focus-view="work"][data-empire-call-phase="connected"] #empire-mode-workspace-root > .empire-mode-grid > .empire-mode-contact,
  body.empire-focused-advisor[data-empire-focus-view="work"][data-empire-call-phase="wrap"] .empire-mode-contact > #disposition-center,
  body.empire-focused-advisor[data-empire-focus-view="work"][data-empire-call-phase="wrap"] .empire-mode-contact > #customer-card {
    grid-column: 1 !important;
    grid-row: auto !important;
  }

  .empire-focused-ready {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .empire-focused-ready-actions {
    grid-column: 1 / -1;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .empire-focused-last-call { grid-column: 1 / -1; }

  body.empire-focused-advisor[data-empire-focus-view="offers"] #campaign-workspace,
  body.empire-focused-advisor.empire-focused-phone-tools-open .empire-mode-phone .phone-deck {
    grid-template-columns: 1fr !important;
  }
}

@media (max-width: 560px) {
  body.empire-focused-advisor .topbar.empireos-unified-header {
    min-height: 56px !important;
    padding: 7px 10px !important;
  }

  body.empire-focused-advisor .topbar #workspace-brand-logo { height: 34px !important; }
  body.empire-focused-advisor .topbar #empireos-header-refresh,
  body.empire-focused-advisor .topbar .dual-view-admin { display: none !important; }
  body.empire-focused-advisor #workspace.content { padding: 8px !important; }

  .empire-focused-context {
    grid-template-columns: auto minmax(0, 1fr);
    gap: 10px;
    min-height: 68px;
    padding: 10px;
  }

  .empire-focused-live-state {
    grid-column: 1 / -1;
    justify-self: stretch;
    justify-content: center;
    border-radius: 9px;
  }

  .empire-focused-person h2 { font-size: 17px !important; }
  .empire-focused-person p { white-space: normal; }

  .empire-focused-navigation button,
  .empire-focused-navigation summary {
    flex: 1 1 auto;
    min-height: 42px;
  }

  #empire-focused-more { flex: 1 1 auto; }
  #empire-focused-more summary { width: 100%; text-align: center; }
  .empire-focused-more-menu { right: 0; width: min(240px, calc(100vw - 34px)); }

  .empire-focused-ready {
    grid-template-columns: 1fr;
    justify-items: center;
    min-height: 0;
    padding: 24px 18px;
    text-align: center;
  }

  .empire-focused-ready-actions {
    grid-column: 1;
    grid-template-columns: 1fr;
    width: 100%;
    min-width: 0;
  }

  .empire-focused-last-call { grid-column: 1; justify-content: center; }

  body.empire-focused-advisor .empire-mode-phone .phone-panel > .panel-heading,
  body.empire-focused-advisor .empire-mode-phone .phone-panel-heading-actions {
    align-items: stretch !important;
    flex-direction: column !important;
    width: 100% !important;
  }

  body.empire-focused-advisor .empire-mode-phone #phone-status,
  body.empire-focused-advisor .empire-mode-phone #phone-campaign-command,
  body.empire-focused-advisor .empire-mode-phone .phone-action-stack > button {
    width: 100% !important;
  }

  body.empire-focused-advisor #disposition-center #disposition-rail,
  body.empire-focused-advisor #call-history.empire-call-history-drawer .call-history-toolbar {
    grid-template-columns: 1fr !important;
  }
}

/* Final compact-phone overrides intentionally live last so older dialer skins
   cannot expand the representative dock back into a second workspace. */
body.empire-focused-advisor #empire-mode-workspace-root .empire-mode-phone .phone-panel > .panel-heading > div:first-child {
  display: none !important;
}

body.empire-focused-advisor #empire-mode-workspace-root .empire-mode-phone .phone-panel,
body.empire-focused-advisor #empire-mode-workspace-root .empire-mode-phone #phone-dialer-body,
body.empire-focused-advisor #empire-mode-workspace-root .empire-mode-phone .phone-deck {
  min-height: 0 !important;
  height: auto !important;
}

body.empire-focused-advisor #empire-mode-workspace-root .empire-mode-phone .phone-panel-heading-actions {
  display: grid !important;
  grid-template-columns: minmax(160px, 1fr) auto !important;
  width: 100% !important;
}

body.empire-focused-advisor #empire-mode-workspace-root .empire-mode-phone .phone-action-stack {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
}

body.empire-focused-advisor #empire-mode-workspace-root .empire-mode-phone .phone-action-stack > button {
  min-width: 0 !important;
}

@media (max-width: 560px) {
  body.empire-focused-advisor #empire-mode-workspace-root .empire-mode-phone .phone-panel-heading-actions,
  body.empire-focused-advisor #empire-mode-workspace-root .empire-mode-phone .phone-action-stack {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}
