@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600&family=Playfair+Display:ital,wght@0,400;0,600;1,400&display=swap');

:root {
  --cream: #fffcf5;
  --teal: #329492;
  --burnt-orange: #C65D2B;
  --gold: #f3aa60;
  --blue: #56bbf6;
  --charcoal: #3a3a3a;
  
  --font-heading: 'Playfair Display', serif;
  --font-body: 'Montserrat', sans-serif;
}

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

body {
  font-family: var(--font-body);
  background-color: var(--cream);
  color: var(--charcoal);
  line-height: 1.6;
  max-width: 100vw;
  overflow-x: hidden;
  height: 100vh;
  display: flex;
  flex-direction: column;
}

h1, h2, h3, h4 {
  font-family: var(--font-heading);
  color: var(--charcoal);
  font-weight: 600;
}

/* Landing Page */
.landing-container {
  display: flex;
  height: 100vh;
}

.landing-left {
  flex: 1;
  background-color: var(--teal);
  color: var(--cream);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 4rem;
  position: relative;
}

.landing-left::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at bottom left, rgba(86,187,246,0.2), transparent);
  pointer-events: none;
}

.landing-left h1 {
  font-size: 4rem;
  color: var(--cream);
  margin-bottom: 1rem;
}

.landing-left p {
  font-size: 1.25rem;
  max-width: 400px;
  line-height: 1.8;
  opacity: 0.9;
}

.landing-right {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.auth-form {
  background: white;
  padding: 3rem;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.05);
  width: 100%;
  max-width: 400px;
}

.auth-form h2 {
  margin-bottom: 1.5rem;
  color: var(--charcoal);
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  font-weight: 500;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
}

.form-group input {
  width: 100%;
  padding: 0.8rem;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-family: var(--font-body);
  transition: border-color 0.2s;
}

.form-group input:focus {
  outline: none;
  border-color: var(--teal);
}

.btn {
  width: 100%;
  padding: 1rem;
  background-color: var(--teal);
  color: var(--cream);
  border: none;
  border-radius: 6px;
  font-family: var(--font-body);
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.2s;
  font-size: 1rem;
}

.btn:hover {
  background-color: #277775;
}

.btn.secondary {
  background-color: transparent;
  color: var(--teal);
  border: 2px solid var(--teal);
  margin-top: 1rem;
}

.btn.secondary:hover {
  background-color: rgba(50, 148, 146, 0.05);
}

.auth-switch {
  text-align: center;
  margin-top: 1.5rem;
  font-size: 0.9rem;
}

.auth-switch a {
  color: var(--teal);
  text-decoration: none;
  font-weight: 600;
  cursor: pointer;
}

/* App Interface */
.app-header {
  padding: 1rem 2rem;
  background-color: var(--cream);
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid rgba(0,0,0,0.05);
}

.app-brand {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  color: var(--charcoal);
  font-weight: 600;
}

.capability-widget {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.5rem 1rem;
  background: white;
  border-radius: 20px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.03);
}

.capability-label {
  font-size: 0.85rem;
  font-weight: 500;
  color: #666;
}

.capability-bar {
  width: 100px;
  height: 8px;
  background: #eee;
  border-radius: 4px;
  overflow: hidden;
}

.capability-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--burnt-orange), var(--gold), var(--teal));
  transition: width 1s ease-out;
}

.chat-container {
  flex: 1;
  display: flex;
  flex-direction: column;
  max-width: 800px;
  margin: 0 auto;
  width: 100%;
  padding: 2rem;
  overflow-y: hidden;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding-bottom: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.message {
  max-width: 80%;
  padding: 1.2rem;
  border-radius: 12px;
  line-height: 1.5;
}

.message.pam {
  align-self: flex-start;
  background-color: white;
  border: 1px solid #f0f0f0;
  box-shadow: 0 2px 10px rgba(0,0,0,0.02);
  color: var(--charcoal);
}

.message.user {
  align-self: flex-end;
  background-color: var(--blue);
  color: white;
}

.chat-input-area {
  margin-top: auto;
  padding-top: 1rem;
}

.chat-form {
  display: flex;
  gap: 1rem;
}

.chat-input {
  flex: 1;
  padding: 1rem 1.5rem;
  border: 1px solid #ddd;
  border-radius: 30px;
  font-family: var(--font-body);
  font-size: 1rem;
  box-shadow: 0 4px 15px rgba(0,0,0,0.05);
  transition: border-color 0.2s;
}

.chat-input:focus {
  outline: none;
  border-color: var(--teal);
}

.send-btn {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background-color: var(--teal);
  color: white;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.2s;
}

.send-btn:hover {
  transform: scale(1.05);
}

/* Helpers */
.hidden {
  display: none !important;
}

.markdown-body {
  font-family: var(--font-body);
}

.markdown-body strong {
  font-weight: 600;
}

.markdown-body ul, .markdown-body ol {
  margin-left: 1.5rem;
  margin-top: 0.5rem;
}

.task-complete-btn {
  margin-top: 1rem;
  background: var(--gold);
  color: var(--charcoal);
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  font-weight: 600;
  font-size: 0.8rem;
  cursor: pointer;
}
