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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
    background-color: #343541;
    height: 100vh;
    overflow: hidden;
    margin: 0;
    padding: 0;
}

.container {
    display: flex;
    height: 100vh;
    width: 100%;
    margin: 0;
    padding: 0;
}

.sidebar {
    width: 250px;
    background-color: #202123;
    color: white;
    padding: 20px;
    display: flex;
    flex-direction: column;
    border-right: 1px solid #444654;
}

.sidebar h2 {
    margin-bottom: 30px;
    font-size: 20px;
    font-weight: 600;
}

.upload-section {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.upload-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 16px;
    background-color: #343541;
    border: 1px solid #565869;
    border-radius: 8px;
    color: white;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.2s;
}

.upload-button:hover {
    background-color: #40414f;
}

.upload-status {
    font-size: 12px;
    padding: 8px;
    border-radius: 4px;
    min-height: 20px;
}

.upload-status.success {
    color: #10a37f;
    background-color: rgba(16, 163, 127, 0.1);
}

.upload-status.error {
    color: #ef4444;
    background-color: rgba(239, 68, 68, 0.1);
}

.upload-status.loading {
    color: #fbbf24;
    background-color: rgba(251, 191, 36, 0.1);
}

.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    background-color: #343541;
}

.chat-container {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.welcome-message {
    text-align: center;
    color: #8e8ea0;
    padding: 40px 20px;
}

.welcome-message h3 {
    font-size: 24px;
    margin-bottom: 10px;
    color: #ececf1;
}

.welcome-message p {
    font-size: 16px;
}

.message {
    display: flex;
    gap: 16px;
    padding: 16px;
    border-radius: 8px;
    animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.message.user {
    background-color: #444654;
}

.message.assistant {
    background-color: transparent;
}

.message-avatar {
    width: 32px;
    height: 32px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-weight: 600;
    font-size: 14px;
}

.message.user .message-avatar {
    background-color: #19c37d;
    color: white;
}

.message.assistant .message-avatar {
    background-color: #ab68ff;
    color: white;
}

.message-content {
    flex: 1;
    color: #ececf1;
    line-height: 1.6;
    white-space: pre-wrap;
    word-wrap: break-word;
}

.message.user .message-content {
    color: #ececf1;
}

.message.assistant .message-content {
    color: #d1d5db;
}

.typing-indicator {
    display: flex;
    gap: 4px;
    padding: 4px 0;
}

.typing-indicator span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: #8e8ea0;
    animation: typing 1.4s infinite;
}

.typing-indicator span:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-indicator span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typing {
    0%, 60%, 100% {
        transform: translateY(0);
        opacity: 0.7;
    }
    30% {
        transform: translateY(-10px);
        opacity: 1;
    }
}

.input-container {
    display: flex;
    gap: 12px;
    padding: 16px;
    background-color: #40414f;
    border-top: 1px solid #565869;
}

#message-input {
    flex: 1;
    background-color: #40414f;
    border: 1px solid #565869;
    border-radius: 12px;
    padding: 12px 16px;
    color: #ececf1;
    font-size: 16px;
    font-family: inherit;
    resize: none;
    max-height: 200px;
    overflow-y: auto;
    outline: none;
}

#message-input:focus {
    border-color: #10a37f;
}

#message-input::placeholder {
    color: #8e8ea0;
}

.send-button {
    width: 40px;
    height: 40px;
    background-color: #19c37d;
    border: none;
    border-radius: 8px;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s;
    flex-shrink: 0;
}

.send-button:hover:not(:disabled) {
    background-color: #15a570;
}

.send-button:disabled {
    background-color: #565869;
    cursor: not-allowed;
    opacity: 0.5;
}

/* Scrollbar styling */
.chat-container::-webkit-scrollbar {
    width: 8px;
}

.chat-container::-webkit-scrollbar-track {
    background: transparent;
}

.chat-container::-webkit-scrollbar-thumb {
    background: #565869;
    border-radius: 4px;
}

.chat-container::-webkit-scrollbar-thumb:hover {
    background: #6e6f7f;
}

