botui/ui/suite/chat/chat.css

797 lines
14 KiB
CSS
Raw Permalink Normal View History

/* Chat module styles - including chat layout and projector component */
/* Chat Layout */
.chat-layout {
display: flex;
flex-direction: column;
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
max-width: 800px;
margin: 0 auto;
padding: 80px 20px 20px 20px;
box-sizing: border-box;
}
/* Connection Status */
.connection-status {
position: fixed;
top: 80px;
right: 20px;
width: 10px;
height: 10px;
border-radius: 50%;
z-index: 1000;
transition: all 0.3s;
}
.connection-status.connecting {
background: #f59e0b;
animation: pulse 1.5s infinite;
}
.connection-status.connected {
background: #10b981;
}
.connection-status.disconnected {
background: #ef4444;
}
@keyframes pulse {
0%,
100% {
opacity: 1;
transform: scale(1);
}
50% {
opacity: 0.5;
transform: scale(1.2);
}
}
/* Messages Area */
#messages {
flex: 1;
overflow-y: auto;
padding: 20px 0;
display: flex;
flex-direction: column;
gap: 16px;
}
/* Message Styles */
.message {
display: flex;
animation: slideIn 0.3s ease;
}
@keyframes slideIn {
from {
opacity: 0;
transform: translateY(10px);
}
to {
opacity: 1;
transform: translateY(0);
}
}
.message.user {
justify-content: flex-end;
}
.message.bot {
justify-content: flex-start;
}
.message-content {
max-width: 80%;
padding: 12px 16px;
border-radius: 16px;
line-height: 1.5;
font-size: 14px;
}
.user-message {
background: var(--accent-color, #3b82f6);
color: white;
border-bottom-right-radius: 4px;
}
.bot-message {
background: var(--secondary-bg, #f3f4f6);
color: var(--text-primary, #1f2937);
border-bottom-left-radius: 4px;
}
/* Dark theme adjustments */
[data-theme="dark"] .bot-message {
background: #374151;
color: #f9fafb;
}
/* Markdown content in bot messages */
.bot-message p {
margin: 0 0 8px 0;
}
.bot-message p:last-child {
margin-bottom: 0;
}
.bot-message code {
background: rgba(0, 0, 0, 0.1);
padding: 2px 6px;
border-radius: 4px;
font-family: "Monaco", "Menlo", monospace;
font-size: 13px;
}
.bot-message pre {
background: rgba(0, 0, 0, 0.1);
padding: 12px;
border-radius: 8px;
overflow-x: auto;
margin: 8px 0;
}
.bot-message pre code {
background: none;
padding: 0;
}
/* Footer */
footer {
padding: 16px 0;
border-top: 1px solid var(--border-color, #e5e7eb);
background: var(--primary-bg, #ffffff);
}
/* Suggestions */
.suggestions-container {
display: flex;
flex-wrap: wrap;
gap: 8px;
margin-bottom: 12px;
}
.suggestion-button {
padding: 6px 12px;
border-radius: 16px;
border: 1px solid var(--border-color, #e5e7eb);
background: var(--secondary-bg, #f9fafb);
color: var(--text-primary, #374151);
font-size: 13px;
cursor: pointer;
transition: all 0.2s;
}
.suggestion-button:hover {
background: var(--accent-color, #3b82f6);
color: white;
border-color: var(--accent-color, #3b82f6);
}
/* Input Container */
.input-container {
display: flex;
gap: 12px;
align-items: center;
padding: 8px 12px;
background: var(--surface, var(--secondary-bg, #f9fafb));
border: 1px solid var(--border, var(--border-color, #e5e7eb));
border-radius: 28px;
}
[data-theme="dark"] .input-container,
[data-theme="sentient"] .input-container {
background: var(--surface, #1a1a24);
border-color: var(--border, #2a2a3a);
}
.input-container:focus-within {
border-color: var(--accent, var(--accent-color, #3b82f6));
box-shadow: 0 0 0 3px var(--accent-glow, rgba(59, 130, 246, 0.1));
}
#messageInput {
flex: 1;
padding: 8px 12px;
border-radius: 20px;
border: none;
background: transparent;
color: var(--text-primary, #1f2937);
font-size: 15px;
outline: none;
transition: all 0.2s;
}
[data-theme="dark"] #messageInput,
[data-theme="sentient"] #messageInput {
color: var(--text-primary, #ffffff);
}
#messageInput:focus {
outline: none;
}
#messageInput::placeholder {
color: var(--text-muted, #9ca3af);
}
#voiceBtn,
#sendBtn {
width: 44px;
height: 44px;
min-width: 44px;
min-height: 44px;
border-radius: 50%;
border: none;
background: var(--accent, var(--accent-color, #3b82f6));
color: var(--accent-foreground, white);
cursor: pointer;
display: flex !important;
align-items: center;
justify-content: center;
font-size: 18px;
transition: all 0.2s;
flex-shrink: 0;
}
#sendBtn {
background: var(--accent, var(--accent-color, #3b82f6));
}
#voiceBtn {
background: var(--surface, var(--secondary-bg, #f9fafb));
color: var(--text-primary, #374151);
border: 1px solid var(--border, var(--border-color, #e5e7eb));
}
#voiceBtn:hover,
#sendBtn:hover {
transform: scale(1.05);
opacity: 0.9;
}
#sendBtn:hover {
background: var(--accent-hover, var(--accent, #2563eb));
}
#voiceBtn:active,
#sendBtn:active {
transform: scale(0.95);
}
/* Dark/Sentient theme overrides */
[data-theme="dark"] #sendBtn,
[data-theme="sentient"] #sendBtn {
background: var(--accent, #d4f505);
color: #000000;
}
[data-theme="dark"] #voiceBtn,
[data-theme="sentient"] #voiceBtn {
background: var(--surface, #1a1a24);
color: var(--text-primary, #ffffff);
border-color: var(--border, #2a2a3a);
}
/* Scroll to Bottom Button */
.scroll-to-bottom {
position: fixed;
bottom: 100px;
right: 20px;
width: 40px;
height: 40px;
border-radius: 50%;
border: 1px solid var(--border-color, #e5e7eb);
background: var(--primary-bg, #ffffff);
color: var(--text-primary, #374151);
cursor: pointer;
display: none;
align-items: center;
justify-content: center;
font-size: 18px;
transition: all 0.2s;
box-shadow: var(--shadow-sm, 0 2px 8px rgba(0, 0, 0, 0.1));
z-index: 100;
}
.scroll-to-bottom.visible {
display: flex;
}
.scroll-to-bottom:hover {
background: var(--bg-hover, #f3f4f6);
}
/* Responsive */
@media (max-width: 768px) {
.chat-layout {
padding: 0 12px;
}
.message-content {
max-width: 90%;
}
}
/* Projector Overlay */
.projector-overlay {
position: fixed;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: rgba(0, 0, 0, 0.9);
z-index: 10000;
2025-12-03 18:42:22 -03:00
display: flex;
align-items: center;
justify-content: center;
animation: fadeIn 0.2s ease;
2025-12-03 18:42:22 -03:00
}
.projector-overlay.hidden {
display: none;
2025-12-03 18:42:22 -03:00
}
@keyframes fadeIn {
from {
opacity: 0;
}
to {
opacity: 1;
}
2025-12-03 18:42:22 -03:00
}
/* Container */
.projector-container {
width: 95%;
max-width: 1400px;
height: 90%;
max-height: 900px;
background: #1a1a1a;
border-radius: 12px;
2025-12-03 18:42:22 -03:00
display: flex;
flex-direction: column;
overflow: hidden;
box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
2025-12-03 18:42:22 -03:00
}
.projector-container.fullscreen {
width: 100%;
max-width: none;
height: 100%;
max-height: none;
border-radius: 0;
2025-12-03 18:42:22 -03:00
}
/* Header */
.projector-header {
2025-12-03 18:42:22 -03:00
display: flex;
justify-content: space-between;
align-items: center;
padding: 12px 20px;
background: #252525;
border-bottom: 1px solid #333;
2025-12-03 18:42:22 -03:00
}
.projector-title-section {
display: flex;
align-items: center;
gap: 10px;
2025-12-03 18:42:22 -03:00
}
.projector-icon {
font-size: 20px;
2025-12-03 18:42:22 -03:00
}
.projector-title {
color: #fff;
font-size: 16px;
font-weight: 500;
max-width: 400px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
2025-12-03 18:42:22 -03:00
}
.projector-actions {
display: flex;
gap: 8px;
2025-12-03 18:42:22 -03:00
}
.projector-btn {
background: transparent;
border: none;
color: #aaa;
2025-12-03 18:42:22 -03:00
font-size: 18px;
padding: 8px;
cursor: pointer;
border-radius: 6px;
transition: all 0.2s ease;
2025-12-03 18:42:22 -03:00
}
.projector-btn:hover {
background: #333;
color: #fff;
2025-12-03 18:42:22 -03:00
}
.projector-btn.close-btn:hover {
background: #e74c3c;
color: #fff;
2025-12-03 18:42:22 -03:00
}
/* Content Area */
.projector-content {
flex: 1;
2025-12-03 18:42:22 -03:00
display: flex;
align-items: center;
justify-content: center;
overflow: hidden;
position: relative;
background: #000;
2025-12-03 18:42:22 -03:00
}
/* Loading */
.projector-loading {
display: flex;
flex-direction: column;
align-items: center;
gap: 16px;
color: #888;
2025-12-03 18:42:22 -03:00
}
.projector-loading.hidden {
display: none;
2025-12-03 18:42:22 -03:00
}
.loading-spinner {
width: 40px;
height: 40px;
border: 3px solid #333;
border-top-color: #667eea;
border-radius: 50%;
animation: spin 1s linear infinite;
2025-12-03 18:42:22 -03:00
}
@keyframes spin {
to {
transform: rotate(360deg);
}
2025-12-03 18:42:22 -03:00
}
/* Video Player */
.projector-video {
max-width: 100%;
max-height: 100%;
width: auto;
height: auto;
2025-12-03 18:42:22 -03:00
}
/* Audio Player */
.projector-audio {
width: 80%;
max-width: 600px;
2025-12-03 18:42:22 -03:00
}
.audio-visualizer {
width: 100%;
height: 200px;
background: linear-gradient(180deg, #1a1a2e 0%, #16213e 100%);
border-radius: 8px;
margin-bottom: 20px;
2025-12-03 18:42:22 -03:00
}
/* Image Viewer */
.projector-image {
max-width: 100%;
max-height: 100%;
object-fit: contain;
transition: transform 0.3s ease;
2025-12-03 18:42:22 -03:00
}
/* PDF Viewer */
.projector-pdf {
width: 100%;
height: 100%;
border: none;
2025-12-03 18:42:22 -03:00
}
/* Code Viewer */
.projector-code {
width: 100%;
height: 100%;
overflow: auto;
background: #1e1e1e;
padding: 20px;
2025-12-03 18:42:22 -03:00
}
.projector-code pre {
margin: 0;
font-family: "Fira Code", "Monaco", "Consolas", monospace;
2025-12-03 18:42:22 -03:00
font-size: 14px;
line-height: 1.5;
color: #d4d4d4;
2025-12-03 18:42:22 -03:00
}
.projector-code.line-numbers pre {
counter-reset: line;
2025-12-03 18:42:22 -03:00
}
.projector-code.line-numbers pre .line::before {
counter-increment: line;
content: counter(line);
display: inline-block;
width: 40px;
padding-right: 20px;
color: #666;
text-align: right;
2025-12-03 18:42:22 -03:00
}
/* Presentation Viewer */
.projector-presentation {
width: 100%;
height: 100%;
2025-12-03 18:42:22 -03:00
display: flex;
align-items: center;
justify-content: center;
}
.slide-container {
background: #fff;
box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
aspect-ratio: 16/9;
max-width: 90%;
max-height: 90%;
display: flex;
align-items: center;
justify-content: center;
overflow: hidden;
2025-12-03 18:42:22 -03:00
}
.slide-content {
width: 100%;
height: 100%;
object-fit: contain;
2025-12-03 18:42:22 -03:00
}
/* Iframe Viewer */
.projector-iframe {
width: 100%;
height: 100%;
border: none;
background: #fff;
2025-12-03 18:42:22 -03:00
}
/* Markdown Viewer */
.projector-markdown {
width: 100%;
height: 100%;
overflow: auto;
padding: 40px;
background: #fff;
color: #333;
}
.projector-markdown h1,
.projector-markdown h2,
.projector-markdown h3 {
color: #1a1a1a;
margin-top: 24px;
margin-bottom: 12px;
2025-12-03 18:42:22 -03:00
}
.projector-markdown code {
background: #f0f0f0;
padding: 2px 6px;
border-radius: 4px;
font-family: monospace;
2025-12-03 18:42:22 -03:00
}
.projector-markdown pre code {
display: block;
padding: 16px;
overflow-x: auto;
2025-12-03 18:42:22 -03:00
}
/* Controls */
.projector-controls {
padding: 12px 20px;
background: #252525;
border-top: 1px solid #333;
2025-12-03 18:42:22 -03:00
}
.media-controls,
.slide-controls,
.image-controls,
.code-controls {
2025-12-03 18:42:22 -03:00
display: flex;
align-items: center;
gap: 12px;
flex-wrap: wrap;
2025-12-03 18:42:22 -03:00
}
.media-controls.hidden,
.slide-controls.hidden,
.image-controls.hidden,
.code-controls.hidden {
display: none;
2025-12-03 18:42:22 -03:00
}
.control-btn {
background: #333;
border: none;
color: #fff;
padding: 8px 12px;
border-radius: 6px;
cursor: pointer;
font-size: 16px;
transition: all 0.2s ease;
2025-12-03 18:42:22 -03:00
}
.control-btn:hover {
background: #444;
2025-12-03 18:42:22 -03:00
}
.control-btn.active {
background: #667eea;
2025-12-03 18:42:22 -03:00
}
.play-btn {
font-size: 20px;
padding: 8px 16px;
2025-12-03 18:42:22 -03:00
}
/* Progress Bar */
.progress-container {
flex: 1;
display: flex;
align-items: center;
gap: 12px;
min-width: 200px;
2025-12-03 18:42:22 -03:00
}
.progress-bar {
flex: 1;
height: 6px;
-webkit-appearance: none;
appearance: none;
background: #444;
border-radius: 3px;
cursor: pointer;
2025-12-03 18:42:22 -03:00
}
.progress-bar::-webkit-slider-thumb {
-webkit-appearance: none;
width: 14px;
height: 14px;
background: #667eea;
border-radius: 50%;
cursor: pointer;
2025-12-03 18:42:22 -03:00
}
.progress-bar::-moz-range-thumb {
width: 14px;
height: 14px;
background: #667eea;
border-radius: 50%;
cursor: pointer;
border: none;
2025-12-03 18:42:22 -03:00
}
.time-display {
color: #888;
font-size: 12px;
min-width: 100px;
text-align: right;
2025-12-03 18:42:22 -03:00
}
/* Volume */
.volume-slider {
width: 80px;
height: 4px;
-webkit-appearance: none;
appearance: none;
background: #444;
border-radius: 2px;
cursor: pointer;
2025-12-03 18:42:22 -03:00
}
.volume-slider::-webkit-slider-thumb {
-webkit-appearance: none;
width: 12px;
height: 12px;
background: #fff;
border-radius: 50%;
cursor: pointer;
2025-12-03 18:42:22 -03:00
}
/* Speed/Theme Select */
.speed-select,
.theme-select {
background: #333;
color: #fff;
border: none;
padding: 6px 10px;
border-radius: 6px;
2025-12-03 18:42:22 -03:00
cursor: pointer;
}
/* Slide Info */
.slide-info,
.image-info,
.code-info,
.zoom-level {
color: #888;
font-size: 14px;
2025-12-03 18:42:22 -03:00
}
.slide-nav input {
width: 50px;
background: #333;
border: none;
color: #fff;
padding: 6px;
border-radius: 4px;
text-align: center;
2025-12-03 18:42:22 -03:00
}
/* Error State */
.projector-error {
display: flex;
flex-direction: column;
align-items: center;
gap: 16px;
color: #e74c3c;
2025-12-03 18:42:22 -03:00
}
.projector-error-icon {
font-size: 48px;
2025-12-03 18:42:22 -03:00
}
.projector-error-message {
font-size: 16px;
color: #888;
2025-12-03 18:42:22 -03:00
}
/* Responsive */
@media (max-width: 768px) {
.projector-container {
width: 100%;
height: 100%;
max-width: none;
max-height: none;
border-radius: 0;
2025-12-03 18:42:22 -03:00
}
.projector-header {
padding: 10px 16px;
2025-12-03 18:42:22 -03:00
}
.projector-title {
max-width: 150px;
2025-12-03 18:42:22 -03:00
font-size: 14px;
}
.projector-controls {
padding: 10px 16px;
}
.progress-container {
min-width: 120px;
2025-12-03 18:42:22 -03:00
}
.time-display {
display: none;
2025-12-03 18:42:22 -03:00
}
.volume-slider {
display: none;
2025-12-03 18:42:22 -03:00
}
}