/* ═══════════════════════════════════════════════════════════════
   ArkQuant official site — iPhone frame + in-phone app screens.
   Everything is authored at fixed design coordinates (410×864 device,
   390×844 screen) and the WHOLE device is scaled via --phone-scale
   (set by JS: slotWidth / 410; coarse media-query fallback without JS).
   ═══════════════════════════════════════════════════════════════ */

.phone-slot{
  position:relative;width:min(410px,88vw);aspect-ratio:410/864;
  --phone-scale:1;
}
@media (max-width:479px){.phone-slot{--phone-scale:.82}}
.phone{
  position:absolute;top:0;left:0;width:410px;height:864px;
  transform:scale(var(--phone-scale));transform-origin:top left;
  border-radius:56px;background:#000;
  box-shadow:
    inset 0 0 0 1px rgba(255,255,255,.09),
    0 0 0 2px #1c1c1f,
    0 34px 80px -22px rgba(0,0,0,.7),
    0 12px 30px rgba(0,0,0,.45);
}
/* hardware nubs */
.p-nub{position:absolute;width:3px;background:#232327;border-radius:2px}
.p-nub-l1{left:-3px;top:186px;height:44px}
.p-nub-l2{left:-3px;top:244px;height:72px}
.p-nub-r{right:-3px;top:230px;height:96px}

.phone-screen{
  position:absolute;inset:10px;border-radius:46px;overflow:hidden;
  background:radial-gradient(900px at 50% 0%,#1a1a1f 0%,#0a0a0c 55%,#060607 100%);
}

/* status chrome (above screens) */
.p-island{
  position:absolute;top:14px;left:50%;transform:translateX(-50%);
  width:112px;height:32px;border-radius:16px;background:#000;z-index:6;
}
.p-status{
  position:absolute;top:0;left:0;right:0;height:54px;z-index:5;
  display:flex;align-items:center;justify-content:space-between;
  padding:12px 34px 0;
}
.p-time{font-size:15px;font-weight:600;letter-spacing:.02em}
.p-glyphs{display:flex;align-items:center;gap:7px}
.g-bars{display:flex;align-items:flex-end;gap:1.5px}
.g-bars b{width:3px;border-radius:1px;background:var(--text)}
.g-bars b:nth-child(1){height:4px}.g-bars b:nth-child(2){height:6px}
.g-bars b:nth-child(3){height:8px}.g-bars b:nth-child(4){height:10px}
.g-batt{position:relative;width:23px;height:11.5px;border:1px solid rgba(255,255,255,.5);border-radius:3.5px}
.g-batt::before{content:"";position:absolute;inset:1.5px;right:5px;background:var(--text);border-radius:1.5px}
.g-batt::after{content:"";position:absolute;right:-3.5px;top:3px;width:1.8px;height:4.5px;background:rgba(255,255,255,.5);border-radius:0 1px 1px 0}
.p-homebar{
  position:absolute;bottom:8px;left:50%;transform:translateX(-50%);
  width:118px;height:5px;border-radius:3px;background:rgba(255,255,255,.35);z-index:6;
}

/* screens & crossfade */
.screen{position:absolute;inset:0;opacity:0;transform:translateY(10px);pointer-events:none;
  transition:opacity .45s ease,transform .45s ease}
.screen.is-on{opacity:1;transform:none}
.demo-device[data-screen="pipeline"] .screen-pipeline,
.demo-device[data-screen="report"] .screen-report{opacity:1;transform:none}
.demo-device.paused *{animation-play-state:paused!important}

/* ═══════════ SCREEN 1 — HOME ═══════════ */
.p-appbar{
  display:flex;align-items:center;gap:8px;height:48px;margin-top:54px;padding-inline:18px;
}
.p-brandtile{
  display:grid;place-items:center;width:24px;height:24px;border-radius:7px;overflow:hidden;background:#000;
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.22),0 2px 6px rgba(0,0,0,.5);
}
.p-brandname{font-size:16px;font-weight:600}
.p-burger{margin-left:auto;display:flex;flex-direction:column;gap:4px;padding:8px}
.p-burger i{width:17px;height:2px;border-radius:1px;background:var(--text-2)}

.p-home{padding:2px 18px 0}
.p-tfrow{display:flex;align-items:center;gap:10px;margin-bottom:20px}
.p-tflabel{font-size:13px;color:var(--text-3)}
.p-seg{display:flex;gap:2px;padding:3px;border-radius:11px;background:var(--bg-elev2)}
.p-seg b{padding:6px 13px;border-radius:8px;font-size:13px;font-weight:600;color:var(--text-2)}
.p-seg b.on{background:var(--bg-elev3);color:var(--text)}
.p-h1{font-size:27px;font-weight:700;letter-spacing:-.01em;margin-bottom:7px}
.p-hsub{font-size:14px;color:var(--text-2);margin-bottom:20px}
.p-slabel{display:flex;align-items:center;gap:7px;font-size:13.5px;color:var(--text-2);margin-bottom:11px}
.p-slabel .ic{width:14px;height:14px}
.p-search{
  display:flex;align-items:center;height:58px;padding:0 9px 0 18px;border-radius:15px;
  background:var(--bg-elev);border:1px solid var(--border-strong);
}
.p-splaceholder{font-size:18px;font-weight:600;color:var(--text-3)}
.p-sbtn{
  margin-left:auto;display:grid;place-items:center;width:40px;height:40px;border-radius:11px;
  background:var(--bg-elev2);color:var(--brand);
}
.p-sbtn .ic{width:16px;height:16px}
.p-helper{font-size:12px;color:var(--text-3);line-height:1.5;margin-top:13px}
.p-helper b{font-weight:700}
.p-hot{font-size:17px;font-weight:600;margin:24px 0 4px}
.p-mtabs{display:flex;height:44px;border-bottom:1px solid var(--border);margin-bottom:10px}
.p-mtabs span{
  position:relative;flex:none;display:flex;align-items:center;justify-content:center;
  padding-inline:14px;font-size:13px;font-weight:600;color:var(--text-3);
}
.p-mtabs span.on{color:var(--brand)}
.p-mtabs span.on i{position:absolute;left:14px;right:14px;bottom:0;height:2px;border-radius:1px;background:var(--brand)}
.p-rows{display:flex;flex-direction:column;gap:8px}
.p-row{
  display:flex;align-items:center;gap:12px;min-height:62px;padding:10px 13px;border-radius:14px;
  background:var(--bg-elev);border:1px solid var(--border);
}
.p-row.sel{
  background:#242226;border:1.5px solid rgba(242,163,60,.72);
  box-shadow:0 12px 18px rgba(0,0,0,.6);transform:scale(1.018);
}
.p-ticon{
  flex:none;display:grid;place-items:center;width:40px;height:40px;border-radius:12px;
  font-size:11px;font-weight:800;color:#fff;letter-spacing:.02em;
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.1);
}
.p-ticon svg{width:56%;height:56%}
.p-rnm{display:flex;flex-direction:column;gap:5px;min-width:0}
.p-rnm b{font-size:14px;font-weight:600}
.p-rnm small{font-size:11.5px;font-weight:600;color:var(--text-3)}
.p-rnm small.amber{color:var(--brand)}
.p-rcheck{
  margin-left:auto;display:grid;place-items:center;width:24px;height:24px;border-radius:50%;
  background:var(--brand);color:var(--ink-on-amber);
}
.p-rcheck .ic{width:12px;height:12px}
.p-fade{
  position:absolute;left:0;right:0;bottom:0;height:130px;pointer-events:none;
  background:linear-gradient(to top,#060607 20%,transparent);
}
.p-tabbar{
  position:absolute;left:10px;right:10px;bottom:26px;display:flex;gap:4px;padding:7px;
  border-radius:23px;background:rgba(24,24,27,.94);
  border:1px solid var(--border-strong);box-shadow:0 15px 19px rgba(0,0,0,.55);
}
.p-tabbar span{
  flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;
  height:56px;border-radius:16px;font-size:10px;font-weight:600;color:var(--text-3);
}
.p-tabbar span .ic{width:18px;height:18px}
.p-tabbar span.on{color:var(--brand);background:var(--brand-dim)}

/* ═══════════ SCREEN 2 — GENERATION PIPELINE ═══════════ */
.screen-pipeline{background:linear-gradient(180deg,rgba(12,12,14,.96),rgba(4,4,6,.98))}
.pl-glow{
  position:absolute;top:-60px;left:50%;transform:translateX(-50%);width:480px;height:300px;
  background:radial-gradient(closest-side,rgba(242,163,60,.16),transparent 70%);pointer-events:none;
}
.pl-body{position:relative;padding:66px 24px 24px}
.pl-head{display:flex;gap:15px;align-items:flex-start}
.pl-orbit{
  position:relative;flex:none;display:grid;place-items:center;width:64px;height:64px;border-radius:20px;
  background:radial-gradient(closest-side,rgba(242,163,60,.26),rgba(242,163,60,.07));
  box-shadow:0 12px 15px rgba(0,0,0,.35);
}
.pl-orbit b{font-size:12px;font-weight:800;letter-spacing:.08em;color:var(--brand)}
.pl-orbit-arc{
  position:absolute;inset:7px;border-radius:50%;
  border:2px solid rgba(242,163,60,.22);border-top-color:var(--brand);
  animation:plSpin 1.1s linear infinite;
}
@keyframes plSpin{to{transform:rotate(360deg)}}
.pl-headtxt{display:flex;flex-direction:column;gap:8px;padding-top:2px}
.pl-headtxt>b{font-size:20px;font-weight:700;line-height:1.28;letter-spacing:-.01em}
.pl-headtxt small{font-size:12.5px;color:var(--text-3);line-height:1.55}
.pl-headtxt small b{color:var(--text-2);font-weight:600}
.pl-line{
  height:1px;margin:18px 0 16px;opacity:.7;
  background:linear-gradient(90deg,transparent,rgba(242,163,60,.36),transparent);
}
.pl-progress{display:flex;align-items:baseline;justify-content:space-between;margin-bottom:9px}
.pl-progress span{font-size:11.5px;font-weight:600;color:var(--text-3)}
.pl-pct{font-size:12px;font-weight:800;color:var(--brand);font-variant-numeric:tabular-nums;min-width:36px;text-align:right}
.pl-bar{position:relative;height:8px;border-radius:4px;background:rgba(255,255,255,.08);overflow:hidden}
.pl-fill{
  position:absolute;inset:0;border-radius:4px;transform:scaleX(.05);transform-origin:left center;
  background:linear-gradient(90deg,#e8943a,#f2a33c 58%,#ffd38a);
  box-shadow:0 0 11px rgba(242,163,60,.42);
}
.pl-steps{display:flex;flex-direction:column;gap:9px;margin-top:16px}
.pl-step{
  display:flex;align-items:center;gap:12px;min-height:58px;padding:10px 14px;border-radius:17px;
  transition:background-color .34s ease,border-color .34s ease,opacity .34s ease,transform .34s ease;
  border:1px solid rgba(255,255,255,.08);background:rgba(255,255,255,.035);
  box-shadow:0 8px 16px rgba(0,0,0,.18);
}
.pl-dot{position:relative;flex:none;display:grid;place-items:center;width:36px;height:36px;border-radius:12px;background:rgba(255,255,255,.06)}
.pl-steptxt{display:flex;flex-direction:column;gap:4px;min-width:0}
.pl-steptxt b{font-size:13.5px;font-weight:700;line-height:1.25;color:var(--text-3);transition:color .34s ease}
.pl-steptxt small{font-size:11px;color:var(--text-3);opacity:.85}
.pl-state{margin-left:auto;flex:none;font-size:10.5px;font-weight:700}

/* — waiting — */
.pl-step[data-state="waiting"]{transform:scale(.985) translateY(7px);opacity:.72}
.pl-step[data-state="waiting"] .pl-dot::before{content:"";width:9px;height:9px;border-radius:50%;background:var(--text-3)}
.pl-step[data-state="waiting"] .pl-state::after{content:"Waiting";color:var(--text-3)}
/* — active — */
.pl-step[data-state="active"]{
  background:rgba(242,163,60,.11);border-color:rgba(242,163,60,.38);
  box-shadow:0 12px 21px rgba(0,0,0,.28);
}
.pl-step[data-state="active"] .pl-dot{background:var(--brand-dim)}
.pl-step[data-state="active"] .pl-dot::before{
  content:"";width:17px;height:17px;border-radius:50%;
  border:2px solid rgba(242,163,60,.25);border-top-color:var(--brand);
  animation:plSpin .85s linear infinite;
}
.pl-step[data-state="active"] .pl-steptxt b{color:var(--text)}
.pl-step[data-state="active"] .pl-state::after{content:"In progress";color:var(--brand)}
/* — done — */
.pl-step[data-state="done"]{background:rgba(54,199,124,.07);border-color:rgba(54,199,124,.22)}
.pl-step[data-state="done"] .pl-dot{background:var(--up-dim)}
.pl-step[data-state="done"] .pl-dot::before{
  content:"";width:5px;height:10px;margin-top:-2px;
  border-right:2px solid var(--up);border-bottom:2px solid var(--up);transform:rotate(43deg);
}
.pl-step[data-state="done"] .pl-steptxt b{color:var(--text-2)}
.pl-step[data-state="done"] .pl-state::after{content:"Done";color:var(--up)}

/* ═══════════ SCREEN 3 — REPORT PREVIEW ═══════════ */
.screen-report{background:var(--bg);display:flex;flex-direction:column}
.rp-nav{
  position:relative;flex:none;display:flex;align-items:center;justify-content:space-between;
  margin-top:54px;padding:7px 16px;border-bottom:1px solid var(--border);
}
.rp-back{width:20px;height:20px;color:var(--text)}
.rp-navtxt{
  position:absolute;left:50%;transform:translateX(-50%);
  display:flex;flex-direction:column;align-items:center;gap:3px;
}
.rp-navtxt b{font-size:15px;font-weight:700}
.rp-navtxt small{font-size:11px;color:var(--text-3)}
.rp-dots{display:flex;gap:3px;padding:6px 0}
.rp-dots i{width:3.5px;height:3.5px;border-radius:50%;background:var(--text-2)}
.rp-scroll{flex:1;min-height:0;overflow:hidden;position:relative}
.rp-content{padding:0 18px}
.demo-device[data-screen="report"] .rp-content{animation:rpScroll 4.4s cubic-bezier(.3,.5,.25,1) .65s forwards}
@keyframes rpScroll{to{transform:translateY(-170px)}}

.rp-masthead{
  padding:18px 18px 20px;margin:0 -18px;border-bottom:1px solid var(--border);
  background:linear-gradient(180deg,var(--bg-elev),var(--bg));
}
.rp-eyebrow{
  display:flex;align-items:center;gap:7px;font-size:9.5px;font-weight:700;
  letter-spacing:.135em;text-transform:uppercase;color:var(--brand);
}
.rp-eyebrow i{width:18px;height:2px;background:var(--brand);border-radius:1px}
.rp-title{font-size:20px;font-weight:700;line-height:1.3;letter-spacing:-.01em;margin-top:13px}
.rp-sub{font-size:12px;color:var(--text-2);margin-top:8px;line-height:1.5}
.rp-gen{font-size:10.5px;color:var(--text-3);margin-top:6px}
.rp-asset{display:flex;align-items:center;gap:11px;margin-top:20px}
.rp-ticon{width:44px;height:44px;border-radius:13px;font-size:13px}
.rp-nm{display:flex;flex-direction:column;gap:5px;min-width:0}
.rp-nm b{font-size:15px;font-weight:600}
.rp-nm small{font-size:10.5px;font-weight:600;color:var(--brand)}
.rp-px{margin-left:auto;display:flex;flex-direction:column;align-items:flex-end;gap:7px}
.rp-px b{font-size:18px;font-weight:700;font-variant-numeric:tabular-nums}
.rp-px small{font-size:10.5px;font-weight:600;color:var(--up)}

.rp-sec{padding:20px 0;border-bottom:1px solid var(--border)}
.rp-sechead{display:flex;align-items:flex-start;gap:10px;margin-bottom:14px}
.rp-no{font-family:var(--mono);font-size:9px;font-weight:700;letter-spacing:.07em;color:var(--brand);padding-top:4px}
.rp-st{display:flex;flex-direction:column;gap:5px;min-width:0}
.rp-st b{font-size:16px;font-weight:700}
.rp-st small{font-size:10.5px;color:var(--text-3)}
.rp-tag{
  margin-left:auto;flex:none;font-size:9.5px;font-weight:600;color:var(--text-2);
  background:var(--bg-elev2);border-radius:7px;padding:5px 8px;
}
.rp-summary{
  position:relative;padding:15px 15px 15px 17px;font-size:12.5px;line-height:1.7;color:var(--text-2);
  background:linear-gradient(90deg,var(--brand-dim),rgba(242,163,60,.025));
  border-radius:0 13px 13px 0;
}
.rp-summary::before{content:"";position:absolute;left:0;top:0;bottom:0;width:3px;background:var(--brand);border-radius:2px}
.rp-pricerow{display:flex;align-items:baseline;justify-content:space-between;margin-bottom:8px}
.rp-pricerow b{font-size:22px;font-weight:700;font-variant-numeric:tabular-nums}
.rp-pricerow small{font-size:11.5px;font-weight:600;color:var(--up)}
.rp-chart{width:100%;height:auto;aspect-ratio:316/150}
.rp-inds{display:grid;grid-template-columns:1fr 1fr;gap:8px}
.rp-inds span{
  display:flex;flex-direction:column;gap:8px;min-height:84px;padding:11px;
  border-radius:12px;background:rgba(255,255,255,.015);border:1px solid var(--border);
}
.rp-inds small{font-size:10.5px;color:var(--text-3)}
.rp-inds b{font-size:12.5px;font-weight:700;color:var(--text-2)}
