.container {
    width: 100%;
    max-width: 100%;
    height: 96vh;
    border: 1px solid #d0d0d0;
    display: flex;
    background: #ffffff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
    overflow: hidden;
}

.sidebar {
    width: 260px;
    border-right: 1px solid #e8e8e8;
    display: flex;
    flex-direction: column;
    background: #fafafa;
    transition: margin-left 0.3s ease;
    flex-shrink: 0;
    overflow: hidden;
}

.sidebar.collapsed {
    margin-left: -260px;
}

.sidebar-header {
    padding: 16px;
    border-bottom: 1px solid #e8e8e8;
    display: flex;
    justify-content: space-between;
    align-items: stretch;
    gap: 10px;
}

.chat-list {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
}

.sidebar-footer {
    padding: 16px;
    border-top: 1px solid #e8e8e8;
    display: flex;
    gap: 8px;
}

.sidebar-footer .btn {
    flex: 1;
}

.main-area {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.chat-header {
    padding: 16px 20px;
    border-bottom: 1px solid #e8e8e8;
    background: #ffffff;
    display: flex;
    justify-content: space-between;
    align-items: stretch;
    gap: 12px;
}

.header-left {
    display: flex;
    align-items: stretch;
    gap: 10px;
    flex: 1;
    min-width: 0;
}

.header-actions {
    display: flex;
    gap: 8px;
    align-items: stretch;
    flex-wrap: nowrap;
}

.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 24px 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    background: #fafafa;
}

.chat-input-container {
    padding: 16px 20px;
    border-top: 1px solid #e8e8e8;
    display: flex;
    gap: 10px;
    background: #ffffff;
    align-items: stretch;
}

@media (max-width: 768px) {
    body {
        padding: 0;
    }
    
    .container {
        height: 100vh;
        max-width: 100%;
        border: none;
        box-shadow: none;
    }

    .sidebar {
        position: fixed;
        left: 0;
        top: 0;
        height: 100%;
        z-index: 100;
        box-shadow: 2px 0 8px rgba(0, 0, 0, 0.1);
    }

    .sidebar.collapsed {
        margin-left: -260px;
    }

    .chat-name-input {
        font-size: 11px;
    }

    .header-actions {
        flex-wrap: wrap;
    }

    .btn {
        font-size: 10px;
        padding: 0 10px;
        height: 32px;
    }
    
    .badge {
        font-size: 10px;
        padding: 0 10px;
        height: 32px;
    }
    
    .input {
        height: 32px;
        line-height: 32px;
    }
    
    .chat-name-input {
        height: 32px;
        line-height: 32px;
    }
    
    #messageInput {
        height: 32px;
        min-height: 32px;
        padding: 6px 12px;
    }
}
