chat.component.css 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. .chat-wrapper {
  2. display: flex;
  3. width: 100vw;
  4. height: 80vh; /* full viewport height minus some margin */
  5. gap: 12px;
  6. padding: 12px;
  7. box-sizing: border-box;
  8. }
  9. .panel {
  10. flex: 1; /* each panel takes equal width */
  11. display: flex;
  12. flex-direction: column;
  13. border-radius: 12px;
  14. box-shadow: 0 6px 16px rgba(0,0,0,0.15);
  15. background-color: #fafafa;
  16. overflow: hidden;
  17. }
  18. mat-card-title {
  19. font-size: 1.4rem;
  20. font-weight: 600;
  21. text-align: center;
  22. padding: 12px 0;
  23. border-bottom: 1px solid #ddd;
  24. }
  25. mat-card-content {
  26. flex: 1;
  27. overflow-y: auto;
  28. padding: 12px;
  29. }
  30. /* Chat messages */
  31. .messages {
  32. display: flex;
  33. flex-direction: column;
  34. gap: 12px;
  35. }
  36. .message {
  37. padding: 10px 16px;
  38. border-radius: 20px;
  39. max-width: 80%;
  40. word-wrap: break-word;
  41. white-space: pre-wrap;
  42. line-height: 1.4;
  43. }
  44. .user {
  45. background-color: #1976d2;
  46. color: white;
  47. align-self: flex-end;
  48. text-align: right;
  49. }
  50. .bot {
  51. background-color: #e0e0e0;
  52. color: #333;
  53. align-self: flex-start;
  54. text-align: left;
  55. }
  56. .bot-typing {
  57. font-style: italic;
  58. color: #666;
  59. }
  60. /* Chat input */
  61. .chat-input {
  62. display: flex;
  63. gap: 10px;
  64. padding: 12px;
  65. border-top: 1px solid #ddd;
  66. background-color: #f5f5f5;
  67. }
  68. .chat-input mat-form-field {
  69. flex: 1;
  70. margin: 0;
  71. }
  72. /* JSON output pre blocks */
  73. pre {
  74. white-space: pre-wrap;
  75. word-break: break-word;
  76. font-size: 0.85rem;
  77. background-color: #f5f5f5;
  78. padding: 10px;
  79. border-radius: 8px;
  80. max-height: 100%;
  81. overflow: auto;
  82. }