您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

828 行
15KB

  1. @keyframes fadeIn {
  2. from {
  3. opacity: 0;
  4. transform: translateY(10px);
  5. }
  6. to {
  7. opacity: 1;
  8. transform: translateY(0);
  9. }
  10. }
  11. @keyframes fileSlideIn {
  12. from {
  13. opacity: 0;
  14. transform: translateY(-10px);
  15. }
  16. to {
  17. opacity: 1;
  18. transform: translateY(0);
  19. }
  20. }
  21. @keyframes typing {
  22. 0%, 60%, 100% {
  23. transform: translateY(0);
  24. opacity: 0.7;
  25. }
  26. 30% {
  27. transform: translateY(-10px);
  28. opacity: 1;
  29. }
  30. }
  31. @keyframes checkPop {
  32. 0% {
  33. transform: scale(0);
  34. }
  35. 50% {
  36. transform: scale(1.2);
  37. }
  38. 100% {
  39. transform: scale(1);
  40. }
  41. }
  42. @keyframes pulse {
  43. from {
  44. opacity: 1;
  45. }
  46. to {
  47. opacity: 0.6;
  48. }
  49. }
  50. /* Boutons d'action */
  51. .attach-button,
  52. .voice-button {
  53. display: flex;
  54. align-items: center;
  55. justify-content: center;
  56. background: transparent;
  57. border: none;
  58. color: #6b7280;
  59. cursor: pointer;
  60. border-radius: 8px;
  61. transition: all 0.2s ease;
  62. }
  63. .attach-button {
  64. gap: 8px;
  65. padding: 0;
  66. font-size: 13px;
  67. font-weight: 500;
  68. }
  69. .attach-button span {
  70. display: none;
  71. }
  72. .attach-button:hover {
  73. color: var(--secondary);
  74. }
  75. .voice-button {
  76. width: 36px;
  77. height: 36px;
  78. }
  79. .voice-button:hover {
  80. background: #f3f4f6;
  81. color: var(--text-dark);
  82. }
  83. .send-button {
  84. display: flex;
  85. align-items: center;
  86. justify-content: center;
  87. width: 36px;
  88. height: 36px;
  89. background: var(--contrast);
  90. border: none;
  91. color: #ffffff;
  92. cursor: pointer;
  93. border-radius: 8px;
  94. transition: all 0.2s ease;
  95. }
  96. .send-button:hover:not(:disabled) {
  97. transform: scale(1.05);
  98. box-shadow: 0 4px 12px rgba(246, 62, 99, 0.3);
  99. }
  100. .send-button:active:not(:disabled) {
  101. transform: scale(0.98);
  102. }
  103. .send-button:disabled {
  104. background: #e5e7eb;
  105. cursor: not-allowed;
  106. opacity: 0.6;
  107. }
  108. .send-button:disabled svg {
  109. color: #9ca3af;
  110. }
  111. /* Gestion des fichiers */
  112. .file-item {
  113. display: flex;
  114. align-items: center;
  115. gap: 8px;
  116. padding: 8px 12px;
  117. background: #ffffff;
  118. border: 1px solid var(--border);
  119. border-radius: 8px;
  120. transition: all 0.2s ease;
  121. }
  122. .file-item:hover {
  123. border-color: #d1d5db;
  124. box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  125. }
  126. .file-preview {
  127. flex-shrink: 0;
  128. width: 40px;
  129. height: 40px;
  130. border-radius: 6px;
  131. overflow: hidden;
  132. background: #ffffff;
  133. display: flex;
  134. align-items: center;
  135. justify-content: center;
  136. border: 1px solid var(--border);
  137. }
  138. .file-icon {
  139. font-size: 20px;
  140. color: var(--secondary);
  141. }
  142. .file-info {
  143. flex: 1;
  144. min-width: 0;
  145. display: flex;
  146. flex-direction: column;
  147. gap: 2px;
  148. }
  149. .file-name {
  150. font-size: 13px;
  151. font-weight: 500;
  152. color: #374151;
  153. white-space: nowrap;
  154. overflow: hidden;
  155. text-overflow: ellipsis;
  156. }
  157. .file-size {
  158. font-size: 11px;
  159. color: #9ca3af;
  160. }
  161. .remove-file-button {
  162. flex-shrink: 0;
  163. width: 24px;
  164. height: 24px;
  165. display: flex;
  166. align-items: center;
  167. justify-content: center;
  168. background: transparent;
  169. border: none;
  170. border-radius: 4px;
  171. color: #9ca3af;
  172. cursor: pointer;
  173. transition: all 0.2s ease;
  174. }
  175. .remove-file-button:hover {
  176. background: #fee2e2;
  177. color: #ef4444;
  178. }
  179. /* Wrapper d'input universel */
  180. .input-wrapper {
  181. background: white;
  182. border: 1px solid var(--border);
  183. border-radius: 16px;
  184. padding: 16px 20px;
  185. display: flex;
  186. flex-direction: column;
  187. gap: 12px;
  188. box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  189. transition: all 0.2s ease;
  190. }
  191. .input-wrapper.has-files {
  192. border-radius: 0 0 16px 16px;
  193. border-top: none;
  194. }
  195. .input-wrapper:focus-within {
  196. border-color: var(--secondary);
  197. box-shadow: 0 4px 12px rgba(41, 132, 161, 0.12);
  198. }
  199. .input-wrapper textarea {
  200. width: 100%;
  201. border: none;
  202. outline: none;
  203. resize: none;
  204. font-size: 15px;
  205. font-family: inherit;
  206. color: var(--text-dark);
  207. background: transparent;
  208. min-height: 24px;
  209. max-height: 200px;
  210. line-height: 1.5;
  211. padding: 0;
  212. }
  213. .input-wrapper textarea::placeholder {
  214. color: #9ca3af;
  215. }
  216. .input-wrapper textarea:disabled {
  217. opacity: 0.6;
  218. cursor: not-allowed;
  219. }
  220. .home-container {
  221. display: flex;
  222. flex-direction: column;
  223. align-items: center;
  224. justify-content: center;
  225. }
  226. .home-content {
  227. width: 100%;
  228. max-width: 1200px;
  229. display: flex;
  230. flex-direction: column;
  231. gap: 3rem;
  232. }
  233. /* Section bienvenue */
  234. .welcome-section {
  235. text-align: center;
  236. margin-bottom: 1rem;
  237. }
  238. .welcome-title {
  239. font-size: 2.5rem;
  240. font-weight: 700;
  241. color: var(--text-dark);
  242. margin-bottom: 0.5rem;
  243. }
  244. .welcome-subtitle {
  245. font-size: 1.25rem;
  246. color: var(--text-light);
  247. margin: 0;
  248. }
  249. /* Zone de saisie Home */
  250. .input-container {
  251. width: 100%;
  252. margin: 0 auto;
  253. }
  254. .input-files {
  255. display: flex;
  256. flex-wrap: wrap;
  257. gap: 8px;
  258. padding: 12px 16px;
  259. background: white;
  260. border: 1px solid var(--border);
  261. border-radius: 16px 16px 0 0;
  262. margin-bottom: -1px;
  263. }
  264. /* Variantes spécifiques pour Home */
  265. .input-files .file-item {
  266. background: #f9fafb;
  267. max-width: 45%;
  268. animation: fileSlideIn 0.3s ease;
  269. }
  270. .input-files .file-preview {
  271. width: 36px;
  272. height: 36px;
  273. }
  274. .input-files .file-icon {
  275. font-size: 18px;
  276. }
  277. .input-actions {
  278. display: flex;
  279. justify-content: space-between;
  280. align-items: center;
  281. padding-top: 4px;
  282. }
  283. .input-right-actions {
  284. display: flex;
  285. align-items: center;
  286. gap: 8px;
  287. }
  288. /* Cartes des agents */
  289. .agents-grid {
  290. display: grid;
  291. grid-template-columns: repeat(auto-fit, minmax(480px, 1fr));
  292. gap: 1.5rem;
  293. margin-top: 1rem;
  294. }
  295. .agent-card {
  296. position: relative;
  297. background: white;
  298. border: 2px solid var(--border);
  299. border-radius: 12px;
  300. padding: 1.5rem;
  301. display: flex;
  302. gap: 1rem;
  303. cursor: pointer;
  304. transition: all 0.2s ease;
  305. }
  306. .agent-card input[type="radio"] {
  307. position: absolute;
  308. opacity: 0;
  309. pointer-events: none;
  310. }
  311. .agent-card:hover {
  312. border-color: var(--secondary);
  313. box-shadow: 0 4px 12px rgba(41, 132, 161, 0.15);
  314. transform: translateY(-2px);
  315. }
  316. .agent-card.selected {
  317. border-color: var(--secondary);
  318. background: linear-gradient(135deg, rgba(41, 132, 161, 0.05) 0%, rgba(57, 181, 221, 0.05) 100%);
  319. box-shadow: 0 4px 12px rgba(41, 132, 161, 0.2);
  320. }
  321. .agent-card.selected .agent-icon {
  322. background: linear-gradient(135deg, var(--secondary) 0%, var(--third-color) 100%);
  323. box-shadow: 0 4px 12px rgba(41, 132, 161, 0.3);
  324. }
  325. .agent-card .agent-check {
  326. position: absolute;
  327. top: 1rem;
  328. right: 1rem;
  329. width: 24px;
  330. height: 24px;
  331. border-radius: 50%;
  332. background: var(--secondary);
  333. color: white;
  334. display: none;
  335. align-items: center;
  336. justify-content: center;
  337. }
  338. .agent-card.selected .agent-check {
  339. display: flex;
  340. animation: checkPop 0.3s ease;
  341. }
  342. .agent-icon {
  343. flex-shrink: 0;
  344. width: 48px;
  345. height: 48px;
  346. border-radius: 10px;
  347. background: linear-gradient(135deg, var(--secondary) 0%, var(--third-color) 100%);
  348. color: white;
  349. display: flex;
  350. align-items: center;
  351. justify-content: center;
  352. }
  353. .agent-content {
  354. flex: 1;
  355. }
  356. .agent-name {
  357. font-size: 1.125rem;
  358. font-weight: 600;
  359. color: var(--text-dark);
  360. margin: 0 0 0.5rem 0;
  361. }
  362. .agent-description {
  363. font-size: 0.9rem;
  364. color: var(--text-light);
  365. line-height: 1.5;
  366. margin: 0;
  367. }
  368. .chatroom-container {
  369. display: flex;
  370. flex-direction: column;
  371. height: 100%;
  372. }
  373. .chatroom-messages {
  374. flex: 1;
  375. overflow-y: auto;
  376. padding: 2rem;
  377. display: flex;
  378. flex-direction: column;
  379. gap: 1.5rem;
  380. }
  381. .chatroom-messages::-webkit-scrollbar {
  382. width: 8px;
  383. }
  384. .chatroom-messages::-webkit-scrollbar-track {
  385. background: transparent;
  386. }
  387. .chatroom-messages::-webkit-scrollbar-thumb {
  388. background: var(--secondary);
  389. border-radius: 4px;
  390. }
  391. .chatroom-messages::-webkit-scrollbar-thumb:hover {
  392. background: var(--third-color);
  393. }
  394. .chatroom-empty {
  395. display: flex;
  396. flex-direction: column;
  397. align-items: center;
  398. justify-content: center;
  399. height: 100%;
  400. color: var(--text-light);
  401. text-align: center;
  402. }
  403. .chatroom-empty h3 {
  404. font-size: 1.5rem;
  405. color: var(--text-dark);
  406. margin-bottom: 0.5rem;
  407. }
  408. .chatroom-empty p {
  409. font-size: 1rem;
  410. margin: 0;
  411. }
  412. .empty-icon {
  413. font-size: 4rem;
  414. color: var(--secondary);
  415. margin-bottom: 1rem;
  416. opacity: 0.5;
  417. }
  418. /* Messages */
  419. .message-row {
  420. display: flex;
  421. align-items: flex-start;
  422. gap: 0.75rem;
  423. animation: fadeIn 0.3s ease;
  424. }
  425. .message-row.user {
  426. flex-direction: row-reverse;
  427. justify-content: flex-start;
  428. }
  429. .message-row.assistant {
  430. flex-direction: row;
  431. justify-content: flex-start;
  432. }
  433. .avatar {
  434. width: 40px;
  435. height: 40px;
  436. border-radius: 50%;
  437. display: flex;
  438. align-items: center;
  439. justify-content: center;
  440. flex-shrink: 0;
  441. }
  442. .avatar-user {
  443. background: linear-gradient(135deg, var(--secondary) 0%, var(--third-color) 100%);
  444. color: white;
  445. }
  446. .avatar-assistant {
  447. background: linear-gradient(135deg, var(--contrast) 0%, #e02851 100%);
  448. color: white;
  449. }
  450. .message-content-wrapper {
  451. display: flex;
  452. flex-direction: column;
  453. max-width: 70%;
  454. gap: 0.5rem;
  455. }
  456. .message-row.user .message-content-wrapper {
  457. align-items: flex-end;
  458. }
  459. .message-row.assistant .message-content-wrapper {
  460. align-items: flex-start;
  461. }
  462. .bubble {
  463. padding: 1rem 1.25rem;
  464. border-radius: 16px;
  465. font-size: 1rem;
  466. line-height: 1.6;
  467. word-wrap: break-word;
  468. white-space: pre-wrap;
  469. }
  470. .bubble-user {
  471. background: linear-gradient(135deg, var(--secondary) 0%, var(--third-color) 100%);
  472. color: white;
  473. border-bottom-right-radius: 4px;
  474. }
  475. .bubble-assistant {
  476. background: white;
  477. color: var(--text-dark);
  478. box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  479. border-bottom-left-radius: 4px;
  480. }
  481. .message-actions {
  482. display: flex;
  483. gap: 0.5rem;
  484. }
  485. .btn-message-action {
  486. width: 32px;
  487. height: 32px;
  488. border-radius: 6px;
  489. border: none;
  490. background: transparent;
  491. color: var(--text-light);
  492. cursor: pointer;
  493. display: flex;
  494. align-items: center;
  495. justify-content: center;
  496. transition: all 0.2s ease;
  497. }
  498. .btn-message-action:hover {
  499. background: var(--bg-light);
  500. color: var(--third-color);
  501. }
  502. /* Indicateur de frappe */
  503. .typing-indicator {
  504. display: flex;
  505. gap: 0.4rem;
  506. padding: 0.5rem 0;
  507. }
  508. .typing-indicator span {
  509. width: 8px;
  510. height: 8px;
  511. border-radius: 50%;
  512. background-color: var(--secondary);
  513. animation: typing 1.4s infinite;
  514. }
  515. .typing-indicator span:nth-child(2) {
  516. animation-delay: 0.2s;
  517. }
  518. .typing-indicator span:nth-child(3) {
  519. animation-delay: 0.4s;
  520. }
  521. /* Zone de saisie ChatRoom */
  522. .chat-input-container {
  523. width: 100%;
  524. padding: 16px 24px;
  525. background: transparent;
  526. display: flex;
  527. flex-direction: column;
  528. justify-content: center;
  529. position: relative;
  530. }
  531. .attached-files {
  532. display: flex;
  533. flex-wrap: wrap;
  534. gap: 8px;
  535. padding: 12px 16px;
  536. max-width: 1000px;
  537. margin: 0 auto;
  538. width: 100%;
  539. }
  540. .chat-input-container .input-wrapper {
  541. max-width: 1000px;
  542. margin: 0 auto;
  543. width: 100%;
  544. }
  545. .actions-row {
  546. display: flex;
  547. justify-content: space-between;
  548. align-items: center;
  549. padding-top: 4px;
  550. }
  551. .right-actions {
  552. display: flex;
  553. align-items: center;
  554. gap: 8px;
  555. }
  556. /* Contrôles spécifiques ChatRoom */
  557. .domain-select {
  558. padding: 6px 12px;
  559. border: 1px solid var(--border);
  560. border-radius: 8px;
  561. background: white;
  562. color: var(--text-dark);
  563. font-size: 13px;
  564. cursor: pointer;
  565. transition: all 0.2s ease;
  566. }
  567. .domain-select:hover {
  568. border-color: var(--secondary);
  569. }
  570. .domain-select:focus {
  571. outline: none;
  572. border-color: var(--secondary);
  573. box-shadow: 0 0 0 3px rgba(41, 132, 161, 0.1);
  574. }
  575. .history-button {
  576. display: flex;
  577. align-items: center;
  578. justify-content: center;
  579. width: 36px;
  580. height: 36px;
  581. background: transparent;
  582. border: none;
  583. color: #6b7280;
  584. cursor: pointer;
  585. border-radius: 8px;
  586. transition: all 0.2s ease;
  587. }
  588. .history-button:hover {
  589. background: #f3f4f6;
  590. color: var(--text-dark);
  591. }
  592. .history-button.active {
  593. background: var(--secondary);
  594. color: white;
  595. }
  596. .history-button.desactive {
  597. opacity: 0.5;
  598. }
  599. @media (min-width: 640px) {
  600. .attach-button span {
  601. display: inline;
  602. }
  603. }
  604. @media (max-width: 768px) {
  605. /* Home */
  606. .home-content {
  607. gap: 2rem;
  608. }
  609. .welcome-title {
  610. font-size: 2rem;
  611. }
  612. .welcome-subtitle {
  613. font-size: 1.125rem;
  614. }
  615. .agents-grid {
  616. grid-template-columns: 1fr;
  617. }
  618. /* ChatRoom */
  619. .chatroom-messages {
  620. padding: 1rem;
  621. }
  622. .message-content-wrapper {
  623. max-width: 85%;
  624. }
  625. .chat-input-container {
  626. padding: 12px 16px;
  627. }
  628. .attached-files {
  629. padding: 10px 12px;
  630. gap: 6px;
  631. }
  632. /* Fichiers */
  633. .file-item {
  634. padding: 6px 10px;
  635. max-width: 200px;
  636. }
  637. .file-preview {
  638. width: 36px;
  639. height: 36px;
  640. }
  641. .file-name {
  642. font-size: 12px;
  643. }
  644. .file-size {
  645. font-size: 10px;
  646. }
  647. .remove-file-button {
  648. width: 20px;
  649. height: 20px;
  650. }
  651. /* Input wrapper */
  652. .input-wrapper {
  653. padding: 12px 16px;
  654. border-radius: 14px;
  655. }
  656. .input-wrapper.has-files {
  657. border-radius: 0 0 14px 14px;
  658. }
  659. .input-wrapper textarea {
  660. font-size: 14px;
  661. }
  662. /* Actions */
  663. .actions-row .right-actions {
  664. gap: 6px;
  665. }
  666. .voice-button,
  667. .send-button {
  668. width: 32px;
  669. height: 32px;
  670. }
  671. .domain-select {
  672. font-size: 12px;
  673. padding: 4px 8px;
  674. }
  675. }
  676. @media (max-width: 480px) {
  677. .bubble {
  678. padding: 0.875rem 1rem;
  679. font-size: 0.95rem;
  680. }
  681. .avatar {
  682. width: 36px;
  683. height: 36px;
  684. }
  685. .agent-card {
  686. padding: 1rem;
  687. }
  688. .agent-icon {
  689. width: 40px;
  690. height: 40px;
  691. }
  692. .agent-name {
  693. font-size: 1rem;
  694. }
  695. .agent-description {
  696. font-size: 0.85rem;
  697. }
  698. }