body.online-connect-pilot .dp {
  display: flex;
  width: min(var(--details-panel-width, 320px), calc(100vw - 520px));
  max-width: calc(100vw - 520px);
  flex-basis: min(var(--details-panel-width, 320px), calc(100vw - 520px));
  opacity: 1;
  transform: translateX(0);
  transition:
    width 560ms cubic-bezier(.16, 1, .3, 1),
    flex-basis 560ms cubic-bezier(.16, 1, .3, 1),
    transform 560ms cubic-bezier(.16, 1, .3, 1),
    opacity 220ms ease-out;
  will-change: width, transform;
  contain: layout paint;
}

body.online-connect-pilot .dp.closed {
  display: flex;
  width: 0;
  flex-basis: 0;
  border-left-width: 0;
  opacity: 0;
  pointer-events: none;
  transform: translateX(100%);
}

body.online-connect-pilot .dp .dp-hd {
  display: flex !important;
  min-width: 0;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: blur(16px);
}

.dock-panels {
  display: flex;
  flex: 1 1 0;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  background: #fff;
}

.dock-profile-panel {
  width: var(--profile-panel-width, 320px);
  min-width: 260px;
  flex: 1 1 var(--profile-panel-width, 320px);
}

.details-resize-handle {
  z-index: 12;
  width: 8px;
  flex: 0 0 8px;
  position: relative;
  cursor: col-resize;
  background: transparent;
  outline: none;
  opacity: 1;
  transition: width 560ms cubic-bezier(.16, 1, .3, 1), flex-basis 560ms cubic-bezier(.16, 1, .3, 1), opacity 220ms ease-out;
}
.details-resize-handle::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: 3px;
  width: 1px;
  background: #e0e0e0;
  transition: background .12s, width .12s;
}
.details-resize-grip {
  position: absolute;
  top: 50%;
  left: 50%;
  display: flex;
  width: 25px;
  height: 30px;
  align-items: center;
  justify-content: center;
  gap: 2px;
  border: 1px solid #cbd5e1;
  border-radius: 999px;
  color: #475569;
  background: #fff;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -50%) scale(.96);
  transition: opacity .12s, transform .12s, border-color .12s;
  box-shadow: 0 8px 18px rgba(15, 23, 42, .16);
}
.details-resize-grip > span { width: 2px; height: 10px; border-radius: 2px; background: currentColor; }
.details-resize-handle:hover::before,
.details-resize-handle:focus-visible::before,
body.resizing-details .details-resize-handle::before { width: 2px; background: #8ec5ff; }
.details-resize-handle:hover .details-resize-grip,
.details-resize-handle:focus-visible .details-resize-grip,
body.resizing-details .details-resize-grip { opacity: 1; transform: translate(-50%, -50%) scale(1); }
.details-resize-handle:focus-visible .details-resize-grip { border-color: #1976d2; box-shadow: 0 0 0 3px rgba(25, 118, 210, .18), 0 8px 18px rgba(15, 23, 42, .16); }
body.resizing-details,
body.resizing-details * { cursor: col-resize !important; user-select: none !important; }
body.resizing-details .dp { transition: none !important; }
.details-resize-handle:has(+ .dp.closed) { width: 0; flex-basis: 0; opacity: 0; pointer-events: none; }

.dock-panel-resize {
  position: relative;
  z-index: 12;
  width: 0;
  flex: 0 0 0;
  overflow: visible;
  cursor: col-resize;
  opacity: 0;
  pointer-events: none;
  outline: none;
  background: transparent;
  transition:
    width 560ms cubic-bezier(.16, 1, .3, 1),
    flex-basis 560ms cubic-bezier(.16, 1, .3, 1),
    opacity 180ms ease-out;
}

.dock-panel-resize::before {
  content: '';
  position: absolute;
  inset: 0 auto 0 3px;
  width: 1px;
  background: #dce3ec;
  transition: width 140ms ease, background 140ms ease, box-shadow 140ms ease;
}

.dp.online-connect-open .dock-panel-resize-online,
.dp.support-mode-open .dock-panel-resize-support {
  width: 8px;
  flex-basis: 8px;
  opacity: 1;
  pointer-events: auto;
}

.dock-panel-resize:hover::before,
.dock-panel-resize:focus-visible::before,
body.resizing-details .dock-panel-resize::before {
  width: 2px;
  background: #5aa9ef;
  box-shadow: 0 0 0 3px rgba(25, 118, 210, .08);
}

.dock-panel-resize:hover .details-resize-grip,
.dock-panel-resize:focus-visible .details-resize-grip,
body.resizing-details .dock-panel-resize .details-resize-grip {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.online-connect-tabs {
  display: flex;
  align-items: center;
  gap: 4px;
  min-width: 0;
}

.online-connect-tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 30px;
  padding: 0 9px;
  border: 0;
  border-radius: 6px;
  color: #64748b;
  background: transparent;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.online-connect-tab:hover { background: #f1f5f9; color: #1f2937; }
.online-connect-tab.active {
  color: #0b63b6;
  background: #eaf4ff;
  box-shadow: inset 0 0 0 1px rgba(25, 118, 210, .08);
}
.online-connect-tab svg { width: 15px; height: 15px; stroke-width: 2; }

.online-connect-view {
  display: flex;
  flex: 0 0 0;
  width: 0;
  min-height: 0;
  min-width: 0;
  overflow: hidden;
  background: #f6f8fb;
  flex-direction: column;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateX(56px);
  transition:
    width 560ms cubic-bezier(.16, 1, .3, 1),
    flex-basis 560ms cubic-bezier(.16, 1, .3, 1),
    min-width 560ms cubic-bezier(.16, 1, .3, 1),
    transform 560ms cubic-bezier(.16, 1, .3, 1),
    opacity 180ms ease-out,
    visibility 0s linear 560ms;
  will-change: width, transform, opacity;
}

.dp.online-connect-open .online-connect-view {
  width: var(--online-panel-width, 360px);
  min-width: 260px;
  flex: 1 1 var(--online-panel-width, 360px);
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(0);
  transition-delay: 0s;
}

.support-mode-view {
  display: flex;
  position: relative;
  flex: 0 0 0;
  width: 0;
  min-height: 0;
  min-width: 0;
  overflow: hidden;
  background: #fff;
  isolation: isolate;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateX(64px);
  transition:
    width 600ms cubic-bezier(.16, 1, .3, 1),
    flex-basis 600ms cubic-bezier(.16, 1, .3, 1),
    min-width 600ms cubic-bezier(.16, 1, .3, 1),
    transform 600ms cubic-bezier(.16, 1, .3, 1),
    opacity 190ms ease-out,
    visibility 0s linear 600ms;
  will-change: width, transform, opacity;
}

.dp.support-mode-open .support-mode-view {
  width: var(--support-panel-width, 420px);
  min-width: 280px;
  flex: 1 1 var(--support-panel-width, 420px);
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(0);
  transition-delay: 0s;
}

.support-mode-frame {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  min-height: 0;
  border: 0;
  background: #fff;
  pointer-events: auto;
}

.support-mode-empty {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 24px;
  color: #64748b;
  background: #f8fafc;
  text-align: center;
  font-size: 12px;
  pointer-events: none;
}

.support-mode-empty[hidden] { display: none; }
.support-mode-empty strong { color: #172033; font-size: 14px; }

.online-connect-status {
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  padding: 8px 12px;
  border-bottom: 1px solid #e2e8f0;
  color: #64748b;
  background: #fff;
  font-size: 11px;
  font-weight: 700;
}

.online-connect-status-dot { width: 7px; height: 7px; border-radius: 50%; background: #94a3b8; }
.online-connect-status.live { color: #137a43; }
.online-connect-status.live .online-connect-status-dot { background: #22c55e; box-shadow: 0 0 0 3px #dcfce7; }
.online-connect-status.error { color: #b42318; }
.online-connect-status.error .online-connect-status-dot { background: #ef4444; }
.online-connect-status-text { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.online-connect-disconnect {
  margin-left: auto;
  height: 26px;
  padding: 0 10px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: #dc2626;
  font-size: 10px;
  font-weight: 800;
}
.online-connect-disconnect:hover { background: #b91c1c; }
.online-connect-disconnect[hidden] { display: none; }

.online-connect-stage { position: relative; flex: 1; min-height: 0; overflow: auto; background: #eef2f6; }
.online-connect-player { position: absolute; top: 0; left: 0; transform-origin: top left; }
.online-connect-player .rr-player { box-shadow: none !important; }

.online-connect-empty {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  gap: 6px;
  padding: 28px;
  color: #64748b;
  text-align: center;
}

.online-connect-empty strong { color: #1f2937; font-size: 14px; }
.online-connect-empty[hidden] { display: none; }

.online-connect-empty.ready {
  inset: 14px 12px auto;
  grid-template-columns: minmax(0, 1fr) auto;
  place-content: initial;
  align-items: center;
  gap: 4px 12px;
  min-height: 76px;
  padding: 14px 16px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  color: #168447;
  background: #fff;
  text-align: left;
  box-shadow: 0 3px 12px rgba(15, 23, 42, .06);
}
.online-connect-empty.ready strong { color: #111827; font-size: 15px; }
.online-connect-empty.ready > span { color: #168447; font-weight: 800; }
.online-connect-empty.ready .online-connect-action { grid-column: 2; grid-row: 1 / span 2; margin: 0; }

.online-connect-empty.offline {
  inset: 14px 12px auto;
  display: flex;
  place-content: initial;
  align-items: center;
  gap: 11px;
  min-height: 68px;
  padding: 13px 15px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #fff;
  text-align: left;
  box-shadow: 0 3px 12px rgba(15, 23, 42, .05);
}
.online-connect-offline-icon {
  display: grid;
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  place-items: center;
  border: 1px solid #cbd5e1;
  border-radius: 50%;
  color: #94a3b8;
  background: #f1f5f9;
  font-size: 24px;
  line-height: 1;
}
.online-connect-offline-copy { display: grid; gap: 2px; min-width: 0; }
.online-connect-offline-copy strong {
  overflow: hidden;
  color: #1f2937;
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.online-connect-offline-copy > span { color: #64748b; font-size: 12px; font-weight: 700; }

.online-connect-view[data-state="connecting"] .online-connect-status,
.online-connect-view[data-state="ended"] .online-connect-status { display: none; }
.online-connect-empty.connecting,
.online-connect-empty.ended {
  z-index: 3;
  gap: 14px;
  color: #fff;
  background: #090720;
}
.online-connect-empty.connecting strong,
.online-connect-empty.ended strong { color: #fff; font-size: 22px; font-weight: 650; }
.online-connect-empty.ended { gap: 24px; }
.online-connect-spinner {
  justify-self: center;
  width: 38px;
  height: 38px;
  border: 5px solid rgba(255, 255, 255, .25);
  border-top-color: #fff;
  border-radius: 50%;
  animation: online-connect-spin .8s linear infinite;
}
@keyframes online-connect-spin { to { transform: rotate(360deg); } }

@media (max-width: 1100px) {
  .details-resize-handle,
  .dock-panel-resize { display: none; }
  body.online-connect-pilot .dp {
    width: 100%;
    max-width: none;
    flex-basis: 100%;
  }
  .dock-profile-panel,
  .dp.online-connect-open .online-connect-view,
  .dp.support-mode-open .support-mode-view {
    width: 100%;
    min-width: 100%;
    flex: 0 0 100%;
  }
  .dp[data-last-panel="online"] .dock-profile-panel,
  .dp[data-last-panel="online"] .support-mode-view,
  .dp[data-last-panel="support"] .dock-profile-panel,
  .dp[data-last-panel="support"] .online-connect-view,
  .dp[data-last-panel="profile"] .online-connect-view,
  .dp[data-last-panel="profile"] .support-mode-view {
    display: none;
  }
}

.online-connect-action {
  justify-self: center;
  min-width: 112px;
  height: 34px;
  margin-top: 10px;
  padding: 0 18px;
  border: 1px solid #0b6ecb;
  border-radius: 6px;
  color: #fff;
  background: #1976d2;
  font-size: 12px;
  font-weight: 800;
  box-shadow: 0 4px 10px rgba(25, 118, 210, .18);
}

.online-connect-action:hover { background: #1268bd; }
.online-connect-action:focus-visible { outline: 3px solid rgba(25, 118, 210, .24); outline-offset: 2px; }
.online-connect-action.hangup {
  min-width: 86px;
  height: 52px;
  margin-top: 8px;
  border: 0;
  border-radius: 22px;
  background: #dc1f1f;
  font-size: 23px;
  line-height: 1;
}
.online-connect-action.hangup:hover { background: #bb1717; }
.online-connect-action.continue {
  min-width: 122px;
  height: 48px;
  border: 0;
  border-radius: 8px;
  background: #6652eb;
  font-size: 16px;
}
.online-connect-action.continue:hover { background: #5744d8; }

@media (max-width: 1100px) {
  body.online-connect-pilot .dp {
    width: min(var(--details-panel-width, 520px), 64vw);
    max-width: 64vw;
    flex-basis: min(var(--details-panel-width, 520px), 64vw);
  }
  body.online-connect-pilot .dp.closed {
    width: min(var(--details-panel-width, 520px), 64vw);
    transform: translateX(105%);
  }
  .dock-panel-resize { display: none; }
}

@media (max-width: 700px) {
  body.online-connect-pilot .dp,
  body.online-connect-pilot .dp.closed {
    width: auto;
    max-width: none;
    flex-basis: auto;
    transform: none;
    opacity: 1;
    border-left-width: 0;
  }
  body.online-connect-pilot .dp.closed { display: none; }
  body.online-connect-pilot .app.mobile-details-open .dp.closed {
    display: flex;
    pointer-events: auto;
  }
}
