:root{
  /* brand */
  --gosi-navy:        #00004e;
  --gosi-navy-soft:   #111167;
  --gosi-green:       #00bf00;
  --gosi-green-deep:  #008f45;
  --gosi-green-light: #bfefbf;
  --gosi-blue:        #0064ff;

  /* surfaces + text */
  --gosi-canvas:      #e8eaee;
  --gosi-card:        #ffffff;
  --gosi-ink:         #161b2b;
  --gosi-muted:       #697386;
  --gosi-line:        #d9dde4;
  --gosi-shadow: 0 1px 2px rgba(0,20,80,.06), 0 8px 22px rgba(0,30,90,.07);

  /* semantic — status only, never decoration */
  --st-ready:    #00bf00;
  --st-notready: #b76a08;
  --st-acw:      #0064ff;
  --st-busy:     #c9363e;
  --st-out:      #697386;

  /* app.js writes these at runtime — keep the names */
  --accent:      var(--gosi-navy);
  --accent-soft: #eef0f7;

  --rail-width: 98px;
  --topbar-height: 66px;
  --radius-card: 10px;
  --radius-control: 7px;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { min-width: 320px; background: var(--gosi-canvas); }
body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  overflow: hidden;
  color: var(--gosi-ink);
  background: var(--gosi-canvas);
  font-family: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: .8125rem;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
}
button, input, select, textarea { font: inherit; }
button, select { cursor: pointer; }
button, input, select, textarea { color: var(--gosi-ink); }
button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, summary:focus-visible, iframe:focus-visible {
  outline: 2px solid var(--gosi-blue);
  outline-offset: 2px;
}
input, select, textarea {
  width: 100%;
  min-height: 36px;
  border: 1px solid var(--gosi-line);
  border-radius: var(--radius-control);
  background: var(--gosi-card);
  padding: 8px 10px;
}
textarea { resize: vertical; }
input::placeholder, textarea::placeholder { color: var(--gosi-muted); }
[hidden] { display: none !important; }
.svg-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}
.visually-hidden-select {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.eyebrow {
  display: block;
  margin-bottom: 2px;
  color: var(--gosi-muted);
  font-size: .6875rem;
  font-weight: 700;
  letter-spacing: .07em;
  line-height: 1.35;
  text-transform: uppercase;
}

/* Shell */
.app-shell { height: 100vh; height: 100dvh; min-height: 0; display: grid; grid-template-columns: var(--rail-width) minmax(0, 1fr); overflow: hidden; }
.rail {
  position: relative;
  z-index: 20;
  height: 100%;
  min-height: 0;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  padding: 10px 8px 12px;
  overflow: visible;
  background: var(--gosi-card);
  border-inline-end: 1px solid var(--gosi-line);
  box-shadow: 7px 0 25px rgba(0,0,50,.035);
}
.state-cluster { position: relative; display: flex; flex-direction: column; align-items: center; padding-bottom: 9px; }
.state-icon-btn {
  position: relative;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid var(--gosi-line);
  border-radius: 50%;
  color: var(--st-out);
  background: var(--gosi-card);
  box-shadow: var(--gosi-shadow);
}
.state-icon-btn::after {
  content: "";
  position: absolute;
  inset-block-end: 1px;
  inset-inline-end: 1px;
  width: 9px;
  height: 9px;
  border: 2px solid var(--gosi-card);
  border-radius: 50%;
  background: var(--st-out);
}
#statePill[data-state="Ready"] { color: var(--gosi-green-deep); border-color: var(--gosi-green-light); }
#statePill[data-state="Ready"]::after { background: var(--st-ready); }
#statePill[data-state="NotReady"] { color: var(--st-notready); }
#statePill[data-state="NotReady"]::after { background: var(--st-notready); }
#statePill[data-state="AfterCallWork"] { color: var(--st-acw); }
#statePill[data-state="AfterCallWork"]::after { background: var(--st-acw); }
#statePill[data-state="Busy"] { color: var(--st-busy); }
#statePill[data-state="Busy"]::after { background: var(--st-busy); }
#statePill[data-state="LoggedOut"] { color: var(--st-out); }
#statePill[data-state="LoggedOut"]::after { background: var(--st-out); }
.state-time {
  margin-top: 4px;
  color: var(--gosi-navy);
  font: 600 .625rem/1.2 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-variant-numeric: tabular-nums;
}
.state-menu {
  position: absolute;
  z-index: 100;
  inset-block-start: 0;
  inset-inline-start: calc(100% + 12px);
  width: 245px;
  padding: 7px;
  border: 1px solid var(--gosi-line);
  border-radius: 10px;
  background: var(--gosi-card);
  box-shadow: var(--gosi-shadow);
}
.state-menu-title { padding: 8px 10px 6px; color: var(--gosi-muted); font-size: .625rem; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; }
.state-menu button {
  width: 100%;
  min-height: 42px;
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) 18px;
  gap: 9px;
  align-items: center;
  padding: 5px 9px;
  border: 0;
  border-radius: 7px;
  color: var(--gosi-ink);
  background: transparent;
  text-align: start;
  font-size: .75rem;
  font-weight: 600;
}
.state-menu button:hover, .state-menu button:focus-visible { background: var(--accent-soft); }
.menu-state-icon { width: 28px; height: 28px; display: grid; place-items: center; border: 1px solid var(--gosi-line); border-radius: 50%; }
.menu-state-icon .icon { width: 15px; height: 15px; }
.menu-state-icon.supervising { color: var(--gosi-navy); }
.menu-state-icon.ready { color: var(--gosi-green-deep); background: var(--gosi-green-light); }
.menu-state-icon.break { color: var(--st-notready); }
.menu-state-icon.meeting { color: var(--st-acw); }
.menu-state-icon.technical { color: var(--st-busy); }
.state-menu .check { width: 15px; height: 15px; visibility: hidden; color: var(--gosi-navy); }
.state-menu button[aria-checked="true"] { color: var(--gosi-navy); background: var(--accent-soft); }
.state-menu button[aria-checked="true"] .check { visibility: visible; }
.rail-brand { height: 54px; display: grid; place-items: center; margin: 0 -2px 6px; border-block: 1px solid var(--gosi-line); }
.rail-brand img { display: block; width: 68px; max-height: 38px; object-fit: contain; }
.rail-items { display: flex; flex-direction: column; gap: 3px; }
.rail-btn {
  position: relative;
  min-height: 57px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 6px 3px;
  border: 0;
  border-radius: 7px;
  color: var(--gosi-muted);
  background: transparent;
  font-size: .5625rem;
  font-weight: 600;
}
.rail-btn::before { content: ""; position: absolute; inset-block: 11px; inset-inline-start: -8px; width: 3px; border-radius: 0 3px 3px 0; background: transparent; }
.rail-btn .icon { width: 19px; height: 19px; }
.rail-btn:hover { color: var(--gosi-navy); background: var(--accent-soft); }
.rail-btn.is-on { color: var(--gosi-navy); background: var(--accent-soft); font-weight: 700; }
.rail-btn.is-on .icon { color: var(--gosi-green-deep); }
.rail-btn.is-on::before { background: var(--gosi-navy); }
.rail-launcher { width: 38px; height: 38px; display: grid; place-items: center; margin: auto auto 0; padding: 0; border: 1px solid var(--gosi-line); border-radius: 8px; color: var(--gosi-muted); background: var(--gosi-card); }
.rail-launcher:hover { color: var(--gosi-navy); background: var(--accent-soft); }

