/* macOS 下载卡的安装说明（partials/mac-open.html）：一行命令安装 + 首次打开放行的循环动画。
   动画：一轮 9 秒，三个画面各占 3 秒。所有画面和步骤用同一组关键帧，只靠负的 animation-delay 错开相位，
   所以永远同步（相位规则写成 .mo .mo-b *，优先级要高过各元素的 animation 简写，否则简写会把延迟重置为 0）；滚出视口（mac-open.js 去掉 .is-live）就暂停。减少动态效果时停在第 2 步「仍要打开」。 */
.mo { --mo-t: 9s; display: grid; gap: 14px; margin-top: 2px; }
.mo-label { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 8px; font-size: 14.5px; color: var(--ink-2); line-height: 1.5; }
.mo-label b { color: var(--ink); }
.mo-cmd { display: grid; gap: 8px; padding: 14px; border-radius: calc(var(--r-control) + 14px); background: color-mix(in srgb,var(--ok) 3%,var(--surface)); border: 1px solid transparent; }
.mo-cmd .cmd { background: var(--surface); }
.mo-cmd .cmd code { font-size: 12.5px; }
.mo-hint { font-size: 13px; color: var(--muted); }
/* 主路径（partials/mac-cmd.html）：在下载卡里、下载按钮上方 */
.mo-cmd-main { margin: 4px 0 2px; }
.mo-cmd-main[hidden] { display: none; }
.mo-cmd-steps { margin: 0; padding-left: 20px; display: grid; gap: 2px; font-size: 13.5px; color: var(--ink-2); line-height: 1.6; }
.mo-cmd-steps kbd { font: inherit; font-size: 12px; padding: 0 5px; border-radius: 5px; border: 1px solid var(--line); background: var(--surface); }
.mo-guide { display: grid; gap: 10px; padding: 14px; border-radius: calc(12px + 14px); background: var(--polish-layer-2); border: 1px solid transparent; }
.mo-open { justify-self: start; display: inline-flex; align-items: center; min-height: 44px; font-size: 14px; font-weight: calc(650 - var(--polish-weight-adjust)); }

