|
6 | 6 | <title>Waste Management Assistant</title> |
7 | 7 | <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0-beta3/css/all.min.css"> |
8 | 8 | <style> |
9 | | - /* ──────────────────── CSS variables: light by default ─────────────────── */ |
| 9 | + /* ─────────────────────── CSS variables ─────────────────────── */ |
| 10 | + |
10 | 11 | :root { |
11 | | - /* neutrals */ |
| 12 | + /* neutrals (light mode) */ |
12 | 13 | --bg-body: #f5f5f5; |
13 | 14 | --bg-card: #ffffff; |
14 | 15 | --bg-chat: #e0e0e0; |
15 | 16 | --bg-user: #aae3c2; |
16 | 17 | --bg-assistant: #F6F6F9; |
| 18 | + --bg-input: #ffffff; |
17 | 19 | --border: #dddddd; |
18 | 20 | --scroll-track: #f1f1f1; |
19 | 21 | --scroll-thumb: #cccccc; |
20 | 22 |
|
21 | | - /* accent */ |
| 23 | + /* text / accent */ |
| 24 | + --text-default: #202124; |
| 25 | + --text-inverse: #ffffff; |
22 | 26 | --accent-pink: #EE125B; |
23 | 27 | } |
24 | 28 |
|
25 | | - /* ──────────────────── automatic dark-mode palette ─────────────────────── */ |
| 29 | + /* ─────────────── automatic dark-mode palette ─────────────── */ |
26 | 30 | @media (prefers-color-scheme: dark) { |
27 | 31 | :root { |
28 | | - --bg-body: #18191b; |
29 | | - --bg-card: #202124; |
30 | | - --bg-chat: #26272a; |
31 | | - --bg-user: #2d4b3a; |
32 | | - --bg-assistant: #323438; |
33 | | - --border: #3b3c3f; |
34 | | - --scroll-track: #1e1f21; |
35 | | - --scroll-thumb: #575a5d; |
36 | | - --accent-pink: #ff2e7a; |
| 32 | + --bg-body: #18191b; |
| 33 | + --bg-card: #202124; |
| 34 | + --bg-chat: #26272a; |
| 35 | + --bg-user: #2d4b3a; |
| 36 | + --bg-assistant: #323438; |
| 37 | + --bg-input: #2b2c2f; |
| 38 | + --border: #3b3c3f; |
| 39 | + --scroll-track: #1e1f21; |
| 40 | + --scroll-thumb: #575a5d; |
| 41 | + |
| 42 | + --text-default: #e8e8e8; |
| 43 | + --text-inverse: #e8e8e8; |
| 44 | + --accent-pink: #ff2e7a; |
37 | 45 | } |
38 | 46 | } |
39 | 47 |
|
40 | | - /* ─────────────── base / mobile styles ─────────────── */ |
| 48 | + /* ───────────────── base / mobile styles ───────────────── */ |
41 | 49 |
|
42 | | - html, body { |
43 | | - height: 100%; |
44 | | - margin: 0; |
45 | | - font-family: Arial, sans-serif; |
46 | | - background-color: var(--bg-body); |
47 | | - overflow: hidden; |
| 50 | + html,body{ |
| 51 | + height:100%;margin:0; |
| 52 | + font-family:Arial,sans-serif;color:var(--text-default); |
| 53 | + background:var(--bg-body);overflow:hidden; |
48 | 54 | } |
49 | 55 |
|
50 | 56 | .container{ |
51 | | - display:flex; |
52 | | - flex-direction:column; |
53 | | - height:100vh; |
54 | | - width:100%; |
55 | | - max-width:100vw; |
56 | | - margin:0; |
57 | | - box-sizing:border-box; |
58 | | - background:var(--bg-card); |
59 | | - border-radius:10px; |
| 57 | + display:flex;flex-direction:column;height:100vh;width:100%; |
| 58 | + max-width:100vw;margin:0;box-sizing:border-box; |
| 59 | + background:var(--bg-card);border-radius:10px; |
60 | 60 | } |
61 | 61 |
|
62 | 62 | .chat-container{ |
63 | | - flex-grow:1; |
64 | | - overflow-y:auto; |
65 | | - background:var(--bg-chat); |
66 | | - padding:10px; |
67 | | - box-sizing:border-box; |
68 | | - margin-bottom:70px;/* reserve space for input bar */ |
| 63 | + flex-grow:1;overflow-y:auto;background:var(--bg-chat); |
| 64 | + padding:10px;box-sizing:border-box;margin-bottom:70px; |
69 | 65 | } |
70 | 66 |
|
71 | 67 | .message{ |
72 | | - margin-bottom:10px; |
73 | | - padding:10px 15px; |
74 | | - border-radius:10px; |
75 | | - word-wrap:break-word; |
76 | | - max-width:80%; |
77 | | - box-sizing:border-box; |
78 | | - box-shadow:0 1px 3px rgba(0,0,0,0.1); |
| 68 | + margin-bottom:10px;padding:10px 15px;border-radius:10px; |
| 69 | + word-wrap:break-word;max-width:80%;box-sizing:border-box; |
| 70 | + box-shadow:0 1px 3px rgba(0,0,0,.1);color:var(--text-default); |
79 | 71 | } |
80 | | - |
81 | 72 | .user-message {background:var(--bg-user); align-self:flex-end;margin-left:auto;} |
82 | 73 | .assistant-message{background:var(--bg-assistant); align-self:flex-start;margin-right:auto;} |
83 | 74 |
|
84 | 75 | .user-image{ |
85 | | - align-self:flex-end;margin-left:auto; |
86 | | - max-width:200px;border:1px solid var(--border); |
87 | | - border-radius:10px;display:block;margin-top:10px;margin-bottom:10px; |
88 | | - background:transparent;box-shadow:none;padding:0; |
| 76 | + align-self:flex-end;margin-left:auto;max-width:200px; |
| 77 | + border:1px solid var(--border);border-radius:10px;display:block; |
| 78 | + margin:10px 0;background:transparent;box-shadow:none; |
89 | 79 | } |
90 | 80 |
|
91 | 81 | .input-container{ |
92 | 82 | display:flex;align-items:flex-end;padding:10px; |
93 | | - background:var(--bg-body);border-top:1px solid var(--border); |
| 83 | + background:var(--bg-input);border-top:1px solid var(--border); |
94 | 84 | box-sizing:border-box;position:sticky;bottom:0;left:0;right:0;width:100%; |
95 | 85 | } |
96 | 86 |
|
97 | 87 | .textarea-container{flex-grow:1;margin-left:10px;display:flex;flex-direction:column;} |
98 | 88 |
|
99 | 89 | textarea{ |
100 | | - width:100%;padding:10px 10px;font-size:16px;line-height:17px; |
101 | | - border-radius:15px;border:1px solid var(--border);background:#fff; |
| 90 | + width:100%;padding:10px;font-size:16px;line-height:17px; |
| 91 | + border-radius:15px;border:1px solid var(--border); |
| 92 | + background:var(--bg-card);color:var(--text-default); |
102 | 93 | resize:none;height:40px;max-height:150px;overflow-y:auto;box-sizing:border-box; |
103 | 94 | } |
104 | 95 |
|
|
111 | 102 | .icon-button i,button#sendButton i{font-size:30px;color:var(--accent-pink);} |
112 | 103 | button#sendButton:disabled{cursor:not-allowed;} |
113 | 104 |
|
114 | | - .chat-container::-webkit-scrollbar{width:8px;} |
115 | | - .chat-container::-webkit-scrollbar-thumb{background:var(--scroll-thumb);border-radius:5px;} |
116 | | - .chat-container::-webkit-scrollbar-track{background:var(--scroll-track);} |
| 105 | + .chat-container::-webkit-scrollbar {width:8px;} |
| 106 | + .chat-container::-webkit-scrollbar-thumb {background:var(--scroll-thumb);border-radius:5px;} |
| 107 | + .chat-container::-webkit-scrollbar-track {background:var(--scroll-track);} |
117 | 108 |
|
118 | 109 | .image-thumbnail{ |
119 | 110 | position:relative;width:50px;height:50px;border-radius:5px;overflow:visible; |
|
132 | 123 | max-width:900px;margin:0 auto;border:1px solid var(--border); |
133 | 124 | } |
134 | 125 | .chat-container{ |
135 | | - margin:20px;margin-bottom:90px;border-radius:12px; |
136 | | - background:var(--bg-chat);box-shadow:0 2px 6px rgba(0,0,0,.06); |
| 126 | + margin:20px;margin-bottom:90px;border-radius:12px;background:var(--bg-chat); |
| 127 | + box-shadow:0 2px 6px rgba(0,0,0,.06); |
137 | 128 | } |
138 | 129 | .message {max-width:60%;font-size:15px;} |
139 | 130 | .user-image{max-width:250px;} |
140 | 131 |
|
141 | 132 | .input-container{ |
142 | 133 | position:static;width:auto;margin:0 20px 20px; |
143 | | - border:1px solid var(--border);border-radius:12px; |
| 134 | + border:1px solid var(--border);border-radius:12px;background:var(--bg-input); |
144 | 135 | } |
145 | 136 | textarea{font-size:15px;padding:12px;} |
146 | 137 | .icon-button i,#sendButton i{font-size:26px;} |
|
0 commit comments