:root {
  color-scheme: light;
  --ink: #17352f;
  --muted: #63736f;
  --paper: #fffefb;
  --wash: #edf6f2;
  --line: #d9e7e1;
  --brand: #167761;
  --brand-dark: #0d5444;
  --accent: #e8b86d;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    radial-gradient(circle at 10% 10%, rgba(232, 184, 109, .18), transparent 28rem),
    linear-gradient(135deg, #f6fbf9, #e5f1ec);
}

button, textarea { font: inherit; }

.shell {
  width: min(1080px, calc(100% - 32px));
  min-height: 100vh;
  margin: 0 auto;
  padding: 28px 0;
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 20px;
  align-items: stretch;
}

.clinic-card, .chat-card {
  background: rgba(255, 254, 251, .94);
  border: 1px solid rgba(255, 255, 255, .9);
  border-radius: 24px;
  box-shadow: 0 20px 55px rgba(21, 72, 60, .12);
}

.clinic-card {
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.brand-mark {
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  border-radius: 20px;
  color: white;
  background: var(--brand);
  font-weight: 800;
  letter-spacing: .08em;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--brand);
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .12em;
}

h1 { margin: 0; font-family: Georgia, serif; font-size: 2.3rem; line-height: 1.02; }
.clinic-card p:not(.eyebrow) { color: var(--muted); line-height: 1.6; }
.status { margin-top: auto; font-size: .86rem; color: var(--muted); }
.status span { display: inline-block; width: 9px; height: 9px; margin-right: 6px; border-radius: 50%; background: #28a677; }

.chat-card { min-height: calc(100vh - 56px); display: flex; flex-direction: column; overflow: hidden; }
.messages { flex: 1; overflow-y: auto; padding: 32px; display: flex; flex-direction: column; gap: 14px; }
.message { display: flex; }
.message.user { justify-content: flex-end; }
.bubble { max-width: min(78%, 620px); padding: 13px 16px; border-radius: 18px 18px 18px 5px; background: var(--wash); line-height: 1.48; white-space: pre-wrap; }
.user .bubble { color: white; background: var(--brand); border-radius: 18px 18px 5px 18px; }

.suggestions { padding: 0 24px 14px; display: flex; flex-wrap: wrap; gap: 8px; }
.suggestions button { padding: 9px 12px; color: var(--brand-dark); background: white; border: 1px solid var(--line); border-radius: 999px; cursor: pointer; }
.suggestions button:hover { border-color: var(--brand); }

.composer { margin: 0 20px 8px; padding: 8px; display: flex; align-items: end; gap: 8px; background: white; border: 1px solid var(--line); border-radius: 18px; }
.composer:focus-within { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(22, 119, 97, .12); }
textarea { flex: 1; min-height: 44px; max-height: 140px; padding: 11px; resize: none; border: 0; outline: 0; color: var(--ink); background: transparent; }
.composer button { padding: 12px 18px; color: white; border: 0; border-radius: 12px; background: var(--brand); cursor: pointer; }
.composer button:disabled { opacity: .62; cursor: wait; }
.privacy { margin: 0 24px 18px; text-align: center; color: var(--muted); font-size: .74rem; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); }

@media (max-width: 760px) {
  .shell { width: 100%; min-height: 100dvh; padding: 0; display: block; }
  .clinic-card { display: none; }
  .chat-card { min-height: 100dvh; border: 0; border-radius: 0; }
  .messages { padding: 22px 16px; }
  .bubble { max-width: 88%; }
  .suggestions { padding-inline: 14px; }
  .composer { margin-inline: 12px; }
}