/* 舞台 */
.mo-stage { position: relative; height: 188px; border-radius: 12px; overflow: hidden;
  background: radial-gradient(80% 90% at 20% 0%, color-mix(in srgb, var(--accent) 22%, transparent), transparent 70%), linear-gradient(160deg, #3b3f63, #1d2135); }
.mo-scene { position: absolute; inset: 0; display: grid; place-items: center; opacity: 0; }
.mo-b { opacity: 1; }
.mo-cur { position: absolute; width: 20px; height: 20px; opacity: 0; pointer-events: none; }
.mo-cur svg { width: 20px; height: 20px; fill: #111729; stroke: #fff; stroke-width: 1.5; }
.mo-a .mo-cur { left: calc(50% + 50px); top: 150px; }
.mo-b .mo-cur { left: calc(50% + 86px); top: 142px; }

/* 1 「未打开」对话框（macOS 15 样式） */
.mo-dlg { display: grid; justify-items: center; gap: 4px; width: 210px; padding: 12px 14px; border-radius: 14px; text-align: center; color: #1d1d1f;
  background: rgb(236 236 240 / .94); box-shadow: 0 16px 40px rgb(0 0 0 / .45); }
.mo-dlg b { font-size: 12px; line-height: 1.3; }
.mo-dlg small { font-size: 10.5px; line-height: 1.35; color: #3a3a3c; }
.mo-shield { position: relative; width: 30px; height: 30px; border-radius: 8px; background: linear-gradient(160deg, #d9d9de, #9a9aa3); }
.mo-shield i { position: absolute; right: -5px; bottom: -4px; display: grid; place-items: center; width: 16px; height: 15px; font: 800 10px/1 var(--font); font-style: normal; color: #1d1d1f;
  background: #ffd60a; clip-path: polygon(50% 0, 100% 100%, 0 100%); padding-top: 3px; }
.mo-btn { display: inline-grid; place-items: center; min-width: 120px; margin-top: 6px; padding: 5px 12px; border-radius: 7px; font-size: 11.5px; font-weight: 700; color: #fff; background: #0a84ff; }
.mo-btn.line { min-width: 0; color: #1d1d1f; background: #fff; border: 1px solid #c7c7cc; }

/* 2 系统设置 → 隐私与安全性 */
.mo-win { width: min(300px, 92%); border-radius: 12px; overflow: hidden; background: rgb(246 246 248 / .97); color: #1d1d1f; box-shadow: 0 16px 40px rgb(0 0 0 / .45); }
.mo-win-bar { display: flex; align-items: center; gap: 5px; padding: 7px 10px; border-bottom: 1px solid #e3e3e8; font-size: 10.5px; color: #6e6e73; }
.mo-win-bar i { width: 8px; height: 8px; border-radius: 50%; background: #ff5f57; }
.mo-win-bar i:nth-child(2) { background: #febc2e; } .mo-win-bar i:nth-child(3) { background: #28c840; }
.mo-win-bar span { margin-left: 6px; }
.mo-set { display: grid; grid-template-columns: 92px minmax(0, 1fr); min-height: 118px; }
.mo-set ul { margin: 0; padding: 8px 6px; list-style: none; display: grid; align-content: start; gap: 3px; background: #ececf0; font-size: 10.5px; }
.mo-set li { padding: 3px 6px; border-radius: 5px; color: #3a3a3c; white-space: nowrap; }
.mo-set li.on { background: #0a84ff; color: #fff; font-weight: 650; }
.mo-set-main { display: grid; align-content: start; gap: 4px; padding: 10px 12px; }
.mo-set-main b { font-size: 12px; }
.mo-set-main small { font-size: 10.5px; line-height: 1.4; color: #3a3a3c; }
.mo-set-main .mo-btn { justify-self: end; }

/* 3 输入密码 → 已打开 */
.mo-done { display: grid; justify-items: center; gap: 6px; color: #fff; text-align: center; }
.mo-done b { font-size: 14px; }
.mo-done small { font-size: 12px; color: rgb(255 255 255 / .75); }
.mo-pass { display: inline-flex; align-items: center; gap: 4px; padding: 6px 10px; border-radius: 8px; background: rgb(255 255 255 / .14); }
.mo-pass i { width: 6px; height: 6px; border-radius: 50%; background: #fff; }
.mo-pass em { margin-left: 6px; font-style: normal; font-size: 11px; color: rgb(255 255 255 / .8); }
.mo-app { position: relative; }
.mo .as-app-ico { display: inline-block; width: 46px; height: 46px; border-radius: 27%; vertical-align: middle;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 64'%3E%3Cpath d='M16 46V20l14 16L49 15' fill='none' stroke='%23fff' stroke-width='7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 64% no-repeat,
    linear-gradient(150deg, #8f80ff, #5b4ef0 48%, #3426b8); box-shadow: 0 6px 18px rgb(52 38 184 / .5); }
.mo-ok { position: absolute; right: -6px; bottom: -4px; display: grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; background: #28c840; color: #fff; font-size: 12px; font-weight: 800; border: 2px solid #1d2135; }

/* 步骤文字：当前画面对应的那一步点亮（默认点亮第 2 步，和静态画面一致） */
.mo-steps { margin: 0; padding: 0; list-style: none; display: grid; gap: 4px; }
.mo-steps li { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border-radius: 9px; font-size: 13.5px; color: var(--ink-2); line-height: 1.4; }
.mo-steps li b { display: grid; place-items: center; flex: none; width: 20px; height: 20px; border-radius: 50%; font-size: 11px; background: var(--polish-layer-2); color: var(--muted); border: 1px solid transparent; }
@media (prefers-reduced-motion: reduce) {
  .mo-steps li:nth-child(2) { background: var(--accent-soft); color: var(--accent); }
  .mo-steps li:nth-child(2) b { background: var(--accent); color: var(--accent-ink); border-color: transparent; }
}

/* 动画（相位：第 1 步 0s、第 2 步 -6s、第 3 步 -3s → 依次在 0–3s、3–6s、6–9s 出现） */
@media (prefers-reduced-motion: no-preference) {
  .mo-scene { animation: mo-scene var(--mo-t) linear infinite; }
  .mo .mo-a, .mo .mo-a * { animation-delay: 0s; }
  .mo .mo-b, .mo .mo-b * { animation-delay: calc(var(--mo-t) * -2 / 3); }
  .mo .mo-c, .mo .mo-c * { animation-delay: calc(var(--mo-t) / -3); }
  .mo-cur { animation: mo-cur var(--mo-t) ease-in-out infinite; }
  .mo-press { animation: mo-press var(--mo-t) ease-out infinite; }
  .mo-dlg, .mo-win { animation: mo-pop var(--mo-t) ease-out infinite; }
  .mo-pass i { animation: mo-dot var(--mo-t) linear infinite; }
  .mo-pass i:nth-child(2) { animation-name: mo-dot2; } .mo-pass i:nth-child(3) { animation-name: mo-dot3; }
  .mo-pass i:nth-child(4) { animation-name: mo-dot4; } .mo-pass i:nth-child(5) { animation-name: mo-dot5; } .mo-pass i:nth-child(6) { animation-name: mo-dot6; }
  .mo-app, .mo-done b, .mo-done small { animation: mo-rise var(--mo-t) ease-out infinite; animation-delay: calc(var(--mo-t) / -3); }
  .mo-steps li { animation: mo-step var(--mo-t) linear infinite; }
  .mo-steps li b { animation: mo-step-b var(--mo-t) linear infinite; }
  .mo-steps li:nth-child(1), .mo-steps li:nth-child(1) b { animation-delay: 0s; }
  .mo-steps li:nth-child(2), .mo-steps li:nth-child(2) b { animation-delay: calc(var(--mo-t) * -2 / 3); }
  .mo-steps li:nth-child(3), .mo-steps li:nth-child(3) b { animation-delay: calc(var(--mo-t) / -3); }
  .mo:not(.is-live) *, .mo:not(.is-live) { animation-play-state: paused !important; }
}
/* 一轮 9s 内的百分比：每个画面在 0–33.3% 可见 */
@keyframes mo-scene { 0% { opacity: 0; } 2.5%, 31% { opacity: 1; } 33.3%, 100% { opacity: 0; } }
@keyframes mo-pop { 0% { transform: translateY(10px) scale(.96); } 5%, 100% { transform: none; } }
@keyframes mo-cur { 0%, 6% { opacity: 0; transform: translate(60px, 40px); } 12% { opacity: 1; } 18% { transform: none; } 20% { transform: scale(.85); } 22%, 30% { opacity: 1; transform: none; } 33%, 100% { opacity: 0; } }
@keyframes mo-press { 0%, 18% { transform: none; box-shadow: none; } 20% { transform: scale(.92); box-shadow: 0 0 0 5px rgb(10 132 255 / .35); } 23%, 100% { transform: none; box-shadow: none; } }
@keyframes mo-dot { 0%, 3% { opacity: 0; } 4%, 100% { opacity: 1; } }
@keyframes mo-dot2 { 0%, 5% { opacity: 0; } 6%, 100% { opacity: 1; } }
@keyframes mo-dot3 { 0%, 7% { opacity: 0; } 8%, 100% { opacity: 1; } }
@keyframes mo-dot4 { 0%, 9% { opacity: 0; } 10%, 100% { opacity: 1; } }
@keyframes mo-dot5 { 0%, 11% { opacity: 0; } 12%, 100% { opacity: 1; } }
@keyframes mo-dot6 { 0%, 13% { opacity: 0; } 14%, 100% { opacity: 1; } }
@keyframes mo-rise { 0%, 15% { opacity: 0; transform: translateY(8px) scale(.9); } 19%, 100% { opacity: 1; transform: none; } }
@keyframes mo-step { 0%, 33% { background: var(--accent-soft); color: var(--accent); } 33.4%, 100% { background: transparent; color: var(--ink-2); } }
@keyframes mo-step-b { 0%, 33% { background: var(--accent); color: var(--accent-ink); border-color: transparent; } 33.4%, 100% { background: var(--surface); color: var(--muted); border-color: var(--line); } }

@media (max-width: 420px) {
  .mo-stage { height: 176px; }
  .mo-set { grid-template-columns: 78px minmax(0, 1fr); }
}

/* ---------- Windows 版（partials/win-open.html）：同一时间轴，画面换成 Windows 11 ---------- */
.wo { --wo-font: "Segoe UI Variable Text", "Segoe UI", "Microsoft YaHei UI", "Microsoft YaHei", var(--font); }
/* 舞台：Windows 11 默认壁纸「Bloom」的蓝色花瓣 + 底部任务栏 */
.wo-stage { font-family: var(--wo-font);
  background: radial-gradient(60% 75% at 62% 58%, #6fb7ff 0%, #2f7cf6 28%, transparent 60%),
    radial-gradient(45% 55% at 40% 70%, rgb(150 200 255 / .75), transparent 65%),
    radial-gradient(90% 90% at 50% 100%, #1146c9, transparent 70%), linear-gradient(160deg, #0a2a7a, #0b1d4f); }
.wo .mo-scene { bottom: 26px; }
.wo-taskbar { position: absolute; left: 0; right: 0; bottom: 0; height: 26px; display: flex; align-items: center; justify-content: center; gap: 6px; padding: 0 8px;
  background: rgb(32 36 52 / .82); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); border-top: 1px solid rgb(255 255 255 / .08); }
.wo-start { display: grid; place-items: center; width: 18px; height: 18px; }
.wo-start svg { width: 13px; height: 13px; fill: #4cc2ff; }
.wo-search { width: 74px; height: 15px; padding-left: 8px; border-radius: 8px; background: rgb(255 255 255 / .1); font-size: 8.5px; line-height: 15px; color: rgb(255 255 255 / .6); }
.wo-tb-app { width: 14px; height: 14px; border-radius: 4px; background: #f3c74b; }
.wo-tb-app.e { background: linear-gradient(135deg, #36c1f1, #0c59a4); border-radius: 50%; }
.wo-clock { position: absolute; right: 10px; font-size: 9px; color: rgb(255 255 255 / .85); }

/* 1–2 SmartScreen 拦截框（Windows 的深蓝色对话框） */
.wo-ss { display: grid; gap: 6px; width: min(270px, 90%); padding: 12px 14px 10px; color: #fff; background: #0a5fb4; box-shadow: 0 14px 34px rgb(0 0 0 / .45); border: 1px solid rgb(255 255 255 / .18); }
.wo-ss b { font-size: 15px; font-weight: 300; letter-spacing: .01em; }
.wo-ss small { font-size: 10px; line-height: 1.45; color: rgb(255 255 255 / .92); }
.wo-more { justify-self: start; font-size: 10.5px; text-decoration: underline; text-underline-offset: 2px; }
.wo-ss-foot { display: flex; justify-content: flex-end; gap: 6px; margin-top: 4px; padding-top: 8px; border-top: 1px solid rgb(255 255 255 / .2); }
.wo-btn { padding: 3px 12px; font-size: 10.5px; border: 1px solid rgb(255 255 255 / .85); }
.wo-cur svg { fill: #fff; stroke: #000; stroke-width: 1.4; }
.wo .mo-a .mo-cur { left: calc(50% - 92px); top: 108px; }
.wo .mo-b .mo-cur { left: calc(50% + 34px); top: 112px; }

/* 3 一键安装进度（Windows 11 窗口）→ 已装好、桌面快捷方式 */
.wo-win { position: absolute; width: min(250px, 86%); border-radius: 8px; overflow: hidden; background: #f3f3f3; color: #1b1b1b; box-shadow: 0 14px 34px rgb(0 0 0 / .45); border: 1px solid rgb(0 0 0 / .1); }
.wo-win-bar { display: flex; align-items: center; gap: 6px; padding: 5px 8px; font-size: 10px; background: #e9eef6; }
.wo-win-bar .as-app-ico { width: 13px; height: 13px; border-radius: 3px; box-shadow: none; }
.wo-caps { margin-left: auto; display: flex; gap: 10px; font-size: 9px; color: #444; }
.wo-caps i { font-style: normal; }
.wo-win-body { display: grid; gap: 8px; padding: 14px 14px 16px; font-size: 10.5px; }
.wo-prog { height: 4px; border-radius: 2px; background: #d6d6d6; overflow: hidden; }
.wo-prog i { display: block; height: 100%; width: 100%; border-radius: inherit; background: #0067c0; transform-origin: left; }
.wo-done { display: grid; justify-items: center; gap: 8px; color: #fff; }
.wo-done b { font-size: 13.5px; font-weight: 600; text-shadow: 0 1px 6px rgb(0 0 0 / .35); }
.wo-short { display: grid; justify-items: center; gap: 4px; padding: 6px 8px; border-radius: 6px; background: rgb(255 255 255 / .16); border: 1px solid rgb(255 255 255 / .25); }
.wo-short .as-app-ico { width: 38px; height: 38px; }
.wo-short small { font-size: 10px; text-shadow: 0 1px 4px rgb(0 0 0 / .5); }
.wo-win { display: none; }
@media (prefers-reduced-motion: no-preference) {
  .wo-win { display: block; animation: wo-hide var(--mo-t) linear infinite; }
  .wo-prog i { animation: wo-prog var(--mo-t) ease-in-out infinite; }
  .wo-done { animation: mo-rise var(--mo-t) ease-out infinite; }
  .wo.mo .mo-c, .wo.mo .mo-c * { animation-delay: calc(var(--mo-t) / -3); }
}
@keyframes wo-hide { 0% { opacity: 0; transform: translateY(8px); } 3%, 15% { opacity: 1; transform: none; } 18%, 100% { opacity: 0; } }
@keyframes wo-prog { 0%, 3% { transform: scaleX(0); } 14%, 100% { transform: scaleX(1); } }
.wo .mo-stage { height: 214px; }
@media (max-width: 420px) { .wo .mo-stage { height: 226px; } }
