.shell {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  background: #0d1117;
  overflow: hidden;
}

.toolbar {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 10px 12px;
  border-bottom: 1px solid #30363d;
  background: #161b22;
  color: #c9d1d9;
}

.toolbarTop {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.statusLine {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  font-size: 12px;
}

.statusText {
  color: #c9d1d9;
}

.statusDot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #6e7681;
  flex-shrink: 0;
}

.statusDot.connecting {
  background: #d29922;
}

.statusDot.connected {
  background: #3fb950;
}

.statusDot.error {
  background: #f85149;
}

.reconnectBtn {
  height: 30px;
  padding: 0 12px;
  border: 1px solid #30363d;
  border-radius: 6px;
  background: #21262d;
  color: #c9d1d9;
  font-size: 12px;
  cursor: pointer;
  flex-shrink: 0;
}

.reconnectBtn:hover:not(:disabled) {
  background: #30363d;
}

.reconnectBtn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.terminalHost {
  position: relative;
  flex: 1 1 auto;
  min-height: 260px;
  overflow: hidden;
  background: #0d1117;
}

.terminalHost :global(.xterm) {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  padding: 10px 12px;
  box-sizing: border-box;
}

.terminalHost :global(.xterm-viewport) {
  overflow-y: auto !important;
  overflow-x: hidden !important;
  width: 100% !important;
}

.terminalHost :global(.xterm-screen) {
  width: 100% !important;
}

.terminalHost :global(.xterm-rows) {
  width: 100% !important;
}

.terminalHost :global(.xterm-helper-textarea) {
  position: absolute;
  opacity: 0;
  left: 0;
  top: 0;
  width: 0;
  height: 0;
  z-index: -1;
}

@media (max-width: 768px) {
  .toolbar {
    padding: 8px 10px;
  }

  .terminalHost {
    min-height: min(360px, calc(var(--app-height) - 220px));
  }

  .terminalHost :global(.xterm) {
    padding: 8px 10px;
  }
}
