<function_calls>
<invoke name="artifacts">
<parameter name="id">paper-chat-css</parameter>
<parameter name="type">application/vnd.ant.code</parameter>
<parameter name="title">Auto-scrolling Chat CSS</parameter>
<parameter name="content">

@import url('https://fonts.googleapis.com/css2?family=IM+Fell+English&display=swap');

.chat-container {
    max-width: 80%;
    margin: 20px 50px;
    padding: 15px;
    background: #F0EEE7;
    font-family: 'IM Fell English', Georgia, Cambria, "Times New Roman", Times, serif;
    font-size: 17px;
}

.chat-box {
    padding: 0px 30px;
    background: #F0EEE7;
    margin-bottom: 15px;
}

.chat-controls-wrapper {
    display: flex;
    gap: 10px;
    flex-direction: column;
    width: 100%;
    padding: 7px 30px;
}

.chat-input-container {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
}

.agent-config {
    width: 100%;
    padding: 15px 0;
    text-align: center;
}

.agent-info {
    font-family: 'IM Fell English', Georgia, Cambria, "Times New Roman", Times, serif;
    font-size: 12px;
}

#chat-input {
    flex: 1;
    padding: 12px;
    background: #fff;
    font-family: Inter, sans-serif;
    font-size: 17px;
    border: none;
    border-bottom: 2px solid transparent;
    transition: border-color 0.3s ease;
}

#chat-input:focus {
    outline: none;
    border-bottom-color: #4a4a4a;
}

#chat-input::placeholder {
    color: #666;
    opacity: 0;
    animation: blinkCursor 1s infinite;
}

@keyframes blinkCursor {
    0%, 100% { 
        opacity: 1;
        content: '|';
    }
    50% { 
        opacity: 0;
        content: '|';
    }
}

.send-button {
    padding: 12px 24px;
    background: #4a4a4a;
    color: #fff;
    border: none;
    cursor: pointer;
    font-weight: normal;
    min-width: 100px;
    font-family: Inter, sans-serif;
    font-size: 17px;
    transition: background 0.2s ease;
}

.send-button:hover {
    background: #333;
}

.control-buttons {
    display: flex;
    gap: 10px;
    width: 100%;
}

.control-button {
    flex: 1;
    padding: 12px 8px;
    background: #ffffff;
    color: #312e23;
    border-radius: 5px;
    border: solid 1px;
    border-color: #e1e1df;
    cursor: pointer;
    font-family: Inter, sans-serif;
    font-weight: normal;
    font-size: 13px;
    text-transform: uppercase;
    transition: background 0.2s ease;
}

.control-button:hover {
    background: #f7f6f1;
    color: #000;
    border-color: #5CCFBF;
}

.user-message, .ai-message {
    margin-bottom: 13px;
    padding: 7px 30px;
    max-width: 100%;
    position: relative;
    line-height: 1.6;
    font-size: 17px;
}

.user-message {
    color: #403e34;
    background-color: #e2e0d5;
    margin-left: auto;
    text-align: left;
    border-radius: 5px;
}

.ai-message {
    color: #403e34;
    background-color: #f7f6f1;
    margin-left: auto;
    text-align: left;
    border-radius: 5px;
}

/* Estilos para o textarea editável e botões */
.editable-response {
    width: 100%;
    background: transparent;
    border: none;
    font-family: inherit;
    font-size: inherit;
    color: inherit;
    line-height: inherit;
    resize: none;
    overflow: hidden;
    margin: 0;
    padding: 0;
    display: block;
}

.editable-response:focus {
    outline: none;
    border: none;
    box-shadow: none;
}

.button-container {
    display: flex;
    gap: 10px;
    margin-top: 18px;
}

.copy-button,
.save-button {
    padding: 8px 12px 8px 8px;
    border: none;
    cursor: pointer;
    font-size: 15px;
    opacity: 0.8;
    font-family: Inter, sans-serif;
    display: flex;
    align-items: center;
    gap: 5px;
    color: #000;
}

.copy-button {
    background: #5CCFBF;
}

.save-button {
    background: #1D2327;
    color: white;
    display: none;
}

.copy-button:hover,
.save-button:hover {
    opacity: 1;
}

.copy-button img,
.save-button img {
    margin-right: 5px;
}

.copied {
    background: #f8f8f8 !important;
}

.message-content {
    word-break: break-word;
    white-space: pre-wrap !important;
    display: block;
    padding: 20px 12px;
    line-height: 1.3; /* aumentado de 1.5 para dar mais espaço */
}

/* Estilos específicos para números */
.message-content br + :not(br) {
    display: block;
    margin-top: 0.5em;
}

/* Força quebra após números */
.message-content [class^="number-"] {
    display: block;
    margin-bottom: 0.5em;
}

/* Garante que todos os <br> sejam efetivos */
.message-content br {
    content: "";
    display: block;
    margin: 0.5em 0;
}

.message-content h3 {
    margin: 1em 0 0.5em 0;
    font-size: 24px;
}

.message-content ul,
.message-content ol {
    margin: 0.5em 0;
    padding-left: 2em;
    font-size: 17px;
}

.message-content li {
    margin: 0.3em 0;
}

.message-content p {
    margin: 0.5em 0;
    font-size: 17px;
}

#chat-input:disabled,
button:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.chat-input-container button:active {
    transform: scale(0.98);
}

/* Media Queries */
@media (max-width: 768px) {
    .control-buttons {
        flex-direction: column;
    }
    
    .control-button {
        width: 100%;
    }
}

@media (max-width: 640px) {
    #chat-container {
        margin: 10px;
    }

    .chat-input-container {
        flex-direction: column;
    }

    .chat-input-container button {
        width: 100%;
    }

    .user-message, .ai-message {
        max-width: 90%;
    }
}
</parameter>
<parameter name="language">css</parameter>
</invoke>