Spaces:
Sleeping
Sleeping
| /* ============================ | |
| GLOBAL THEME & VARIABLES | |
| ============================ */ | |
| :root { | |
| /* Text Colors */ | |
| --primarytext-color: #1a1a1a; | |
| --secondarytext-color: #555; | |
| /* Primary Colors */ | |
| --primary-dark: #345da8; | |
| --primary-light: #a8b5c9; | |
| /* Secondary Colors */ | |
| --secondary-dark: #063d80; | |
| --secondary-light: #6ea1fa; | |
| /* Chat & Container Colors */ | |
| --chathistory_area: #f0f1f4; | |
| --container-color: #f5f6f8; | |
| --Send: #6ea1fa; | |
| --Send-hover: #87d0d5; | |
| --clear: #b2b8c2; | |
| --clear-hover: #2c5be0; | |
| --text_areabackground: #fafafa; | |
| /* Chat Bubble Colors */ | |
| --bot-bubble-color: #b9c8e3; | |
| --user-bubble-color: #e3eaf6; | |
| /* Scrollbar Colors */ | |
| --scrollbar-bg: #d0d3d8; | |
| --scrollbar-thumb: #a2a6ad; | |
| --scrollbar-thumb-hover: #888d94; | |
| /* Border & Radius */ | |
| --border-thin: 1px; | |
| --border-medium: 2px; | |
| --border-default: 1px; | |
| --border-focus: 2px; | |
| --border-hover: 3px; | |
| --button-border: 2px; | |
| --radius-sm: 4px; | |
| --radius-md: 6px; | |
| } | |
| /* ============================ | |
| DARK MODE THEME (SOFTER) | |
| ============================ */ | |
| @media (prefers-color-scheme: dark) { | |
| :root { | |
| --primarytext-color: #f8f8f8; | |
| --secondarytext-color: #d0d3d8; | |
| --primary-dark: #27477d; | |
| --primary-light: #7d8da9; | |
| --secondary-dark: #042a59; | |
| --secondary-light: #5e88d6; | |
| --chathistory_area: #202327; | |
| --container-color: #1b1d20; | |
| --Send: #5e88d6; | |
| --Send-hover: #7ac4c9; | |
| --clear: #7a7f88; | |
| --clear-hover: #5e88d6; | |
| --text_areabackground: #25282c; | |
| --bot-bubble-color: #425575; | |
| --user-bubble-color: #566583; | |
| --scrollbar-bg: #2b2e33; | |
| --scrollbar-thumb: #4b4f56; | |
| --scrollbar-thumb-hover: #5e636b; | |
| } | |
| } | |
| /* ============================ | |
| FONT IMPORT & BASE STYLING | |
| ============================ */ | |
| @import url('https://fonts.googleapis.com/css2?family=Oswald:wght@200..700&display=swap'); | |
| body { | |
| background: var(--text_areabackground); | |
| color: var(--primarytext-color); | |
| font-family: "Oswald", sans-serif; | |
| margin: 0; | |
| } | |
| * { | |
| color: var(--primarytext-color) ; | |
| font-family: "Oswald", sans-serif ; | |
| box-sizing: border-box; | |
| } | |
| /* ============================ | |
| CUSTOM SCROLLBAR | |
| ============================ */ | |
| ::-webkit-scrollbar { | |
| width: 12px; | |
| } | |
| ::-webkit-scrollbar-track { | |
| background: var(--scrollbar-bg); | |
| } | |
| ::-webkit-scrollbar-thumb { | |
| background-color: var(--scrollbar-thumb); | |
| border-radius: 6px; | |
| border: 2px solid var(--scrollbar-bg); | |
| } | |
| ::-webkit-scrollbar-thumb:hover { | |
| background-color: var(--scrollbar-thumb-hover); | |
| } | |
| /* ============================ | |
| GRADIO CONTAINER & LAYOUT | |
| ============================ */ | |
| .gradio-container, | |
| [data-testid="block-container"], | |
| .contain { | |
| background-color: var(--container-color) ; | |
| font-family: "Oswald", sans-serif ; | |
| display: flex ; | |
| flex-direction: column ; | |
| height: 100vh ; | |
| max-height: 100vh ; | |
| overflow: hidden ; | |
| } | |
| /* ============================ | |
| HEADER & NAVIGATION | |
| ============================ */ | |
| .title-header { | |
| background-color: transparent; | |
| padding: 10px; | |
| border-bottom: var(--border-focus) solid var(--primary-dark); | |
| display: flex; | |
| align-items: center; | |
| height: 60px ; | |
| } | |
| .title-header h1 { | |
| font-size: 3.5rem; | |
| font-weight: 700; | |
| color: var(--primarytext-color); | |
| margin: 0; | |
| } | |
| /* ============================ | |
| CHAT CONTAINER | |
| ============================ */ | |
| #main-chatbot, | |
| [data-testid="chatbot"], | |
| .gradio-chatbot, | |
| [role="log"] { | |
| border: var(--border-default) solid var(--primary-dark) ; | |
| border-radius: var(--radius-md) ; | |
| background-color: var(--chathistory_area) ; | |
| box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1) ; | |
| padding: 15px ; | |
| margin: 15px 20px ; | |
| flex: 1 ; | |
| overflow-y: auto ; | |
| } | |
| /* ============================ | |
| TEXT INPUT AREA | |
| ============================ */ | |
| textarea, | |
| .gradio-textbox textarea { | |
| background-color: var(--text_areabackground) ; | |
| border: var(--border-default) solid var(--secondary-dark) ; | |
| border-radius: var(--radius-md) ; | |
| color: var(--primarytext-color) ; | |
| padding: 10px ; | |
| resize: none ; | |
| box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) ; | |
| } | |
| textarea:focus { | |
| border-color: var(--secondary-light) ; | |
| box-shadow: 0 0 0 var(--border-focus) rgba(96, 165, 250, 0.2) ; | |
| } | |
| /* ============================ | |
| BUTTONS | |
| ============================ */ | |
| button.send-button { | |
| background-color: var(--Send) ; | |
| color: var(--primarytext-color) ; | |
| border: var(--button-border) solid var(--secondary-dark) ; | |
| border-radius: var(--radius-md) ; | |
| padding: 8px 16px ; | |
| font-weight: 600 ; | |
| box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); | |
| width: 100%; | |
| } | |
| button.send-button:hover { | |
| background-color: var(--Send-hover) ; | |
| } | |
| button.clear-button { | |
| background-color: var(--clear) ; | |
| color: var(--primarytext-color) ; | |
| border: var(--button-border) solid var(--secondary-dark) ; | |
| border-radius: var(--radius-md) ; | |
| padding: 8px 16px ; | |
| font-weight: 600 ; | |
| box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); | |
| width: 100%; | |
| } | |
| button.clear-button:hover { | |
| background-color: var(--clear-hover) ; | |
| } | |
| /* ============================ | |
| CHAT BUBBLES (VARIABLE COLORS) | |
| ============================ */ | |
| .message.user, | |
| .message.bot { | |
| background: none ; | |
| border: none ; | |
| padding: 0 ; | |
| margin: 0 ; | |
| box-shadow: none ; | |
| } | |
| .message-row { | |
| display: flex; | |
| margin: 8px 12px; | |
| } | |
| .message.panel-full-width { | |
| max-width: 80%; | |
| min-width: 240px; | |
| padding: 14px 20px ; | |
| border-radius: 18px ; | |
| box-shadow: none ; | |
| position: relative; | |
| line-height: 1.5; | |
| word-wrap: break-word; | |
| } | |
| /* Bot Bubble */ | |
| .message-row.bot-row .message.panel-full-width { | |
| background-color: var(--bot-bubble-color) ; | |
| color: var(--primarytext-color) ; | |
| margin-right: auto; | |
| margin-left: 0; | |
| } | |
| .message-row.bot-row .message.panel-full-width::before { | |
| content: ""; | |
| position: absolute; | |
| top: 12px; | |
| left: -10px; | |
| width: 0; | |
| height: 0; | |
| border-top: 10px solid transparent; | |
| border-right: 10px solid var(--bot-bubble-color); | |
| border-bottom: 10px solid transparent; | |
| } | |
| /* User Bubble */ | |
| .message-row.user-row .message.panel-full-width { | |
| background-color: var(--user-bubble-color) ; | |
| color: var(--primarytext-color) ; | |
| margin-left: auto; | |
| margin-right: 0; | |
| } | |
| .message-row.user-row .message.panel-full-width::before { | |
| content: ""; | |
| position: absolute; | |
| top: 12px; | |
| right: -10px; | |
| width: 0; | |
| height: 0; | |
| border-top: 10px solid transparent; | |
| border-left: 10px solid var(--user-bubble-color); | |
| border-bottom: 10px solid transparent; | |
| } | |
| /* ============================ | |
| RESPONSIVE ADJUSTMENTS | |
| ============================ */ | |
| @media (max-width: 768px) { | |
| .message.panel-full-width { | |
| max-width: 85%; | |
| } | |
| } | |
| /* ============================ | |
| FOOTER: RESTORE BUILT-IN GRADIO LINKS (settings, API, etc.) | |
| ============================ */ | |
| footer.svelte-czcr5b { | |
| display: flex ; | |
| align-items: center ; | |
| justify-content: center ; | |
| gap: 12px ; | |
| visibility: visible ; | |
| position: fixed ; | |
| bottom: 0 ; | |
| left: 0 ; | |
| right: 0 ; | |
| background-color: var(--container-color) ; | |
| backdrop-filter: blur(5px) ; | |
| border-top: var(--border-default) solid rgba(0, 0, 0, 0.12) ; | |
| padding: 8px 16px ; | |
| z-index: 1000 ; | |
| min-height: 36px ; | |
| } | |
| footer.svelte-czcr5b a, | |
| footer.svelte-czcr5b button, | |
| footer.svelte-czcr5b span { | |
| color: var(--secondarytext-color) ; | |
| font-size: 12px ; | |
| font-family: "Oswald", sans-serif ; | |
| text-decoration: none ; | |
| background: none ; | |
| border: none ; | |
| cursor: pointer ; | |
| opacity: 0.8; | |
| transition: opacity 0.15s ease; | |
| } | |
| footer.svelte-czcr5b a:hover, | |
| footer.svelte-czcr5b button:hover, | |
| footer.svelte-czcr5b span:hover { | |
| opacity: 1; | |
| color: var(--primarytext-color) ; | |
| } | |
| /* Divider style between footer links */ | |
| footer.svelte-czcr5b .divider { | |
| color: var(--secondarytext-color) ; | |
| opacity: 0.5; | |
| margin: 0 6px ; | |
| } | |
| /* Make sure footer items never collapse */ | |
| footer.svelte-czcr5b > * { | |
| display: inline-flex ; | |
| align-items: center ; | |
| } |