File size: 5,424 Bytes
102e23b | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 | @tailwind base;
@tailwind components;
@tailwind utilities;
/* ===== CSS Custom Properties ===== */
:root {
--vh: 1vh;
--color-bg-primary: #0f172a;
--color-bg-secondary: #1e293b;
--color-bg-tertiary: #334155;
--color-text-primary: #f8fafc;
--color-text-secondary: #94a3b8;
--color-accent: #3b82f6;
--color-accent-secondary: #10b981;
--color-danger: #ef4444;
--color-warning: #f59e0b;
--safe-area-top: env(safe-area-inset-top, 0px);
--safe-area-bottom: env(safe-area-inset-bottom, 0px);
--safe-area-left: env(safe-area-inset-left, 0px);
--safe-area-right: env(safe-area-inset-right, 0px);
}
/* ===== Base Styles ===== */
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
html {
-webkit-text-size-adjust: 100%;
-webkit-tap-highlight-color: transparent;
}
body {
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
'Helvetica Neue', Arial, sans-serif;
background-color: var(--color-bg-primary);
color: var(--color-text-primary);
overflow: hidden;
overscroll-behavior: none;
}
/* ===== Mobile Viewport Height Fix (iOS Safari) ===== */
.h-screen-safe {
height: calc(var(--vh, 1vh) * 100);
}
/* ===== Safe Area Padding ===== */
.pt-safe {
padding-top: var(--safe-area-top);
}
.pb-safe {
padding-bottom: var(--safe-area-bottom);
}
.pl-safe {
padding-left: var(--safe-area-left);
}
.pr-safe {
padding-right: var(--safe-area-right);
}
/* ===== Prevent Zoom on Input Focus (iOS) ===== */
input,
textarea,
select {
font-size: 16px !important;
}
/* ===== Touch Targets (Apple HIG: 44x44px minimum) ===== */
.touch-target {
min-height: 44px;
min-width: 44px;
display: flex;
align-items: center;
justify-content: center;
}
/* ===== Smooth Scrolling ===== */
.scroll-smooth {
-webkit-overflow-scrolling: touch;
scroll-behavior: smooth;
}
/* ===== Custom Scrollbar ===== */
::-webkit-scrollbar {
width: 6px;
height: 6px;
}
::-webkit-scrollbar-track {
background: transparent;
}
::-webkit-scrollbar-thumb {
background: #475569;
border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
background: #64748b;
}
/* ===== Selection Style ===== */
::selection {
background-color: rgba(59, 130, 246, 0.3);
color: #f8fafc;
}
/* ===== RTL Support ===== */
[dir='rtl'] .sidebar-nav {
right: 0;
left: auto;
}
[dir='rtl'] .message-user {
margin-left: 0;
margin-right: auto;
}
[dir='rtl'] .message-bot {
margin-right: 0;
margin-left: auto;
}
[dir='rtl'] .chat-input-area {
flex-direction: row-reverse;
}
/* ===== Sidebar Menu Popup ===== */
.desktop-sidebar {
overflow: visible !important;
}
/* ===== Animation Utilities ===== */
.animate-delay-100 {
animation-delay: 100ms;
}
.animate-delay-200 {
animation-delay: 200ms;
}
.animate-delay-300 {
animation-delay: 300ms;
}
/* ===== Typing Indicator ===== */
.typing-dot {
width: 8px;
height: 8px;
border-radius: 50%;
background-color: #64748b;
animation: pulseDot 1.4s infinite ease-in-out both;
}
.typing-dot:nth-child(1) {
animation-delay: -0.32s;
}
.typing-dot:nth-child(2) {
animation-delay: -0.16s;
}
/* ===== Message Markdown Rendering ===== */
.message-content p {
margin-bottom: 0.5rem;
}
.message-content p:last-child {
margin-bottom: 0;
}
.message-content ul,
.message-content ol {
padding-left: 1.5rem;
margin-bottom: 0.5rem;
}
.message-content li {
margin-bottom: 0.25rem;
}
.message-content code {
background-color: rgba(71, 85, 105, 0.5);
padding: 0.125rem 0.375rem;
border-radius: 0.25rem;
font-size: 0.875rem;
}
.message-content pre {
background-color: rgba(15, 23, 42, 0.8);
padding: 0.75rem;
border-radius: 0.5rem;
overflow-x: auto;
margin-bottom: 0.5rem;
}
.message-content pre code {
background: none;
padding: 0;
}
.message-content strong {
font-weight: 600;
color: #f1f5f9;
}
.message-content h3,
.message-content h4 {
font-weight: 600;
margin-top: 0.75rem;
margin-bottom: 0.375rem;
}
/* ===== Swipe Sheet ===== */
.swipe-sheet {
transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
will-change: transform;
}
/* ===== Bottom Navigation ===== */
.bottom-nav {
backdrop-filter: blur(12px);
-webkit-backdrop-filter: blur(12px);
background-color: rgba(15, 23, 42, 0.85);
}
/* ===== PWA Standalone Mode ===== */
@media all and (display-mode: standalone) {
body {
-webkit-user-select: none;
user-select: none;
}
.pwa-only {
display: block;
}
.browser-only {
display: none;
}
}
@media not all and (display-mode: standalone) {
.pwa-only {
display: none;
}
}
/* ===== Responsive Breakpoints ===== */
@media (max-width: 768px) {
.desktop-sidebar {
display: none;
}
.desktop-right-panel {
display: none;
}
.mobile-bottom-nav {
display: flex;
}
}
@media (min-width: 769px) {
.mobile-bottom-nav {
display: none;
}
.mobile-header-compact {
display: none;
}
}
/* ===== Emergency Pulse Animation ===== */
@keyframes emergencyPulse {
0%,
100% {
box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.4);
}
50% {
box-shadow: 0 0 0 12px rgba(239, 68, 68, 0);
}
}
.emergency-pulse {
animation: emergencyPulse 2s infinite;
}
/* ===== Voice Recording Indicator ===== */
@keyframes voicePulse {
0%,
100% {
transform: scale(1);
opacity: 1;
}
50% {
transform: scale(1.2);
opacity: 0.7;
}
}
.voice-recording {
animation: voicePulse 1s infinite;
}
|