﻿.chat-container {
    max-width: 800px;
    margin: 0 auto;
    height: 90vh;
    display: flex;
    flex-direction: column;
}

.login-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
}

    .login-container h2 {
        margin-bottom: 30px;
        color: #333;
    }

.input-group {
    display: flex;
    gap: 10px;
    width: 100%;
    max-width: 400px;
}

.input-field {
    flex: 1;
    padding: 12px 16px;
    border: 2px solid #ddd;
    border-radius: 25px;
    font-size: 14px;
    outline: none;
    transition: border-color 0.3s;
}

    .input-field:focus {
        border-color: #007bff;
    }

.btn-primary {
    padding: 12px 30px;
    background: #007bff;
    color: white;
    border: none;
    border-radius: 25px;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.3s;
}

    .btn-primary:hover {
        background: #0056b3;
    }

.chat-layout {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    overflow: hidden;
}

.chat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background: #f8f9fa;
    border-bottom: 1px solid #e9ecef;
}

    .chat-header h3 {
        margin: 0;
        color: #333;
    }

.user-badge {
    background: #007bff;
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 12px;
}

.chat-messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    background: #f8f9fa;
    display:flex;
    flex-direction:column;
}

.message-wrapper {
    margin-bottom: 10px;
}

.message {
    max-width: 70%;
    padding: 10px 15px;
    border-radius: 12px;
    display: inline-block;
}

.own-message {
    background: #007bff;
    color: white;
    float: right;
}

.other-message {
    background: white;
    color: #333;
    float: left;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.message-header {
    display: flex;
    justify-content: space-between;
    gap: 15px;
    font-size: 12px;
    margin-bottom: 4px;
}

.own-message .message-header {
    color: rgba(255,255,255,0.8);
}

.other-message .message-header {
    color: #6c757d;
}

.timestamp {
    font-size: 10px;
}

.message-body {
    word-wrap: break-word;
    font-size: 14px;
}

.chat-input {
    display: flex;
    padding: 15px 20px;
    background: white;
    border-top: 1px solid #e9ecef;
    gap: 10px;
}

    .chat-input .input-field {
        flex: 1;
    }

#scroll-anchor {
    float: left;
    clear: both;
}
