/* /features/workflows — 12 section, mockup bằng HTML. Tiền tố .wf- (chỉ nạp ở trang này). */

/* ---- 1. hero ---- */
.wf-hero .pp-hero-in { padding-top: 62px; }
.wf-stage { position: relative; height: 448px; max-width: 1240px; margin: 0 auto; }
.wf-mascot { position: absolute; left: 5%; bottom: -8px; height: 330px; width: auto; z-index: 3;
  filter: drop-shadow(0 26px 44px rgba(0,0,0,.55)); }
.wf-flow { position: absolute; right: 4%; bottom: 118px; display: flex; align-items: center; gap: 10px; z-index: 4; }
.wf-flow-chip { display: inline-flex; align-items: center; gap: 8px; padding: 10px 14px; border-radius: 13px;
  font-size: 12.5px; color: #e9e9ee; background: rgba(28,27,22,.9); border: 1px solid #3a362c;
  box-shadow: 0 14px 30px rgba(0,0,0,.35); }
.wf-flow-chip.wf-trigger { border-color: rgba(45,212,191,.45); }
.wf-flow-chip.wf-generate { border-color: rgba(255,122,26,.45); }
.wf-flow-chip.wf-dest { border-color: rgba(200,247,81,.4); }
.wf-flow-arrow { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; color: #cfcabb;
  border: 1px dashed rgba(255,255,255,.28); }
.wf-flow-arrow .ic { width: 12px; height: 12px; }
.wf-spark { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 7px; color: #141311;
  background: var(--pink); flex: 0 0 auto; }
.wf-spark .ic { width: 13px; height: 13px; }

/* ---- 2. how it works ---- */
.wf-diagram { position: relative; z-index: 2; display: grid; grid-template-columns: 1fr 340px 1fr; gap: 24px;
  align-items: center; max-width: 1100px; margin: 0 auto; }
.wf-col { display: grid; gap: 11px; }
.wf-col > small { font-size: 9.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--pp-mute); }
.wf-col-out { justify-items: stretch; }
.wf-sig { display: flex; align-items: center; gap: 9px; padding: 15px 14px; border-radius: 12px; font-size: 12.5px;
  color: var(--pp-ink); background: var(--pp-card); border: 1px solid var(--pp-line); }
.wf-sig.in { border-left: 2px solid var(--teal); }
.wf-out { border-right: 2px solid var(--orange); }
.wf-sig-ic { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 7px; color: var(--orange);
  background: rgba(255,122,26,.14); flex: 0 0 auto; }
