.blueprint-detail,.blueprint-upgrades {max-width:1100px;margin:auto;padding-bottom:6rem}
.blueprint-hero,.upgrade-feature {background:#000;color:#fff;overflow:hidden;border-radius:24px}
.blueprint-media {position:relative;display:grid;place-items:center;overflow:hidden;background:black}
.blueprint-media>.chrome-object {position:absolute;inset:6% 8%;display:block;width:84%;height:88%;max-width:none;max-height:none;object-fit:contain;border-radius:0}
.blueprint-media>.market-card-cover {position:absolute;inset:0;width:100%;height:100%;object-fit:cover}
.blueprint-media>.market-card-cover[hidden] {display:none}
.blueprint-hero .blueprint-media {height:clamp(188px,54vw,300px)}
.blueprint-hero-copy {padding:10px 24px 24px;display:grid;gap:6px}
.blueprint-hero-copy small,.blueprint-hero-copy span {font-size:.85rem}
.blueprint-hero-copy h1 {color:inherit;font-size:clamp(1.6rem,4vw,2.75rem);line-height:1.07;margin:0;max-width:24ch}
.blueprint-hero-copy strong {font-size:clamp(3rem,9vw,5.25rem);line-height:.98;letter-spacing:-.065em;overflow-wrap:anywhere}
.blueprint-detail .contest-prize {display:block;margin:2.25rem 0 1.5rem}
.blueprint-detail .contest-prize h2,.blueprint-detail .contest-entries h2 a {font:inherit;color:inherit}
.blueprint-detail .contest-prize h2 {font-size:var(--title-size,1.4rem);font-weight:700}
.blueprint-detail .podium-line {width:100%;display:flex;align-items:center;gap:12px;margin:12px 0}
.podium-medal {display:grid;place-items:center;background:#000;width:48px;height:48px;border-radius:12px}
.podium-medal img {width:100%;height:100%;object-fit:contain}
.podium-line>div {display:grid;gap:2px;flex:1;font-weight:650}
.podium-line small {font-size:.85rem;color:var(--muted);font-weight:400}
.podium-line strong {font-size:1.12rem}
.podium-line a {color:var(--positive-text)}
.blueprint-pin {position:fixed;z-index:22;bottom:0;left:0;right:0;padding:10px max(16px,calc((100% - 470px)/2)) max(16px,env(safe-area-inset-bottom));background:var(--paper)}
.blueprint-pin>.button {width:100%;min-height:48px;display:flex;align-items:center;justify-content:center;background:var(--ink);color:var(--paper)}
body:has(.blueprint-pin) .dock {display:none}
.blueprint-comment {display:grid;grid-template-columns:1fr auto;gap:5px 12px;padding:12px 0}
.blueprint-comment a {font-weight:650}
.blueprint-comment p {grid-column:1/-1;white-space:pre-wrap;overflow-wrap:anywhere;margin:0}
.blueprint-comment time,.blueprint-section>p,.upgrade-copy>p {color:var(--muted)}
.upgrade-feature {color:var(--ink);background:var(--canvas-soft);margin:14px 0 32px}
.upgrade-feature .blueprint-media {height:clamp(155px,44vw,250px)}
.upgrade-copy {padding:18px}
.upgrade-copy small,.upgrade-copy>span {color:var(--muted)}
.upgrade-copy h2 {margin:8px 0}
.upgrade-copy>strong {font-size:clamp(2.3rem,8vw,3.4rem);letter-spacing:-.06em}
.upgrade-checks {list-style:none;padding:0;margin:12px 0}
.upgrade-checks li {display:flex;align-items:start;gap:9px;margin:6px 0}
.upgrade-checks svg {width:17px;height:20px;flex:none}
.upgrade-shelf {display:flex;overflow-x:auto;gap:12px;scroll-snap-type:x proximity}
.upgrade-shelf>a {flex:0 0 min(47%,240px);scroll-snap-align:start;display:grid;gap:3px;text-decoration:none;color:var(--ink)}
.upgrade-shelf .blueprint-media {height:110px;border-radius:20px;margin-bottom:6px}
.cash-flow:has(.bp-welcome) .flow-content {display:flex;align-items:stretch;flex-direction:column}
.cash-flow:has(.bp-welcome) .flow-page {display:flex;flex-direction:column}
.cash-flow:has(.bp-welcome) .flow-page>h2 {position:absolute;clip-path:inset(50%);height:1px;width:1px;overflow:hidden}
.bp-welcome .market-mark {display:block;padding:14px;background:#000;border-radius:22px;overflow:hidden;margin-bottom:18px}
.bp-welcome .market-mark img {display:block;object-fit:contain;width:100%;height:clamp(140px,36vh,280px)}
.bp-welcome h3 {font-size:clamp(1.9rem,5vw,2.6rem);margin:0;letter-spacing:-.055em}
.bp-welcome p {color:var(--muted)}
.cash-flow:has(.bp-post-pad) .pad-keys {border-radius:24px;padding:16px;background:#42db80;color:#111}
.cash-flow:has(.bp-post-pad),.cash-flow:has(.bp-post-pad) .flow-foot {background:var(--paper);color:var(--ink)}
.cash-flow:has(.bp-post-pad) .flow-primary,.cash-flow:has(.bp-step) .flow-primary,.cash-flow:has(.bp-welcome) .flow-primary {background:var(--ink);color:var(--paper)}
.cash-flow:has(.bp-post-pad) .flow-primary:disabled,.cash-flow:has(.bp-step) .flow-primary:disabled {background:var(--surface2);color:var(--muted)}
.bp-step textarea {width:100%;resize:vertical;min-height:4rem}
@media(min-width:760px){.blueprint-hero {display:grid;grid-template-columns:1fr 1fr;align-items:center}.blueprint-hero .blueprint-media {height:340px}.blueprint-detail .section,.blueprint-detail .contest-prize {max-width:780px}.blueprint-upgrades {max-width:850px}.upgrade-feature {display:grid;grid-template-columns:1fr 1fr;align-items:center}.upgrade-feature .blueprint-media {height:280px}}

/* Amount, progress and question screens follow the shared one-question flow. */
dialog.cash-flow[open]:has(.bp-post-pad),dialog.cash-flow:has(.bp-post-pad)::backdrop {
  --ground:var(--paper);--surface:var(--paper);--surface2:#eee;--ink:#111;--muted:#56585b;
  --control-fill:#f2f2f2;--control-ink:#111;--control-hover:#e2e2e2;
  background:var(--paper);color:var(--ink)
}
dialog.cash-flow:has(.bp-post-pad) .flow-foot {background:var(--paper)}
dialog.cash-flow:has(.bp-post-pad) .cash-pad {justify-items:start;gap:12px}
dialog.cash-flow:has(.bp-post-pad) .cash-pad output {text-align:left;font-size:clamp(50px,13vw,72px);padding:0}
dialog.cash-flow:has(.bp-post-pad) .pad-keys {width:100%;padding:12px;background:var(--money-green)}
dialog.cash-flow:has(.bp-post-pad) .pad-keys button {font-size:clamp(26px,6vw,32px);min-height:clamp(44px,8.6dvh,76px)}
dialog.cash-flow:has(.bp-post-pad) .flow-page h2 {font-size:clamp(30px,6vw,40px)}
dialog.cash-flow:has(.bp-step,.bp-post-pad) .flow-page {padding-top:18px}
dialog.cash-flow:has(.bp-step,.bp-post-pad) .flow-track {position:static;order:1;min-height:4px;margin-top:8px;background:#dedee0}
dialog.cash-flow:has(.bp-step,.bp-post-pad) .flow-track i {background:#138747}
dialog.cash-flow:has(.bp-step,.bp-post-pad) .flow-form {order:2}
dialog.cash-flow:has(.bp-step,.bp-post-pad,.bp-welcome) .flow-back {background:#f2f2f2;margin-left:0}
dialog.cash-flow:has(.bp-step,.bp-post-pad) .flow-primary:disabled {color:#555;background:#e8e8e8}
dialog.cash-flow:has(.bp-welcome) .flow-page {padding-top:8px}
dialog.cash-flow:has(.bp-welcome) .flow-track {visibility:hidden}
dialog.cash-flow .flow-content .bp-step :is(textarea,input:not([type=radio]),select) {
  background:#f3f3f3;color:var(--ink);border:0;border-radius:18px;padding:12px 16px
}
.bp-step>p {margin:0 0 14px}
.bp-step label+p {margin-top:14px}
@media(max-width:759px) {
  #main:has(>.blueprint-detail),#main:has(>.blueprint-upgrades){padding-top:8px}
}

.upgrade-detail>.blueprint-media {min-height:180px;aspect-ratio:16 / 9;border-radius:var(--radius-card);align-self:start;}
