.chat-page {
    display: flex;
    flex-direction: column;
    align-items: center;
    height: calc(100vh - 60px);
    overflow: hidden;
}

.chat-page h1 {
    background-color: #004080;
    color: white;
    padding: 20px;
    width: 100%;
    text-align: center;
    margin: 0;
    box-sizing: border-box;
}

h1 {
    background-color: #004080;
    color: white;
    padding: 20px;
    width: 100%;
    text-align: center;
    margin: 0;
    box-sizing: border-box;
}

#chatbox {
    flex: 1;
    overflow-y: auto;
    padding: 10px;
    width: 100%;
    max-width: 700px;
    background: white;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    gap: 10px;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    margin-top: 10px;
    margin-bottom: 10px;
}

.message {
    padding: 10px;
    border-radius: 10px;
    max-width: 80%;
    position: relative;
    word-wrap: break-word;
}

.user {
    background-color: #e0f7fa;
    align-self: flex-end;
    animation: fadeInRight 0.3s ease-in-out;
}

.bot {
    background-color: #e8eaf6;
    align-self: flex-start;
    animation: fadeInLeft 0.3s ease-in-out;
}

.typing {
    font-style: italic;
    color: #555;
    align-self: flex-start;
    animation: blink 1s infinite;
}

.read-receipt {
    font-size: 12px;
    color: #007aff;
    margin-left: 5px;
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes blink {
    0% {
        opacity: 0.2;
    }

    50% {
        opacity: 1;
    }

    100% {
        opacity: 0.2;
    }
}

#inputArea {
    /* Removido: position: fixed; */
    background-color: #f4f4f4;
    z-index: 100;
    display: flex;
    padding: 10px;
    box-sizing: border-box;
    width: 100%;
    max-width: 700px;
    margin: 0 auto;
    position: sticky;
    bottom: 0;
    border-top: 1px solid #ccc;
}

#userInput {
    flex-grow: 1;
    padding: 10px;
    font-size: 16px;
    border-radius: 5px;
    border: 1px solid #ccc;
    box-sizing: border-box;
}

#sendButton {
    padding: 10px 20px;
    margin-left: 10px;
    background-color: #004080;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

@media (max-width: 600px) {

    #chatbox,
    #inputArea {
        width: 95%;
        padding: 8;
    }

    #chatbox{
        height: 80hv;
    }

    #sendButton {
        padding: 8px;
        margin-left: 5px;
    }

    #userInput {
        font-size: 14px;
        padding: 6px;
    }
}