|
122 | 122 | display: flex; |
123 | 123 | align-items: center; |
124 | 124 | justify-content: space-between; |
125 | | - padding: 14px 18px; |
| 125 | + padding: 10px 18px; |
126 | 126 | border-bottom: 1px solid var(--border-color); |
127 | 127 | background: var(--header-bg); |
128 | 128 | flex-shrink: 0; |
| 129 | + min-height: 0; |
129 | 130 | } |
130 | 131 |
|
131 | 132 | .ai-panel-title { |
|
135 | 136 | font-weight: 600; |
136 | 137 | font-size: 15px; |
137 | 138 | color: var(--text-color); |
| 139 | + min-width: 0; |
| 140 | + overflow: hidden; |
138 | 141 | } |
139 | 142 |
|
140 | | -.ai-panel-title i { |
| 143 | +.ai-panel-title > i { |
141 | 144 | font-size: 18px; |
142 | 145 | background: linear-gradient(135deg, #667eea, #764ba2); |
143 | 146 | -webkit-background-clip: text; |
144 | 147 | -webkit-text-fill-color: transparent; |
145 | 148 | background-clip: text; |
| 149 | + flex-shrink: 0; |
| 150 | +} |
| 151 | + |
| 152 | +.ai-panel-title-group { |
| 153 | + display: flex; |
| 154 | + flex-direction: column; |
| 155 | + gap: 1px; |
| 156 | + min-width: 0; |
| 157 | +} |
| 158 | + |
| 159 | +.ai-panel-title-row { |
| 160 | + display: flex; |
| 161 | + align-items: center; |
| 162 | + gap: 8px; |
| 163 | +} |
| 164 | + |
| 165 | +/* Inline status (merged into header) */ |
| 166 | +.ai-header-status { |
| 167 | + font-size: 11px; |
| 168 | + font-weight: 400; |
| 169 | + color: var(--text-color); |
| 170 | + opacity: 0.6; |
| 171 | + display: flex; |
| 172 | + align-items: center; |
| 173 | + gap: 5px; |
| 174 | + white-space: nowrap; |
| 175 | + overflow: hidden; |
| 176 | + text-overflow: ellipsis; |
| 177 | + min-height: 14px; |
| 178 | + transition: opacity 0.2s; |
| 179 | +} |
| 180 | + |
| 181 | +.ai-header-status:empty { |
| 182 | + display: none; |
146 | 183 | } |
147 | 184 |
|
148 | 185 | .ai-badge { |
|
164 | 201 | display: flex; |
165 | 202 | align-items: center; |
166 | 203 | gap: 4px; |
| 204 | + flex-shrink: 0; |
167 | 205 | } |
168 | 206 |
|
169 | 207 | /* Input options row (below textarea) */ |
|
317 | 355 | display: flex; |
318 | 356 | flex-direction: column; |
319 | 357 | gap: 12px; |
| 358 | + justify-content: center; |
| 359 | + align-items: center; |
| 360 | + min-height: 0; |
| 361 | + transition: justify-content 0.3s ease, align-items 0.3s ease; |
| 362 | +} |
| 363 | + |
| 364 | +/* When messages exist, switch to top-aligned scrollable conversation */ |
| 365 | +.ai-chat-area:has(.ai-message) { |
| 366 | + justify-content: flex-start; |
| 367 | + align-items: stretch; |
| 368 | +} |
| 369 | + |
| 370 | +/* ======================================== |
| 371 | + CENTERED INITIAL STATE (Claude-like) |
| 372 | + When welcome message is showing, center |
| 373 | + the greeting + input together in the panel |
| 374 | + ======================================== */ |
| 375 | + |
| 376 | +/* Both areas split remaining flex space equally — |
| 377 | + chat pushes content down, input pushes content up, |
| 378 | + so they meet in the center */ |
| 379 | +.ai-panel:has(.ai-welcome-message) .ai-chat-area { |
| 380 | + flex: 1 1 0; |
| 381 | + justify-content: flex-end; |
| 382 | + align-items: center; |
| 383 | + padding-bottom: 4px; |
| 384 | + overflow-y: hidden; |
| 385 | +} |
| 386 | + |
| 387 | +.ai-panel:has(.ai-welcome-message) .ai-input-area { |
| 388 | + flex: 1 1 0; |
| 389 | + display: flex; |
| 390 | + flex-direction: column; |
| 391 | + justify-content: flex-start; |
| 392 | + align-items: center; |
| 393 | + border-top: none; |
| 394 | + background: transparent; |
| 395 | + padding-top: 8px; |
| 396 | + transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1); |
| 397 | +} |
| 398 | + |
| 399 | +/* Constrain input children width within centered area */ |
| 400 | +.ai-panel:has(.ai-welcome-message) .ai-input-area > .ai-model-selector, |
| 401 | +.ai-panel:has(.ai-welcome-message) .ai-input-area > .ai-attachments-strip, |
| 402 | +.ai-panel:has(.ai-welcome-message) .ai-input-area > .ai-input-wrapper { |
| 403 | + max-width: 440px; |
| 404 | + width: 100%; |
| 405 | +} |
| 406 | + |
| 407 | +/* Style the model selector in centered state */ |
| 408 | +.ai-panel:has(.ai-welcome-message) .ai-input-area > .ai-model-selector { |
| 409 | + max-width: 440px; |
| 410 | + width: 100%; |
| 411 | + order: 1; /* Push below input wrapper */ |
| 412 | + margin-top: 8px; |
| 413 | +} |
| 414 | + |
| 415 | +/* Also hide quick actions in initial state for cleaner look */ |
| 416 | +.ai-panel:has(.ai-welcome-message) .ai-quick-actions { |
| 417 | + display: none; |
320 | 418 | } |
321 | 419 |
|
322 | 420 | .ai-chat-area::-webkit-scrollbar { |
|
557 | 655 | border-top: 1px solid var(--border-color); |
558 | 656 | background: var(--header-bg); |
559 | 657 | flex-shrink: 0; |
| 658 | + transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1); |
560 | 659 | } |
561 | 660 |
|
562 | 661 | /* --- Model Selector --- */ |
|
865 | 964 |
|
866 | 965 | .ai-attach-button i { |
867 | 966 | font-size: 15px; |
868 | | - transform: rotate(-45deg); |
| 967 | + transition: transform 0.2s ease; |
| 968 | +} |
| 969 | + |
| 970 | +/* Rotate '+' to 'x' when menu is open */ |
| 971 | +.ai-attach-wrapper:has(.ai-screenshot-menu.active) .ai-attach-button i { |
| 972 | + transform: rotate(45deg); |
869 | 973 | } |
870 | 974 |
|
871 | 975 | /* --- Attachments Preview Strip --- */ |
|
1531 | 1635 | /* Compact input area on mobile */ |
1532 | 1636 | .ai-input-area { |
1533 | 1637 | padding: 8px 10px; |
| 1638 | + padding-bottom: max(8px, env(safe-area-inset-bottom)); |
1534 | 1639 | } |
1535 | 1640 |
|
1536 | 1641 | /* --- Merge model selector into chat bar on mobile --- */ |
|
1641 | 1746 | .ai-action-chip i { |
1642 | 1747 | font-size: 11px; |
1643 | 1748 | } |
| 1749 | + |
| 1750 | + /* Mobile centered initial state overrides */ |
| 1751 | + .ai-panel:has(.ai-welcome-message) .ai-input-area { |
| 1752 | + padding: 8px 10px; |
| 1753 | + padding-bottom: max(8px, env(safe-area-inset-bottom)); |
| 1754 | + } |
| 1755 | + |
| 1756 | + .ai-panel:has(.ai-welcome-message) .ai-input-area > .ai-input-wrapper { |
| 1757 | + max-width: 100%; |
| 1758 | + } |
| 1759 | + |
| 1760 | + /* Reset model selector absolute positioning in centered state */ |
| 1761 | + .ai-panel:has(.ai-welcome-message) .ai-model-selector { |
| 1762 | + position: relative; |
| 1763 | + left: auto; |
| 1764 | + bottom: auto; |
| 1765 | + right: auto; |
| 1766 | + } |
1644 | 1767 | } |
1645 | 1768 |
|
1646 | | -/* --- AI Status Indicator (in-panel) --- */ |
| 1769 | +/* --- AI Status Indicator (in-panel) --- |
| 1770 | + Regular status now shown inline in header. |
| 1771 | + Download progress bar still uses standalone bar. */ |
1647 | 1772 | .ai-status-bar { |
1648 | 1773 | padding: 8px 16px; |
1649 | 1774 | font-size: 12px; |
1650 | 1775 | color: var(--text-color); |
1651 | 1776 | opacity: 0.6; |
1652 | | - display: flex; |
| 1777 | + display: none; /* Hidden by default — only shown for downloads */ |
1653 | 1778 | align-items: center; |
1654 | 1779 | gap: 6px; |
1655 | 1780 | border-bottom: 1px solid var(--border-color); |
|
1658 | 1783 | } |
1659 | 1784 |
|
1660 | 1785 | .ai-status-bar.downloading { |
| 1786 | + display: flex; /* Override default display:none for downloads */ |
1661 | 1787 | opacity: 1; |
1662 | 1788 | flex-direction: column; |
1663 | 1789 | align-items: stretch; |
|
0 commit comments