#telephony-sip-softphone {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 99980;
  font-family: var(--font-stack, "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif);
  touch-action: none;
  /* Try to follow the active Frappe theme where possible. */
  --tp-primary: #16a34a; /* HARDCODED Velo brand green — do not inherit page theme (was resolving black on portal) */
  --tp-primary-alt: #2563eb; /* HARDCODED Velo brand blue accent */
  --tp-surface: var(--card-bg, #ffffff);
  --tp-surface-muted: var(--control-bg, #f3f4f6);
  --tp-border-subtle: var(--border-color, rgba(148, 163, 184, 0.3));
  --tp-text: var(--text-color, #111827);
  --tp-muted: var(--text-muted, #6b7280);
  --tp-success: var(--success, #22c55e);
  --tp-danger: var(--danger, #ef4444);
  --tp-secondary: var(--secondary, rgba(148, 163, 184, 0.15));
  --tp-disabled-bg: var(--disabled-control-bg, #e5e7eb);
  --tp-keypad-bg: var(--control-bg-on-gray, var(--control-bg, #f1f5f9));
  --tp-keypad-danger-bg: #fee2e2;
}
[data-theme="dark"] #telephony-sip-softphone {
  --tp-surface: var(--surface-cards, var(--card-bg, #1c1c1c));
  --tp-surface-muted: var(--surface-gray-2, #2b2b2b);
  --tp-border-subtle: var(--outline-gray-3, #424242);
  --tp-text: var(--ink-gray-9, #f8f8f8);
  --tp-muted: var(--ink-gray-5, #808080);
  --tp-disabled-bg: var(--surface-gray-2, #2b2b2b);
  --tp-keypad-bg: var(--surface-gray-2, #2b2b2b);
}
#telephony-sip-softphone .tp-softphone-toggle {
  width: 48px;
  height: 48px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: row;
  gap: 0;
  border: none;
  /* HARDCODED brand gradient — NEVER inherit page/portal theme (was rendering black) */
  background: linear-gradient(145deg, #26d366, #12a150) !important;
  color: #fff !important;
  box-shadow: 0 8px 20px -6px rgba(18, 161, 80, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.28) !important;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
#telephony-sip-softphone .tp-softphone-toggle:hover {
  transform: translateY(-2px);
}
/* Hardcoded — same brand color in dark mode too, no theme-dependent black fallback */
[data-theme="dark"] #telephony-sip-softphone .tp-softphone-toggle {
  background: linear-gradient(145deg, #26d366, #12a150) !important;
  color: #fff !important;
}
#telephony-sip-softphone .tp-softphone-toggle-main,
#telephony-sip-softphone .tp-softphone-toggle-inline-btn {
  border: none;
  background: transparent;
  color: inherit;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  cursor: pointer;
}
#telephony-sip-softphone .tp-softphone-toggle-main {
  width: 32px;
  height: 32px;
  border-radius: 999px;
}
#telephony-sip-softphone .tp-softphone-toggle-inline-controls {
  display: none;
  align-items: center;
  gap: 4px;
  margin-left: 6px;
}
#telephony-sip-softphone .tp-softphone-toggle-inline-btn {
  width: 32px;
  height: 32px;
  border-radius: 999px;
  font-size: 16px;
  background: transparent;
  border: none;
  padding: 0;
}
#telephony-sip-softphone .tp-softphone-toggle.tp-softphone-toggle-active {
  width: auto;
  height: 48px;
  padding: 0 12px;
  border-radius: 999px;
  justify-content: flex-start;
  gap: 8px;
}
#telephony-sip-softphone .tp-softphone-toggle.tp-softphone-toggle-active .tp-softphone-toggle-inline-controls {
  display: inline-flex;
}
#telephony-sip-softphone .tp-softphone-toggle-icon {
  display: block;
  line-height: 1;
}
#telephony-sip-softphone .tp-softphone-toggle-timer {
  display: none;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  font-weight: 600;
  color: #ffffff;
}
#telephony-sip-softphone .tp-softphone-toggle.tp-softphone-toggle-active .tp-softphone-toggle-timer {
  display: inline-block;
}
#telephony-sip-softphone .tp-softphone-inline-icon {
  width: 20px;
  height: 20px;
  display: inline-block;
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
}
#telephony-sip-softphone .tp-softphone-inline-mic {
  background-image: url("/assets/telephony/softphone_media/mic_on.svg");
}
#telephony-sip-softphone.tp-softphone-muted .tp-softphone-inline-mic {
  background-image: url("/assets/telephony/softphone_media/mic_off.svg");
}
#telephony-sip-softphone .tp-softphone-inline-hangup {
  background-image: url("/assets/telephony/softphone_media/hangup_icon.svg");
}
#telephony-sip-softphone .tp-softphone-toggle-inline-btn.tp-softphone-hangup {
  background-color: #e53935 !important;
  border-radius: 999px;
}
#telephony-sip-softphone .tp-softphone-toggle-inline-btn.tp-softphone-hangup:hover {
  background-color: #c62828 !important;
}
#telephony-sip-softphone .tp-softphone-panel {
  position: absolute;
  bottom: 72px;
  right: 0;
  width: ${BASE_PANEL_WIDTH  min-width: 320px;
  min-height: auto;
  background: linear-gradient(160deg, #141821, #1d2330);
  border-radius: 20px;
  border: 1px solid rgba(255,255,255,0.08);
  box-shadow: 0 24px 60px -12px rgba(0,0,0,0.65);
  color: #e8ecf4;
  font-family: "Inter", system-ui, -apple-system, sans-serif;
}px;
  height: ${BASE_PANEL_HEIGHT}px;
  max-width: 90vw;
  max-height: 90vh;
  background: var(--tp-surface);
  border-radius: 18px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.6);
  color: var(--tp-text);
  backdrop-filter: blur(14px);
  box-sizing: border-box;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translateX(110%);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.25s ease, opacity 0.25s ease;
}
#telephony-sip-softphone .tp-softphone-panel.tp-open {
  transform: translateX(0%);
  opacity: 1;
  pointer-events: auto;
}
#telephony-sip-softphone .tp-softphone-content {
  width: ${BASE_PANEL_WIDTH}px;
  height: ${BASE_PANEL_HEIGHT}px;
  flex: 0 0 auto;
  transform-origin: center center;
}
#telephony-sip-softphone .tp-softphone-inner {
  box-sizing: border-box;
  padding: 16px 4px;
  height: 100%;
  display: grid;
  flex-direction: column;
}
#telephony-sip-softphone .tp-softphone-header {
  display: flex;
  justify-content: space-between;
  padding: 0 0 8px;
  gap: 12px;
  cursor: grab;
}
#telephony-sip-softphone .tp-softphone-title {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 2px;
}
#telephony-sip-softphone .tp-softphone-status {
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--tp-muted);
  text-transform: uppercase;
  font-size: 11px;
  letter-spacing: 0.08em;
  display: flex;
  align-items: center;
  gap: 6px;
}
#telephony-sip-softphone .tp-softphone-status::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #f59e0b;
  flex-shrink: 0;
}
#telephony-sip-softphone.tp-softphone-registered .tp-softphone-status::before { background: #26d366; }
#telephony-sip-softphone.tp-softphone-connecting .tp-softphone-status::before { background: #f59e0b; }
#telephony-sip-softphone.tp-softphone-failed .tp-softphone-status::before { background: #ef4444; }
#telephony-sip-softphone .tp-softphone-build {
  font-size: 10px;
  letter-spacing: 0.04em;
  color: var(--tp-muted);
  opacity: 0.75;
  margin-top: 2px;
  user-select: text;
}
#telephony-sip-softphone .tp-softphone-close {
  background: rgba(255, 255, 255, 0.08);
  border: none;
  color: var(--tp-muted);
  border-radius: 999px;
  width: 32px;
  height: 32px;
  font-size: 18px;
  cursor: pointer;
  align-self: flex-start;
}
#telephony-sip-softphone .tp-softphone-header-actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: flex-end;
}
#telephony-sip-softphone .tp-softphone-diagnostics {
  background: rgba(255, 255, 255, 0.08);
  border: none;
  color: var(--tp-muted);
  border-radius: 999px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  width: 32px;
  height: 32px;
}
#telephony-sip-softphone .tp-softphone-diagnostics-panel {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.5);
  backdrop-filter: blur(2px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 14px;
  box-sizing: border-box;
  z-index: 10;
  touch-action: auto;
}
#telephony-sip-softphone.tp-softphone-diagnostics-open .tp-softphone-diagnostics-panel {
  display: flex;
}
#telephony-sip-softphone .tp-softphone-diagnostics-card {
  width: 100%;
  max-width: 420px;
  background: var(--tp-surface);
  border-radius: 14px;
  border: 1px solid var(--tp-border-subtle);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.55);
  overflow: hidden;
}
#telephony-sip-softphone .tp-softphone-diagnostics-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  background: var(--tp-surface-muted);
  border-bottom: 1px solid var(--tp-border-subtle);
}
#telephony-sip-softphone .tp-softphone-diagnostics-title {
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--tp-muted);
  font-weight: 700;
}
#telephony-sip-softphone .tp-softphone-diagnostics-close {
  background: rgba(255, 255, 255, 0.08);
  border: none;
  color: var(--tp-muted);
  border-radius: 999px;
  width: 28px;
  height: 28px;
  font-size: 16px;
  cursor: pointer;
}
#telephony-sip-softphone .tp-softphone-diagnostics-body {
  padding: 12px;
}
#telephony-sip-softphone .tp-softphone-diagnostics-json {
  margin: 0;
  padding: 0;
  max-height: 55vh;
  overflow: auto;
  font-size: 11px;
  line-height: 1.35;
  color: var(--tp-text);
  white-space: pre-wrap;
  word-break: break-word;
  user-select: text;
  touch-action: auto;
}
#telephony-sip-softphone .tp-softphone-display {
  padding: 0 0 8px;
}
#telephony-sip-softphone .tp-softphone-remote-value {
  animation: none;
}
#telephony-sip-softphone .tp-softphone-status-text:contains("incoming"),
#telephony-sip-softphone .tp-softphone-status-text:contains("Incoming") {
  color: #22c55e;
  font-weight: bold;
}
#telephony-sip-softphone .tp-softphone-remote-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--tp-muted);
  margin-bottom: 2px;
}
#telephony-sip-softphone .tp-softphone-remote-value {
  font-weight: 600;
  font-size: 16px;
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
#telephony-sip-softphone .tp-softphone-timer {
  font-size: 16px;
  font-weight: 600;
  color: var(--tp-text);
  margin: 2px 0 6px;
  text-align: right;
  font-variant-numeric: tabular-nums;
  display: block;
  width: fit-content;
  margin-left: auto;
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--tp-surface-muted);
  min-width: 68px; /* fits mm:ss and hh:mm:ss */
  visibility: hidden;
}
#telephony-sip-softphone .tp-softphone-btn-icon {
  width: 44px;
  height: 44px;
  display: inline-block;
  margin-right: 6px;
  background-repeat: no-repeat;
  background-position: center;
  background-size: 80%;
}
#telephony-sip-softphone .tp-softphone-btn-label {
  display: inline-block;
}
#telephony-sip-softphone .tp-softphone-answer-icon {
  background-image: url("/assets/telephony/softphone_media/call_answer_icon.svg");
}
#telephony-sip-softphone .tp-softphone-end-icon {
  background-image: url("/assets/telephony/softphone_media/hangup_icon.svg");
}
#telephony-sip-softphone .tp-softphone-mute-icon {
  background-image: url("/assets/telephony/softphone_media/mic_on.svg");
}
#telephony-sip-softphone.tp-softphone-muted .tp-softphone-mute-icon {
  background-image: url("/assets/telephony/softphone_media/mic_off.svg");
}
#telephony-sip-softphone .tp-softphone-hold-icon {
  background-image: url("/assets/telephony/softphone_media/hold_off.svg");
}
#telephony-sip-softphone.tp-softphone-held .tp-softphone-hold-icon {
  background-image: url("/assets/telephony/softphone_media/hold_on.svg");
}
#telephony-sip-softphone .tp-softphone-transfer-icon {
  background-image: url("/assets/telephony/softphone_media/transfer_off.svg");
}
#telephony-sip-softphone.tp-softphone-transferring .tp-softphone-transfer-icon {
  background-image: url("/assets/telephony/softphone_media/transfer_on.svg");
}
#telephony-sip-softphone .tp-softphone-attended-icon {
  background-image: url("/assets/telephony/softphone_media/attended_transfer_off.svg");
}
#telephony-sip-softphone.tp-softphone-attended .tp-softphone-attended-icon {
  background-image: url("/assets/telephony/softphone_media/attended_transfer_on.svg");
}
#telephony-sip-softphone .tp-softphone-transfer-back-icon {
  background-image: url("/assets/telephony/softphone_media/back_button.svg");
}
#telephony-sip-softphone .tp-softphone-swap-icon {
  background-image: url("/assets/telephony/softphone_media/swap_calls.svg");
}
#telephony-sip-softphone .tp-softphone-attended-icon {
  background-image: url("/assets/telephony/softphone_media/attended_transfer_off.svg");
}
#telephony-sip-softphone.tp-softphone-attended .tp-softphone-attended-icon {
  background-image: url("/assets/telephony/softphone_media/attended_transfer_on.svg");
}
#telephony-sip-softphone .tp-softphone-dialpad-icon {
  width: 44px;
  height: 44px;
  background-image: url("/assets/telephony/softphone_media/dialpad_icon_off.svg");
  background-size: 80%;
}
#telephony-sip-softphone.tp-softphone-keypad-visible .tp-softphone-dialpad-icon {
  background-image: url("/assets/telephony/softphone_media/dialpad_icon_on.svg");
}
#telephony-sip-softphone .tp-softphone-input-wrap {
  position: relative;
}
#telephony-sip-softphone .tp-softphone-dial-input {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--tp-border-subtle);
  background: var(--tp-surface-muted);
  color: var(--tp-text);
  padding: 8px 32px 8px 10px;
  font-size: 15px;
  outline: none;
}
#telephony-sip-softphone .tp-softphone-input-clear {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  border: none;
  background: transparent;
  color: var(--tp-muted);
  cursor: pointer;
  padding: 0;
  font-size: 16px;
  display: none;
}
#telephony-sip-softphone .tp-softphone-preflight {
  width: 100%;
  margin: 8px 0 12px;
  border: 1px solid var(--tp-border-subtle);
  background: transparent;
  color: var(--tp-muted);
  border-radius: 12px;
  padding: 8px 10px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
