.cosmos-chat { max-width: 48rem; margin: auto; padding: 3rem 1.25rem; line-height: 1.65; }
.cosmos-chat h1 { font-size: clamp(2rem,6vw,3.5rem); margin: 0; }
.cosmos-chat form { display: grid; gap: .6rem; margin: 1rem 0 2rem; }
.cosmos-chat textarea, .cosmos-chat select, .cosmos-chat button { font: inherit; }
.cosmos-chat textarea { padding: .7rem; border-radius: .35rem; resize: vertical; }
.cosmos-chat button { cursor: pointer; }
.cosmos-chat button:disabled { opacity: .55; cursor: wait; }
.cosmos-chat input { max-width: 100%; }
#chat-history { display: grid; gap: .6rem; margin-top: 1rem; }
#chat-history p { margin: 0; padding: .65rem 1rem; background: #1b272b; color: #f3f7f5; border-left: 3px solid #87dec0; white-space: pre-wrap; overflow-wrap: anywhere; }
.chat-memory { padding: .85rem 1rem; border: 1px solid #394844; border-radius: .45rem; }
.chat-memory-rss, .chat-memory dl > div:not([hidden]) { display: flex; justify-content: space-between; align-items: baseline; gap: .25rem 1rem; flex-wrap: wrap; }
.chat-memory-rss span, .chat-memory dd { font-variant-numeric: tabular-nums; color: #87dec0; }
.chat-memory meter { display: block; width: 100%; height: 1rem; margin: .35rem 0; }
.chat-memory meter::-webkit-meter-optimum-value { background: #87dec0; }
.chat-memory meter::-moz-meter-bar { background: #87dec0; }
.chat-memory dl { margin: .5rem 0 .2rem; font-size: .9rem; }
.chat-memory dd { margin: 0; }
.chat-memory small { color: #b9c7c4; }
