:root {
  color-scheme: light;
  --bg: #f8f6f1;
  --paper: #fffdf9;
  --ink: #262f33;
  --muted: #778181;
  --line: #e8e8e3;
  --accent: #5a857a;
  --accent-strong: #34695d;
  --accent-pale: #e9f3ee;
  --peach: #f9eee6;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}
* { box-sizing: border-box; }
html { min-height: 100%; background: var(--bg); }
body {
  margin: 0; color: var(--ink); min-height: 100vh;
  background: radial-gradient(circle at 50% 0, #e8f1e9 0, transparent 38%), var(--bg);
}
button, textarea { font: inherit; }
button { cursor: pointer; }
button:focus-visible, textarea:focus-visible {
  outline: 3px solid #79aa95; outline-offset: 3px;
}
.shell {
  width: min(100%, 750px); margin: 0 auto; min-height: 100dvh;
  display: flex; flex-direction: column;
  padding: max(14px, env(safe-area-inset-top)) 18px max(16px, env(safe-area-inset-bottom));
}
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 4px 24px; }
.identity { display: flex; align-items: center; gap: 12px; min-width: 0; }
.mark {
  width: 45px; height: 45px; border-radius: 15px; display: grid; place-items: center;
  color: #fff; font-size: 26px; background: linear-gradient(145deg, #719e8c, #416f64);
  box-shadow: 0 7px 20px #547d6b2b;
}
.identity h1 { font-size: 19px; margin: 0 0 3px; letter-spacing: .02em; }
.identity p { margin: 0; color: var(--muted); font-size: 12px; }
.demo-tag { color: #52766b; background: #e4f1e9; border: 1px solid #d5e7dd; border-radius: 99px; padding: 6px 10px; font-size: 12px; white-space: nowrap; }
.safety-banner {
  display: flex; gap: 12px; align-items: flex-start; background: #fffaf4;
  border: 1px solid #f1dfcb; border-radius: 17px; padding: 15px; margin-bottom: 28px;
}
.safety-icon {
  flex: none; width: 25px; height: 25px; border-radius: 50%;
  background: #f5dbc6; color: #a46a46; display: grid; place-items: center; font-size: 24px; line-height: 1;
}
.safety-banner strong { font-size: 14px; }
.safety-banner p { color: #8c786c; font-size: 12px; margin: 5px 0 0; line-height: 1.6; }
.chat-heading { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 0 3px 16px; }
.tiny-kicker { color: #8aa99b; font-weight: 700; font-size: 10px; letter-spacing: .13em; }
.chat-heading h2 { font-size: 23px; letter-spacing: -.03em; margin: 5px 0 6px; }
.chat-heading p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.reset-button {
  flex: none; border: 1px solid #dce5dd; background: var(--paper); color: #62796c;
  border-radius: 12px; font-size: 12px; padding: 9px 13px;
}
.messages {
  flex: 1; min-height: 260px; padding: 14px 0 25px; display: flex;
  flex-direction: column; align-items: flex-start; gap: 18px;
  border-top: 1px solid #e3e6df; overflow-wrap: anywhere;
}
.message { display: flex; gap: 9px; align-items: flex-end; max-width: 88%; }
.message.user { align-self: flex-end; flex-direction: row-reverse; }
.avatar {
  flex: none; width: 30px; height: 30px; border-radius: 11px; display: grid;
  place-items: center; color: #fff; background: #648f81; font-size: 15px;
}
.message.user .avatar { background: #c79c85; }
.bubble { padding: 13px 15px; background: var(--paper); border: 1px solid #e5e8e2; border-radius: 16px 16px 16px 5px; box-shadow: 0 5px 12px #293c3410; }
.message.user .bubble { border-color: #d5e8de; background: #dff0e6; border-radius: 16px 16px 5px 16px; }
.bubble p { margin: 0; font-size: 14px; line-height: 1.75; white-space: pre-wrap; }
.msg-meta { font-size: 10px; color: #9aaa9f; margin-top: 6px; }
.message.user .msg-meta { text-align: right; color: #739186; }
.suggestion-area { padding-bottom: 18px; }
.section-label { font-size: 12px; color: #9a9d97; margin: 0 0 9px; }
.suggestions { display: flex; flex-wrap: wrap; gap: 8px; }
.prompt {
  border: 1px solid #dfe7de; border-radius: 99px; color: #537165; background: #fdfdfa;
  padding: 9px 12px; font-size: 12px; transition: background .15s;
}
.prompt:hover { background: #eaf3ed; }
.composer-wrap {
  background: #fffefa; border: 1px solid #e3e6df; border-radius: 20px; padding: 10px 12px;
  box-shadow: 0 9px 36px #6f80651c;
}
.composer { display: flex; gap: 10px; align-items: flex-end; }
textarea {
  background: none; border: 0; resize: vertical; min-height: 43px; max-height: 140px;
  flex: 1; color: var(--ink); padding: 11px 3px; outline: none; font-size: 14px;
}
textarea::placeholder { color: #aaaead; }
.composer button {
  flex: none; width: 43px; height: 43px; border: 0; border-radius: 14px; background: var(--accent-strong);
  color: white; font-size: 18px; display: grid; place-items: center;
}
.composer button:disabled { opacity: .4; cursor: not-allowed; }
.composer-note, .footnote { display: flex; justify-content: space-between; gap: 8px; font-size: 10px; color: #9ca59d; }
.composer-note { padding: 4px 3px 0; }
.status { margin: 0; color: #986c55; font-size: 12px; }
.status:empty { display: none; }
.footnote { padding: 16px 4px 0; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
@media (min-width: 720px) {
  .shell { margin: 28px auto; min-height: calc(100dvh - 56px); border-radius: 30px; background: #f8f8f3; padding: 18px 30px 25px; border: 1px solid #e8ede6; box-shadow: 0 18px 70px #22342a12; }
}
@media (max-width: 390px) {
  .shell { padding-left: 13px; padding-right: 13px; }
  .chat-heading h2 { font-size: 21px; }
  .messages { min-height: 215px; }
  .footnote { font-size: 9px; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; scroll-behavior: auto !important; }
}
