:root {
  --bg-1: #050816;
  --bg-2: #090b18;
  --text: rgba(255,255,255,0.96);
  --muted: rgba(255,255,255,0.62);
  --border: rgba(255,255,255,0.12);
  --border-focus: rgba(216, 180, 254, 0.72);
  --glass: rgba(255,255,255,0.08);
  --glass-strong: rgba(255,255,255,0.12);
  --purple: rgba(168,85,247,0.25);
  --shadow: 0 24px 80px rgba(0,0,0,0.30);
  --shadow-focus: 0 0 0 1px rgba(217,70,239,0.22), 0 24px 80px rgba(139,92,246,0.24);
  --radius-xl: 32px;
  --radius-lg: 24px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  min-height: 100%;
  background:
    radial-gradient(circle at top, rgba(168,85,247,0.16), transparent 35%),
    linear-gradient(180deg, var(--bg-1) 0%, var(--bg-2) 45%, var(--bg-1) 100%);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body {
  min-height: 100vh;
}

.olivia-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 24px;
}

.olivia-shell {
  width: 100%;
  max-width: 960px;
}

.olivia-header {
  text-align: center;
  margin-bottom: 28px;
}

.olivia-kicker {
  margin: 0 0 12px;
  text-transform: uppercase;
  letter-spacing: 0.28em;
  font-size: 12px;
  color: rgba(232, 213, 255, 0.72);
}

.olivia-title {
  margin: 0;
  font-size: clamp(2rem, 4vw, 3.4rem);
  line-height: 1.06;
}

.olivia-subtitle {
  margin: 16px auto 0;
  max-width: 720px;
  color: var(--muted);
  line-height: 1.7;
  font-size: 15px;
}

.olivia-chat-root {
  max-width: 760px;
  margin: 0 auto;
}

.olivia-history {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 16px;
}

.olivia-message {
  max-width: 85%;
  padding: 14px 16px;
  border-radius: 24px;
  border: 1px solid var(--border);
  backdrop-filter: blur(20px);
  box-shadow: 0 10px 40px rgba(0,0,0,0.20);
  line-height: 1.7;
  font-size: 14px;
}

.olivia-message.user {
  margin-left: auto;
  background: rgba(168,85,247,0.14);
  border-color: rgba(216,180,254,0.28);
}

.olivia-message.assistant {
  margin-right: auto;
  background: rgba(255,255,255,0.06);
}

.olivia-composer {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-xl);
  border: 1px solid var(--border);
  background: linear-gradient(135deg, rgba(255,255,255,0.14), rgba(255,255,255,0.04), rgba(168,85,247,0.10));
  backdrop-filter: blur(24px);
  box-shadow: var(--shadow);
  transition:
    box-shadow 200ms ease,
    border-color 200ms ease,
    transform 300ms var(--ease);
}

.olivia-composer.expanded {
  transform: scale(1);
}

.olivia-composer.focused {
  border-color: var(--border-focus);
  box-shadow: var(--shadow-focus);
}

.olivia-composer-inner {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  padding: 16px;
}

.olivia-input {
  width: 100%;
  min-height: 30px;
  max-height: 180px;
  resize: none;
  border: 0;
  outline: none;
  background: transparent;
  color: var(--text);
  font-size: 15px;
  line-height: 1.7;
}

.olivia-input::placeholder {
  color: rgba(255,255,255,0.42);
}

.olivia-send {
  border: 1px solid rgba(216,180,254,0.24);
  background: rgba(168,85,247,0.18);
  color: white;
  border-radius: 18px;
  width: 46px;
  height: 46px;
  cursor: pointer;
  box-shadow: 0 10px 30px rgba(168,85,247,0.20);
  transition: background 180ms ease, transform 180ms ease;
}

.olivia-send:hover {
  background: rgba(168,85,247,0.30);
  transform: translateY(-1px);
}

.olivia-prompts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 0 16px 16px;
}

.olivia-chip {
  border: 1px solid rgba(255,255,255,0.10);
  background: rgba(255,255,255,0.07);
  color: rgba(255,255,255,0.78);
  border-radius: 999px;
  padding: 8px 12px;
  font-size: 12px;
  cursor: pointer;
  transition: all 180ms ease;
}

.olivia-chip:hover {
  border-color: rgba(216,180,254,0.30);
  background: rgba(168,85,247,0.12);
  color: white;
}

.olivia-composer.collapsed .olivia-prompts {
  display: none;
}

.olivia-composer.collapsed .olivia-input {
  min-height: 28px;
}

@media (max-width: 640px) {
  .olivia-page {
    padding: 24px 14px;
  }

  .olivia-composer-inner {
    padding: 14px;
  }

  .olivia-send {
    width: 42px;
    height: 42px;
  }

  .olivia-message {
    max-width: 92%;
  }
}
.olivia-status{display:inline-flex;margin:16px 8px 0 0;padding:8px 12px;border:1px solid var(--border);border-radius:999px;color:var(--muted);background:rgba(255,255,255,.06)}.olivia-retry{border:1px solid rgba(216,180,254,.24);background:rgba(168,85,247,.18);color:white;border-radius:999px;padding:8px 12px;cursor:pointer}.companion-message{max-width:85%;padding:14px 16px;border-radius:24px;border:1px solid var(--border);backdrop-filter:blur(20px);box-shadow:0 10px 40px rgba(0,0,0,.20);line-height:1.7;font-size:14px}.companion-message.user{margin-left:auto;background:rgba(168,85,247,.14);border-color:rgba(216,180,254,.28)}.companion-message.assistant{margin-right:auto;background:rgba(255,255,255,.06)}

.companion-message[data-origin="scheduled_checkin"]::before {
  content: "Scheduled check-in";
  display: block;
  font-size: 0.75rem;
  color: #6b7280;
  margin-bottom: 0.25rem;
}

.olivia-checkins-summary {
  margin-top: 18px;
  padding: 16px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 8px;
  background: rgba(255,255,255,.05);
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
}
.olivia-checkins-summary[hidden] { display: none; }
.olivia-checkins-summary h2 { margin: 0 0 6px; font-size: 1rem; }
.olivia-checkins-summary p { margin: 0; color: rgba(255,255,255,.72); }
.olivia-checkins-summary a { border: 1px solid rgba(255,255,255,.18); border-radius: 8px; padding: 9px 12px; color: inherit; text-decoration: none; }
