/* TuringWork 官网 —— 设计令牌
 *
 * 意象：图灵纸带。人、Agent、插件都是带上的一格，工作沿带子向前走。
 * 纸白底 + 墨黑字 + 电传蓝（品牌）+ 信号绿（Agent 完成态），等宽字体承担
 * 所有"机器的声音"（单号、命令、状态）。 */
:root {
  --paper: #f7f6f2;
  --ink: #16181b;
  --ink-soft: #5c6066;
  --blue: #2743f0;   /* 电传蓝：品牌与链接 */
  --green: #0d9d6c;  /* 信号绿：Agent、完成态 */
  --line: #d9d7d0;
  --cell: #ffffff;
  --mono: ui-monospace, "SF Mono", "JetBrains Mono", Menlo, Consolas, monospace;
  --sans: -apple-system, "PingFang SC", "HarmonyOS Sans SC", "Microsoft YaHei", sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--sans);
  background: var(--paper);
  color: var(--ink);
  line-height: 1.65;
  font-size: 16px;
}

a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }

.wrap { max-width: 1060px; margin: 0 auto; padding: 0 24px; }

/* ---- 顶栏 ---- */
header {
  border-bottom: 1px solid var(--line);
  background: var(--paper);
  position: sticky; top: 0; z-index: 10;
}
.nav { display: flex; align-items: baseline; gap: 28px; padding: 18px 0; }
.brand { font-weight: 700; font-size: 1.15rem; letter-spacing: .01em; color: var(--ink); }
.brand .tw-dot { color: var(--blue); }
.nav a.item { color: var(--ink-soft); font-size: .95rem; }
.nav a.item[aria-current="page"] { color: var(--ink); font-weight: 600; }
.nav .cta { margin-left: auto; color: var(--blue); font-weight: 600; }

/* ---- Hero ---- */
.hero { padding: 88px 0 40px; }
.hero h1 {
  font-size: clamp(2.1rem, 5.4vw, 3.6rem);
  font-weight: 800;
  line-height: 1.18;
  letter-spacing: .01em;
  max-width: 21em;
}
.hero h1 em { font-style: normal; color: var(--blue); }
.hero p.lead {
  margin-top: 20px; max-width: 34em;
  font-size: 1.12rem; color: var(--ink-soft);
}
.hero .actions { margin-top: 32px; display: flex; gap: 16px; flex-wrap: wrap; }
.btn {
  display: inline-block; padding: 12px 22px; border-radius: 6px;
  font-weight: 600; font-size: .98rem; border: 1.5px solid var(--ink);
  color: var(--ink); background: transparent;
}
.btn:hover { text-decoration: none; background: #fff; }
.btn.primary { background: var(--ink); color: var(--paper); }
.btn.primary:hover { background: var(--blue); border-color: var(--blue); }

/* ---- 图灵纸带（署名元素） ----
 * 一条等宽格子的带子横贯页面，一项工作从左往右流经：待办→认领→执行→交付。
 * 高亮格由动画推进；打开"减少动态"时静止在交付格。 */
.tape { margin: 64px 0 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); overflow-x: auto; }
.tape-inner { display: flex; min-width: 640px; }
.tape .cellu {
  flex: 1; min-width: 80px; padding: 14px 10px 12px;
  border-right: 1px solid var(--line);
  font-family: var(--mono); font-size: .78rem; color: var(--ink-soft);
  background: var(--cell); text-align: center; white-space: nowrap;
}
.tape .cellu:first-child { border-left: 1px solid var(--line); }
.tape .cellu b { display: block; font-size: .95rem; color: var(--ink); font-weight: 600; margin-top: 2px; }
.tape .cellu.agent b { color: var(--green); }
@keyframes tapewalk {
  0%, 12%   { box-shadow: inset 0 -3px 0 var(--blue); }
  100%      { box-shadow: inset 0 0 0 transparent; }
}
.tape .cellu { animation: tapewalk 7s infinite; }
.tape .cellu:nth-child(1) { animation-delay: 0s; }
.tape .cellu:nth-child(2) { animation-delay: 1s; }
.tape .cellu:nth-child(3) { animation-delay: 2s; }
.tape .cellu:nth-child(4) { animation-delay: 3s; }
.tape .cellu:nth-child(5) { animation-delay: 4s; }
.tape .cellu:nth-child(6) { animation-delay: 5s; }
@media (prefers-reduced-motion: reduce) {
  .tape .cellu { animation: none; }
  .tape .cellu:last-child { box-shadow: inset 0 -3px 0 var(--green); }
}

