body {
      font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei UI", "Microsoft YaHei",
                   "WenQuanYi Micro Hei", "Noto Sans SC", system-ui, -apple-system, sans-serif;
      -webkit-font-smoothing: antialiased;
    }
    html[lang="en"] body {
      font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    }
    html { scroll-behavior: smooth; scroll-padding-top: 5rem; }

    #scroll-progress {
      position: fixed; top: 0; left: 0; height: 3px; width: 0%; z-index: 60;
      background: linear-gradient(90deg, #2563eb, #38bdf8, #818cf8);
      transition: width 0.08s linear;
    }

    .gradient-bg {
      background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 40%, #0ea5e9 100%);
      background-size: 200% 200%;
      animation: gradientShift 12s ease infinite;
    }

    html.dark .gradient-bg {
      background: linear-gradient(135deg, #020617 0%, #0b1224 42%, #172554 100%);
      background-size: 200% 200%;
    }
    @keyframes gradientShift {
      0%, 100% { background-position: 0% 50%; }
      50% { background-position: 100% 50%; }
    }

    .icon-svg {
      width: 1.5rem; height: 1.5rem;
      stroke: currentColor; fill: none; stroke-width: 2;
      stroke-linecap: round; stroke-linejoin: round;
      flex-shrink: 0; pointer-events: none;
    }
    .icon-svg-sm { width: 1rem; height: 1rem; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
    .icon-svg-lg { width: 1.75rem; height: 1.75rem; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

    nav { transition: box-shadow 0.35s ease, background 0.35s ease; }
    nav.scrolled {
      box-shadow: 0 8px 30px -8px rgb(0 0 0 / 0.1);
      background: rgba(255,255,255,0.95);
    }
    html.dark nav.scrolled { background: rgba(15, 23, 42, 0.96); }

    #theme-toggle, #lang-toggle {
      width: 2.25rem; height: 2.25rem;
      display: inline-flex; align-items: center; justify-content: center;
      border-radius: 9999px; color: #475569;
      transition: background 0.2s, color 0.2s;
    }
    #theme-toggle:hover, #lang-toggle:hover { background: #f1f5f9; color: #0f172a; }
    html.dark #theme-toggle, html.dark #lang-toggle { color: #94a3b8; }
    html.dark #theme-toggle:hover, html.dark #lang-toggle:hover { background: #1e293b; color: #f1f5f9; }
    #lang-toggle { font-size: 0.75rem; font-weight: 700; letter-spacing: 0.02em; }
    #theme-toggle .icon-sun { display: none; }
    html.dark #theme-toggle .icon-moon { display: none; }
    html.dark #theme-toggle .icon-sun { display: block; }

    
    .step-num {
      width: 2.5rem; height: 2.5rem;
      border-radius: 0.75rem;
      background: linear-gradient(145deg, #3b82f6, #1d4ed8);
      color: #fff; font-weight: 800; font-size: 1.1rem;
      display: flex; align-items: center; justify-content: center;
      flex-shrink: 0;
      box-shadow: 0 8px 20px -6px rgba(37, 99, 235, 0.45);
      position: relative;
      z-index: 1;
    }

    
    .fade-up {
      opacity: 0; transform: translateY(22px);
      transition: opacity 0.55s cubic-bezier(0.16, 1, 0.3, 1), transform 0.55s cubic-bezier(0.16, 1, 0.3, 1);
    }
    .fade-up.visible { opacity: 1; transform: translateY(0); }
    .fade-up-delay-1 { transition-delay: 0.08s; }
    .fade-up-delay-2 { transition-delay: 0.16s; }
    .fade-up-delay-3 { transition-delay: 0.24s; }
    .fade-up-delay-4 { transition-delay: 0.32s; }

    
    .step-icon-wrap {
      width: 2.75rem; height: 2.75rem;
      border-radius: 0.85rem;
      display: flex; align-items: center; justify-content: center;
      flex-shrink: 0;
      animation: iconFloat 2.6s ease-in-out infinite;
    }
    .step-icon-wrap.d2 { animation-delay: 0.35s; }
    .step-icon-wrap.d3 { animation-delay: 0.7s; }
    .step-icon-wrap.d4 { animation-delay: 1.05s; }
    @keyframes iconFloat {
      0%, 100% { transform: translateY(0); }
      50% { transform: translateY(-6px); }
    }
    .step-icon-wrap .icon-svg-lg {
      animation: iconSoftPulse 2.2s ease-in-out infinite;
    }
    @keyframes iconSoftPulse {
      0%, 100% { opacity: 1; transform: scale(1); }
      50% { opacity: 0.7; transform: scale(1.1); }
    }
    .guide-card:hover .step-icon-wrap {
      animation-play-state: paused;
      transform: scale(1.08);
    }

    .step-icon-wrap.red { background: #fef2f2; color: #dc2626; }
    .step-icon-wrap.blue { background: #eff6ff; color: #2563eb; }
    .step-icon-wrap.emerald { background: #ecfdf5; color: #059669; }
    .step-icon-wrap.violet { background: #f5f3ff; color: #7c3aed; }
    html.dark .step-icon-wrap.red { background: rgba(127,29,29,0.35); color: #fca5a5; }
    html.dark .step-icon-wrap.blue { background: rgba(30,58,138,0.4); color: #93c5fd; }
    html.dark .step-icon-wrap.emerald { background: rgba(6,78,59,0.4); color: #6ee7b7; }
    html.dark .step-icon-wrap.violet { background: rgba(76,29,149,0.35); color: #c4b5fd; }

    
    .step-num::after {
      content: '';
      position: absolute;
      inset: -4px;
      border-radius: 0.95rem;
      border: 2px solid rgba(37, 99, 235, 0.4);
      animation: stepRing 2s ease-out infinite;
      pointer-events: none;
    }
    @keyframes stepRing {
      0% { transform: scale(1); opacity: 0.75; }
      100% { transform: scale(1.4); opacity: 0; }
    }
    .hero-badge-dot {
      animation: badgeBlink 1.5s ease-in-out infinite;
    }
    @keyframes badgeBlink {
      0%, 100% { opacity: 1; transform: scale(1); }
      50% { opacity: 0.35; transform: scale(0.8); }
    }

    .mock-added {
      animation: addedFlash 1.6s ease-in-out infinite;
    }
    @keyframes addedFlash {
      0%, 100% { opacity: 1; }
      50% { opacity: 0.35; }
    }
    .mock-add-btn {
      animation: addBtnPulse 2s ease-in-out infinite;
    }
    @keyframes addBtnPulse {
      0%, 100% { border-color: rgba(59, 130, 246, 0.4); box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.15); }
      50% { border-color: rgba(37, 99, 235, 0.95); box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12); }
    }

    @media (prefers-reduced-motion: reduce) {
      .fade-up { opacity: 1; transform: none; transition: none; }
      .step-icon-wrap,
      .step-icon-wrap .icon-svg-lg,
      .step-num::after,
      .hero-badge-dot,
      .mock-added,
      .mock-add-btn,
      .win-row.highlight,
      .win-toggle.anim-off,
      .win-toggle.anim-off::after,
      .av-tag {
        animation: none !important;
      }
    }

    
    .av-tag {
      display: inline-flex; align-items: center; gap: 0.4rem;
      padding: 0.45rem 0.85rem;
      border-radius: 9999px;
      background: #fef2f2; color: #b91c1c;
      border: 1px solid #fecaca;
      font-size: 0.8125rem; font-weight: 500;
      animation: tagPop 0.45s cubic-bezier(0.16, 1, 0.3, 1) both;
    }
    .av-tag:nth-child(1) { animation-delay: 0.05s; }
    .av-tag:nth-child(2) { animation-delay: 0.1s; }
    .av-tag:nth-child(3) { animation-delay: 0.15s; }
    .av-tag:nth-child(4) { animation-delay: 0.2s; }
    .av-tag:nth-child(5) { animation-delay: 0.25s; }
    .av-tag:nth-child(6) { animation-delay: 0.3s; }
    .av-tag:nth-child(7) { animation-delay: 0.35s; }
    .av-tag:nth-child(8) { animation-delay: 0.4s; }
    @keyframes tagPop {
      from { opacity: 0; transform: scale(0.88) translateY(8px); }
      to { opacity: 1; transform: scale(1) translateY(0); }
    }
    .av-tag-static {
      display: inline-flex; align-items: center; gap: 0.4rem;
      padding: 0.45rem 0.85rem;
      border-radius: 9999px;
      background: #fef2f2; color: #b91c1c;
      border: 1px solid #fecaca;
      font-size: 0.8125rem; font-weight: 500;
    }
    html.dark .av-tag {
      background: rgba(127, 29, 29, 0.35); color: #fca5a5; border-color: rgba(248, 113, 113, 0.3);
    }
    .av-ok {
      background: #ecfdf5; color: #047857; border-color: #a7f3d0;
    }
    html.dark .av-ok {
      background: rgba(6, 78, 59, 0.4); color: #6ee7b7; border-color: rgba(52, 211, 153, 0.3);
    }

    
    .win-panel {
      background: #f3f3f3;
      border-radius: 0.75rem;
      border: 1px solid #e5e5e5;
      overflow: hidden;
      box-shadow: 0 12px 40px -12px rgba(0,0,0,0.18);
      font-family: "Segoe UI", system-ui, sans-serif;
    }
    html.dark .win-panel {
      background: #1e1e1e; border-color: #333;
    }
    .win-titlebar {
      background: #fff; padding: 0.65rem 1rem;
      border-bottom: 1px solid #e5e5e5;
      display: flex; align-items: center; gap: 0.6rem;
      font-size: 0.8rem; color: #1a1a1a; font-weight: 600;
    }
    html.dark .win-titlebar {
      background: #2d2d2d; border-color: #404040; color: #f0f0f0;
    }
    .win-dot { width: 0.55rem; height: 0.55rem; border-radius: 50%; }
    .win-body { padding: 1rem 1.1rem; }
    .win-row {
      display: flex; align-items: center; justify-content: space-between;
      padding: 0.7rem 0.85rem;
      background: #fff; border-radius: 0.5rem;
      margin-bottom: 0.5rem;
      border: 1px solid #eee;
      transition: border-color 0.25s, box-shadow 0.25s;
    }
    html.dark .win-row {
      background: #2a2a2a; border-color: #3a3a3a; color: #e5e5e5;
    }
    .win-row.highlight {
      border-color: #2563eb;
      box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.25);
      animation: rowPulse 2s ease-in-out infinite;
    }
    @keyframes rowPulse {
      0%, 100% { box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.2); }
      50% { box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.35); }
    }
    .win-toggle {
      width: 2.5rem; height: 1.35rem; border-radius: 9999px;
      background: #2563eb; position: relative; flex-shrink: 0;
      transition: background 0.3s;
    }
    .win-toggle.off { background: #a1a1aa; }
    .win-toggle::after {
      content: ''; position: absolute; top: 0.15rem; right: 0.15rem;
      width: 1.05rem; height: 1.05rem; border-radius: 50%; background: #fff;
      transition: transform 0.3s;
    }
    .win-toggle.off::after { right: auto; left: 0.15rem; }
    .win-toggle.anim-off {
      animation: toggleOff 2s ease-in-out infinite;
    }
    @keyframes toggleOff {
      0%, 35% { background: #2563eb; }
      50%, 100% { background: #a1a1aa; }
    }
    .win-toggle.anim-off::after {
      animation: knobMove 2s ease-in-out infinite;
    }
    @keyframes knobMove {
      0%, 35% { left: auto; right: 0.15rem; }
      50%, 100% { right: auto; left: 0.15rem; }
    }
    
    .mock-added {
      animation: addedFlash 1.8s ease-in-out infinite;
    }
    @keyframes addedFlash {
      0%, 100% { opacity: 1; }
      50% { opacity: 0.4; }
    }
    
    .mock-add-btn {
      animation: addBtnPulse 2.2s ease-in-out infinite;
    }
    @keyframes addBtnPulse {
      0%, 100% { border-color: rgba(59, 130, 246, 0.45); box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.2); }
      50% { border-color: rgba(37, 99, 235, 0.9); box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12); }
    }

    .path-chip {
      display: inline-block;
      font-family: ui-monospace, "Cascadia Code", Consolas, monospace;
      font-size: 0.75rem;
      background: #eff6ff; color: #1d4ed8;
      border: 1px solid #bfdbfe;
      padding: 0.2rem 0.55rem; border-radius: 0.35rem;
    }
    html.dark .path-chip {
      background: rgba(30, 58, 138, 0.4); color: #93c5fd; border-color: rgba(59, 130, 246, 0.35);
    }

    .guide-card {
      border: 1px solid #e2e8f0; border-radius: 1.25rem;
      background: #fff; overflow: hidden;
      transition: border-color 0.3s, box-shadow 0.3s;
    }
    html.dark .guide-card {
      background: #0f172a; border-color: #1e293b;
    }
    .guide-card:hover {
      border-color: rgba(37, 99, 235, 0.35);
      box-shadow: 0 16px 40px -16px rgba(37, 99, 235, 0.15);
    }

    .breadcrumb a { color: #64748b; }
    .breadcrumb a:hover { color: #2563eb; }

    html.dark footer { border-color: #1e293b; }
    html.dark .tip-box { background: #0f172a; border-color: #1e293b; }

    #back-to-top {
      position: fixed;
      right: calc(1.25rem + env(safe-area-inset-right, 0px));
      bottom: calc(1.5rem + env(safe-area-inset-bottom, 0px));
      z-index: 40;
      width: 2.75rem;
      height: 2.75rem;
      border-radius: 9999px;
      background: #2563eb;
      color: #fff;
      display: flex;
      align-items: center;
      justify-content: center;
      box-shadow: 0 8px 24px -6px rgb(37 99 235 / 0.45);
      opacity: 0;
      visibility: hidden;
      transform: translateY(12px) scale(0.9);
      transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), background 0.2s ease;
      -webkit-tap-highlight-color: transparent;
      border: none;
      cursor: pointer;
    }
    #back-to-top.visible {
      opacity: 1;
      visibility: visible;
      transform: translateY(0) scale(1);
    }
    #back-to-top:hover {
      background: #1d4ed8;
      transform: translateY(-2px) scale(1.05);
    }
    #back-to-top:active {
      transform: scale(0.95);
    }
    html.dark #back-to-top {
      background: #3b82f6;
      box-shadow: 0 8px 24px -6px rgb(59 130 246 / 0.5);
    }
    html.dark #back-to-top:hover {
      background: #2563eb;
    }

    @media (prefers-reduced-motion: reduce) {
      .win-row.highlight, .win-toggle.anim-off, .win-toggle.anim-off::after, .gradient-bg {
        animation: none !important;
      }
    }
  
    
    .js-anim-root.is-offscreen,
    .js-anim-root.is-offscreen * {
      animation-play-state: paused !important;
    }
