export const WIDGET_STYLES = ` /* Font faces for Shadow DOM */ @font-face { font-family: 'Aeonik'; src: url('/shared/themes/sendcloud/assets/Aeonik-Regular.woff2') format('woff2'); font-weight: 400; font-style: normal; font-display: swap; } @font-face { font-family: 'Aeonik'; src: url('/shared/themes/sendcloud/assets/Aeonik-Bold.woff2') format('woff2'); font-weight: 700; font-style: normal; font-display: swap; } @font-face { font-family: 'Aeonik'; src: url('/shared/themes/sendcloud/assets/Aeonik-RegularItalic.woff2') format('woff2'); font-weight: 400; font-style: italic; font-display: swap; } :host { all: initial; } /* Size mode classes */ .bt-size-minimal { width: var(--bt-size-minimal-width, 140px); height: var(--bt-size-minimal-height, 60px); position: fixed; bottom: 16px; right: 16px; z-index: 2147483000; transition: var(--bt-size-transition, 0.3s cubic-bezier(0.2, 0, 0, 1)); border-radius: 8px; overflow: hidden; } /* Show only size controls in minimal mode with smaller icons */ .bt-size-minimal .bt-controls { display: flex !important; gap: 3px; align-items: center; justify-content: center; height: 100%; padding: 4px; width: 100%; } /* Hide text content in minimal mode */ .bt-size-minimal .bt-title, .bt-size-minimal .bt-chat-area, .bt-size-minimal .bt-video-area, .bt-size-minimal .bt-content-controls, .bt-size-minimal .bt-call-controls, .bt-size-minimal .bt-interaction-controls, .bt-size-minimal .bt-body { display: none !important; } /* Smaller icons in minimal mode */ .bt-size-minimal .bt-icon { width: 24px; height: 24px; min-width: 24px; min-height: 24px; padding: 4px; display: flex !important; visibility: visible !important; opacity: 1 !important; background: rgba(255, 255, 255, 0.15) !important; border: 1px solid rgba(255, 255, 255, 0.3) !important; color: #ffffff !important; border-radius: 6px; } .bt-size-minimal .bt-icon:hover { background: rgba(255, 255, 255, 0.25) !important; border-color: rgba(255, 255, 255, 0.5) !important; transform: translateY(-1px); } .bt-size-minimal .bt-icon svg { width: 14px; height: 14px; } /* Ensure minimal mode shows buttons */ .bt-size-minimal .bt-toolbar { display: flex !important; align-items: center; justify-content: center; width: 100%; height: 100%; } /* Hide title in minimal mode */ .bt-size-minimal .bt-title { display: none !important; } /* Make toolbar more compact in minimal mode */ .bt-size-minimal .bt-toolbar { padding: 4px; height: 100%; display: flex; align-items: center; justify-content: center; background: var(--bt-color-navy, #1e293b); border: none; } /* Hide resize handles in minimal mode */ .bt-size-minimal .bt-resize-handle { display: none; } .bt-size-medium { width: var(--bt-size-medium-width, 400px); height: var(--bt-size-medium-height, 313px); /* 16:9 video area + 88px header */ position: fixed; bottom: 16px; right: 16px; z-index: 2147483000; transition: var(--bt-size-transition, 0.3s cubic-bezier(0.2, 0, 0, 1)); box-shadow: var(--bt-size-shadow, 0 8px 32px rgba(0,0,0,0.12)); border: var(--bt-size-border, 1px solid rgba(0,176,255,0.15)); container-type: inline-size; } /* Browser responsive behavior for medium mode */ @media (max-width: 400px) { .bt-size-medium { width: calc(100vw - 32px); max-width: 350px; right: 16px; left: 16px; } /* Ensure chat overlay adapts to smaller browser windows */ .bt-size-medium .bt-chat-overlay { width: 40%; min-width: 100px; } } @media (max-width: 300px) { .bt-size-medium { width: calc(100vw - 24px); right: 12px; left: 12px; } /* Further adapt chat overlay for very small browser windows */ .bt-size-medium .bt-chat-overlay { width: 45%; min-width: 80px; } } /* Prevent cutoff on extremely small browser windows */ @media (max-width: 250px) { .bt-size-medium { width: calc(100vw - 16px); right: 8px; left: 8px; } .bt-size-medium .bt-chat-overlay { width: 50%; min-width: 60px; } } /* Medium mode with drag enabled */ .bt-size-medium.bt-draggable { cursor: move; } /* Medium mode with resize enabled */ .bt-size-medium.bt-resizable { /* Resize handles will be added via JavaScript */ } /* Dynamic button scaling based on widget width */ .bt-controls { display: flex; gap: 8px; align-items: center; justify-content: center; height: 40px; /* Match toolbar height */ } /* Base button styles */ .bt-icon, .bt-btn { min-width: 40px; height: 40px; padding: 0 8px; border-radius: var(--bt-radius-md); border: var(--bt-border-1) solid var(--bt-color-border); background: var(--bt-bg); color: var(--bt-text); cursor: pointer; display: flex; align-items: center; justify-content: center; transition: all 0.2s ease; } .bt-icon:hover, .bt-btn:hover { background: var(--bt-bg-subtle); transform: translateY(-1px); } .bt-icon svg, .bt-btn svg { width: 16px; height: 16px; transition: all 0.2s ease; } /* Dynamic scaling based on widget width */ @container (max-width: 450px) { .bt-icon, .bt-btn { min-width: 38px; height: 38px; padding: 0 7px; } .bt-icon svg { width: 15px; height: 15px; } .bt-controls { gap: 7px; } /* Responsive header text */ .bt-title { font-size: 17px; } .bt-title .responsive-hide-1 { display: none; } .bt-title .responsive-hide-2 { display: inline; } .bt-title .responsive-hide-3 { display: none; } .bt-title .responsive-hide-4 { display: none; } } @container (max-width: 400px) { .bt-icon, .bt-btn { min-width: 34px; height: 34px; padding: 0 6px; } .bt-icon svg { width: 13px; height: 13px; } .bt-controls { gap: 6px; } /* Responsive header text */ .bt-title { font-size: 16px; } .bt-title .responsive-hide-1 { display: none; } .bt-title .responsive-hide-2 { display: inline; } .bt-title .responsive-hide-3 { display: none; } .bt-title .responsive-hide-4 { display: none; } } @container (max-width: 350px) { .bt-icon, .bt-btn { min-width: 30px; height: 30px; padding: 0 5px; } .bt-icon svg { width: 11px; height: 11px; } .bt-controls { gap: 5px; } /* Responsive header text */ .bt-title { font-size: 15px; } .bt-title .responsive-hide-1 { display: none; } .bt-title .responsive-hide-2 { display: none; } .bt-title .responsive-hide-3 { display: inline; } .bt-title .responsive-hide-4 { display: none; } } @container (max-width: 300px) { .bt-icon, .bt-btn { min-width: 26px; height: 26px; padding: 0 4px; } .bt-icon svg { width: 9px; height: 9px; } .bt-controls { gap: 4px; } /* Responsive header text */ .bt-title { font-size: 14px; } .bt-title .responsive-hide-1 { display: none; } .bt-title .responsive-hide-2 { display: none; } .bt-title .responsive-hide-3 { display: none; } .bt-title .responsive-hide-4 { display: inline; } } @container (max-width: 250px) { .bt-icon, .bt-btn { min-width: 22px; height: 22px; padding: 0 3px; } .bt-icon svg { width: 8px; height: 8px; } .bt-controls { gap: 3px; } /* Responsive header text */ .bt-title { font-size: 12px; } .bt-title .responsive-hide-1 { display: none; } .bt-title .responsive-hide-2 { display: none; } .bt-title .responsive-hide-3 { display: none; } .bt-title .responsive-hide-4 { display: inline; } } @container (max-width: 200px) { .bt-icon, .bt-btn { min-width: 20px; height: 20px; padding: 0 2px; } .bt-icon svg { width: 7px; height: 7px; } .bt-controls { gap: 2px; } /* Responsive header text */ .bt-title { font-size: 11px; } .bt-title .responsive-hide-1 { display: none; } .bt-title .responsive-hide-2 { display: none; } .bt-title .responsive-hide-3 { display: none; } .bt-title .responsive-hide-4 { display: inline; } } gap: 3px; } /* Responsive header text */ .bt-title { font-size: 12px; } .bt-title .responsive-hide-1 { display: none; } .bt-title .responsive-hide-2 { display: none; } .bt-title .responsive-hide-3 { display: none; } .bt-title .responsive-hide-4 { display: inline; } /* Scale down toolbar */ .bt-toolbar { padding: 6px 8px; min-height: 36px; } .bt-body { height: calc(100% - 36px); } } @container (max-width: 250px) { .bt-icon, .bt-btn { min-width: 24px; height: 24px; padding: 0 3px; } .bt-icon svg { width: 8px; height: 8px; } .bt-controls { gap: 2px; } /* Responsive header text */ .bt-title { font-size: 10px; } .bt-title .responsive-hide-1 { display: none; } .bt-title .responsive-hide-2 { display: none; } .bt-title .responsive-hide-3 { display: none; } .bt-title .responsive-hide-4 { display: inline; } /* Scale down toolbar */ .bt-toolbar { padding: 4px 6px; min-height: 32px; } .bt-body { height: calc(100% - 32px); } } /* Ensure minimal mode buttons are always visible */ .bt-size-minimal .bt-controls { display: flex !important; visibility: visible !important; opacity: 1 !important; } .bt-size-minimal .bt-icon { display: flex !important; visibility: visible !important; opacity: 1 !important; } .bt-size-large { width: var(--bt-size-large-width, 96vw); height: var(--bt-size-large-height, calc(96vw * 0.5625 + 88px)); /* 16:9 video area + 88px header */ position: fixed; top: 1vh; left: 1vw; right: 1vw; z-index: 2147483000; transition: var(--bt-size-transition, 0.3s cubic-bezier(0.2, 0, 0, 1)); box-shadow: var(--bt-size-shadow, 0 8px 32px rgba(0,0,0,0.12)); border: var(--bt-size-border, 1px solid rgba(0,176,255,0.15)); container-type: inline-size; } /* Browser window responsive behavior */ @media (max-width: 1200px) { .bt-size-large { width: 94vw; height: calc(94vw * 0.5625 + 88px); /* 16:9 video area + 88px header */ left: 2vw; right: 2vw; } /* Responsive title text for browser window size */ .bt-title { font-size: 16px; } .bt-title .responsive-hide-1 { display: none; } .bt-title .responsive-hide-2 { display: inline; } .bt-title .responsive-hide-3 { display: none; } .bt-title .responsive-hide-4 { display: none; } /* Scale down buttons for browser window size */ .bt-icon, .bt-btn { min-width: 36px; height: 36px; padding: 0 6px; } .bt-icon svg { width: 14px; height: 14px; } .bt-controls { gap: 6px; } } @media (max-width: 1000px) { .bt-size-large { width: 92vw; height: calc(92vw * 0.5625 + 88px); /* 16:9 video area + 88px header */ left: 3vw; right: 3vw; } /* Responsive title text for browser window size */ .bt-title { font-size: 14px; } .bt-title .responsive-hide-1 { display: none; } .bt-title .responsive-hide-2 { display: none; } .bt-title .responsive-hide-3 { display: inline; } .bt-title .responsive-hide-4 { display: none; } /* Scale down buttons for browser window size */ .bt-icon, .bt-btn { min-width: 32px; height: 32px; padding: 0 5px; } .bt-icon svg { width: 12px; height: 12px; } .bt-controls { gap: 4px; } } @media (max-width: 800px) { .bt-size-large { width: 90vw; height: calc(90vw * 0.5625 + 88px); /* 16:9 video area + 88px header */ left: 4vw; right: 4vw; } /* Responsive title text for browser window size */ .bt-title { font-size: 12px; } .bt-title .responsive-hide-1 { display: none; } .bt-title .responsive-hide-2 { display: none; } .bt-title .responsive-hide-3 { display: none; } .bt-title .responsive-hide-4 { display: inline; } /* Scale down buttons for browser window size */ .bt-icon, .bt-btn { min-width: 28px; height: 28px; padding: 0 4px; } .bt-icon svg { width: 10px; height: 10px; } .bt-controls { gap: 3px; } } @media (max-width: 600px) { .bt-size-large { width: 88vw; height: calc(88vw * 0.5625 + 88px); /* 16:9 video area + 88px header */ left: 5vw; right: 5vw; } /* Responsive title text for browser window size */ .bt-title { font-size: 10px; } .bt-title .responsive-hide-1 { display: none; } .bt-title .responsive-hide-2 { display: none; } .bt-title .responsive-hide-3 { display: none; } .bt-title .responsive-hide-4 { display: inline; } /* Scale down buttons for browser window size */ .bt-icon, .bt-btn { min-width: 24px; height: 24px; padding: 0 3px; } .bt-icon svg { width: 8px; height: 8px; } .bt-controls { gap: 2px; } } @media (max-width: 400px) { .bt-size-large { width: 85vw; height: calc(85vw * 0.5625 + 88px); /* 16:9 video area + 88px header */ left: 6vw; right: 6vw; } /* Responsive title text for browser window size */ .bt-title { font-size: 8px; } .bt-title .responsive-hide-1 { display: none; } .bt-title .responsive-hide-2 { display: none; } .bt-title .responsive-hide-3 { display: none; } .bt-title .responsive-hide-4 { display: inline; } /* Scale down buttons for browser window size */ .bt-icon, .bt-btn { min-width: 20px; height: 20px; padding: 0 2px; } .bt-icon svg { width: 6px; height: 6px; } .bt-controls { gap: 1px; } } /* Hide resize handles in large mode */ .bt-size-large .bt-resize-handle { display: none; } /* Disable dragging in large mode */ .bt-size-large { cursor: default; } .bt-size-large .bt-toolbar { cursor: default; } /* Responsive breakpoints - now based on widget size, not browser size */ @media (max-width: 767px) { .bt-size-minimal { width: var(--bt-size-minimal-width-mobile, 80px); height: var(--bt-size-minimal-height-mobile, 60px); } .bt-size-medium { width: var(--bt-size-medium-width-tablet, 400px); height: var(--bt-size-medium-height-tablet, 313px); /* 16:9 video area + 88px header */ } } /* Reduce toolbar height and padding */ .bt-toolbar { padding: 8px 12px; min-height: 40px; } /* Adjust body height for smaller toolbar */ .bt-body { height: calc(100% - 40px); } } @media (max-width: 479px) { .bt-size-medium-floating { display: none; /* Fallback to fixed on mobile */ } .bt-size-large { width: 100vw; height: 100vh; top: 0; left: 0; transform: none; } /* Hide more text on very small screens */ .bt-title { font-size: 14px; } .bt-title .responsive-hide-1 { display: none; } .bt-title .responsive-hide-2 { display: none; } .bt-title .responsive-hide-3 { display: inline; } /* Even smaller buttons */ .bt-icon, .bt-btn { min-width: 28px; height: 28px; padding: 0 4px; } .bt-icon svg { width: 12px; height: 12px; } /* Scale down send button more */ .bt-chat-send { height: 28px; padding: 0 8px; font-size: 12px; } /* Scale down chat input more */ .bt-chat-input { min-height: 28px; max-height: 50px; padding: 5px 6px; font-size: 12px; } /* Compact toolbar */ .bt-toolbar { padding: 6px 8px; min-height: 36px; } .bt-body { height: calc(100% - 36px); } } /* Extra small screens - show only "BuzzTrail" */ @media (max-width: 320px) { .bt-title .responsive-hide-1 { display: none; } .bt-title .responsive-hide-2 { display: none; } .bt-title .responsive-hide-3 { display: inline; } .bt-icon, .bt-btn { min-width: 24px; height: 24px; padding: 0 2px; } .bt-icon svg { width: 10px; height: 10px; } /* Scale down send button to minimum */ .bt-chat-send { height: 24px; padding: 0 6px; font-size: 11px; } /* Scale down chat input to minimum */ .bt-chat-input { min-height: 24px; max-height: 40px; padding: 4px 5px; font-size: 11px; } .bt-toolbar { padding: 4px 6px; min-height: 32px; } .bt-body { height: calc(100% - 32px); } } .bt-launcher { position: fixed; right: 16px; bottom: 16px; z-index: 2147483000; width: 48px; height: 48px; border-radius: 9999px; border: var(--bt-border-1) solid var(--bt-border-color); background: var(--bt-color-navy); color: var(--bt-text-on-dark); display: inline-flex; align-items: center; justify-content: center; box-shadow: 0 8px 20px rgba(0,0,0,0.18); cursor: pointer; } /* Panel base styles */ .bt-panel { display: flex; flex-direction: column; background: var(--bt-bg, #ffffff); border-radius: var(--bt-radius-lg, 12px); box-shadow: var(--bt-shadow-lg, 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04)); overflow: hidden; font-family: var(--bt-font-base, 'Aeonik', ui-sans-serif); color: var(--bt-text, #1a1a1a); border: var(--bt-border-1) solid var(--bt-color-border, rgba(0,0,0,0.1)); } .bt-shell { width: 100%; height: 100%; background: var(--bt-bg); border-radius: var(--bt-radius-video); box-shadow: var(--bt-shadow-overlay); overflow: hidden; display: grid; grid-template-rows: auto 1fr; border: var(--bt-border-1) solid rgba(0,176,255,0.35); } .bt-toolbar { display:flex; align-items:center; justify-content: space-between; padding: var(--bt-space-5); background: var(--bt-color-navy); color: var(--bt-text-on-dark); } .bt-actions { display:flex; gap: 10px; align-items: center; } /* Control groups */ .bt-size-controls, .bt-content-controls, .bt-call-controls, .bt-interaction-controls { display: flex; gap: 6px; align-items: center; justify-content: center; height: 40px; /* Match toolbar height */ } /* Separator between groups */ .bt-content-controls::before, .bt-call-controls::before, .bt-interaction-controls::before { content: ''; width: 1px; height: 24px; background: rgba(255,255,255,0.2); margin: 0 8px; } /* Base icon styles with Sendcloud-inspired colors */ .bt-icon, .bt-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 0 10px; min-width: 40px; height: 40px; border: var(--bt-border-1) solid rgba(255,255,255,0.15); border-radius: var(--bt-radius-md); background: rgba(255,255,255,0.04); color: #1e293b; /* Dark blue like Sendcloud icons */ cursor: pointer; transition: all 0.2s ease; } .bt-icon:hover, .bt-btn:hover { background: rgba(0,176,255,0.1); border-color: rgba(0,176,255,0.3); color: #0ea5e9; /* Light blue on hover */ } .bt-icon-active { background: rgba(0,176,255,0.2) !important; border-color: rgba(0,176,255,0.5) !important; color: #0ea5e9 !important; /* Light blue when active */ } /* Specific icon colors for different functions */ .bt-icon svg { transition: all 0.2s ease; } /* Size control icons - subtle gray */ .bt-size-controls .bt-icon, .bt-size-controls .bt-btn { color: #64748b; } .bt-size-controls .bt-icon:hover, .bt-size-controls .bt-btn:hover { color: #0ea5e9; } /* Interaction control icons - orange accent */ .bt-interaction-controls .bt-icon, .bt-interaction-controls .bt-btn { color: #f59e0b; } .bt-interaction-controls .bt-icon:hover, .bt-interaction-controls .bt-btn:hover { color: #d97706; } /* Chat icon - blue accent */ .bt-content-controls .bt-icon, .bt-content-controls .bt-btn { color: #0ea5e9; } .bt-content-controls .bt-icon:hover, .bt-content-controls .bt-btn:hover { color: #0284c7; } /* Call control icons - vibrant blue */ .bt-call-controls .bt-icon, .bt-call-controls .bt-btn { color: #0ea5e9; } .bt-call-controls .bt-icon:hover, .bt-call-controls .bt-btn:hover { color: #0284c7; } /* Play/Pause button - special styling */ .bt-call-controls .bt-icon:last-child, .bt-call-controls .bt-btn:last-child { background: linear-gradient(135deg, #0ea5e9 0%, #0284c7 100%); color: white; border-color: #0ea5e9; } .bt-call-controls .bt-icon:last-child:hover, .bt-call-controls .bt-btn:last-child:hover { background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%); transform: translateY(-1px); box-shadow: 0 4px 12px rgba(14, 165, 233, 0.3); } /* Media Controls - Always visible in header, positioned left */ .bt-media-controls { display: flex; align-items: center; justify-content: center; height: 40px; /* Match toolbar height */ gap: var(--bt-spacing-2, 8px); margin-right: var(--bt-spacing-3, 12px); margin-left: var(--bt-spacing-4, 16px); } /* Override device select styling to match toolbar height */ .bt-media-controls :global([class*="deviceButtonContainer"]) { height: 40px !important; display: flex; align-items: center; justify-content: center; border-radius: var(--bt-radius-md) !important; backdrop-filter: none !important; } .bt-media-controls :global([class*="deviceButton"]) { height: 40px !important; width: 40px !important; min-width: 40px !important; border-radius: var(--bt-radius-md) !important; background: var(--bt-color-accent, #00B0FF) !important; border: var(--bt-border-1) solid rgba(0,176,255,0.3) !important; display: flex; align-items: center; justify-content: center; cursor: pointer; transition: all 0.2s ease; color: #ffffff !important; position: relative !important; left: auto !important; top: auto !important; z-index: auto !important; } /* Override specific device button classes */ .bt-media-controls :global(.device_select_deviceButton) { background-color: var(--bt-color-accent, #00B0FF) !important; border-color: rgba(0,176,255,0.3) !important; color: #ffffff !important; } .bt-media-controls :global([class*="deviceButton"]:hover) { background: rgba(0,176,255,0.1) !important; border-color: rgba(0,176,255,0.3) !important; color: #0ea5e9 !important; } .bt-media-controls :global([class*="deviceButton"]:disabled) { opacity: 0.5; cursor: not-allowed; } .bt-media-controls :global([class*="deviceButtonIcon"]) { display: flex; align-items: center; justify-content: center; width: 16px; height: 16px; } /* Override screen share button to match toolbar styling */ .bt-media-controls :global([class*="screenShareButton"]) { height: 40px !important; width: 40px !important; min-width: 40px !important; border-radius: var(--bt-radius-md) !important; background: var(--bt-color-accent, #00B0FF) !important; border: var(--bt-border-1) solid rgba(0,176,255,0.3) !important; color: #ffffff !important; backdrop-filter: none !important; } /* Override specific screen share button class */ .bt-media-controls :global(.device_select_screenShareButton) { background-color: var(--bt-color-accent, #00B0FF) !important; border-color: rgba(0,176,255,0.3) !important; color: #ffffff !important; } .bt-media-controls :global([class*="screenShareButton"]:hover) { background: rgba(0,176,255,0.1) !important; border-color: rgba(0,176,255,0.3) !important; color: #0ea5e9 !important; } /* Visual separator after media controls */ .bt-media-controls::after { content: ''; width: 1px; height: 24px; background-color: rgba(255, 255, 255, 0.2); margin-left: var(--bt-spacing-3, 12px); border-radius: 1px; } /* Hide Tavus footer controls since they're now in the header */ .bt-video :global(.footer), .bt-audio :global(.footer) { display: none !important; } /* Drag handle */ .bt-drag-handle { display: flex; align-items: center; justify-content: center; width: 24px; height: 24px; margin-left: 8px; color: #64748b; /* Subtle gray like size controls */ cursor: move; border-radius: 4px; transition: all 0.2s; } .bt-drag-handle:hover { color: #0ea5e9; /* Light blue on hover */ background: rgba(14, 165, 233, 0.1); } /* Dragging state */ .bt-dragging { opacity: 0.8; transform: scale(1.02); transition: none !important; } .bt-dragging .bt-toolbar { cursor: move; } /* Resizing state */ .bt-resizing { opacity: 0.8; transform: scale(1.02); transition: none !important; } .bt-resizing .bt-toolbar { cursor: move; } /* Resize handles - made larger for easier targeting */ .bt-resize-handle { position: absolute; width: 16px; height: 16px; background: rgba(0,176,255,0.6); border: 2px solid rgba(255,255,255,0.8); border-radius: 50%; cursor: pointer; z-index: 10; transition: all 0.2s; opacity: 0; pointer-events: none; } .bt-panel:hover .bt-resize-handle { opacity: 1; pointer-events: auto; } .bt-resize-handle:hover { background: rgba(0,176,255,1); transform: scale(1.2); border-color: rgba(255,255,255,1); } /* Corner positions with proper cursors - adjusted for larger handles */ .bt-resize-nw { top: -8px; left: -8px; cursor: nw-resize; } .bt-resize-ne { top: -8px; right: -8px; cursor: ne-resize; } .bt-resize-sw { bottom: -8px; left: -8px; cursor: sw-resize; } .bt-resize-se { bottom: -8px; right: -8px; cursor: se-resize; } /* Only show resize handles on medium modes */ .bt-size-minimal .bt-resize-handle, .bt-size-large .bt-resize-handle { display: none; } /* Toolbar layout */ .bt-toolbar { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; background: var(--bt-color-navy, #1e293b); border-bottom: var(--bt-border-1) solid var(--bt-color-border, rgba(255,255,255,0.1)); min-height: 48px; } /* Title in toolbar */ .bt-title { font: 700 18px/1.2 var(--bt-font-heading, 'Aeonik', ui-sans-serif); color: var(--bt-text-on-dark, #ffffff); margin-right: auto; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: flex; align-items: center; } .bt-title span { white-space: nowrap; display: inline-block; } /* Default responsive behavior - show full title on large screens */ .bt-title .responsive-hide-1 { display: inline; } .bt-title .responsive-hide-2 { display: none; } .bt-title .responsive-hide-3 { display: none; } .bt-title .responsive-hide-4 { display: none; } /* Control groups */ .bt-size-controls, .bt-content-controls, .bt-call-controls, .bt-interaction-controls { display: flex; gap: 6px; align-items: center; justify-content: center; height: 40px; /* Match toolbar height */ } .bt-content-controls::before, .bt-call-controls::before { content: ''; width: 1px; height: 24px; background: rgba(255,255,255,0.2); margin: 0 8px; } /* Body content - fill available space */ .bt-body { flex: 1; display: flex; flex-direction: column; min-height: 0; height: calc(100% - 48px); /* Subtract toolbar height */ } .bt-body-split { display: grid; grid-template-rows: 65% 35%; gap: 0; height: 100%; overflow: hidden; } /* Audio mode split - same as video split */ .bt-body-split.bt-body-audio-mode { grid-template-rows: 65% 35% !important; } /* Force audio mode layout with higher specificity */ .bt-body.bt-body-split.bt-body-audio-mode { grid-template-rows: 65% 35% !important; } /* Even more specific override */ .bt-panel .bt-body.bt-body-split.bt-body-audio-mode { grid-template-rows: 65% 35% !important; } .bt-video-area { display: flex; flex-direction: column; min-height: 0; overflow: hidden; } .bt-video-split { height: 100%; overflow: hidden; } .bt-video-full { height: 100%; overflow: hidden; } .bt-chat-area { display: flex; flex-direction: column; min-height: 0; overflow: hidden; } .bt-chat-split { height: 100%; border-top: var(--bt-border-1) solid var(--bt-color-border, rgba(255,255,255,0.1)); overflow: hidden; } .bt-chat-full { height: 100%; overflow: hidden; } .bt-video { width: 100%; height: 100%; } /* Video area uses conversation component's built-in CSS */ .bt-video-area { height: 100%; width: 100%; position: relative; overflow: hidden; } .bt-iframe { width: 100%; height: 100%; border: 0; } /* Visual feedback when resize constraints are applied */ .bt-constraint-applied { animation: constraint-pulse 0.3s ease-out; } @keyframes constraint-pulse { 0% { box-shadow: 0 8px 32px rgba(0,0,0,0.12); } 50% { box-shadow: 0 8px 32px rgba(0,176,255,0.3), 0 0 0 2px rgba(0,176,255,0.2); } 100% { box-shadow: 0 8px 32px rgba(0,0,0,0.12); } } /* Show aspect ratio during resize */ .bt-panel[data-aspect-ratio]:after { content: attr(data-aspect-ratio); position: absolute; top: -30px; right: 10px; background: rgba(0,0,0,0.8); color: white; padding: 4px 8px; border-radius: 4px; font-size: 12px; font-family: monospace; z-index: 2147483001; pointer-events: none; opacity: 0.9; } /* Audio area styles */ .bt-audio-area { display: flex; flex-direction: column; min-height: 0; overflow: hidden; } .bt-audio-split { height: 100%; overflow: hidden; } .bt-audio-full { height: 100%; overflow: hidden; } .bt-audio.placeholder { display: flex; flex-direction: column; align-items: center; justify-content: center; height: 100%; background: linear-gradient(135deg, #0ea5e9 0%, #0284c7 100%); color: white; gap: 8px; padding: 8px; } .bt-audio-text { font: 600 14px/1.2 var(--bt-font-heading, 'Aeonik', ui-sans-serif); color: white; } /* Audio icon in placeholder */ .bt-audio.placeholder svg { color: white; filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2)); } /* Compact audio area for split mode */ .bt-audio-split .bt-audio.placeholder { flex-direction: row; gap: 6px; padding: 4px 8px; min-height: 0; } .bt-audio-split .bt-audio.placeholder svg { width: 20px; height: 20px; } .bt-audio-split .bt-audio-text { font: 600 11px/1.2 var(--bt-font-heading, 'Aeonik', ui-sans-serif); } /* ===== OVERLAY LAYOUT STYLES ===== */ /* Overlay body container */ .bt-body-overlay { position: relative; height: 100%; overflow: hidden; } /* Video/audio areas in overlay mode */ .bt-video-overlay, .bt-audio-overlay { width: 100%; height: 100%; position: relative; } /* Chat overlay - positioned on the right 1/3 */ .bt-chat-overlay { position: absolute; top: 0; right: 0; width: 33%; height: 100%; background: transparent !important; backdrop-filter: none !important; border-left: none !important; z-index: 10; display: flex; flex-direction: column; transform: translateX(100%); transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), width 0.3s cubic-bezier(0.4, 0, 0.2, 1); overflow: hidden; box-sizing: border-box; min-width: 120px; /* Prevent chat from becoming too narrow */ max-width: 50%; /* Prevent chat from becoming too wide */ } /* Responsive chat overlay based on widget size */ @container (max-width: 500px) { .bt-chat-overlay { width: 45%; /* Wider chat for narrow widgets */ min-width: 120px; } .bt-chat-overlay .bt-chat-bubble { font-size: 11px; padding: 4px 8px; max-width: 90%; word-wrap: break-word; overflow-wrap: break-word; hyphens: auto; } .bt-chat-overlay .bt-chat-input { font-size: 11px; padding: 4px 6px; min-height: 28px; max-width: 100%; word-wrap: break-word; overflow-wrap: break-word; } .bt-chat-overlay .bt-chat-composer { padding: 4px 6px; gap: 4px; } } @container (max-width: 300px) { .bt-chat-overlay { width: 45%; /* Even wider for very narrow widgets */ min-width: 100px; } .bt-chat-overlay .bt-chat-bubble { font-size: 10px; padding: 3px 6px; max-width: 95%; word-wrap: break-word; overflow-wrap: break-word; hyphens: auto; } .bt-chat-overlay .bt-chat-input { font-size: 10px; padding: 3px 4px; min-height: 24px; max-width: 100%; word-wrap: break-word; overflow-wrap: break-word; } .bt-chat-overlay .bt-chat-composer { padding: 3px 4px; gap: 3px; } } @container (max-width: 250px) { .bt-chat-overlay { width: 50%; /* Maximum width for extremely narrow widgets */ min-width: 80px; } .bt-chat-overlay .bt-chat-bubble { font-size: 9px; padding: 2px 4px; max-width: 100%; word-wrap: break-word; overflow-wrap: break-word; } .bt-chat-overlay .bt-chat-input { font-size: 9px; padding: 2px 3px; min-height: 20px; } .bt-chat-overlay .bt-chat-composer { padding: 2px 3px; gap: 2px; } } /* Medium mode specific adjustments for typical widget sizes */ @container (max-width: 500px) { .bt-chat-overlay .bt-chat-bubble { max-width: 75%; word-wrap: break-word; overflow-wrap: break-word; hyphens: auto; } .bt-chat-overlay .bt-chat-list { padding: 8px 6px 8px 8px; } .bt-chat-overlay .bt-chat-input { max-width: 100%; word-wrap: break-word; overflow-wrap: break-word; } } /* For wider widgets, keep chat proportional but not too wide */ @container (min-width: 600px) { .bt-chat-overlay { width: 25%; /* Slightly narrower for wide widgets */ } .bt-chat-overlay .bt-chat-bubble { font-size: 13px; padding: 8px 12px; max-width: 88%; } .bt-chat-overlay .bt-chat-input { font-size: 13px; padding: 8px 10px; min-height: 36px; } .bt-chat-overlay .bt-chat-composer { padding: 8px 10px; gap: 8px; } } @container (min-width: 800px) { .bt-chat-overlay { width: 22%; /* Even narrower for very wide widgets */ } .bt-chat-overlay .bt-chat-bubble { font-size: 14px; padding: 10px 14px; } .bt-chat-overlay .bt-chat-input { font-size: 14px; padding: 10px 12px; min-height: 40px; } .bt-chat-overlay .bt-chat-composer { padding: 10px 12px; gap: 10px; } } /* Show overlay when chat is active */ .bt-chat-overlay.active { transform: translateX(0); animation: overlaySlideIn 0.3s cubic-bezier(0.4, 0, 0.2, 1); } @keyframes overlaySlideIn { from { opacity: 0; transform: translateX(100%); } to { opacity: 1; transform: translateX(0); } } /* Alternative backdrop with gradient */ .bt-chat-overlay.gradient-backdrop { background: linear-gradient(135deg, rgba(255, 255, 255, 0.6) 0%, rgba(240, 248, 255, 0.5) 100%); backdrop-filter: blur(2px); } /* Compact chat styles for overlay */ .bt-chat-overlay .bt-chat-list { padding: 8px 6px 8px 8px; gap: 4px; background: transparent !important; display: flex; flex-direction: column-reverse; justify-content: flex-start; align-items: stretch; width: 100%; max-width: 100%; overflow: hidden; box-sizing: border-box; position: relative; } /* Force all direct children to stay within bounds */ .bt-chat-overlay .bt-chat-list > * { max-width: 100% !important; overflow: hidden !important; box-sizing: border-box !important; } /* Specific constraint for chat message containers */ .bt-chat-overlay .bt-chat-msg { max-width: 100% !important; overflow: hidden !important; box-sizing: border-box !important; width: 100% !important; } .bt-chat-overlay .bt-chat-bubble { max-width: 85%; padding: 6px 10px; font-size: 12px; line-height: 1.3; border-radius: 12px; backdrop-filter: blur(4px); box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15); word-wrap: break-word; overflow-wrap: break-word; hyphens: auto; color: rgba(0, 0, 0, 0.9) !important; overflow: hidden; box-sizing: border-box; width: fit-content; max-width: calc(100% - 16px); white-space: normal; word-break: break-word; } .bt-chat-overlay .bt-chat-composer { padding: 6px 8px; gap: 6px; background: transparent !important; backdrop-filter: none !important; border-top: 1px solid rgba(0, 0, 0, 0.1); box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.1); z-index: 5; } .bt-chat-overlay .bt-chat-input { min-height: 32px; max-height: 60px; padding: 6px 32px 6px 8px; font-size: 12px; line-height: 1.3; background: rgba(255, 255, 255, 0.3) !important; backdrop-filter: blur(2px) !important; border: 1px solid rgba(0, 0, 0, 0.1); box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1); position: relative; color: rgba(0, 0, 0, 0.9) !important; } .bt-chat-overlay .bt-chat-input::placeholder { color: rgba(0, 0, 0, 0.6) !important; } .bt-chat-overlay .bt-chat-send { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); width: 20px; height: 20px; padding: 0; background: transparent; border: none; color: var(--bt-color-accent); cursor: pointer; display: flex; align-items: center; justify-content: center; border-radius: 50%; transition: all 0.2s ease; } .bt-chat-overlay .bt-chat-send:hover { background: rgba(0, 176, 255, 0.1); transform: translateY(-50%) scale(1.1); } .bt-chat-overlay .bt-chat-send svg { width: 14px; height: 14px; } /* Responsive adjustments for overlay */ @media (max-width: 768px) { .bt-chat-overlay { width: 40%; } } @media (max-width: 480px) { .bt-chat-overlay { width: 50%; } .bt-chat-overlay .bt-chat-bubble { font-size: 11px; padding: 5px 8px; } .bt-chat-overlay .bt-chat-input { font-size: 11px; min-height: 28px; } .bt-chat-overlay .bt-chat-send { height: 28px; padding: 0 8px; font-size: 11px; } } .bt-cta { display:inline-flex; align-items:center; justify-content:center; gap:8px; padding: 0 18px; color: var(--bt-cta-text); background: var(--bt-cta-gradient); border: 0; border-radius: var(--bt-radius-button-lg); cursor: pointer; transition: transform var(--bt-cta-transition), box-shadow var(--bt-cta-transition), background var(--bt-cta-transition); box-shadow: 0 8px 20px rgba(0, 176, 255, 0.25); } .bt-cta-sm { height: 36px; border-radius: var(--bt-radius-md); padding: 0 14px; } .bt-cta:hover { background: var(--bt-cta-gradient-hover); transform: translateY(-1px); } .bt-cta:active { transform: scale(var(--bt-cta-press-scale)); } .bt-cta-danger { background: linear-gradient(90deg, #ef4444, #dc2626); } /* Chat styles */ .bt-chat, .bt-chat-only { display: grid; grid-template-rows: 1fr auto; height: 100%; } .bt-chat-only .bt-chat { height: 100%; } .bt-chat-list { padding: 16px; overflow: auto; display: flex; flex-direction: column; gap: 8px; background: transparent !important; } .bt-chat-msg { display: flex; align-items: flex-end; } .bt-chat-msg.user { justify-content: flex-end; } .bt-chat-msg.assistant { justify-content: flex-start; } .bt-chat-bubble { display: inline-block; max-width: 72%; padding: 8px 12px; border-radius: 16px; font-size: var(--bt-body-size, 14px); line-height: var(--bt-body-leading, 20px); font-family: var(--bt-font-base, 'Aeonik', ui-sans-serif); } .bt-chat-msg.user .bt-chat-bubble { background: var(--bt-color-navy); color: var(--bt-text-on-dark); box-shadow: 0 6px 12px rgba(0,0,0,0.18); } .bt-chat-msg.assistant .bt-chat-bubble { background: var(--bt-bg-subtle); color: var(--bt-text); border: var(--bt-border-1) solid var(--bt-color-border); } /* Enhanced overlay message bubbles for better visibility */ .bt-chat-overlay .bt-chat-msg.user .bt-chat-bubble { background: rgba(255, 255, 255, 0.85) !important; color: #000000 !important; border: 1px solid rgba(0, 0, 0, 0.1); box-shadow: 0 4px 12px rgba(0,0,0,0.15); backdrop-filter: none !important; text-shadow: none !important; max-width: calc(100% - 16px) !important; overflow: hidden !important; box-sizing: border-box !important; white-space: normal !important; word-break: break-word !important; word-wrap: break-word !important; overflow-wrap: break-word !important; } .bt-chat-overlay .bt-chat-msg.assistant .bt-chat-bubble { background: rgba(30, 41, 59, 0.85) !important; color: #ffffff !important; box-shadow: 0 4px 12px rgba(0,0,0,0.3); backdrop-filter: none !important; text-shadow: none !important; max-width: calc(100% - 16px) !important; overflow: hidden !important; box-sizing: border-box !important; white-space: normal !important; word-break: break-word !important; word-wrap: break-word !important; overflow-wrap: break-word !important; } .bt-chat-composer { display:flex; gap: 8px; padding: 10px 12px; border-top: var(--bt-border-1) solid var(--bt-color-border); background: transparent !important; } .bt-chat-input { flex: 1; resize: none; border-radius: var(--bt-radius-md); border: var(--bt-border-1) solid var(--bt-color-border); padding: 8px 10px; font: 400 var(--bt-body-size,14px)/var(--bt-body-leading,20px) var(--bt-font-base, 'Aeonik', ui-sans-serif); background: var(--bt-bg); color: var(--bt-text); min-height: 36px; max-height: 80px; } .bt-chat-input:focus { outline: var(--bt-outline-accent); outline-offset: 2px; } .bt-chat-send { border-radius: var(--bt-radius-md); border: 0; padding: 0 14px; background: var(--bt-color-accent); color: #fff; cursor: pointer; height: 38px; font-family: var(--bt-font-base, 'Aeonik', ui-sans-serif); } /* Error notification styles */ .bt-error-notification { position: fixed; top: 20px; right: 20px; background: #fee2e2; border: 1px solid #fecaca; border-radius: 8px; padding: 12px; max-width: 300px; z-index: 2147483001; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); animation: slideInRight 0.3s ease-out; } .bt-error-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; } .bt-error-title { font-weight: 600; color: #dc2626; font-size: 14px; font-family: var(--bt-font-base, 'Aeonik', ui-sans-serif); } .bt-error-close { background: none; border: none; color: #dc2626; cursor: pointer; font-size: 18px; padding: 0; width: 20px; height: 20px; display: flex; align-items: center; justify-content: center; border-radius: 4px; } .bt-error-close:hover { background: rgba(220, 38, 38, 0.1); } .bt-error-message { color: #991b1b; font-size: 13px; line-height: 1.4; font-family: var(--bt-font-base, 'Aeonik', ui-sans-serif); } /* Loading overlay styles */ .bt-loading-overlay { position: absolute; top: 0; left: 0; right: 0; bottom: 0; background: rgba(0, 0, 0, 0.7); display: flex; flex-direction: column; align-items: center; justify-content: center; z-index: 1000; border-radius: 8px; } .bt-loading-spinner { width: 32px; height: 32px; border: 3px solid rgba(255, 255, 255, 0.3); border-top: 3px solid #ffffff; border-radius: 50%; animation: spin 1s linear infinite; margin-bottom: 12px; } .bt-loading-text { color: #ffffff; font-size: 14px; font-family: var(--bt-font-base, 'Aeonik', ui-sans-serif); text-align: center; } /* Animations */ @keyframes slideInRight { from { transform: translateX(100%); opacity: 0; } to { transform: translateX(0); opacity: 1; } } @keyframes spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } } /* Accessibility improvements */ .sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; } /* Focus indicators for keyboard navigation */ .bt-icon:focus, .bt-btn:focus { outline: 2px solid var(--bt-color-accent, #3b82f6); outline-offset: 2px; border-radius: 6px; } /* High contrast mode support */ @media (prefers-contrast: high) { .bt-icon { border: 2px solid currentColor; } .bt-error-notification { border: 2px solid #dc2626; } } /* Reduced motion support */ @media (prefers-reduced-motion: reduce) { .bt-loading-spinner { animation: none; } .bt-error-notification { animation: none; } } /* Mock Conversation Styles */ .bt-mock-conversation { display: flex; flex-direction: column; height: 100%; background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); border-radius: 8px; overflow: hidden; position: relative; } .bt-mock-video-placeholder { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 20px; background: rgba(255, 255, 255, 0.1); } .bt-mock-avatar { margin-bottom: 16px; } .bt-mock-avatar-circle { width: 80px; height: 80px; border-radius: 50%; background: rgba(255, 255, 255, 0.2); display: flex; align-items: center; justify-content: center; font-size: 40px; backdrop-filter: blur(10px); border: 2px solid rgba(255, 255, 255, 0.3); } .bt-mock-status { text-align: center; } .bt-mock-status-text { color: white; font-size: 18px; font-weight: 600; margin-bottom: 4px; font-family: var(--bt-font-base, 'Aeonik', ui-sans-serif); } .bt-mock-status-indicator { color: #4ade80; font-size: 14px; font-weight: 500; font-family: var(--bt-font-base, 'Aeonik', ui-sans-serif); } .bt-mock-conversation-info { background: rgba(0, 0, 0, 0.3); padding: 16px; text-align: center; } .bt-mock-title { color: white; font-size: 16px; font-weight: 600; margin-bottom: 4px; font-family: var(--bt-font-base, 'Aeonik', ui-sans-serif); } .bt-mock-subtitle { color: rgba(255, 255, 255, 0.8); font-size: 12px; margin-bottom: 8px; font-family: var(--bt-font-base, 'Aeonik', ui-sans-serif); } .bt-mock-timer { color: #fbbf24; font-size: 14px; font-weight: 500; font-family: var(--bt-font-base, 'Aeonik', ui-sans-serif); } /* Audio mode specific styles */ .bt-mock-audio { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); border-radius: 12px; padding: 20px; color: white; text-align: center; } .bt-mock-audio-placeholder { display: flex; flex-direction: column; align-items: center; gap: 12px; margin-bottom: 16px; } .bt-mock-audio-icon { background: rgba(255, 255, 255, 0.2); border-radius: 50%; width: 80px; height: 80px; display: flex; align-items: center; justify-content: center; color: white; } .bt-mock-audio-status { text-align: center; } .bt-mock-audio-status-text { font-size: 16px; font-weight: 600; margin-bottom: 4px; font-family: var(--bt-font-base, 'Aeonik', ui-sans-serif); } .bt-mock-audio-status-indicator { font-size: 12px; color: #10b981; font-weight: 500; font-family: var(--bt-font-base, 'Aeonik', ui-sans-serif); } .bt-panel { transition: none; } } `;