:root{
    --bg:#f3f6fb;
    --panel:#ffffff;
    --ink:#10213b;
    --muted:#6f7c91;
    --line:#dce4f1;
    --grid:#eaf0f8;
    --blue:#1f5eff;
    --purple:#7b4ce2;
    --teal:#0d899a;
    --green:#23884a;
    --orange:#e98b50;
    --pink:#d56ba8;
    --red:#d63d4f;
    --shadow:0 12px 32px rgba(40,72,120,.08);
  }
  *{box-sizing:border-box}
  html,body{margin:0;background:
      radial-gradient(circle at 85% 5%, rgba(123,76,226,.08), transparent 25%),
      linear-gradient(180deg,#f6f8fc,#eef3f9);
      color:var(--ink);font-family:Inter,ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI","PingFang SC","Hiragino Sans GB","Microsoft YaHei",Arial,sans-serif}
  body{padding:18px}
  .app{max-width:1920px;margin:0 auto;background:var(--panel);border:1px solid #d8e1ef;border-radius:30px;box-shadow:var(--shadow);overflow:hidden}
  .header{display:flex;justify-content:space-between;gap:20px;align-items:flex-start;padding:34px 34px 22px}
  .eyebrow{font-size:13px;font-weight:800;color:var(--blue);letter-spacing:.12em;text-transform:uppercase;margin-bottom:8px}
  h1{font-size:38px;line-height:1.08;margin:0 0 10px;letter-spacing:-.03em}
  .subtitle{color:var(--muted);font-size:16px;line-height:1.65;max-width:960px}
  .header-actions{display:flex;gap:10px;align-items:center;flex-wrap:wrap;justify-content:flex-end}
  button,.select{
    border:1px solid #d9e1ef;background:#fff;color:#21324d;border-radius:14px;padding:11px 14px;
    font-weight:800;font-size:14px;cursor:pointer;transition:.2s ease;box-shadow:0 4px 12px rgba(20,50,90,.04)
  }
  button:hover{transform:translateY(-1px);border-color:#b7c6df}
  .primary{background:var(--blue);color:#fff;border-color:var(--blue);box-shadow:0 10px 20px rgba(31,94,255,.22)}
  .danger-lite{color:var(--red)}
  .toolbar{display:flex;align-items:center;gap:10px;flex-wrap:wrap;padding:0 34px 18px}
  .chip{
    border:1px solid #dfe7f3;background:#f8fafc;border-radius:999px;padding:8px 12px;color:#5f6d82;
    font-weight:800;font-size:13px;cursor:pointer;transition:.2s
  }
  .chip.active{background:#eef3ff;color:var(--blue);border-color:#bfcfff}
  .legend{margin-left:auto;display:flex;gap:14px;align-items:center;color:#7a879a;font-size:12px;font-weight:700}
  .legend i{display:inline-block;width:28px;height:4px;border-radius:99px;vertical-align:middle;margin-right:6px}
  .legend .g{background:#dfe6f0}.legend .b{background:var(--blue)}
  .stage-wrap{padding:0 28px 28px}
  .stage{
    position:relative;min-height:950px;overflow:auto;border:1px solid #dae3f0;border-radius:24px;
    background-color:#fbfdff;
    background-image:
      linear-gradient(var(--grid) 1px,transparent 1px),
      linear-gradient(90deg,var(--grid) 1px,transparent 1px);
    background-size:28px 28px;
  }
  .canvas{position:relative;min-width:2520px;min-height:930px;padding:26px}
  .group{
    position:absolute;border:1px dashed #c9d6e9;border-radius:24px;background:rgba(255,255,255,.48);
    pointer-events:none;transition:.25s
  }
  .group-title{
    position:absolute;left:18px;top:-13px;background:#fbfdff;padding:0 10px;font-size:12px;font-weight:900;letter-spacing:.08em
  }
  .group.basic{left:260px;top:315px;width:520px;height:280px}
  .group.offline{left:820px;top:38px;width:950px;height:270px}
  .group.online{left:820px;top:335px;width:1375px;height:280px}
  .group.ops{left:1450px;top:655px;width:785px;height:230px}
  .group.basic .group-title{color:var(--purple)}
  .group.offline .group-title{color:var(--teal)}
  .group.online .group-title{color:var(--blue)}
  .group.ops .group-title{color:var(--green)}

  #edges{position:absolute;inset:0;width:100%;height:100%;pointer-events:none;overflow:visible}
  .edge{fill:none;stroke:#dfe6f0;stroke-width:5;stroke-linecap:round;stroke-linejoin:round;transition:.25s}
  .edge.active{stroke:var(--blue);filter:drop-shadow(0 3px 4px rgba(31,94,255,.18))}
  .edge.optional{stroke-dasharray:10 10}
  .edge-label{font-size:12px;font-weight:900;fill:#7d8ba0}
  .node{
    position:absolute;width:230px;min-height:160px;padding:18px 18px 16px;background:#fff;border:2px solid var(--c,#90a4c5);
    border-radius:22px;box-shadow:0 12px 24px rgba(44,70,108,.06);transition:.26s ease;cursor:pointer;z-index:2
  }
  .node:hover{transform:translateY(-4px);box-shadow:0 18px 38px rgba(35,64,106,.12)}
  .node.dim{opacity:.22;filter:saturate(.25)}
  .node.current{
    transform:translateY(-7px) scale(1.025);
    box-shadow:0 0 0 7px color-mix(in srgb,var(--c) 12%,transparent),0 22px 45px rgba(31,94,255,.16)
  }
  .node.visited{box-shadow:0 0 0 5px rgba(31,94,255,.07),0 16px 30px rgba(44,70,108,.08)}
  .topline{display:flex;align-items:center;gap:8px;margin-bottom:10px}
  .badge{background:var(--c);color:#fff;border-radius:9px;padding:4px 7px;font-size:12px;font-weight:900}
  .kind{color:var(--c);font-size:12px;font-weight:900}
  .node h3{margin:0 0 8px;font-size:20px;line-height:1.2;letter-spacing:-.02em}
  .node p{margin:0;color:#6c788b;line-height:1.5;font-size:13px}
  .tags{display:flex;gap:7px;flex-wrap:wrap;margin-top:12px}
  .tag{background:color-mix(in srgb,var(--c) 10%,white);color:var(--c);border-radius:999px;padding:5px 8px;font-size:11px;font-weight:900}
  .root{
    width:185px;min-height:240px;display:flex;flex-direction:column;justify-content:center;left:42px;top:350px;
    --c:var(--blue);background:linear-gradient(180deg,#fff,#f6f8ff)
  }
  .root h3{font-size:26px}
  .root p{font-size:14px}
  .n1{left:300px;top:370px;--c:var(--purple)}
  .n2{left:555px;top:370px;--c:var(--purple)}
  .n3{left:860px;top:82px;--c:var(--teal)}
  .n4{left:1120px;top:82px;--c:var(--teal)}
  .n5{left:1380px;top:82px;--c:var(--teal)}
  .n6{left:860px;top:380px;--c:var(--blue)}
  .n7{left:1120px;top:380px;--c:var(--blue)}
  .n8{left:1380px;top:380px;--c:var(--blue)}
  .n9{left:1640px;top:380px;--c:var(--blue)}
  .n10{left:1900px;top:380px;--c:var(--blue)}
  .n11{left:1490px;top:700px;--c:var(--green)}
  .n12{left:1750px;top:700px;--c:var(--green)}
  .n13{left:2010px;top:700px;--c:var(--orange)}
  .diagnostic{
    position:absolute;left:835px;top:632px;width:570px;padding:12px 16px;border:1px solid #cbd7ea;background:#fff;border-radius:15px;
    color:#536178;font-weight:800;font-size:12px;z-index:1;box-shadow:0 7px 18px rgba(45,72,110,.05)
  }
  .diagnostic b{color:var(--blue)}
  .progressbar{height:4px;background:#edf1f7;margin:0 34px 18px;border-radius:99px;overflow:hidden}
  .progressbar span{display:block;height:100%;width:0;background:linear-gradient(90deg,var(--blue),#7b4ce2);transition:width .25s}
  .drawer{
    position:fixed;right:22px;top:22px;bottom:22px;width:min(520px,calc(100vw - 44px));background:#fff;border:1px solid #dbe4f0;border-radius:26px;
    box-shadow:0 28px 75px rgba(26,48,83,.22);z-index:20;transform:translateX(calc(100% + 48px));transition:.3s ease;overflow:auto
  }
  .drawer.open{transform:translateX(0)}
  .drawer-head{position:sticky;top:0;background:rgba(255,255,255,.95);backdrop-filter:blur(10px);padding:22px 24px 15px;border-bottom:1px solid #edf1f6;z-index:2}
  .drawer-head-row{display:flex;justify-content:space-between;gap:10px;align-items:start}
  .drawer .num{display:inline-flex;background:#eef3ff;color:var(--blue);border-radius:10px;padding:5px 9px;font-weight:900;font-size:12px;margin-bottom:8px}
  .drawer h2{margin:0;font-size:26px;letter-spacing:-.02em}
  .close{border:none;background:#f3f6fa;border-radius:12px;padding:9px 11px;box-shadow:none}
  .drawer-body{padding:20px 24px 36px}
  .drawer-body h4{margin:20px 0 8px;font-size:14px;color:#2a3a54}
  .drawer-body ul{margin:0;padding-left:19px;color:#5e6c81}
  .drawer-body li{margin:7px 0;line-height:1.55}

  .drawer-body h4{
    display:flex;align-items:center;gap:8px;margin:22px 0 9px;font-size:14px;color:#263954
  }
  .drawer-body h4::before{
    content:"";width:4px;height:16px;border-radius:99px;background:var(--blue);display:inline-block
  }
  .interview-title{
    margin:30px 0 12px;padding-top:20px;border-top:1px solid #e8eef6;font-size:18px;color:#172b48
  }
  .qa-card{
    border:1px solid #e1e8f3;background:linear-gradient(180deg,#fbfdff,#f7f9fc);
    border-radius:16px;padding:14px 15px;margin:10px 0;box-shadow:0 5px 14px rgba(37,63,99,.04)
  }
  .qa-q{font-weight:900;color:#20334f;line-height:1.55;margin-bottom:7px}
  .qa-q::before{content:"Q";display:inline-grid;place-items:center;width:22px;height:22px;margin-right:8px;border-radius:7px;background:#eef3ff;color:var(--blue);font-size:11px}
  .qa-a{color:#5c6c82;line-height:1.65;font-size:13px;padding-left:30px}
  .qa-a b{color:#23884a}


  .teach-badge{
    display:inline-block;margin-top:9px;padding:6px 9px;border-radius:999px;
    background:#f2f6ff;color:#4566a8;font-size:11px;font-weight:900
  }
  .drawer-body code{
    background:#eef3f8;border:1px solid #dde6f0;border-radius:6px;padding:1px 5px;
    font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono",monospace;font-size:.92em
  }
  .drawer-body h4:nth-of-type(n){
    scroll-margin-top:90px;
  }


  .key-point{
    position:relative;
    padding:8px 10px 8px 12px;
    margin:7px 0;
    border-radius:10px;
    background:
      linear-gradient(180deg,transparent 18%,rgba(255,238,130,.48) 18%,rgba(255,238,130,.48) 82%,transparent 82%);
  }
  .key-point::before{
    content:"重点";
    display:inline-block;
    margin-right:7px;
    padding:2px 6px;
    border-radius:999px;
    background:linear-gradient(90deg,#ffe980,#ffd0e6,#cfe5ff);
    color:#5b4b2f;
    font-size:10px;
    font-weight:900;
    vertical-align:1px;
  }
  .hl-yellow,.hl-pink,.hl-blue,.hl-green{
    font-weight:900;
    padding:0 .08em;
    border-radius:3px;
    -webkit-box-decoration-break:clone;
    box-decoration-break:clone;
  }
  .hl-yellow{background:linear-gradient(180deg,transparent 56%,rgba(255,225,95,.72) 56%)}
  .hl-pink{background:linear-gradient(180deg,transparent 56%,rgba(255,169,205,.60) 56%)}
  .hl-blue{background:linear-gradient(180deg,transparent 56%,rgba(147,199,255,.56) 56%)}
  .hl-green{background:linear-gradient(180deg,transparent 56%,rgba(148,226,181,.55) 56%)}
  .u-key{
    font-weight:900;
    text-decoration:underline;
    text-decoration-thickness:2px;
    text-underline-offset:3px;
    text-decoration-color:#5f7fe8;
  }

  details.example-section{
    margin:16px 0 6px;
    border:1px solid #e4eaf3;
    border-radius:15px;
    background:#fbfcfe;
    overflow:hidden;
  }
  details.example-section summary{
    list-style:none;
    cursor:pointer;
    user-select:none;
    padding:13px 15px;
    font-weight:900;
    color:#34445f;
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:10px;
  }
  details.example-section summary::-webkit-details-marker{display:none}
  details.example-section summary::after{
    content:"点击展开";
    flex:0 0 auto;
    font-size:11px;
    color:#6a7b92;
    background:#eef3f8;
    border-radius:999px;
    padding:4px 8px;
  }
  details.example-section[open] summary::after{content:"收起例子"}
  .example-content{
    padding:0 15px 14px 15px;
    border-top:1px solid #edf1f6;
  }
  .example-content ul{margin-top:12px}
  .example-content li{
    margin:9px 0;
    line-height:1.65;
  }
  .example-tip{
    margin:12px 0 0;
    font-size:11px;
    color:#8290a4;
  }

  .code-example{
    margin:14px 0 4px;border:1px solid #273a50;border-radius:14px;overflow:hidden;
    background:#111c2b;color:#dce8f5;box-shadow:0 8px 18px rgba(23,43,69,.1)
  }
  .code-example-head{display:flex;justify-content:space-between;gap:12px;padding:10px 12px;background:#1a2a40;border-bottom:1px solid rgba(255,255,255,.1)}
  .code-example-head strong{font-size:12px;color:#fff}
  .code-example-head span{font:10px ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;color:#92c9ff;text-transform:uppercase}
  .code-example p{margin:0;padding:9px 12px;color:#aebed0;font-size:11px;line-height:1.55}
  .code-example pre{margin:0;padding:13px 12px 16px;overflow-x:auto;border-top:1px solid rgba(255,255,255,.08);background:#0c1522}
  .code-example pre code{padding:0;border:0;background:transparent;color:#dce8f5;font:11px/1.65 ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono",monospace;white-space:pre}


  .global-case{
    margin:0 34px 18px;
    border:1px solid #d8e4f5;
    border-radius:18px;
    padding:15px 17px;
    background:
      linear-gradient(135deg,rgba(238,244,255,.95),rgba(252,248,255,.95));
    box-shadow:0 8px 20px rgba(44,72,110,.04)
  }
  .global-case-badge{
    display:inline-block;padding:4px 8px;border-radius:999px;
    background:linear-gradient(90deg,#ffe980,#ffd8ea,#d7e8ff);
    color:#514a65;font-size:10px;font-weight:900;margin-bottom:7px
  }
  .global-case-title{font-size:15px;font-weight:950;color:#203653;margin-bottom:5px}
  .global-case-text{font-size:13px;line-height:1.65;color:#66758b}
  .global-case-tags{display:flex;gap:7px;flex-wrap:wrap;margin-top:9px}
  .global-case-tags span{
    padding:5px 8px;border-radius:999px;background:#fff;border:1px solid #e1e8f3;
    color:#63728a;font-size:11px;font-weight:800
  }

  .playbook{
    margin:0 34px 18px;border:1px solid #dce5f2;border-radius:20px;background:#fff;
    box-shadow:0 8px 20px rgba(44,72,110,.04);overflow:hidden
  }
  .playbook summary{
    list-style:none;cursor:pointer;display:flex;align-items:center;justify-content:space-between;gap:16px;
    padding:15px 17px;font-weight:950;color:#203653;background:linear-gradient(90deg,#fbfdff,#f7f9ff)
  }
  .playbook summary::-webkit-details-marker{display:none}
  .playbook summary::after{
    content:"展开速查";flex:0 0 auto;padding:5px 9px;border-radius:999px;background:#eef3ff;
    color:var(--blue);font-size:11px;font-weight:900
  }
  .playbook[open] summary::after{content:"收起速查"}
  .playbook-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;padding:0 16px 16px}
  .playbook-card{border:1px solid #e3eaf4;border-radius:16px;padding:14px;background:#fbfcfe}
  .playbook-card h3{margin:0 0 10px;font-size:14px;color:#243a59}
  .playbook-card ol,.playbook-card ul{margin:0;padding-left:19px;color:#64738a;font-size:12px;line-height:1.62}
  .playbook-card li{margin:6px 0}
  .playbook-card b{color:#243a59}
  .route-table{width:100%;border-collapse:collapse;font-size:12px;color:#64738a}
  .route-table th,.route-table td{padding:7px 6px;border-bottom:1px solid #e8edf5;text-align:left;vertical-align:top;line-height:1.45}
  .route-table th{color:#344b69;font-size:11px}
  .route-table tr:last-child td{border-bottom:0}
  .route-table strong{color:var(--blue)}

  .footer-note{padding:0 34px 30px;color:#8190a4;font-size:12px;line-height:1.6}
  .hint{font-weight:900;color:#4a5b74}
  @media (max-width:980px){
    body{padding:8px}.app{border-radius:20px}.header{padding:24px 20px 16px;display:block}
    h1{font-size:30px}.header-actions{justify-content:flex-start;margin-top:16px}.toolbar{padding:0 20px 14px}
    .legend{width:100%;margin-left:0}.stage-wrap{padding:0 10px 14px}.progressbar{margin:0 20px 14px}
    .global-case,.playbook{margin-left:20px;margin-right:20px}.playbook-grid{grid-template-columns:1fr}
  }
