/* Shared kit for the 1.4 M1–M4 dashboard mockups (m1-*, m4-*). Tokens copied from dashboard/app/app.css;
   chrome follows components/site-shell/top-bar.tsx + site-sidebar.tsx (0.87 shell). Mockup only. */
:root,.light{
  --background:#faf9f7;--foreground:#1c1917;--card:#fff;--muted:#f4f3f0;--muted-foreground:#6f6760;
  --secondary:#efeeea;--accent:#efeeea;--border:#e8e6e2;--input:#e1dfda;--primary:#ffcb05;--primary-foreground:#1c1917;--ring:#a67c00;
  --destructive:#bb342a;--success:#4f7d5b;--success-muted:#eaf1ec;--success-muted-foreground:#3f6a4b;
  --warning-muted:#f6efe2;--warning-muted-foreground:#856023;--danger-muted:#f8ebe9;--danger-muted-foreground:#9a382c;
  --shared:#565f91;--shared-muted:#eff0fa;--plan-gold:#8a6500;--plan-gold-ring:#e0b400;
  --publish:#1c1917;--publish-foreground:#fff;--publish-hover:#36312d;
  --font-ui:"Inter","Geist",ui-sans-serif,system-ui,-apple-system,"Segoe UI",Roboto,sans-serif;
  --font-mono:"JetBrains Mono","Geist Mono",ui-monospace,"SF Mono",Consolas,monospace;
  --radius:.625rem;--shadow:0 18px 50px -12px rgba(28,25,23,.22),0 2px 8px rgba(28,25,23,.06);
  color-scheme:light;
}
.dark{
  --background:#0a0a0b;--foreground:#ededed;--card:#141416;--muted:#1a1a1d;--muted-foreground:#8f8f96;
  --secondary:#202023;--accent:#202023;--border:#27272a;--input:#2c2c30;
  --success-muted:#16241b;--success-muted-foreground:#86c79a;--warning-muted:#241d10;--warning-muted-foreground:#d9b677;
  --danger-muted:#271513;--danger-muted-foreground:#e8a89d;--shared:#a9b1e3;--shared-muted:#1d2033;--plan-gold:#e0b400;
  --publish:#ededed;--publish-foreground:#0a0a0b;--publish-hover:#fff;--shadow:0 18px 50px -12px rgba(0,0,0,.7),0 0 0 1px rgba(255,255,255,.05);
  color-scheme:dark;
}
*{box-sizing:border-box}
html,body{margin:0}
body{background:var(--background);color:var(--foreground);font:400 14px/1.5 var(--font-ui);-webkit-font-smoothing:antialiased}
button,input,textarea,select{font:inherit;color:inherit}
a{color:inherit}
.ico{width:16px;height:16px;stroke:currentColor;fill:none;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round;flex:none}
:focus-visible{outline:2px solid var(--ring);outline-offset:2px}
.mono{font-family:var(--font-mono);font-size:12.5px}
.muted{color:var(--muted-foreground)}
.sr{position:absolute!important;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0)}
.glyph{position:relative;display:inline-block;width:24px;height:24px;border-radius:23.607%;background:var(--primary);flex:none}
.glyph::after{content:"";position:absolute;inset:30.9%;border-radius:50%;background:#1c1917}
.tbd{font-family:var(--font-mono);font-size:12px;font-weight:600;color:#9a382c;background:#fdecec;border:1px dashed #e8a89d;border-radius:5px;padding:1px 6px;white-space:nowrap}
.dark .tbd{background:#271513;color:#e8a89d}

/* ---------- mockup state bar (not product) ---------- */
.mk-bar{position:sticky;top:0;z-index:100;display:flex;align-items:center;gap:6px;min-height:48px;padding:6px 12px;background:#1c1917;color:#f4f3f0;flex-wrap:wrap}
.mk-title{display:flex;align-items:center;gap:8px;font-weight:600;font-size:13px;margin-right:8px;white-space:nowrap}
.mk-title a{color:inherit;opacity:.7;text-decoration:none;font-weight:500}
.mk-title .s{font-family:var(--font-mono);font-size:12px;background:#ffcb05;color:#1c1917;border-radius:5px;padding:0 6px}
.mk-btn{height:32px;padding:0 10px;border-radius:8px;border:1px solid #3a3633;background:transparent;color:#d6d3ce;font-size:12.5px;white-space:nowrap;cursor:pointer;display:inline-flex;align-items:center;gap:6px}
.mk-btn:hover{background:#2a2623;color:#fff}
.mk-btn[aria-pressed="true"]{background:#ffcb05;color:#1c1917;border-color:#ffcb05;font-weight:600}
.mk-btn b{font-family:var(--font-mono);opacity:.65}
.mk-sp{flex:1}
.mk-note{font-size:12px;color:#a8a29e;max-width:520px;line-height:1.35}
body.shot .mk-bar{display:none}

/* ---------- shell: top bar ---------- */
.top{position:sticky;top:0;z-index:40;height:48px;display:flex;align-items:center;gap:4px;padding:0 16px;background:var(--card);border-bottom:1px solid var(--border)}
body:not(.shot) .top{top:48px}
.top .brand{display:grid;place-items:center;width:36px;height:36px;border-radius:8px}
.top .brand .glyph{width:30px;height:30px}
.slash{width:16px;height:16px;stroke:var(--input);fill:none;stroke-width:1.5;stroke-linecap:round;flex:none}
.crumb{display:inline-flex;align-items:center;gap:6px;height:32px;padding:0 8px;border-radius:8px;font-weight:500;font-size:13.5px}
.crumb .tile{width:20px;height:20px;border-radius:6px;display:grid;place-items:center;background:var(--secondary);font-size:11px;font-weight:600;box-shadow:0 0 0 1.5px var(--plan-gold-ring)}
.crumb .ico{width:14px;height:14px;color:var(--muted-foreground)}
.capsule{display:inline-flex;align-items:center;gap:8px;height:34px;padding:0 4px 0 12px;border:1px solid var(--border);border-radius:999px;font-size:13.5px;margin-left:2px}
.capsule .nm{font-weight:600}
.capsule .st{display:inline-flex;align-items:center;gap:6px;color:var(--muted-foreground);font-size:12.5px}
.capsule .st i{width:7px;height:7px;border-radius:50%;background:var(--success)}
.capsule .pub{height:26px;padding:0 12px;border-radius:999px;border:0;background:var(--publish);color:var(--publish-foreground);font-weight:500;font-size:12.5px}
.jump{display:inline-flex;align-items:center;gap:8px;height:32px;width:260px;margin-left:12px;padding:0 10px;border:1px solid var(--input);border-radius:8px;background:var(--background);color:var(--muted-foreground);font-size:13px}
.jump kbd{margin-left:auto;font:500 11px var(--font-ui);border:1px solid var(--border);border-radius:4px;padding:0 5px}
.trail{margin-left:auto;display:flex;align-items:center;gap:4px}
.ib{position:relative;width:36px;height:36px;border-radius:8px;border:0;background:none;display:grid;place-items:center;color:var(--muted-foreground);cursor:pointer}
.ib:hover,.ib.on{background:var(--accent);color:var(--foreground)}
.ib .ico{width:18px;height:18px}
.ib .dot{position:absolute;top:7px;right:7px;width:8px;height:8px;border-radius:50%;background:var(--primary);box-shadow:0 0 0 2px var(--card)}
.avatar{width:30px;height:30px;border-radius:50%;display:grid;place-items:center;background:var(--secondary);font-weight:600;font-size:12px;margin-left:4px}

/* ---------- shell: sidebar + page ---------- */
.shell{display:flex;min-height:calc(100vh - 48px)}
.side{width:232px;flex:none;background:var(--card);border-right:1px solid var(--border);padding:8px;display:flex;flex-direction:column;gap:2px}
.nav{display:flex;align-items:center;gap:10px;height:36px;padding:0 10px;border-radius:8px;color:var(--muted-foreground);font-size:14px;text-decoration:none}
.nav:hover{background:var(--accent);color:var(--foreground)}
.nav.on{background:color-mix(in srgb,var(--primary) 15%,transparent);color:var(--foreground);font-weight:500}
.nav .ico{width:17px;height:17px}
.nav .n{margin-left:auto;font-size:11.5px;font-weight:600;min-width:20px;height:20px;border-radius:10px;display:grid;place-items:center;padding:0 6px;background:var(--primary);color:#1c1917}
.nav .new{margin-left:auto;font-size:10.5px;font-weight:600;letter-spacing:.03em;color:var(--muted-foreground);border:1px solid var(--border);border-radius:5px;padding:0 5px}
.page{flex:1;min-width:0;padding:0 40px 48px}
.tabs{position:sticky;top:96px;z-index:20;display:flex;align-items:flex-end;gap:24px;height:54px;background:var(--background);border-bottom:1px solid var(--border)}
body.shot .tabs{top:48px}
.tabs .t{padding:0 0 13px;font-size:15px;color:var(--muted-foreground);text-decoration:none;white-space:nowrap}
.tabs h1.t{margin:0;font-size:20px;font-weight:600;letter-spacing:-.02em;color:var(--foreground);box-shadow:inset 0 -2px 0 var(--primary);padding-bottom:11px}
.tabs .acts{margin-left:auto;align-self:center;display:flex;gap:8px}
.intro{color:var(--muted-foreground);margin:14px 0 22px;max-width:760px}

/* ---------- buttons (rule 3: yellow, black, white) ---------- */
.btn{display:inline-flex;align-items:center;justify-content:center;gap:6px;height:36px;padding:0 14px;border-radius:8px;border:1px solid var(--border);background:var(--card);font-weight:500;font-size:13.5px;cursor:pointer;white-space:nowrap;text-decoration:none}
.btn:hover{background:var(--accent)}
.btn.primary{background:var(--primary);border-color:var(--primary);color:var(--primary-foreground)}
.btn.publish{background:var(--publish);border-color:var(--publish);color:var(--publish-foreground)}
.btn.ghost{border-color:transparent;background:none}
.btn.danger{color:var(--destructive)}
.btn.sm{height:30px;padding:0 10px;font-size:12.5px}
.btn .ico{width:15px;height:15px}
.link{color:var(--foreground);text-decoration:underline;text-underline-offset:2px;text-decoration-color:var(--input)}

/* ---------- cards, rows, chips ---------- */
.sc{background:var(--card);border:1px solid var(--border);border-radius:var(--radius)}
.sc+.sc{margin-top:16px}
.sc-h{display:flex;align-items:center;gap:10px;padding:14px 18px;border-bottom:1px solid var(--border)}
.sc-h h2,.sc-h h3{margin:0;font-size:15px;font-weight:600}
.sc-h p{margin:0;color:var(--muted-foreground);font-size:13px}
.sc-b{padding:16px 18px}
.sec-label{font-size:12px;font-weight:600;color:var(--muted-foreground);text-transform:uppercase;letter-spacing:.05em;margin:28px 0 8px}
.srow{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:16px;padding:14px 18px;border-top:1px solid var(--border)}
.srow:first-child{border-top:0}
.srow b{display:block;font-weight:500}
.srow .v{color:var(--muted-foreground);font-size:13px}
.srow .v strong{color:var(--foreground);font-weight:500}
.chip{display:inline-flex;align-items:center;gap:5px;height:22px;padding:0 8px;border-radius:999px;font-size:12px;font-weight:500;white-space:nowrap;background:var(--secondary);color:var(--muted-foreground)}
.chip.ok{background:var(--success-muted);color:var(--success-muted-foreground)}
.chip.warn{background:var(--warning-muted);color:var(--warning-muted-foreground)}
.chip.bad{background:var(--danger-muted);color:var(--danger-muted-foreground)}
.chip.info{background:var(--shared-muted);color:var(--shared)}
.chip.line{background:none;border:1px solid var(--border)}
.seg{display:inline-flex;padding:3px;border-radius:9px;background:var(--muted);border:1px solid var(--border)}
.seg span{height:28px;padding:0 12px;border-radius:7px;display:inline-flex;align-items:center;gap:6px;font-size:13px;color:var(--muted-foreground);white-space:nowrap}
.seg span.on{background:var(--card);color:var(--foreground);font-weight:600;box-shadow:0 1px 2px rgba(28,25,23,.08)}
.seg span small{font-size:11.5px;opacity:.75}
.switch{width:36px;height:20px;border-radius:10px;background:var(--input);position:relative;flex:none;display:inline-block;vertical-align:middle}
.switch::after{content:"";position:absolute;top:2px;left:2px;width:16px;height:16px;border-radius:50%;background:#fff;box-shadow:0 1px 2px rgba(0,0,0,.2)}
.switch.on{background:var(--foreground)}
.switch.on::after{left:18px;background:var(--card)}
.field{display:flex;align-items:center;gap:8px;height:36px;padding:0 10px;border:1px solid var(--input);border-radius:8px;background:var(--card)}
.field input{border:0;outline:0;background:none;flex:1;min-width:0}
.field .ico{color:var(--muted-foreground)}
.copyrow{display:flex;align-items:center;gap:8px;height:36px;padding:0 4px 0 10px;border:1px solid var(--input);border-radius:8px;background:var(--muted);font-family:var(--font-mono);font-size:12.5px}
.copyrow span{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}

/* ---------- overlays: menu, dialog, sheet ---------- */
.menu{position:absolute;z-index:50;background:var(--card);border:1px solid var(--border);border-radius:12px;box-shadow:var(--shadow);padding:6px;width:320px}
.mi{display:flex;align-items:center;gap:12px;padding:8px 10px;border-radius:8px;text-decoration:none;color:inherit;min-height:44px}
.mi:hover,.mi.hl{background:var(--accent)}
.mi .mic{width:32px;height:32px;border-radius:8px;display:grid;place-items:center;background:var(--muted);flex:none}
.mi .mic .ico{width:17px;height:17px}
.mi b{display:block;font-weight:500;font-size:14px}
.mi small{display:block;color:var(--muted-foreground);font-size:12.5px}
.mi .end{margin-left:auto;display:flex;align-items:center;gap:6px;color:var(--muted-foreground);font-size:12px}
.mi .unread{width:8px;height:8px;border-radius:50%;background:var(--primary)}
.menu hr{border:0;border-top:1px solid var(--border);margin:6px 4px}
kbd{font:500 11px var(--font-ui);border:1px solid var(--border);border-bottom-width:2px;border-radius:4px;padding:0 5px;color:var(--muted-foreground);background:var(--card)}
.scrim{position:fixed;inset:0;z-index:60;background:rgba(28,25,23,.38);display:grid;place-items:center}
.dialog{width:480px;max-width:calc(100vw - 32px);background:var(--card);border:1px solid var(--border);border-radius:14px;box-shadow:var(--shadow);overflow:hidden}
.dialog .dh{padding:20px 22px 6px}
.dialog .dh h2{margin:0 0 4px;font-size:18px;font-weight:600;letter-spacing:-.01em}
.dialog .dh p{margin:0;color:var(--muted-foreground)}
.dialog .db{padding:14px 22px}
.dialog .df{display:flex;justify-content:flex-end;gap:8px;padding:14px 22px 20px}
.lbl{display:block;font-size:13px;font-weight:500;margin:0 0 6px}
.hint{font-size:12.5px;color:var(--muted-foreground);margin:6px 0 0}
.opt{display:flex;gap:12px;align-items:flex-start;padding:12px 14px;border:1px solid var(--border);border-radius:10px;cursor:pointer}
.opt+.opt{margin-top:8px}
.opt.on{border-color:var(--foreground);box-shadow:0 0 0 1px var(--foreground)}
.opt .radio{width:18px;height:18px;border-radius:50%;border:1.5px solid var(--input);flex:none;margin-top:2px}
.opt.on .radio{border:5px solid var(--foreground)}
.opt b{display:block;font-weight:500}
.opt small{display:block;color:var(--muted-foreground);font-size:12.5px}
.opt .price{margin-left:auto;white-space:nowrap}
.sumline{display:flex;justify-content:space-between;align-items:center;padding:10px 0;border-top:1px solid var(--border);font-size:13.5px}

/* ---------- the support widget panel, drawn in the dashboard (same look as widget.html) ---------- */
.wp{position:fixed;right:20px;top:112px;z-index:45;width:400px;background:var(--card);border:1px solid var(--border);border-radius:16px;box-shadow:var(--shadow);display:flex;flex-direction:column;overflow:hidden}
body.shot .wp{top:64px}
.wp-h{display:flex;align-items:center;gap:10px;padding:12px 10px 12px 12px;border-bottom:1px solid var(--border)}
.wp-h b{display:block;font-weight:600;font-size:14.5px}
.wp-h small{display:block;color:var(--muted-foreground);font-size:12.5px}
.wp-h .sp{flex:1}
.wp-b{padding:14px 16px;overflow:auto}
.wp-f{padding:10px 12px;border-top:1px solid var(--border)}
.wp-f .send{width:100%;height:44px;border-radius:10px;border:0;background:var(--primary);color:#1c1917;font-weight:600;display:flex;align-items:center;justify-content:center;gap:8px}
.wp textarea{width:100%;border:1px solid var(--border);border-radius:10px;padding:10px 12px;min-height:72px;resize:none;background:var(--card)}
.shot-frame{position:relative;border:1px solid var(--border);border-radius:10px;overflow:hidden;background:var(--background)}
.shot-acts{display:flex;align-items:center;gap:8px;padding:8px;border-top:1px solid var(--border);background:var(--card)}
.det{border:1px solid var(--border);border-radius:10px;margin-top:12px;font-size:12.5px}
.det .dh{display:flex;align-items:center;gap:8px;padding:9px 12px;color:var(--muted-foreground)}
.det .dh b{color:var(--foreground);font-weight:500}
.det ul{list-style:none;margin:0;padding:0 12px 8px}
.det li{display:grid;grid-template-columns:110px minmax(0,1fr);gap:8px;padding:5px 0;border-top:1px solid var(--border)}
.det li span:first-child{color:var(--muted-foreground)}
.mask-note{display:flex;gap:8px;align-items:flex-start;padding:10px 12px;margin-top:10px;border-radius:10px;background:var(--success-muted);color:var(--success-muted-foreground);font-size:12.5px}
.mask-note .ico{margin-top:1px}
/* Thumbnail = a scaled live clone of the page; private fields are replaced before "capture". */
.thumb{position:relative;height:210px;overflow:hidden}
.thumb > .clone{position:absolute;top:0;left:0;transform-origin:0 0;pointer-events:none}
.thumb [data-dotsy-private]{color:transparent!important;background:repeating-linear-gradient(135deg,#8f8a84 0 6px,#a8a39d 6px 12px)!important;border-color:transparent!important;border-radius:6px;position:relative}
.thumb [data-dotsy-private] *{visibility:hidden}
.thumb [data-dotsy-private]::after{content:"Hidden";visibility:visible;position:absolute;inset:0;display:grid;place-items:center;color:#fff;font:600 22px var(--font-ui)}