.wf-sig-ic .ic { width: 13px; height: 13px; }
.wf-mid { display: grid; justify-items: center; gap: 10px; position: relative; }
.wf-head { width: 330px; height: auto; filter: drop-shadow(0 20px 40px rgba(255,122,26,.22)); }
.wf-gen-real { display: inline-flex; align-items: center; gap: 8px; padding: 9px 14px; border-radius: 12px; font-size: 12.5px;
  color: #f5f5f6; background: #1f1a12; border: 1px solid rgba(200,247,81,.4); box-shadow: 0 0 30px rgba(200,247,81,.12); }
.wf-three { position: relative; z-index: 2; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 34px; }
.wf-num { padding: 24px; min-height: 220px; }
.wf-num span { display: block; margin-bottom: 34px; font: 700 11px/1 ui-monospace, monospace; color: var(--orange); }
.wf-num h3 { font-size: 15.5px; }

/* ---- 3. triggers ---- */
.wf-trigs { position: relative; z-index: 2; display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.wf-trig { padding: 24px; }
.wf-trig.wf-card-wide { grid-column: 1 / 2; }
.wf-trig.wf-card-soon { grid-column: 2 / 3; border-style: dashed; }
.wf-trig-h { display: flex; align-items: center; gap: 9px; }
.wf-trig-h span { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 7px;
  font: 700 10px/1 ui-monospace, monospace; color: #141311; background: var(--orange); }
.wf-trig-h h3 { font-size: 16.5px; }
.wf-soon { margin-left: auto; font-style: normal; font-size: 9px; font-weight: 700; letter-spacing: .1em;
  text-transform: uppercase; padding: 3px 7px; border-radius: 5px; color: #141311; background: var(--pink); }
.wf-trig > p { margin: 8px 0 12px; font-size: 13px; line-height: 1.5; color: var(--pp-mute); }
.wf-trig-note { margin: 14px 0 0 !important; padding: 12px 14px; border-radius: 10px; font-size: 11.5px !important;
  line-height: 1.55 !important; color: var(--pp-mute); background: rgba(255,255,255,.03); border: 1px dashed var(--pp-line); }
.wf-trig ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 7px; }
.wf-trig li { display: flex; align-items: center; gap: 8px; padding: 7px 9px; border-radius: 8px; font-size: 12px;
  color: var(--pp-ink); background: rgba(255,255,255,.04); border: 1px solid var(--pp-line); }
.wf-li-ic { display: grid; place-items: center; width: 20px; height: 20px; border-radius: 6px; color: var(--teal);
  background: rgba(45,212,191,.14); flex: 0 0 auto; }
.wf-li-ic .ic { width: 12px; height: 12px; }
.wf-trig.wf-card-wide ul { grid-template-columns: 1fr 1fr; }
.wf-footbar { position: relative; z-index: 2; max-width: 900px; margin: 22px auto 0; padding: 12px 16px; border-radius: 12px;
  text-align: center; font-size: 12px; line-height: 1.6; color: var(--pp-mute); background: rgba(255,255,255,.03);
  border: 1px solid var(--pp-line); }

/* ---- 4. steps ---- */
.wf-pillstrip { position: relative; z-index: 2; margin: -10px 0 26px; padding: 12px 0; overflow: hidden;
  border-top: 1px solid var(--pp-line); border-bottom: 1px solid var(--pp-line);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); }
.wf-pilltrack { display: flex; gap: 8px; width: max-content; animation: wf-scroll 34s linear infinite; }
.wf-pill { padding: 7px 13px; border-radius: 999px; font-size: 12px; color: var(--pp-ink); background: var(--pp-card);
  border: 1px solid var(--pp-line); white-space: nowrap; }
@keyframes wf-scroll { to { transform: translateX(-50%); } }
.wf-stepgrid { position: relative; z-index: 2; display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.wf-stepcol { display: grid; align-content: start; gap: 9px; }
.wf-stepcol > small { font-size: 9.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--orange); }
.wf-step { padding: 18px; border-radius: 12px; background: var(--pp-card); border: 1px solid var(--pp-line); min-height: 150px; }
.wf-step b { font-size: 13.5px; }
.wf-step p { margin: 4px 0 0; font-size: 11.5px; line-height: 1.5; color: var(--pp-mute); }
.pp-side-mascot.wf-steps-mascot { right: 16px; top: -6px; height: 104px; width: auto; transform: rotate(6deg); }

/* ---- 5. write once ---- */
.wf-chain { display: grid; gap: 7px; padding: 16px; border-radius: 18px; background: #15140f; border: 1px solid #34312a;
  color: #f5f5f6; box-shadow: 0 30px 70px rgba(0,0,0,.4); }
.wf-chain-h { display: flex; align-items: center; justify-content: space-between; padding-bottom: 10px;
  border-bottom: 1px solid #2c2921; }
.wf-chain-h b { font-size: 13px; }
.wf-chain-h span { font-size: 10px; letter-spacing: .1em; text-transform: uppercase; color: #8f8b80; }
.wf-chain-row { display: grid; grid-template-columns: 24px 1fr 24px; align-items: center; gap: 10px; padding: 8px 11px;
  border-radius: 10px; background: #1b1a14; border: 1px solid #2c2921; font-size: 12px; }
.wf-chain-row b { font-size: 12.5px; }
.wf-chain-row small { display: block; font-size: 10.5px; color: #8f8b80; }
.wf-chain-n { display: grid; place-items: center; width: 20px; height: 20px; border-radius: 6px;
  font: 700 10px/1 ui-monospace, monospace; color: #141311; background: var(--orange); }

/* ---- 6. data down the line ---- */
.wf-data { position: relative; z-index: 2; display: grid; grid-template-columns: 1fr 1fr; gap: 16px; max-width: 1020px;
  margin: 0 auto; }
.wf-prompt, .wf-testbox { padding: 18px; border-radius: 16px; background: var(--pp-card); border: 1px solid var(--pp-line); }
.wf-prompt { display: grid; gap: 8px; }
.wf-prompt-h { display: flex; align-items: center; gap: 8px; }
.wf-prompt-h b { font-size: 13.5px; }
.wf-prompt small { font-size: 9.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--pp-mute); }
.wf-prompt p { margin: 0; padding: 12px; border-radius: 10px; font-size: 12.5px; line-height: 1.6; color: var(--pp-ink);
  background: rgba(255,255,255,.04); border: 1px solid var(--pp-line); }
.wf-prompt mark { padding: 1px 4px; border-radius: 4px; background: rgba(255,122,26,.25); color: var(--pp-ink); }
.wf-tokens { display: flex; flex-wrap: wrap; gap: 6px; }
.wf-token { padding: 4px 8px; border-radius: 6px; font: 11px/1.4 ui-monospace, monospace; color: #7ee6d8;
  background: rgba(45,212,191,.1); border: 1px solid rgba(45,212,191,.3); }
html[data-theme="light"] .wf-token { color: #0b5f55; background: rgba(45,212,191,.16); border-color: rgba(45,212,191,.5); }
.wf-hand { display: flex; align-items: center; gap: 7px; margin-top: 2px; padding-top: 10px; font-size: 11.5px;
  color: var(--pp-mute); border-top: 1px dashed var(--pp-line); }
.wf-hand .ic { width: 14px; height: 14px; color: var(--orange); }
.wf-hand code { font-size: 11px; color: var(--pp-ink); }
.wf-testbox { display: grid; gap: 8px; align-content: start; }
.wf-testbox-h { display: flex; align-items: center; justify-content: space-between; padding-bottom: 8px;
  border-bottom: 1px solid var(--pp-line); }
.wf-testbox-h b { font-size: 13.5px; }
.wf-testbox-h span { font-size: 10px; color: var(--pp-mute); }
.wf-test { display: grid; grid-template-columns: 24px 1fr auto; align-items: center; gap: 10px; padding: 10px 11px;
  border-radius: 10px; background: rgba(255,255,255,.03); border: 1px solid var(--pp-line); }
.wf-test b { font-size: 12.5px; }
.wf-test small { display: block; font-size: 11px; color: var(--pp-mute); }
.wf-ok { font-style: normal; font-size: 10px; font-weight: 700; padding: 3px 8px; border-radius: 6px; color: #0d2d22;
  background: #34d399; }
.wf-runbtn { font-style: normal; font-size: 10px; font-weight: 700; padding: 3px 8px; border-radius: 6px; color: #141311;
  background: var(--pink); }
.wf-dataline { position: relative; z-index: 2; display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px;
  max-width: 1020px; margin: 18px auto 0; }
.wf-dataline span { display: flex; gap: 8px; align-items: flex-start; font-size: 11.5px; line-height: 1.5; color: var(--pp-mute); }
.wf-dataline i { width: 6px; height: 6px; margin-top: 6px; border-radius: 50%; background: var(--teal); flex: 0 0 auto; }

/* ---- 7. ways to start ---- */
.wf-ways { position: relative; z-index: 2; display: grid; grid-template-columns: 1fr 1fr; gap: 18px; max-width: 1020px;
  margin: 0 auto; }
.wf-way { display: flex; gap: 12px; padding: 14px 16px; border-radius: 14px; background: var(--pp-card);
  border: 1px solid var(--pp-line); }
.wf-way span { display: grid; place-items: center; width: 26px; height: 26px; flex: 0 0 auto; border-radius: 8px;
  font: 700 10.5px/1 ui-monospace, monospace; color: #141311; background: var(--orange); }
.wf-way b { font-size: 14px; }
.wf-way p { margin: 3px 0 0; font-size: 12.5px; line-height: 1.5; color: var(--pp-mute); }
.wf-create { display: grid; gap: 8px; padding: 16px; border-radius: 16px; background: #15140f; border: 1px solid #34312a;
  color: #f5f5f6; grid-row: 1 / 4; grid-column: 2; box-shadow: 0 30px 60px rgba(0,0,0,.35); }
.wf-create-h { padding-bottom: 9px; font-size: 13px; border-bottom: 1px solid #2c2921; }
.wf-create-in { display: flex; gap: 9px; align-items: flex-start; padding: 10px 12px; border-radius: 10px; background: #1b1a14;
  border: 1px solid #2c2921; }
.wf-create-in .ic { width: 14px; height: 14px; color: #ffb36b; flex: 0 0 auto; margin-top: 3px; }
.wf-create-in p { margin: 0; font-size: 11.5px; line-height: 1.5; color: #cfcabb; }
.wf-create-l { font-size: 9px; letter-spacing: .12em; text-transform: uppercase; color: #8f8b80; }
.wf-create-row { display: grid; grid-template-columns: 24px 1fr auto; align-items: center; gap: 10px; padding: 9px 11px;
  border-radius: 10px; background: #1b1a14; border: 1px solid #2c2921; font-size: 12px; }
.wf-create-row b { font-size: 12.5px; }
.wf-create-row em { font-style: normal; font-size: 9px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
  color: #8f8b80; }
.wf-examples { position: relative; z-index: 2; max-width: 1240px; margin: 26px auto 0; }
.wf-examples > small { display: block; margin-bottom: 10px; text-align: center; font-size: 9.5px; letter-spacing: .16em;
  text-transform: uppercase; color: var(--pp-mute); }
.wf-exrow { overflow: hidden; padding: 5px 0;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); }
.wf-extrack { display: flex; gap: 10px; width: max-content; animation: wf-scroll 52s linear infinite; }
.wf-extrack.wf-rev { animation-direction: reverse; animation-duration: 60s; }
.wf-ex { display: grid; gap: 8px; width: 236px; min-height: 116px; padding: 16px; border-radius: 12px; text-align: left;
  background: var(--pp-card); border: 1px solid var(--pp-line); }
.wf-ex b { font-size: 12px; line-height: 1.4; color: var(--pp-ink); white-space: normal; }
.wf-ex span { font-size: 9.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--pp-mute); }
.wf-ex .pp-ic { width: 20px; height: 20px; font-size: 9px; }
.wf-ex > div { display: flex; }

/* ---- 8. runs ---- */
.wf-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 20px; }
.wf-stat { padding: 14px; }
.wf-stat p { font-size: 11.5px; }
.wf-st { display: inline-flex; align-items: center; gap: 6px; font-style: normal; font-size: 10.5px; font-weight: 700;
  letter-spacing: .06em; text-transform: uppercase; }
.wf-st i { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.wf-st-prog { color: #4aa8ff; } .wf-st-ok { color: #34d399; } .wf-st-err { color: #ff5a5f; } .wf-st-exit { color: #ffb020; }
.wf-note { margin-top: 16px; font-size: 12.5px; line-height: 1.6; color: var(--pp-mute); }
.wf-runs { display: grid; gap: 7px; padding: 16px; border-radius: 16px; background: #15140f; border: 1px solid #34312a;
  color: #f5f5f6; box-shadow: 0 30px 60px rgba(0,0,0,.35); }
.wf-runs-h { display: flex; align-items: center; justify-content: space-between; padding-bottom: 9px;
  border-bottom: 1px solid #2c2921; }
.wf-runs-h b { font-size: 13px; }
.wf-runs-h span { font-size: 9.5px; letter-spacing: .1em; text-transform: uppercase; color: #8f8b80; }
.wf-run { display: grid; grid-template-columns: 44px 1fr auto; align-items: center; gap: 10px; padding: 9px 11px;
  border-radius: 10px; background: #1b1a14; border: 1px solid #2c2921; cursor: pointer; }
.wf-run:hover { border-color: #4a4536; }
.wf-run-t { font: 700 11px/1 ui-monospace, monospace; color: #ffb36b; }
.wf-run b { display: block; font-size: 12px; }
.wf-run small { font-size: 10.5px; color: #8f8b80; }
.wf-run-d { display: none; margin: 6px 0 0; padding-top: 6px; font-size: 10.5px; line-height: 1.5; color: #cfcabb;
  border-top: 1px solid #2c2921; }
.wf-run.wf-open .wf-run-d { display: block; }
.wf-runs-f { margin: 4px 0 0; font-size: 10.5px; line-height: 1.55; color: #8f8b80; }

/* ---- 9. quiet workflow ---- */
.wf-quiet { position: relative; z-index: 2; display: grid; grid-template-columns: 1fr 1fr; gap: 22px; align-items: start;
  max-width: 1020px; margin: 0 auto; }
.wf-quiet-l { display: grid; gap: 14px; }
.wf-card { padding: 14px; border-radius: 16px; background: #15140f; border: 1px solid #34312a; color: #f5f5f6; }
.wf-card-h { display: flex; align-items: center; gap: 10px; padding-bottom: 9px; border-bottom: 1px solid #2c2921; }
.wf-card-h b { font-size: 13px; }
.wf-draft-tag { padding: 3px 8px; border-radius: 999px; font-size: 9.5px; font-weight: 700; letter-spacing: .1em;
  text-transform: uppercase; color: #cfcabb; background: #2a2820; }
.wf-draft-tag.wf-live { color: #0d2d22; background: #34d399; }
.wf-setlive { margin-left: auto; padding: 5px 11px; border-radius: 8px; font-size: 11px; font-weight: 600; color: #141311;
  background: var(--pink); }
.wf-setlive.on { color: #f5f5f6; background: #2a2820; border: 1px solid #3a362c; }
.wf-card-row { display: grid; grid-template-columns: 24px 1fr auto; align-items: center; gap: 10px; margin-top: 7px;
  padding: 9px 11px; border-radius: 10px; background: #1b1a14; border: 1px solid #2c2921; font-size: 12px; }
.wf-card-row em { font-style: normal; font-size: 10.5px; color: #ff8f8f; }
.wf-card-f { margin: 10px 0 0; font-size: 10px; line-height: 1.5; color: #8f8b80; }
.wf-timing { padding: 14px; border-radius: 16px; background: var(--pp-card); border: 1px solid var(--pp-line); }
.wf-timing-h { display: flex; align-items: center; gap: 8px; padding-bottom: 9px; border-bottom: 1px solid var(--pp-line); }
.wf-timing-h .ic { width: 14px; height: 14px; color: var(--orange); }
.wf-timing-h b { font-size: 12.5px; }
.wf-trow { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 0;
  font-size: 11.5px; color: var(--pp-mute); border-bottom: 1px solid var(--pp-line); }
.wf-trow:last-child { border-bottom: 0; }
.wf-trow b { font-size: 11.5px; color: var(--pp-ink); font-weight: 650; }
.wf-quiet-r { display: grid; gap: 10px; position: relative; padding-top: 96px; }
.wf-quiet-mascot { position: absolute; right: 0; top: -18px; width: 130px; height: auto; opacity: .95; }
.wf-reason { display: flex; gap: 12px; padding: 18px; border-radius: 13px; background: var(--pp-card);
  border: 1px solid var(--pp-line); min-height: 118px; }
.wf-reason span { display: grid; place-items: center; width: 22px; height: 22px; flex: 0 0 auto; border-radius: 7px;
  font: 700 10px/1 ui-monospace, monospace; color: #141311; background: var(--orange); }
.wf-reason b { font-size: 13px; }
.wf-reason p { margin: 3px 0 0; font-size: 12px; line-height: 1.5; color: var(--pp-mute); }

/* ---- 10. MCP band ---- */
.wf-mcpsec { padding: 96px 0; background: #0d0c0a; color: #f5f5f6; }
.wf-mcp { display: flex; align-items: center; gap: 20px; padding: 28px 30px; border-radius: 18px;
  background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.1); }
.wf-mcp-ic { display: grid; place-items: center; width: 42px; height: 42px; flex: 0 0 auto; border-radius: 12px;
  color: #141311; background: var(--orange); }
.wf-mcp-ic .ic { width: 20px; height: 20px; }
.wf-mcp b { font-size: 16px; }
.wf-mcp p { margin: 5px 0 0; font-size: 13px; line-height: 1.6; color: #a9a9b3; max-width: 620px; }
.wf-mcp .btn { margin-left: auto; }

/* ---- responsive ---- */
@media (max-width: 1100px) {
  .wf-diagram { grid-template-columns: 1fr 220px 1fr; }
  .wf-stepgrid { grid-template-columns: 1fr 1fr; }
  .pp-side-mascot.wf-steps-mascot { display: none; }
  .wf-ways { grid-template-columns: 1fr; }
  .wf-create { grid-column: 1; grid-row: auto; }
}
@media (max-width: 880px) {
  .wf-stage { height: 400px; }
  .wf-mascot { height: 260px; }
  .wf-flow { position: static; display: flex; flex-wrap: wrap; justify-content: center; padding-top: 10px; }
  .wf-diagram { grid-template-columns: 1fr; }
  .wf-col-out { order: 3; }
  .wf-mid { order: 2; }
  .wf-three, .wf-trigs, .wf-data, .wf-dataline, .wf-quiet, .wf-stats { grid-template-columns: 1fr; }
  .wf-num, .wf-step, .wf-reason { min-height: 0; }
  .wf-trig.wf-card-wide, .wf-trig.wf-card-soon { grid-column: auto; }
  .wf-trig.wf-card-wide ul { grid-template-columns: 1fr; }
  .wf-mcp { flex-wrap: wrap; }
  .wf-mcp .btn { margin-left: 0; }
  .wf-quiet-r { padding-top: 0; }
  .wf-quiet-mascot { display: none; }
}
@media (max-width: 720px) {
  .wf-stepgrid { grid-template-columns: 1fr; }
  .wf-run { grid-template-columns: 40px 1fr; row-gap: 5px; }
  .wf-run .wf-st { grid-column: 2; }
}
@media (prefers-reduced-motion: reduce) { .wf-pilltrack, .wf-extrack { animation: none; } }