.desktop { width: 100%; min-width: 0; height: 100%; min-height: 0; display: grid; grid-template-rows: var(--topbar-height) minmax(0, 1fr); overflow: hidden; }
.topbar {
  position: relative;
  z-index: 10;
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto;
  align-items: center;
  gap: 20px;
  padding: 0 14px 0 18px;
  border-bottom: 1px solid var(--gosi-line);
  background: var(--gosi-card);
}
.topbar-title { min-width: 0; }
.topbar-title > div { display: flex; align-items: baseline; gap: 9px; min-width: 0; }
.topbar-title strong { color: var(--gosi-navy); font-size: .9375rem; font-weight: 700; white-space: nowrap; }
.topbar-title div span { min-width: 0; overflow: hidden; color: var(--gosi-muted); font-size: .6875rem; text-overflow: ellipsis; white-space: nowrap; }
.queue-metrics { height: 40px; display: flex; align-items: stretch; border: 1px solid var(--gosi-line); border-radius: 8px; background: var(--gosi-card); }
.queue-metrics div { min-width: 86px; display: flex; align-items: center; justify-content: center; gap: 7px; padding: 0 11px; border-inline-end: 1px solid var(--gosi-line); }
.queue-metrics div:last-child { border-inline-end: 0; }
.queue-metrics span { color: var(--gosi-muted); font-size: .625rem; }
.queue-metrics strong { color: var(--gosi-navy); font-size: .8125rem; font-variant-numeric: tabular-nums; }
.topbar-actions { display: flex; align-items: center; justify-content: flex-end; gap: 8px; min-width: 0; }
.mode-badge { padding: 3px 7px; border: 1px solid var(--gosi-line); border-radius: 999px; color: var(--gosi-muted); background: var(--gosi-card); font-size: .5625rem; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; }
#modeBadge[data-live="1"] { color: var(--gosi-navy); border-color: var(--gosi-navy); }
.icon-button, .collapse-button {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid var(--gosi-line);
  border-radius: 7px;
  color: var(--gosi-muted);
  background: var(--gosi-card);
}
.icon-button:hover, .collapse-button:hover { color: var(--gosi-navy); background: var(--accent-soft); }
.topbar-actions > .icon-button { position: relative; }
.topbar-actions > .icon-button i { position: absolute; inset-block-start: 6px; inset-inline-end: 6px; width: 5px; height: 5px; border-radius: 50%; background: var(--st-busy); }
.desktop-settings { position: relative; }
.desktop-settings summary { width: 34px; height: 34px; display: grid; place-items: center; list-style: none; border: 1px solid var(--gosi-line); border-radius: 7px; color: var(--gosi-muted); cursor: pointer; }
.desktop-settings summary::-webkit-details-marker { display: none; }
.desktop-settings[open] summary { color: var(--gosi-navy); background: var(--accent-soft); }
.settings-popover { position: absolute; z-index: 80; inset-block-start: 42px; inset-inline-end: 0; width: 294px; padding: 14px; border: 1px solid var(--gosi-line); border-radius: 10px; background: var(--gosi-card); box-shadow: var(--gosi-shadow); }
.settings-heading { display: flex; flex-direction: column; margin-bottom: 11px; }
.settings-heading strong { color: var(--gosi-navy); font-size: .8125rem; }
.settings-heading small { color: var(--gosi-muted); font-size: .625rem; }
.settings-popover label { display: block; margin: 9px 0 4px; color: var(--gosi-muted); font-size: .625rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.settings-actions { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-top: 10px; }
.settings-actions.session-actions { grid-template-columns: 1fr 1fr; padding-top: 10px; border-top: 1px solid var(--gosi-line); }
.agent-chip { min-width: 0; display: flex; align-items: center; gap: 8px; padding-inline-start: 8px; border-inline-start: 1px solid var(--gosi-line); }
.agent-chip > span { width: 34px; height: 34px; flex: 0 0 34px; display: grid; place-items: center; border-radius: 50%; color: var(--gosi-card); background: var(--gosi-navy); font-size: .625rem; font-weight: 800; }
.agent-chip div { min-width: 0; display: flex; flex-direction: column; }
.agent-chip strong { font-size: .6875rem; white-space: nowrap; }
.agent-chip small { color: var(--gosi-muted); font-size: .5625rem; white-space: nowrap; }

/* Shared components */
.workspace-grid {
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(280px, 320px) minmax(0, 1fr) minmax(270px, 300px);
  gap: 8px;
  padding: 8px;
  overflow: hidden;
}
.left-column, .centre-column, .right-column { min-width: 0; min-height: 0; overflow-y: auto; scrollbar-width: thin; }
.left-column, .right-column { display: flex; flex-direction: column; gap: 8px; }
.centre-column { overflow-x: hidden; }
.card { border: 1px solid var(--gosi-line); border-radius: var(--radius-card); background: var(--gosi-card); box-shadow: var(--gosi-shadow); }
.card-header, .section-title, .right-card-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.section-title h2, .right-card-header h2 { margin: 0; color: var(--gosi-navy); font-size: .875rem; line-height: 1.25; }
.btn { min-height: 34px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 7px 11px; border: 1px solid transparent; border-radius: 7px; font-size: .6875rem; font-weight: 700; }
.btn .icon { width: 15px; height: 15px; }
.btn.primary { color: var(--gosi-card); border-color: var(--gosi-navy); background: var(--gosi-navy); }
.btn.primary:hover { background: var(--gosi-navy-soft); }
.btn.secondary { color: var(--gosi-navy); border-color: var(--gosi-line); background: var(--gosi-card); }
.btn.secondary:hover { background: var(--accent-soft); }
.text-button { display: inline-flex; align-items: center; gap: 5px; padding: 3px; border: 0; color: var(--gosi-navy); background: transparent; font-size: .625rem; font-weight: 700; }
.text-button .icon { width: 13px; height: 13px; }
.text-button:hover { text-decoration: underline; }
.status-pill { display: inline-flex; align-items: center; width: max-content; padding: 3px 7px; border-radius: 999px; font-size: .5625rem; font-style: normal; font-weight: 700; white-space: nowrap; }
.status-pill.pending { color: var(--st-notready); border: 1px solid var(--st-notready); background: var(--gosi-card); }
.status-pill.complete { color: var(--gosi-green-deep); background: var(--gosi-green-light); }
.status-pill.neutral { color: var(--gosi-muted); border: 1px solid var(--gosi-line); background: var(--gosi-card); }

/* Interaction list */
.interaction-list-card { min-height: 180px; flex: 1 1 0; display: flex; flex-direction: column; overflow: hidden; }
.interaction-list-header { min-height: 54px; padding: 9px 11px 7px; }
.interaction-list-header h1 { margin: 0; color: var(--gosi-navy); font-size: .875rem; line-height: 1.25; }
.interaction-list-header h1 b { display: inline-grid; place-items: center; min-width: 20px; height: 20px; margin-inline-start: 4px; padding: 0 5px; border-radius: 999px; color: var(--gosi-navy); background: var(--accent-soft); font-size: .625rem; }
.sort-control { display: flex; align-items: center; gap: 3px; color: var(--gosi-muted); font-size: .5625rem; white-space: nowrap; }
.sort-control select { width: auto; min-height: auto; padding: 2px 15px 2px 3px; border: 0; color: var(--gosi-navy); background: transparent; font-size: .5625rem; font-weight: 700; }
.channel-tabs { display: grid; grid-template-columns: repeat(4, 1fr); padding: 0 8px; border-block: 1px solid var(--gosi-line); }
.channel-tabs button { position: relative; min-height: 34px; padding: 4px 2px; border: 0; color: var(--gosi-muted); background: transparent; font-size: .75rem; font-weight: 700; }
.channel-tabs button::after { content: ""; position: absolute; inset-inline: 8px; inset-block-end: -1px; height: 2px; background: transparent; }
.channel-tabs button.is-active { color: var(--gosi-navy); }
.channel-tabs button.is-active::after { background: var(--gosi-navy); }
.channel-tabs span { color: var(--gosi-muted); font-size: .5625rem; }
.interaction-rows { min-height: 0; flex: 1 1 auto; display: flex; flex-direction: column; overflow-y: auto; }
.interaction-rows:empty::before { content: "No active interactions"; flex: 1; display: grid; place-items: center; padding: 20px; color: var(--gosi-muted); font-size: .75rem; text-align: center; }
.interaction-row { width: 100%; flex: 0 0 auto; display: grid; grid-template-columns: 32px minmax(0, 1fr) auto; gap: 8px; align-items: center; padding: 8px 10px; border: 0; border-bottom: 1px solid var(--gosi-line); background: var(--gosi-card); text-align: start; }
.interaction-row[role="status"] { flex: 1 0 auto; display: flex; flex-direction: column; justify-content: center; gap: 8px; border-bottom: 0; text-align: center; }
.interaction-row[role="status"] .row-copy { align-items: center; }
.interaction-row:last-child { border-bottom: 0; }
.interaction-row:hover { background: var(--accent-soft); }
.interaction-row.is-current { box-shadow: inset 3px 0 0 var(--gosi-navy); background: var(--accent-soft); }
.channel-avatar { width: 32px; height: 32px; display: grid; place-items: center; border: 1px solid var(--gosi-line); border-radius: 50%; }
.channel-avatar .icon { width: 15px; height: 15px; }
.channel-avatar.voice { color: var(--gosi-navy); }
.channel-avatar.chat { color: var(--gosi-blue); }
.channel-avatar.mail { color: var(--gosi-muted); }
.row-copy, .row-time { min-width: 0; display: flex; flex-direction: column; }
.row-copy strong { overflow: hidden; color: var(--gosi-ink); font-size: .75rem; text-overflow: ellipsis; white-space: nowrap; }
.row-copy small { color: var(--gosi-muted); font-size: .6875rem; }
.row-copy em { overflow: hidden; margin-top: 2px; color: var(--gosi-muted); font-size: .5625rem; font-style: normal; text-overflow: ellipsis; white-space: nowrap; }
.row-time { align-items: flex-end; align-self: stretch; justify-content: space-between; }
.row-time time { color: var(--gosi-navy); font: 600 .5625rem/1.3 ui-monospace, SFMono-Regular, Menlo, monospace; font-variant-numeric: tabular-nums; }
.sla-breach { display: flex; align-items: center; gap: 4px; padding: 2px 5px; border-radius: 999px; color: var(--gosi-card); background: var(--st-busy); font-size: .5rem; font-weight: 700; }
.sla-breach i { width: 4px; height: 4px; border-radius: 50%; background: var(--gosi-card); }

/* Call panel */
.call-panel { flex: 0 0 auto; overflow: hidden; }
.call-header { min-height: 57px; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 11px 9px 13px; border-bottom: 1px solid var(--gosi-line); background: var(--gosi-card); }
.call-title { min-width: 0; display: flex; flex-direction: column; }
.call-title > span { display: flex; align-items: center; gap: 6px; color: var(--gosi-navy); font-size: .625rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.call-title > span i { width: 7px; height: 7px; flex: 0 0 7px; border-radius: 50%; background: var(--gosi-green); }
.call-title strong { margin-top: 3px; overflow: hidden; color: var(--gosi-ink); font-size: .6875rem; text-overflow: ellipsis; white-space: nowrap; }
.call-header-actions { display: flex; align-items: center; gap: 7px; }
.call-header-actions time { color: var(--gosi-navy); font: 700 .875rem/1 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-variant-numeric: tabular-nums; }
.collapse-button { width: 30px; height: 30px; }
.collapse-button .icon { width: 15px; height: 15px; transition: transform 160ms ease; }
.call-panel.is-collapsed .call-header { border-bottom: 0; }
.call-panel.is-collapsed .collapse-button .icon { transform: rotate(-90deg); }
[dir="rtl"] .call-panel.is-collapsed .collapse-button .icon { transform: rotate(90deg); }
.caller-summary { display: flex; flex-direction: column; align-items: center; padding: 14px 12px 11px; }
.caller-avatar { position: relative; width: 48px; height: 48px; display: grid; place-items: center; border-radius: 50%; color: var(--gosi-card); background: var(--gosi-navy); font-size: .8125rem; font-weight: 800; }
.caller-avatar i { position: absolute; inset-inline-end: 1px; inset-block-end: 2px; width: 9px; height: 9px; border: 2px solid var(--gosi-card); border-radius: 50%; background: var(--gosi-green-deep); }
.caller-summary strong { margin-top: 7px; color: var(--gosi-navy); font-size: .8125rem; }
.phone-number { margin-top: 2px; color: var(--gosi-muted); font: .625rem/1.3 ui-monospace, SFMono-Regular, Menlo, monospace; direction: ltr; }
.call-meta { display: grid; grid-template-columns: repeat(3, 1fr); margin: 0; border-block: 1px solid var(--gosi-line); }
.call-meta div { min-width: 0; padding: 8px 5px; border-inline-end: 1px solid var(--gosi-line); text-align: center; }
.call-meta div:last-child { border-inline-end: 0; }
.call-meta dt { color: var(--gosi-muted); font-size: .5rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; }
.call-meta dd { margin: 2px 0 0; overflow: hidden; color: var(--gosi-navy); font-size: .5625rem; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.dock-btns { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 7px; padding: 10px; }
.call-panel[data-phase="ringing"] .dock-btns { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.call-control { min-width: 0; min-height: 57px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; padding: 6px 3px; border: 1px solid var(--gosi-line); border-radius: 8px; color: var(--gosi-muted); background: var(--gosi-card); font-size: .5625rem; font-weight: 700; }
.call-control .icon { width: 18px; height: 18px; }
.call-control:hover { color: var(--gosi-navy); border-color: var(--gosi-navy); background: var(--accent-soft); }
.call-control[aria-pressed="true"], .record-control { color: var(--gosi-navy); border-color: var(--gosi-navy); background: var(--accent-soft); }
.call-control.positive-action { color: var(--gosi-navy); border-color: var(--gosi-green); background: var(--gosi-green); }
.call-control.positive-action:hover { color: var(--gosi-navy); background: var(--gosi-green-light); }
.contract-action { display: none !important; }
.end-call { grid-column: 1 / -1; min-height: 38px; display: flex; align-items: center; justify-content: center; gap: 7px; border: 1px solid var(--st-busy); border-radius: 7px; color: var(--gosi-card); background: var(--st-busy); font-size: .6875rem; font-weight: 800; }
.end-call:hover { color: var(--gosi-card); background: var(--st-busy); }
.end-call .icon { width: 16px; height: 16px; transform: rotate(135deg); }
.call-tools { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; padding: 10px; border-top: 1px solid var(--gosi-line); background: var(--accent-soft); }
.quick-dial-field { grid-column: 1 / -1; }
.compact-field { min-width: 0; }
.compact-field label, .quick-note label, .composer label { display: block; margin-bottom: 4px; color: var(--gosi-muted); font-size: .5625rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.compact-field > div { display: flex; gap: 5px; }
.compact-field > div input { min-width: 0; }
.compact-field .btn { flex: 0 0 auto; }
.split-actions { margin-top: 5px; }
.split-actions .btn { flex: 1; }
.quick-note { padding: 10px; border-top: 1px solid var(--gosi-line); }
.quick-note textarea { min-height: 64px; font-size: .6875rem; }
.full-button { width: 100%; margin-top: 7px; }

/* Centre workspace */
.centre-column > .page { height: 100%; min-height: 0; }
.page { display: none; }
.page.is-on { display: block; }
.centre-column > .page.is-on { height: 100%; }
.canvas-tabs { height: 45px; display: flex; align-items: flex-end; gap: 2px; padding: 0 7px; overflow-x: auto; border: 1px solid var(--gosi-line); border-radius: 10px 10px 0 0; background: var(--gosi-card); box-shadow: var(--gosi-shadow); scrollbar-width: thin; }
.canvas-tabs button { position: relative; height: 44px; flex: 0 0 auto; padding: 0 10px; border: 0; color: var(--gosi-muted); background: transparent; font-size: .625rem; font-weight: 700; white-space: nowrap; }
.canvas-tabs button::after { content: ""; position: absolute; inset-inline: 10px; inset-block-end: -1px; height: 2px; background: transparent; }
.canvas-tabs button.is-active { color: var(--gosi-navy); }
.canvas-tabs button.is-active::after { background: var(--gosi-navy); }
.canvas-tabs button span { color: var(--gosi-muted); font-size: .5625rem; }
.canvas-scroll { height: calc(100% - 45px); overflow-y: auto; padding: 10px 2px 12px; scrollbar-width: thin; }
.canvas-panel { display: none; }
.canvas-panel.is-active { min-height: 100%; display: flex; flex-direction: column; gap: 8px; }
.form-card, .description-card, .linked-card, .wrapup-card, .customer-card-large, .data-card, .bp-card, .empty-state, .crm-frame-card { padding: 12px; }
.section-title { margin-bottom: 10px; }
.draft-badge, .field-status, .sync-label, .within-goal { display: inline-flex; align-items: center; gap: 5px; color: var(--gosi-green-deep); font-size: .5625rem; font-weight: 700; white-space: nowrap; }
.field-status { color: var(--st-notready); }
.sync-label i, .within-goal i { width: 6px; height: 6px; border-radius: 50%; background: var(--gosi-green-deep); }
.form-grid { width: 100%; max-width: 780px; display: grid; grid-template-columns: 1fr 1fr; gap: 9px 12px; margin-inline-end: auto; }
.form-grid label > span, .segmented-field legend, .wrapup-row label { display: block; margin-bottom: 4px; color: var(--gosi-muted); font-size: .75rem; font-weight: 600; }
.form-grid input, .form-grid select { min-height: 32px; padding-block: 6px; font-size: .75rem; }
.segmented-field { min-width: 0; margin: 0; padding: 0; border: 0; }
.segmented-field > div { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; min-height: 32px; padding: 2px; border: 1px solid var(--gosi-line); border-radius: 7px; background: var(--accent-soft); }
.segmented-field button { border: 0; border-radius: 5px; color: var(--gosi-muted); background: transparent; font-size: .75rem; font-weight: 700; }
.segmented-field button.is-selected { color: var(--gosi-card); background: var(--gosi-navy); }
.segmented-field button.is-selected.priority { color: var(--gosi-card); background: var(--st-notready); }
.description-card textarea { width: 100%; max-width: 780px; height: 100px; min-height: 90px; max-height: 260px; margin-inline-end: auto; padding: 7px 9px; font-size: .75rem; }
.description-footer { width: 100%; max-width: 780px; display: flex; align-items: center; justify-content: space-between; margin-top: 7px; margin-inline-end: auto; }
.description-footer span { color: var(--gosi-muted); font-size: .5625rem; }
.record-row { display: grid; grid-template-columns: 32px minmax(0, 1fr) auto auto; gap: 10px; align-items: center; padding: 9px 0; border-top: 1px solid var(--gosi-line); }
.record-icon { width: 30px; height: 30px; display: grid; place-items: center; border-radius: 7px; color: var(--gosi-navy); background: var(--accent-soft); font-size: .625rem; font-weight: 800; }
.record-row > div { min-width: 0; display: flex; flex-direction: column; }
.record-row strong { color: var(--gosi-navy); font-size: .6875rem; }
.record-row small, .record-row time { color: var(--gosi-muted); font-size: .5625rem; }
.wrapup-card { border-inline-start: 3px solid var(--gosi-blue); }
body:not(.has-active-interaction) .draft-badge,
body:not(.has-active-interaction) .wrapup-card { display: none; }
.wrapup-time { color: var(--st-busy); font: 700 .625rem/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; }
.wrapup-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; align-items: end; }
.wrapup-row label { margin: 0; }
.customer-hero { display: grid; grid-template-columns: 54px minmax(0, 1fr) auto; gap: 13px; align-items: center; padding-bottom: 15px; border-bottom: 1px solid var(--gosi-line); }
.customer-hero > span { width: 52px; height: 52px; display: grid; place-items: center; border-radius: 50%; color: var(--gosi-card); background: var(--gosi-navy); font-weight: 800; }
.customer-hero h2 { margin: 1px 0; color: var(--gosi-navy); font-size: 1rem; }
.customer-hero small, .customer-hero p { margin: 0; color: var(--gosi-muted); font-size: .625rem; }
.info-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; margin: 0; }
.info-grid div { padding: 13px 10px; border-bottom: 1px solid var(--gosi-line); }
.info-grid dt { color: var(--gosi-muted); font-size: .5625rem; }
.info-grid dd { margin: 3px 0 0; color: var(--gosi-ink); font-size: .6875rem; font-weight: 700; overflow-wrap: anywhere; }
.frame-label { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.frame-label > span { color: var(--gosi-muted); font-size: .5625rem; text-transform: uppercase; letter-spacing: .05em; }
.frame-label > strong { color: var(--gosi-navy); font-size: .75rem; }
.frame-label .text-button { margin-inline-start: auto; }
.crm-frame { width: 100%; height: 520px; display: block; border: 1px solid var(--gosi-line); border-radius: 8px; background: var(--gosi-card); }
.data-card { overflow: hidden; }
.data-card table { width: 100%; border-collapse: collapse; }
.data-card th, .data-card td { padding: 7px 9px; border-bottom: 1px solid var(--gosi-line); text-align: start; }
.data-card th { color: var(--gosi-muted); background: var(--accent-soft); font-size: .5625rem; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.data-card td { font-size: .625rem; }
.empty-state { min-height: 320px; display: flex !important; align-items: center; justify-content: center; text-align: center; }
.empty-state > .icon { width: 32px; height: 32px; color: var(--gosi-muted); }
.empty-state h2 { margin: 9px 0 3px; color: var(--gosi-navy); font-size: .875rem; }
.empty-state p { max-width: 340px; margin: 0; color: var(--gosi-muted); font-size: .6875rem; }
#bpMount {
  width: 100%;
  height: 520px;
  min-height: 360px;
  display: block;
  overflow: auto;
  border: 1px solid var(--gosi-line);
  border-radius: 8px;
  background: var(--gosi-card);
}
.mount-note { margin: 10px 0 0; padding: 9px 10px; border: 1px solid var(--gosi-line); border-radius: 7px; color: var(--gosi-muted); background: var(--accent-soft); font-size: .625rem; }
.mount-note strong { color: var(--gosi-navy); }
.admin-options { display: flex; flex-direction: column; }
.admin-options > div { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 13px 0; border-bottom: 1px solid var(--gosi-line); }
.admin-options > div:last-child { border-bottom: 0; }
.admin-options > div > .icon { width: 20px; height: 20px; margin: auto; color: var(--gosi-navy); }
.admin-options span { display: flex; flex-direction: column; }
.admin-options strong { font-size: .6875rem; }
.admin-options small { color: var(--gosi-muted); font-size: .5625rem; }

/* Standalone centre pages */
.standalone-page { height: 100%; overflow-y: auto; padding: 4px 2px 12px; }
.page-heading { padding: 12px 3px 16px; }
.page-heading h1 { margin: 0; color: var(--gosi-navy); font-size: 1.25rem; line-height: 1.2; }
.page-heading p { margin: 5px 0 0; color: var(--gosi-muted); font-size: .6875rem; }
.scripts-card, .kb-page { padding: 15px; }
.scripts-card ul { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 0; padding: 0; list-style: none; }
.scripts-card li { padding: 11px; border: 1px solid var(--gosi-line); border-radius: 7px; color: var(--gosi-ink); background: var(--gosi-card); font-size: .6875rem; cursor: pointer; }
.scripts-card li:hover { color: var(--gosi-navy); border-color: var(--gosi-navy); background: var(--accent-soft); }
.composer { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--gosi-line); }
.composer > div { display: flex; gap: 7px; }
.composer input { min-width: 0; }
.search-box { position: relative; display: flex; align-items: center; }
.search-box .icon { position: absolute; inset-inline-start: 11px; color: var(--gosi-muted); pointer-events: none; }
.search-box input { padding-inline-start: 38px; }
.kb-results { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 12px; }
.kb-results article { padding: 12px; border: 1px solid var(--gosi-line); border-radius: 8px; cursor: pointer; }
.kb-results article:hover { border-color: var(--gosi-navy); background: var(--accent-soft); }
.kb-results h4 { margin: 0 0 4px; color: var(--gosi-navy); font-size: .75rem; }
.kb-results p { margin: 0; color: var(--gosi-muted); font-size: .625rem; }
.report-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.metric-card { display: flex; flex-direction: column; padding: 18px; }
.metric-card > span { color: var(--gosi-muted); font-size: .625rem; font-weight: 700; }
.metric-card strong { margin: 8px 0 3px; color: var(--gosi-navy); font-size: 1.5rem; font-weight: 600; font-variant-numeric: tabular-nums; }
.metric-card small { color: var(--gosi-muted); font-size: .5625rem; }
.inline-heading { display: flex; align-items: center; justify-content: space-between; }
.log { width: 100%; height: calc(100% - 82px); min-height: 420px; margin: 0; padding: 14px; overflow: auto; border: 1px solid var(--gosi-line); border-radius: 10px; color: #e9edfa; background: #00004e; font: .625rem/1.6 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; white-space: pre-wrap; overflow-wrap: anywhere; }
.log .err { color: var(--st-busy); }
.log .ok { color: var(--gosi-green-light); }
.log .ev { color: #aab1c6; }

/* Right information column */
.right-column .right-card:first-child { flex: 1 0 auto; display: flex; flex-direction: column; }
.right-card { padding: 11px 12px; }
.right-card-header { margin-bottom: 7px; }
.right-card-header .icon-button { width: 29px; height: 29px; }
.right-card-header .icon-button .icon { width: 14px; height: 14px; }
.detail-list { margin: 0; }
.detail-list > div { min-width: 0; display: grid; grid-template-columns: minmax(88px, .8fr) minmax(0, 1.2fr); gap: 8px; align-items: center; min-height: 29px; padding: 5px 0; border-bottom: 1px solid var(--gosi-line); }
.detail-list > div:last-child { border-bottom: 0; }
.detail-list dt { overflow: hidden; color: var(--gosi-muted); font-size: .6875rem; text-overflow: ellipsis; white-space: nowrap; }
.detail-list dd { min-width: 0; margin: 0; overflow: hidden; color: var(--gosi-ink); font-size: .75rem; font-weight: 600; text-align: end; text-overflow: ellipsis; white-space: nowrap; }
body:not(.has-active-interaction) .detail-list { flex: 1; display: grid; place-items: center; }
body:not(.has-active-interaction) .detail-list::after { content: "No active interaction"; color: var(--gosi-muted); font-size: .75rem; text-align: center; }
body:not(.has-active-interaction) .detail-list > div { display: none; }
.sla-values { display: grid; grid-template-columns: 1fr 1fr; margin-bottom: 9px; }
.sla-values div { display: flex; flex-direction: column; padding: 4px 0; }
.sla-values div:last-child { align-items: flex-end; border-inline-start: 1px solid var(--gosi-line); }
.sla-values span { color: var(--gosi-muted); font-size: .5625rem; }
.sla-values strong { color: var(--gosi-navy); font: 700 .875rem/1.3 ui-monospace, SFMono-Regular, Menlo, monospace; }
.progress-track { height: 7px; overflow: hidden; border-radius: 999px; background: var(--gosi-line); }
.progress-track span { display: block; width: 0; height: 100%; border-radius: inherit; background: var(--gosi-navy); }
.progress-labels { display: flex; justify-content: space-between; margin-top: 5px; color: var(--gosi-muted); font-size: .5rem; }
.case-list { display: flex; flex-direction: column; }
.case-list button { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 9px 0; border: 0; border-top: 1px solid var(--gosi-line); background: transparent; text-align: start; }
.case-list button:first-child { border-top: 0; }
.case-list button:hover strong { color: var(--gosi-blue); }
.case-list button > span:first-child { min-width: 0; display: flex; flex-direction: column; }
.case-list strong { color: var(--gosi-navy); font-size: .625rem; }
.case-list small { overflow: hidden; color: var(--gosi-muted); font-size: .5625rem; text-overflow: ellipsis; white-space: nowrap; }
.suggestion-count { min-width: 21px; height: 21px; display: grid; place-items: center; border-radius: 999px; color: var(--gosi-navy); background: var(--accent-soft); font-size: .5625rem; font-weight: 800; }
.suggestion-list { display: flex; flex-direction: column; }
.suggestion-list button { width: 100%; display: grid; grid-template-columns: 52px minmax(0, 1fr) 15px; gap: 7px; align-items: center; padding: 9px 0; border: 0; border-top: 1px solid var(--gosi-line); background: transparent; text-align: start; }
.suggestion-list button:first-child { border-top: 0; }
.suggestion-list button > span { color: var(--gosi-blue); font: 600 .5625rem/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; }
.suggestion-list strong { color: var(--gosi-ink); font-size: .625rem; font-weight: 600; }
.suggestion-list .icon { width: 14px; height: 14px; color: var(--gosi-muted); transform: rotate(-90deg); }
[dir="rtl"] .suggestion-list .icon { transform: rotate(90deg); }

/* RTL and responsive resilience */
[dir="rtl"] .rail { box-shadow: -7px 0 25px rgba(0,0,50,.035); }
[dir="rtl"] .rail-btn::before { border-radius: 3px 0 0 3px; }
[dir="rtl"] .interaction-row.is-current { box-shadow: inset -3px 0 0 var(--gosi-navy); }
[dir="rtl"] .topbar { padding: 0 18px 0 14px; }

@media (max-width: 1500px) {
  .topbar { grid-template-columns: minmax(200px, 1fr) auto; gap: 12px; }
  .queue-metrics div { min-width: 75px; padding-inline: 8px; }
  .agent-chip div { display: none; }
  .agent-chip { padding-inline-start: 4px; }
  .workspace-grid { grid-template-columns: minmax(265px, .8fr) minmax(0, 2fr) minmax(258px, .76fr); gap: 8px; padding: 8px; }
  .call-tools { grid-template-columns: 1fr; }
  .info-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 1280px) {
  :root { --rail-width: 88px; }
  .rail { padding-inline: 6px; }
  .rail-btn::before { inset-inline-start: -6px; }
  .rail-brand img { width: 62px; }
  .topbar { grid-template-columns: minmax(190px, 1fr) auto; }
  .topbar-title div span { display: none; }
  .queue-metrics div:last-child { display: none; }
  .workspace-grid { grid-template-columns: minmax(260px, .74fr) minmax(0, 2fr) minmax(250px, .72fr); }
  .form-grid { gap: 11px; }
  .canvas-tabs button { padding-inline: 8px; }
  .record-row { grid-template-columns: 30px minmax(0, 1fr) auto; }
  .record-row time { display: none; }
}

@media (max-width: 1120px) {
  body { overflow: auto; }
  .app-shell { min-height: 100vh; }
  .desktop { min-height: 100vh; }
  .topbar { grid-template-columns: 1fr auto; }
  .queue-metrics { display: none; }
  .workspace-grid { min-height: calc(100vh - var(--topbar-height)); grid-template-columns: minmax(250px, 310px) minmax(0, 1fr); overflow: visible; }
  .right-column { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(2, 1fr); overflow: visible; }
  .left-column, .centre-column { min-height: calc(100vh - var(--topbar-height) - 16px); }
}

@media (max-width: 820px) {
  :root { --rail-width: 64px; --topbar-height: 58px; }
  .rail-btn span, .rail-brand { display: none; }
  .rail-btn { min-height: 49px; }
  .state-icon-btn { width: 38px; height: 38px; }
  .topbar { padding-inline: 10px; }
  .topbar-title .eyebrow, .mode-badge, .agent-chip { display: none; }
  .topbar-title strong { font-size: .8125rem; }
  .workspace-grid { grid-template-columns: 1fr; overflow: visible; }
  .left-column, .centre-column { min-height: auto; overflow: visible; }
  .interaction-list-card { display: none; }
  .right-column { grid-template-columns: 1fr; }
  .centre-column { min-height: 680px; }
  .form-grid, .info-grid, .scripts-card ul, .kb-results, .report-grid { grid-template-columns: 1fr; }
  .state-menu { position: fixed; inset-block-start: 8px; inset-inline-start: calc(var(--rail-width) + 8px); }
}

@media (max-width: 520px) {
  :root { --rail-width: 56px; }
  .rail { padding-inline: 4px; }
  .topbar-title strong { max-width: 150px; display: block; overflow: hidden; text-overflow: ellipsis; }
  .workspace-grid { padding: 6px; }
  .right-column { display: flex; }
  .form-card, .description-card, .linked-card, .wrapup-card, .customer-card-large, .data-card, .bp-card, .empty-state, .crm-frame-card { padding: 12px; }
  .form-grid { grid-template-columns: 1fr; }
  .record-row { grid-template-columns: 30px minmax(0, 1fr); }
  .record-row .status-pill { grid-column: 2; }
  .customer-hero { grid-template-columns: 45px minmax(0, 1fr); }
  .customer-hero > span { width: 44px; height: 44px; }
  .customer-hero .btn { grid-column: 1 / -1; }
  .wrapup-row { grid-template-columns: 1fr; }
  .crm-frame { height: 460px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}

/* Authentication gate — appended so the existing desktop remains untouched. */
body:not(.auth-desktop) .app-shell {
  /* Do NOT take this out of flow with position:fixed/inset:0. Tested: doing so makes
     Bright Pattern's widget render a blank frame — it evidently decides it is not
     visible and paints nothing, leaving the agent with an empty sign-in box.
     display:none is likewise forbidden: #bpMount lives in this subtree and would be
     torn down with the session.
     The RTL overflow this was meant to solve is handled instead by clipping the two
     collapsed containers below (.bp-card and .canvas-panel[hidden]). */
  visibility: hidden;
  pointer-events: none;
  user-select: none;
}

body.auth-desktop .auth-shell { display: none; }

.auth-shell {
  position: fixed;
  z-index: 100;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 28px;
  overflow: auto;
  background: var(--gosi-canvas);
}

.auth-frame {
  width: min(1080px, 100%);
  min-height: min(680px, calc(100vh - 56px));
  display: grid;
  grid-template-columns: minmax(310px, .82fr) minmax(500px, 1.18fr);
  overflow: hidden;
  border: 1px solid var(--gosi-line);
  border-radius: 14px;
  background: var(--gosi-card);
  box-shadow: var(--gosi-shadow);
}

.auth-context {
  display: flex;
  flex-direction: column;
  padding: 40px;
  color: var(--gosi-card);
  background: var(--gosi-navy);
}

.auth-brand {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 3px 16px;
  padding-bottom: 28px;
  border-bottom: 1px solid rgba(188,194,224,.18);
}

.auth-brand img {
  width: 118px;
  height: 54px;
  grid-row: 1 / 3;
  display: block;
  object-fit: contain;
  padding: 8px;
  border-radius: 8px;
  background: var(--gosi-card);
}

.auth-tenant-label {
  color: #aab1c6;
  font-size: .625rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.auth-tenant {
  color: #e9edfa;
  font: 600 .75rem/1.4 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  text-align: end;
  overflow-wrap: anywhere;
}

.auth-context-copy { margin: auto 0; padding: 48px 0; }
.auth-context .auth-kicker { color: #aab1c6; }
.auth-context h1 { max-width: 420px; margin: 12px 0 16px; color: var(--gosi-card); font-size: clamp(2rem, 4vw, 3.25rem); line-height: 1.06; letter-spacing: -.04em; }
.auth-context p { max-width: 430px; margin: 0; color: #aab1c6; font-size: .875rem; line-height: 1.7; }
.auth-kicker { display: block; color: var(--gosi-muted); font-size: .625rem; font-weight: 800; letter-spacing: .11em; text-transform: uppercase; }

.auth-assurance { display: grid; gap: 12px; margin: 0; padding: 24px 0 0; border-top: 1px solid rgba(188,194,224,.18); list-style: none; }
.auth-assurance li { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 9px; align-items: center; color: #e9edfa; font-size: .6875rem; }
.auth-assurance .icon { width: 18px; height: 18px; padding: 3px; border-radius: 50%; color: var(--gosi-navy); background: var(--gosi-green-light); stroke-width: 2.2; }

.auth-card {
  position: relative;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 42px 46px 30px;
  background: var(--gosi-card);
}

.auth-card-tools {
  position: absolute;
  inset-block-start: 24px;
  inset-inline: 30px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.auth-secure-label { display: inline-flex; align-items: center; gap: 6px; color: var(--gosi-muted); font-size: .625rem; font-weight: 700; }
.auth-secure-label .icon { width: 14px; height: 14px; color: var(--gosi-green-deep); }
.auth-language { min-height: 34px; padding: 5px 10px; border: 1px solid var(--gosi-line); border-radius: 7px; color: var(--gosi-navy); background: var(--gosi-card); font-size: .625rem; font-weight: 800; }
.auth-language:hover { background: var(--accent-soft); }

.auth-view { width: min(460px, 100%); margin: auto; padding: 52px 0 22px; }
.auth-view-heading { margin-bottom: 14px; }
.auth-view h2 { margin: 9px 0 8px; color: var(--gosi-navy); font-size: clamp(1.4rem, 3vw, 2rem); line-height: 1.2; letter-spacing: -.025em; }
.auth-view > p, .auth-view-heading p { margin: 0; color: var(--gosi-muted); font-size: .8125rem; line-height: 1.65; }

.auth-state-icon {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  margin-bottom: 24px;
  border: 1px solid var(--gosi-line);
  border-radius: 12px;
  color: var(--gosi-navy);
  background: var(--accent-soft);
}

.auth-state-icon .icon { width: 25px; height: 25px; }
.auth-state-icon.is-loading .icon { animation: auth-pulse 1.5s ease-in-out infinite; }
.auth-state-icon.is-error { color: var(--st-busy); background: var(--gosi-card); border-color: var(--st-busy); }

.auth-progress { height: 4px; margin-top: 30px; overflow: hidden; border-radius: 999px; background: var(--gosi-line); }
.auth-progress span { width: 38%; height: 100%; display: block; border-radius: inherit; background: var(--gosi-navy); animation: auth-progress 1.6s ease-in-out infinite; }

.auth-notice { margin-bottom: 12px; padding: 10px 12px; border: 1px solid var(--gosi-line); border-inline-start: 3px solid var(--gosi-navy); border-radius: 7px; color: var(--gosi-navy); background: var(--accent-soft); font-size: .6875rem; font-weight: 700; }
.auth-notice.is-expired { color: var(--st-busy); border-inline-start-color: var(--st-busy); background: var(--gosi-card); }

.auth-mount-slot { width: 500px; max-width: 100%; height: clamp(420px, calc(100vh - 200px), 760px); margin: 0 auto; border: 1px solid var(--gosi-line); border-radius: 9px; background: var(--gosi-card); box-shadow: var(--gosi-shadow); }
.auth-form-owner { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 12px !important; text-align: center; font-size: .625rem !important; }
.auth-form-owner .icon { width: 13px; height: 13px; flex: 0 0 13px; color: var(--gosi-green-deep); }

.auth-primary-button, .auth-secondary-button { min-height: 42px; display: inline-flex; align-items: center; justify-content: center; padding: 9px 16px; border-radius: 7px; font-size: .75rem; font-weight: 800; }
.auth-primary-button { border: 1px solid var(--gosi-green); color: var(--gosi-navy); background: var(--gosi-green); }
.auth-primary-button:hover { background: var(--gosi-green-light); }
.auth-secondary-button { border: 1px solid var(--gosi-line); color: var(--gosi-navy); background: var(--gosi-card); }
.auth-secondary-button:hover { background: var(--accent-soft); }
.auth-primary-button:disabled, .auth-secondary-button:disabled { cursor: not-allowed; opacity: .55; }

.auth-error-detail { margin: 18px 0 22px !important; padding: 11px 12px; border: 1px solid var(--gosi-line); border-radius: 7px; background: var(--accent-soft); font-size: .6875rem !important; }
.auth-live-status { min-height: 18px; margin: 0; color: var(--gosi-muted); font-size: .625rem; text-align: center; }

.auth-copy-ar { display: none; }
[lang="ar"] .auth-copy-en { display: none; }
[lang="ar"] .auth-copy-ar { display: inline; }
[lang="ar"] .auth-context h1 { letter-spacing: 0; }

/* #bpMount remains in its original DOM location for the entire session. */
.centre-column > .page[data-page="customer"] { display: block !important; }
.centre-column > .page[data-page="customer"]:not(.is-on) {
  position: absolute;
  width: 1px;
  height: 1px;
  min-height: 1px;
  top: 0;
  left: 0;
  overflow: visible;
  visibility: hidden;
  pointer-events: none;
}

.canvas-panel[data-canvas-panel="bp"] {
  position: absolute;
  width: 1px;
  height: 1px;
  min-height: 1px;
  top: 0;
  left: 0;
  display: block !important;
  overflow: visible;
  visibility: hidden;
  pointer-events: none;
}

body:not(.auth-awaiting) #bpMount {
  /* Park the live BP widget out of sight without destroying it.
     Offset on the VERTICAL axis only: a negative `left` is not scrollable in LTR but
     becomes 1000px of scrollable overflow once the scroll origin flips in RTL.
     Content above the viewport never produces a scrollbar in either direction. */
  position: absolute;
  width: 1px;
  height: 1px;
  min-height: 1px;
  top: -1000px;
  left: 0;
  right: auto;
  z-index: -1000;
  overflow: hidden;
  border: 0;
  border-radius: 0;
  visibility: visible;
  pointer-events: none;
}

/* Iframes are inline by default, so the line-box descender adds ~5px below BP's
   frame and makes the mount scroll. */
body.auth-awaiting #bpMount iframe { display: block; }

body.auth-awaiting #bpMount {
  /* The slot rect includes the border, so border-box would shave 2px off BP's
     500px iframe and clip its sign-in form. Keep the border outside the box. */
  box-sizing: content-box;
  position: fixed;
  top: var(--auth-mount-top, 190px);
  left: var(--auth-mount-left, calc(50% - 250px));
  z-index: 200;
  width: var(--auth-mount-width, 500px);
  height: var(--auth-mount-height, clamp(420px, calc(100vh - 200px), 760px));
  min-height: 370px;
  visibility: visible;
  pointer-events: auto;
  overflow: auto;
  border: 1px solid var(--gosi-line);
  border-radius: 9px;
  background: var(--gosi-card);
  box-shadow: var(--gosi-shadow);
}

@keyframes auth-pulse {
  0%, 100% { opacity: .5; }
  50% { opacity: 1; }
}

@keyframes auth-progress {
  0% { transform: translateX(-110%); }
  50% { transform: translateX(85%); }
  100% { transform: translateX(270%); }
}

[dir="rtl"] .auth-progress span { animation-name: auth-progress-rtl; }
@keyframes auth-progress-rtl {
  0% { transform: translateX(110%); }
  50% { transform: translateX(-85%); }
  100% { transform: translateX(-270%); }
}

@media (max-width: 900px) {
  .auth-shell { place-items: start center; padding: 18px; }
  .auth-frame { min-height: 0; grid-template-columns: 1fr; }
  .auth-context { padding: 24px 28px; }
  .auth-context-copy { padding: 30px 0 22px; }
  .auth-context h1 { max-width: none; font-size: 2rem; }
  .auth-assurance { display: none; }
  .auth-card { min-height: 590px; padding: 58px 28px 26px; }
}

@media (max-width: 520px) {
  .auth-shell { padding: 0; }
  .auth-frame { min-height: 100vh; border: 0; border-radius: 0; }
  .auth-context { padding: 18px 20px; }
  .auth-brand { padding-bottom: 15px; }
  .auth-brand img { width: 92px; height: 44px; }
  .auth-context-copy { padding: 22px 0 6px; }
  .auth-context h1 { margin: 7px 0; font-size: 1.5rem; }
  .auth-context p { font-size: .75rem; }
  .auth-card { min-height: 570px; padding: 58px 18px 22px; }
  .auth-card-tools { inset-block-start: 16px; inset-inline: 18px; }
  .auth-view { padding-top: 38px; }
  .auth-login-view { padding-top: 20px; }
  .auth-login-view .auth-view-heading p { display: none; }
  .auth-mount-slot { height: clamp(380px, calc(100vh - 170px), 760px); }
}


/* BP's sign-in iframe is a fixed 500px wide. The auth view must give the slot at
   least that much or the form is clipped and the agent cannot reach Sign In. */
.auth-view { width: 100%; }
@media (max-width: 620px) {
  /* Below BP's own minimum there is nothing to do but allow scrolling. */
  .auth-mount-slot { width: 100%; }
  body.auth-awaiting #bpMount { overflow: auto; }
}

/* The card that hosts #bpMount collapses to a sliver once the widget is parked
   off-screen, and its heading text then spilled past the viewport edge in RTL
   (~161px of horizontal scroll). Clip it.
   Safe for the sign-in screen: #bpMount is position:fixed while awaiting, and a
   fixed element's containing block is the viewport, so ancestor overflow cannot
   clip it. */
.bp-card { overflow: hidden; }

/* The desktop never scrolls the document horizontally — wide content (grids, tables,
   the CRM frame) scrolls inside its own container. Enforce it, so the sliver of the
   parked #bpMount card cannot drag a scrollbar into view under RTL.
   Scoped to the desktop state so the sign-in screen is unaffected. Safe for the parked
   mount: .app-shell is statically positioned here, so it is not the mount's containing
   block and cannot clip it. */
body.auth-desktop .app-shell { overflow-x: hidden; }

/* The panel holding #bpMount is kept rendered (not display:none) so the Bright Pattern
   iframe survives, which collapses it to a 1px absolutely-positioned box. Its card then
   spilled ~31px past the viewport edge in RTL and produced a real horizontal scrollbar.
   Clip it at the panel.
   Parked state: #bpMount is position:absolute and this panel is its containing block, so
   the mount is clipped too — harmless, it is already off-screen and clipping does not
   suspend an iframe. Sign-in state: #bpMount is position:fixed, so its containing block is
   the viewport and this rule cannot clip the visible form. */
.canvas-panel[hidden] { overflow: hidden; }

/* Shown in the STATE menu before sign-in, when the tenant's not-ready reasons
   have not been fetched yet. */
.state-menu-empty {
  margin: 4px 10px 8px;
  color: var(--gosi-muted);
  font-size: .75rem;
  line-height: 1.45;
}

/* Idle centre column ------------------------------------------------------
   With no interaction the activity form, description and wrap-up have nothing to act on,
   so they are hidden and a single centred idle card takes their place. This is what
   removes the large empty region below the form on an idle desktop. */
body:not(.has-interaction) .form-card,
body:not(.has-interaction) .description-card { display: none; }

/* Disposition is an after-call-work step, never something offered mid-call. */
body:not(.in-wrapup) .wrapup-card { display: none; }

body.has-interaction .centre-idle { display: none; }

.centre-idle {
  flex: 1 1 auto;
  display: grid;
  place-items: center;
  min-height: 0;
  padding: 32px 24px;
  text-align: center;
}
.centre-idle-inner { max-width: 34ch; display: grid; gap: 8px; justify-items: center; }
.centre-idle-mark {
  width: 42px; height: 42px; border-radius: 50%;
  display: grid; place-items: center; margin-bottom: 4px;
  color: var(--gosi-muted); background: var(--gosi-canvas);
  border: 1px solid var(--gosi-line);
}
.centre-idle-mark .icon { width: 19px; height: 19px; }
.centre-idle h2 {
  margin: 0; font-size: .95rem; font-weight: 700; color: var(--gosi-ink);
}
.centre-idle p {
  margin: 0; font-size: .78rem; line-height: 1.5; color: var(--gosi-muted);
}


/* Bright Pattern's sign-in form is taller than 500px, so a fixed-height mount made BP
   render its own scrollbar and pushed the "Log in" button below the fold. Let the mount
   take the height actually available instead. */

/* Sign-in must fit the viewport exactly ------------------------------------
   A fixed-height mount is wrong in both directions: too short and Bright Pattern renders
   its own scrollbar with "Log in" below the fold; too tall and the card (998px) overflows
   a short viewport (900px) and gets CLIPPED — worse than scrolling, because the button
   becomes unreachable.
   Make the card a flex column bounded by the viewport and let the mount take whatever is
   left after the heading and footer. Nothing scrolls, nothing clips. */
.auth-card {
  display: flex;
  flex-direction: column;
  max-height: 100%;
  min-height: 0;
  padding-top: clamp(18px, 3vh, 42px);
  padding-bottom: clamp(14px, 2.4vh, 30px);
}

.auth-view {
  display: flex;
  flex-direction: column;
  min-height: 0;
  flex: 1 1 auto;
  padding-top: clamp(10px, 2.4vh, 52px);
  padding-bottom: clamp(10px, 1.6vh, 22px);
}

/* The slot is the flexible element: it absorbs the leftover height. #bpMount is
   position:fixed and mirrors this element's measured rect, so sizing it here is enough. */
.auth-mount-slot {
  flex: 1 1 auto;
  height: auto;
  min-height: 360px;
  max-height: 760px;
}

.auth-frame { min-height: 0; }

/* The card must FILL the available height, not shrink to its content — otherwise the
   flexible mount collapses to its min-height and Bright Pattern's form is cut off again. */
.auth-shell { align-items: stretch; }
.auth-frame { height: 100%; }
.auth-card  { height: 100%; }

/* On a short window Bright Pattern's sign-in form is taller than the space available.
   Scrolling inside the frame is the only correct answer there — the alternative is the
   "Log in" button being cut off entirely, which is what happened at 720px. */
body.auth-awaiting #bpMount { overflow-y: auto; overflow-x: hidden; }

/* Bright Pattern's sign-in form needs roughly 610px. The SDK sets the iframe to height:100%,
   so on a short window the iframe shrank with the mount and the form was simply cut off with
   nothing to scroll. Give the frame its natural minimum and let the mount scroll it, so
   "Log in" is always reachable however short the window is. */
/* Normally the frame is exactly the mount's height and nothing scrolls. The minimum is
   applied only under the short-window rule below, where scrolling is the lesser evil. */
body.auth-awaiting #bpMount iframe { min-height: 0; }

/* At small viewport heights the clamped padding pulled the "AGENT ACCESS" eyebrow up
   underneath the "Secure session" status row. Keep them clear of each other. */
.auth-view { padding-top: max(24px, clamp(10px, 2.4vh, 52px)); }

/* Short windows -----------------------------------------------------------
   Bright Pattern's form needs ~610px. On a 720px-tall window the surrounding chrome
   (eyebrow, heading, subtitle, footer, padding) leaves only ~445px and the form gets cut
   off. Scrolling is not an acceptable answer for a sign-in screen, so below ~820px the
   chrome collapses instead and hands its space to the form. */
@media (max-height: 820px) {
  /* Bright Pattern's sign-in form is a fixed ~600px and will render its own scrollbar the
     moment it gets less. On a short window our own chrome is the only thing competing for
     that space, so drop it: the heading and subtitle go, leaving the secure-session row,
     the form, and the footer. Branding still sits in the navy panel alongside.
     This is what keeps "Log in" reachable without any scrollbar down to ~700px. */
  .auth-card { padding-top: 10px; padding-bottom: 8px; }
  .auth-card-tools { inset-block-start: 8px; }
  .auth-view { padding-top: 26px; padding-bottom: 4px; }
  .auth-view .auth-view-heading,
  .auth-view .auth-view-heading + p,
  .auth-view > p:not(.auth-notice):not(.hint) { display: none; }
  .auth-form-owner { margin-top: 4px !important; font-size: .58rem !important; }
  .auth-mount-slot { min-height: 600px; max-height: none; }
  .auth-status-note { display: none; }
}

/* Signed-out notices (expired / signed out) must survive the compact heading rule. */
@media (max-height: 820px) {
  .auth-view .auth-notice { display: block; margin-bottom: 6px; }
}

/* Below BP's own minimum there is genuinely nowhere left to go: let it scroll rather than
   hide the Log in button. */
@media (max-height: 700px) {
  /* Below BP's own minimum there is genuinely nowhere left to go: give the frame its
     natural height and let the mount scroll, so "Log in" stays reachable. */
  body.auth-awaiting #bpMount { overflow-y: auto; }
  body.auth-awaiting #bpMount iframe { min-height: 580px; }
}

/* Native credential sign-in ------------------------------------------------
   The communicator SDK is headless in this mode, so the login surface is part
   of GOSI's page. These rules intentionally come last and leave the BP fallback
   mount rules above intact for loginMode "bp". */
body.auth-mode-native .auth-shell {
  align-items: center;
  padding: clamp(18px, 3vh, 28px);
  overflow: hidden;
}

body.auth-mode-native .auth-frame {
  width: min(1060px, 100%);
  height: min(660px, calc(100dvh - clamp(36px, 6vh, 56px)));
  min-height: 0;
  grid-template-columns: minmax(340px, .9fr) minmax(470px, 1.1fr);
}

body.auth-mode-native .auth-context {
  position: relative;
  min-height: 0;
  padding: clamp(30px, 4vw, 46px);
  overflow: hidden;
}

body.auth-mode-native .auth-context::after {
  content: "";
  position: absolute;
  inset-inline-start: clamp(30px, 4vw, 46px);
  inset-block-end: 0;
  width: 72px;
  height: 4px;
  border-radius: 4px 4px 0 0;
  background: var(--gosi-green);
}

body.auth-mode-native .auth-brand { padding-bottom: 24px; }
body.auth-mode-native .auth-context-copy { margin: auto 0; padding: 34px 0; }
body.auth-mode-native .auth-context h1 {
  margin: 11px 0 15px;
  font-size: clamp(2.1rem, 4vw, 3.35rem);
}

body.auth-mode-native .auth-card {
  height: 100%;
  min-height: 0;
  justify-content: center;
  padding: 62px clamp(38px, 5vw, 58px) 24px;
}

body.auth-mode-native .auth-card::before {
  content: "";
  position: absolute;
  inset-block-start: 0;
  inset-inline: 0;
  height: 3px;
  background: var(--gosi-green);
}

body.auth-mode-native .auth-card-tools {
  inset-block-start: 22px;
  inset-inline: clamp(30px, 4vw, 46px);
}

body.auth-mode-native .auth-view {
  width: min(430px, 100%);
  flex: 0 1 auto;
  margin: auto;
  padding: 0;
}

body.auth-mode-native .auth-native-panel { width: 100%; }
body.auth-mode-native .auth-view-heading { display: block; margin-bottom: 24px; }
body.auth-mode-native .auth-view-heading h2 { margin: 7px 0 8px; font-size: clamp(1.7rem, 3vw, 2.15rem); }
body.auth-mode-native .auth-view-heading p { display: block; max-width: 42ch; font-size: .8125rem; line-height: 1.6; }

.auth-form { display: grid; gap: 17px; }
.auth-field { display: grid; gap: 7px; text-align: start; }
.auth-field label {
  color: var(--gosi-ink);
  font-size: .75rem;
  font-weight: 800;
}
.auth-field small { color: var(--gosi-muted); font-size: .625rem; line-height: 1.4; }

.auth-input-wrap { position: relative; }
.auth-input-wrap > .icon {
  position: absolute;
  z-index: 1;
  inset-block-start: 50%;
  inset-inline-start: 16px;
  width: 18px;
  height: 18px;
  color: var(--gosi-muted);
  transform: translateY(-50%);
  pointer-events: none;
}
.auth-input-wrap input {
  min-height: 50px;
  padding: 12px 48px;
  border-color: var(--gosi-line);
  border-radius: 8px;
  color: var(--gosi-ink);
  background: var(--gosi-card);
  font-size: .875rem;
  transition: border-color 150ms ease, box-shadow 150ms ease, background 150ms ease;
}
.auth-input-wrap input:hover { border-color: var(--gosi-muted); }
.auth-input-wrap input:focus {
  border-color: var(--gosi-navy);
  outline: 0;
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.auth-input-wrap:focus-within > .icon { color: var(--gosi-navy); }
.auth-input-wrap input[aria-invalid="true"] { border-color: var(--st-busy); }
.auth-input-wrap input[aria-invalid="true"]:focus { box-shadow: 0 0 0 3px var(--accent-soft); }
.auth-input-wrap input:disabled { cursor: wait; color: var(--gosi-muted); background: var(--gosi-canvas); opacity: 1; }

.auth-password-toggle {
  position: absolute;
  z-index: 2;
  inset-block: 3px;
  inset-inline-end: 3px;
  width: 44px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 6px;
  color: var(--gosi-muted);
  background: transparent;
}
.auth-password-toggle:hover { color: var(--gosi-navy); background: var(--accent-soft); }
.auth-password-toggle .icon { width: 18px; height: 18px; }
.auth-password-toggle .auth-eye-off { display: none; }
.auth-password-toggle[aria-pressed="true"] .auth-eye-on { display: none; }
.auth-password-toggle[aria-pressed="true"] .auth-eye-off { display: block; }

.auth-submit-button {
  width: 100%;
  min-height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 2px;
  padding: 11px 18px;
  border: 1px solid var(--gosi-navy);
  border-radius: 8px;
  color: var(--gosi-card);
  background: var(--gosi-navy);
  font-size: .8125rem;
  font-weight: 800;
  transition: background 150ms ease, transform 150ms ease;
}
.auth-submit-button:hover:not(:disabled) { background: var(--gosi-navy-soft); }
.auth-submit-button:active:not(:disabled) { transform: translateY(1px); }
.auth-submit-button:disabled { cursor: wait; opacity: 1; }
.auth-submit-busy { display: none; align-items: center; justify-content: center; gap: 10px; }
.auth-submit-busy i {
  width: 17px;
  height: 17px;
  border: 2px solid var(--gosi-card);
  border-top-color: var(--gosi-green);
  border-radius: 50%;
  animation: auth-spin 700ms linear infinite;
}
.auth-form[data-state="submitting"] .auth-submit-idle { display: none; }
.auth-form[data-state="submitting"] .auth-submit-busy { display: flex; }

.auth-credential-status {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 12px 13px;
  border: 1px solid var(--st-busy);
  border-inline-start-width: 3px;
  border-radius: 8px;
  color: var(--gosi-ink);
  background: var(--gosi-card);
  text-align: start;
}
.auth-credential-status > .icon { width: 18px; height: 18px; margin-top: 1px; color: var(--st-busy); }
.auth-credential-status div { display: flex; flex-direction: column; gap: 2px; }
.auth-credential-status strong { color: var(--st-busy); font-size: .75rem; }
.auth-credential-status span { color: var(--gosi-muted); font-size: .6875rem; line-height: 1.45; }

body.auth-mode-native .auth-notice { margin-bottom: 16px; }
body.auth-mode-native .auth-form-owner {
  margin-top: 19px !important;
  color: var(--gosi-muted);
  font-size: .625rem !important;
}
body.auth-mode-native .auth-form-owner strong { color: var(--gosi-navy); font-weight: 700; }

body.auth-mode-native.auth-success .auth-state-icon {
  color: var(--gosi-green-deep);
  border-color: var(--gosi-green-light);
  background: var(--gosi-green-light);
}
body.auth-mode-native.auth-success .auth-state-icon .icon { animation: none; }
body.auth-mode-native .auth-primary-button { border-color: var(--gosi-navy); color: var(--gosi-card); background: var(--gosi-navy); }
body.auth-mode-native .auth-primary-button:hover { background: var(--gosi-navy-soft); }

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

@media (max-height: 740px) and (min-width: 761px) {
  body.auth-mode-native .auth-context-copy { padding: 22px 0; }
  body.auth-mode-native .auth-context h1 { font-size: 2.35rem; }
  body.auth-mode-native .auth-card { padding-top: 54px; padding-bottom: 16px; }
  body.auth-mode-native .auth-card-tools { inset-block-start: 14px; }
  body.auth-mode-native .auth-view-heading { display: block; margin-bottom: 16px; }
  body.auth-mode-native .auth-view-heading h2 { margin-block: 5px; font-size: 1.7rem; }
  body.auth-mode-native .auth-view-heading p { display: block; line-height: 1.45; }
  body.auth-mode-native .auth-form { gap: 12px; }
  body.auth-mode-native .auth-field { gap: 5px; }
  body.auth-mode-native .auth-field small { display: none; }
  body.auth-mode-native .auth-input-wrap input,
  body.auth-mode-native .auth-submit-button { min-height: 46px; }
  body.auth-mode-native .auth-form-owner { margin-top: 11px !important; }
}

@media (max-width: 760px) {
  body.auth-mode-native .auth-shell { padding: 0; }
  body.auth-mode-native .auth-frame {
    width: 100%;
    height: 100dvh;
    grid-template-columns: 1fr;
    grid-template-rows: auto minmax(0, 1fr);
    border: 0;
    border-radius: 0;
  }
  body.auth-mode-native .auth-context { padding: 16px 22px; }
  body.auth-mode-native .auth-brand { padding: 0; border: 0; }
  body.auth-mode-native .auth-brand img { width: 92px; height: 44px; }
  body.auth-mode-native .auth-context-copy,
  body.auth-mode-native .auth-assurance { display: none; }
  body.auth-mode-native .auth-context::after { display: none; }
  body.auth-mode-native .auth-card { padding: 58px 24px 18px; overflow-y: auto; }
  body.auth-mode-native .auth-card-tools { inset-block-start: 14px; inset-inline: 22px; }
  body.auth-mode-native .auth-view-heading { display: block; margin-bottom: 18px; }
  body.auth-mode-native .auth-view-heading p { display: block; }
}

@media (max-width: 430px) {
  body.auth-mode-native .auth-context { padding-inline: 16px; }
  body.auth-mode-native .auth-tenant-label { font-size: .5625rem; }
  body.auth-mode-native .auth-tenant { max-width: 170px; font-size: .625rem; }
  body.auth-mode-native .auth-card { padding-inline: 18px; }
  body.auth-mode-native .auth-card-tools { inset-inline: 18px; }
  body.auth-mode-native .auth-view-heading h2 { font-size: 1.55rem; }
}

/* BP-owned sign-in: make the embedded frame seamless -----------------------
   Bright Pattern must render the form itself (only its own UI can offer the "force login"
   confirmation when an account is already signed in elsewhere). Since we cannot restyle
   what is inside the iframe, at least remove the seam around it so it reads as one page
   rather than a third-party widget sitting in a card. */
body.auth-awaiting #bpMount,
.auth-mount-slot {
  border: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  background: var(--gosi-card);
}
