/* SlowDown page: hero hop diagram and the Diagnose demo. Shared look in ../showcase.css. */

/* Hero: the connection path as a product shot */
.hop-hero{border-radius:28px;background:var(--stage);color:#eaf6f3;padding:clamp(20px,3vw,32px);box-shadow:var(--shadow);display:grid;gap:22px}
.hh-row{display:flex;align-items:center;gap:6px}
.hh-node{flex:none;display:grid;justify-items:center;gap:4px;font-size:clamp(22px,3vw,30px);line-height:1}
.hh-node small{font-size:12px;font-weight:600;color:#9fbdb7}
.hh-link{flex:1;display:grid;justify-items:center;gap:6px;min-width:24px}
.hh-link i{display:block;width:100%;height:4px;border-radius:4px;background:#4ade80}
.hh-link.bad i{background:repeating-linear-gradient(90deg,#f97316 0 8px,transparent 8px 13px)}
.hh-link b{font:600 12px var(--mono)}
.hh-link.bad b{color:#fdba74}
.hh-verdict{display:grid;gap:6px;padding:18px;border-radius:18px;background:#ffffff0d;border:1px solid #ffffff14}
.hh-verdict b{font:800 clamp(18px,2.2vw,22px)/1.2 var(--display)}
.hh-verdict span:last-child{font-size:15px;color:#b7d0cb}
.hh-badge{justify-self:start;font:700 12px/1 var(--body);letter-spacing:.12em;text-transform:uppercase;color:#5eead4}
.hh-bars{display:flex;align-items:flex-end;gap:6px;height:70px}
.hh-bars span{flex:1;height:var(--h);border-radius:6px 6px 2px 2px;background:linear-gradient(#5eead4,#0f8f7e)}
.hh-bars .spike{background:linear-gradient(#fdba74,#ea580c)}

/* Demo window */
.wd-window{background:#f8fbfa}
.wd-window .titlebar{justify-content:flex-start}
.wd-state{margin-left:auto;font-weight:700;color:#0f8f7e}
.wd-state.busy{color:#b45309}
.wd-body{display:grid;grid-template-columns:minmax(220px,260px) minmax(0,1fr);min-height:440px}
.wd-side{display:flex;flex-direction:column;gap:10px;padding:18px;border-right:1px solid #0000000d;background:#eef4f2}
.wd-side-label{margin:0;font:700 12px/1 var(--body);letter-spacing:.1em;text-transform:uppercase;color:#5b6b67}
.wd-scenarios{display:grid;gap:6px}
.wd-scenarios button{display:flex;align-items:center;min-height:44px;padding:0 12px;border-radius:12px;border:1px solid transparent;background:transparent;color:#1d2a27;font:600 15px var(--body);text-align:left;cursor:pointer}
.wd-scenarios button:hover{background:#ffffff}
.wd-scenarios button[aria-checked="true"]{background:#fff;border-color:#0f8f7e55;box-shadow:0 4px 14px -8px #0f8f7e88}
.wd-run{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:48px;margin-top:6px;border:0;border-radius:999px;background:#0f8f7e;color:#fff;font:700 15px var(--body);cursor:pointer}
.wd-run svg{width:18px;height:18px;fill:currentColor}
.wd-run:disabled{opacity:.6;cursor:progress}
.wd-note{margin:auto 0 0;font-size:13px;line-height:1.45;color:#5b6b67}
.wd-main{display:flex;flex-direction:column;gap:16px;padding:clamp(16px,2.4vw,24px);min-width:0;color:#1d2a27}

.wd-path{display:flex;align-items:center;gap:4px;padding:14px;border-radius:16px;background:#fff;border:1px solid #0000000d}
.wd-node{flex:none;display:grid;justify-items:center;gap:3px;font-size:24px;line-height:1;transition:transform .3s}
.wd-node small{font-size:12px;font-weight:600;color:#5b6b67}
.wd-node.at{transform:translateY(-3px)}
.wd-link{flex:1;display:grid;justify-items:center;gap:5px;min-width:18px}
.wd-link i{display:block;width:100%;height:4px;border-radius:4px;background:#dfe7e5;transition:background .3s}
.wd-link b{font:600 12px var(--mono);color:#5b6b67;white-space:nowrap}
.wd-link.ok i{background:#22c55e}.wd-link.warn i{background:#eab308}.wd-link.bad i{background:repeating-linear-gradient(90deg,#ea580c 0 8px,transparent 8px 13px)}
.wd-link.bad b{color:#c2410c}
.wd-path:not(.with-vpn) .vpn-only{display:none}

.wd-steps{list-style:none;margin:0;padding:0;display:grid;gap:6px}
.wd-steps:empty::before{content:"Choose a situation on the left and run the diagnosis. Each check appears here as it runs.";display:block;padding:18px;border-radius:14px;border:1px dashed #0000001f;color:#5b6b67;font-size:15px}
.wd-steps li{display:grid;grid-template-columns:24px minmax(0,1fr) auto;gap:10px;align-items:center;min-height:44px;padding:6px 12px;border-radius:12px;background:#fff;border:1px solid #0000000a;font-size:15px;animation:wd-in .3s ease-out}
.wd-steps li .ico{font-size:16px;text-align:center}
.wd-steps li b{font:600 13px var(--mono);color:#5b6b67;text-align:right}
.wd-steps li.running .ico::before{content:"";display:inline-block;width:14px;height:14px;border-radius:50%;border:2px solid #0f8f7e;border-right-color:transparent;animation:wd-spin .8s linear infinite}
.wd-steps li.warn b{color:#a16207}.wd-steps li.bad b{color:#c2410c}
@keyframes wd-in{from{opacity:0;transform:translateY(6px)}}
@keyframes wd-spin{to{transform:rotate(360deg)}}

.wd-verdict{padding:18px;border-radius:16px;background:#0c1716;color:#eaf6f3}
.wd-verdict-label{font:700 12px/1 var(--body);letter-spacing:.12em;text-transform:uppercase;color:#5eead4}
.wd-verdict h3{font:800 clamp(19px,2.4vw,24px)/1.2 var(--display);margin:8px 0 6px}
.wd-verdict p{margin:0 0 12px;color:#b7d0cb;font-size:15px}
.wd-actions{display:flex;flex-wrap:wrap;align-items:center;gap:10px}
.wd-secondary{display:inline-flex;align-items:center;gap:8px;min-height:44px;padding:0 16px;border-radius:999px;border:1px solid #ffffff2a;background:#ffffff10;color:#eaf6f3;font:700 14px var(--body);cursor:pointer}
.wd-secondary kbd{background:#ffffff14;border-color:#ffffff24;color:#eaf6f3}
#wd-copied{font-size:14px;color:#5eead4}
.wd-summary{margin:12px 0 0;padding:14px;border-radius:12px;background:#ffffff0a;color:#d7e7e3;font:13px/1.5 var(--mono);white-space:pre-wrap;overflow-wrap:anywhere}

/* Charts fed by the demo */
.wd-gauge{position:relative;display:grid;justify-items:center;max-width:280px;margin:0 auto}
.wd-gauge svg{width:100%;height:auto;fill:none;stroke-width:16;stroke-linecap:round}
.wd-gauge .track{stroke:var(--paper-2)}
.wd-gauge .fill{stroke:var(--accent);stroke-dasharray:0 100;transition:stroke-dasharray 1s cubic-bezier(.2,.7,.2,1),stroke .3s}
.wd-gauge b{margin-top:-58px;font:800 44px/1 var(--display);letter-spacing:-.03em}
.wd-gauge span{margin-top:6px;font-size:14px;color:var(--muted)}

@media (max-width:760px){
  .wd-body{grid-template-columns:1fr}
  .wd-side{border-right:0;border-bottom:1px solid #0000000d}
  .wd-scenarios{grid-template-columns:1fr 1fr}
  .wd-note{margin-top:0}
  .wd-link b{font-size:12px}
}
@media (max-width:420px){
  .wd-node{font-size:20px}
  .wd-path{gap:2px;padding:12px 8px}
  .wd-scenarios button{font-size:14px;padding:0 8px}
  .hh-node{font-size:20px}
}

/* Phones: the path runs top to bottom so every hop keeps its label and latency readable,
   and each check's result sits under its name. */
@media (max-width:560px){
  .wd-path{flex-direction:column;align-items:stretch;gap:0;padding:10px 14px}
  .wd-node{display:flex;align-items:center;gap:10px;font-size:20px}
  .wd-node small{font-size:14px;color:#1d2a27}
  .wd-link{display:flex;align-items:center;gap:12px;min-height:26px;margin-left:9px}
  .wd-link i{width:4px;height:26px;flex:none}
  .wd-link.bad i{background:repeating-linear-gradient(180deg,#ea580c 0 6px,transparent 6px 10px)}
  .wd-steps li{grid-template-columns:24px minmax(0,1fr);row-gap:2px;padding:8px 12px}
  .wd-steps li b{grid-column:2;text-align:left;overflow-wrap:anywhere}
}