/* ---- 章节 ---- */
section { padding: 72px 0 8px; }
.kicker {
  font-family: var(--mono); font-size: .8rem; letter-spacing: .12em;
  color: var(--blue); text-transform: uppercase;
}
section h2 { font-size: 1.7rem; font-weight: 700; margin: 8px 0 8px; }
section > .wrap > p.sub { color: var(--ink-soft); max-width: 40em; }

.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 36px; }
@media (max-width: 820px) { .grid { grid-template-columns: 1fr; } }
.card {
  background: var(--cell); border: 1px solid var(--line); border-radius: 8px;
  padding: 26px 24px 24px;
}
.card h3 { font-size: 1.08rem; font-weight: 700; margin-bottom: 10px; }
.card p { color: var(--ink-soft); font-size: .95rem; }
.card .tag {
  font-family: var(--mono); font-size: .72rem; color: var(--green);
  border: 1px solid currentColor; border-radius: 99px; padding: 1px 9px;
  display: inline-block; margin-bottom: 14px;
}
.card .tag.blue { color: var(--blue); }
.card .tag.gray { color: var(--ink-soft); }

/* 对话示例：@Agent 的那一幕 */
.scene {
  margin-top: 36px; background: var(--cell); border: 1px solid var(--line);
  border-radius: 8px; padding: 22px 24px; font-family: var(--mono);
  font-size: .88rem; line-height: 1.9; overflow-x: auto;
}
.scene .who { color: var(--blue); }
.scene .who.agent { color: var(--green); }
.scene .meta { color: var(--ink-soft); }

/* ---- 商店卡片 ---- */
.store-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; margin-top: 36px; }
.plugin { background: var(--cell); border: 1px solid var(--line); border-radius: 8px; padding: 24px; display: flex; flex-direction: column; }
.plugin .pname { font-weight: 700; font-size: 1.05rem; }
.plugin .pver { font-family: var(--mono); font-size: .75rem; color: var(--ink-soft); margin-left: 8px; }
.plugin p { color: var(--ink-soft); font-size: .92rem; margin: 10px 0 16px; flex: 1; }
.plugin .pfoot { display: flex; align-items: center; gap: 10px; }
.plugin .signed { font-family: var(--mono); font-size: .72rem; color: var(--green); }

/* ---- 私有化段落 ---- */
.deploy-points { margin-top: 28px; display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px 40px; max-width: 56em; }
@media (max-width: 820px) { .deploy-points { grid-template-columns: 1fr; } }
.deploy-points li { list-style: none; padding-left: 26px; position: relative; color: var(--ink-soft); }
.deploy-points li::before {
  content: "▪"; position: absolute; left: 4px; color: var(--green);
}
.deploy-points li b { color: var(--ink); }

/* ---- 页脚 ---- */
footer { margin-top: 96px; border-top: 1px solid var(--line); padding: 36px 0 48px; }
footer .wrap { display: flex; flex-wrap: wrap; gap: 12px 32px; align-items: baseline; }
footer, footer a { color: var(--ink-soft); font-size: .88rem; }

/* ================= 动效：分开 → 拼合 =================
 * 初始态=散开（各元素从不同方向位移+微旋转），body.assemble / .in 后归位。
 * motion-off（系统减少动态）下所有初始位移取消，页面直接是终态。 */

