Team Ai
Apppublic

Decoder2704/python-chatbot-jay

sourceHugging Faceupdated 7mo agoView on Hugging Face
0likes
Chatbot.css350 linesDownload Raw Back to pages
1.chat-dashboard {2  display: grid;3  grid-template-columns: minmax(260px, 300px) minmax(0, 1fr);4  gap: 1.5rem;5  width: 100%;6  max-width: 1440px;7  margin: 0 auto;8  padding: 1.5rem 1.25rem 2rem;9  min-height: calc(100vh - 4rem);10  align-items: start;11  box-sizing: border-box;12}13 14.chat-dashboard__sidebar {15  display: flex;16  flex-direction: column;17  gap: 1rem;18}19 20.chat-dashboard__main {21  min-width: 0;22  display: flex;23  flex-direction: column;24}25 26.chat-panel {27  display: flex;28  flex-direction: column;29  flex: 1;30  min-height: min(720px, calc(100vh - 8rem));31  max-height: calc(100vh - 6rem);32  background: #ffffff;33  border: 1px solid rgba(15, 23, 42, 0.07);34  border-radius: 20px;35  box-shadow: 0 4px 24px rgba(15, 23, 42, 0.07);36  overflow: hidden;37  transition: box-shadow var(--duration-normal) var(--ease-standard);38}39 40@media (hover: hover) {41  .chat-panel:hover {42    box-shadow: 0 6px 32px rgba(15, 23, 42, 0.09);43  }44}45 46.chat-panel__header {47  display: flex;48  align-items: center;49  justify-content: space-between;50  gap: 1rem;51  padding: 1rem 1.25rem;52  border-bottom: 1px solid rgba(15, 23, 42, 0.06);53  flex-shrink: 0;54}55 56.chat-panel__title-row {57  display: flex;58  align-items: center;59  gap: 0.5rem;60}61 62.chat-panel__title {63  margin: 0;64  font-size: 1.125rem;65  font-weight: 700;66  letter-spacing: -0.02em;67  color: #0f172a;68}69 70.chat-panel__online {71  display: inline-flex;72  align-items: center;73  gap: 0.35rem;74  font-size: 0.75rem;75  font-weight: 600;76  color: #16a34a;77}78 79.chat-panel__online-dot {80  width: 8px;81  height: 8px;82  background: #22c55e;83  border-radius: 50%;84  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.25);85  animation: pulse-dot 2s ease-in-out infinite;86}87 88@keyframes pulse-dot {89  0%,90  100% {91    opacity: 1;92  }93  50% {94    opacity: 0.7;95  }96}97 98.chat-panel__toolbar {99  display: flex;100  align-items: center;101  gap: 0.35rem;102}103 104.chat-panel__tool-btn {105  display: flex;106  align-items: center;107  justify-content: center;108  width: 2.5rem;109  height: 2.5rem;110  padding: 0;111  color: #64748b;112  background: transparent;113  border: none;114  border-radius: 10px;115  cursor: pointer;116  transition:117    color var(--duration-normal) var(--ease-standard),118    background var(--duration-normal) var(--ease-standard),119    transform var(--duration-fast) var(--ease-standard);120}121 122.chat-panel__tool-btn:hover {123  color: #6366f1;124  background: rgba(99, 102, 241, 0.1);125}126 127.chat-panel__tool-btn:active {128  transform: scale(0.94);129}130 131.chat-panel__tool-btn:focus-visible {132  outline: none;133  box-shadow: var(--focus-ring);134}135 136/* Scrollable middle: welcome OR conversation */137.chat-panel__scroll {138  flex: 1;139  min-height: 0;140  overflow-y: auto;141  overflow-x: hidden;142  -webkit-overflow-scrolling: touch;143}144 145.chat-panel__welcome {146  display: flex;147  flex-direction: column;148  align-items: center;149  text-align: center;150  gap: 0.25rem;151  padding: clamp(1.75rem, 4vw, 2.5rem) clamp(1.25rem, 3vw, 2rem) clamp(2rem, 5vw, 2.75rem);152  min-height: min(460px, 55vh);153  justify-content: center;154}155 156.chat-panel__welcome h2 {157  margin: 0 0 0.35rem;158  font-size: clamp(1.5rem, 3vw, 1.85rem);159  font-weight: 800;160  letter-spacing: -0.03em;161  color: #0f172a;162}163 164.chat-panel__welcome p {165  margin: 0 0 2rem;166  max-width: 28rem;167  font-size: 0.9375rem;168  line-height: 1.65;169  color: #64748b;170}171 172.chat-panel__prompts {173  display: grid;174  grid-template-columns: repeat(2, minmax(0, 1fr));175  gap: 0.85rem;176  width: 100%;177  max-width: 640px;178}179 180@media (max-width: 640px) {181  .chat-panel__prompts {182    grid-template-columns: 1fr;183    gap: 0.65rem;184  }185}186 187.chat-panel__conversation {188  padding: 1.25rem 1.35rem 1.5rem;189}190 191.chat-panel__messages {192  display: flex;193  flex-direction: column;194  gap: 1rem;195}196 197.chat-panel__scroll-anchor {198  height: 1px;199  width: 100%;200  flex-shrink: 0;201}202 203/* Typing / thinking row (bot-aligned) */204.chat-panel__typing {205  display: flex;206  align-items: flex-end;207  gap: 0.65rem;208  width: 100%;209}210 211.chat-panel__typing-avatar {212  flex-shrink: 0;213  width: 2rem;214  height: 2rem;215  display: flex;216  align-items: center;217  justify-content: center;218  font-size: 0.55rem;219  font-weight: 800;220  letter-spacing: 0.02em;221  color: #6366f1;222  background: linear-gradient(145deg, rgba(99, 102, 241, 0.16) 0%, rgba(124, 58, 237, 0.1) 100%);223  border: 1px solid rgba(99, 102, 241, 0.22);224  border-radius: 50%;225}226 227.chat-panel__typing-bubble {228  display: inline-flex;229  align-items: center;230  gap: 0.5rem;231  padding: 0.65rem 1rem;232  background: #f8fafc;233  border: 1px solid rgba(15, 23, 42, 0.08);234  border-radius: 18px 18px 18px 6px;235  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.05);236}237 238.chat-panel__typing-text {239  font-size: 0.875rem;240  font-weight: 500;241  color: #64748b;242}243 244.chat-panel__spinner {245  width: 1rem;246  height: 1rem;247  border: 2px solid #e2e8f0;248  border-top-color: #6366f1;249  border-radius: 50%;250  animation: chat-spin 0.7s linear infinite;251  flex-shrink: 0;252}253 254@keyframes chat-spin {255  to {256    transform: rotate(360deg);257  }258}259 260.chat-panel__error {261  margin: 0;262  padding: 0.5rem 1.25rem;263  font-size: 0.85rem;264  color: #b91c1c;265  background: #fef2f2;266  border-top: 1px solid #fecaca;267  border-bottom: 1px solid #fecaca;268  flex-shrink: 0;269}270 271.chat-panel__chips {272  display: flex;273  flex-wrap: wrap;274  gap: 0.5rem;275  padding: 0.65rem 1.25rem;276  flex-shrink: 0;277  border-top: 1px solid rgba(15, 23, 42, 0.06);278  background: #fafbfc;279}280 281/* Fixed composer: input + disclaimer */282.chat-panel__composer {283  flex-shrink: 0;284  padding: 1rem 1.25rem 0.75rem;285  border-top: 1px solid rgba(15, 23, 42, 0.08);286  background: #ffffff;287  box-shadow: 0 -4px 16px rgba(15, 23, 42, 0.04);288}289 290.chat-panel__footer {291  margin: 0.65rem 0 0;292  padding: 0;293  font-size: 0.6875rem;294  color: #94a3b8;295  text-align: center;296}297 298@media (max-width: 1024px) {299  .chat-dashboard {300    grid-template-columns: 1fr;301    min-height: auto;302    padding: 1.25rem clamp(1rem, 3vw, 1.5rem) 1.75rem;303    gap: 1.25rem;304  }305 306  .chat-dashboard__sidebar {307    flex-direction: row;308    flex-wrap: wrap;309  }310 311  .chat-dashboard__sidebar > * {312    flex: 1 1 min(200px, 100%);313  }314 315  .chat-panel {316    max-height: none;317    min-height: min(600px, 85vh);318  }319}320 321@media (max-width: 900px) {322  .chat-dashboard__sidebar {323    flex-direction: column;324  }325 326  .chat-dashboard__sidebar > * {327    flex: 1 1 auto;328  }329}330 331@media (max-width: 640px) {332  .chat-dashboard {333    padding: 1rem 0.85rem 1.5rem;334  }335 336  .chat-panel__header {337    flex-wrap: wrap;338    justify-content: flex-end;339  }340 341  .chat-panel__title-row {342    flex: 1 1 100%;343    min-width: 0;344  }345 346  .chat-panel__toolbar {347    margin-left: auto;348  }349}350