#telephony-sip-softphone .tp-softphone-preflight:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}
#telephony-sip-softphone .tp-softphone-actions {
  padding: 0 0 8px;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}
#telephony-sip-softphone .tp-softphone-btn {
  border: none;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}
#telephony-sip-softphone .tp-softphone-btn:not(.tp-softphone-icon-only) {
  border-radius: 12px;
  padding: 8px 4px;
}
#telephony-sip-softphone .tp-softphone-btn.primary {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: linear-gradient(135deg, #26d366, #12a150);
  box-shadow: 0 4px 20px rgba(38,211,102,0.35);
  border: none;
  color: #fff;
}
[data-theme="dark"] #telephony-sip-softphone .tp-softphone-btn.primary:not(:disabled):not(.tp-softphone-icon-only) {
  background: var(--surface-gray-3, #343434);
  color: var(--ink-gray-9, #f8f8f8);
}
#telephony-sip-softphone .tp-softphone-btn.success {
  background: var(--tp-success);
  color: #062216;
}
#telephony-sip-softphone .tp-softphone-btn.danger {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: linear-gradient(135deg, #ff5a5a, #d92020);
  box-shadow: 0 4px 20px rgba(255,90,90,0.35);
  border: none;
  color: #fff;
}
#telephony-sip-softphone .tp-softphone-btn.secondary {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  color: #e8ecf4;
}
#telephony-sip-softphone .tp-softphone-btn:disabled:not(.tp-softphone-icon-only) {
  opacity: 1;
  background: var(--tp-disabled-bg);
  color: var(--tp-muted);
  cursor: not-allowed;
}
#telephony-sip-softphone .tp-softphone-btn.tp-softphone-icon-only {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 60px;
  height: 60px;
  padding: 0;
  background: transparent;
  box-shadow: none;
  justify-self: center;
}
#telephony-sip-softphone .tp-softphone-btn.tp-softphone-icon-only .tp-softphone-btn-icon {
  margin-right: 0;
}
#telephony-sip-softphone .tp-softphone-btn.tp-softphone-icon-only .tp-softphone-btn-label {
  display: none;
}
#telephony-sip-softphone .tp-softphone-btn.tp-softphone-icon-only:disabled {
  background: transparent;
}
#telephony-sip-softphone .tp-softphone-btn.tp-softphone-highlight {
  /* When a call is ringing, animate the answer icon instead of
     drawing an outline box. */
}
#telephony-sip-softphone .tp-softphone-btn.tp-softphone-highlight .tp-softphone-btn-icon {
  animation: tp-softphone-answer-wiggle 0.6s ease-in-out infinite;
  transform-origin: 50% 50%;
}
@keyframes tp-softphone-answer-wiggle {
  0% {
    transform: rotate(0deg);
  }
  25% {
    transform: rotate(-10deg);
  }
  50% {
    transform: rotate(10deg);
  }
  75% {
    transform: rotate(-10deg);
  }
  100% {
    transform: rotate(0deg);
  }
}
#telephony-sip-softphone .tp-softphone-keypad {
  display: none;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 4px;
}
#telephony-sip-softphone.tp-softphone-keypad-visible .tp-softphone-keypad {
  display: grid;
}
#telephony-sip-softphone .tp-softphone-keypad button {
  border-radius: 12px;
  border: 1px solid var(--tp-border-subtle);
  padding: 8px 0;
  font-size: 17px;
  font-weight: 600;
  background: var(--tp-keypad-bg);
  color: var(--tp-text);
  cursor: pointer;
  transition: transform 0.1s ease;
}
#telephony-sip-softphone .tp-softphone-keypad button:active {
  transform: scale(0.97);
}
#telephony-sip-softphone .tp-softphone-keypad button[data-action="backspace"] {
  grid-column: span 3;
  background: #fee2e2;
  color: #b91c1c;
}