/* —— 第一幕：首屏标题两半拼合 —— */
.motion-on .hero .h-left,
.motion-on .hero .h-right { display: inline-block; transition: transform .9s cubic-bezier(.2,1.4,.3,1), opacity .6s ease; }
.motion-on body:not(.assemble) .hero .h-left,
.motion-on .hero .h-left { transform: none; }
.motion-on .assemble .hero .h-left,
.motion-on .assemble .hero .h-right { transform: none; opacity: 1; }
.motion-on .hero .h-left { transform: translateX(-56px) rotate(-1.5deg); opacity: 0; }
.motion-on .hero .h-right { transform: translateX(56px) rotate(1.5deg); opacity: 0; }
.motion-on .assemble .hero .h-left { transform: none; opacity: 1; }
.motion-on .assemble .hero .h-right { transform: none; opacity: 1; transition-delay: .08s; }

.motion-on .hero p.lead,
.motion-on .hero .actions { opacity: 0; transform: translateY(18px); transition: transform .7s ease .5s, opacity .7s ease .5s; }
.motion-on .assemble .hero p.lead,
.motion-on .assemble .hero .actions { opacity: 1; transform: none; }
.motion-on .hero .actions { transition-delay: .65s; }

/* —— 第二幕：纸带合拢，逐格扣上 —— */
.motion-on .tape .cellu {
  opacity: 0;
  transition: transform .8s cubic-bezier(.2,1.5,.3,1), opacity .5s ease;
}
.motion-on .tape .cellu:nth-child(odd)  { transform: translateX(-90px) translateY(6px); }
.motion-on .tape .cellu:nth-child(even) { transform: translateX(90px) translateY(-6px); }
.motion-on .assemble .tape .cellu { transform: none; opacity: 1; }
.motion-on .assemble .tape .cellu:nth-child(1) { transition-delay: .55s; }
.motion-on .assemble .tape .cellu:nth-child(2) { transition-delay: .67s; }
.motion-on .assemble .tape .cellu:nth-child(3) { transition-delay: .79s; }
.motion-on .assemble .tape .cellu:nth-child(4) { transition-delay: .91s; }
.motion-on .assemble .tape .cellu:nth-child(5) { transition-delay: 1.03s; }
.motion-on .assemble .tape .cellu:nth-child(6) { transition-delay: 1.15s; }
/* 流转高亮等拼合完再开演 */
.motion-on .tape .cellu { animation-play-state: paused; }
.motion-on .assemble .tape .cellu { animation-play-state: running; animation-delay: calc(1.6s + var(--walk, 0s)); }
.motion-on .assemble .tape .cellu:nth-child(1) { --walk: 0s; }
.motion-on .assemble .tape .cellu:nth-child(2) { --walk: 1s; }
.motion-on .assemble .tape .cellu:nth-child(3) { --walk: 2s; }
.motion-on .assemble .tape .cellu:nth-child(4) { --walk: 3s; }
.motion-on .assemble .tape .cellu:nth-child(5) { --walk: 4s; }
.motion-on .assemble .tape .cellu:nth-child(6) { --walk: 5s; }

/* —— 第三幕：滚动装配 —— */
.motion-on .fly {
  opacity: 0;
  transform: translateY(42px) rotate(.6deg);
  transition: transform .8s cubic-bezier(.2,1.3,.3,1), opacity .6s ease;
}
.motion-on .fly[style*="--fly-i: 0"] { transform: translateX(-48px) translateY(24px) rotate(-.8deg); }
.motion-on .fly[style*="--fly-i: 2"] { transform: translateX(48px) translateY(24px) rotate(.8deg); }
.motion-on .fly.in { opacity: 1; transform: none; }
.motion-on .fly.in:nth-child(2) { transition-delay: .1s; }
.motion-on .fly.in:nth-child(3) { transition-delay: .2s; }

/* 悬停微动 */
.motion-on .card:hover, .motion-on .plugin:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 28px rgba(20, 24, 27, .08);
  transition: transform .25s ease, box-shadow .25s ease;
}
.motion-on .btn { transition: transform .15s ease, background .2s ease, border-color .2s ease; }
.motion-on .btn:hover { transform: translateY(-2px); }
