Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.

571 rinda
10KB

  1. .chatroom-container {
  2. display: flex;
  3. flex-direction: column;
  4. height: 100%;
  5. background: var(--bg-light);
  6. }
  7. .chatroom-messages {
  8. flex: 1;
  9. overflow-y: auto;
  10. padding: 2rem;
  11. display: flex;
  12. flex-direction: column;
  13. gap: 1.5rem;
  14. }
  15. .chatroom-messages::-webkit-scrollbar {
  16. width: 8px;
  17. }
  18. .chatroom-messages::-webkit-scrollbar-track {
  19. background: transparent;
  20. }
  21. .chatroom-messages::-webkit-scrollbar-thumb {
  22. background: var(--secondary);
  23. border-radius: 4px;
  24. }
  25. .chatroom-messages::-webkit-scrollbar-thumb:hover {
  26. background: var( --third-color);
  27. }
  28. .chatroom-empty {
  29. display: flex;
  30. flex-direction: column;
  31. align-items: center;
  32. justify-content: center;
  33. height: 100%;
  34. color: var(--text-light);
  35. text-align: center;
  36. }
  37. .empty-icon {
  38. font-size: 4rem;
  39. color: var(--secondary);
  40. margin-bottom: 1rem;
  41. opacity: 0.5;
  42. }
  43. .chatroom-empty h3 {
  44. font-size: 1.5rem;
  45. color: var(--text-dark);
  46. margin-bottom: 0.5rem;
  47. }
  48. .chatroom-empty p {
  49. font-size: 1rem;
  50. margin: 0;
  51. }
  52. /* Messages */
  53. .message-row {
  54. display: flex;
  55. align-items: flex-start;
  56. gap: 0.75rem;
  57. animation: fadeIn 0.3s ease;
  58. }
  59. @keyframes fadeIn {
  60. from {
  61. opacity: 0;
  62. transform: translateY(10px);
  63. }
  64. to {
  65. opacity: 1;
  66. transform: translateY(0);
  67. }
  68. }
  69. .message-row.user {
  70. flex-direction: row-reverse;
  71. justify-content: flex-start;
  72. }
  73. .message-row.assistant {
  74. flex-direction: row;
  75. justify-content: flex-start;
  76. }
  77. .avatar {
  78. width: 40px;
  79. height: 40px;
  80. border-radius: 50%;
  81. display: flex;
  82. align-items: center;
  83. justify-content: center;
  84. flex-shrink: 0;
  85. }
  86. .avatar-user {
  87. background: linear-gradient(135deg, var(--secondary) 0%, var( --third-color) 100%);
  88. color: white;
  89. }
  90. .avatar-assistant {
  91. background: linear-gradient(135deg, var( --contrast) 0%, #e02851 100%);
  92. color: white;
  93. }
  94. .message-content-wrapper {
  95. display: flex;
  96. flex-direction: column;
  97. max-width: 70%;
  98. gap: 0.5rem;
  99. }
  100. .message-row.user .message-content-wrapper {
  101. align-items: flex-end;
  102. }
  103. .message-row.assistant .message-content-wrapper {
  104. align-items: flex-start;
  105. }
  106. .bubble {
  107. padding: 1rem 1.25rem;
  108. border-radius: 16px;
  109. font-size: 1rem;
  110. line-height: 1.6;
  111. word-wrap: break-word;
  112. white-space: pre-wrap;
  113. }
  114. .bubble-user {
  115. background: linear-gradient(135deg, var(--secondary) 0%, var( --third-color) 100%);
  116. color: white;
  117. border-bottom-right-radius: 4px;
  118. }
  119. .bubble-assistant {
  120. background: white;
  121. color: var(--text-dark);
  122. box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  123. border-bottom-left-radius: 4px;
  124. }
  125. .message-actions {
  126. display: flex;
  127. gap: 0.5rem;
  128. }
  129. .btn-message-action {
  130. width: 32px;
  131. height: 32px;
  132. border-radius: 6px;
  133. border: none;
  134. background: transparent;
  135. color: var(--text-light);
  136. cursor: pointer;
  137. display: flex;
  138. align-items: center;
  139. justify-content: center;
  140. transition: all 0.2s ease;
  141. }
  142. .btn-message-action:hover {
  143. background: var(--bg-light);
  144. color: var( --third-color);
  145. }
  146. .typing-indicator {
  147. display: flex;
  148. gap: 0.4rem;
  149. padding: 0.5rem 0;
  150. }
  151. .typing-indicator span {
  152. width: 8px;
  153. height: 8px;
  154. border-radius: 50%;
  155. background-color: var(--secondary);
  156. animation: typing 1.4s infinite;
  157. }
  158. .typing-indicator span:nth-child(2) {
  159. animation-delay: 0.2s;
  160. }
  161. .typing-indicator span:nth-child(3) {
  162. animation-delay: 0.4s;
  163. }
  164. @keyframes typing {
  165. 0%, 60%, 100% {
  166. transform: translateY(0);
  167. opacity: 0.7;
  168. }
  169. 30% {
  170. transform: translateY(-10px);
  171. opacity: 1;
  172. }
  173. }
  174. .chat-input-container {
  175. width: 100%;
  176. padding: 16px 24px;
  177. background: transparent;
  178. display: flex;
  179. flex-direction: column;
  180. justify-content: center;
  181. position: relative;
  182. }
  183. /* Fichiers attachés */
  184. .attached-files {
  185. display: flex;
  186. flex-wrap: wrap;
  187. gap: 8px;
  188. padding: 12px 16px;
  189. max-width: 1000px;
  190. margin: 0 auto;
  191. width: 100%;
  192. }
  193. .file-item {
  194. display: flex;
  195. align-items: center;
  196. gap: 8px;
  197. padding: 8px 12px;
  198. background: #ffffff;
  199. border: 1px solid var(--border);
  200. border-radius: 8px;
  201. max-width: 32%;
  202. transition: all 0.2s ease;
  203. animation: fileSlideIn 0.3s ease;
  204. }
  205. .file-item:hover {
  206. border-color: #d1d5db;
  207. box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  208. }
  209. .file-preview {
  210. flex-shrink: 0;
  211. width: 40px;
  212. height: 40px;
  213. border-radius: 6px;
  214. overflow: hidden;
  215. background: #ffffff;
  216. display: flex;
  217. align-items: center;
  218. justify-content: center;
  219. border: 1px solid var(--border);
  220. }
  221. .file-icon {
  222. font-size: 20px;
  223. color: var(--secondary);
  224. }
  225. .file-info {
  226. flex: 1;
  227. min-width: 0;
  228. display: flex;
  229. flex-direction: column;
  230. gap: 2px;
  231. }
  232. .file-name {
  233. font-size: 13px;
  234. font-weight: 500;
  235. color: #374151;
  236. white-space: nowrap;
  237. overflow: hidden;
  238. text-overflow: ellipsis;
  239. }
  240. .file-size {
  241. font-size: 11px;
  242. color: #9ca3af;
  243. }
  244. .remove-file-button {
  245. flex-shrink: 0;
  246. width: 24px;
  247. height: 24px;
  248. display: flex;
  249. align-items: center;
  250. justify-content: center;
  251. background: transparent;
  252. border: none;
  253. border-radius: 4px;
  254. color: #9ca3af;
  255. cursor: pointer;
  256. transition: all 0.2s ease;
  257. }
  258. .remove-file-button:hover {
  259. background: #fee2e2;
  260. color: #ef4444;
  261. }
  262. @keyframes fileSlideIn {
  263. from {
  264. opacity: 0;
  265. transform: translateY(-10px);
  266. }
  267. to {
  268. opacity: 1;
  269. transform: translateY(0);
  270. }
  271. }
  272. /* Input wrapper */
  273. .input-wrapper {
  274. width: 100%;
  275. max-width: 1000px;
  276. margin: 0 auto;
  277. background: #ffffff;
  278. border: 1px solid var(--border);
  279. border-radius: 16px;
  280. padding: 16px 20px;
  281. display: flex;
  282. flex-direction: column;
  283. gap: 12px;
  284. box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  285. transition: all 0.2s ease;
  286. }
  287. .input-wrapper.has-files {
  288. border-radius: 0 0 16px 16px;
  289. border-top: none;
  290. padding-top: 12px;
  291. }
  292. .input-wrapper:focus-within {
  293. border-color: var(--secondary);
  294. box-shadow: 0 4px 12px rgba(41, 132, 161, 0.12);
  295. }
  296. .input-wrapper textarea {
  297. width: 100%;
  298. border: none;
  299. outline: none;
  300. resize: none;
  301. font-size: 15px;
  302. font-family: inherit;
  303. color: #1f2937;
  304. background: transparent;
  305. min-height: 24px;
  306. max-height: 200px;
  307. line-height: 1.5;
  308. padding: 0;
  309. }
  310. .input-wrapper textarea::placeholder {
  311. color: #9ca3af;
  312. }
  313. .input-wrapper textarea:disabled {
  314. opacity: 0.6;
  315. cursor: not-allowed;
  316. }
  317. /* Actions row */
  318. .actions-row {
  319. display: flex;
  320. justify-content: space-between;
  321. align-items: center;
  322. padding-top: 4px;
  323. }
  324. .attach-button {
  325. display: flex;
  326. align-items: center;
  327. gap: 8px;
  328. padding: 0;
  329. background: transparent;
  330. border: none;
  331. color: #6b7280;
  332. cursor: pointer;
  333. font-size: 13px;
  334. font-weight: 500;
  335. transition: color 0.2s ease;
  336. }
  337. .attach-button:hover {
  338. color: var(--secondary);
  339. }
  340. .attach-button span {
  341. display: none;
  342. }
  343. @media (min-width: 640px) {
  344. .attach-button span {
  345. display: inline;
  346. }
  347. }
  348. .right-actions {
  349. display: flex;
  350. align-items: center;
  351. gap: 8px;
  352. }
  353. .domain-select {
  354. padding: 6px 12px;
  355. border: 1px solid var(--border);
  356. border-radius: 8px;
  357. background: white;
  358. color: var(--text-dark);
  359. font-size: 13px;
  360. cursor: pointer;
  361. transition: all 0.2s ease;
  362. }
  363. .domain-select:hover {
  364. border-color: var(--secondary);
  365. }
  366. .domain-select:focus {
  367. outline: none;
  368. border-color: var(--secondary);
  369. box-shadow: 0 0 0 3px rgba(41, 132, 161, 0.1);
  370. }
  371. .voice-button {
  372. display: flex;
  373. align-items: center;
  374. justify-content: center;
  375. width: 36px;
  376. height: 36px;
  377. background: transparent;
  378. border: none;
  379. color: #6b7280;
  380. cursor: pointer;
  381. border-radius: 8px;
  382. transition: all 0.2s ease;
  383. }
  384. .voice-button:hover {
  385. background: #f3f4f6;
  386. color: var(--text-dark);
  387. }
  388. .send-button {
  389. display: flex;
  390. align-items: center;
  391. justify-content: center;
  392. width: 36px;
  393. height: 36px;
  394. background: var( --contrast);
  395. border: none;
  396. color: #ffffff;
  397. cursor: pointer;
  398. border-radius: 8px;
  399. transition: all 0.2s ease;
  400. }
  401. .send-button:hover:not(:disabled) {
  402. transform: scale(1.05);
  403. box-shadow: 0 4px 12px rgba(246, 62, 99, 0.3);
  404. }
  405. .send-button:active:not(:disabled) {
  406. transform: scale(0.98);
  407. }
  408. .send-button:disabled {
  409. background: #e5e7eb;
  410. cursor: not-allowed;
  411. opacity: 0.6;
  412. }
  413. .send-button:disabled svg {
  414. color: #9ca3af;
  415. }
  416. @media (max-width: 768px) {
  417. .chatroom-messages {
  418. padding: 1rem;
  419. }
  420. .message-content-wrapper {
  421. max-width: 85%;
  422. }
  423. .chat-input-container {
  424. padding: 12px 16px;
  425. }
  426. .attached-files {
  427. padding: 10px 12px;
  428. gap: 6px;
  429. }
  430. .file-item {
  431. padding: 6px 10px;
  432. max-width: 200px;
  433. }
  434. .file-preview {
  435. width: 36px;
  436. height: 36px;
  437. }
  438. .file-name {
  439. font-size: 12px;
  440. }
  441. .file-size {
  442. font-size: 10px;
  443. }
  444. .remove-file-button {
  445. width: 20px;
  446. height: 20px;
  447. }
  448. .input-wrapper {
  449. padding: 12px 16px;
  450. border-radius: 14px;
  451. }
  452. .input-wrapper.has-files {
  453. border-radius: 0 0 14px 14px;
  454. }
  455. .input-wrapper textarea {
  456. font-size: 14px;
  457. }
  458. .actions-row .right-actions {
  459. gap: 6px;
  460. }
  461. .voice-button,
  462. .send-button {
  463. width: 32px;
  464. height: 32px;
  465. }
  466. .domain-select {
  467. font-size: 12px;
  468. padding: 4px 8px;
  469. }
  470. }
  471. @media (max-width: 480px) {
  472. .bubble {
  473. padding: 0.875rem 1rem;
  474. font-size: 0.95rem;
  475. }
  476. .avatar {
  477. width: 36px;
  478. height: 36px;
  479. }
  480. }