/* Modern theme: active toggle states */
#telephony-sip-softphone.tp-softphone-muted .tp-softphone-btn[data-action="mute"] {
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  color: #fff;
}
#telephony-sip-softphone.tp-softphone-held .tp-softphone-btn[data-action="hold"] {
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  color: #fff;
}
/* Drag handle pill affordance */
#telephony-sip-softphone .tp-softphone-header::before {
  content: "";
  display: block;
  width: 26px;
  height: 4px;
  border-radius: 2px;
  background: rgba(255,255,255,0.15);
  margin: 0 auto 8px;
}
/* Keypad modern styling */
#telephony-sip-softphone .tp-softphone-keypad button {
  border-radius: 12px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.06);
  color: #e8ecf4;
  transition: transform 0.1s ease;
}
#telephony-sip-softphone .tp-softphone-keypad button:active {
  transform: scale(0.94);
}
/* Hide build signature from main panel */
#telephony-sip-softphone .tp-softphone-build {
  display: none !important;
}
/* Incoming call card overlay */
#telephony-sip-softphone .tp-softphone-incoming-card {
  position: fixed;
  inset: 0;
  z-index: 99996;
  background: rgba(0,0,0,0.85);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 24px;
  backdrop-filter: blur(8px);
}
#telephony-sip-softphone .tp-softphone-incoming-card .tp-incoming-avatar {
  width: 96px; height: 96px; border-radius: 50%;
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  display: flex; align-items: center; justify-content: center;
  font-size: 36px; color: #fff; font-weight: 600;
}
#telephony-sip-softphone .tp-softphone-incoming-card .tp-incoming-name {
  font-size: 28px; font-weight: 600; color: #e8ecf4;
}
#telephony-sip-softphone .tp-softphone-incoming-card .tp-incoming-number {
  font-size: 16px; color: rgba(255,255,255,0.6);
}
#telephony-sip-softphone .tp-softphone-incoming-card .tp-incoming-actions {
  display: flex; gap: 32px; margin-top: 16px;
}
#telephony-sip-softphone .tp-softphone-incoming-card .tp-incoming-btn {
  width: 72px; height: 72px; border-radius: 50%;
  border: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  font-size: 28px; color: #fff;
  transition: transform 0.15s ease;
}
#telephony-sip-softphone .tp-softphone-incoming-card .tp-incoming-btn:active {
  transform: scale(0.92);
}
#telephony-sip-softphone .tp-softphone-incoming-card .tp-incoming-btn.tp-incoming-answer {
  background: linear-gradient(135deg, #26d366, #12a150);
  box-shadow: 0 4px 24px rgba(38,211,102,0.4);
}
#telephony-sip-softphone .tp-softphone-incoming-card .tp-incoming-btn.tp-incoming-decline {
  background: linear-gradient(135deg, #ff5a5a, #d92020);
  box-shadow: 0 4px 24px rgba(255,90,90,0.4);
}
#telephony-sip-softphone .tp-softphone-incoming-card .tp-incoming-label {
  font-size: 12px; color: rgba(255,255,255,0.5);
  text-align: center; margin-top: 4px;
}
/* Transfer sheet */
#telephony-sip-softphone .tp-softphone-transfer-sheet {
  position: fixed; inset: 0; z-index: 99996;
  background: rgba(0,0,0,0.85);
  display: flex; align-items: center; justify-content: center;
  backdrop-filter: blur(8px);
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-transfer-card {
  width: 360px; max-width: 90vw;
  background: linear-gradient(160deg, #141821, #1d2330);
  border-radius: 20px;
  border: 1px solid rgba(255,255,255,0.08);
  box-shadow: 0 24px 60px -12px rgba(0,0,0,0.65);
  color: #e8ecf4; padding: 24px;
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-transfer-title {
  font-size: 18px; font-weight: 600; margin-bottom: 16px;
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-transfer-search {
  width: 100%; padding: 10px 14px; border-radius: 12px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  color: #e8ecf4; font-size: 14px; margin-bottom: 12px;
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-transfer-list {
  max-height: 240px; overflow-y: auto; margin-bottom: 16px;
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-transfer-item {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 14px; border-radius: 10px; cursor: pointer;
  transition: background 0.15s;
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-transfer-item:hover {
  background: rgba(255,255,255,0.08);
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-transfer-item .tp-transfer-ext {
  width: 36px; height: 36px; border-radius: 50%;
  background: rgba(59,130,246,0.2);
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 600; color: #60a5fa;
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-transfer-item .tp-transfer-name {
  font-size: 14px;
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-transfer-actions {
  display: flex; gap: 12px;
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-transfer-btn {
  flex: 1; padding: 12px; border-radius: 12px; border: none;
  cursor: pointer; font-size: 14px; font-weight: 500;
  transition: transform 0.1s;
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-transfer-btn:active {
  transform: scale(0.96);
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-transfer-btn.tp-transfer-attended {
  background: linear-gradient(135deg, #3b82f6, #2563eb); color: #fff;
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-transfer-btn.tp-transfer-blind {
  background: rgba(255,255,255,0.08); color: #e8ecf4;
  border: 1px solid rgba(255,255,255,0.1);
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-transfer-btn.tp-transfer-cancel {
  background: rgba(255,90,90,0.15); color: #ff5a5a;
}
/* Attended transfer consult view */
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-consult-legs {
  margin-bottom: 16px;
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-consult-leg {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 14px; border-radius: 10px; margin-bottom: 8px;
  background: rgba(255,255,255,0.04);
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-consult-leg.on-hold {
  opacity: 0.5;
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-consult-leg .tp-leg-label {
  font-size: 12px; color: rgba(255,255,255,0.5);
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-consult-leg .tp-leg-name {
  font-size: 14px; font-weight: 500;
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-consult-leg .tp-leg-status {
  font-size: 11px; padding: 2px 8px; border-radius: 6px;
  background: rgba(255,255,255,0.08);
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-consult-actions {
  display: flex; gap: 8px;
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-consult-btn {
  flex: 1; padding: 10px; border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.06); color: #e8ecf4;
  cursor: pointer; font-size: 13px; transition: transform 0.1s;
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-consult-btn:active {
  transform: scale(0.95);
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-consult-btn.tp-consult-complete {
  background: linear-gradient(135deg, #26d366, #12a150); color: #fff; border: none;
}
#telephony-sip-softphone .tp-softphone-transfer-sheet .tp-consult-btn.tp-consult-cancel {
  background: rgba(255,90,90,0.15); color: #ff5a5a;
}
