styles.css 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644
  1. :root {
  2. color-scheme: light;
  3. font-family: "Microsoft YaHei", "PingFang SC", "Segoe UI", Arial, sans-serif;
  4. --paper: #f4f0e7;
  5. --paper-deep: #e9e2d5;
  6. --paper-soft: rgba(255, 252, 244, 0.72);
  7. --ink: #20231f;
  8. --muted: #686d61;
  9. --line: rgba(82, 83, 72, 0.2);
  10. --line-strong: rgba(70, 77, 63, 0.34);
  11. --moss: #6c7666;
  12. --moss-deep: #3f4d3f;
  13. --clay: #8b7762;
  14. --ash: #d8d2c5;
  15. --charcoal: #2f302c;
  16. --danger: #8c3b32;
  17. --warning: #a27b3f;
  18. --shadow: 0 8px 18px rgba(38, 35, 28, 0.06);
  19. }
  20. * {
  21. box-sizing: border-box;
  22. }
  23. html {
  24. min-height: 100%;
  25. }
  26. body {
  27. margin: 0;
  28. min-height: 100vh;
  29. color: var(--ink);
  30. background:
  31. linear-gradient(90deg, rgba(76, 87, 69, 0.04) 1px, transparent 1px),
  32. linear-gradient(rgba(76, 87, 69, 0.035) 1px, transparent 1px),
  33. linear-gradient(135deg, #f7f3eb 0%, #ece6d9 52%, #f3eee4 100%);
  34. background-size: 44px 44px, 44px 44px, 100% 100%;
  35. overflow-x: hidden;
  36. }
  37. body::before {
  38. content: "";
  39. position: fixed;
  40. inset: 0;
  41. pointer-events: none;
  42. z-index: 0;
  43. background:
  44. repeating-linear-gradient(11deg, rgba(72, 68, 58, 0.025) 0 1px, transparent 1px 7px),
  45. repeating-linear-gradient(96deg, rgba(255, 255, 255, 0.18) 0 1px, transparent 1px 9px);
  46. opacity: 0.7;
  47. }
  48. button,
  49. textarea {
  50. font: inherit;
  51. }
  52. button {
  53. transition: background-color 220ms ease, border-color 220ms ease, color 220ms ease, opacity 220ms ease;
  54. }
  55. button:hover,
  56. button:focus-visible {
  57. border-color: var(--moss-deep);
  58. outline: none;
  59. }
  60. .paper-grain {
  61. position: fixed;
  62. inset: 0;
  63. z-index: 0;
  64. pointer-events: none;
  65. background-image:
  66. radial-gradient(circle at 12% 18%, rgba(61, 64, 55, 0.035) 0 1px, transparent 1px),
  67. radial-gradient(circle at 74% 28%, rgba(61, 64, 55, 0.028) 0 1px, transparent 1px),
  68. radial-gradient(circle at 42% 80%, rgba(61, 64, 55, 0.026) 0 1px, transparent 1px);
  69. background-size: 28px 31px, 39px 43px, 47px 53px;
  70. mix-blend-mode: multiply;
  71. }
  72. .top-nav {
  73. position: sticky;
  74. top: 0;
  75. z-index: 20;
  76. min-height: 74px;
  77. padding: 14px 28px;
  78. display: grid;
  79. grid-template-columns: minmax(230px, auto) 1fr minmax(210px, auto);
  80. align-items: center;
  81. gap: 22px;
  82. border-bottom: 1px solid var(--line);
  83. background: rgba(246, 241, 231, 0.9);
  84. backdrop-filter: blur(10px);
  85. }
  86. .brand {
  87. display: flex;
  88. gap: 13px;
  89. align-items: center;
  90. min-width: 0;
  91. }
  92. .brand img {
  93. width: 42px;
  94. height: 42px;
  95. border-radius: 6px;
  96. object-fit: cover;
  97. border: 1px solid rgba(58, 63, 53, 0.18);
  98. filter: saturate(0.72) contrast(0.96);
  99. }
  100. .brand strong {
  101. display: block;
  102. font-size: 18px;
  103. line-height: 1.2;
  104. font-weight: 700;
  105. letter-spacing: 0;
  106. }
  107. .session-card span {
  108. display: block;
  109. margin-top: 4px;
  110. color: var(--muted);
  111. font-size: 12px;
  112. font-weight: 500;
  113. letter-spacing: 0;
  114. }
  115. .nav {
  116. display: flex;
  117. justify-content: center;
  118. gap: 10px;
  119. }
  120. .nav-item {
  121. min-width: 68px;
  122. border: 1px solid transparent;
  123. border-radius: 999px;
  124. padding: 8px 17px;
  125. color: var(--charcoal);
  126. background: transparent;
  127. text-align: center;
  128. cursor: pointer;
  129. font-weight: 600;
  130. }
  131. .nav-item.active {
  132. border-color: var(--line-strong);
  133. background: rgba(255, 252, 244, 0.58);
  134. }
  135. .nav-item:hover {
  136. background: rgba(255, 252, 244, 0.72);
  137. }
  138. .session-card {
  139. justify-self: end;
  140. min-width: 210px;
  141. padding: 10px 12px;
  142. border: 1px solid var(--line);
  143. border-radius: 8px;
  144. display: flex;
  145. align-items: center;
  146. gap: 10px;
  147. background: rgba(255, 252, 244, 0.58);
  148. }
  149. .session-card strong {
  150. font-size: 15px;
  151. font-weight: 700;
  152. }
  153. .status-dot {
  154. width: 10px;
  155. height: 10px;
  156. border-radius: 999px;
  157. background: var(--warning);
  158. flex: 0 0 auto;
  159. box-shadow: 0 0 0 4px rgba(162, 123, 63, 0.1);
  160. }
  161. .status-dot.ok {
  162. background: var(--moss);
  163. box-shadow: 0 0 0 4px rgba(108, 118, 102, 0.12);
  164. }
  165. .status-dot.error {
  166. background: var(--danger);
  167. box-shadow: 0 0 0 4px rgba(140, 59, 50, 0.12);
  168. }
  169. .shell {
  170. position: relative;
  171. z-index: 1;
  172. width: min(1460px, calc(100% - 48px));
  173. margin: 0 auto;
  174. padding: 24px 0 32px;
  175. }
  176. .chat-card,
  177. .panel {
  178. border: 1px solid var(--line);
  179. background: var(--paper-soft);
  180. box-shadow: var(--shadow);
  181. }
  182. .workspace {
  183. display: grid;
  184. grid-template-columns: minmax(620px, 1fr) 360px;
  185. gap: 16px;
  186. align-items: stretch;
  187. }
  188. .chat-card,
  189. .panel {
  190. border-radius: 8px;
  191. }
  192. .chat-card {
  193. min-height: calc(100vh - 366px);
  194. display: grid;
  195. grid-template-rows: auto minmax(360px, 1fr) auto;
  196. overflow: hidden;
  197. }
  198. .window-bar {
  199. min-height: 46px;
  200. padding: 0 18px;
  201. display: flex;
  202. align-items: center;
  203. gap: 10px;
  204. border-bottom: 1px solid var(--line);
  205. background: rgba(236, 230, 217, 0.64);
  206. }
  207. .window-bar span {
  208. width: 12px;
  209. height: 12px;
  210. border-radius: 2px;
  211. border: 1px solid rgba(139, 119, 98, 0.55);
  212. background: rgba(139, 119, 98, 0.16);
  213. transform: rotate(4deg);
  214. }
  215. .messages {
  216. padding: 22px;
  217. overflow: auto;
  218. scroll-behavior: smooth;
  219. }
  220. .message-row {
  221. display: grid;
  222. grid-template-columns: 38px minmax(0, 1fr);
  223. gap: 12px;
  224. margin-bottom: 18px;
  225. }
  226. .message-row.user {
  227. grid-template-columns: minmax(0, 1fr) 38px;
  228. }
  229. .avatar {
  230. width: 38px;
  231. height: 38px;
  232. border-radius: 7px;
  233. background: rgba(255, 252, 244, 0.62);
  234. color: var(--moss-deep);
  235. display: grid;
  236. place-items: center;
  237. font-size: 14px;
  238. font-weight: 700;
  239. overflow: hidden;
  240. border: 1px solid var(--line);
  241. }
  242. .avatar img {
  243. width: 100%;
  244. height: 100%;
  245. object-fit: cover;
  246. filter: saturate(0.7) contrast(0.95);
  247. }
  248. .bubble {
  249. width: min(100%, 820px);
  250. border-radius: 8px;
  251. padding: 15px 17px;
  252. background: rgba(255, 252, 244, 0.62);
  253. border: 1px solid rgba(82, 83, 72, 0.14);
  254. line-height: 1.78;
  255. white-space: pre-wrap;
  256. color: var(--ink);
  257. }
  258. .message-row.user .bubble {
  259. justify-self: end;
  260. background: rgba(232, 237, 225, 0.72);
  261. border-color: rgba(108, 118, 102, 0.24);
  262. }
  263. .message-row.user .avatar {
  264. grid-column: 2;
  265. grid-row: 1;
  266. }
  267. .message-row.user .bubble {
  268. grid-column: 1;
  269. grid-row: 1;
  270. }
  271. .progress-bubble {
  272. display: grid;
  273. gap: 6px;
  274. width: min(100%, 560px);
  275. background: rgba(245, 243, 236, 0.78);
  276. }
  277. .progress-title {
  278. display: block;
  279. color: var(--moss-deep);
  280. font-size: 15px;
  281. font-weight: 700;
  282. }
  283. .progress-detail {
  284. display: block;
  285. color: var(--muted);
  286. font-size: 13px;
  287. line-height: 1.55;
  288. }
  289. .typing {
  290. display: inline-flex;
  291. align-items: center;
  292. gap: 6px;
  293. white-space: nowrap;
  294. font-weight: 600;
  295. color: var(--moss-deep);
  296. }
  297. .typing i {
  298. width: 5px;
  299. height: 5px;
  300. border-radius: 50%;
  301. background: var(--moss);
  302. animation: pulse 1.3s infinite ease-in-out;
  303. }
  304. .typing i:nth-child(2) {
  305. animation-delay: 0.16s;
  306. }
  307. .typing i:nth-child(3) {
  308. animation-delay: 0.32s;
  309. }
  310. @keyframes pulse {
  311. 0%,
  312. 80%,
  313. 100% {
  314. opacity: 0.25;
  315. }
  316. 40% {
  317. opacity: 1;
  318. }
  319. }
  320. .table-card {
  321. margin-top: 14px;
  322. border: 1px solid var(--line);
  323. border-radius: 8px;
  324. background: rgba(255, 252, 244, 0.76);
  325. overflow: hidden;
  326. }
  327. .table-head {
  328. display: flex;
  329. justify-content: space-between;
  330. align-items: center;
  331. gap: 10px;
  332. padding: 11px 13px;
  333. background: rgba(232, 226, 213, 0.58);
  334. border-bottom: 1px solid var(--line);
  335. }
  336. .table-head strong {
  337. font-size: 14px;
  338. font-weight: 700;
  339. }
  340. .table-head button {
  341. border: 1px solid var(--line-strong);
  342. background: rgba(255, 252, 244, 0.58);
  343. color: var(--moss-deep);
  344. border-radius: 3px;
  345. padding: 6px 11px;
  346. cursor: pointer;
  347. white-space: nowrap;
  348. font-weight: 600;
  349. }
  350. .table-wrap {
  351. overflow: auto;
  352. max-height: 430px;
  353. }
  354. table {
  355. width: 100%;
  356. min-width: 700px;
  357. border-collapse: collapse;
  358. font-size: 13px;
  359. }
  360. th,
  361. td {
  362. border-bottom: 1px solid rgba(82, 83, 72, 0.14);
  363. padding: 10px 12px;
  364. text-align: left;
  365. vertical-align: top;
  366. word-break: break-word;
  367. }
  368. th {
  369. position: sticky;
  370. top: 0;
  371. z-index: 1;
  372. background: #eee8dc;
  373. color: var(--charcoal);
  374. font-weight: 700;
  375. }
  376. tbody tr:nth-child(even) {
  377. background: rgba(237, 232, 221, 0.42);
  378. }
  379. .composer {
  380. margin: 0 22px 22px;
  381. border: 1px solid var(--line);
  382. border-radius: 8px;
  383. padding: 11px;
  384. background: rgba(255, 252, 244, 0.68);
  385. }
  386. .composer:focus-within {
  387. border-color: var(--moss);
  388. }
  389. .composer textarea {
  390. width: 100%;
  391. min-height: 76px;
  392. max-height: 190px;
  393. border: 0;
  394. outline: 0;
  395. resize: vertical;
  396. color: var(--ink);
  397. background: transparent;
  398. }
  399. .composer textarea::placeholder {
  400. color: #75786e;
  401. }
  402. .composer-footer {
  403. display: flex;
  404. justify-content: space-between;
  405. align-items: center;
  406. color: var(--muted);
  407. font-size: 12px;
  408. }
  409. .send-button {
  410. border: 1px solid var(--moss-deep);
  411. border-radius: 4px;
  412. min-width: 96px;
  413. height: 40px;
  414. padding: 0 16px;
  415. background: var(--moss-deep);
  416. color: #f7f3eb;
  417. display: inline-flex;
  418. align-items: center;
  419. justify-content: center;
  420. gap: 8px;
  421. cursor: pointer;
  422. font-weight: 600;
  423. }
  424. .send-button:hover,
  425. .send-button:focus-visible {
  426. background: #354236;
  427. }
  428. .send-button:disabled {
  429. cursor: not-allowed;
  430. opacity: 0.64;
  431. }
  432. .send-icon,
  433. .send-text {
  434. white-space: nowrap;
  435. }
  436. .inspector {
  437. display: grid;
  438. align-content: start;
  439. gap: 14px;
  440. max-height: calc(100vh - 210px);
  441. overflow: auto;
  442. }
  443. .panel {
  444. padding: 16px;
  445. }
  446. .panel-title {
  447. display: flex;
  448. align-items: center;
  449. justify-content: space-between;
  450. gap: 12px;
  451. margin-bottom: 12px;
  452. }
  453. .panel h2 {
  454. margin: 0;
  455. font-size: 18px;
  456. font-weight: 700;
  457. }
  458. .tool-list,
  459. .trace-list {
  460. display: grid;
  461. gap: 9px;
  462. }
  463. .tool-item,
  464. .trace-item {
  465. border: 1px solid rgba(82, 83, 72, 0.14);
  466. border-radius: 7px;
  467. padding: 11px;
  468. background: rgba(255, 252, 244, 0.52);
  469. }
  470. .tool-item {
  471. width: 100%;
  472. text-align: left;
  473. color: inherit;
  474. cursor: pointer;
  475. }
  476. .tool-item:hover,
  477. .tool-item:focus-visible {
  478. background: rgba(249, 245, 235, 0.86);
  479. border-color: rgba(63, 77, 63, 0.36);
  480. }
  481. .tool-item.active {
  482. border-color: rgba(63, 77, 63, 0.54);
  483. background: rgba(232, 226, 213, 0.58);
  484. }
  485. .tool-item strong,
  486. .trace-item strong {
  487. display: block;
  488. font-size: 14px;
  489. font-weight: 700;
  490. }
  491. .tool-item span,
  492. .trace-item span {
  493. display: block;
  494. color: var(--muted);
  495. font-size: 12px;
  496. margin-top: 4px;
  497. word-break: break-word;
  498. line-height: 1.5;
  499. }
  500. .tool-item small {
  501. display: inline-block;
  502. margin-top: 8px;
  503. padding: 3px 7px;
  504. border-radius: 999px;
  505. color: var(--moss-deep);
  506. background: rgba(225, 232, 218, 0.64);
  507. font-size: 11px;
  508. line-height: 1.4;
  509. }
  510. .phase-error strong {
  511. color: var(--danger);
  512. }
  513. @media (max-width: 1180px) {
  514. .top-nav {
  515. grid-template-columns: 1fr;
  516. }
  517. .session-card {
  518. justify-self: stretch;
  519. }
  520. .nav {
  521. justify-content: flex-start;
  522. overflow-x: auto;
  523. }
  524. .workspace {
  525. grid-template-columns: 1fr;
  526. }
  527. .inspector {
  528. max-height: none;
  529. }
  530. }
  531. @media (max-width: 720px) {
  532. .top-nav {
  533. padding: 12px;
  534. gap: 12px;
  535. }
  536. .shell {
  537. width: min(100% - 20px, 1460px);
  538. padding-top: 12px;
  539. }
  540. .chat-card {
  541. min-height: 620px;
  542. }
  543. .message-row,
  544. .message-row.user {
  545. grid-template-columns: 1fr;
  546. }
  547. .message-row .avatar,
  548. .message-row.user .avatar {
  549. display: none;
  550. }
  551. .message-row.user .bubble,
  552. .message-row.user .avatar {
  553. grid-column: auto;
  554. grid-row: auto;
  555. }
  556. }