/* Reset and base styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  background-color: #f7f9fb;
  color: #333;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

header {
  background: #2b5c7d;
  color: #fff;
  padding: 1rem 0;
}

header .container {
  display: flex;
  align-items: center;
  justify-content: center;
}

h1 {
  font-size: 1.8rem;
  font-weight: bold;
}

.container {
  width: 90%;
  max-width: 800px;
  margin: 0 auto;
}

main {
  flex: 1;
  padding: 2rem 0;
}

/* Chat section styles */
.chat-section {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.chat-messages {
  width: 100%;
  background: #eef3f8;
  border-radius: 8px;
  padding: 1rem;
  height: 400px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}

.message {
  max-width: 80%;
  padding: 0.75rem 1rem;
  border-radius: 12px;
  margin-bottom: 0.5rem;
  white-space: pre-wrap;
  line-height: 1.4;
}

.message.assistant {
  background: #e0e7ef;
  color: #2b5c7d;
  align-self: flex-start;
}

.message.user {
  background: #f0932b;
  color: #fff;
  align-self: flex-end;
}

.chat-input {
  width: 100%;
  display: flex;
  gap: 0.5rem;
  margin-top: 1rem;
}

#chatInput {
  flex: 1;
  padding: 0.75rem;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 1rem;
}

button.btn {
  padding: 0.75rem 1.5rem;
  background: #2b5c7d;
  color: #fff;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 1rem;
  transition: background 0.3s;
}

button.btn:hover {
  background: #214a63;
}

footer {
  background: #2b5c7d;
  color: #fff;
  text-align: center;
  padding: 1rem 0;
  font-size: 0.9rem;
}