/* -----------------------------------------------------------------------
   Layout
   ----------------------------------------------------------------------- */
body {
    overflow: hidden;
}

.chat-shell {
    background: #f8f9fa;
}

/* -----------------------------------------------------------------------
   Sidebar
   ----------------------------------------------------------------------- */
.sidebar {
    background: #fff;
}

.conv-item {
    cursor: pointer;
    transition: background 0.1s;
}

.conv-item:hover {
    background: #f0f4ff;
}

.conv-item.active {
    background: #e8eeff;
    border-left: 3px solid #0d6efd;
}

/* Status badges */
.conv-badge {
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    white-space: nowrap;
}

.conv-badge-available { background-color: #198754; color: #fff; }
.conv-badge-assigned  { background-color: #0d6efd; color: #fff; }
.conv-badge-closed    { background-color: #6c757d; color: #fff; }

/* -----------------------------------------------------------------------
   Chat panel
   ----------------------------------------------------------------------- */
.chat-panel {
    background: #f8f9fa;
}

.chat-header {
    border-bottom: 1px solid #dee2e6;
    box-shadow: 0 1px 3px rgba(0,0,0,.04);
}

/* -----------------------------------------------------------------------
   Messages
   ----------------------------------------------------------------------- */
.messages-area {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.message-bubble {
    max-width: 70%;
    padding: 8px 12px;
    border-radius: 12px;
    font-size: 0.9rem;
    line-height: 1.45;
    word-break: break-word;
}

.bubble-bot {
    background: #fff;
    border: 1px solid #dee2e6;
    border-bottom-left-radius: 3px;
}

.bubble-agent {
    background: #0d6efd;
    color: #fff;
    border-bottom-right-radius: 3px;
}

.bubble-system {
    background: #fff3cd;
    border: 1px solid #ffc107;
    font-style: italic;
    font-size: 0.82rem;
}

.bubble-sender {
    font-size: 0.72rem;
    font-weight: 600;
    margin-bottom: 2px;
    opacity: 0.7;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.bubble-time {
    font-size: 0.68rem;
    margin-top: 3px;
    opacity: 0.55;
    text-align: right;
}

/* -----------------------------------------------------------------------
   Input area
   ----------------------------------------------------------------------- */
.chat-input textarea {
    font-size: 0.9rem;
}

/* -----------------------------------------------------------------------
   Misc
   ----------------------------------------------------------------------- */
.cursor-pointer { cursor: pointer; }

#toastContainer {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 1100;
    min-width: 280px;
}
