| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171 |
- /* 现代文案撰写系统界面 - 毛玻璃效果版 */
- @import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');
- /* 导入组件样式 */
- @import 'components/copy-button.css';
- @import 'components/tables.css';
- @import 'components/markdown.css';
- /*
- * Z-Index 层级说明:
- * 1000: 用户下拉菜单、通知消息
- * 1001: 移动端智能体菜单遮罩层
- * 1002: 智能体菜单、智能体下拉按钮
- * 1003+: 其他高级UI元素
- */
- :root {
- /* 主色调更新为现代风格 */
- --primary-indigo: #6366f1;
- --primary-purple: #8b5cf6;
- --primary-blue: #3b82f6;
- --primary-teal: #14b8a6;
-
- /* 渐变色 */
- --indigo-purple-gradient: linear-gradient(135deg, var(--primary-indigo), var(--primary-purple));
- --blue-teal-gradient: linear-gradient(135deg, var(--primary-blue), var(--primary-teal));
-
- /* 状态颜色 */
- --success-color: #10b981;
- --warning-color: #f59e0b;
- --danger-color: #ef4444;
- --info-color: #3b82f6;
-
- /* 创意等级颜色 */
- --creative-high-color: #10b981;
- --creative-medium-color: #f59e0b;
- --creative-low-color: #ef4444;
-
- /* 中性色调 */
- --gray-50: #f9fafb;
- --gray-100: #f3f4f6;
- --gray-200: #e5e7eb;
- --gray-300: #d1d5db;
- --gray-400: #9ca3af;
- --gray-500: #6b7280;
- --gray-600: #4b5563;
- --gray-700: #374151;
- --gray-800: #1f2937;
- --gray-900: #111827;
-
- /* 阴影效果 */
- --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
- --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
- --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
- --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
- --shadow-inner: inset 0 2px 4px 0 rgba(0, 0, 0, 0.06);
- --shadow-glow-indigo: 0 0 15px 2px rgba(99, 102, 241, 0.25);
- --shadow-glow-purple: 0 0 15px 2px rgba(139, 92, 246, 0.25);
-
- /* 圆角设置 */
- --radius-sm: 0.25rem;
- --radius: 0.5rem;
- --radius-md: 0.75rem;
- --radius-lg: 1rem;
- --radius-xl: 1.5rem;
- --radius-full: 9999px;
-
- /* 过渡和动效 */
- --transition: all 0.3s ease;
- --transition-slow: all 0.5s ease;
- --transition-bounce: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
-
- /* 毛玻璃效果 */
- --blur-sm: 4px;
- --blur-md: 8px;
- --blur-lg: 12px;
- --glass-opacity: 0.7;
- --glass-border: 1px solid rgba(255, 255, 255, 0.2);
- --glass-background: rgba(255, 255, 255, 0.15);
- --glass-background-dark: rgba(23, 25, 35, 0.6);
- }
- /* 水波纹效果 */
- .ripple {
- position: absolute;
- border-radius: 50%;
- background-color: rgba(255, 255, 255, 0.4);
- transform: scale(0);
- animation: ripple 0.6s linear;
- pointer-events: none;
- }
- @keyframes ripple {
- to {
- transform: scale(4);
- opacity: 0;
- }
- }
- .btn, #reset-btn, #toggle-streaming-btn, #send-btn {
- position: relative;
- overflow: hidden;
- }
- /* 发送按钮动画效果 */
- #send-btn.sending {
- animation: sending-pulse 0.6s ease-in-out;
- }
- /* 停止按钮样式 */
- #send-btn.stopping {
- background-color: var(--danger-color);
- transition: background-color 0.3s ease;
- position: relative;
- }
- #send-btn.stopping:hover {
- background-color: #f43636;
- transform: translateY(-2px);
- }
- #send-btn.stopping svg {
- width: 12px;
- height: 12px;
- color: white;
- background-color: white;
- border-radius: 2px;
- }
- @keyframes sending-pulse {
- 0% {
- transform: scale(1);
- }
- 50% {
- transform: scale(0.92);
- background: var(--primary-indigo);
- }
- 100% {
- transform: scale(1);
- }
- }
- * {
- box-sizing: border-box;
- margin: 0;
- padding: 0;
- }
- /* 全局过渡效果 - 确保主题切换平滑 */
- * {
- transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
- }
- /* 排除不需要过渡的元素 */
- .typing-indicator span,
- .loading-spinner,
- .ripple,
- .message {
- transition: none !important;
- }
- html {
- height: 100%;
- scroll-behavior: smooth;
- }
- body {
- font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
- background: linear-gradient(135deg, #f5f3ff, #ede9fe, #dbeafe, #e0f2fe);
- background-attachment: fixed;
- color: var(--gray-800);
- line-height: 1.6;
- min-height: 100vh;
- display: flex;
- justify-content: center;
- align-items: center;
- padding: 20px;
- position: relative;
- overflow-x: hidden;
- transition: background 0.3s ease, color 0.3s ease;
- }
- /* 背景动画元素 */
- .glass-particles {
- position: fixed;
- top: 0;
- left: 0;
- width: 100%;
- height: 100%;
- z-index: -1;
- overflow: hidden;
- }
- .glass-particles::before,
- .glass-particles::after {
- content: '';
- position: absolute;
- border-radius: 50%;
- filter: blur(var(--blur-lg));
- opacity: 0.4;
- animation: float 20s infinite alternate ease-in-out;
- }
- .glass-particles::before {
- width: 300px;
- height: 300px;
- background: var(--primary-indigo);
- top: 10%;
- left: 15%;
- animation-delay: 0s;
- }
- .glass-particles::after {
- width: 250px;
- height: 250px;
- background: var(--primary-purple);
- bottom: 15%;
- right: 10%;
- animation-delay: -10s;
- }
- @keyframes float {
- 0% {
- transform: translate(0, 0) scale(1);
- }
- 50% {
- transform: translate(5%, 5%) scale(1.1);
- }
- 100% {
- transform: translate(-5%, -5%) scale(0.9);
- }
- }
- body::before {
- content: '';
- position: fixed;
- top: 0;
- left: 0;
- width: 100%;
- height: 100%;
- 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");
- opacity: 0.5;
- z-index: -1;
- }
- /* 通用毛玻璃效果 */
- .glass-panel {
- background-color: rgb(255, 255, 255);
- backdrop-filter: blur(var(--blur-sm));
- -webkit-backdrop-filter: blur(var(--blur-sm));
- box-shadow: var(--shadow);
- border: var(--glass-border);
- transition: var(--transition);
- }
- .glass-panel:hover {
- box-shadow: var(--shadow-md);
- }
- .glass-header {
- backdrop-filter: blur(var(--blur-md));
- -webkit-backdrop-filter: blur(var(--blur-md));
- border-radius: var(--radius-lg) var(--radius-lg) 0 0;
- z-index: 100;
- position: relative;
- }
- .chat-container {
- width: 100%;
- max-width: 1600px;
- height: calc(100vh - 40px);
- max-height: 900px;
- display: flex;
- flex-direction: row;
- margin: 0 auto;
- box-shadow: var(--shadow-lg);
- position: relative;
- background-color: rgba(255, 255, 255, 0.1);
- backdrop-filter: blur(var(--blur-sm));
- -webkit-backdrop-filter: blur(var(--blur-sm));
- border: var(--glass-border);
- border-radius: var(--radius-lg);
- transition: var(--transition);
- overflow: hidden; /* 防止内容溢出 */
- z-index: 1;
- }
- .chat-container:hover {
- box-shadow: var(--shadow-glow-indigo);
- }
- /* 历史记录侧边栏样式 */
- .history-sidebar {
- width: 280px;
- min-width: 280px;
- height: 100%;
- background: rgba(255, 255, 255, 0.15);
- backdrop-filter: blur(var(--blur-md));
- -webkit-backdrop-filter: blur(var(--blur-md));
- border-right: var(--glass-border);
- display: flex;
- flex-direction: column;
- position: relative;
- z-index: 2;
- }
- .sidebar-header {
- padding: 20px 16px 16px 16px;
- border-bottom: var(--glass-border);
- background: rgba(255, 255, 255, 0.1);
- }
- .logo-container {
- display: flex;
- align-items: center;
- gap: 12px;
- margin-bottom: 16px;
- }
- .sidebar-logo {
- width: 32px;
- height: 32px;
- border-radius: var(--radius);
- object-fit: contain;
- filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
- }
- .sidebar-title {
- font-size: 1.1rem;
- font-weight: 600;
- color: var(--gray-800);
- }
- .new-chat-btn {
- width: 100%;
- padding: 12px 16px;
- background: rgba(255, 255, 255, 0.8);
- border: 1px solid rgba(255, 255, 255, 0.3);
- border-radius: var(--radius);
- color: var(--gray-700);
- font-size: 0.9rem;
- font-weight: 500;
- cursor: pointer;
- display: flex;
- align-items: center;
- justify-content: center;
- gap: 8px;
- transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
- box-shadow: var(--shadow-sm);
- position: relative;
- overflow: hidden;
- }
- .new-chat-btn::before {
- content: '';
- position: absolute;
- top: 0;
- left: -100%;
- width: 100%;
- height: 100%;
- background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
- transition: left 0.5s ease;
- }
- .new-chat-btn:hover {
- background: rgba(255, 255, 255, 0.95);
- color: var(--gray-900);
- transform: translateY(-2px);
- box-shadow: var(--shadow-md);
- border-color: rgba(99, 102, 241, 0.3);
- }
- .new-chat-btn:hover::before {
- left: 100%;
- }
- .new-chat-btn:active {
- transform: translateY(-1px);
- box-shadow: var(--shadow-sm);
- }
- .new-chat-btn svg {
- transition: transform 0.3s ease;
- }
- .new-chat-btn:hover svg {
- transform: scale(1.1) rotate(90deg);
- }
- .history-content {
- flex: 1;
- overflow-y: auto;
- padding: 8px 0;
- scrollbar-width: thin;
- scrollbar-color: rgba(100, 116, 139, 0.3) transparent;
- }
- .history-content::-webkit-scrollbar {
- width: 6px;
- }
- .history-content::-webkit-scrollbar-track {
- background: transparent;
- }
- .history-content::-webkit-scrollbar-thumb {
- background-color: rgba(100, 116, 139, 0.3);
- border-radius: 3px;
- }
- .history-content::-webkit-scrollbar-thumb:hover {
- background-color: rgba(100, 116, 139, 0.5);
- }
- .history-group {
- margin-bottom: 24px;
- }
- .group-header {
- padding: 8px 16px 8px 16px;
- font-size: 0.8rem;
- font-weight: 600;
- color: var(--gray-500);
- text-transform: uppercase;
- letter-spacing: 0.5px;
- margin-bottom: 8px;
- position: relative;
- transition: all 0.3s ease;
- }
- .group-header::before {
- content: '';
- position: absolute;
- left: 0;
- top: 50%;
- width: 3px;
- height: 12px;
- background: linear-gradient(to bottom, var(--primary-indigo), var(--primary-purple));
- border-radius: 2px;
- transform: translateY(-50%);
- opacity: 0.6;
- transition: all 0.3s ease;
- }
- .group-header:hover {
- color: var(--gray-700);
- transform: translateX(4px);
- }
- .group-header:hover::before {
- opacity: 1;
- height: 16px;
- }
- .conversation-list {
- padding: 0 8px;
- }
- .conversation-item {
- display: flex;
- align-items: center;
- padding: 12px 16px;
- margin-bottom: 4px;
- border-radius: var(--radius);
- cursor: pointer;
- transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
- position: relative;
- background: transparent;
- border: 1px solid transparent;
- overflow: hidden;
- }
- .conversation-item::before {
- content: '';
- position: absolute;
- top: 0;
- left: -100%;
- width: 100%;
- height: 100%;
- background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.1), transparent);
- transition: left 0.6s ease;
- opacity: 0;
- }
- .conversation-item:hover {
- background: rgba(255, 255, 255, 0.15);
- border-color: rgba(255, 255, 255, 0.25);
- transform: translateX(4px);
- box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
- }
- .conversation-item:hover::before {
- left: 100%;
- opacity: 1;
- }
- .conversation-item.active {
- background: rgba(99, 102, 241, 0.2);
- border-color: rgba(99, 102, 241, 0.4);
- box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
- transform: translateX(6px);
- }
- .conversation-item.active::before {
- background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.2), transparent);
- opacity: 1;
- }
- .conversation-content {
- flex: 1;
- min-width: 0;
- margin-right: 8px;
- }
- .conversation-title {
- font-size: 0.9rem;
- color: var(--gray-700);
- font-weight: 500;
- line-height: 1.4;
- overflow: hidden;
- text-overflow: ellipsis;
- white-space: nowrap;
- }
- .conversation-item.active .conversation-title {
- color: var(--primary-indigo);
- font-weight: 600;
- }
- .conversation-menu {
- width: 24px;
- height: 24px;
- background: transparent;
- border: none;
- border-radius: 50%;
- cursor: pointer;
- display: flex;
- align-items: center;
- justify-content: center;
- opacity: 0;
- transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
- color: var(--gray-500);
- position: relative;
- overflow: hidden;
- }
- .conversation-menu::before {
- content: '';
- position: absolute;
- top: 50%;
- left: 50%;
- width: 0;
- height: 0;
- background: rgba(99, 102, 241, 0.1);
- border-radius: 50%;
- transition: all 0.3s ease;
- transform: translate(-50%, -50%);
- }
- .conversation-item:hover .conversation-menu {
- opacity: 1;
- background: rgba(255, 255, 255, 0.1);
- transform: scale(1.1);
- }
- .conversation-item:hover .conversation-menu::before {
- width: 100%;
- height: 100%;
- }
- .conversation-menu:hover {
- background: rgba(255, 255, 255, 0.2);
- color: var(--gray-700);
- transform: scale(1.2);
- }
- .conversation-menu:hover::before {
- background: rgba(99, 102, 241, 0.2);
- }
- .sidebar-footer {
- padding: 16px;
- border-top: var(--glass-border);
- background: rgba(255, 255, 255, 0.05);
- }
- .user-profile {
- display: flex;
- align-items: center;
- gap: 12px;
- padding: 12px;
- border-radius: var(--radius);
- background: rgba(255, 255, 255, 0.1);
- border: 1px solid rgba(255, 255, 255, 0.2);
- cursor: pointer;
- transition: var(--transition);
- }
- .user-profile:hover {
- background: rgba(255, 255, 255, 0.15);
- border-color: rgba(255, 255, 255, 0.3);
- }
- .user-avatar-sidebar {
- width: 32px;
- height: 32px;
- border-radius: 50%;
- overflow: hidden;
- background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
- border: 2px solid rgba(255, 255, 255, 0.3);
- flex-shrink: 0;
- }
- .user-avatar-sidebar img {
- width: 100%;
- height: 100%;
- object-fit: cover;
- }
- .avatar-fallback-sidebar {
- width: 100%;
- height: 100%;
- background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
- display: flex;
- align-items: center;
- justify-content: center;
- color: white;
- font-weight: 600;
- font-size: 14px;
- text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
- }
- .user-info-sidebar {
- flex: 1;
- min-width: 0;
- }
- .user-name-sidebar {
- font-size: 0.9rem;
- font-weight: 600;
- color: var(--gray-800);
- white-space: nowrap;
- overflow: hidden;
- text-overflow: ellipsis;
- }
- .user-menu-btn {
- width: 24px;
- height: 24px;
- background: transparent;
- border: none;
- border-radius: 50%;
- cursor: pointer;
- display: flex;
- align-items: center;
- justify-content: center;
- opacity: 0.6;
- transition: var(--transition);
- color: var(--gray-500);
- }
- .user-profile:hover .user-menu-btn {
- opacity: 1;
- background: rgba(255, 255, 255, 0.1);
- }
- .user-menu-btn:hover {
- background: rgba(255, 255, 255, 0.2);
- color: var(--gray-700);
- }
- /* 对话上下文菜单样式 */
- .conversation-context-menu {
- position: absolute;
- background: rgba(255, 255, 255, 0.95);
- backdrop-filter: blur(20px);
- -webkit-backdrop-filter: blur(20px);
- border: 1px solid rgba(255, 255, 255, 0.3);
- border-radius: 8px;
- box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
- padding: 8px 0;
- min-width: 120px;
- z-index: 1000;
- opacity: 0;
- transform: scale(0.9);
- transition: all 0.2s ease;
- }
- .conversation-context-menu.show {
- opacity: 1;
- transform: scale(1);
- }
- .menu-item {
- display: flex;
- align-items: center;
- gap: 8px;
- padding: 8px 16px;
- cursor: pointer;
- transition: background-color 0.2s ease;
- color: var(--gray-700);
- font-size: 0.9rem;
- }
- .menu-item:hover {
- background: rgba(99, 102, 241, 0.1);
- color: var(--primary-indigo);
- }
- .menu-item svg {
- width: 16px;
- height: 16px;
- flex-shrink: 0;
- }
- /* 主聊天区域样式 */
- .main-chat-area {
- flex: 1;
- display: flex;
- flex-direction: column;
- min-width: 0;
- height: 100%;
- }
- /* 智能体切换菜单栏样式 */
- .agent-switcher-container {
- position: absolute;
- left: -280px;
- top: 80px;
- width: 260px;
- z-index: 20;
- }
- .agent-switcher {
- width: 100%;
- background: rgba(255, 255, 255, 0.15);
- backdrop-filter: blur(var(--blur-md));
- -webkit-backdrop-filter: blur(var(--blur-md));
- border: var(--glass-border);
- border-radius: var(--radius-lg);
- padding: 20px;
- box-shadow: var(--shadow-lg);
- transition: var(--transition);
- }
- .agent-switcher:hover {
- box-shadow: var(--shadow-glow-indigo);
- transform: translateX(5px);
- }
- /* 状态指示器样式 */
- .agent-status-indicator {
- display: flex;
- align-items: center;
- gap: 10px;
- margin-bottom: 20px;
- padding: 12px 16px;
- background: rgba(255, 255, 255, 0.1);
- border-radius: var(--radius);
- border: 1px solid rgba(255, 255, 255, 0.2);
- }
- .status-dot {
- width: 8px;
- height: 8px;
- border-radius: 50%;
- background: var(--success-color);
- animation: pulse 2s infinite;
- }
- .status-dot.active {
- background: var(--primary-indigo);
- }
- .status-text {
- font-size: 0.9rem;
- color: var(--gray-700);
- font-weight: 500;
- }
- #current-platform-name {
- color: var(--primary-indigo);
- font-weight: 600;
- }
- @keyframes pulse {
- 0% {
- opacity: 1;
- }
- 50% {
- opacity: 0.5;
- }
- 100% {
- opacity: 1;
- }
- }
- .agent-switcher-header {
- margin-bottom: 20px;
- padding-bottom: 15px;
- border-bottom: 1px solid rgba(255, 255, 255, 0.2);
- }
- .agent-switcher-header h3 {
- margin: 0 0 10px 0;
- font-size: 1.1rem;
- font-weight: 600;
- color: var(--gray-800);
- text-align: center;
- }
- .current-agent {
- display: flex;
- align-items: center;
- justify-content: center;
- gap: 8px;
- font-size: 0.9rem;
- }
- .agent-label {
- color: var(--gray-600);
- }
- .agent-name {
- color: var(--primary-indigo);
- font-weight: 600;
- }
- .agent-list {
- display: flex;
- flex-direction: column;
- gap: 12px;
- }
- .agent-item {
- display: flex;
- align-items: center;
- gap: 12px;
- padding: 16px 20px;
- border-radius: var(--radius);
- background: rgba(255, 255, 255, 0.1);
- border: 1px solid transparent;
- cursor: pointer;
- transition: var(--transition);
- position: relative;
- overflow: hidden;
- user-select: none; /* 防止文本被选中 */
- }
- .agent-item:active {
- transform: scale(0.98);
- transition: transform 0.1s ease;
- }
- .agent-item.active {
- background: rgba(99, 102, 241, 0.1) !important;
- border-color: rgba(99, 102, 241, 0.4) !important;
- box-shadow: var(--shadow-glow-indigo) !important;
- transform: translateX(5px);
- cursor: default; /* 激活状态下显示默认光标 */
- }
- .agent-item.active::before {
- opacity: 1;
- }
- .agent-item.active .agent-title {
- color: var(--primary-indigo) !important;
- font-weight: 700;
- }
- .agent-item.active:hover {
- transform: translateX(5px); /* 保持激活状态的偏移 */
- }
- .agent-item::before {
- content: '';
- position: absolute;
- top: 0;
- left: 0;
- width: 100%;
- height: 100%;
- background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(139, 92, 246, 0.1));
- opacity: 0;
- transition: var(--transition);
- }
- .agent-item:hover {
- background: rgba(255, 255, 255, 0.2);
- border-color: rgba(99, 102, 241, 0.3);
- transform: translateX(3px);
- }
- .agent-item:hover::before {
- opacity: 1;
- }
- .agent-item.active .agent-title {
- color: var(--primary-indigo) !important;
- font-weight: 700;
- }
- .agent-icon {
- width: 50px;
- height: 50px;
- display: flex;
- align-items: center;
- justify-content: center;
- border-radius: var(--radius);
- flex-shrink: 0;
- transition: var(--transition);
- overflow: hidden;
- }
- .platform-icon {
- width: 32px;
- height: 32px;
- object-fit: contain;
- transition: var(--transition);
- filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
- }
- .icon-fallback {
- font-size: 1.8rem;
- color: var(--gray-600);
- display: none;
- }
- /* 图标悬停效果 */
- .agent-item:hover .platform-icon {
- filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.15));
- }
- /* 激活状态下的图标效果 */
- .agent-item.active .platform-icon {
- filter: drop-shadow(0 4px 12px rgba(99, 102, 241, 0.3));
- }
- .agent-item:hover .agent-icon .platform-icon {
- transform: scale(1.1);
- }
- .agent-info {
- flex: 1;
- min-width: 0;
- }
- .agent-title {
- font-weight: 600;
- color: var(--gray-800);
- font-size: 1.1rem;
- }
- /* 聊天主内容区域 */
- .chat-main-content {
- flex: 1;
- display: flex;
- flex-direction: column;
- position: relative;
- min-height: 0; /* 确保flex子元素能够正确收缩 */
- }
- /* 移动端菜单切换按钮 - 默认隐藏 */
- .mobile-menu-toggle {
- display: none;
- position: fixed;
- left: 20px;
- top: 100px;
- z-index: 999;
- width: 50px;
- height: 50px;
- background: var(--primary-indigo);
- border: none;
- border-radius: 50%;
- color: white;
- font-size: 1.2rem;
- box-shadow: var(--shadow-lg);
- cursor: pointer;
- transition: var(--transition);
- }
- .mobile-menu-toggle:hover {
- transform: scale(1.1);
- box-shadow: var(--shadow-glow-indigo);
- }
- .logo-title-container {
- display: flex;
- align-items: center;
- gap: 12px;
- }
- .logo-title-link{
- color: red;
- text-decoration: none;
- }
- .header-logo {
- width: 40px;
- height: 40px;
- border-radius: var(--radius);
- object-fit: contain;
- transition: var(--transition);
- filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
- }
- .header-logo:hover {
- transform: scale(1.05);
- filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.15));
- }
- .version-tag {
- font-size: 0.7rem;
- font-weight: 500;
- color: var(--gray-50);
- background: linear-gradient(135deg, var(--primary-indigo), var(--primary-purple));
- padding: 2px 8px;
- border-radius: var(--radius-full);
- margin-left: 8px;
- box-shadow: var(--shadow-sm);
- vertical-align: middle;
- display: inline-flex;
- align-items: center;
- justify-content: center;
- }
- header {
- display: flex;
- justify-content: space-between;
- align-items: center;
- padding: 12px 20px;
- background-color: rgba(255, 255, 255, 0.25);
- border-bottom: var(--glass-border);
- position: relative;
- z-index: 2;
- backdrop-filter: blur(var(--blur-md));
- -webkit-backdrop-filter: blur(var(--blur-md));
- border-radius: var(--radius-lg) var(--radius-lg) 0 0;
- }
- header::before {
- content: '';
- position: absolute;
- top: 0;
- left: 0;
- width: 100%;
- height: 100%;
- background: linear-gradient(to right, rgba(99, 102, 241, 0.15), rgba(139, 92, 246, 0.15));
- opacity: 0.5;
- z-index: -1;
- border-radius: var(--radius-lg) var(--radius-lg) 0 0;
- }
- header h1 {
- font-size: 1.25rem;
- font-weight: 600;
- color: var(--gray-800);
- display: flex;
- align-items: center;
- margin: 0;
- }
- header h1 svg {
- margin-right: 8px;
- }
- .buttons-container {
- display: flex;
- gap: 10px;
- align-items: center;
- }
- /* 用户信息样式 */
- .user-info {
- position: relative;
- display: flex;
- align-items: center;
- gap: 12px;
- padding: 10px 16px;
- background: rgba(255, 255, 255, 0.15);
- border-radius: 12px;
- border: 1px solid rgba(255, 255, 255, 0.25);
- backdrop-filter: blur(15px);
- transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
- cursor: pointer;
- }
- .user-info:hover {
- background: rgba(255, 255, 255, 0.2);
- border-color: rgba(255, 255, 255, 0.35);
- transform: translateY(-1px);
- box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
- }
- .user-details {
- display: flex;
- align-items: center;
- gap: 10px;
- }
- .user-avatar {
- position: relative;
- width: 36px;
- height: 36px;
- border-radius: 50%;
- overflow: hidden;
- background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
- border: 2px solid rgba(255, 255, 255, 0.3);
- transition: all 0.3s ease;
- }
- .user-info:hover .user-avatar {
- border-color: rgba(255, 255, 255, 0.5);
- transform: scale(1.05);
- }
- .user-avatar img {
- width: 100%;
- height: 100%;
- object-fit: cover;
- transition: transform 0.3s ease;
- }
- .user-info:hover .user-avatar img {
- transform: scale(1.1);
- }
- .avatar-fallback {
- width: 100%;
- height: 100%;
- background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
- display: flex;
- align-items: center;
- justify-content: center;
- color: white;
- font-weight: 600;
- font-size: 16px;
- text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
- }
- .user-text {
- display: flex;
- flex-direction: column;
- align-items: flex-start;
- gap: 2px;
- }
- .user-info-row {
- display: flex;
- align-items: center;
- gap: 8px;
- width: 100%;
- }
- .user-name {
- font-size: 14px;
- font-weight: 600;
- color: #1a1a1a;
- white-space: nowrap;
- text-shadow: 0 1px 2px rgba(255, 255, 255, 0.5);
- }
- .user-type {
- font-size: 11px;
- color: #666;
- opacity: 0.8;
- padding: 2px 6px;
- background: rgba(255, 255, 255, 0.3);
- border-radius: 10px;
- font-weight: 500;
- text-transform: uppercase;
- letter-spacing: 0.5px;
- }
- .user-title {
- font-size: 10px;
- color: #888;
- opacity: 0.7;
- font-style: italic;
- max-width: 120px;
- overflow: hidden;
- text-overflow: ellipsis;
- white-space: nowrap;
- }
- .user-dropdown {
- position: absolute;
- top: calc(100% + 8px);
- right: 0;
- background: rgba(255, 255, 255, 0.98);
- border-radius: 12px;
- box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
- backdrop-filter: blur(20px);
- border: 1px solid rgba(255, 255, 255, 0.3);
- min-width: 220px;
- z-index: 1000;
- opacity: 0;
- visibility: hidden;
- transform: translateY(-15px) scale(0.95);
- transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
- overflow: hidden;
- }
- .user-info:hover .user-dropdown {
- opacity: 1;
- visibility: visible;
- transform: translateY(0) scale(1);
- }
- .user-dropdown::before {
- content: '';
- position: absolute;
- top: -6px;
- right: 20px;
- width: 12px;
- height: 12px;
- background: rgba(255, 255, 255, 0.98);
- border: 1px solid rgba(255, 255, 255, 0.3);
- border-bottom: none;
- border-right: none;
- transform: rotate(45deg);
- }
- .user-dropdown-content {
- padding: 16px;
- }
- .user-info-item {
- display: flex;
- justify-content: space-between;
- align-items: center;
- padding: 10px 0;
- border-bottom: 1px solid rgba(0, 0, 0, 0.08);
- transition: background-color 0.2s ease;
- }
- .user-info-item:hover {
- background-color: rgba(0, 0, 0, 0.02);
- padding-left: 8px;
- padding-right: 8px;
- margin-left: -8px;
- margin-right: -8px;
- border-radius: 6px;
- }
- .user-info-item:last-child {
- border-bottom: none;
- }
- .info-label {
- font-size: 12px;
- color: #666;
- font-weight: 500;
- }
- .info-value {
- font-size: 12px;
- color: #333;
- max-width: 120px;
- overflow: hidden;
- text-overflow: ellipsis;
- white-space: nowrap;
- font-weight: 500;
- }
- /* 成功和错误消息样式 */
- .success-message, .error-message {
- position: fixed;
- top: 20px;
- left: 50%;
- transform: translateX(-50%);
- padding: 12px 24px;
- border-radius: 8px;
- font-weight: 500;
- z-index: 1000;
- animation: slideDown 0.3s ease-out;
- box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
- }
- .success-message {
- background: linear-gradient(135deg, #4caf50, #45a049);
- color: white;
- }
- .error-message {
- background: linear-gradient(135deg, #f44336, #d32f2f);
- color: white;
- }
- @keyframes slideDown {
- from {
- opacity: 0;
- transform: translateX(-50%) translateY(-20px);
- }
- to {
- opacity: 1;
- transform: translateX(-50%) translateY(0);
- }
- }
- .logout-btn {
- width: 100%;
- padding: 10px 16px;
- background: linear-gradient(135deg, #ff4757 0%, #ff3742 100%);
- color: white;
- border: none;
- border-radius: 8px;
- font-size: 14px;
- font-weight: 500;
- cursor: pointer;
- transition: all 0.3s ease;
- display: flex;
- align-items: center;
- justify-content: center;
- gap: 8px;
- }
- .logout-btn:hover {
- background: linear-gradient(135deg, #ff3742 0%, #ff2f3a 100%);
- transform: translateY(-1px);
- box-shadow: 0 4px 12px rgba(255, 71, 87, 0.3);
- }
- .logout-btn svg {
- transition: transform 0.3s ease;
- }
- .logout-btn:hover svg {
- transform: translateX(2px);
- }
- .btn {
- padding: 8px 16px;
- background-color: transparent;
- border: none;
- border-radius: var(--radius);
- font-weight: 500;
- font-size: 0.875rem;
- cursor: pointer;
- display: flex;
- align-items: center;
- justify-content: center;
- gap: 6px;
- transition: var(--transition);
- /* color: var(--gray-700); */
- background-color: rgba(255, 255, 255, 0.5);
- backdrop-filter: blur(var(--blur-sm));
- -webkit-backdrop-filter: blur(var(--blur-sm));
- box-shadow: var(--shadow-sm);
- }
- .btn:hover {
- background-color: rgba(255, 255, 255, 0.7);
- color: var(--gray-900);
- box-shadow: var(--shadow);
- transform: translateY(-1px);
- }
- .btn:active {
- transform: translateY(0);
- box-shadow: var(--shadow-sm);
- }
- .glass-btn {
- padding: 8px 16px;
- background-color: rgba(255, 255, 255, 0.3);
- border: var(--glass-border);
- color: var(--gray-700);
- box-shadow: var(--shadow-sm);
- transition: var(--transition);
- }
- .glass-btn:hover {
- background-color: rgba(255, 255, 255, 0.4);
- box-shadow: var(--shadow);
- color: var(--gray-900);
- }
- .glass-btn-primary {
- padding: 10px;
- background-color: var(--primary-indigo);
- border: none;
- color: white;
- border-radius: var(--radius-full);
- width: 40px;
- height: 40px;
- display: flex;
- align-items: center;
- justify-content: center;
- box-shadow: var(--shadow);
- transition: var(--transition);
- cursor: pointer;
- opacity: 1;
- position: relative;
- overflow: hidden;
- }
- .glass-btn-primary:hover {
- transform: translateY(-1px);
- box-shadow: var(--shadow-md);
- }
- .glass-btn-primary:active {
- transform: translateY(0);
- }
- .glass-btn svg, .glass-btn-primary svg {
- width: 16px;
- height: 16px;
- }
- .glass-btn:hover svg {
- transform: scale(1.05);
- }
- .glass-btn-primary:hover svg {
- transform: scale(1.1);
- }
- #reset-btn {
- color: var(--gray-700);
- display: flex;
- align-items: center;
- gap: 6px;
- font-size: 0.875rem;
- font-weight: 500;
- background-color: rgba(255, 255, 255, 0.4);
- box-shadow: var(--shadow-sm);
- }
- #reset-btn:hover {
- background-color: rgba(255, 255, 255, 0.6);
- color: var(--gray-900);
- box-shadow: var(--shadow);
- }
- #reset-btn.confirming {
- background-color: var(--danger-color);
- color: white;
- animation: pulse 2s infinite;
- }
- @keyframes pulse {
- 0% {
- box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.4);
- }
- 70% {
- box-shadow: 0 0 0 5px rgba(239, 68, 68, 0);
- }
- 100% {
- box-shadow: 0 0 0 0 rgba(239, 68, 68, 0);
- }
- }
- /* 智能体选择按钮样式 - 与重置按钮保持一致 */
- #agent-dropdown {
- color: var(--gray-700);
- display: flex;
- align-items: center;
- gap: 6px;
- font-size: 0.875rem;
- font-weight: 500;
- background-color: rgba(255, 255, 255, 0.4);
- box-shadow: var(--shadow-sm);
- cursor: pointer;
- border-radius: var(--radius);
- transition: var(--transition);
- position: relative;
- z-index: 1002;
- }
- #agent-dropdown:hover {
- background-color: rgba(255, 255, 255, 0.6);
- color: var(--gray-900);
- box-shadow: var(--shadow);
- }
- #agent-dropdown svg {
- transition: var(--transition);
- }
- #agent-dropdown:hover svg {
- transform: scale(1.05);
- }
- /* 智能体菜单样式 */
- #agent-menu {
- z-index: 1001 !important;
- position: absolute !important;
- top: calc(100% + 6px) !important;
- left: 0 !important;
- min-width: 220px !important;
- background: rgba(255, 255, 255, 0.95) !important;
- backdrop-filter: blur(20px) !important;
- -webkit-backdrop-filter: blur(20px) !important;
- border: 1px solid rgba(255, 255, 255, 0.3) !important;
- border-radius: 12px !important;
- box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15) !important;
- overflow: hidden !important;
- }
- #agent-menu ul {
- list-style: none !important;
- margin: 0 !important;
- padding: 8px !important;
- }
- .agent-option {
- display: flex !important;
- align-items: center !important;
- gap: 8px !important;
- padding: 12px !important;
- border-radius: 8px !important;
- cursor: pointer !important;
- transition: all 0.2s ease !important;
- background: transparent !important;
- border: 1px solid transparent !important;
- }
- .agent-option:hover {
- background: rgba(99, 102, 241, 0.1) !important;
- border-color: rgba(99, 102, 241, 0.2) !important;
- transform: translateY(-1px) !important;
- }
- .agent-option[data-active="true"] {
- background: rgba(99, 102, 241, 0.15) !important;
- border-color: rgba(99, 102, 241, 0.3) !important;
- box-shadow: 0 2px 8px rgba(99, 102, 241, 0.2) !important;
- }
- .chat-messages {
- flex: 1;
- min-height: 0; /* 确保能够收缩 */
- overflow-y: auto;
- padding: 30px;
- position: relative;
- display: flex;
- flex-direction: column;
- gap: 30px;
- background: rgba(255, 255, 255, 0.1);
- backdrop-filter: blur(var(--blur-sm));
- -webkit-backdrop-filter: blur(var(--blur-sm));
- scrollbar-width: thin;
- scrollbar-color: rgba(100, 116, 139, 0.5) transparent;
- }
- .chat-messages::before {
- content: '';
- position: absolute;
- top: 0;
- left: 0;
- width: 100%;
- height: 100%;
- background: linear-gradient(to bottom, rgba(255, 255, 255, 0.5), rgba(255, 255, 255, 0.02));
- opacity: 0.3;
- z-index: -1;
- pointer-events: none;
- }
- .chat-messages::-webkit-scrollbar {
- width: 8px;
- height: 8px;
- }
- .chat-messages::-webkit-scrollbar-track {
- background: transparent;
- }
- .chat-messages::-webkit-scrollbar-thumb {
- background-color: rgba(100, 116, 139, 0.5);
- border-radius: 20px;
- }
- .chat-messages::-webkit-scrollbar-thumb:hover {
- background-color: rgba(100, 116, 139, 0.7);
- }
- .message {
- padding: 15px 20px;
- border-radius: var(--radius);
- animation: fadeIn 0.3s ease-out forwards;
- word-break: break-word;
- position: relative;
- opacity: 0;
- transform: translateY(10px);
- transition: transform 0.3s ease, opacity 0.3s ease;
- }
- @keyframes fadeIn {
- to {
- opacity: 1;
- transform: translateY(0);
- }
- }
- .message.user {
- align-self: flex-end;
- background-color: rgba(59, 130, 246, 0.1);
- }
- .message.bot {
- align-self: flex-start;
- background-color: rgba(255, 255, 255, 0.15);
- width: 90%;
- max-width: 1200px;
- }
- .message-content {
- font-size: 1rem;
- line-height: 1.6;
- background: rgba(255, 255, 255, 0.8);
- padding: 20px 30px;
- border-radius: var(--radius);
- box-shadow: var(--shadow-sm);
- backdrop-filter: blur(var(--blur-sm));
- -webkit-backdrop-filter: blur(var(--blur-sm));
- }
- .message.bot .message-content {
- width: 100%;
- display: flex;
- flex-direction: column;
- padding: 24px;
- line-height: 1.7;
- font-size: 1.05rem;
- }
- .thought-container {
- width: 100%;
- margin: 10px 0 20px 0;
- background-color: rgba(121, 82, 179, 0.08);
- border-left: 3px solid #7952b3;
- padding: 14px 18px;
- border-radius: 0 8px 8px 0;
- font-style: italic;
- color: #6c757d;
- position: relative;
- box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
- transition: all 0.3s ease;
- }
- .thought-container[data-collapsed="true"] {
- padding-bottom: 10px;
- }
- .thought-container::before {
- content: "思考中...";
- display: inline-block;
- font-size: 0.9rem;
- color: #7952b3;
- font-weight: 600;
- margin-bottom: 8px;
- font-style: normal;
- letter-spacing: 0.03em;
- }
- .thought-container p {
- margin: 0 0 8px 0;
- padding: 0;
- line-height: 1.6;
- font-size: 0.95rem;
- white-space: normal;
- word-break: normal;
- word-wrap: break-word;
- overflow-wrap: break-word;
- text-align: left;
- width: 100%;
- transition: all 0.2s ease;
- display: block;
- }
- /* 最后一个段落不需要底部间距 */
- .thought-container p:last-child {
- margin-bottom: 0;
- }
- /* 确保段落内容按段落显示,不连续 */
- .thought-container p:not(:last-child) {
- margin-bottom: 8px;
- }
- /* 思考过程第一段的特殊样式 */
- .thought-container p:first-of-type {
- font-weight: normal;
- margin-top: 0;
- }
- /* 折叠/展开思考过程功能 */
- .thought-toggle {
- position: absolute;
- top: 12px;
- right: 12px;
- background: transparent;
- border: none;
- color: #7952b3;
- cursor: pointer;
- font-size: 1.2rem;
- opacity: 0.7;
- transition: opacity 0.2s;
- display: flex;
- align-items: center;
- justify-content: center;
- width: 24px;
- height: 24px;
- padding: 0;
- border-radius: 50%;
- }
- .thought-toggle:hover {
- opacity: 1;
- background-color: rgba(121, 82, 179, 0.1);
- }
- .chat-input-container {
- padding: 20px;
- display: flex;
- gap: 10px;
- align-items: flex-start; /* 改为顶部对齐,适应多行输入 */
- border-top: var(--glass-border);
- position: relative;
- z-index: 1;
- background: rgba(255, 255, 255, 0.15);
- backdrop-filter: blur(var(--blur-md));
- -webkit-backdrop-filter: blur(var(--blur-md));
- flex-shrink: 0; /* 防止输入框被压缩 */
- }
- .chat-input-container::before {
- content: '';
- position: absolute;
- top: 0;
- left: 0;
- width: 100%;
- height: 100%;
- background: linear-gradient(to right, rgba(99, 102, 241, 0.05), rgba(139, 92, 246, 0.05));
- opacity: 0.7;
- z-index: -1;
- border-radius: 0 0 var(--radius-lg) var(--radius-lg);
- }
- #user-input {
- flex: 1;
- padding: 12px 20px;
- border: var(--glass-border);
- border-radius: var(--radius);
- background-color: rgba(255, 255, 255, 0.8);
- font-size: 1rem;
- resize: none;
- min-height: 44px; /* 设置最小高度 */
- max-height: 200px;
- overflow-y: auto;
- line-height: 1.5;
- box-shadow: var(--shadow-inner);
- transition: var(--transition);
- font-family: inherit;
- }
- #user-input:focus {
- outline: none;
- border-color: rgba(99, 102, 241, 0.5);
- box-shadow: var(--shadow-glow-indigo);
- }
- .chat-input-container::before {
- content: '';
- position: absolute;
- top: 0;
- left: 0;
- width: 100%;
- height: 100%;
- background: linear-gradient(to right, rgba(99, 102, 241, 0.05), rgba(139, 92, 246, 0.05));
- opacity: 0.7;
- z-index: -1;
- border-radius: 0 0 var(--radius-lg) var(--radius-lg);
- }
- #send-btn {
- width: 40px;
- height: 40px;
- background-color: var(--primary-indigo);
- border: none;
- border-radius: var(--radius-full);
- display: flex;
- align-items: center;
- justify-content: center;
- cursor: pointer;
- box-shadow: var(--shadow);
- transition: var(--transition);
- color: white;
- padding: 0;
- overflow: hidden;
- }
- #send-btn:hover {
- transform: translateY(-2px) scale(1.03);
- box-shadow: var(--shadow-md);
- }
- #send-btn:active {
- transform: translateY(0) scale(0.98);
- }
- .typing-indicator {
- display: inline-flex;
- align-items: center;
- background-color: rgba(255, 255, 255, 0.5);
- padding: 8px 16px;
- border-radius: var(--radius-full);
- box-shadow: var(--shadow-sm);
- backdrop-filter: blur(var(--blur-sm));
- -webkit-backdrop-filter: blur(var(--blur-sm));
- margin: 0 auto;
- }
- .typing-indicator span {
- display: inline-block;
- width: 8px;
- height: 8px;
- background-color: var(--primary-indigo);
- border-radius: 50%;
- margin: 0 2px;
- animation: typing 1.4s infinite ease-in-out;
- }
- .typing-indicator span:nth-child(1) {
- animation-delay: 0s;
- }
- .typing-indicator span:nth-child(2) {
- animation-delay: 0.2s;
- }
- .typing-indicator span:nth-child(3) {
- animation-delay: 0.4s;
- }
- @keyframes typing {
- 0%, 80%, 100% {
- transform: scale(0.6);
- opacity: 0.6;
- }
- 40% {
- transform: scale(1);
- opacity: 1;
- }
- }
- /* 深色模式适配 - 自动跟随浏览器主题 */
- @media (prefers-color-scheme: dark) {
- :root {
- /* 深色模式下的颜色变量 */
- --glass-border: 1px solid rgba(255, 255, 255, 0.1);
- --glass-background: rgba(23, 25, 35, 0.3);
- --glass-background-dark: rgba(15, 23, 42, 0.6);
- --shadow-glow-indigo: 0 0 15px 2px rgba(99, 102, 241, 0.35);
- --shadow-glow-purple: 0 0 15px 2px rgba(139, 92, 246, 0.35);
-
- /* 深色模式下的文本颜色 */
- --text-primary: #e2e8f0;
- --text-secondary: #cbd5e1;
- --text-muted: #94a3b8;
- --text-inverse: #1e293b;
-
- /* 深色模式下的背景颜色 */
- --bg-primary: #0f172a;
- --bg-secondary: #1e293b;
- --bg-tertiary: #334155;
- --bg-glass: rgba(15, 23, 42, 0.8);
- }
-
- body {
- background: linear-gradient(135deg, #0f172a, #1e293b, #334155, #475569);
- color: var(--text-primary);
- transition: background 0.3s ease, color 0.3s ease;
- }
-
- body::before {
- opacity: 0.1;
- 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");
- }
-
- /* 主容器深色模式 */
- .chat-container {
- background-color: var(--bg-glass);
- border: var(--glass-border);
- backdrop-filter: blur(var(--blur-md));
- -webkit-backdrop-filter: blur(var(--blur-md));
- }
-
- /* 头部深色模式 */
- header {
- background-color: rgba(15, 23, 42, 0.8);
- border-bottom: var(--glass-border);
- backdrop-filter: blur(var(--blur-md));
- -webkit-backdrop-filter: blur(var(--blur-md));
- }
-
- header::before {
- background: linear-gradient(to right, rgba(99, 102, 241, 0.1), rgba(139, 92, 246, 0.1));
- opacity: 0.3;
- }
-
- header h1 {
- color: var(--text-primary);
- }
-
- /* 侧边栏深色模式 */
- .history-sidebar {
- background: rgba(15, 23, 42, 0.6);
- border-right: var(--glass-border);
- }
-
- .sidebar-header {
- background: rgba(15, 23, 42, 0.8);
- border-bottom: var(--glass-border);
- }
-
- .sidebar-title {
- color: var(--text-primary);
- }
-
- .new-chat-btn {
- background: rgba(30, 41, 59, 0.8);
- border: 1px solid rgba(255, 255, 255, 0.1);
- color: var(--text-secondary);
- box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
- }
-
- .new-chat-btn::before {
- background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.3), transparent);
- }
-
- .new-chat-btn:hover {
- background: rgba(51, 65, 85, 0.95);
- color: var(--text-primary);
- border-color: rgba(99, 102, 241, 0.4);
- box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(99, 102, 241, 0.2);
- }
-
- .new-chat-btn:hover svg {
- transform: scale(1.1) rotate(90deg);
- filter: drop-shadow(0 0 4px rgba(99, 102, 241, 0.5));
- }
-
- .conversation-item {
- background: transparent;
- border: 1px solid transparent;
- }
-
- .conversation-item::before {
- background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.15), transparent);
- }
-
- .conversation-item:hover {
- background: rgba(30, 41, 59, 0.6);
- border-color: rgba(255, 255, 255, 0.15);
- transform: translateX(4px);
- box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
- }
-
- .conversation-item.active {
- background: rgba(99, 102, 241, 0.25);
- border-color: rgba(99, 102, 241, 0.5);
- box-shadow: 0 6px 16px rgba(99, 102, 241, 0.4);
- transform: translateX(6px);
- }
-
- .conversation-item.active::before {
- background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.3), transparent);
- opacity: 1;
- }
-
- .conversation-title {
- color: var(--text-secondary);
- }
-
- .conversation-item.active .conversation-title {
- color: var(--primary-indigo);
- }
-
- .conversation-menu {
- color: var(--text-muted);
- }
-
- .conversation-menu::before {
- background: rgba(99, 102, 241, 0.15);
- }
-
- .conversation-item:hover .conversation-menu {
- background: rgba(30, 41, 59, 0.6);
- transform: scale(1.1);
- }
-
- .conversation-menu:hover {
- background: rgba(51, 65, 85, 0.8);
- color: var(--text-primary);
- transform: scale(1.2);
- }
-
- .conversation-menu:hover::before {
- background: rgba(99, 102, 241, 0.3);
- }
-
- .group-header {
- color: var(--text-muted);
- }
-
- .group-header::before {
- background: linear-gradient(to bottom, var(--primary-indigo), var(--primary-purple));
- opacity: 0.4;
- }
-
- .group-header:hover {
- color: var(--text-secondary);
- transform: translateX(4px);
- }
-
- .group-header:hover::before {
- opacity: 0.8;
- height: 16px;
- box-shadow: 0 0 8px rgba(99, 102, 241, 0.3);
- }
-
- .sidebar-footer {
- background: rgba(15, 23, 42, 0.4);
- border-top: var(--glass-border);
- }
-
- .user-profile {
- background: rgba(30, 41, 59, 0.6);
- border: 1px solid rgba(255, 255, 255, 0.1);
- }
-
- .user-profile:hover {
- background: rgba(51, 65, 85, 0.8);
- border-color: rgba(255, 255, 255, 0.2);
- }
-
- .user-name-sidebar {
- color: var(--text-primary);
- }
-
- /* 聊天消息区域深色模式 */
- .chat-messages {
- background: rgba(15, 23, 42, 0.3);
- }
-
- .chat-messages::before {
- background: linear-gradient(to bottom, rgba(30, 41, 59, 0.3), rgba(15, 23, 42, 0.5));
- opacity: 0.4;
- }
-
- /* 消息样式深色模式 */
- .message.user {
- background-color: rgba(99, 102, 241, 0.2);
- }
-
- .message.bot {
- background-color: rgba(30, 41, 59, 0.3);
- }
-
- .message-content {
- background: rgba(30, 41, 59, 0.8);
- color: var(--text-primary);
- border: 1px solid rgba(255, 255, 255, 0.1);
- box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
- }
-
- .message.bot .message-content {
- background: rgba(30, 41, 59, 0.9);
- color: var(--text-primary);
- }
-
- /* 思考过程深色模式 */
- .thought-container {
- background-color: rgba(121, 82, 179, 0.15);
- border-left-color: #9370db;
- color: var(--text-secondary);
- }
-
- .thought-container::before {
- color: #a98eda;
- }
-
- /* 按钮深色模式 */
- .btn, #reset-btn, #toggle-streaming-btn {
- background-color: rgba(30, 41, 59, 0.8);
- color: var(--text-secondary);
- border: 1px solid rgba(255, 255, 255, 0.1);
- }
-
- .btn:hover, #reset-btn:hover, #toggle-streaming-btn:hover {
- background-color: rgba(51, 65, 85, 0.9);
- color: var(--text-primary);
- }
-
- .glass-btn {
- background-color: rgba(30, 41, 59, 0.6);
- border: var(--glass-border);
- color: var(--text-secondary);
- }
-
- .glass-btn:hover {
- background-color: rgba(51, 65, 85, 0.8);
- color: var(--text-primary);
- }
-
- /* 智能体菜单深色模式 */
- .agent-switcher {
- background: rgba(15, 23, 42, 0.8);
- border: var(--glass-border);
- }
-
- .agent-switcher-header h3 {
- color: var(--text-primary);
- }
-
- .agent-label {
- color: var(--text-muted);
- }
-
- .agent-item {
- background: rgba(30, 41, 59, 0.6);
- border: 1px solid transparent;
- }
-
- .agent-item:hover {
- background: rgba(51, 65, 85, 0.8);
- border-color: rgba(99, 102, 241, 0.3);
- }
-
- .agent-item.active {
- background: rgba(99, 102, 241, 0.2) !important;
- border-color: rgba(99, 102, 241, 0.4) !important;
- }
-
- .agent-title {
- color: var(--text-primary);
- }
-
- .agent-item.active .agent-title {
- color: var(--primary-indigo) !important;
- }
-
- /* 输入区域深色模式 */
- .chat-input-container {
- background: rgba(15, 23, 42, 0.8);
- border-top: var(--glass-border);
- }
-
- .chat-input-container::before {
- background: linear-gradient(to right, rgba(99, 102, 241, 0.1), rgba(139, 92, 246, 0.1));
- opacity: 0.4;
- }
-
- #user-input {
- background-color: rgba(30, 41, 59, 0.8);
- color: var(--text-primary);
- border: 1px solid rgba(255, 255, 255, 0.1);
- }
-
- #user-input:focus {
- border-color: rgba(99, 102, 241, 0.5);
- background-color: rgba(30, 41, 59, 0.9);
- }
-
- #user-input::placeholder {
- color: var(--text-muted);
- }
-
- /* 用户信息深色模式 */
- .user-info {
- background: rgba(30, 41, 59, 0.8);
- border: 1px solid rgba(255, 255, 255, 0.1);
- }
-
- .user-info:hover {
- background: rgba(51, 65, 85, 0.9);
- border-color: rgba(255, 255, 255, 0.2);
- }
-
- .user-name {
- color: var(--text-primary);
- }
-
- .user-type {
- color: var(--text-muted);
- background: rgba(51, 65, 85, 0.6);
- }
-
- .user-title {
- color: var(--text-muted);
- }
-
- .user-dropdown {
- background: rgba(15, 23, 42, 0.95);
- border: 1px solid rgba(255, 255, 255, 0.1);
- }
-
- .user-dropdown::before {
- background: rgba(15, 23, 42, 0.95);
- border: 1px solid rgba(255, 255, 255, 0.1);
- }
-
- .info-label {
- color: var(--text-muted);
- }
-
- .info-value {
- color: var(--text-secondary);
- }
-
- /* 通知消息深色模式 */
- .typing-indicator, .loading-animation {
- background-color: rgba(30, 41, 59, 0.8);
- border: 1px solid rgba(255, 255, 255, 0.1);
- }
-
- .loading-text {
- color: var(--text-secondary);
- }
-
- .status-badge {
- background-color: rgba(30, 41, 59, 0.9);
- }
-
- .ripple {
- background-color: rgba(255, 255, 255, 0.1);
- }
-
- /* 智能体切换通知深色模式 */
- .agent-switch-notification .notification-content {
- background: rgba(15, 23, 42, 0.95);
- border: 1px solid rgba(99, 102, 241, 0.3);
- }
-
- .notification-text {
- color: var(--text-primary);
- }
-
- /* 上下文菜单深色模式 */
- .conversation-context-menu {
- background: rgba(15, 23, 42, 0.95);
- border: 1px solid rgba(255, 255, 255, 0.1);
- }
-
- .menu-item {
- color: var(--text-secondary);
- }
-
- .menu-item:hover {
- background: rgba(99, 102, 241, 0.2);
- color: var(--primary-indigo);
- }
-
- /* 智能体菜单深色模式 */
- #agent-menu {
- background: rgba(15, 23, 42, 0.95) !important;
- border: 1px solid rgba(255, 255, 255, 0.1) !important;
- }
-
- .agent-option {
- background: rgba(30, 41, 59, 0.6) !important;
- border: 1px solid rgba(255, 255, 255, 0.1) !important;
- color: var(--text-secondary) !important;
- }
-
- .agent-option:hover {
- background: rgba(99, 102, 241, 0.2) !important;
- border-color: rgba(99, 102, 241, 0.3) !important;
- color: var(--primary-indigo) !important;
- }
-
- .agent-option[data-active="true"] {
- background: rgba(99, 102, 241, 0.3) !important;
- border-color: rgba(99, 102, 241, 0.5) !important;
- color: var(--primary-indigo) !important;
- }
-
- /* Markdown内容深色模式 */
- .bot .message-content blockquote {
- border-left-color: rgba(99, 102, 241, 0.5);
- background-color: rgba(30, 58, 138, 0.3);
- color: var(--text-secondary);
- }
-
- .bot .message-content code {
- background-color: rgba(30, 58, 138, 0.3);
- color: var(--text-secondary);
- }
-
- .bot .message-content pre {
- background-color: rgba(15, 23, 42, 0.8);
- border: 1px solid rgba(255, 255, 255, 0.1);
- }
-
- .bot .message-content h1,
- .bot .message-content h2,
- .bot .message-content h3,
- .bot .message-content h4,
- .bot .message-content h5,
- .bot .message-content h6 {
- color: var(--text-primary);
- }
-
- .bot .message-content table {
- background-color: rgba(30, 41, 59, 0.5);
- }
-
- .bot .message-content table th,
- .bot .message-content table td {
- border-color: rgba(255, 255, 255, 0.1);
- }
-
- .bot .message-content table th {
- background-color: rgba(51, 65, 85, 0.7);
- color: var(--text-primary);
- }
-
- .bot .message-content table td {
- color: var(--text-secondary);
- }
-
- /* 滚动条深色模式 */
- .chat-messages::-webkit-scrollbar-thumb {
- background-color: rgba(100, 116, 139, 0.6);
- }
-
- .chat-messages::-webkit-scrollbar-thumb:hover {
- background-color: rgba(100, 116, 139, 0.8);
- }
-
- .history-content::-webkit-scrollbar-thumb {
- background-color: rgba(100, 116, 139, 0.4);
- }
-
- .history-content::-webkit-scrollbar-thumb:hover {
- background-color: rgba(100, 116, 139, 0.6);
- }
-
- /* 移动端侧边栏切换按钮深色模式 */
- .sidebar-toggle {
- background: var(--primary-indigo);
- box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
- }
-
- .sidebar-toggle::before {
- background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
- }
-
- .sidebar-toggle:hover {
- box-shadow: 0 12px 35px rgba(99, 102, 241, 0.4);
- }
- }
- /* 响应式布局 */
- @media (max-width: 768px) {
- .chat-container {
- height: calc(100vh - 20px);
- max-height: none;
- border-radius: var(--radius);
- margin: 10px;
- flex-direction: column;
- }
- /* 移动端侧边栏样式 */
- .history-sidebar {
- position: fixed;
- left: -280px;
- top: 0;
- width: 280px;
- height: 100vh;
- z-index: 1000;
- transition: transform 0.3s ease;
- border-right: none;
- border-radius: 0;
- }
- .history-sidebar.show {
- transform: translateX(280px);
- }
- /* 移动端主聊天区域 */
- .main-chat-area {
- width: 100%;
- height: 100%;
- }
- /* 移动端侧边栏切换按钮 */
- .sidebar-toggle {
- position: fixed;
- left: 20px;
- top: 20px;
- z-index: 1001;
- width: 44px;
- height: 44px;
- background: var(--primary-indigo);
- border: none;
- border-radius: 50%;
- color: white;
- font-size: 1.2rem;
- box-shadow: var(--shadow-lg);
- cursor: pointer;
- transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
- display: flex;
- align-items: center;
- justify-content: center;
- position: relative;
- overflow: hidden;
- }
- .sidebar-toggle::before {
- content: '';
- position: absolute;
- top: 0;
- left: -100%;
- width: 100%;
- height: 100%;
- background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
- transition: left 0.5s ease;
- }
- .sidebar-toggle:hover {
- transform: scale(1.1);
- box-shadow: var(--shadow-glow-indigo);
- }
- .sidebar-toggle:hover::before {
- left: 100%;
- }
- .sidebar-toggle:active {
- transform: scale(0.95);
- }
- /* 移动端侧边栏遮罩层 */
- .sidebar-overlay {
- position: fixed;
- top: 0;
- left: 0;
- width: 100%;
- height: 100%;
- background: rgba(0, 0, 0, 0.5);
- backdrop-filter: blur(4px);
- -webkit-backdrop-filter: blur(4px);
- z-index: 999;
- opacity: 0;
- visibility: hidden;
- transition: all 0.3s ease;
- }
- .sidebar-overlay.show {
- opacity: 1;
- visibility: visible;
- }
-
- header,
- .glass-header,
- header::before {
- border-radius: var(--radius) var(--radius) 0 0;
- padding: 12px 16px;
- flex-direction: column;
- gap: 12px;
- align-items: stretch;
- }
-
- /* 头部第一行:图标、应用文案和版本号 */
- .logo-title-container {
- display: flex;
- align-items: center;
- justify-content: center;
- gap: 8px;
- order: 1;
- }
- .logo-title-link{
- display: none;
- }
-
- .header-logo {
- width: 32px;
- height: 32px;
- }
-
- header h1 {
- font-size: 1.1rem;
- margin: 0;
- text-align: center;
- }
-
- .version-tag {
- font-size: 0.65rem;
- padding: 1px 6px;
- }
-
- /* 头部第二行:智能体切换和重置按钮 */
- .buttons-container {
- display: flex;
- gap: 8px;
- align-items: center;
- justify-content: center;
- order: 2;
- flex-wrap: wrap;
- }
-
- /* 智能体下拉菜单移动端优化 */
- #agent-dropdown {
- flex: 1;
- min-width: 120px;
- justify-content: center;
- padding: 8px 12px;
- font-size: 0.8rem;
- }
-
- #agent-dropdown span {
- font-size: 0.8rem;
- }
-
- /* 重置按钮移动端优化 */
- #reset-btn {
- flex: 1;
- min-width: 120px;
- justify-content: center;
- padding: 8px 12px;
- font-size: 0.8rem;
- }
-
- #reset-btn svg {
- width: 14px;
- height: 14px;
- }
-
- /* 用户信息移动端优化 - 保持左右布局,上下排版 */
- .user-info {
- order: 3;
- flex-direction: row;
- align-items: center;
- gap: 12px;
- padding: 12px 16px;
- margin-top: 8px;
- width: 100%;
- max-width: 280px;
- margin-left: auto;
- margin-right: auto;
- }
-
- .user-details {
- flex-direction: row;
- align-items: center;
- gap: 12px;
- text-align: left;
- flex: 1;
- }
-
- .user-avatar {
- width: 44px;
- height: 44px;
- flex-shrink: 0;
- }
-
- .user-text {
- display: flex;
- flex-direction: column;
- align-items: flex-start;
- gap: 3px;
- flex: 1;
- min-width: 0;
- }
-
- .user-info-row {
- display: flex;
- align-items: center;
- gap: 8px;
- width: 100%;
- }
-
- .user-name {
- font-size: 0.9rem;
- font-weight: 600;
- white-space: nowrap;
- }
-
- .user-type {
- font-size: 0.75rem;
- padding: 1px 5px;
- white-space: nowrap;
- }
-
- .user-title {
- font-size: 0.8rem;
- max-width: none;
- width: 100%;
- }
-
- /* 移动端用户下拉菜单优化 */
- .user-dropdown {
- position: fixed;
- top: 50%;
- left: 50%;
- transform: translate(-50%, -50%) scale(0.95);
- right: auto;
- width: 90%;
- max-width: 300px;
- opacity: 0;
- visibility: hidden;
- transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
- }
-
- .user-info:hover .user-dropdown {
- opacity: 1;
- visibility: visible;
- transform: translate(-50%, -50%) scale(1);
- }
-
- .user-dropdown::before {
- display: none;
- }
-
- .user-type {
- font-size: 0.75rem;
- padding: 2px 8px;
- }
-
- .user-title {
- font-size: 0.75rem;
- opacity: 0.8;
- }
-
- /* 智能体菜单移动端优化 */
- #agent-menu {
- position: fixed !important;
- top: 50% !important;
- left: 50% !important;
- transform: translate(-50%, -50%) !important;
- width: 280px !important;
- max-width: 90vw !important;
- z-index: 1002 !important;
- background: rgba(255, 255, 255, 0.95) !important;
- backdrop-filter: blur(20px) !important;
- border: 1px solid rgba(255, 255, 255, 0.3) !important;
- box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2) !important;
- }
-
- #agent-menu ul {
- padding: 16px !important;
- }
-
- .agent-option {
- padding: 16px !important;
- margin-bottom: 8px !important;
- border-radius: 12px !important;
- background: rgba(255, 255, 255, 0.8) !important;
- border: 1px solid rgba(255, 255, 255, 0.3) !important;
- transition: all 0.2s ease !important;
- }
-
- .agent-option:hover {
- background: rgba(99, 102, 241, 0.1) !important;
- border-color: rgba(99, 102, 241, 0.3) !important;
- transform: translateY(-2px) !important;
- }
-
- .agent-option[data-active="true"] {
- background: rgba(99, 102, 241, 0.15) !important;
- border-color: rgba(99, 102, 241, 0.4) !important;
- box-shadow: 0 4px 12px rgba(99, 102, 241, 0.2) !important;
- }
-
- /* 聊天内容区域移动端优化 */
- .chat-main-content {
- flex: 1;
- display: flex;
- flex-direction: column;
- min-height: 0;
- background: rgba(255, 255, 255, 0.02);
- }
-
- .chat-messages {
- padding: 16px;
- gap: 20px;
- flex: 1;
- min-height: 0;
- overflow-y: auto;
- -webkit-overflow-scrolling: touch;
- }
-
- .chat-messages::-webkit-scrollbar {
- width: 6px;
- }
-
- .chat-messages::-webkit-scrollbar-track {
- background: transparent;
- }
-
- .chat-messages::-webkit-scrollbar-thumb {
- background: rgba(255, 255, 255, 0.2);
- border-radius: 3px;
- }
-
- .chat-messages::-webkit-scrollbar-thumb:hover {
- background: rgba(255, 255, 255, 0.3);
- }
-
- .message {
- border-radius: 16px;
- margin-bottom: 16px;
- box-shadow: var(--shadow-sm);
- transition: all 0.2s ease;
- }
-
- .message:hover {
- transform: translateY(-1px);
- box-shadow: var(--shadow);
- }
-
- .message-content {
- padding: 16px;
- font-size: 0.9rem;
- line-height: 1.6;
- border-radius: 16px;
- }
-
- .message.bot {
- width: 100%;
- max-width: 100%;
- margin-right: 0;
- }
-
- .message.bot .message-content {
- padding: 16px;
- background: rgba(255, 255, 255, 0.15);
- border: 1px solid rgba(255, 255, 255, 0.1);
- }
-
- .message.user {
- align-self: flex-end;
- margin-left: 20px;
- }
-
- .message.user .message-content {
- background: rgba(99, 102, 241, 0.15);
- border: 1px solid rgba(99, 102, 241, 0.2);
- color: var(--gray-800);
- }
-
- .thought-container {
- margin: 12px 0 20px 0;
- padding: 12px 16px;
- border-radius: 12px;
- background: rgba(99, 102, 241, 0.08);
- border-left: 3px solid var(--primary-indigo);
- }
-
- /* 输入区域移动端优化 */
- .chat-input-container {
- padding: 16px;
- border-top: 1px solid rgba(255, 255, 255, 0.1);
- background: rgba(255, 255, 255, 0.05);
- position: relative;
- }
-
- .chat-input-container::before {
- content: '';
- position: absolute;
- top: 0;
- left: 0;
- width: 100%;
- height: 100%;
- background: linear-gradient(to bottom, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.02));
- opacity: 0.3;
- z-index: -1;
- pointer-events: none;
- border-radius: 0 0 var(--radius) var(--radius);
- }
-
- #user-input {
- padding: 12px 16px;
- font-size: 0.9rem;
- min-height: 44px;
- max-height: 120px;
- resize: none;
- border-radius: 12px;
- border: 1px solid rgba(255, 255, 255, 0.2);
- background: rgba(255, 255, 255, 0.1);
- color: var(--gray-800);
- transition: all 0.2s ease;
- }
-
- #user-input:focus {
- outline: none;
- border-color: var(--primary-indigo);
- background: rgba(255, 255, 255, 0.15);
- box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
- }
-
- #send-btn {
- width: 44px;
- height: 44px;
- min-width: 44px;
- border-radius: 12px;
- background: var(--primary-indigo);
- border: none;
- color: white;
- transition: all 0.2s ease;
- box-shadow: var(--shadow-sm);
- }
-
- #send-btn:hover {
- background: var(--primary-purple);
- transform: translateY(-1px);
- box-shadow: var(--shadow);
- }
-
- #send-btn:active {
- transform: translateY(0);
- box-shadow: var(--shadow-sm);
- }
-
- #send-btn svg {
- width: 18px;
- height: 18px;
- }
-
- /* 移动端智能体切换菜单栏适配 */
- .agent-switcher-container {
- position: fixed;
- left: 0;
- top: 0;
- width: 100%;
- height: 100%;
- z-index: 1000;
- background: rgba(0, 0, 0, 0.5);
- opacity: 0;
- visibility: hidden;
- transition: all 0.3s ease;
- }
- .agent-switcher-container.show {
- opacity: 1;
- visibility: visible;
- }
- .agent-switcher {
- position: absolute;
- left: 0;
- top: 0;
- width: 280px;
- height: 100%;
- border-radius: 0;
- transform: translateX(-100%);
- transition: transform 0.3s ease;
- overflow-y: auto;
- }
- .agent-switcher-container.show .agent-switcher {
- transform: translateX(0);
- }
- /* 移动端平台项样式优化 */
- .agent-item {
- padding: 20px 24px;
- margin: 0 16px 16px 16px;
- border-radius: var(--radius-lg);
- }
- .agent-icon {
- width: 60px;
- height: 60px;
- }
- .platform-icon {
- width: 40px;
- height: 40px;
- filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.1));
- }
- .agent-title {
- font-size: 1.2rem;
- }
- /* 添加移动端菜单切换按钮 */
- .mobile-menu-toggle {
- display: block;
- position: fixed;
- left: 20px;
- top: 100px;
- z-index: 999;
- width: 50px;
- height: 50px;
- background: var(--primary-indigo);
- border: none;
- border-radius: 50%;
- color: white;
- font-size: 1.2rem;
- box-shadow: var(--shadow-lg);
- cursor: pointer;
- transition: var(--transition);
- }
- .mobile-menu-toggle:hover {
- transform: scale(1.1);
- box-shadow: var(--shadow-glow-indigo);
- }
-
- /* 移动端智能体切换通知优化 */
- .agent-switch-notification {
- top: 20px;
- right: 20px;
- left: 20px;
- transform: translateY(-100px);
- }
-
- .agent-switch-notification.show {
- transform: translateY(0);
- }
-
- .notification-content {
- padding: 12px 16px;
- min-width: auto;
- width: 100%;
- }
-
- .notification-text {
- font-size: 0.85rem;
- }
- }
- /* 改进markdown内容的渲染样式 */
- .markdown-content {
- width: 100%;
- }
- .markdown-content p {
- margin-bottom: 1em;
- }
- .markdown-content h1,
- .markdown-content h2,
- .markdown-content h3,
- .markdown-content h4 {
- margin-top: 1.2em;
- margin-bottom: 0.8em;
- font-weight: 600;
- line-height: 1.3;
- }
- .markdown-content h1 {
- font-size: 1.7em;
- }
- .markdown-content h2 {
- font-size: 1.5em;
- }
- .markdown-content h3 {
- font-size: 1.3em;
- }
- .markdown-content ul,
- .markdown-content ol {
- margin-bottom: 1em;
- padding-left: 1.5em;
- }
- .markdown-content li {
- margin-bottom: 0.5em;
- }
- .markdown-content pre {
- margin-bottom: 1.2em;
- border-radius: 6px;
- }
- /* 智能体切换通知样式 */
- .agent-switch-notification {
- position: fixed;
- top: 100px;
- right: 30px;
- z-index: 1003;
- transform: translateX(400px);
- transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
- }
- .agent-switch-notification.show {
- transform: translateX(0);
- }
- .notification-content {
- display: flex;
- align-items: center;
- gap: 12px;
- padding: 16px 20px;
- background: rgba(255, 255, 255, 0.95);
- backdrop-filter: blur(var(--blur-md));
- -webkit-backdrop-filter: blur(var(--blur-md));
- border: 1px solid rgba(99, 102, 241, 0.2);
- border-radius: var(--radius-lg);
- box-shadow: var(--shadow-lg);
- min-width: 200px;
- }
- .notification-icon {
- font-size: 1.2rem;
- animation: bounce 0.6s ease-in-out;
- }
- .notification-text {
- font-weight: 500;
- color: var(--gray-800);
- font-size: 0.95rem;
- }
- /* 平台特定通知样式 */
- .agent-switch-notification[data-platform="kuaishou"] .notification-content {
- border-color: rgba(255, 69, 0, 0.3);
- background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(255, 69, 0, 0.05));
- }
- .agent-switch-notification[data-platform="toutiao"] .notification-content {
- border-color: rgba(0, 123, 255, 0.3);
- background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(0, 123, 255, 0.05));
- }
- .agent-switch-notification[data-platform="videoaccount"] .notification-content {
- border-color: rgba(40, 167, 69, 0.3);
- background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(40, 167, 69, 0.05));
- }
- @keyframes bounce {
- 0%, 20%, 50%, 80%, 100% {
- transform: translateY(0);
- }
- 40% {
- transform: translateY(-8px);
- }
- 60% {
- transform: translateY(-4px);
- }
- }
- /* 移动端智能体菜单遮罩层样式 */
- .mobile-agent-overlay {
- position: fixed;
- top: 0;
- left: 0;
- width: 100%;
- height: 100%;
- background: rgba(0, 0, 0, 0.5);
- backdrop-filter: blur(4px);
- -webkit-backdrop-filter: blur(4px);
- z-index: 1001;
- opacity: 0;
- transition: opacity 0.3s ease;
- }
- .mobile-agent-overlay.show {
- opacity: 1;
- }
- /* 移动端智能体菜单动画 */
- @media (max-width: 768px) {
- #agent-menu {
- opacity: 0;
- transform: translate(-50%, -50%) scale(0.9) !important;
- transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
- }
-
- #agent-menu.show {
- opacity: 1;
- transform: translate(-50%, -50%) scale(1) !important;
- }
- }
- /* 移动端触摸优化 */
- .glass-btn,
- #agent-dropdown,
- #reset-btn,
- #send-btn {
- -webkit-tap-highlight-color: transparent;
- touch-action: manipulation;
- user-select: none;
- }
- .glass-btn:active,
- #agent-dropdown:active,
- #reset-btn:active,
- #send-btn:active {
- transform: scale(0.95);
- transition: transform 0.1s ease;
- }
- /* 移动端智能体选项触摸优化 */
- .agent-option {
- -webkit-tap-highlight-color: transparent;
- touch-action: manipulation;
- user-select: none;
- }
- .agent-option:active {
- transform: scale(0.98);
- transition: transform 0.1s ease;
- }
- /* 移动端用户信息触摸优化 */
- .user-info {
- -webkit-tap-highlight-color: transparent;
- touch-action: manipulation;
- }
- .user-info:active {
- transform: scale(0.98);
- transition: transform 0.1s ease;
- }
- /* 移动端输入框触摸优化 */
- #user-input {
- -webkit-tap-highlight-color: transparent;
- touch-action: manipulation;
- }
- /* 历史记录加载动画和空状态样式 */
- .history-loading, .history-empty {
- display: flex;
- flex-direction: column;
- align-items: center;
- justify-content: center;
- padding: 20px;
- color: var(--gray-500);
- font-size: 14px;
- text-align: center;
- gap: 10px;
- height: 100%;
- }
- .history-loading .loading-spinner {
- border: 4px solid rgba(99, 102, 241, 0.2);
- border-top: 4px solid var(--primary-indigo);
- border-radius: 50%;
- width: 30px;
- height: 30px;
- animation: spin 1s linear infinite;
- }
- @keyframes spin {
- 0% { transform: rotate(0deg); }
- 100% { transform: rotate(360deg); }
- }
- .history-empty svg {
- color: var(--gray-400);
- width: 48px;
- height: 48px;
- }
- .history-empty p {
- margin: 0;
- font-weight: 500;
- }
- .history-empty .new-chat-btn {
- margin-top: 15px;
- }
|