:root {
  --bg: #f7f7f5;
  --sidebar: #efefec;
  --surface: #ffffff;
  --surface-soft: #f3f3f0;
  --line: #deded9;
  --line-strong: #c9c9c3;
  --text: #202126;
  --muted: #737479;
  --muted-light: #98999d;
  --accent: #1948b7;
  --accent-strong: #123990;
  --accent-soft: #e8eefc;
  --danger: #b42318;
  --danger-soft: #fff0ed;
  --user: #e9edf7;
  --shadow: 0 14px 42px rgba(24, 29, 40, .09);
}

* { box-sizing: border-box; }
html, body { min-height: 100%; margin: 0; }
body {
  min-width: 320px;
  overflow: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  -webkit-font-smoothing: antialiased;
}
body.editor-open { overflow: hidden; }
button, textarea, input, select { font: inherit; }
button { cursor: pointer; }
button:focus-visible, textarea:focus-visible, input:focus-visible, select:focus-visible, a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
[hidden] { display: none !important; }

.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;
}

.workspace {
  display: grid;
  grid-template-columns: 292px minmax(0, 1fr);
  min-height: 100vh;
}

.sidebar {
  display: flex;
  min-height: 100vh;
  min-width: 0;
  flex-direction: column;
  padding: 22px 16px 16px;
  overflow: hidden;
  background: var(--sidebar);
  border-right: 1px solid var(--line);
}
.brand-block { padding: 0 8px; }
.brand { display: block; width: 206px; max-width: 100%; line-height: 0; }
.brand-logo { display: block; width: 100%; height: auto; mix-blend-mode: multiply; }
.brand-block p { margin: 6px 0 0; color: var(--muted); font-size: .76rem; }

