:root {
  color-scheme: dark;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --bg: #08070d;
  --surface: #110d1a;
  --surface-2: #191128;
  --input: #0d0a14;
  --drawer: #0d0a14;
  --ink: #f4effa;
  --muted: #a99bb8;
  --faint: #766780;
  --line: rgba(224, 198, 255, .14);
  --primary: #a875ff;
  --primary-strong: #c19aff;
  --primary-ink: #130a20;
  --accent: #edb7ff;
  --danger: #ff899c;
  --radius: 18px;
}
body[data-theme="light-violet"] { color-scheme: light; --bg: #f7f5fb; --surface: #ffffff; --surface-2: #f0ebfa; --input: #faf9fd; --drawer: #ffffff; --ink: #21172c; --muted: #71677c; --faint: #94899f; --line: rgba(74, 45, 106, .15); --primary: #7541d8; --primary-strong: #6130c0; --primary-ink: #ffffff; --accent: #a878ef; --danger: #d94c6b; }
body[data-theme="pink"] { --primary: #ff6fae; --primary-strong: #ff91c1; --primary-ink: #260817; --accent: #ffaccd; --line: rgba(255, 174, 211, .16); }
body[data-theme="orange"] { color-scheme: light; --bg: #fff8f0; --surface: #ffffff; --surface-2: #fff0df; --input: #fffaf5; --drawer: #fffdf9; --ink: #2a1b12; --muted: #78685d; --faint: #a49387; --line: rgba(117, 71, 36, .16); --primary: #e76c1b; --primary-strong: #c9550d; --primary-ink: #ffffff; --accent: #f4a15d; --danger: #c94f4f; }
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { min-width: 320px; min-height: 100%; }
body { margin: 0; overflow-x: hidden; background: var(--bg); color: var(--ink); transition: background .2s ease, color .2s ease; }
body.drawer-open { overflow: hidden; }
button, input, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
a { color: inherit; text-decoration: none; }
.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; }
.app-shell { min-height: 100svh; }
.main-area { min-width: 0; min-height: 100svh; display: flex; flex-direction: column; }
.drawer { position: fixed; z-index: 20; inset: 0 auto 0 0; width: min(350px, 88vw); display: flex; flex-direction: column; padding: 20px 15px 16px; background: var(--drawer); border-right: 1px solid var(--line); transform: translateX(-102%); transition: transform .25s ease, background .2s ease; box-shadow: 18px 0 60px rgba(0,0,0,.22); }
body.drawer-open .drawer { transform: translateX(0); }
.drawer-backdrop { position: fixed; z-index: 19; inset: 0; background: rgba(5, 3, 10, .62); backdrop-filter: blur(3px); }
.drawer-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 2px 4px 19px; }
.brand-row, .topbar-brand { display: flex; align-items: center; gap: 10px; }
.brand-mark { width: 35px; height: 35px; display: grid; place-items: center; border-radius: 11px; background: var(--primary); color: var(--primary-ink); font-size: 16px; font-weight: 950; letter-spacing: -.1em; }
.brand-row strong { display: block; font-size: 13px; letter-spacing: .1em; }
.brand-row span { display: block; margin-top: 3px; color: var(--faint); font-size: 10px; letter-spacing: .08em; text-transform: uppercase; }
.icon-button, .menu-button, .clear-button { border: 1px solid var(--line); background: transparent; color: var(--muted); transition: .2s ease; }
.icon-button { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 11px; font-size: 22px; line-height: 1; }
.icon-button:hover, .menu-button:hover, .clear-button:hover { border-color: var(--primary); color: var(--primary); }
.new-chat-button { width: 100%; min-height: 48px; display: flex; align-items: center; justify-content: center; gap: 8px; border: 0; border-radius: 13px; background: var(--primary); color: var(--primary-ink); font-size: 12px; font-weight: 850; transition: .2s ease; }
.new-chat-button:hover { background: var(--primary-strong); transform: translateY(-1px); }
.new-chat-button span:first-child { font-size: 20px; font-weight: 400; line-height: 0; }
.drawer-scroll { min-height: 0; flex: 1; overflow-y: auto; padding: 27px 0 15px; }
.menu-section + .menu-section { margin-top: 28px; }
.menu-label { margin: 0 12px 9px; color: var(--faint); font-size: 10px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
.topic-list { display: grid; gap: 4px; }
.topic-item { min-height: 46px; padding: 0 12px; display: flex; align-items: center; gap: 12px; border: 0; border-radius: 12px; background: transparent; color: var(--muted); text-align: left; font-size: 13px; transition: .2s ease; }
.topic-item:hover { color: var(--ink); background: rgba(128, 86, 180, .1); }
.topic-item.is-active { color: var(--primary); background: color-mix(in srgb, var(--primary) 14%, transparent); font-weight: 700; }
.topic-symbol { width: 21px; color: currentColor; font-size: 15px; font-weight: 700; text-align: center; }
.settings-toggle { width: 100%; min-height: 46px; padding: 0 12px; display: flex; align-items: center; justify-content: space-between; border: 0; border-radius: 12px; background: transparent; color: var(--muted); font-size: 13px; text-align: left; }
.settings-toggle:hover, .settings-toggle[aria-expanded="true"] { color: var(--ink); background: rgba(128, 86, 180, .1); }
.settings-toggle > span:first-child { display: flex; align-items: center; gap: 12px; }
.settings-symbol { width: 21px; display: inline-block; color: var(--primary); font-size: 20px; text-align: center; }
.chevron { font-size: 23px; line-height: 1; transition: transform .2s ease; }
.settings-toggle[aria-expanded="true"] .chevron { transform: rotate(90deg); }
.settings-panel { padding: 17px 0 0; }
.theme-grid { display: grid; gap: 7px; }
.theme-option { min-height: 44px; padding: 6px 9px; display: flex; align-items: center; gap: 10px; border: 1px solid transparent; border-radius: 11px; background: transparent; color: var(--muted); font-size: 11px; text-align: left; }
.theme-option:hover, .theme-option.is-selected { border-color: color-mix(in srgb, var(--primary) 45%, transparent); background: color-mix(in srgb, var(--primary) 8%, transparent); color: var(--ink); }
.theme-option.is-selected { color: var(--primary); font-weight: 700; }
.theme-swatch { width: 27px; height: 27px; flex: 0 0 27px; border: 1px solid var(--line); border-radius: 8px; background: linear-gradient(135deg, #08070d 0 52%, #a875ff 52%); }
.swatch-light-violet { background: linear-gradient(135deg, #fff 0 52%, #7541d8 52%); }
.swatch-pink { background: linear-gradient(135deg, #08070d 0 52%, #ff6fae 52%); }
.swatch-orange { background: linear-gradient(135deg, #fff8f0 0 52%, #e76c1b 52%); }
.drawer-ad { margin-top: auto; padding: 17px; border: 1px solid color-mix(in srgb, var(--primary) 30%, transparent); border-radius: 16px; background: linear-gradient(135deg, color-mix(in srgb, var(--primary) 14%, transparent), transparent); }
.ad-kicker { display: block; margin-bottom: 8px; color: var(--primary); font-size: 9px; font-weight: 850; letter-spacing: .16em; }
.drawer-ad strong { display: block; font-size: 13px; letter-spacing: .08em; }
.drawer-ad p { margin: 7px 0 14px; color: var(--muted); font-size: 11px; line-height: 1.45; }
.social-link { min-height: 38px; padding: 0 11px; display: flex; align-items: center; justify-content: space-between; gap: 8px; border-radius: 10px; background: var(--primary); color: var(--primary-ink); font-size: 10px; font-weight: 800; transition: .2s ease; }
.social-link:hover { background: var(--primary-strong); }
.topbar { position: sticky; top: 0; z-index: 5; min-height: 68px; display: flex; align-items: center; justify-content: space-between; padding: 0 clamp(16px, 4vw, 54px); border-bottom: 1px solid var(--line); background: color-mix(in srgb, var(--bg) 91%, transparent); backdrop-filter: blur(15px); }
.menu-button { min-height: 40px; padding: 0 12px; display: inline-flex; align-items: center; gap: 8px; border-radius: 11px; font-size: 11px; }
.menu-lines { font-size: 16px; line-height: 1; }
.topbar-brand { position: absolute; left: 50%; transform: translateX(-50%); }
.topbar-brand strong { font-size: 12px; letter-spacing: .1em; }
.topbar-brand .brand-mark { width: 30px; height: 30px; border-radius: 9px; font-size: 13px; }
.topbar-actions { display: flex; align-items: center; gap: 10px; }
.status-pill { display: flex; align-items: center; gap: 7px; color: var(--muted); font-size: 10px; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--primary); box-shadow: 0 0 0 4px color-mix(in srgb, var(--primary) 16%, transparent); }
.top-profile-button { min-height: 40px; display: inline-flex; align-items: center; gap: 7px; padding: 3px 10px 3px 4px; border: 1px solid var(--line); border-radius: 22px; background: transparent; color: var(--muted); font-size: 10px; font-weight: 750; }
.top-profile-button:hover { border-color: var(--primary); color: var(--primary); }
.top-profile-avatar { width: 30px; height: 30px; display: grid; place-items: center; border-radius: 50%; background: color-mix(in srgb, var(--primary) 18%, transparent); color: var(--primary); font-size: 11px; font-weight: 850; background-position: center; background-size: cover; }
.top-profile-avatar.has-image { color: transparent; }
.chat-page { width: min(100%, 990px); flex: 1; margin: 0 auto; padding: clamp(28px, 5vh, 58px) clamp(15px, 4vw, 54px) 24px; }
.chat-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 22px; margin-bottom: 20px; }
.eyebrow { color: var(--primary); font-size: 10px; font-weight: 800; letter-spacing: .18em; text-transform: uppercase; }
.chat-heading h1 { margin: 12px 0 9px; font-size: clamp(28px, 4.4vw, 44px); letter-spacing: -.06em; line-height: 1; }
.chat-heading p { max-width: 600px; margin: 0; color: var(--muted); font-size: 13px; line-height: 1.55; }
.clear-button { min-height: 38px; flex: 0 0 auto; padding: 0 12px; border-radius: 10px; font-size: 10px; }
.clear-button:hover { border-color: var(--danger); color: var(--danger); }
.chat-panel { overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: 0 22px 80px rgba(0,0,0,.16); }
.chat-log { min-height: min(52vh, 570px); max-height: min(58vh, 650px); overflow-y: auto; display: flex; flex-direction: column; gap: 14px; padding: 25px 22px 18px; scroll-behavior: smooth; }
.message { max-width: min(78%, 650px); padding: 13px 15px; border-radius: 16px; font-size: 13px; line-height: 1.6; white-space: pre-wrap; overflow-wrap: anywhere; }
.message.user { align-self: flex-end; color: var(--primary-ink); background: var(--primary); border-bottom-right-radius: 4px; }
.message.assistant { align-self: flex-start; color: var(--ink); background: var(--surface-2); border-bottom-left-radius: 4px; }
.message-text:empty { display: none; }
.message-attachment { display: block; width: min(100%, 260px); max-height: 220px; margin-bottom: 9px; border-radius: 10px; object-fit: cover; }
.message-image { margin-top: 12px; }
.message-image img { display: block; width: min(100%, 430px); max-height: 430px; border-radius: 11px; background: #050307; object-fit: contain; }
.image-download { display: inline-flex; min-height: 34px; align-items: center; margin-top: 9px; padding: 0 11px; border: 1px solid var(--line); border-radius: 9px; color: var(--primary); font-size: 11px; font-weight: 750; }
.image-download:hover { border-color: var(--primary); background: color-mix(in srgb, var(--primary) 10%, transparent); }
.empty-chat { min-height: 310px; display: flex; flex-direction: column; align-items: center; justify-content: center; color: var(--muted); text-align: center; }
.empty-mark { width: 45px; height: 45px; display: grid; place-items: center; margin-bottom: 14px; border-radius: 14px; background: var(--primary); color: var(--primary-ink); font-weight: 900; }
.empty-chat strong { color: var(--ink); font-size: 14px; }
.empty-chat p { max-width: 270px; margin: 7px 0 0; font-size: 12px; line-height: 1.5; }
.loading-message { display: flex; align-items: center; gap: 9px; color: var(--muted); }
.loading-dots { display: inline-flex; gap: 3px; }
.loading-dots i { width: 5px; height: 5px; display: block; border-radius: 50%; background: var(--primary); animation: pulse 1s ease-in-out infinite; }
.loading-dots i:nth-child(2) { animation-delay: .15s; } .loading-dots i:nth-child(3) { animation-delay: .3s; }
.suggestions { display: flex; gap: 8px; overflow-x: auto; padding: 0 22px 15px; scrollbar-width: none; }
.suggestions::-webkit-scrollbar { display: none; }
.suggestions button { min-height: 35px; flex: 0 0 auto; padding: 0 11px; border: 1px solid var(--line); border-radius: 10px; background: transparent; color: var(--muted); font-size: 11px; transition: .2s ease; }
.suggestions button:hover { border-color: color-mix(in srgb, var(--primary) 55%, transparent); color: var(--primary); }
.composer { padding: 0 14px 14px; }
.attachment-preview { padding: 0 8px 9px; }
.attachment-chip { width: fit-content; max-width: 100%; min-height: 42px; display: flex; align-items: center; gap: 8px; padding: 5px 7px 5px 5px; border: 1px solid var(--line); border-radius: 10px; background: var(--input); color: var(--muted); font-size: 11px; }
.attachment-chip img { width: 30px; height: 30px; border-radius: 6px; object-fit: cover; }
.attachment-chip span { max-width: 210px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.attachment-chip button { width: 27px; height: 27px; border: 0; border-radius: 7px; background: transparent; color: var(--muted); font-size: 19px; line-height: 1; }
.attachment-chip button:hover { color: var(--danger); background: color-mix(in srgb, var(--danger) 10%, transparent); }
.composer-row { min-height: 58px; display: flex; align-items: flex-end; gap: 8px; padding: 7px; border: 1px solid var(--line); border-radius: 16px; background: var(--input); }
.chat-input { flex: 1; min-width: 0; max-height: 150px; padding: 9px 3px; resize: none; overflow-y: auto; border: 0; outline: 0; background: transparent; color: var(--ink); font-size: 13px; line-height: 1.45; }
.chat-input::placeholder { color: var(--faint); }
.attach-button, .send-button { width: 40px; height: 40px; flex: 0 0 40px; display: grid; place-items: center; border-radius: 11px; }
.attach-button { color: var(--muted); cursor: pointer; font-size: 22px; }
.attach-button:hover { color: var(--primary); background: color-mix(in srgb, var(--primary) 9%, transparent); }
.file-input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.send-button { border: 0; background: var(--primary); color: var(--primary-ink); font-size: 22px; font-weight: 850; transition: .2s ease; }
.send-button:hover { background: var(--primary-strong); transform: translateY(-1px); }
.send-button:disabled { cursor: wait; opacity: .5; transform: none; }
.composer-footer { display: flex; justify-content: space-between; gap: 12px; padding: 8px 3px 0; color: var(--faint); font-size: 10px; line-height: 1.4; }
.app-footer { display: flex; justify-content: space-between; gap: 15px; padding: 14px clamp(15px, 4vw, 54px) 20px; color: var(--faint); font-size: 10px; }
.footer-brand { white-space: nowrap; }
.toast { position: fixed; z-index: 30; left: 50%; bottom: 24px; max-width: min(92vw, 430px); padding: 11px 15px; transform: translate(-50%, 18px); border: 1px solid var(--line); border-radius: 11px; background: var(--surface-2); color: var(--ink); font-size: 12px; opacity: 0; pointer-events: none; transition: .25s ease; box-shadow: 0 10px 30px rgba(0,0,0,.25); }
.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
@keyframes pulse { 0%, 100% { opacity: .35; transform: translateY(0); } 50% { opacity: 1; transform: translateY(-2px); } }
.profile-card { width: 100%; min-height: 66px; display: flex; align-items: center; gap: 10px; margin-top: 12px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 14px; background: color-mix(in srgb, var(--primary) 6%, transparent); color: var(--ink); text-align: left; transition: .2s ease; }
.profile-card:hover { border-color: color-mix(in srgb, var(--primary) 55%, transparent); background: color-mix(in srgb, var(--primary) 12%, transparent); }
.profile-card-copy { min-width: 0; flex: 1; }
.profile-card-copy strong, .profile-card-copy span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.profile-card-copy strong { font-size: 12px; }
.profile-card-copy span { margin-top: 4px; color: var(--muted); font-size: 10px; }
.profile-arrow { color: var(--primary); font-size: 23px; line-height: 1; }
.profile-avatar { width: 39px; height: 39px; flex: 0 0 39px; display: grid; place-items: center; border-radius: 50%; background-color: var(--primary); background-position: center; background-size: cover; color: var(--primary-ink); font-size: 14px; font-weight: 850; }
.profile-avatar-empty { background: color-mix(in srgb, var(--primary) 18%, transparent); color: var(--primary); }
.profile-avatar.has-image { color: transparent; }
.modal-open { overflow: hidden; }
.profile-modal { position: fixed; z-index: 40; inset: 0; display: grid; place-items: center; padding: 18px; }
.profile-modal[hidden] { display: none; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(4, 3, 9, .72); backdrop-filter: blur(8px); }
.profile-dialog { position: relative; width: min(100%, 470px); max-height: min(720px, calc(100svh - 36px)); overflow-y: auto; padding: 22px; border: 1px solid var(--line); border-radius: 22px; background: var(--surface); box-shadow: 0 25px 90px rgba(0,0,0,.35); }
.profile-dialog-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; }
.profile-dialog h2 { margin: 8px 0 0; font-size: clamp(24px, 5vw, 30px); letter-spacing: -.05em; }
.profile-dialog-note { margin: 12px 0 21px; color: var(--muted); font-size: 12px; line-height: 1.55; }
.profile-cloud-box { margin: -7px 0 18px; padding: 10px; border: 1px solid color-mix(in srgb, var(--primary) 30%, transparent); border-radius: 13px; background: color-mix(in srgb, var(--primary) 7%, transparent); }
.profile-cloud-modes { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.cloud-mode-button { min-height: 36px; padding: 0 8px; border: 1px solid transparent; border-radius: 9px; background: transparent; color: var(--muted); font-size: 10px; font-weight: 700; }
.cloud-mode-button:hover, .cloud-mode-button.is-active { border-color: color-mix(in srgb, var(--primary) 45%, transparent); background: color-mix(in srgb, var(--primary) 12%, transparent); color: var(--primary); }
.profile-auth-hint { margin: 9px 2px 1px; color: var(--muted); font-size: 10px; line-height: 1.45; }
.profile-avatar-editor { display: flex; align-items: center; gap: 14px; margin-bottom: 20px; }
.profile-avatar-large { width: 72px; height: 72px; flex-basis: 72px; font-size: 25px; }
.upload-avatar-button { min-height: 38px; display: inline-flex; align-items: center; padding: 0 11px; border: 1px solid var(--line); border-radius: 10px; color: var(--primary); cursor: pointer; font-size: 11px; font-weight: 750; }
.upload-avatar-button:hover { border-color: var(--primary); background: color-mix(in srgb, var(--primary) 9%, transparent); }
.text-button { display: block; margin-top: 6px; padding: 0; border: 0; background: transparent; color: var(--faint); font-size: 10px; }
.text-button:hover { color: var(--danger); }
.field-label { display: grid; gap: 7px; margin-top: 14px; color: var(--muted); font-size: 11px; font-weight: 750; }
.field-label input, .field-label textarea { width: 100%; padding: 12px 13px; border: 1px solid var(--line); border-radius: 11px; outline: 0; background: var(--input); color: var(--ink); font-size: 13px; font-weight: 400; resize: vertical; }
.field-label input:focus, .field-label textarea:focus { border-color: var(--primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 15%, transparent); }
.field-label input::placeholder, .field-label textarea::placeholder { color: var(--faint); }
.field-label small { color: var(--faint); font-size: 10px; font-weight: 400; line-height: 1.35; }
.profile-progress { margin-top: 19px; padding: 13px; border-radius: 13px; background: var(--surface-2); color: var(--muted); }
.profile-progress-title { color: var(--ink); font-size: 12px; font-weight: 800; }
.profile-progress p { margin: 5px 0 0; font-size: 11px; line-height: 1.45; }
.leaderboard { margin-top: 12px; padding: 13px; border: 1px solid var(--line); border-radius: 13px; background: color-mix(in srgb, var(--primary) 5%, transparent); }
.leaderboard-title { color: var(--ink); font-size: 12px; font-weight: 800; }
.leaderboard-note { margin: 4px 0 10px; color: var(--faint); font-size: 10px; }
.leaderboard-row { display: grid; grid-template-columns: 25px 1fr auto; align-items: center; gap: 8px; min-height: 31px; border-top: 1px solid var(--line); color: var(--muted); font-size: 10px; }
.leaderboard-row strong { color: var(--ink); font-size: 11px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.leaderboard-row em { color: var(--primary); font-size: 10px; font-style: normal; font-weight: 800; }
.profile-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; text-align: center; }
.profile-stats div { padding: 7px 3px; border-right: 1px solid var(--line); }
.profile-stats div:last-child { border-right: 0; }
.profile-stats strong, .profile-stats span { display: block; }
.profile-stats strong { color: var(--ink); font-size: 17px; }
.profile-stats span { margin-top: 3px; font-size: 9px; }
.profile-level, .reward-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 12px; font-size: 10px; }
.profile-level strong { color: var(--primary); }
.reward-list { display: flex; gap: 5px; }
.reward-badge { width: 26px; height: 26px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 8px; color: var(--faint); opacity: .45; }
.reward-badge.is-unlocked { border-color: color-mix(in srgb, var(--primary) 50%, transparent); background: color-mix(in srgb, var(--primary) 13%, transparent); color: var(--primary); opacity: 1; }
.reward-badge span { font-size: 14px; }
.profile-form-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 20px; }
.secondary-button, .primary-button { min-height: 42px; padding: 0 14px; border-radius: 10px; font-size: 11px; font-weight: 750; }
.secondary-button { border: 1px solid var(--line); background: transparent; color: var(--muted); }
.secondary-button:hover { border-color: var(--primary); color: var(--primary); }
.primary-button { border: 0; background: var(--primary); color: var(--primary-ink); }
.primary-button:hover { background: var(--primary-strong); }
@media (max-width: 620px) {
  .topbar { min-height: 62px; padding: 0 12px; }
  .topbar-brand strong { display: none; }
  .status-pill { display: none; }
  .menu-button { min-height: 38px; padding: 0 10px; }
  .chat-page { padding: 25px 10px 15px; }
  .chat-heading { align-items: flex-start; flex-direction: column; gap: 13px; margin-bottom: 15px; }
  .chat-heading h1 { margin-top: 10px; font-size: 31px; }
  .chat-heading p { font-size: 12px; }
  .clear-button { align-self: flex-end; }
  .chat-panel { border-radius: 15px; }
  .chat-log { min-height: 48vh; max-height: 57vh; padding: 17px 11px 14px; }
  .message { max-width: 92%; padding: 12px 13px; font-size: 12px; }
  .suggestions { padding: 0 11px 11px; }
  .composer { padding: 0 8px 9px; }
  .composer-footer { display: block; padding-top: 7px; }
  .composer-footer span { display: block; }
  .composer-footer span + span { margin-top: 3px; }
  .app-footer { display: block; padding-top: 10px; line-height: 1.6; }
  .footer-brand { display: block; margin-top: 4px; }
  .profile-modal { padding: 10px; align-items: end; }
  .profile-dialog { max-height: calc(100svh - 20px); padding: 19px 16px; border-radius: 19px 19px 14px 14px; }
  .profile-form-actions { position: sticky; bottom: -19px; margin: 19px -16px -19px; padding: 12px 16px; background: color-mix(in srgb, var(--surface) 94%, transparent); backdrop-filter: blur(10px); }
  .profile-form-actions button { flex: 1; }
}
@media (max-height: 650px) and (min-width: 621px) { .chat-page { padding-top: 25px; } .chat-log { min-height: 42vh; } }
