:root { color-scheme: light; font-family: Pretendard, Arial, sans-serif; background: #f6f7fb; color: #172033; }
:root[data-theme="dark"] { color-scheme: dark; background: #111827; color: #f3f4f6; }
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; }
.shell { width: min(1180px, calc(100% - 32px)); margin: 0 auto; padding: 28px 0; }
.topbar, .chat-head, .section-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.eyebrow { color: #6d5dfc; font-size: 12px; font-weight: 800; letter-spacing: .04em; }
h1, h2 { margin: 4px 0; }
button, input { font: inherit; }
button { border: 1px solid #d7dbe5; border-radius: 6px; background: #fff; color: inherit; padding: 9px 12px; cursor: pointer; }
button:hover, button.active { border-color: #6d5dfc; }
.layout { display: grid; grid-template-columns: minmax(240px, 320px) 8px minmax(0, 1fr); gap: 0; margin-top: 24px; }
.resizer { cursor: col-resize; background: transparent; }
.resizer:hover { background: #6d5dfc; }
.rooms, .chat { min-width: 0; background: #fff; border: 1px solid #e1e5ed; border-radius: 8px; }
:root[data-theme="dark"] .rooms, :root[data-theme="dark"] .chat, :root[data-theme="dark"] button, :root[data-theme="dark"] input { background: #182235; border-color: #334155; }
.rooms { padding: 16px; }
.room { display: grid; width: 100%; text-align: left; margin-top: 8px; }
.room span { color: #68738a; font-size: 12px; margin-top: 5px; }
.chat { min-height: 600px; display: grid; grid-template-rows: auto minmax(0, 1fr) auto; }
.chat-head { border-bottom: 1px solid #e1e5ed; padding: 16px 20px; }
.messages { overflow: auto; padding: 20px; }
.message { width: fit-content; max-width: min(76%, 620px); margin: 0 0 12px; padding: 10px 12px; border: 1px solid #e1e5ed; border-radius: 8px; background: #fafbff; }
.message.mine { margin-left: auto; background: #eeeaff; border-color: #cfc8ff; }
.message p { margin: 5px 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.message time { color: #7a8498; font-size: 11px; }
#composer { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; padding: 16px; border-top: 1px solid #e1e5ed; }
input { min-width: 0; border: 1px solid #d7dbe5; border-radius: 6px; padding: 11px 12px; background: #fff; color: inherit; }
.status { color: #68738a; font-size: 12px; }
.status.online { color: #11875d; }
.status.offline { color: #c0392b; }
.notice { color: #c0392b; min-height: 20px; }
@media (max-width: 720px) { .resizer { display:none; } .shell { width: min(100% - 20px, 560px); padding: 16px 0; } .layout { grid-template-columns: 1fr; } .rooms { max-height: 260px; overflow: auto; } .chat { min-height: 520px; } .message { max-width: 88%; } }
.reply-bar { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 16px; border-top: 1px solid #e1e5ed; background: #f7f8fc; color: #59647a; font-size: 12px; }
.message-actions { display: flex; gap: 6px; margin-top: 8px; }
.message-actions button { padding: 4px 7px; font-size: 11px; }
.reply-preview { margin: 6px 0; padding: 5px 8px; border-left: 3px solid #6d5dfc; background: #f0efff; color: #59647a; font-size: 12px; overflow-wrap: anywhere; }
:root[data-theme="dark"] .reply-bar, :root[data-theme="dark"] .reply-preview { background: #111827; color: #cbd5e1; border-color: #475569; }
