style.css 71 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171
  1. /* 现代文案撰写系统界面 - 毛玻璃效果版 */
  2. @import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');
  3. /* 导入组件样式 */
  4. @import 'components/copy-button.css';
  5. @import 'components/tables.css';
  6. @import 'components/markdown.css';
  7. /*
  8. * Z-Index 层级说明:
  9. * 1000: 用户下拉菜单、通知消息
  10. * 1001: 移动端智能体菜单遮罩层
  11. * 1002: 智能体菜单、智能体下拉按钮
  12. * 1003+: 其他高级UI元素
  13. */
  14. :root {
  15. /* 主色调更新为现代风格 */
  16. --primary-indigo: #6366f1;
  17. --primary-purple: #8b5cf6;
  18. --primary-blue: #3b82f6;
  19. --primary-teal: #14b8a6;
  20. /* 渐变色 */
  21. --indigo-purple-gradient: linear-gradient(135deg, var(--primary-indigo), var(--primary-purple));
  22. --blue-teal-gradient: linear-gradient(135deg, var(--primary-blue), var(--primary-teal));
  23. /* 状态颜色 */
  24. --success-color: #10b981;
  25. --warning-color: #f59e0b;
  26. --danger-color: #ef4444;
  27. --info-color: #3b82f6;
  28. /* 创意等级颜色 */
  29. --creative-high-color: #10b981;
  30. --creative-medium-color: #f59e0b;
  31. --creative-low-color: #ef4444;
  32. /* 中性色调 */
  33. --gray-50: #f9fafb;
  34. --gray-100: #f3f4f6;
  35. --gray-200: #e5e7eb;
  36. --gray-300: #d1d5db;
  37. --gray-400: #9ca3af;
  38. --gray-500: #6b7280;
  39. --gray-600: #4b5563;
  40. --gray-700: #374151;
  41. --gray-800: #1f2937;
  42. --gray-900: #111827;
  43. /* 阴影效果 */
  44. --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  45. --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  46. --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  47. --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  48. --shadow-inner: inset 0 2px 4px 0 rgba(0, 0, 0, 0.06);
  49. --shadow-glow-indigo: 0 0 15px 2px rgba(99, 102, 241, 0.25);
  50. --shadow-glow-purple: 0 0 15px 2px rgba(139, 92, 246, 0.25);
  51. /* 圆角设置 */
  52. --radius-sm: 0.25rem;
  53. --radius: 0.5rem;
  54. --radius-md: 0.75rem;
  55. --radius-lg: 1rem;
  56. --radius-xl: 1.5rem;
  57. --radius-full: 9999px;
  58. /* 过渡和动效 */
  59. --transition: all 0.3s ease;
  60. --transition-slow: all 0.5s ease;
  61. --transition-bounce: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
  62. /* 毛玻璃效果 */
  63. --blur-sm: 4px;
  64. --blur-md: 8px;
  65. --blur-lg: 12px;
  66. --glass-opacity: 0.7;
  67. --glass-border: 1px solid rgba(255, 255, 255, 0.2);
  68. --glass-background: rgba(255, 255, 255, 0.15);
  69. --glass-background-dark: rgba(23, 25, 35, 0.6);
  70. }
  71. /* 水波纹效果 */
  72. .ripple {
  73. position: absolute;
  74. border-radius: 50%;
  75. background-color: rgba(255, 255, 255, 0.4);
  76. transform: scale(0);
  77. animation: ripple 0.6s linear;
  78. pointer-events: none;
  79. }
  80. @keyframes ripple {
  81. to {
  82. transform: scale(4);
  83. opacity: 0;
  84. }
  85. }
  86. .btn, #reset-btn, #toggle-streaming-btn, #send-btn {
  87. position: relative;
  88. overflow: hidden;
  89. }
  90. /* 发送按钮动画效果 */
  91. #send-btn.sending {
  92. animation: sending-pulse 0.6s ease-in-out;
  93. }
  94. /* 停止按钮样式 */
  95. #send-btn.stopping {
  96. background-color: var(--danger-color);
  97. transition: background-color 0.3s ease;
  98. position: relative;
  99. }
  100. #send-btn.stopping:hover {
  101. background-color: #f43636;
  102. transform: translateY(-2px);
  103. }
  104. #send-btn.stopping svg {
  105. width: 12px;
  106. height: 12px;
  107. color: white;
  108. background-color: white;
  109. border-radius: 2px;
  110. }
  111. @keyframes sending-pulse {
  112. 0% {
  113. transform: scale(1);
  114. }
  115. 50% {
  116. transform: scale(0.92);
  117. background: var(--primary-indigo);
  118. }
  119. 100% {
  120. transform: scale(1);
  121. }
  122. }
  123. * {
  124. box-sizing: border-box;
  125. margin: 0;
  126. padding: 0;
  127. }
  128. /* 全局过渡效果 - 确保主题切换平滑 */
  129. * {
  130. transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
  131. }
  132. /* 排除不需要过渡的元素 */
  133. .typing-indicator span,
  134. .loading-spinner,
  135. .ripple,
  136. .message {
  137. transition: none !important;
  138. }
  139. html {
  140. height: 100%;
  141. scroll-behavior: smooth;
  142. }
  143. body {
  144. font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
  145. background: linear-gradient(135deg, #f5f3ff, #ede9fe, #dbeafe, #e0f2fe);
  146. background-attachment: fixed;
  147. color: var(--gray-800);
  148. line-height: 1.6;
  149. min-height: 100vh;
  150. display: flex;
  151. justify-content: center;
  152. align-items: center;
  153. padding: 20px;
  154. position: relative;
  155. overflow-x: hidden;
  156. transition: background 0.3s ease, color 0.3s ease;
  157. }
  158. /* 背景动画元素 */
  159. .glass-particles {
  160. position: fixed;
  161. top: 0;
  162. left: 0;
  163. width: 100%;
  164. height: 100%;
  165. z-index: -1;
  166. overflow: hidden;
  167. }
  168. .glass-particles::before,
  169. .glass-particles::after {
  170. content: '';
  171. position: absolute;
  172. border-radius: 50%;
  173. filter: blur(var(--blur-lg));
  174. opacity: 0.4;
  175. animation: float 20s infinite alternate ease-in-out;
  176. }
  177. .glass-particles::before {
  178. width: 300px;
  179. height: 300px;
  180. background: var(--primary-indigo);
  181. top: 10%;
  182. left: 15%;
  183. animation-delay: 0s;
  184. }
  185. .glass-particles::after {
  186. width: 250px;
  187. height: 250px;
  188. background: var(--primary-purple);
  189. bottom: 15%;
  190. right: 10%;
  191. animation-delay: -10s;
  192. }
  193. @keyframes float {
  194. 0% {
  195. transform: translate(0, 0) scale(1);
  196. }
  197. 50% {
  198. transform: translate(5%, 5%) scale(1.1);
  199. }
  200. 100% {
  201. transform: translate(-5%, -5%) scale(0.9);
  202. }
  203. }
  204. body::before {
  205. content: '';
  206. position: fixed;
  207. top: 0;
  208. left: 0;
  209. width: 100%;
  210. height: 100%;
  211. background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%236366f1' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  212. opacity: 0.5;
  213. z-index: -1;
  214. }
  215. /* 通用毛玻璃效果 */
  216. .glass-panel {
  217. background-color: rgb(255, 255, 255);
  218. backdrop-filter: blur(var(--blur-sm));
  219. -webkit-backdrop-filter: blur(var(--blur-sm));
  220. box-shadow: var(--shadow);
  221. border: var(--glass-border);
  222. transition: var(--transition);
  223. }
  224. .glass-panel:hover {
  225. box-shadow: var(--shadow-md);
  226. }
  227. .glass-header {
  228. backdrop-filter: blur(var(--blur-md));
  229. -webkit-backdrop-filter: blur(var(--blur-md));
  230. border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  231. z-index: 100;
  232. position: relative;
  233. }
  234. .chat-container {
  235. width: 100%;
  236. max-width: 1600px;
  237. height: calc(100vh - 40px);
  238. max-height: 900px;
  239. display: flex;
  240. flex-direction: row;
  241. margin: 0 auto;
  242. box-shadow: var(--shadow-lg);
  243. position: relative;
  244. background-color: rgba(255, 255, 255, 0.1);
  245. backdrop-filter: blur(var(--blur-sm));
  246. -webkit-backdrop-filter: blur(var(--blur-sm));
  247. border: var(--glass-border);
  248. border-radius: var(--radius-lg);
  249. transition: var(--transition);
  250. overflow: hidden; /* 防止内容溢出 */
  251. z-index: 1;
  252. }
  253. .chat-container:hover {
  254. box-shadow: var(--shadow-glow-indigo);
  255. }
  256. /* 历史记录侧边栏样式 */
  257. .history-sidebar {
  258. width: 280px;
  259. min-width: 280px;
  260. height: 100%;
  261. background: rgba(255, 255, 255, 0.15);
  262. backdrop-filter: blur(var(--blur-md));
  263. -webkit-backdrop-filter: blur(var(--blur-md));
  264. border-right: var(--glass-border);
  265. display: flex;
  266. flex-direction: column;
  267. position: relative;
  268. z-index: 2;
  269. }
  270. .sidebar-header {
  271. padding: 20px 16px 16px 16px;
  272. border-bottom: var(--glass-border);
  273. background: rgba(255, 255, 255, 0.1);
  274. }
  275. .logo-container {
  276. display: flex;
  277. align-items: center;
  278. gap: 12px;
  279. margin-bottom: 16px;
  280. }
  281. .sidebar-logo {
  282. width: 32px;
  283. height: 32px;
  284. border-radius: var(--radius);
  285. object-fit: contain;
  286. filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
  287. }
  288. .sidebar-title {
  289. font-size: 1.1rem;
  290. font-weight: 600;
  291. color: var(--gray-800);
  292. }
  293. .new-chat-btn {
  294. width: 100%;
  295. padding: 12px 16px;
  296. background: rgba(255, 255, 255, 0.8);
  297. border: 1px solid rgba(255, 255, 255, 0.3);
  298. border-radius: var(--radius);
  299. color: var(--gray-700);
  300. font-size: 0.9rem;
  301. font-weight: 500;
  302. cursor: pointer;
  303. display: flex;
  304. align-items: center;
  305. justify-content: center;
  306. gap: 8px;
  307. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  308. box-shadow: var(--shadow-sm);
  309. position: relative;
  310. overflow: hidden;
  311. }
  312. .new-chat-btn::before {
  313. content: '';
  314. position: absolute;
  315. top: 0;
  316. left: -100%;
  317. width: 100%;
  318. height: 100%;
  319. background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
  320. transition: left 0.5s ease;
  321. }
  322. .new-chat-btn:hover {
  323. background: rgba(255, 255, 255, 0.95);
  324. color: var(--gray-900);
  325. transform: translateY(-2px);
  326. box-shadow: var(--shadow-md);
  327. border-color: rgba(99, 102, 241, 0.3);
  328. }
  329. .new-chat-btn:hover::before {
  330. left: 100%;
  331. }
  332. .new-chat-btn:active {
  333. transform: translateY(-1px);
  334. box-shadow: var(--shadow-sm);
  335. }
  336. .new-chat-btn svg {
  337. transition: transform 0.3s ease;
  338. }
  339. .new-chat-btn:hover svg {
  340. transform: scale(1.1) rotate(90deg);
  341. }
  342. .history-content {
  343. flex: 1;
  344. overflow-y: auto;
  345. padding: 8px 0;
  346. scrollbar-width: thin;
  347. scrollbar-color: rgba(100, 116, 139, 0.3) transparent;
  348. }
  349. .history-content::-webkit-scrollbar {
  350. width: 6px;
  351. }
  352. .history-content::-webkit-scrollbar-track {
  353. background: transparent;
  354. }
  355. .history-content::-webkit-scrollbar-thumb {
  356. background-color: rgba(100, 116, 139, 0.3);
  357. border-radius: 3px;
  358. }
  359. .history-content::-webkit-scrollbar-thumb:hover {
  360. background-color: rgba(100, 116, 139, 0.5);
  361. }
  362. .history-group {
  363. margin-bottom: 24px;
  364. }
  365. .group-header {
  366. padding: 8px 16px 8px 16px;
  367. font-size: 0.8rem;
  368. font-weight: 600;
  369. color: var(--gray-500);
  370. text-transform: uppercase;
  371. letter-spacing: 0.5px;
  372. margin-bottom: 8px;
  373. position: relative;
  374. transition: all 0.3s ease;
  375. }
  376. .group-header::before {
  377. content: '';
  378. position: absolute;
  379. left: 0;
  380. top: 50%;
  381. width: 3px;
  382. height: 12px;
  383. background: linear-gradient(to bottom, var(--primary-indigo), var(--primary-purple));
  384. border-radius: 2px;
  385. transform: translateY(-50%);
  386. opacity: 0.6;
  387. transition: all 0.3s ease;
  388. }
  389. .group-header:hover {
  390. color: var(--gray-700);
  391. transform: translateX(4px);
  392. }
  393. .group-header:hover::before {
  394. opacity: 1;
  395. height: 16px;
  396. }
  397. .conversation-list {
  398. padding: 0 8px;
  399. }
  400. .conversation-item {
  401. display: flex;
  402. align-items: center;
  403. padding: 12px 16px;
  404. margin-bottom: 4px;
  405. border-radius: var(--radius);
  406. cursor: pointer;
  407. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  408. position: relative;
  409. background: transparent;
  410. border: 1px solid transparent;
  411. overflow: hidden;
  412. }
  413. .conversation-item::before {
  414. content: '';
  415. position: absolute;
  416. top: 0;
  417. left: -100%;
  418. width: 100%;
  419. height: 100%;
  420. background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.1), transparent);
  421. transition: left 0.6s ease;
  422. opacity: 0;
  423. }
  424. .conversation-item:hover {
  425. background: rgba(255, 255, 255, 0.15);
  426. border-color: rgba(255, 255, 255, 0.25);
  427. transform: translateX(4px);
  428. box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  429. }
  430. .conversation-item:hover::before {
  431. left: 100%;
  432. opacity: 1;
  433. }
  434. .conversation-item.active {
  435. background: rgba(99, 102, 241, 0.2);
  436. border-color: rgba(99, 102, 241, 0.4);
  437. box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
  438. transform: translateX(6px);
  439. }
  440. .conversation-item.active::before {
  441. background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.2), transparent);
  442. opacity: 1;
  443. }
  444. .conversation-content {
  445. flex: 1;
  446. min-width: 0;
  447. margin-right: 8px;
  448. }
  449. .conversation-title {
  450. font-size: 0.9rem;
  451. color: var(--gray-700);
  452. font-weight: 500;
  453. line-height: 1.4;
  454. overflow: hidden;
  455. text-overflow: ellipsis;
  456. white-space: nowrap;
  457. }
  458. .conversation-item.active .conversation-title {
  459. color: var(--primary-indigo);
  460. font-weight: 600;
  461. }
  462. .conversation-menu {
  463. width: 24px;
  464. height: 24px;
  465. background: transparent;
  466. border: none;
  467. border-radius: 50%;
  468. cursor: pointer;
  469. display: flex;
  470. align-items: center;
  471. justify-content: center;
  472. opacity: 0;
  473. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  474. color: var(--gray-500);
  475. position: relative;
  476. overflow: hidden;
  477. }
  478. .conversation-menu::before {
  479. content: '';
  480. position: absolute;
  481. top: 50%;
  482. left: 50%;
  483. width: 0;
  484. height: 0;
  485. background: rgba(99, 102, 241, 0.1);
  486. border-radius: 50%;
  487. transition: all 0.3s ease;
  488. transform: translate(-50%, -50%);
  489. }
  490. .conversation-item:hover .conversation-menu {
  491. opacity: 1;
  492. background: rgba(255, 255, 255, 0.1);
  493. transform: scale(1.1);
  494. }
  495. .conversation-item:hover .conversation-menu::before {
  496. width: 100%;
  497. height: 100%;
  498. }
  499. .conversation-menu:hover {
  500. background: rgba(255, 255, 255, 0.2);
  501. color: var(--gray-700);
  502. transform: scale(1.2);
  503. }
  504. .conversation-menu:hover::before {
  505. background: rgba(99, 102, 241, 0.2);
  506. }
  507. .sidebar-footer {
  508. padding: 16px;
  509. border-top: var(--glass-border);
  510. background: rgba(255, 255, 255, 0.05);
  511. }
  512. .user-profile {
  513. display: flex;
  514. align-items: center;
  515. gap: 12px;
  516. padding: 12px;
  517. border-radius: var(--radius);
  518. background: rgba(255, 255, 255, 0.1);
  519. border: 1px solid rgba(255, 255, 255, 0.2);
  520. cursor: pointer;
  521. transition: var(--transition);
  522. }
  523. .user-profile:hover {
  524. background: rgba(255, 255, 255, 0.15);
  525. border-color: rgba(255, 255, 255, 0.3);
  526. }
  527. .user-avatar-sidebar {
  528. width: 32px;
  529. height: 32px;
  530. border-radius: 50%;
  531. overflow: hidden;
  532. background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  533. border: 2px solid rgba(255, 255, 255, 0.3);
  534. flex-shrink: 0;
  535. }
  536. .user-avatar-sidebar img {
  537. width: 100%;
  538. height: 100%;
  539. object-fit: cover;
  540. }
  541. .avatar-fallback-sidebar {
  542. width: 100%;
  543. height: 100%;
  544. background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  545. display: flex;
  546. align-items: center;
  547. justify-content: center;
  548. color: white;
  549. font-weight: 600;
  550. font-size: 14px;
  551. text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  552. }
  553. .user-info-sidebar {
  554. flex: 1;
  555. min-width: 0;
  556. }
  557. .user-name-sidebar {
  558. font-size: 0.9rem;
  559. font-weight: 600;
  560. color: var(--gray-800);
  561. white-space: nowrap;
  562. overflow: hidden;
  563. text-overflow: ellipsis;
  564. }
  565. .user-menu-btn {
  566. width: 24px;
  567. height: 24px;
  568. background: transparent;
  569. border: none;
  570. border-radius: 50%;
  571. cursor: pointer;
  572. display: flex;
  573. align-items: center;
  574. justify-content: center;
  575. opacity: 0.6;
  576. transition: var(--transition);
  577. color: var(--gray-500);
  578. }
  579. .user-profile:hover .user-menu-btn {
  580. opacity: 1;
  581. background: rgba(255, 255, 255, 0.1);
  582. }
  583. .user-menu-btn:hover {
  584. background: rgba(255, 255, 255, 0.2);
  585. color: var(--gray-700);
  586. }
  587. /* 对话上下文菜单样式 */
  588. .conversation-context-menu {
  589. position: absolute;
  590. background: rgba(255, 255, 255, 0.95);
  591. backdrop-filter: blur(20px);
  592. -webkit-backdrop-filter: blur(20px);
  593. border: 1px solid rgba(255, 255, 255, 0.3);
  594. border-radius: 8px;
  595. box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
  596. padding: 8px 0;
  597. min-width: 120px;
  598. z-index: 1000;
  599. opacity: 0;
  600. transform: scale(0.9);
  601. transition: all 0.2s ease;
  602. }
  603. .conversation-context-menu.show {
  604. opacity: 1;
  605. transform: scale(1);
  606. }
  607. .menu-item {
  608. display: flex;
  609. align-items: center;
  610. gap: 8px;
  611. padding: 8px 16px;
  612. cursor: pointer;
  613. transition: background-color 0.2s ease;
  614. color: var(--gray-700);
  615. font-size: 0.9rem;
  616. }
  617. .menu-item:hover {
  618. background: rgba(99, 102, 241, 0.1);
  619. color: var(--primary-indigo);
  620. }
  621. .menu-item svg {
  622. width: 16px;
  623. height: 16px;
  624. flex-shrink: 0;
  625. }
  626. /* 主聊天区域样式 */
  627. .main-chat-area {
  628. flex: 1;
  629. display: flex;
  630. flex-direction: column;
  631. min-width: 0;
  632. height: 100%;
  633. }
  634. /* 智能体切换菜单栏样式 */
  635. .agent-switcher-container {
  636. position: absolute;
  637. left: -280px;
  638. top: 80px;
  639. width: 260px;
  640. z-index: 20;
  641. }
  642. .agent-switcher {
  643. width: 100%;
  644. background: rgba(255, 255, 255, 0.15);
  645. backdrop-filter: blur(var(--blur-md));
  646. -webkit-backdrop-filter: blur(var(--blur-md));
  647. border: var(--glass-border);
  648. border-radius: var(--radius-lg);
  649. padding: 20px;
  650. box-shadow: var(--shadow-lg);
  651. transition: var(--transition);
  652. }
  653. .agent-switcher:hover {
  654. box-shadow: var(--shadow-glow-indigo);
  655. transform: translateX(5px);
  656. }
  657. /* 状态指示器样式 */
  658. .agent-status-indicator {
  659. display: flex;
  660. align-items: center;
  661. gap: 10px;
  662. margin-bottom: 20px;
  663. padding: 12px 16px;
  664. background: rgba(255, 255, 255, 0.1);
  665. border-radius: var(--radius);
  666. border: 1px solid rgba(255, 255, 255, 0.2);
  667. }
  668. .status-dot {
  669. width: 8px;
  670. height: 8px;
  671. border-radius: 50%;
  672. background: var(--success-color);
  673. animation: pulse 2s infinite;
  674. }
  675. .status-dot.active {
  676. background: var(--primary-indigo);
  677. }
  678. .status-text {
  679. font-size: 0.9rem;
  680. color: var(--gray-700);
  681. font-weight: 500;
  682. }
  683. #current-platform-name {
  684. color: var(--primary-indigo);
  685. font-weight: 600;
  686. }
  687. @keyframes pulse {
  688. 0% {
  689. opacity: 1;
  690. }
  691. 50% {
  692. opacity: 0.5;
  693. }
  694. 100% {
  695. opacity: 1;
  696. }
  697. }
  698. .agent-switcher-header {
  699. margin-bottom: 20px;
  700. padding-bottom: 15px;
  701. border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  702. }
  703. .agent-switcher-header h3 {
  704. margin: 0 0 10px 0;
  705. font-size: 1.1rem;
  706. font-weight: 600;
  707. color: var(--gray-800);
  708. text-align: center;
  709. }
  710. .current-agent {
  711. display: flex;
  712. align-items: center;
  713. justify-content: center;
  714. gap: 8px;
  715. font-size: 0.9rem;
  716. }
  717. .agent-label {
  718. color: var(--gray-600);
  719. }
  720. .agent-name {
  721. color: var(--primary-indigo);
  722. font-weight: 600;
  723. }
  724. .agent-list {
  725. display: flex;
  726. flex-direction: column;
  727. gap: 12px;
  728. }
  729. .agent-item {
  730. display: flex;
  731. align-items: center;
  732. gap: 12px;
  733. padding: 16px 20px;
  734. border-radius: var(--radius);
  735. background: rgba(255, 255, 255, 0.1);
  736. border: 1px solid transparent;
  737. cursor: pointer;
  738. transition: var(--transition);
  739. position: relative;
  740. overflow: hidden;
  741. user-select: none; /* 防止文本被选中 */
  742. }
  743. .agent-item:active {
  744. transform: scale(0.98);
  745. transition: transform 0.1s ease;
  746. }
  747. .agent-item.active {
  748. background: rgba(99, 102, 241, 0.1) !important;
  749. border-color: rgba(99, 102, 241, 0.4) !important;
  750. box-shadow: var(--shadow-glow-indigo) !important;
  751. transform: translateX(5px);
  752. cursor: default; /* 激活状态下显示默认光标 */
  753. }
  754. .agent-item.active::before {
  755. opacity: 1;
  756. }
  757. .agent-item.active .agent-title {
  758. color: var(--primary-indigo) !important;
  759. font-weight: 700;
  760. }
  761. .agent-item.active:hover {
  762. transform: translateX(5px); /* 保持激活状态的偏移 */
  763. }
  764. .agent-item::before {
  765. content: '';
  766. position: absolute;
  767. top: 0;
  768. left: 0;
  769. width: 100%;
  770. height: 100%;
  771. background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(139, 92, 246, 0.1));
  772. opacity: 0;
  773. transition: var(--transition);
  774. }
  775. .agent-item:hover {
  776. background: rgba(255, 255, 255, 0.2);
  777. border-color: rgba(99, 102, 241, 0.3);
  778. transform: translateX(3px);
  779. }
  780. .agent-item:hover::before {
  781. opacity: 1;
  782. }
  783. .agent-item.active .agent-title {
  784. color: var(--primary-indigo) !important;
  785. font-weight: 700;
  786. }
  787. .agent-icon {
  788. width: 50px;
  789. height: 50px;
  790. display: flex;
  791. align-items: center;
  792. justify-content: center;
  793. border-radius: var(--radius);
  794. flex-shrink: 0;
  795. transition: var(--transition);
  796. overflow: hidden;
  797. }
  798. .platform-icon {
  799. width: 32px;
  800. height: 32px;
  801. object-fit: contain;
  802. transition: var(--transition);
  803. filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
  804. }
  805. .icon-fallback {
  806. font-size: 1.8rem;
  807. color: var(--gray-600);
  808. display: none;
  809. }
  810. /* 图标悬停效果 */
  811. .agent-item:hover .platform-icon {
  812. filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.15));
  813. }
  814. /* 激活状态下的图标效果 */
  815. .agent-item.active .platform-icon {
  816. filter: drop-shadow(0 4px 12px rgba(99, 102, 241, 0.3));
  817. }
  818. .agent-item:hover .agent-icon .platform-icon {
  819. transform: scale(1.1);
  820. }
  821. .agent-info {
  822. flex: 1;
  823. min-width: 0;
  824. }
  825. .agent-title {
  826. font-weight: 600;
  827. color: var(--gray-800);
  828. font-size: 1.1rem;
  829. }
  830. /* 聊天主内容区域 */
  831. .chat-main-content {
  832. flex: 1;
  833. display: flex;
  834. flex-direction: column;
  835. position: relative;
  836. min-height: 0; /* 确保flex子元素能够正确收缩 */
  837. }
  838. /* 移动端菜单切换按钮 - 默认隐藏 */
  839. .mobile-menu-toggle {
  840. display: none;
  841. position: fixed;
  842. left: 20px;
  843. top: 100px;
  844. z-index: 999;
  845. width: 50px;
  846. height: 50px;
  847. background: var(--primary-indigo);
  848. border: none;
  849. border-radius: 50%;
  850. color: white;
  851. font-size: 1.2rem;
  852. box-shadow: var(--shadow-lg);
  853. cursor: pointer;
  854. transition: var(--transition);
  855. }
  856. .mobile-menu-toggle:hover {
  857. transform: scale(1.1);
  858. box-shadow: var(--shadow-glow-indigo);
  859. }
  860. .logo-title-container {
  861. display: flex;
  862. align-items: center;
  863. gap: 12px;
  864. }
  865. .logo-title-link{
  866. color: red;
  867. text-decoration: none;
  868. }
  869. .header-logo {
  870. width: 40px;
  871. height: 40px;
  872. border-radius: var(--radius);
  873. object-fit: contain;
  874. transition: var(--transition);
  875. filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
  876. }
  877. .header-logo:hover {
  878. transform: scale(1.05);
  879. filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.15));
  880. }
  881. .version-tag {
  882. font-size: 0.7rem;
  883. font-weight: 500;
  884. color: var(--gray-50);
  885. background: linear-gradient(135deg, var(--primary-indigo), var(--primary-purple));
  886. padding: 2px 8px;
  887. border-radius: var(--radius-full);
  888. margin-left: 8px;
  889. box-shadow: var(--shadow-sm);
  890. vertical-align: middle;
  891. display: inline-flex;
  892. align-items: center;
  893. justify-content: center;
  894. }
  895. header {
  896. display: flex;
  897. justify-content: space-between;
  898. align-items: center;
  899. padding: 12px 20px;
  900. background-color: rgba(255, 255, 255, 0.25);
  901. border-bottom: var(--glass-border);
  902. position: relative;
  903. z-index: 2;
  904. backdrop-filter: blur(var(--blur-md));
  905. -webkit-backdrop-filter: blur(var(--blur-md));
  906. border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  907. }
  908. header::before {
  909. content: '';
  910. position: absolute;
  911. top: 0;
  912. left: 0;
  913. width: 100%;
  914. height: 100%;
  915. background: linear-gradient(to right, rgba(99, 102, 241, 0.15), rgba(139, 92, 246, 0.15));
  916. opacity: 0.5;
  917. z-index: -1;
  918. border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  919. }
  920. header h1 {
  921. font-size: 1.25rem;
  922. font-weight: 600;
  923. color: var(--gray-800);
  924. display: flex;
  925. align-items: center;
  926. margin: 0;
  927. }
  928. header h1 svg {
  929. margin-right: 8px;
  930. }
  931. .buttons-container {
  932. display: flex;
  933. gap: 10px;
  934. align-items: center;
  935. }
  936. /* 用户信息样式 */
  937. .user-info {
  938. position: relative;
  939. display: flex;
  940. align-items: center;
  941. gap: 12px;
  942. padding: 10px 16px;
  943. background: rgba(255, 255, 255, 0.15);
  944. border-radius: 12px;
  945. border: 1px solid rgba(255, 255, 255, 0.25);
  946. backdrop-filter: blur(15px);
  947. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  948. cursor: pointer;
  949. }
  950. .user-info:hover {
  951. background: rgba(255, 255, 255, 0.2);
  952. border-color: rgba(255, 255, 255, 0.35);
  953. transform: translateY(-1px);
  954. box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
  955. }
  956. .user-details {
  957. display: flex;
  958. align-items: center;
  959. gap: 10px;
  960. }
  961. .user-avatar {
  962. position: relative;
  963. width: 36px;
  964. height: 36px;
  965. border-radius: 50%;
  966. overflow: hidden;
  967. background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  968. border: 2px solid rgba(255, 255, 255, 0.3);
  969. transition: all 0.3s ease;
  970. }
  971. .user-info:hover .user-avatar {
  972. border-color: rgba(255, 255, 255, 0.5);
  973. transform: scale(1.05);
  974. }
  975. .user-avatar img {
  976. width: 100%;
  977. height: 100%;
  978. object-fit: cover;
  979. transition: transform 0.3s ease;
  980. }
  981. .user-info:hover .user-avatar img {
  982. transform: scale(1.1);
  983. }
  984. .avatar-fallback {
  985. width: 100%;
  986. height: 100%;
  987. background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  988. display: flex;
  989. align-items: center;
  990. justify-content: center;
  991. color: white;
  992. font-weight: 600;
  993. font-size: 16px;
  994. text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  995. }
  996. .user-text {
  997. display: flex;
  998. flex-direction: column;
  999. align-items: flex-start;
  1000. gap: 2px;
  1001. }
  1002. .user-info-row {
  1003. display: flex;
  1004. align-items: center;
  1005. gap: 8px;
  1006. width: 100%;
  1007. }
  1008. .user-name {
  1009. font-size: 14px;
  1010. font-weight: 600;
  1011. color: #1a1a1a;
  1012. white-space: nowrap;
  1013. text-shadow: 0 1px 2px rgba(255, 255, 255, 0.5);
  1014. }
  1015. .user-type {
  1016. font-size: 11px;
  1017. color: #666;
  1018. opacity: 0.8;
  1019. padding: 2px 6px;
  1020. background: rgba(255, 255, 255, 0.3);
  1021. border-radius: 10px;
  1022. font-weight: 500;
  1023. text-transform: uppercase;
  1024. letter-spacing: 0.5px;
  1025. }
  1026. .user-title {
  1027. font-size: 10px;
  1028. color: #888;
  1029. opacity: 0.7;
  1030. font-style: italic;
  1031. max-width: 120px;
  1032. overflow: hidden;
  1033. text-overflow: ellipsis;
  1034. white-space: nowrap;
  1035. }
  1036. .user-dropdown {
  1037. position: absolute;
  1038. top: calc(100% + 8px);
  1039. right: 0;
  1040. background: rgba(255, 255, 255, 0.98);
  1041. border-radius: 12px;
  1042. box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
  1043. backdrop-filter: blur(20px);
  1044. border: 1px solid rgba(255, 255, 255, 0.3);
  1045. min-width: 220px;
  1046. z-index: 1000;
  1047. opacity: 0;
  1048. visibility: hidden;
  1049. transform: translateY(-15px) scale(0.95);
  1050. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  1051. overflow: hidden;
  1052. }
  1053. .user-info:hover .user-dropdown {
  1054. opacity: 1;
  1055. visibility: visible;
  1056. transform: translateY(0) scale(1);
  1057. }
  1058. .user-dropdown::before {
  1059. content: '';
  1060. position: absolute;
  1061. top: -6px;
  1062. right: 20px;
  1063. width: 12px;
  1064. height: 12px;
  1065. background: rgba(255, 255, 255, 0.98);
  1066. border: 1px solid rgba(255, 255, 255, 0.3);
  1067. border-bottom: none;
  1068. border-right: none;
  1069. transform: rotate(45deg);
  1070. }
  1071. .user-dropdown-content {
  1072. padding: 16px;
  1073. }
  1074. .user-info-item {
  1075. display: flex;
  1076. justify-content: space-between;
  1077. align-items: center;
  1078. padding: 10px 0;
  1079. border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  1080. transition: background-color 0.2s ease;
  1081. }
  1082. .user-info-item:hover {
  1083. background-color: rgba(0, 0, 0, 0.02);
  1084. padding-left: 8px;
  1085. padding-right: 8px;
  1086. margin-left: -8px;
  1087. margin-right: -8px;
  1088. border-radius: 6px;
  1089. }
  1090. .user-info-item:last-child {
  1091. border-bottom: none;
  1092. }
  1093. .info-label {
  1094. font-size: 12px;
  1095. color: #666;
  1096. font-weight: 500;
  1097. }
  1098. .info-value {
  1099. font-size: 12px;
  1100. color: #333;
  1101. max-width: 120px;
  1102. overflow: hidden;
  1103. text-overflow: ellipsis;
  1104. white-space: nowrap;
  1105. font-weight: 500;
  1106. }
  1107. /* 成功和错误消息样式 */
  1108. .success-message, .error-message {
  1109. position: fixed;
  1110. top: 20px;
  1111. left: 50%;
  1112. transform: translateX(-50%);
  1113. padding: 12px 24px;
  1114. border-radius: 8px;
  1115. font-weight: 500;
  1116. z-index: 1000;
  1117. animation: slideDown 0.3s ease-out;
  1118. box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  1119. }
  1120. .success-message {
  1121. background: linear-gradient(135deg, #4caf50, #45a049);
  1122. color: white;
  1123. }
  1124. .error-message {
  1125. background: linear-gradient(135deg, #f44336, #d32f2f);
  1126. color: white;
  1127. }
  1128. @keyframes slideDown {
  1129. from {
  1130. opacity: 0;
  1131. transform: translateX(-50%) translateY(-20px);
  1132. }
  1133. to {
  1134. opacity: 1;
  1135. transform: translateX(-50%) translateY(0);
  1136. }
  1137. }
  1138. .logout-btn {
  1139. width: 100%;
  1140. padding: 10px 16px;
  1141. background: linear-gradient(135deg, #ff4757 0%, #ff3742 100%);
  1142. color: white;
  1143. border: none;
  1144. border-radius: 8px;
  1145. font-size: 14px;
  1146. font-weight: 500;
  1147. cursor: pointer;
  1148. transition: all 0.3s ease;
  1149. display: flex;
  1150. align-items: center;
  1151. justify-content: center;
  1152. gap: 8px;
  1153. }
  1154. .logout-btn:hover {
  1155. background: linear-gradient(135deg, #ff3742 0%, #ff2f3a 100%);
  1156. transform: translateY(-1px);
  1157. box-shadow: 0 4px 12px rgba(255, 71, 87, 0.3);
  1158. }
  1159. .logout-btn svg {
  1160. transition: transform 0.3s ease;
  1161. }
  1162. .logout-btn:hover svg {
  1163. transform: translateX(2px);
  1164. }
  1165. .btn {
  1166. padding: 8px 16px;
  1167. background-color: transparent;
  1168. border: none;
  1169. border-radius: var(--radius);
  1170. font-weight: 500;
  1171. font-size: 0.875rem;
  1172. cursor: pointer;
  1173. display: flex;
  1174. align-items: center;
  1175. justify-content: center;
  1176. gap: 6px;
  1177. transition: var(--transition);
  1178. /* color: var(--gray-700); */
  1179. background-color: rgba(255, 255, 255, 0.5);
  1180. backdrop-filter: blur(var(--blur-sm));
  1181. -webkit-backdrop-filter: blur(var(--blur-sm));
  1182. box-shadow: var(--shadow-sm);
  1183. }
  1184. .btn:hover {
  1185. background-color: rgba(255, 255, 255, 0.7);
  1186. color: var(--gray-900);
  1187. box-shadow: var(--shadow);
  1188. transform: translateY(-1px);
  1189. }
  1190. .btn:active {
  1191. transform: translateY(0);
  1192. box-shadow: var(--shadow-sm);
  1193. }
  1194. .glass-btn {
  1195. padding: 8px 16px;
  1196. background-color: rgba(255, 255, 255, 0.3);
  1197. border: var(--glass-border);
  1198. color: var(--gray-700);
  1199. box-shadow: var(--shadow-sm);
  1200. transition: var(--transition);
  1201. }
  1202. .glass-btn:hover {
  1203. background-color: rgba(255, 255, 255, 0.4);
  1204. box-shadow: var(--shadow);
  1205. color: var(--gray-900);
  1206. }
  1207. .glass-btn-primary {
  1208. padding: 10px;
  1209. background-color: var(--primary-indigo);
  1210. border: none;
  1211. color: white;
  1212. border-radius: var(--radius-full);
  1213. width: 40px;
  1214. height: 40px;
  1215. display: flex;
  1216. align-items: center;
  1217. justify-content: center;
  1218. box-shadow: var(--shadow);
  1219. transition: var(--transition);
  1220. cursor: pointer;
  1221. opacity: 1;
  1222. position: relative;
  1223. overflow: hidden;
  1224. }
  1225. .glass-btn-primary:hover {
  1226. transform: translateY(-1px);
  1227. box-shadow: var(--shadow-md);
  1228. }
  1229. .glass-btn-primary:active {
  1230. transform: translateY(0);
  1231. }
  1232. .glass-btn svg, .glass-btn-primary svg {
  1233. width: 16px;
  1234. height: 16px;
  1235. }
  1236. .glass-btn:hover svg {
  1237. transform: scale(1.05);
  1238. }
  1239. .glass-btn-primary:hover svg {
  1240. transform: scale(1.1);
  1241. }
  1242. #reset-btn {
  1243. color: var(--gray-700);
  1244. display: flex;
  1245. align-items: center;
  1246. gap: 6px;
  1247. font-size: 0.875rem;
  1248. font-weight: 500;
  1249. background-color: rgba(255, 255, 255, 0.4);
  1250. box-shadow: var(--shadow-sm);
  1251. }
  1252. #reset-btn:hover {
  1253. background-color: rgba(255, 255, 255, 0.6);
  1254. color: var(--gray-900);
  1255. box-shadow: var(--shadow);
  1256. }
  1257. #reset-btn.confirming {
  1258. background-color: var(--danger-color);
  1259. color: white;
  1260. animation: pulse 2s infinite;
  1261. }
  1262. @keyframes pulse {
  1263. 0% {
  1264. box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.4);
  1265. }
  1266. 70% {
  1267. box-shadow: 0 0 0 5px rgba(239, 68, 68, 0);
  1268. }
  1269. 100% {
  1270. box-shadow: 0 0 0 0 rgba(239, 68, 68, 0);
  1271. }
  1272. }
  1273. /* 智能体选择按钮样式 - 与重置按钮保持一致 */
  1274. #agent-dropdown {
  1275. color: var(--gray-700);
  1276. display: flex;
  1277. align-items: center;
  1278. gap: 6px;
  1279. font-size: 0.875rem;
  1280. font-weight: 500;
  1281. background-color: rgba(255, 255, 255, 0.4);
  1282. box-shadow: var(--shadow-sm);
  1283. cursor: pointer;
  1284. border-radius: var(--radius);
  1285. transition: var(--transition);
  1286. position: relative;
  1287. z-index: 1002;
  1288. }
  1289. #agent-dropdown:hover {
  1290. background-color: rgba(255, 255, 255, 0.6);
  1291. color: var(--gray-900);
  1292. box-shadow: var(--shadow);
  1293. }
  1294. #agent-dropdown svg {
  1295. transition: var(--transition);
  1296. }
  1297. #agent-dropdown:hover svg {
  1298. transform: scale(1.05);
  1299. }
  1300. /* 智能体菜单样式 */
  1301. #agent-menu {
  1302. z-index: 1001 !important;
  1303. position: absolute !important;
  1304. top: calc(100% + 6px) !important;
  1305. left: 0 !important;
  1306. min-width: 220px !important;
  1307. background: rgba(255, 255, 255, 0.95) !important;
  1308. backdrop-filter: blur(20px) !important;
  1309. -webkit-backdrop-filter: blur(20px) !important;
  1310. border: 1px solid rgba(255, 255, 255, 0.3) !important;
  1311. border-radius: 12px !important;
  1312. box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15) !important;
  1313. overflow: hidden !important;
  1314. }
  1315. #agent-menu ul {
  1316. list-style: none !important;
  1317. margin: 0 !important;
  1318. padding: 8px !important;
  1319. }
  1320. .agent-option {
  1321. display: flex !important;
  1322. align-items: center !important;
  1323. gap: 8px !important;
  1324. padding: 12px !important;
  1325. border-radius: 8px !important;
  1326. cursor: pointer !important;
  1327. transition: all 0.2s ease !important;
  1328. background: transparent !important;
  1329. border: 1px solid transparent !important;
  1330. }
  1331. .agent-option:hover {
  1332. background: rgba(99, 102, 241, 0.1) !important;
  1333. border-color: rgba(99, 102, 241, 0.2) !important;
  1334. transform: translateY(-1px) !important;
  1335. }
  1336. .agent-option[data-active="true"] {
  1337. background: rgba(99, 102, 241, 0.15) !important;
  1338. border-color: rgba(99, 102, 241, 0.3) !important;
  1339. box-shadow: 0 2px 8px rgba(99, 102, 241, 0.2) !important;
  1340. }
  1341. .chat-messages {
  1342. flex: 1;
  1343. min-height: 0; /* 确保能够收缩 */
  1344. overflow-y: auto;
  1345. padding: 30px;
  1346. position: relative;
  1347. display: flex;
  1348. flex-direction: column;
  1349. gap: 30px;
  1350. background: rgba(255, 255, 255, 0.1);
  1351. backdrop-filter: blur(var(--blur-sm));
  1352. -webkit-backdrop-filter: blur(var(--blur-sm));
  1353. scrollbar-width: thin;
  1354. scrollbar-color: rgba(100, 116, 139, 0.5) transparent;
  1355. }
  1356. .chat-messages::before {
  1357. content: '';
  1358. position: absolute;
  1359. top: 0;
  1360. left: 0;
  1361. width: 100%;
  1362. height: 100%;
  1363. background: linear-gradient(to bottom, rgba(255, 255, 255, 0.5), rgba(255, 255, 255, 0.02));
  1364. opacity: 0.3;
  1365. z-index: -1;
  1366. pointer-events: none;
  1367. }
  1368. .chat-messages::-webkit-scrollbar {
  1369. width: 8px;
  1370. height: 8px;
  1371. }
  1372. .chat-messages::-webkit-scrollbar-track {
  1373. background: transparent;
  1374. }
  1375. .chat-messages::-webkit-scrollbar-thumb {
  1376. background-color: rgba(100, 116, 139, 0.5);
  1377. border-radius: 20px;
  1378. }
  1379. .chat-messages::-webkit-scrollbar-thumb:hover {
  1380. background-color: rgba(100, 116, 139, 0.7);
  1381. }
  1382. .message {
  1383. padding: 15px 20px;
  1384. border-radius: var(--radius);
  1385. animation: fadeIn 0.3s ease-out forwards;
  1386. word-break: break-word;
  1387. position: relative;
  1388. opacity: 0;
  1389. transform: translateY(10px);
  1390. transition: transform 0.3s ease, opacity 0.3s ease;
  1391. }
  1392. @keyframes fadeIn {
  1393. to {
  1394. opacity: 1;
  1395. transform: translateY(0);
  1396. }
  1397. }
  1398. .message.user {
  1399. align-self: flex-end;
  1400. background-color: rgba(59, 130, 246, 0.1);
  1401. }
  1402. .message.bot {
  1403. align-self: flex-start;
  1404. background-color: rgba(255, 255, 255, 0.15);
  1405. width: 90%;
  1406. max-width: 1200px;
  1407. }
  1408. .message-content {
  1409. font-size: 1rem;
  1410. line-height: 1.6;
  1411. background: rgba(255, 255, 255, 0.8);
  1412. padding: 20px 30px;
  1413. border-radius: var(--radius);
  1414. box-shadow: var(--shadow-sm);
  1415. backdrop-filter: blur(var(--blur-sm));
  1416. -webkit-backdrop-filter: blur(var(--blur-sm));
  1417. }
  1418. .message.bot .message-content {
  1419. width: 100%;
  1420. display: flex;
  1421. flex-direction: column;
  1422. padding: 24px;
  1423. line-height: 1.7;
  1424. font-size: 1.05rem;
  1425. }
  1426. .thought-container {
  1427. width: 100%;
  1428. margin: 10px 0 20px 0;
  1429. background-color: rgba(121, 82, 179, 0.08);
  1430. border-left: 3px solid #7952b3;
  1431. padding: 14px 18px;
  1432. border-radius: 0 8px 8px 0;
  1433. font-style: italic;
  1434. color: #6c757d;
  1435. position: relative;
  1436. box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
  1437. transition: all 0.3s ease;
  1438. }
  1439. .thought-container[data-collapsed="true"] {
  1440. padding-bottom: 10px;
  1441. }
  1442. .thought-container::before {
  1443. content: "思考中...";
  1444. display: inline-block;
  1445. font-size: 0.9rem;
  1446. color: #7952b3;
  1447. font-weight: 600;
  1448. margin-bottom: 8px;
  1449. font-style: normal;
  1450. letter-spacing: 0.03em;
  1451. }
  1452. .thought-container p {
  1453. margin: 0 0 8px 0;
  1454. padding: 0;
  1455. line-height: 1.6;
  1456. font-size: 0.95rem;
  1457. white-space: normal;
  1458. word-break: normal;
  1459. word-wrap: break-word;
  1460. overflow-wrap: break-word;
  1461. text-align: left;
  1462. width: 100%;
  1463. transition: all 0.2s ease;
  1464. display: block;
  1465. }
  1466. /* 最后一个段落不需要底部间距 */
  1467. .thought-container p:last-child {
  1468. margin-bottom: 0;
  1469. }
  1470. /* 确保段落内容按段落显示,不连续 */
  1471. .thought-container p:not(:last-child) {
  1472. margin-bottom: 8px;
  1473. }
  1474. /* 思考过程第一段的特殊样式 */
  1475. .thought-container p:first-of-type {
  1476. font-weight: normal;
  1477. margin-top: 0;
  1478. }
  1479. /* 折叠/展开思考过程功能 */
  1480. .thought-toggle {
  1481. position: absolute;
  1482. top: 12px;
  1483. right: 12px;
  1484. background: transparent;
  1485. border: none;
  1486. color: #7952b3;
  1487. cursor: pointer;
  1488. font-size: 1.2rem;
  1489. opacity: 0.7;
  1490. transition: opacity 0.2s;
  1491. display: flex;
  1492. align-items: center;
  1493. justify-content: center;
  1494. width: 24px;
  1495. height: 24px;
  1496. padding: 0;
  1497. border-radius: 50%;
  1498. }
  1499. .thought-toggle:hover {
  1500. opacity: 1;
  1501. background-color: rgba(121, 82, 179, 0.1);
  1502. }
  1503. .chat-input-container {
  1504. padding: 20px;
  1505. display: flex;
  1506. gap: 10px;
  1507. align-items: flex-start; /* 改为顶部对齐,适应多行输入 */
  1508. border-top: var(--glass-border);
  1509. position: relative;
  1510. z-index: 1;
  1511. background: rgba(255, 255, 255, 0.15);
  1512. backdrop-filter: blur(var(--blur-md));
  1513. -webkit-backdrop-filter: blur(var(--blur-md));
  1514. flex-shrink: 0; /* 防止输入框被压缩 */
  1515. }
  1516. .chat-input-container::before {
  1517. content: '';
  1518. position: absolute;
  1519. top: 0;
  1520. left: 0;
  1521. width: 100%;
  1522. height: 100%;
  1523. background: linear-gradient(to right, rgba(99, 102, 241, 0.05), rgba(139, 92, 246, 0.05));
  1524. opacity: 0.7;
  1525. z-index: -1;
  1526. border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  1527. }
  1528. #user-input {
  1529. flex: 1;
  1530. padding: 12px 20px;
  1531. border: var(--glass-border);
  1532. border-radius: var(--radius);
  1533. background-color: rgba(255, 255, 255, 0.8);
  1534. font-size: 1rem;
  1535. resize: none;
  1536. min-height: 44px; /* 设置最小高度 */
  1537. max-height: 200px;
  1538. overflow-y: auto;
  1539. line-height: 1.5;
  1540. box-shadow: var(--shadow-inner);
  1541. transition: var(--transition);
  1542. font-family: inherit;
  1543. }
  1544. #user-input:focus {
  1545. outline: none;
  1546. border-color: rgba(99, 102, 241, 0.5);
  1547. box-shadow: var(--shadow-glow-indigo);
  1548. }
  1549. .chat-input-container::before {
  1550. content: '';
  1551. position: absolute;
  1552. top: 0;
  1553. left: 0;
  1554. width: 100%;
  1555. height: 100%;
  1556. background: linear-gradient(to right, rgba(99, 102, 241, 0.05), rgba(139, 92, 246, 0.05));
  1557. opacity: 0.7;
  1558. z-index: -1;
  1559. border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  1560. }
  1561. #send-btn {
  1562. width: 40px;
  1563. height: 40px;
  1564. background-color: var(--primary-indigo);
  1565. border: none;
  1566. border-radius: var(--radius-full);
  1567. display: flex;
  1568. align-items: center;
  1569. justify-content: center;
  1570. cursor: pointer;
  1571. box-shadow: var(--shadow);
  1572. transition: var(--transition);
  1573. color: white;
  1574. padding: 0;
  1575. overflow: hidden;
  1576. }
  1577. #send-btn:hover {
  1578. transform: translateY(-2px) scale(1.03);
  1579. box-shadow: var(--shadow-md);
  1580. }
  1581. #send-btn:active {
  1582. transform: translateY(0) scale(0.98);
  1583. }
  1584. .typing-indicator {
  1585. display: inline-flex;
  1586. align-items: center;
  1587. background-color: rgba(255, 255, 255, 0.5);
  1588. padding: 8px 16px;
  1589. border-radius: var(--radius-full);
  1590. box-shadow: var(--shadow-sm);
  1591. backdrop-filter: blur(var(--blur-sm));
  1592. -webkit-backdrop-filter: blur(var(--blur-sm));
  1593. margin: 0 auto;
  1594. }
  1595. .typing-indicator span {
  1596. display: inline-block;
  1597. width: 8px;
  1598. height: 8px;
  1599. background-color: var(--primary-indigo);
  1600. border-radius: 50%;
  1601. margin: 0 2px;
  1602. animation: typing 1.4s infinite ease-in-out;
  1603. }
  1604. .typing-indicator span:nth-child(1) {
  1605. animation-delay: 0s;
  1606. }
  1607. .typing-indicator span:nth-child(2) {
  1608. animation-delay: 0.2s;
  1609. }
  1610. .typing-indicator span:nth-child(3) {
  1611. animation-delay: 0.4s;
  1612. }
  1613. @keyframes typing {
  1614. 0%, 80%, 100% {
  1615. transform: scale(0.6);
  1616. opacity: 0.6;
  1617. }
  1618. 40% {
  1619. transform: scale(1);
  1620. opacity: 1;
  1621. }
  1622. }
  1623. /* 深色模式适配 - 自动跟随浏览器主题 */
  1624. @media (prefers-color-scheme: dark) {
  1625. :root {
  1626. /* 深色模式下的颜色变量 */
  1627. --glass-border: 1px solid rgba(255, 255, 255, 0.1);
  1628. --glass-background: rgba(23, 25, 35, 0.3);
  1629. --glass-background-dark: rgba(15, 23, 42, 0.6);
  1630. --shadow-glow-indigo: 0 0 15px 2px rgba(99, 102, 241, 0.35);
  1631. --shadow-glow-purple: 0 0 15px 2px rgba(139, 92, 246, 0.35);
  1632. /* 深色模式下的文本颜色 */
  1633. --text-primary: #e2e8f0;
  1634. --text-secondary: #cbd5e1;
  1635. --text-muted: #94a3b8;
  1636. --text-inverse: #1e293b;
  1637. /* 深色模式下的背景颜色 */
  1638. --bg-primary: #0f172a;
  1639. --bg-secondary: #1e293b;
  1640. --bg-tertiary: #334155;
  1641. --bg-glass: rgba(15, 23, 42, 0.8);
  1642. }
  1643. body {
  1644. background: linear-gradient(135deg, #0f172a, #1e293b, #334155, #475569);
  1645. color: var(--text-primary);
  1646. transition: background 0.3s ease, color 0.3s ease;
  1647. }
  1648. body::before {
  1649. opacity: 0.1;
  1650. background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%236366f1' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  1651. }
  1652. /* 主容器深色模式 */
  1653. .chat-container {
  1654. background-color: var(--bg-glass);
  1655. border: var(--glass-border);
  1656. backdrop-filter: blur(var(--blur-md));
  1657. -webkit-backdrop-filter: blur(var(--blur-md));
  1658. }
  1659. /* 头部深色模式 */
  1660. header {
  1661. background-color: rgba(15, 23, 42, 0.8);
  1662. border-bottom: var(--glass-border);
  1663. backdrop-filter: blur(var(--blur-md));
  1664. -webkit-backdrop-filter: blur(var(--blur-md));
  1665. }
  1666. header::before {
  1667. background: linear-gradient(to right, rgba(99, 102, 241, 0.1), rgba(139, 92, 246, 0.1));
  1668. opacity: 0.3;
  1669. }
  1670. header h1 {
  1671. color: var(--text-primary);
  1672. }
  1673. /* 侧边栏深色模式 */
  1674. .history-sidebar {
  1675. background: rgba(15, 23, 42, 0.6);
  1676. border-right: var(--glass-border);
  1677. }
  1678. .sidebar-header {
  1679. background: rgba(15, 23, 42, 0.8);
  1680. border-bottom: var(--glass-border);
  1681. }
  1682. .sidebar-title {
  1683. color: var(--text-primary);
  1684. }
  1685. .new-chat-btn {
  1686. background: rgba(30, 41, 59, 0.8);
  1687. border: 1px solid rgba(255, 255, 255, 0.1);
  1688. color: var(--text-secondary);
  1689. box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  1690. }
  1691. .new-chat-btn::before {
  1692. background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.3), transparent);
  1693. }
  1694. .new-chat-btn:hover {
  1695. background: rgba(51, 65, 85, 0.95);
  1696. color: var(--text-primary);
  1697. border-color: rgba(99, 102, 241, 0.4);
  1698. box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(99, 102, 241, 0.2);
  1699. }
  1700. .new-chat-btn:hover svg {
  1701. transform: scale(1.1) rotate(90deg);
  1702. filter: drop-shadow(0 0 4px rgba(99, 102, 241, 0.5));
  1703. }
  1704. .conversation-item {
  1705. background: transparent;
  1706. border: 1px solid transparent;
  1707. }
  1708. .conversation-item::before {
  1709. background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.15), transparent);
  1710. }
  1711. .conversation-item:hover {
  1712. background: rgba(30, 41, 59, 0.6);
  1713. border-color: rgba(255, 255, 255, 0.15);
  1714. transform: translateX(4px);
  1715. box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  1716. }
  1717. .conversation-item.active {
  1718. background: rgba(99, 102, 241, 0.25);
  1719. border-color: rgba(99, 102, 241, 0.5);
  1720. box-shadow: 0 6px 16px rgba(99, 102, 241, 0.4);
  1721. transform: translateX(6px);
  1722. }
  1723. .conversation-item.active::before {
  1724. background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.3), transparent);
  1725. opacity: 1;
  1726. }
  1727. .conversation-title {
  1728. color: var(--text-secondary);
  1729. }
  1730. .conversation-item.active .conversation-title {
  1731. color: var(--primary-indigo);
  1732. }
  1733. .conversation-menu {
  1734. color: var(--text-muted);
  1735. }
  1736. .conversation-menu::before {
  1737. background: rgba(99, 102, 241, 0.15);
  1738. }
  1739. .conversation-item:hover .conversation-menu {
  1740. background: rgba(30, 41, 59, 0.6);
  1741. transform: scale(1.1);
  1742. }
  1743. .conversation-menu:hover {
  1744. background: rgba(51, 65, 85, 0.8);
  1745. color: var(--text-primary);
  1746. transform: scale(1.2);
  1747. }
  1748. .conversation-menu:hover::before {
  1749. background: rgba(99, 102, 241, 0.3);
  1750. }
  1751. .group-header {
  1752. color: var(--text-muted);
  1753. }
  1754. .group-header::before {
  1755. background: linear-gradient(to bottom, var(--primary-indigo), var(--primary-purple));
  1756. opacity: 0.4;
  1757. }
  1758. .group-header:hover {
  1759. color: var(--text-secondary);
  1760. transform: translateX(4px);
  1761. }
  1762. .group-header:hover::before {
  1763. opacity: 0.8;
  1764. height: 16px;
  1765. box-shadow: 0 0 8px rgba(99, 102, 241, 0.3);
  1766. }
  1767. .sidebar-footer {
  1768. background: rgba(15, 23, 42, 0.4);
  1769. border-top: var(--glass-border);
  1770. }
  1771. .user-profile {
  1772. background: rgba(30, 41, 59, 0.6);
  1773. border: 1px solid rgba(255, 255, 255, 0.1);
  1774. }
  1775. .user-profile:hover {
  1776. background: rgba(51, 65, 85, 0.8);
  1777. border-color: rgba(255, 255, 255, 0.2);
  1778. }
  1779. .user-name-sidebar {
  1780. color: var(--text-primary);
  1781. }
  1782. /* 聊天消息区域深色模式 */
  1783. .chat-messages {
  1784. background: rgba(15, 23, 42, 0.3);
  1785. }
  1786. .chat-messages::before {
  1787. background: linear-gradient(to bottom, rgba(30, 41, 59, 0.3), rgba(15, 23, 42, 0.5));
  1788. opacity: 0.4;
  1789. }
  1790. /* 消息样式深色模式 */
  1791. .message.user {
  1792. background-color: rgba(99, 102, 241, 0.2);
  1793. }
  1794. .message.bot {
  1795. background-color: rgba(30, 41, 59, 0.3);
  1796. }
  1797. .message-content {
  1798. background: rgba(30, 41, 59, 0.8);
  1799. color: var(--text-primary);
  1800. border: 1px solid rgba(255, 255, 255, 0.1);
  1801. box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  1802. }
  1803. .message.bot .message-content {
  1804. background: rgba(30, 41, 59, 0.9);
  1805. color: var(--text-primary);
  1806. }
  1807. /* 思考过程深色模式 */
  1808. .thought-container {
  1809. background-color: rgba(121, 82, 179, 0.15);
  1810. border-left-color: #9370db;
  1811. color: var(--text-secondary);
  1812. }
  1813. .thought-container::before {
  1814. color: #a98eda;
  1815. }
  1816. /* 按钮深色模式 */
  1817. .btn, #reset-btn, #toggle-streaming-btn {
  1818. background-color: rgba(30, 41, 59, 0.8);
  1819. color: var(--text-secondary);
  1820. border: 1px solid rgba(255, 255, 255, 0.1);
  1821. }
  1822. .btn:hover, #reset-btn:hover, #toggle-streaming-btn:hover {
  1823. background-color: rgba(51, 65, 85, 0.9);
  1824. color: var(--text-primary);
  1825. }
  1826. .glass-btn {
  1827. background-color: rgba(30, 41, 59, 0.6);
  1828. border: var(--glass-border);
  1829. color: var(--text-secondary);
  1830. }
  1831. .glass-btn:hover {
  1832. background-color: rgba(51, 65, 85, 0.8);
  1833. color: var(--text-primary);
  1834. }
  1835. /* 智能体菜单深色模式 */
  1836. .agent-switcher {
  1837. background: rgba(15, 23, 42, 0.8);
  1838. border: var(--glass-border);
  1839. }
  1840. .agent-switcher-header h3 {
  1841. color: var(--text-primary);
  1842. }
  1843. .agent-label {
  1844. color: var(--text-muted);
  1845. }
  1846. .agent-item {
  1847. background: rgba(30, 41, 59, 0.6);
  1848. border: 1px solid transparent;
  1849. }
  1850. .agent-item:hover {
  1851. background: rgba(51, 65, 85, 0.8);
  1852. border-color: rgba(99, 102, 241, 0.3);
  1853. }
  1854. .agent-item.active {
  1855. background: rgba(99, 102, 241, 0.2) !important;
  1856. border-color: rgba(99, 102, 241, 0.4) !important;
  1857. }
  1858. .agent-title {
  1859. color: var(--text-primary);
  1860. }
  1861. .agent-item.active .agent-title {
  1862. color: var(--primary-indigo) !important;
  1863. }
  1864. /* 输入区域深色模式 */
  1865. .chat-input-container {
  1866. background: rgba(15, 23, 42, 0.8);
  1867. border-top: var(--glass-border);
  1868. }
  1869. .chat-input-container::before {
  1870. background: linear-gradient(to right, rgba(99, 102, 241, 0.1), rgba(139, 92, 246, 0.1));
  1871. opacity: 0.4;
  1872. }
  1873. #user-input {
  1874. background-color: rgba(30, 41, 59, 0.8);
  1875. color: var(--text-primary);
  1876. border: 1px solid rgba(255, 255, 255, 0.1);
  1877. }
  1878. #user-input:focus {
  1879. border-color: rgba(99, 102, 241, 0.5);
  1880. background-color: rgba(30, 41, 59, 0.9);
  1881. }
  1882. #user-input::placeholder {
  1883. color: var(--text-muted);
  1884. }
  1885. /* 用户信息深色模式 */
  1886. .user-info {
  1887. background: rgba(30, 41, 59, 0.8);
  1888. border: 1px solid rgba(255, 255, 255, 0.1);
  1889. }
  1890. .user-info:hover {
  1891. background: rgba(51, 65, 85, 0.9);
  1892. border-color: rgba(255, 255, 255, 0.2);
  1893. }
  1894. .user-name {
  1895. color: var(--text-primary);
  1896. }
  1897. .user-type {
  1898. color: var(--text-muted);
  1899. background: rgba(51, 65, 85, 0.6);
  1900. }
  1901. .user-title {
  1902. color: var(--text-muted);
  1903. }
  1904. .user-dropdown {
  1905. background: rgba(15, 23, 42, 0.95);
  1906. border: 1px solid rgba(255, 255, 255, 0.1);
  1907. }
  1908. .user-dropdown::before {
  1909. background: rgba(15, 23, 42, 0.95);
  1910. border: 1px solid rgba(255, 255, 255, 0.1);
  1911. }
  1912. .info-label {
  1913. color: var(--text-muted);
  1914. }
  1915. .info-value {
  1916. color: var(--text-secondary);
  1917. }
  1918. /* 通知消息深色模式 */
  1919. .typing-indicator, .loading-animation {
  1920. background-color: rgba(30, 41, 59, 0.8);
  1921. border: 1px solid rgba(255, 255, 255, 0.1);
  1922. }
  1923. .loading-text {
  1924. color: var(--text-secondary);
  1925. }
  1926. .status-badge {
  1927. background-color: rgba(30, 41, 59, 0.9);
  1928. }
  1929. .ripple {
  1930. background-color: rgba(255, 255, 255, 0.1);
  1931. }
  1932. /* 智能体切换通知深色模式 */
  1933. .agent-switch-notification .notification-content {
  1934. background: rgba(15, 23, 42, 0.95);
  1935. border: 1px solid rgba(99, 102, 241, 0.3);
  1936. }
  1937. .notification-text {
  1938. color: var(--text-primary);
  1939. }
  1940. /* 上下文菜单深色模式 */
  1941. .conversation-context-menu {
  1942. background: rgba(15, 23, 42, 0.95);
  1943. border: 1px solid rgba(255, 255, 255, 0.1);
  1944. }
  1945. .menu-item {
  1946. color: var(--text-secondary);
  1947. }
  1948. .menu-item:hover {
  1949. background: rgba(99, 102, 241, 0.2);
  1950. color: var(--primary-indigo);
  1951. }
  1952. /* 智能体菜单深色模式 */
  1953. #agent-menu {
  1954. background: rgba(15, 23, 42, 0.95) !important;
  1955. border: 1px solid rgba(255, 255, 255, 0.1) !important;
  1956. }
  1957. .agent-option {
  1958. background: rgba(30, 41, 59, 0.6) !important;
  1959. border: 1px solid rgba(255, 255, 255, 0.1) !important;
  1960. color: var(--text-secondary) !important;
  1961. }
  1962. .agent-option:hover {
  1963. background: rgba(99, 102, 241, 0.2) !important;
  1964. border-color: rgba(99, 102, 241, 0.3) !important;
  1965. color: var(--primary-indigo) !important;
  1966. }
  1967. .agent-option[data-active="true"] {
  1968. background: rgba(99, 102, 241, 0.3) !important;
  1969. border-color: rgba(99, 102, 241, 0.5) !important;
  1970. color: var(--primary-indigo) !important;
  1971. }
  1972. /* Markdown内容深色模式 */
  1973. .bot .message-content blockquote {
  1974. border-left-color: rgba(99, 102, 241, 0.5);
  1975. background-color: rgba(30, 58, 138, 0.3);
  1976. color: var(--text-secondary);
  1977. }
  1978. .bot .message-content code {
  1979. background-color: rgba(30, 58, 138, 0.3);
  1980. color: var(--text-secondary);
  1981. }
  1982. .bot .message-content pre {
  1983. background-color: rgba(15, 23, 42, 0.8);
  1984. border: 1px solid rgba(255, 255, 255, 0.1);
  1985. }
  1986. .bot .message-content h1,
  1987. .bot .message-content h2,
  1988. .bot .message-content h3,
  1989. .bot .message-content h4,
  1990. .bot .message-content h5,
  1991. .bot .message-content h6 {
  1992. color: var(--text-primary);
  1993. }
  1994. .bot .message-content table {
  1995. background-color: rgba(30, 41, 59, 0.5);
  1996. }
  1997. .bot .message-content table th,
  1998. .bot .message-content table td {
  1999. border-color: rgba(255, 255, 255, 0.1);
  2000. }
  2001. .bot .message-content table th {
  2002. background-color: rgba(51, 65, 85, 0.7);
  2003. color: var(--text-primary);
  2004. }
  2005. .bot .message-content table td {
  2006. color: var(--text-secondary);
  2007. }
  2008. /* 滚动条深色模式 */
  2009. .chat-messages::-webkit-scrollbar-thumb {
  2010. background-color: rgba(100, 116, 139, 0.6);
  2011. }
  2012. .chat-messages::-webkit-scrollbar-thumb:hover {
  2013. background-color: rgba(100, 116, 139, 0.8);
  2014. }
  2015. .history-content::-webkit-scrollbar-thumb {
  2016. background-color: rgba(100, 116, 139, 0.4);
  2017. }
  2018. .history-content::-webkit-scrollbar-thumb:hover {
  2019. background-color: rgba(100, 116, 139, 0.6);
  2020. }
  2021. /* 移动端侧边栏切换按钮深色模式 */
  2022. .sidebar-toggle {
  2023. background: var(--primary-indigo);
  2024. box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
  2025. }
  2026. .sidebar-toggle::before {
  2027. background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  2028. }
  2029. .sidebar-toggle:hover {
  2030. box-shadow: 0 12px 35px rgba(99, 102, 241, 0.4);
  2031. }
  2032. }
  2033. /* 响应式布局 */
  2034. @media (max-width: 768px) {
  2035. .chat-container {
  2036. height: calc(100vh - 20px);
  2037. max-height: none;
  2038. border-radius: var(--radius);
  2039. margin: 10px;
  2040. flex-direction: column;
  2041. }
  2042. /* 移动端侧边栏样式 */
  2043. .history-sidebar {
  2044. position: fixed;
  2045. left: -280px;
  2046. top: 0;
  2047. width: 280px;
  2048. height: 100vh;
  2049. z-index: 1000;
  2050. transition: transform 0.3s ease;
  2051. border-right: none;
  2052. border-radius: 0;
  2053. }
  2054. .history-sidebar.show {
  2055. transform: translateX(280px);
  2056. }
  2057. /* 移动端主聊天区域 */
  2058. .main-chat-area {
  2059. width: 100%;
  2060. height: 100%;
  2061. }
  2062. /* 移动端侧边栏切换按钮 */
  2063. .sidebar-toggle {
  2064. position: fixed;
  2065. left: 20px;
  2066. top: 20px;
  2067. z-index: 1001;
  2068. width: 44px;
  2069. height: 44px;
  2070. background: var(--primary-indigo);
  2071. border: none;
  2072. border-radius: 50%;
  2073. color: white;
  2074. font-size: 1.2rem;
  2075. box-shadow: var(--shadow-lg);
  2076. cursor: pointer;
  2077. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  2078. display: flex;
  2079. align-items: center;
  2080. justify-content: center;
  2081. position: relative;
  2082. overflow: hidden;
  2083. }
  2084. .sidebar-toggle::before {
  2085. content: '';
  2086. position: absolute;
  2087. top: 0;
  2088. left: -100%;
  2089. width: 100%;
  2090. height: 100%;
  2091. background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  2092. transition: left 0.5s ease;
  2093. }
  2094. .sidebar-toggle:hover {
  2095. transform: scale(1.1);
  2096. box-shadow: var(--shadow-glow-indigo);
  2097. }
  2098. .sidebar-toggle:hover::before {
  2099. left: 100%;
  2100. }
  2101. .sidebar-toggle:active {
  2102. transform: scale(0.95);
  2103. }
  2104. /* 移动端侧边栏遮罩层 */
  2105. .sidebar-overlay {
  2106. position: fixed;
  2107. top: 0;
  2108. left: 0;
  2109. width: 100%;
  2110. height: 100%;
  2111. background: rgba(0, 0, 0, 0.5);
  2112. backdrop-filter: blur(4px);
  2113. -webkit-backdrop-filter: blur(4px);
  2114. z-index: 999;
  2115. opacity: 0;
  2116. visibility: hidden;
  2117. transition: all 0.3s ease;
  2118. }
  2119. .sidebar-overlay.show {
  2120. opacity: 1;
  2121. visibility: visible;
  2122. }
  2123. header,
  2124. .glass-header,
  2125. header::before {
  2126. border-radius: var(--radius) var(--radius) 0 0;
  2127. padding: 12px 16px;
  2128. flex-direction: column;
  2129. gap: 12px;
  2130. align-items: stretch;
  2131. }
  2132. /* 头部第一行:图标、应用文案和版本号 */
  2133. .logo-title-container {
  2134. display: flex;
  2135. align-items: center;
  2136. justify-content: center;
  2137. gap: 8px;
  2138. order: 1;
  2139. }
  2140. .logo-title-link{
  2141. display: none;
  2142. }
  2143. .header-logo {
  2144. width: 32px;
  2145. height: 32px;
  2146. }
  2147. header h1 {
  2148. font-size: 1.1rem;
  2149. margin: 0;
  2150. text-align: center;
  2151. }
  2152. .version-tag {
  2153. font-size: 0.65rem;
  2154. padding: 1px 6px;
  2155. }
  2156. /* 头部第二行:智能体切换和重置按钮 */
  2157. .buttons-container {
  2158. display: flex;
  2159. gap: 8px;
  2160. align-items: center;
  2161. justify-content: center;
  2162. order: 2;
  2163. flex-wrap: wrap;
  2164. }
  2165. /* 智能体下拉菜单移动端优化 */
  2166. #agent-dropdown {
  2167. flex: 1;
  2168. min-width: 120px;
  2169. justify-content: center;
  2170. padding: 8px 12px;
  2171. font-size: 0.8rem;
  2172. }
  2173. #agent-dropdown span {
  2174. font-size: 0.8rem;
  2175. }
  2176. /* 重置按钮移动端优化 */
  2177. #reset-btn {
  2178. flex: 1;
  2179. min-width: 120px;
  2180. justify-content: center;
  2181. padding: 8px 12px;
  2182. font-size: 0.8rem;
  2183. }
  2184. #reset-btn svg {
  2185. width: 14px;
  2186. height: 14px;
  2187. }
  2188. /* 用户信息移动端优化 - 保持左右布局,上下排版 */
  2189. .user-info {
  2190. order: 3;
  2191. flex-direction: row;
  2192. align-items: center;
  2193. gap: 12px;
  2194. padding: 12px 16px;
  2195. margin-top: 8px;
  2196. width: 100%;
  2197. max-width: 280px;
  2198. margin-left: auto;
  2199. margin-right: auto;
  2200. }
  2201. .user-details {
  2202. flex-direction: row;
  2203. align-items: center;
  2204. gap: 12px;
  2205. text-align: left;
  2206. flex: 1;
  2207. }
  2208. .user-avatar {
  2209. width: 44px;
  2210. height: 44px;
  2211. flex-shrink: 0;
  2212. }
  2213. .user-text {
  2214. display: flex;
  2215. flex-direction: column;
  2216. align-items: flex-start;
  2217. gap: 3px;
  2218. flex: 1;
  2219. min-width: 0;
  2220. }
  2221. .user-info-row {
  2222. display: flex;
  2223. align-items: center;
  2224. gap: 8px;
  2225. width: 100%;
  2226. }
  2227. .user-name {
  2228. font-size: 0.9rem;
  2229. font-weight: 600;
  2230. white-space: nowrap;
  2231. }
  2232. .user-type {
  2233. font-size: 0.75rem;
  2234. padding: 1px 5px;
  2235. white-space: nowrap;
  2236. }
  2237. .user-title {
  2238. font-size: 0.8rem;
  2239. max-width: none;
  2240. width: 100%;
  2241. }
  2242. /* 移动端用户下拉菜单优化 */
  2243. .user-dropdown {
  2244. position: fixed;
  2245. top: 50%;
  2246. left: 50%;
  2247. transform: translate(-50%, -50%) scale(0.95);
  2248. right: auto;
  2249. width: 90%;
  2250. max-width: 300px;
  2251. opacity: 0;
  2252. visibility: hidden;
  2253. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  2254. }
  2255. .user-info:hover .user-dropdown {
  2256. opacity: 1;
  2257. visibility: visible;
  2258. transform: translate(-50%, -50%) scale(1);
  2259. }
  2260. .user-dropdown::before {
  2261. display: none;
  2262. }
  2263. .user-type {
  2264. font-size: 0.75rem;
  2265. padding: 2px 8px;
  2266. }
  2267. .user-title {
  2268. font-size: 0.75rem;
  2269. opacity: 0.8;
  2270. }
  2271. /* 智能体菜单移动端优化 */
  2272. #agent-menu {
  2273. position: fixed !important;
  2274. top: 50% !important;
  2275. left: 50% !important;
  2276. transform: translate(-50%, -50%) !important;
  2277. width: 280px !important;
  2278. max-width: 90vw !important;
  2279. z-index: 1002 !important;
  2280. background: rgba(255, 255, 255, 0.95) !important;
  2281. backdrop-filter: blur(20px) !important;
  2282. border: 1px solid rgba(255, 255, 255, 0.3) !important;
  2283. box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2) !important;
  2284. }
  2285. #agent-menu ul {
  2286. padding: 16px !important;
  2287. }
  2288. .agent-option {
  2289. padding: 16px !important;
  2290. margin-bottom: 8px !important;
  2291. border-radius: 12px !important;
  2292. background: rgba(255, 255, 255, 0.8) !important;
  2293. border: 1px solid rgba(255, 255, 255, 0.3) !important;
  2294. transition: all 0.2s ease !important;
  2295. }
  2296. .agent-option:hover {
  2297. background: rgba(99, 102, 241, 0.1) !important;
  2298. border-color: rgba(99, 102, 241, 0.3) !important;
  2299. transform: translateY(-2px) !important;
  2300. }
  2301. .agent-option[data-active="true"] {
  2302. background: rgba(99, 102, 241, 0.15) !important;
  2303. border-color: rgba(99, 102, 241, 0.4) !important;
  2304. box-shadow: 0 4px 12px rgba(99, 102, 241, 0.2) !important;
  2305. }
  2306. /* 聊天内容区域移动端优化 */
  2307. .chat-main-content {
  2308. flex: 1;
  2309. display: flex;
  2310. flex-direction: column;
  2311. min-height: 0;
  2312. background: rgba(255, 255, 255, 0.02);
  2313. }
  2314. .chat-messages {
  2315. padding: 16px;
  2316. gap: 20px;
  2317. flex: 1;
  2318. min-height: 0;
  2319. overflow-y: auto;
  2320. -webkit-overflow-scrolling: touch;
  2321. }
  2322. .chat-messages::-webkit-scrollbar {
  2323. width: 6px;
  2324. }
  2325. .chat-messages::-webkit-scrollbar-track {
  2326. background: transparent;
  2327. }
  2328. .chat-messages::-webkit-scrollbar-thumb {
  2329. background: rgba(255, 255, 255, 0.2);
  2330. border-radius: 3px;
  2331. }
  2332. .chat-messages::-webkit-scrollbar-thumb:hover {
  2333. background: rgba(255, 255, 255, 0.3);
  2334. }
  2335. .message {
  2336. border-radius: 16px;
  2337. margin-bottom: 16px;
  2338. box-shadow: var(--shadow-sm);
  2339. transition: all 0.2s ease;
  2340. }
  2341. .message:hover {
  2342. transform: translateY(-1px);
  2343. box-shadow: var(--shadow);
  2344. }
  2345. .message-content {
  2346. padding: 16px;
  2347. font-size: 0.9rem;
  2348. line-height: 1.6;
  2349. border-radius: 16px;
  2350. }
  2351. .message.bot {
  2352. width: 100%;
  2353. max-width: 100%;
  2354. margin-right: 0;
  2355. }
  2356. .message.bot .message-content {
  2357. padding: 16px;
  2358. background: rgba(255, 255, 255, 0.15);
  2359. border: 1px solid rgba(255, 255, 255, 0.1);
  2360. }
  2361. .message.user {
  2362. align-self: flex-end;
  2363. margin-left: 20px;
  2364. }
  2365. .message.user .message-content {
  2366. background: rgba(99, 102, 241, 0.15);
  2367. border: 1px solid rgba(99, 102, 241, 0.2);
  2368. color: var(--gray-800);
  2369. }
  2370. .thought-container {
  2371. margin: 12px 0 20px 0;
  2372. padding: 12px 16px;
  2373. border-radius: 12px;
  2374. background: rgba(99, 102, 241, 0.08);
  2375. border-left: 3px solid var(--primary-indigo);
  2376. }
  2377. /* 输入区域移动端优化 */
  2378. .chat-input-container {
  2379. padding: 16px;
  2380. border-top: 1px solid rgba(255, 255, 255, 0.1);
  2381. background: rgba(255, 255, 255, 0.05);
  2382. position: relative;
  2383. }
  2384. .chat-input-container::before {
  2385. content: '';
  2386. position: absolute;
  2387. top: 0;
  2388. left: 0;
  2389. width: 100%;
  2390. height: 100%;
  2391. background: linear-gradient(to bottom, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.02));
  2392. opacity: 0.3;
  2393. z-index: -1;
  2394. pointer-events: none;
  2395. border-radius: 0 0 var(--radius) var(--radius);
  2396. }
  2397. #user-input {
  2398. padding: 12px 16px;
  2399. font-size: 0.9rem;
  2400. min-height: 44px;
  2401. max-height: 120px;
  2402. resize: none;
  2403. border-radius: 12px;
  2404. border: 1px solid rgba(255, 255, 255, 0.2);
  2405. background: rgba(255, 255, 255, 0.1);
  2406. color: var(--gray-800);
  2407. transition: all 0.2s ease;
  2408. }
  2409. #user-input:focus {
  2410. outline: none;
  2411. border-color: var(--primary-indigo);
  2412. background: rgba(255, 255, 255, 0.15);
  2413. box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
  2414. }
  2415. #send-btn {
  2416. width: 44px;
  2417. height: 44px;
  2418. min-width: 44px;
  2419. border-radius: 12px;
  2420. background: var(--primary-indigo);
  2421. border: none;
  2422. color: white;
  2423. transition: all 0.2s ease;
  2424. box-shadow: var(--shadow-sm);
  2425. }
  2426. #send-btn:hover {
  2427. background: var(--primary-purple);
  2428. transform: translateY(-1px);
  2429. box-shadow: var(--shadow);
  2430. }
  2431. #send-btn:active {
  2432. transform: translateY(0);
  2433. box-shadow: var(--shadow-sm);
  2434. }
  2435. #send-btn svg {
  2436. width: 18px;
  2437. height: 18px;
  2438. }
  2439. /* 移动端智能体切换菜单栏适配 */
  2440. .agent-switcher-container {
  2441. position: fixed;
  2442. left: 0;
  2443. top: 0;
  2444. width: 100%;
  2445. height: 100%;
  2446. z-index: 1000;
  2447. background: rgba(0, 0, 0, 0.5);
  2448. opacity: 0;
  2449. visibility: hidden;
  2450. transition: all 0.3s ease;
  2451. }
  2452. .agent-switcher-container.show {
  2453. opacity: 1;
  2454. visibility: visible;
  2455. }
  2456. .agent-switcher {
  2457. position: absolute;
  2458. left: 0;
  2459. top: 0;
  2460. width: 280px;
  2461. height: 100%;
  2462. border-radius: 0;
  2463. transform: translateX(-100%);
  2464. transition: transform 0.3s ease;
  2465. overflow-y: auto;
  2466. }
  2467. .agent-switcher-container.show .agent-switcher {
  2468. transform: translateX(0);
  2469. }
  2470. /* 移动端平台项样式优化 */
  2471. .agent-item {
  2472. padding: 20px 24px;
  2473. margin: 0 16px 16px 16px;
  2474. border-radius: var(--radius-lg);
  2475. }
  2476. .agent-icon {
  2477. width: 60px;
  2478. height: 60px;
  2479. }
  2480. .platform-icon {
  2481. width: 40px;
  2482. height: 40px;
  2483. filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.1));
  2484. }
  2485. .agent-title {
  2486. font-size: 1.2rem;
  2487. }
  2488. /* 添加移动端菜单切换按钮 */
  2489. .mobile-menu-toggle {
  2490. display: block;
  2491. position: fixed;
  2492. left: 20px;
  2493. top: 100px;
  2494. z-index: 999;
  2495. width: 50px;
  2496. height: 50px;
  2497. background: var(--primary-indigo);
  2498. border: none;
  2499. border-radius: 50%;
  2500. color: white;
  2501. font-size: 1.2rem;
  2502. box-shadow: var(--shadow-lg);
  2503. cursor: pointer;
  2504. transition: var(--transition);
  2505. }
  2506. .mobile-menu-toggle:hover {
  2507. transform: scale(1.1);
  2508. box-shadow: var(--shadow-glow-indigo);
  2509. }
  2510. /* 移动端智能体切换通知优化 */
  2511. .agent-switch-notification {
  2512. top: 20px;
  2513. right: 20px;
  2514. left: 20px;
  2515. transform: translateY(-100px);
  2516. }
  2517. .agent-switch-notification.show {
  2518. transform: translateY(0);
  2519. }
  2520. .notification-content {
  2521. padding: 12px 16px;
  2522. min-width: auto;
  2523. width: 100%;
  2524. }
  2525. .notification-text {
  2526. font-size: 0.85rem;
  2527. }
  2528. }
  2529. /* 改进markdown内容的渲染样式 */
  2530. .markdown-content {
  2531. width: 100%;
  2532. }
  2533. .markdown-content p {
  2534. margin-bottom: 1em;
  2535. }
  2536. .markdown-content h1,
  2537. .markdown-content h2,
  2538. .markdown-content h3,
  2539. .markdown-content h4 {
  2540. margin-top: 1.2em;
  2541. margin-bottom: 0.8em;
  2542. font-weight: 600;
  2543. line-height: 1.3;
  2544. }
  2545. .markdown-content h1 {
  2546. font-size: 1.7em;
  2547. }
  2548. .markdown-content h2 {
  2549. font-size: 1.5em;
  2550. }
  2551. .markdown-content h3 {
  2552. font-size: 1.3em;
  2553. }
  2554. .markdown-content ul,
  2555. .markdown-content ol {
  2556. margin-bottom: 1em;
  2557. padding-left: 1.5em;
  2558. }
  2559. .markdown-content li {
  2560. margin-bottom: 0.5em;
  2561. }
  2562. .markdown-content pre {
  2563. margin-bottom: 1.2em;
  2564. border-radius: 6px;
  2565. }
  2566. /* 智能体切换通知样式 */
  2567. .agent-switch-notification {
  2568. position: fixed;
  2569. top: 100px;
  2570. right: 30px;
  2571. z-index: 1003;
  2572. transform: translateX(400px);
  2573. transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  2574. }
  2575. .agent-switch-notification.show {
  2576. transform: translateX(0);
  2577. }
  2578. .notification-content {
  2579. display: flex;
  2580. align-items: center;
  2581. gap: 12px;
  2582. padding: 16px 20px;
  2583. background: rgba(255, 255, 255, 0.95);
  2584. backdrop-filter: blur(var(--blur-md));
  2585. -webkit-backdrop-filter: blur(var(--blur-md));
  2586. border: 1px solid rgba(99, 102, 241, 0.2);
  2587. border-radius: var(--radius-lg);
  2588. box-shadow: var(--shadow-lg);
  2589. min-width: 200px;
  2590. }
  2591. .notification-icon {
  2592. font-size: 1.2rem;
  2593. animation: bounce 0.6s ease-in-out;
  2594. }
  2595. .notification-text {
  2596. font-weight: 500;
  2597. color: var(--gray-800);
  2598. font-size: 0.95rem;
  2599. }
  2600. /* 平台特定通知样式 */
  2601. .agent-switch-notification[data-platform="kuaishou"] .notification-content {
  2602. border-color: rgba(255, 69, 0, 0.3);
  2603. background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(255, 69, 0, 0.05));
  2604. }
  2605. .agent-switch-notification[data-platform="toutiao"] .notification-content {
  2606. border-color: rgba(0, 123, 255, 0.3);
  2607. background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(0, 123, 255, 0.05));
  2608. }
  2609. .agent-switch-notification[data-platform="videoaccount"] .notification-content {
  2610. border-color: rgba(40, 167, 69, 0.3);
  2611. background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(40, 167, 69, 0.05));
  2612. }
  2613. @keyframes bounce {
  2614. 0%, 20%, 50%, 80%, 100% {
  2615. transform: translateY(0);
  2616. }
  2617. 40% {
  2618. transform: translateY(-8px);
  2619. }
  2620. 60% {
  2621. transform: translateY(-4px);
  2622. }
  2623. }
  2624. /* 移动端智能体菜单遮罩层样式 */
  2625. .mobile-agent-overlay {
  2626. position: fixed;
  2627. top: 0;
  2628. left: 0;
  2629. width: 100%;
  2630. height: 100%;
  2631. background: rgba(0, 0, 0, 0.5);
  2632. backdrop-filter: blur(4px);
  2633. -webkit-backdrop-filter: blur(4px);
  2634. z-index: 1001;
  2635. opacity: 0;
  2636. transition: opacity 0.3s ease;
  2637. }
  2638. .mobile-agent-overlay.show {
  2639. opacity: 1;
  2640. }
  2641. /* 移动端智能体菜单动画 */
  2642. @media (max-width: 768px) {
  2643. #agent-menu {
  2644. opacity: 0;
  2645. transform: translate(-50%, -50%) scale(0.9) !important;
  2646. transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
  2647. }
  2648. #agent-menu.show {
  2649. opacity: 1;
  2650. transform: translate(-50%, -50%) scale(1) !important;
  2651. }
  2652. }
  2653. /* 移动端触摸优化 */
  2654. .glass-btn,
  2655. #agent-dropdown,
  2656. #reset-btn,
  2657. #send-btn {
  2658. -webkit-tap-highlight-color: transparent;
  2659. touch-action: manipulation;
  2660. user-select: none;
  2661. }
  2662. .glass-btn:active,
  2663. #agent-dropdown:active,
  2664. #reset-btn:active,
  2665. #send-btn:active {
  2666. transform: scale(0.95);
  2667. transition: transform 0.1s ease;
  2668. }
  2669. /* 移动端智能体选项触摸优化 */
  2670. .agent-option {
  2671. -webkit-tap-highlight-color: transparent;
  2672. touch-action: manipulation;
  2673. user-select: none;
  2674. }
  2675. .agent-option:active {
  2676. transform: scale(0.98);
  2677. transition: transform 0.1s ease;
  2678. }
  2679. /* 移动端用户信息触摸优化 */
  2680. .user-info {
  2681. -webkit-tap-highlight-color: transparent;
  2682. touch-action: manipulation;
  2683. }
  2684. .user-info:active {
  2685. transform: scale(0.98);
  2686. transition: transform 0.1s ease;
  2687. }
  2688. /* 移动端输入框触摸优化 */
  2689. #user-input {
  2690. -webkit-tap-highlight-color: transparent;
  2691. touch-action: manipulation;
  2692. }
  2693. /* 历史记录加载动画和空状态样式 */
  2694. .history-loading, .history-empty {
  2695. display: flex;
  2696. flex-direction: column;
  2697. align-items: center;
  2698. justify-content: center;
  2699. padding: 20px;
  2700. color: var(--gray-500);
  2701. font-size: 14px;
  2702. text-align: center;
  2703. gap: 10px;
  2704. height: 100%;
  2705. }
  2706. .history-loading .loading-spinner {
  2707. border: 4px solid rgba(99, 102, 241, 0.2);
  2708. border-top: 4px solid var(--primary-indigo);
  2709. border-radius: 50%;
  2710. width: 30px;
  2711. height: 30px;
  2712. animation: spin 1s linear infinite;
  2713. }
  2714. @keyframes spin {
  2715. 0% { transform: rotate(0deg); }
  2716. 100% { transform: rotate(360deg); }
  2717. }
  2718. .history-empty svg {
  2719. color: var(--gray-400);
  2720. width: 48px;
  2721. height: 48px;
  2722. }
  2723. .history-empty p {
  2724. margin: 0;
  2725. font-weight: 500;
  2726. }
  2727. .history-empty .new-chat-btn {
  2728. margin-top: 15px;
  2729. }