/* Reusable discovery structure. Client look lives in /clients/<id>/theme.css */
:root{--bg:#000;--surface:#121212;--surface-2:#1c1c1e;--line:#262628;--line-strong:#48484a;--text:#f5f5f7;--muted:#8e8e93;--accent:#f5f5f7;--accent-ink:#000;--radius:18px;--font:-apple-system,BlinkMacSystemFont,"Helvetica Neue",Arial,sans-serif;--wordmark-tracking:.26em}
*{box-sizing:border-box;-webkit-tap-highlight-color:transparent}
html{-webkit-text-size-adjust:100%;background:var(--bg)}
body{margin:0;background:radial-gradient(120% 60% at 50% 0,#1a1a1c 0,var(--bg) 60%) no-repeat,var(--bg);color:var(--text);font:400 17px/1.4 var(--font);-webkit-font-smoothing:antialiased;min-height:100vh;min-height:100dvh;overscroll-behavior-y:none}
[hidden]{display:none!important}
button,input,textarea{font:inherit;color:inherit}
.app{max-width:520px;margin:0 auto;min-height:100vh;min-height:100dvh;display:flex;flex-direction:column;padding-top:env(safe-area-inset-top)}

.top{padding:8px 16px 0}
.top-row{display:grid;grid-template-columns:48px 1fr 48px;align-items:center;height:48px}
.back{width:44px;height:44px;margin-left:-8px;display:grid;place-items:center;background:none;border:0;color:var(--text);border-radius:50%;cursor:pointer;touch-action:manipulation}
.back[data-off]{visibility:hidden}
.back:active{background:var(--surface-2)}
.wordmark{text-align:center;font-size:12px;font-weight:700;letter-spacing:var(--wordmark-tracking);padding-left:var(--wordmark-tracking);white-space:nowrap}
.count{text-align:right;font-size:13px;color:var(--muted);font-variant-numeric:tabular-nums}
.progress{height:2px;background:var(--line);border-radius:2px;overflow:hidden}
.progress i{display:block;height:100%;background:var(--accent);transition:width .25s ease}

.screen{flex:1;padding:28px 20px 28px;animation:rise .18s ease-out}
@keyframes rise{from{opacity:0;transform:translateY(6px)}to{opacity:1;transform:none}}
.eyebrow{margin:0 0 10px;min-height:14px;font-size:11px;font-weight:600;letter-spacing:.16em;text-transform:uppercase;color:var(--muted)}
.q{margin:0;font-size:28px;line-height:1.15;font-weight:650;letter-spacing:-.022em;outline:0;text-wrap:balance}
.hint{margin:10px 0 0;color:var(--muted);font-size:15px}

.opts{display:grid;gap:10px;margin-top:24px}
.opt{appearance:none;width:100%;min-height:60px;padding:14px 16px 14px 18px;display:flex;align-items:center;justify-content:space-between;gap:14px;text-align:left;border-radius:var(--radius);border:1px solid var(--line);background:var(--surface);cursor:pointer;touch-action:manipulation;font-weight:520;transition:transform .08s ease,background .08s ease,color .08s ease,border-color .08s ease}
.opt:active{transform:scale(.985);background:var(--surface-2)}
.opt[aria-checked=true]{background:var(--accent);color:var(--accent-ink);border-color:var(--accent)}
.mark{flex:none;width:24px;height:24px;border-radius:50%;border:1.5px solid var(--line-strong);display:grid;place-items:center}
.opt.multi .mark{border-radius:8px}
.mark svg{width:14px;height:14px;stroke:var(--accent);opacity:0}
.opt[aria-checked=true] .mark{background:var(--accent-ink);border-color:var(--accent-ink)}
.opt[aria-checked=true] .mark svg{opacity:1}
@media (hover:hover){.opt:hover:not([aria-checked=true]){border-color:var(--line-strong)}}
.opt:focus-visible,.cta:focus-visible,.back:focus-visible,.ghost:focus-visible{outline:2px solid var(--text);outline-offset:2px}

.field{width:100%;margin-top:10px;padding:14px 16px;background:var(--surface);border:1px solid var(--line);border-radius:14px;font-size:16px;outline:0;resize:none}
.field::placeholder{color:#636366}
.field:focus{border-color:#8e8e93}
.other .field{margin-top:0}
.field.note{margin-top:14px;min-height:104px}

.bar{position:sticky;bottom:0;padding:16px 20px calc(16px + env(safe-area-inset-bottom));background:linear-gradient(to top,var(--bg) 72%,transparent)}
.cta{appearance:none;width:100%;height:56px;border:0;border-radius:999px;background:var(--accent);color:var(--accent-ink);font-size:17px;font-weight:650;cursor:pointer;touch-action:manipulation;transition:transform .08s ease,opacity .12s ease}
.cta:active:not([disabled]){transform:scale(.985)}
.cta[disabled]{opacity:.32;cursor:default}
.cta.inline{margin-top:24px}
.ghost{appearance:none;margin-top:18px;background:none;border:0;color:var(--muted);font-size:15px;padding:10px;cursor:pointer;text-decoration:underline;text-underline-offset:3px}

/* reveal */
.reveal .q{margin-bottom:4px}
.stage{margin:6px -10px 0}
.eco{display:block;width:100%;height:auto;overflow:visible}
.eco text{font-family:var(--font)}
.eco .dot{fill:none;stroke:var(--line-strong);stroke-width:1}
.eco .dot.on{fill:var(--text);stroke:none}
.eco .orbit{fill:none;stroke:var(--line);stroke-dasharray:2 5;stroke-linecap:round}
.eco .spoke{stroke:var(--line-strong);stroke-width:1.2;stroke-dasharray:var(--len);stroke-dashoffset:var(--len);animation:draw .5s ease-out forwards;animation-delay:var(--d)}
.eco .spoke.priority{stroke:var(--text);stroke-width:2}
.eco .spoke.suggested{stroke-dasharray:3 4;stroke-dashoffset:0;opacity:0;animation:fade .4s ease-out forwards;animation-delay:var(--d)}
@keyframes draw{to{stroke-dashoffset:0}}
@keyframes fade{to{opacity:1}}
.eco .node{opacity:0;transform-box:fill-box;transform-origin:center;animation:pop .35s ease-out forwards;animation-delay:var(--d)}
@keyframes pop{from{opacity:0;transform:scale(.85)}to{opacity:1;transform:none}}
.eco .disc{fill:var(--surface);stroke:var(--text);stroke-width:1.5}
.eco .icon{fill:none;stroke:var(--text);stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}
.eco .label{fill:var(--text);font-size:12px;font-weight:550;paint-order:stroke;stroke:var(--bg);stroke-width:6px;stroke-linejoin:round}
.eco .node.priority .disc{fill:var(--accent);stroke:var(--accent)}
.eco .node.priority .icon{stroke:var(--accent-ink);stroke-width:1.5}
.eco .node.priority .label{font-weight:700}
.eco .pulse{fill:none;stroke:var(--text);stroke-width:1;opacity:0;animation:pulse 1.8s ease-out 1s 2}
@keyframes pulse{0%{opacity:.5;transform:scale(.9)}100%{opacity:0;transform:scale(1.25)}}
.eco .pulse{transform-box:fill-box;transform-origin:center}
.eco .node.suggested .disc{fill:none;stroke:var(--line-strong);stroke-dasharray:3 4}
.eco .node.suggested .label{fill:var(--muted)}
.eco .node.suggested .icon{fill:none;stroke:var(--muted)}
.eco .hub circle{fill:var(--bg);stroke:var(--line-strong);stroke-width:1.5}
.eco .hub-1{fill:var(--text);font-size:12px;font-weight:700;letter-spacing:.24em}
.eco .hub-2{fill:var(--muted);font-size:8.5px;font-weight:600;letter-spacing:.2em}
.ringkey{display:flex;justify-content:center;align-items:center;gap:8px;margin:2px 0 22px;font-size:12px;color:var(--muted)}
.ringkey .k{width:7px;height:7px;border-radius:50%;border:1px solid var(--line-strong);margin-left:10px}
.ringkey .k:first-child{margin-left:0}
.ringkey .k.on{background:var(--text);border-color:var(--text)}

.legend{list-style:none;margin:0;padding:0;border-top:1px solid var(--line)}
.lg{padding:16px 0;border-bottom:1px solid var(--line)}
.lg-k{display:block;font-size:11px;font-weight:600;letter-spacing:.14em;text-transform:uppercase;color:var(--muted);margin-bottom:4px}
.lg strong{font-size:18px;font-weight:620;letter-spacing:-.01em}
.lg.priority strong{font-size:22px}
.lg.soft strong{color:#c7c7cc;font-weight:520}
.lg p{margin:6px 0 0;color:#c7c7cc;font-size:15px}
.muted{color:var(--muted)}
.small{font-size:13px}
.fine{margin:14px 0 0}
.chips{display:grid;grid-template-columns:auto 1fr;gap:8px 16px;margin:22px 0 0;font-size:14px}
.chips dt{color:var(--muted)}
.chips dd{margin:0}

.card{margin-top:28px;padding:20px;border:1px solid var(--line);border-radius:22px;background:var(--surface)}
.card h2{margin:0 0 6px;font-size:20px;font-weight:650;letter-spacing:-.015em}
.card p{margin:0 0 10px}
.sent{margin:0 0 12px;padding-left:20px;color:#d1d1d6;font-size:15px}
.sent li{margin:3px 0}
.raw{margin-top:12px;font-size:14px}
.raw summary{cursor:pointer;color:var(--muted);padding:6px 0}
.raw pre{margin:8px 0 0;padding:12px;max-height:240px;overflow:auto;background:var(--bg);border-radius:12px;font:12px/1.5 ui-monospace,SFMono-Regular,Menlo,monospace;color:#c7c7cc;white-space:pre-wrap;word-break:break-word}
.send-box{margin-top:18px}
.err{color:#ffd60a;font-size:14px}
.done{text-align:center}
.done .check{width:48px;height:48px;border-radius:50%;margin:0 auto 14px;background:var(--accent);display:grid;place-items:center}
.done .check svg{width:24px;height:24px;stroke:var(--accent-ink)}
.slogan{margin:36px 0 0;text-align:center;font-size:11px;font-weight:700;letter-spacing:.3em;color:#636366}

.eco.settled *{animation:none!important}
.eco.settled .spoke{stroke-dashoffset:0}
.eco.settled .spoke.suggested,.eco.settled .node{opacity:1}
@media (prefers-reduced-motion:reduce){
  .screen{animation:none}
  .eco .spoke{animation:none;stroke-dashoffset:0}
  .eco .spoke.suggested{opacity:1}
  .eco .node{animation:none;opacity:1}
  .eco .pulse{animation:none}
  .progress i,.opt,.cta{transition:none}
}
@media (min-width:600px){.screen{padding-top:44px}.q{font-size:32px}}
