base.css 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401
  1. :root {
  2. --paper: #f6f2e9;
  3. --paper-2: #fbf8f1;
  4. --paper-3: #efe9dc;
  5. --ink: #17140f;
  6. --ink-2: #2c271f;
  7. --muted: #7d7466;
  8. --muted-2: #a79d8d;
  9. --line: #e2dacb;
  10. --line-2: #d3c9b7;
  11. --accent: #ff5c2b; /* 默认橙;主题由 assets/js/theme.js 运行时覆盖 */
  12. --accent-dark: #e64718;
  13. --accent-soft: #ffe0d2;
  14. --accent-on: #fff; /* 主色上的文字/图标色(深色主色为白,亮色主色自动转墨) */
  15. --accent-rgb: 255,92,43; /* 供 rgba(var(--accent-rgb), .x) 使用 */
  16. --lime: #d9f07c;
  17. --lime-dark: #b9d24e;
  18. --sage: #1e3a2c;
  19. --blue: #bfe3f2;
  20. --white: #fffdf8;
  21. --radius-s: 10px;
  22. --radius-m: 16px;
  23. --radius-l: 24px;
  24. --radius-xl: 34px;
  25. --shadow-s: 0 2px 10px rgba(32, 24, 12, 0.06);
  26. --shadow-m: 0 14px 40px rgba(32, 24, 12, 0.1);
  27. --shadow-l: 0 30px 80px rgba(32, 24, 12, 0.16);
  28. --font: "SF Pro SC", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, -apple-system, sans-serif;
  29. --font-serif: "Songti SC", "STSong", "SimSun", Georgia, serif;
  30. --font-mono: "SF Mono", "JetBrains Mono", Menlo, Consolas, monospace;
  31. --font-latin: "Helvetica Neue", "Arial", sans-serif;
  32. --ease: cubic-bezier(0.22, 1, 0.36, 1);
  33. }
  34. * { box-sizing: border-box; }
  35. html {
  36. scroll-behavior: smooth;
  37. -webkit-text-size-adjust: 100%;
  38. }
  39. body {
  40. margin: 0;
  41. background: var(--paper);
  42. color: var(--ink);
  43. font-family: var(--font);
  44. font-size: 15px;
  45. line-height: 1.6;
  46. -webkit-font-smoothing: antialiased;
  47. text-rendering: optimizeLegibility;
  48. }
  49. body.no-scroll { overflow: hidden; }
  50. a { color: inherit; text-decoration: none; }
  51. button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; padding: 0; }
  52. input, select, textarea { font: inherit; color: inherit; }
  53. img, svg { display: block; max-width: 100%; }
  54. h1, h2, h3, h4, p, figure { margin: 0; }
  55. ul, ol { margin: 0; padding: 0; list-style: none; }
  56. ::selection { background: var(--accent); color: var(--accent-on); }
  57. .container {
  58. width: min(1280px, calc(100% - 88px));
  59. margin: 0 auto;
  60. }
  61. .btn {
  62. display: inline-flex;
  63. align-items: center;
  64. justify-content: center;
  65. gap: 9px;
  66. height: 50px;
  67. padding: 0 26px;
  68. border-radius: 999px;
  69. font-size: 14px;
  70. font-weight: 650;
  71. letter-spacing: 0.01em;
  72. white-space: nowrap;
  73. transition: transform 0.25s var(--ease), background 0.25s, color 0.25s, box-shadow 0.25s;
  74. }
  75. .btn:hover { transform: translateY(-2px); }
  76. .btn:active { transform: translateY(0); }
  77. .btn-primary { background: var(--accent); color: var(--accent-on); box-shadow: 0 10px 26px rgba(var(--accent-rgb), 0.26); }
  78. .btn-primary:hover { background: var(--accent-dark); box-shadow: 0 14px 32px rgba(var(--accent-rgb), 0.32); }
  79. .btn-ink { background: var(--ink); color: var(--paper-2); }
  80. .btn-ink:hover { background: #2c271f; }
  81. .btn-ghost { border: 1px solid var(--line-2); background: transparent; }
  82. .btn-ghost:hover { background: var(--white); border-color: var(--ink); }
  83. .btn-lime { background: var(--lime); color: var(--ink); }
  84. .btn-lime:hover { background: #e5f79a; }
  85. .btn-sm { height: 38px; padding: 0 18px; font-size: 13px; }
  86. .btn-lg { height: 58px; padding: 0 34px; font-size: 15px; }
  87. .btn[disabled] { opacity: 0.45; pointer-events: none; }
  88. .icon {
  89. width: 18px;
  90. height: 18px;
  91. stroke: currentColor;
  92. stroke-width: 1.7;
  93. fill: none;
  94. stroke-linecap: round;
  95. stroke-linejoin: round;
  96. flex: none;
  97. }
  98. .eyebrow {
  99. display: inline-flex;
  100. align-items: center;
  101. gap: 10px;
  102. font-family: var(--font-mono);
  103. font-size: 11px;
  104. letter-spacing: 0.18em;
  105. text-transform: uppercase;
  106. color: var(--muted);
  107. }
  108. .eyebrow::before {
  109. content: "";
  110. width: 26px;
  111. height: 1px;
  112. background: currentColor;
  113. opacity: 0.5;
  114. }
  115. .tag {
  116. display: inline-flex;
  117. align-items: center;
  118. gap: 6px;
  119. height: 26px;
  120. padding: 0 11px;
  121. border: 1px solid var(--line);
  122. border-radius: 999px;
  123. background: var(--paper-2);
  124. font-size: 11px;
  125. font-weight: 550;
  126. color: var(--ink-2);
  127. white-space: nowrap;
  128. }
  129. .tag-accent { background: var(--accent-soft); border-color: rgba(var(--accent-rgb), 0.25); color: var(--accent-dark); }
  130. .tag-lime { background: var(--lime); border-color: transparent; }
  131. .tag-dark { background: var(--ink); border-color: var(--ink); color: var(--paper-2); }
  132. .logo {
  133. display: inline-flex;
  134. align-items: center;
  135. gap: 11px;
  136. font-weight: 800;
  137. letter-spacing: -0.02em;
  138. }
  139. .logo-img { display: block; width: auto; height: 34px; }
  140. .footer-brand .logo-img { height: 56px; }
  141. .site-header {
  142. position: sticky;
  143. top: 0;
  144. z-index: 60;
  145. background: rgba(246, 242, 233, 0.82);
  146. backdrop-filter: blur(18px);
  147. -webkit-backdrop-filter: blur(18px);
  148. border-bottom: 1px solid rgba(226, 218, 203, 0.7);
  149. }
  150. .site-header .container {
  151. height: 76px;
  152. display: flex;
  153. align-items: center;
  154. justify-content: space-between;
  155. gap: 30px;
  156. }
  157. .site-nav { display: flex; align-items: center; gap: 34px; }
  158. .site-nav a {
  159. position: relative;
  160. font-size: 13.5px;
  161. font-weight: 550;
  162. color: var(--ink-2);
  163. padding: 6px 0;
  164. }
  165. .site-nav a::after {
  166. content: "";
  167. position: absolute;
  168. left: 0;
  169. bottom: 0;
  170. width: 0;
  171. height: 1.5px;
  172. background: var(--accent);
  173. transition: width 0.3s var(--ease);
  174. }
  175. .site-nav a:hover::after { width: 100%; }
  176. .header-actions { display: flex; align-items: center; gap: 12px; }
  177. .header-link { font-size: 13px; font-weight: 550; color: var(--muted); }
  178. .header-link:hover { color: var(--ink); }
  179. a.header-link { text-decoration: none; background: none; border: 0; cursor: pointer; padding: 0; font-family: inherit; }
  180. .site-footer {
  181. background: var(--ink);
  182. color: var(--paper-2);
  183. padding: 70px 0 0;
  184. margin-top: 100px;
  185. }
  186. .footer-top {
  187. display: grid;
  188. grid-template-columns: 1.6fr 1fr 1fr 1.4fr;
  189. gap: 50px;
  190. padding-bottom: 60px;
  191. }
  192. .footer-brand p {
  193. margin-top: 22px;
  194. max-width: 300px;
  195. color: rgba(255, 253, 248, 0.55);
  196. font-size: 13px;
  197. line-height: 1.8;
  198. }
  199. .footer-col h4 {
  200. font-size: 11px;
  201. font-family: var(--font-mono);
  202. letter-spacing: 0.16em;
  203. color: rgba(255, 253, 248, 0.4);
  204. margin-bottom: 20px;
  205. font-weight: 500;
  206. }
  207. .footer-col a, .footer-col span {
  208. display: block;
  209. font-size: 13px;
  210. color: rgba(255, 253, 248, 0.78);
  211. margin-bottom: 12px;
  212. }
  213. .footer-col a:hover { color: var(--lime); }
  214. .footer-sub {
  215. border: 1px solid rgba(255, 253, 248, 0.16);
  216. border-radius: var(--radius-m);
  217. padding: 22px;
  218. }
  219. .footer-sub p { font-size: 13px; color: rgba(255, 253, 248, 0.6); margin-bottom: 16px; }
  220. .footer-sub .field { display: flex; gap: 8px; }
  221. .footer-sub input {
  222. flex: 1;
  223. height: 42px;
  224. border-radius: 999px;
  225. border: 1px solid rgba(255, 253, 248, 0.16);
  226. background: rgba(255, 253, 248, 0.06);
  227. color: var(--paper-2);
  228. padding: 0 16px;
  229. font-size: 12px;
  230. outline: none;
  231. }
  232. .footer-sub input::placeholder { color: rgba(255, 253, 248, 0.3); }
  233. .footer-sub button {
  234. width: 42px;
  235. height: 42px;
  236. border-radius: 50%;
  237. background: var(--lime);
  238. color: var(--ink);
  239. display: grid;
  240. place-items: center;
  241. }
  242. .footer-bottom {
  243. border-top: 1px solid rgba(255, 253, 248, 0.12);
  244. height: 78px;
  245. display: flex;
  246. align-items: center;
  247. justify-content: space-between;
  248. font-size: 11.5px;
  249. color: rgba(255, 253, 248, 0.4);
  250. font-family: var(--font-mono);
  251. letter-spacing: 0.04em;
  252. }
  253. .footer-bottom-links { display: flex; gap: 24px; }
  254. .footer-bottom a:hover { color: var(--lime); }
  255. .toast {
  256. position: fixed;
  257. left: 50%;
  258. bottom: 36px;
  259. transform: translate(-50%, 20px);
  260. background: var(--ink);
  261. color: var(--paper-2);
  262. padding: 13px 22px;
  263. border-radius: 999px;
  264. font-size: 13px;
  265. box-shadow: var(--shadow-l);
  266. opacity: 0;
  267. pointer-events: none;
  268. transition: opacity 0.3s, transform 0.3s var(--ease);
  269. z-index: 300;
  270. display: flex;
  271. align-items: center;
  272. gap: 9px;
  273. max-width: calc(100vw - 40px);
  274. }
  275. .toast.show { opacity: 1; transform: translate(-50%, 0); }
  276. .toast .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--lime); flex: none; }
  277. .fade-up { opacity: 0; transform: translateY(24px); transition: opacity 0.8s var(--ease), transform 0.8s var(--ease); }
  278. .fade-up.in { opacity: 1; transform: none; }
  279. ::-webkit-scrollbar { width: 10px; height: 10px; }
  280. ::-webkit-scrollbar-track { background: transparent; }
  281. ::-webkit-scrollbar-thumb { background: #cfc5b4; border-radius: 99px; border: 3px solid var(--paper); }
  282. ::-webkit-scrollbar-thumb:hover { background: #b3a794; }
  283. @media (max-width: 1024px) {
  284. .container { width: calc(100% - 48px); }
  285. .site-nav { display: none; }
  286. .footer-top { grid-template-columns: 1fr 1fr; }
  287. }
  288. @media (max-width: 680px) {
  289. .container { width: calc(100% - 32px); }
  290. .header-actions .header-link { display: none; }
  291. .footer-top { grid-template-columns: 1fr; gap: 32px; }
  292. .footer-bottom { flex-direction: column; justify-content: center; gap: 10px; height: auto; padding: 24px 0; }
  293. .footer-bottom-links { gap: 16px; }
  294. .site-footer { margin-top: 60px; padding-top: 50px; }
  295. }
  296. /* AI 设计师 Agent 聊天窗 */
  297. #plAgentFab {
  298. position: fixed; right: 26px; bottom: 30px; z-index: 70;
  299. display: inline-flex; align-items: center; gap: 8px;
  300. border: 0; cursor: pointer; font-family: inherit;
  301. background: linear-gradient(135deg, #17140f, #3a332a); color: #fffdf8;
  302. border-radius: 999px; padding: 12px 20px; font-size: 13.5px; font-weight: 700;
  303. box-shadow: 0 14px 34px rgba(23,20,15,0.32); transition: transform 0.15s;
  304. }
  305. #plAgentFab:hover { transform: translateY(-2px); }
  306. .pl-agent-panel {
  307. position: fixed; right: 26px; bottom: 88px; z-index: 70; width: 400px; max-width: calc(100vw - 40px);
  308. background: #fffdf8; border: 1px solid #e2dacb; border-radius: 16px;
  309. box-shadow: 0 30px 70px rgba(23,20,15,0.22); display: flex; flex-direction: column;
  310. max-height: min(78vh, 720px); overflow: hidden;
  311. }
  312. .pl-agent-panel[hidden] { display: none; }
  313. .pl-agent-head {
  314. display: flex; align-items: center; gap: 10px; padding: 14px 16px;
  315. border-bottom: 1px solid #efe9dc; background: #fffdf8;
  316. }
  317. .pl-agent-head b { font-size: 14.5px; display: block; }
  318. .pl-agent-head small { font-size: 10.5px; color: #a79d8d; display: block; margin-top: 2px; }
  319. .pl-agent-quota { font-size: 10.5px; color: #7d7466; background: #f6f2e9; border-radius: 999px; padding: 3px 9px; }
  320. .pl-agent-close { margin-left: auto; border: 0; background: none; cursor: pointer; color: #a79d8d; font-size: 14px; }
  321. .pl-agent-body { flex: 1; overflow-y: auto; padding: 14px 16px; display: flex; flex-direction: column; gap: 10px; min-height: 120px; }
  322. .pl-agent-msg { max-width: 88%; padding: 9px 12px; border-radius: 12px; font-size: 12.5px; line-height: 1.65; }
  323. .pl-agent-msg.ai { background: #f6f2e9; color: #2c271f; align-self: flex-start; border-bottom-left-radius: 4px; }
  324. .pl-agent-msg.user { background: var(--accent); color: var(--accent-on); align-self: flex-end; border-bottom-right-radius: 4px; }
  325. .pl-agent-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--accent); margin-right: 6px; animation: plAgentBlink 1s infinite; }
  326. @keyframes plAgentBlink { 50% { opacity: 0.25; } }
  327. .pl-agent-preview { padding: 0 16px 8px; }
  328. .pl-agent-preview[hidden] { display: none; }
  329. .pl-agent-faces { display: flex; gap: 10px; justify-content: center; }
  330. .pl-agent-face { position: relative; width: 46%; border-radius: 10px; border: 1px solid #efe9dc; background: #fff; overflow: hidden; }
  331. .pl-agent-face svg { width: 100%; height: auto; display: block; }
  332. .pl-agent-face i { position: absolute; left: 8px; bottom: 6px; font-style: normal; font-size: 10px; color: #a79d8d; background: rgba(255,253,248,.8); border-radius: 6px; padding: 1px 6px; }
  333. .pl-agent-boxfaces { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
  334. .pl-agent-boxface { position: relative; border-radius: 8px; border: 1px solid #efe9dc; height: 64px; padding: 6px; overflow: hidden; }
  335. .pl-agent-boxface i { font-style: normal; font-size: 9.5px; color: #a79d8d; display: block; }
  336. .pl-agent-boxface b { font-size: 10.5px; color: #2c271f; line-height: 1.4; font-weight: 600; display: block; margin-top: 3px; }
  337. .pl-agent-state { padding: 0 16px 10px; }
  338. .pl-agent-state[hidden] { display: none; }
  339. .pl-agent-chips { display: flex; flex-wrap: wrap; gap: 6px; }
  340. .pl-agent-chips span { font-size: 10.5px; color: #2c271f; background: var(--accent-soft); border-radius: 999px; padding: 3px 10px; }
  341. .pl-agent-go { display: block; text-align: center; margin-top: 8px; background: #17140f; color: #fffdf8; border-radius: 10px; padding: 9px; font-size: 12.5px; font-weight: 700; text-decoration: none; }
  342. .pl-agent-go:hover { background: var(--accent); }
  343. .pl-agent-input { display: flex; gap: 8px; padding: 12px 16px; border-top: 1px solid #efe9dc; }
  344. .pl-agent-input textarea {
  345. flex: 1; border: 1px solid #e2dacb; border-radius: 10px; padding: 9px; font-size: 12.5px;
  346. resize: none; font-family: inherit; background: #fff; color: #2c271f;
  347. }
  348. .pl-agent-send { border: 0; background: var(--accent); color: var(--accent-on); border-radius: 10px; padding: 0 16px; cursor: pointer; font-weight: 700; font-size: 13px; font-family: inherit; }
  349. .pl-agent-send[disabled] { opacity: 0.55; }
  350. .pl-agent-step { font-size: 11.5px; color: #4f6b2f; padding: 1px 0; }
  351. .pl-agent-step.pending { color: #a79d8d; }
  352. /* Agent 聊天窗 · 盒 3D 预览 */
  353. .pl-agent-3d {
  354. position: relative; height: 200px; display: grid; place-items: center;
  355. perspective: 640px; cursor: grab; user-select: none; touch-action: none;
  356. border: 1px solid #efe9dc; border-radius: 12px; background: radial-gradient(circle at 50% 30%, #fffdf8, #f6f2e9);
  357. overflow: hidden; outline: none;
  358. }
  359. .pl-agent-3d:active { cursor: grabbing; }
  360. .pl-agent-3d-inner { position: relative; width: 0; height: 0; transform-style: preserve-3d; transition: transform 0.05s linear; }
  361. .pl-agent-3d-face {
  362. position: absolute; left: 0; top: 0; transform-style: preserve-3d;
  363. backface-visibility: hidden; border: 1px solid rgba(43,38,32,0.16);
  364. border-radius: 2px; overflow: hidden;
  365. }
  366. .pv-text {
  367. position: absolute; transform: translate(-50%, -50%); white-space: nowrap;
  368. font-family: Georgia, "PingFang SC", serif; line-height: 1.3;
  369. }
  370. .pv-logo { position: absolute; transform: translate(-50%, -50%); pointer-events: none; }
  371. .pv-bg { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
  372. .pl-agent-3d-hint {
  373. position: absolute; bottom: 6px; right: 10px; font-size: 10px; color: #a79d8d;
  374. background: rgba(255,253,248,.85); border-radius: 6px; padding: 2px 8px; pointer-events: none;
  375. }
  376. /* AI 设计师图标(SVG 星芒,替代 emoji) */
  377. #plAgentFab svg { width: 18px; height: 18px; flex: none; }
  378. #plAgentFab span { line-height: 1; }
  379. .pl-agent-head b svg { width: 15px; height: 15px; vertical-align: -2px; margin-right: 4px; }