.new-task {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 43px;
  gap: 8px;
  margin: 22px 0 14px;
  padding: 0 14px;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  color: var(--text);
  font-size: .88rem;
  font-weight: 620;
}
.new-task:hover { border-color: #aaa9a3; background: #fbfbfa; }
.new-task svg { width: 17px; height: 17px; }

.category-nav {
  flex: 0 0 auto;
  min-height: 0;
  max-height: 43vh;
  overflow-y: auto;
  border-top: 1px solid var(--line);
  scrollbar-width: thin;
  scrollbar-color: #c6c6c1 transparent;
}
.category { padding: 5px 0; border-bottom: 1px solid var(--line); }
.category-toggle {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) 18px;
  align-items: center;
  width: 100%;
  min-height: 43px;
  gap: 8px;
  padding: 5px 7px;
  background: transparent;
  border: 0;
  border-radius: 9px;
  color: #38393e;
  text-align: left;
  font-size: .88rem;
  font-weight: 620;
}
.category-toggle:hover, .category.is-open > .category-toggle { background: rgba(255,255,255,.7); }
.category.is-active > .category-toggle { color: var(--accent); }
.category-icon {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  background: rgba(255,255,255,.7);
  border: 1px solid var(--line);
  border-radius: 8px;
}
.category.is-active .category-icon { background: var(--accent-soft); border-color: #cbd7f4; }
.category-icon svg { width: 16px; height: 16px; }
.category-chevron { width: 15px; height: 15px; color: #8d8e92; transition: transform .18s ease; }
.category.is-open .category-chevron { transform: rotate(180deg); }

.category-tools {
  display: none;
  gap: 2px;
  padding: 4px 4px 5px 38px;
}
.category.is-open .category-tools,
.category:hover .category-tools,
.category:focus-within .category-tools { display: grid; }
.subtool-button {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr) auto;
  align-items: center;
  width: 100%;
  min-height: 34px;
  gap: 7px;
  padding: 5px 8px;
  background: transparent;
  border: 0;
  border-radius: 8px;
  color: #5a5b60;
  text-align: left;
  font-size: .79rem;
}
.subtool-button:hover { background: rgba(255,255,255,.75); color: var(--text); }
.subtool-button.is-active { background: var(--surface); color: var(--accent); font-weight: 620; }
.subtool-button.is-disabled { cursor: default; color: #8e8f93; }
.subtool-button.is-disabled:hover { background: rgba(255,255,255,.45); }
.subtool-button svg { width: 15px; height: 15px; }
.subtool-button small {
  padding: 2px 5px;
  background: #e4e4e0;
  border-radius: 4px;
  color: #8a8b8e;
  font-size: .62rem;
  font-weight: 500;
}

.history-panel {
  display: flex;
  min-height: 120px;
  flex: 1 1 auto;
  flex-direction: column;
  margin-top: 15px;
  padding-top: 13px;
  overflow: hidden;
  border-top: 1px solid var(--line-strong);
}
.history-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 8px 7px;
  color: #4f5054;
  font-size: .76rem;
  font-weight: 620;
}
.history-heading small { color: var(--muted-light); font-size: .65rem; font-weight: 400; }
.history-list {
  min-height: 0;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: #c6c6c1 transparent;
}
.history-empty { margin: 12px 8px; color: var(--muted-light); font-size: .74rem; }
.history-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 30px;
  align-items: center;
  gap: 2px;
  margin-bottom: 2px;
  border-radius: 8px;
}
.history-row:hover, .history-row.is-active { background: rgba(255,255,255,.72); }
.history-open {
  display: grid;
  grid-template-columns: 16px minmax(0, 1fr);
  align-items: center;
  min-width: 0;
  min-height: 34px;
  gap: 7px;
  padding: 5px 6px 5px 8px;
  overflow: hidden;
  background: transparent;
  border: 0;
  color: #636469;
  text-align: left;
  font-size: .75rem;
}
.history-row.is-active .history-open { color: var(--text); font-weight: 600; }
.history-open svg { width: 14px; height: 14px; }
.history-open span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.history-pin {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  padding: 0;
  opacity: 0;
  background: transparent;
  border: 0;
  border-radius: 7px;
  color: #85868a;
}
.history-row:hover .history-pin, .history-pin.is-pinned, .history-pin:focus-visible { opacity: 1; }
.history-pin.is-pinned { color: var(--accent); }
.history-pin:hover { background: #e2e5ec; }
.history-pin svg { width: 13px; height: 13px; }
.sidebar-note { margin: 10px 7px 0; color: #95969a; font-size: .68rem; }

.chat-shell {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  min-width: 0;
  height: 100vh;
  overflow: hidden;
}
.chat-header {
  display: flex;
  align-items: center;
  min-height: 76px;
  gap: 11px;
  padding: 12px 28px;
  background: rgba(247,247,245,.96);
  border-bottom: 1px solid var(--line);
}
.current-tool-icon {
  display: grid;
  width: 39px;
  height: 39px;
  flex: 0 0 39px;
  place-items: center;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--accent);
}
.current-tool-icon svg { width: 19px; height: 19px; }
.chat-heading { display: grid; grid-template-columns: auto auto; align-items: baseline; column-gap: 8px; }
.chat-kicker { grid-column: 1; margin: 0; color: var(--accent); font-size: .68rem; font-weight: 650; }
.chat-header h1 { grid-column: 2; margin: 0; font-size: .98rem; font-weight: 650; line-height: 1.4; }
.chat-header p#chatSubtitle { grid-column: 1 / -1; margin: 2px 0 0; color: var(--muted); font-size: .74rem; }

.chat-messages { min-height: 0; overflow-y: auto; scroll-behavior: smooth; }
.chat-messages.is-empty { display: grid; place-items: center; padding: 44px 40px; }
.chat-messages.has-history { width: min(860px, calc(100% - 72px)); margin: 0 auto; padding: 40px 0 24px; }
.welcome-panel { width: min(790px, 100%); text-align: center; }
.welcome-eyebrow {
  display: inline-flex;
  align-items: center;
  min-height: 27px;
  margin: 0 0 16px;
  padding: 0 10px;
  background: var(--accent-soft);
  border-radius: 999px;
  color: var(--accent);
  font-size: .72rem;
  font-weight: 650;
}
.welcome-panel h2 { margin: 0; font-size: clamp(2rem, 4vw, 3rem); font-weight: 650; letter-spacing: -.045em; line-height: 1.14; }
.welcome-text { max-width: 640px; margin: 15px auto 0; color: var(--muted); font-size: .94rem; line-height: 1.72; }
.suggestions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; margin-top: 30px; }
.suggestions button {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  align-items: center;
  min-height: 64px;
  gap: 10px;
  padding: 10px 13px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  color: #45464b;
  text-align: left;
}
.suggestions button:hover { border-color: #b9c4dd; color: var(--accent); }
.suggestion-icon { display: grid; width: 34px; height: 34px; place-items: center; background: var(--surface-soft); border-radius: 9px; }
.suggestion-icon svg { width: 17px; height: 17px; }
.suggestion-copy { display: grid; gap: 3px; }
.suggestion-copy strong { font-size: .82rem; font-weight: 650; }
.suggestion-copy small { overflow: hidden; color: var(--muted); font-size: .68rem; text-overflow: ellipsis; white-space: nowrap; }

.message { display: flex; margin: 0 0 24px; }
.message-content { max-width: min(690px, 90%); font-size: .92rem; line-height: 1.7; white-space: pre-wrap; }
.user-message { justify-content: flex-end; }
.user-message .message-content { padding: 10px 14px; background: var(--user); border-radius: 14px 14px 4px 14px; }
.assistant-message .message-content { color: #55565b; }
.status-message .message-content { color: var(--muted); font-size: .82rem; }
.error-message .message-content { padding: 10px 13px; background: var(--danger-soft); border-radius: 9px; color: var(--danger); font-size: .82rem; }

.generation-card { display: block; width: min(480px, 90%); margin-bottom: 28px; }
.generation-card-inner { overflow: hidden; background: #f0f0ee; border-radius: 22px; }
.generation-card-copy { display: grid; gap: 4px; padding: 20px 22px 12px; }
.generation-card-copy strong { font-size: .9rem; }
.generation-card-copy span { color: var(--muted); font-size: .72rem; }
.generation-preview { position: relative; height: 280px; overflow: hidden; }
.generation-preview::before {
  position: absolute;
  inset: 24px;
  content: "";
  background: #e7e7e4;
  border-radius: 15px;
  animation: loading-breathe 1.7s ease-in-out infinite;
}
.generation-progress-line { position: absolute; right: 24px; bottom: 23px; left: 24px; height: 3px; overflow: hidden; background: #dadad6; border-radius: 999px; }
.generation-progress-line::after { display: block; width: 34%; height: 100%; content: ""; background: #aeb9d6; border-radius: inherit; animation: loading-slide 1.55s ease-in-out infinite; }

.media-message { display: block; }
.media-content { display: inline-grid; max-width: min(500px, 90%); gap: 8px; }
.image-open-button { display: block; width: fit-content; max-width: 100%; padding: 0; overflow: hidden; background: transparent; border: 0; border-radius: 12px; cursor: zoom-in; }
.media-content img, .media-content video { display: block; width: auto; max-width: 100%; max-height: 560px; object-fit: contain; border-radius: 12px; box-shadow: 0 6px 22px rgba(23,29,43,.08); }
.image-open-button:hover img { filter: brightness(.97); }
.media-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 30px; color: var(--muted); font-size: .7rem; }
.media-footer-actions { display: flex; gap: 6px; }
.media-action, .download-button {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  gap: 5px;
  padding: 0 9px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: #4a4b50;
  font-size: .7rem;
  text-decoration: none;
}
.media-action:hover, .download-button:hover { border-color: #bfc7dc; color: var(--accent); }
.media-action svg, .download-button svg { width: 13px; height: 13px; }

.composer-area { padding: 9px 28px 18px; background: var(--bg); }
.generation-options, .composer, .mode-hint { width: min(860px, 100%); margin-right: auto; margin-left: auto; }
.generation-options { display: flex; align-items: center; justify-content: flex-end; gap: 7px; margin-bottom: 7px; color: var(--muted); font-size: .7rem; }
.generation-options select { min-height: 30px; padding: 0 27px 0 9px; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; color: #55565a; font-size: .7rem; }
.composer {
  display: flex;
  align-items: flex-end;
  min-height: 64px;
  gap: 8px;
  padding: 10px 10px 10px 16px;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: 16px;
  box-shadow: 0 8px 28px rgba(26,31,43,.08);
}
.composer:focus-within { border-color: #aeb9d5; box-shadow: 0 8px 30px rgba(26,31,43,.10); }
.composer textarea { flex: 1; min-width: 0; min-height: 42px; max-height: 144px; padding: 9px 4px 5px; resize: none; overflow-y: auto; outline: 0; background: transparent; border: 0; color: var(--text); font-size: .92rem; line-height: 1.5; }
.composer textarea::placeholder { color: #9a9b9e; opacity: 1; }
.voice-button, .send-button { display: grid; width: 42px; height: 42px; flex: 0 0 42px; place-items: center; padding: 0; border: 0; border-radius: 11px; }
.voice-button { background: var(--surface-soft); color: #65666a; }
.voice-button:hover { background: #e8e8e5; color: var(--accent); }
.voice-button.is-listening { background: #ffe4e0; color: var(--danger); animation: pulse 1.2s ease-in-out infinite; }
.voice-button svg { width: 18px; height: 18px; }
.send-button { background: var(--accent); color: #fff; }
.send-button:hover { background: var(--accent-strong); }
.send-button:disabled { cursor: wait; opacity: .55; }
.send-button svg { width: 19px; height: 19px; }
.mode-hint { min-height: 17px; margin-top: 8px; padding-left: 4px; color: #8c8d91; font-size: .69rem; line-height: 1.45; }

.image-editor { position: fixed; inset: 0; z-index: 30; display: grid; grid-template-rows: auto minmax(0,1fr) auto; background: #f7f7f5; }
.editor-toolbar { position: relative; z-index: 4; display: flex; align-items: center; justify-content: space-between; min-height: 68px; gap: 20px; padding: 10px 18px; background: rgba(255,255,255,.96); border-bottom: 1px solid var(--line); }
.editor-title-wrap { display: flex; align-items: center; gap: 10px; min-width: 0; }
.editor-title-wrap h2 { margin: 0; font-size: .92rem; font-weight: 650; }
.editor-title-wrap p { margin: 2px 0 0; color: var(--muted); font-size: .66rem; }
.editor-icon-button { display: grid; width: 36px; height: 36px; place-items: center; padding: 0; background: var(--surface-soft); border: 0; border-radius: 9px; color: #4e4f54; }
.editor-icon-button:hover { background: #e8e8e5; }
.editor-icon-button svg { width: 18px; height: 18px; }
.editor-actions { display: flex; align-items: center; gap: 7px; }
.editor-action {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  gap: 6px;
  padding: 0 11px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 9px;
  color: #3e3f44;
  font-size: .76rem;
  text-decoration: none;
}
.editor-action:hover, .editor-action.is-active { border-color: #b7c3df; color: var(--accent); }
.editor-action svg { width: 15px; height: 15px; }
.ratio-control { position: relative; }
.ratio-menu { position: absolute; top: calc(100% + 7px); right: 0; z-index: 8; width: 174px; padding: 7px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); }
.ratio-menu button { display: grid; grid-template-columns: 26px minmax(0,1fr); align-items: center; width: 100%; min-height: 36px; gap: 9px; padding: 5px 8px; background: transparent; border: 0; border-radius: 8px; color: #505156; text-align: left; font-size: .74rem; }
.ratio-menu button:hover { background: var(--surface-soft); color: var(--accent); }
.ratio-menu button svg { width: 16px; height: 16px; justify-self: center; }

.editor-stage { position: relative; display: grid; place-items: center; min-height: 0; padding: 26px 32px; overflow: auto; }
.editor-image-frame { position: relative; display: inline-block; line-height: 0; user-select: none; }
.editor-image-frame.is-selecting { cursor: crosshair; }
.editor-image-frame img { display: block; width: auto; max-width: min(76vw, 1180px); max-height: calc(100vh - 220px); object-fit: contain; box-shadow: 0 10px 40px rgba(21,25,34,.12); }
.selection-box { position: absolute; z-index: 2; background: rgba(25,72,183,.13); border: 2px solid #fff; box-shadow: 0 0 0 1px var(--accent); pointer-events: none; }
.selection-actions { position: fixed; z-index: 5; bottom: 102px; left: 50%; display: flex; align-items: center; gap: 8px; padding: 8px 9px 8px 13px; transform: translateX(-50%); background: #24252a; border-radius: 12px; box-shadow: var(--shadow); color: #fff; font-size: .72rem; }
.selection-actions button { min-height: 31px; padding: 0 10px; background: #fff; border: 0; border-radius: 8px; color: #2d2e33; font-size: .7rem; }
.selection-actions button:last-child { background: #3b3c42; color: #fff; }
.editor-progress { position: absolute; inset: 0; z-index: 6; display: grid; align-content: center; justify-items: center; gap: 8px; background: rgba(247,247,245,.9); color: var(--text); }
.editor-progress strong { margin-top: 5px; font-size: .9rem; }
.editor-progress span { color: var(--muted); font-size: .72rem; }
.progress-spinner { width: 30px; height: 30px; border: 3px solid #d9dce5; border-top-color: var(--accent); border-radius: 50%; animation: spin .8s linear infinite; }
.editor-footer { position: relative; z-index: 4; padding: 10px 20px 16px; background: rgba(247,247,245,.97); }
.editor-composer { display: flex; align-items: flex-end; width: min(780px,100%); min-height: 55px; gap: 8px; margin: 0 auto; padding: 8px 8px 8px 14px; background: var(--surface); border: 1px solid var(--line-strong); border-radius: 15px; box-shadow: 0 7px 24px rgba(24,29,40,.08); }
.editor-composer:focus-within { border-color: #aeb9d5; }
.editor-composer textarea { flex: 1; min-width: 0; max-height: 100px; padding: 9px 3px 5px; resize: none; outline: 0; background: transparent; border: 0; color: var(--text); font-size: .84rem; line-height: 1.45; }
.editor-composer button { display: grid; width: 39px; height: 39px; flex: 0 0 39px; place-items: center; padding: 0; background: var(--accent); border: 0; border-radius: 10px; color: #fff; }
.editor-composer button svg { width: 18px; height: 18px; }
#editorError { width: min(780px,100%); min-height: 16px; margin: 6px auto 0; color: var(--muted); font-size: .67rem; text-align: center; }
#editorError.is-error { color: var(--danger); }

.gate { position: fixed; inset: 0; z-index: 50; display: none; align-items: center; justify-content: center; padding: 20px; background: rgba(247,247,245,.98); }
.gate.show { display: flex; }
.gate-card { width: min(380px,100%); padding: 34px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 18px 45px rgba(24,30,42,.09); text-align: center; }
.gate-mark { margin-bottom: 20px; }
.gate-mark img { display: block; width: min(245px,100%); height: auto; margin: 0 auto; mix-blend-mode: multiply; }
.gate-card h2 { margin: 0 0 7px; font-size: 1.05rem; }
.gate-card p { margin: 0 0 20px; color: var(--muted); font-size: .82rem; }
.gate-card input { width: 100%; padding: 12px 13px; outline: 0; border: 1px solid var(--line-strong); border-radius: 9px; text-align: center; }
.gate-card button { width: 100%; margin-top: 10px; padding: 12px; background: var(--accent); border: 0; border-radius: 9px; color: #fff; }
.gate-err { min-height: 1.2em; margin-top: 9px; color: var(--danger); font-size: .76rem; }

@keyframes pulse { 0%,100% { box-shadow: 0 0 0 0 rgba(180,35,24,.18); } 50% { box-shadow: 0 0 0 5px rgba(180,35,24,0); } }
@keyframes loading-breathe { 0%,100% { opacity: .52; transform: scale(.985); } 50% { opacity: 1; transform: scale(1); } }
@keyframes loading-slide { 0% { transform: translateX(-120%); } 50% { transform: translateX(95%); } 100% { transform: translateX(295%); } }
@keyframes spin { to { transform: rotate(360deg); } }

@media (max-width: 900px) {
  body { overflow: auto; }
  .workspace { grid-template-columns: 1fr; grid-template-rows: auto minmax(0,1fr); }
  .sidebar { min-height: 0; padding: 10px 13px; overflow: visible; border-right: 0; border-bottom: 1px solid var(--line); }
  .brand-block { display: flex; align-items: center; justify-content: space-between; padding: 0 2px 8px; }
  .brand { width: 132px; }
  .brand-block p { margin: 0; font-size: .68rem; }
  .new-task { position: absolute; top: 9px; right: 13px; width: 38px; min-height: 38px; margin: 0; padding: 0; }
  .new-task span { display: none; }
  .brand-block p { display: none; }
  .category-nav { display: flex; gap: 5px; max-height: none; overflow-x: auto; overflow-y: visible; border-top: 1px solid var(--line); padding-top: 7px; }
  .category { position: relative; flex: 0 0 auto; padding: 0; border: 0; }
  .category-toggle { grid-template-columns: 25px auto; min-height: 38px; padding: 4px 8px 4px 5px; }
  .category-icon { width: 25px; height: 25px; }
  .category-icon svg { width: 14px; height: 14px; }
  .category-chevron { display: none; }
  .category-tools { position: absolute; top: calc(100% + 5px); left: 0; z-index: 12; width: 190px; padding: 7px; background: var(--surface); border: 1px solid var(--line); border-radius: 11px; box-shadow: var(--shadow); }
  .category.is-open:not(:hover):not(:focus-within) .category-tools { display: none; }
  .history-panel, .sidebar-note { display: none; }
  .chat-shell { height: calc(100vh - 107px); }
  .chat-header { min-height: 62px; padding: 9px 17px; }
  .chat-messages.has-history { width: calc(100% - 34px); padding-top: 27px; }
  .chat-messages.is-empty { padding: 30px 18px; }
  .welcome-panel h2 { font-size: clamp(1.75rem,7vw,2.35rem); }
  .suggestions { width: min(520px,100%); margin-right: auto; margin-left: auto; }
  .composer-area { padding: 8px 13px 12px; }
  .editor-toolbar { align-items: flex-start; padding: 9px 11px; }
  .editor-title-wrap h2, .editor-title-wrap p { display: none; }
  .editor-actions { max-width: calc(100vw - 58px); overflow-x: auto; }
  .editor-action { flex: 0 0 auto; }
  .editor-stage { padding: 18px 14px; }
  .editor-image-frame img { max-width: 92vw; max-height: calc(100vh - 215px); }
}

@media (max-width: 560px) {
  .sidebar { padding-right: 9px; padding-left: 9px; }
  .brand { width: 114px; }
  .new-task { right: 9px; }
  .category-toggle { font-size: .78rem; }
  .chat-shell { height: calc(100vh - 101px); }
  .chat-header { display: none; }
  .chat-messages.has-history { width: calc(100% - 22px); padding: 20px 0 12px; }
  .chat-messages.is-empty { padding: 22px 13px; }
  .welcome-text { margin-top: 12px; font-size: .85rem; }
  .suggestions { grid-template-columns: 1fr; gap: 7px; margin-top: 22px; }
  .suggestions button { min-height: 55px; }
  .composer-area { padding-right: 8px; padding-left: 8px; }
  .composer { min-height: 58px; padding: 7px 7px 7px 11px; }
  .voice-button, .send-button { width: 39px; height: 39px; flex-basis: 39px; }
  .generation-card { width: 100%; }
  .generation-preview { height: 220px; }
  .media-content { max-width: 100%; }
  .editor-action span { display: none; }
  .editor-action { width: 36px; justify-content: center; padding: 0; }
  .ratio-menu { right: -80px; }
  .selection-actions { bottom: 100px; width: calc(100% - 24px); justify-content: center; flex-wrap: wrap; }
  .selection-actions span { width: 100%; text-align: center; }
  .editor-footer { padding: 8px 8px 12px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}
