* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    background-color: #f5f5f5;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding-top: 20px;
}

#chat-container {
    width: 100%;
    max-width: 600px;
    background-color: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 80vh;
}

#chat-messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.message {
    max-width: 80%;
    word-wrap: break-word;
}

.message.user {
    align-self: flex-end;
    background-color: #007aff;
    color: white;
    border-radius: 18px 18px 4px 18px;
    padding: 10px 16px;
}

.message.assistant {
    align-self: flex-start;
    background-color: #e9e9eb;
    color: black;
    border-radius: 18px 18px 18px 4px;
    padding: 10px 16px;
}

#chat-form {
    display: flex;
    padding: 16px;
    background-color: #f8f9fa;
    border-top: 1px solid #eee;
    gap: 10px;
}

#user-input {
    flex: 1;
    padding: 12px 16px;
    border: 1px solid #ddd;
    border-radius: 20px;
    font-size: 16px;
    outline: none;
}

#user-input:focus {
    border-color: #007aff;
    box-shadow: 0 0 0 2px rgba(0,122,255,0.25);
}

#user-input::placeholder {
    color: #999;
}

button {
    background-color: #007aff;
    color: white;
    border: none;
    border-radius: 20px;
    padding: 0 20px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s;
}

button:hover {
    background-color: #0066cc;
}

button:active {
    background-color: #0052a3;
}