/* =========================================================
   Build — the learner's city and workbench (positions are inside .app-main, 1226 x 1004; nothing scrolls).
   The city on top: one zone for every domain, one building for every project. Below it, the build in
   progress with its six steps and studio tools, and every build with its zone.
   ========================================================= */
.ws-new { position: absolute; inset-inline-end: 20px; top: 22px; height: 44px; padding: 0 18px; gap: 8px; font-size: 15px}
.bd-kpi { position: absolute; inset-inline-end: 190px; top: 22px; display: flex; gap: 8px}
.bd-kpi span { display: inline-flex; align-items: baseline; gap: 6px; height: 44px; padding: 0 14px; border-radius: 12px; border: 1px solid var(--ip-line); background: var(--ip-card); font-size: 12.5px; line-height: 44px; color: #aeaeb2; white-space: nowrap}
.bd-kpi b { font-size: 16px; font-weight: 700; color: #ffffff}

.bd-card { position: absolute; display: flex; flex-direction: column; padding: 16px; border-radius: var(--ip-r); border: 1px solid var(--ip-line); background: var(--ip-card)}
.bd-ch { display: flex; align-items: center; justify-content: space-between; gap: 12px}
.ws-h { display: flex; align-items: center; gap: 8px; margin: 0; font-size: 18px; font-weight: 600; color: #ffffff}
.ws-h .ico { color: var(--accent)}
.ws-h small { margin-inline-start: auto; font-size: 13px; font-weight: 400; color: #98989d}

/* the city */
.bd-city { inset-inline-start: 15px; top: 92px; width: 1191px; height: 476px}
.bd-leg { display: flex; gap: 16px; font-size: 12.5px; color: #aeaeb2}
.bd-leg span { display: inline-flex; align-items: center; gap: 6px}
.bd-leg i { width: 12px; height: 12px; border-radius: 3px; border: 1.5px solid #636366}
.bd-leg .built i { border-color: var(--accent)}
.bd-leg .construction i { border-color: #8b5cf6; border-style: dashed}
/* two rows of zones show at once; more domains scroll inside the city */
.bd-zones { flex: 1; min-height: 0; display: grid; grid-template-columns: repeat(3, 1fr); grid-auto-rows: 192px; align-content: start; gap: 12px; margin-top: 12px; overflow-y: auto}
.bd-dadd { display: flex; align-items: center; gap: 12px}
.bd-dadd .btn { height: 36px; padding: 0 14px; gap: 6px; font-size: 14px}
.bd-dadd small { font-size: 13px; color: #aeaeb2}
.bd-dadd small b { color: #ffffff}
.bd-zone { display: flex; flex-direction: column; gap: 8px; min-width: 0; min-height: 0; padding: 12px; border-radius: 14px; border: 1px solid #232325; background: #111112; overflow: hidden}
.bd-zone.built { border-color: var(--accent-line)}
.bd-zone.construction { border-color: rgba(139, 92, 246, 0.5); border-style: dashed}
.bd-zh { display: grid; grid-template-columns: 38px 1fr auto auto; gap: 10px; align-items: center}
.bd-zx { width: 26px; height: 26px; display: grid; place-items: center; border-radius: 8px; color: #86868b}
.bd-zx:hover { background: #1d1d1f; color: #ffffff}
.bd-zone.flash { animation: paFlash 1.4s ease}
.bd-zi { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 10px; background: #1d1d1f; color: var(--accent)}
.bd-zone.vacant .bd-zi { color: #86868b}
.bd-zh b { display: block; font-size: 16px; font-weight: 700; color: #ffffff}
.bd-zh small { display: block; font-size: 12px; color: #98989d}
.bd-zh em { font-style: normal; font-size: 12px; color: #aeaeb2; white-space: nowrap}
.bd-bl { display: grid; gap: 6px; min-width: 0}
.bd-b { display: grid; grid-template-columns: 34px 1fr auto; gap: 10px; align-items: center; min-width: 0; padding: 6px 8px; border-radius: 10px; border: 1px solid #232325; background: #161617; text-align: start}
.bd-b:hover { border-color: var(--accent-line)}
.bd-bt { width: 34px; height: 34px; flex: none; display: grid; place-items: center; overflow: hidden; border-radius: 8px; background: #1d1d1f; color: var(--accent)}
.bd-bt img { width: 100%; height: 100%; object-fit: cover; display: block}
.bd-bn { min-width: 0}
.bd-bn b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13.5px; font-weight: 600; color: #ffffff}
.bd-bn small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11.5px; color: #98989d}
.bd-st { display: inline-flex; align-items: center; gap: 4px; flex: none; height: 24px; padding: 0 8px; border-radius: 999px; border: 1px solid #2c2c2e; font-size: 11.5px; font-weight: 600; color: #aeaeb2; white-space: nowrap}
.bd-st.built { border-color: var(--accent-line); color: var(--accent)}
.bd-st.construction { border-color: rgba(139, 92, 246, 0.45); color: #a78bfa}
.bd-more { display: inline-flex; align-items: center; gap: 4px; align-self: flex-start; font-size: 12.5px; font-weight: 600; color: var(--accent)}
.bd-more:hover { text-decoration: underline}
.bd-empty { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; border-radius: 10px; border: 1px dashed #2c2c2e; text-align: center}
.bd-empty p { margin: 0; font-size: 13px; color: #98989d}
.bd-empty .btn { height: 34px; padding: 0 12px; gap: 6px; font-size: 13px}
.bd-all { max-height: 460px; overflow-y: auto}

/* the 20 domains (modal) */
.bd-dpick { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px}
.bd-dom { display: grid; grid-template-columns: 36px 1fr; column-gap: 10px; align-items: start; padding: 10px 12px; border-radius: 12px; border: 1px solid var(--line); background: var(--panel-2); text-align: start}
.bd-dom:hover:not(.on) { border-color: var(--accent-line)}
.bd-dom .bd-zi { width: 36px; height: 36px; grid-row: 1 / 3}
.bd-dt em { display: block; font-style: normal; font-size: 11px; font-weight: 700; letter-spacing: .04em; color: var(--accent)}
.bd-dt b { display: block; margin-top: 2px; font-size: 14px; line-height: 1.25; color: var(--text)}
.bd-dt small { display: block; margin-top: 3px; font-size: 12px; line-height: 1.35; color: var(--muted)}
.bd-dom i { grid-column: 2; justify-self: start; display: inline-flex; align-items: center; gap: 4px; margin-top: 6px; font-style: normal; font-size: 12.5px; font-weight: 600; color: var(--accent)}
.bd-dom.on { opacity: .6}
.bd-dom.on i { color: var(--muted)}

/* the build in progress */
.bd-cont { inset-inline-start: 15px; top: 582px; width: 590px; height: 408px}
.ws-kick { display: flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--accent)}
.ws-badge { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 11px; border-radius: 999px; background: #161617; border: 1px solid #2c2c2e; font-size: 12.5px; font-weight: 600; color: #e5e5ea}
.ws-badge.ok { color: var(--accent)}
.bd-mh { display: grid; grid-template-columns: 92px 1fr; gap: 14px; align-items: center; margin-top: 12px}
.bd-mh img { width: 92px; height: 62px; border-radius: 10px; object-fit: cover; display: block}
.bd-mh h2 { margin: 0; font-size: 22px; font-weight: 700; letter-spacing: -.01em; color: #ffffff}
.ws-sub { display: flex; align-items: center; gap: 6px; margin: 4px 0 0; font-size: 13.5px; color: #d2d2d7}
.ws-sub .ico { color: var(--accent); flex: none}
.ws-sub .bd-zc { margin-inline-start: 6px; padding-inline-start: 10px; border-inline-start: 1px solid #2c2c2e}
.ws-prog { display: flex; align-items: center; gap: 12px; margin-top: 12px}
.ws-prog .progress { flex: 1; height: 6px}
.ws-prog small { font-size: 13px; color: #d2d2d7; white-space: nowrap}

/* the six steps as one timeline, grouped by Know · Do · Become */
.ws-tl { display: grid; grid-template-columns: repeat(6, 1fr); row-gap: 8px; margin-top: 14px}
.ws-ph { margin-inline-end: 10px; padding-bottom: 6px; border-bottom: 1px solid #2c2c2e; font-size: 11.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: #98989d}
.ws-ph.now, .ws-ph.done { color: var(--accent)}
.ws-st { position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 2px 0; font-size: 12.5px; color: #d2d2d7}
.ws-st::before { content: ""; position: absolute; top: 15px; right: 50%; width: 100%; height: 2px; background: #2c2c2e; z-index: 0}
.ws-st.first::before { display: none}
.ws-st.lk::before { background: var(--accent)}
.ws-st .d { position: relative; z-index: 1; width: 28px; height: 28px; display: grid; place-items: center; border-radius: 50%; border: 2px solid #424245; background: var(--ip-card); font-size: 12px; font-weight: 700; color: #d2d2d7}
.ws-st .l { text-align: center; line-height: 1.2}
.ws-st.done .d { background: var(--accent); border-color: var(--accent); color: #0a0a0b}
.ws-st.now .d { border-color: var(--accent); color: var(--accent); outline: 4px solid rgba(0, 255, 111, .16); outline-offset: 0; box-shadow: none}
.ws-st.now .l { color: #ffffff; font-weight: 600}
.ws-st.lock { color: #7c7c80}
.ws-st.lock .d { color: #7c7c80; border-color: #2c2c2e}
.ws-st:hover:not(.lock) .d { border-color: var(--accent)}
.ws-acts { display: flex; gap: 10px; margin-top: 14px}
.ws-go { height: 44px; padding: 0 18px; gap: 10px; font-size: 15px}
.ws-guide { height: 44px; padding: 0 16px; gap: 8px; font-size: 14.5px}
.bd-tools { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-top: auto}
.bd-tool { display: flex; align-items: center; gap: 8px; min-width: 0; height: 44px; padding: 0 10px; border-radius: 10px; border: 1px solid #2c2c2e; background: #161617; font-size: 12.5px; font-weight: 600; line-height: 1.15; color: #e5e5ea; text-align: start; overflow: hidden}
.bd-tool .ico { flex: none; color: var(--accent)}
.bd-tool:hover { border-color: var(--accent-line)}
.bd-tool.lock, .bd-tool.lock .ico { color: #86868b}

/* every build, with its zone */
.bd-builds { inset-inline-start: 619px; top: 582px; width: 587px; height: 408px}
.ws-list { flex: 1; min-height: 0; overflow-y: auto; margin-top: 10px; display: grid; align-content: start; gap: 6px}
.ws-row { display: flex; align-items: center; gap: 10px; min-height: 56px; padding: 7px 10px; border-radius: 10px; text-align: start; border: 1px solid transparent; background: #161617}
.ws-row:hover { border-color: var(--accent-line)}
.ws-row .bd-bt { width: 40px; height: 40px}
.ws-row .t { flex: 1; min-width: 0}
.ws-row b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14.5px; font-weight: 600; color: #ffffff}
.ws-row small { display: block; margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12.5px; color: #aeaeb2}
.bd-zc { display: inline-flex; align-items: center; gap: 5px; flex: none; font-size: 12.5px; color: #d2d2d7; white-space: nowrap}
.bd-zc .ico { color: var(--accent)}
.ws-none { margin: 6px 4px 0; font-size: 13.5px; line-height: 1.45; color: #98989d}
.ws-foot { display: flex; gap: 10px; margin-top: 12px}
.ws-foot .btn { height: 42px; padding: 0 16px; gap: 8px; font-size: 14px}

/* the project's building, in the Projects side panel */
.pzone { display: flex; align-items: center; gap: 8px; width: 100%; margin-top: 10px; padding: 8px 10px; border-radius: 10px; border: 1px solid #232325; background: #161617; font-size: 13px; color: #d2d2d7; text-align: start}
.pzone > .ico:first-child { flex: none; color: var(--accent)}
.pzone > span:not(.bd-st) { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap}
.pzone b { color: #ffffff}
.pzone > .ico:last-child { flex: none; color: #7c7c80}
.pzone:hover { border-color: var(--accent-line)}

/* parts library (modal) */
.ws-parts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px}
.ws-part { display: grid; grid-template-columns: 44px 1fr auto; gap: 12px; align-items: start; padding: 12px; border-radius: 12px; border: 1px solid var(--line); background: var(--panel-2)}
.ws-part .pi { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 11px; background: #1d1d1f}
.ws-part b { display: block; font-size: 15px; font-weight: 600; color: var(--text)}
.ws-part small { display: block; margin-top: 2px; font-size: 12.5px; color: var(--muted)}
.ws-part p { margin: 6px 0 0; font-size: 13px; line-height: 1.45; color: var(--text-2)}
.ws-part em { font-style: normal; font-size: 13px; font-weight: 600; color: var(--accent); white-space: nowrap}
/* an empty city: it starts with the first mission */
.bd-zones.bd-none { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; text-align: center; overflow: hidden}
.bd-none .bd-zi { width: 52px; height: 52px; display: grid; place-items: center; border-radius: 14px; background: var(--tile, #1d1d1f); color: var(--accent)}
.bd-none b { font-size: 17px; font-weight: 700; color: var(--text)}
.bd-none p { margin: 0 0 6px; max-width: 420px; font-size: 14px; line-height: 1.45; color: var(--muted, #98989d)}

/* Build's two pages, City and Lab, as tabs beside the title (on both pages) */
.bd-ht { display: flex; align-items: center; gap: 16px}
.bd-tabs { display: inline-flex; gap: 2px; padding: 3px; border-radius: 999px; border: 1px solid var(--line-2, #2c2c2e); background: var(--panel, #111112)}
.bd-tabs button { height: 28px; padding: 0 14px; border-radius: 999px; display: inline-flex; align-items: center; gap: 6px; font-size: 13.5px; font-weight: 600; color: var(--text-2)}
.bd-tabs button:hover { color: var(--text)}
.bd-tabs button.on { background: var(--panel-2, #1d1d1f); color: var(--text)}
.bd-tabs button.on .ico { color: var(--accent)}
