/* First-run screen, part-request panel and import fix-ups (visitor.js). */
.first-run{display:none;position:fixed;left:0;right:0;bottom:0;top:70px;z-index:40;overflow:auto;background:radial-gradient(circle at 70% 20%,#fff 0,#f5f4f1 60%);padding:40px 16px}
html[data-first-run="true"] .first-run{display:flex}
html[data-first-run="true"] .export-trigger,html[data-first-run="true"] .undo-group,html[data-first-run="true"] .restore-button,html[data-first-run="true"] .project-name,html[data-first-run="true"] .floor-link{display:none}
.first-run-inner{margin:auto;width:100%;max-width:720px;display:flex;flex-direction:column;align-items:center;text-align:center;gap:18px}
.first-run h1{margin:0;font-size:clamp(28px,4.4vw,46px);line-height:1.08;letter-spacing:-.02em;color:#24363d;font-weight:700}
.first-run-drop{width:100%;min-height:230px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:10px;border:2px dashed #e0a585;border-radius:20px;background:#fffaf6;color:#40525a;cursor:pointer;font:inherit;padding:24px;transition:background .15s,border-color .15s}
.first-run-drop:hover,.first-run-drop.drag-over{background:#fff1e7;border-color:#ed622d}
.first-run-drop.failed{border-color:#c46a3d}
.first-run-drop svg{width:44px;height:44px;fill:none;stroke:#ed622d;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.first-run-drop strong{font-size:20px}
.first-run-drop span{font-size:13px;color:#6c7d80;max-width:520px}
.first-run-drop.failed span{color:#ad5c38}
.first-run .button.primary{font-size:16px;padding:14px 26px;height:auto}
.first-run-offer{margin:4px 0 0;font-size:14px;color:#4b5d63;max-width:520px;line-height:1.5}
.text-link{border:0;background:none;padding:0;font:inherit;color:#d4572a;text-decoration:underline;cursor:pointer;font-weight:650}
.first-run-skip{border:0;background:none;color:#7b8b8e;font:inherit;font-size:13px;cursor:pointer;text-decoration:underline}
.part-request-trigger{white-space:nowrap}
.part-request-link{display:block;margin-top:10px;font-size:10px;color:#6c7d80}
#part-fixes{margin-top:10px;display:grid;gap:6px}
.fix-row{margin:0;display:flex;align-items:center;justify-content:space-between;gap:8px;font-size:10px;color:#4b5d63;line-height:1.4}
.fix-row select{max-width:150px;font-size:10px}
.fix-row.warn{padding:8px 10px;border:1px solid #e4b39b;border-radius:8px;background:#fff7f0;color:#8a4a2c}
.fix-row.note{color:#7b8b8e;font-size:9px}
.fix-row .button.small{flex:none}
dialog.part-request-modal{max-width:620px;width:calc(100vw - 32px);max-height:calc(100dvh - 32px);overflow:auto}
.part-request-modal form{display:grid;gap:10px}
.part-request-modal label{display:grid;gap:4px;font-size:12px;color:#4b5d63;text-align:left}
.part-request-modal input,.part-request-modal textarea,.part-request-modal select{font:inherit;font-size:14px;padding:9px 10px;border:1px solid #cdd8d6;border-radius:8px;background:#fff;color:#24363d;width:100%;box-sizing:border-box}
.part-request-modal .pr-two{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.pr-file{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:9px 10px;border:1px solid #dfe5e5;border-radius:8px;background:#f7f8f5;font-size:12px;color:#4b5d63;text-align:left}
.pr-hp{position:absolute;left:-9999px;width:1px;height:1px;overflow:hidden}
.pr-status{margin:0;padding:10px 12px;border-radius:8px;font-size:13px;line-height:1.45;text-align:left}
.pr-status.ok{background:#eef7f1;color:#2f6b4a;border:1px solid #bfdcc9}
.pr-status.warn{background:#fff7f0;color:#8a4a2c;border:1px solid #e4b39b}
.pr-status a{color:inherit;font-weight:650}
@media(max-width:640px){.first-run{padding:24px 16px;top:59px!important}.first-run-drop{min-height:190px}.part-request-trigger{display:none}.part-request-modal .pr-two{grid-template-columns:1fr}}
/* Guided steps (steps.js) */
body[data-guided="true"] .sidebar-intro,body[data-guided="true"] .cell-profile,body[data-guided="true"] .builder-section,body[data-guided="true"] .sidebar-footer,body[data-guided="true"] .machine-section{display:none}
body[data-guided="true"][data-step-more="part"] .part-section,body[data-guided="true"][data-step-more="part"] .builder-section:first-of-type{display:block}
body[data-guided="true"][data-step-more="part"][data-task="machine-tending"] .machine-section{display:block}
body[data-guided="true"] .part-section #part-fixes{display:none}
.step-rail{margin:0 0 6px}
.step-list{list-style:none;margin:0;padding:0;display:grid;gap:6px}
.step{border:1px solid #e3e7e4;border-radius:12px;background:#fff}
.step.active{border-color:#ed622d;box-shadow:0 6px 22px rgba(237,98,45,.12)}
.step-head{display:flex;align-items:center;gap:10px;width:100%;border:0;background:none;padding:10px 12px;font:inherit;font-size:13px;font-weight:650;color:#24363d;text-align:left;cursor:pointer}
.step-head:disabled{cursor:not-allowed;color:#a3afb1}
.step.upcoming .step-head{color:#7b8b8e;font-weight:600}
.step-dot{flex:none;display:grid;place-items:center;width:24px;height:24px;border-radius:50%;background:#eef1ee;color:#5d6f74;font-size:12px;font-weight:700}
.step.active .step-dot{background:#ed622d;color:#fff}
.step.done .step-dot{background:#4c8065;color:#fff}
.step-body{padding:0 12px 12px 46px;font-size:12px;color:#40525a;line-height:1.5}
.step-body p{margin:0 0 8px}
.step-facts{margin:0 0 10px;display:grid;gap:4px}
.step-facts div{display:grid;grid-template-columns:76px 1fr;gap:6px}
.step-facts dt{color:#8b9a9a;font-size:11px}
.step-facts dd{margin:0;font-size:12px;color:#24363d}
.step-actions{display:flex;flex-wrap:wrap;gap:8px;margin:10px 0 6px}
.step-actions .button{height:auto;padding:9px 13px;font-size:12px}
.step-pulse{position:relative;animation:step-pulse 1.8s ease-out infinite}
@keyframes step-pulse{0%{box-shadow:0 0 0 0 rgba(237,98,45,.45)}70%{box-shadow:0 0 0 10px rgba(237,98,45,0)}100%{box-shadow:0 0 0 0 rgba(237,98,45,0)}}
.step-more{font-size:11px;color:#6c7d80;padding:2px 0}
.step-more-body{margin-top:8px;display:grid;gap:8px}
.step-seg{display:flex;align-items:center;gap:6px;flex-wrap:wrap}
.step-seg span{font-size:11px;color:#8b9a9a;min-width:52px}
.step-seg button{border:1px solid #d5dedc;background:#fff;border-radius:7px;padding:5px 9px;font:inherit;font-size:11px;cursor:pointer}
.step-seg button.active{border-color:#ed622d;background:#fff1e7;color:#b04a1f;font-weight:650}
.step-field{display:flex;align-items:center;justify-content:space-between;gap:8px;margin:6px 0;font-size:11px;color:#5d6f74}
.step-field select{max-width:190px;font:inherit;font-size:11px;padding:5px}
.step-input{display:inline-flex;align-items:center;gap:4px;color:#7b8b8e;font-size:11px}
.step-input input{width:62px;padding:5px;border:1px solid #cdd8d6;border-radius:6px;font:inherit;font-size:12px;text-align:right}
.step-grid{grid-template-columns:1fr 1fr}
.step-grid label{display:grid;gap:2px;font-size:10px;color:#6c7d80}
.step-check{display:flex!important;align-items:center;gap:6px}
.step-note{font-size:11px;color:#6c7d80}
.step-problem{padding:8px 10px;border:1px solid #e4b39b;border-radius:8px;background:#fff7f0;color:#8a4a2c}
.pockets{display:flex;flex-wrap:wrap;gap:4px;margin:4px 0 8px}
.pocket{font-size:10px;padding:3px 7px;border-radius:6px;background:#eef7f1;color:#2f6b4a;border:1px solid #bfdcc9}
.pocket.bad{background:#fff1eb;color:#a5441c;border-color:#e4b39b}
.step-body .good{color:#2f6b4a;font-weight:650}.step-body .bad{color:#a5441c;font-weight:650}
.step-offer{margin-top:12px;padding:10px 12px;border-radius:10px;background:#fff7f0;border:1px solid #f0cdb8;font-size:12px}
.step-strip{display:none}
@media(max-width:640px){
  .step-strip{display:flex;position:sticky;top:59px;z-index:19;gap:4px;overflow-x:auto;padding:7px 10px;background:#fff;border-bottom:1px solid #e3e7e4;scrollbar-width:none}
  html[data-first-run="true"] .step-strip{display:none}
  .step-strip button{flex:1 0 auto;display:flex;align-items:center;gap:5px;border:1px solid #e3e7e4;background:#fff;border-radius:999px;padding:5px 9px;font:inherit;font-size:11px;color:#5d6f74;white-space:nowrap}
  .step-strip button span{display:grid;place-items:center;width:17px;height:17px;border-radius:50%;background:#eef1ee;font-size:10px;font-weight:700}
  .step-strip button.active{border-color:#ed622d;color:#b04a1f;font-weight:650}.step-strip button.active span{background:#ed622d;color:#fff}
  .step-strip button.done span{background:#4c8065;color:#fff}
  .step-strip button:disabled{opacity:.5}
  body[data-guided="true"] .sidebar-scroll{display:block}
  .step-body{padding-left:12px}
  .step-actions .button{flex:1 1 auto;justify-content:center}
}
/* Floor designer hint (designer.html) */
.d-steps{display:flex;align-items:center;gap:16px;padding:6px 20px;background:#fff;border-bottom:1px solid #e3e7e4;font-size:12px;color:#5d6f74;position:relative;z-index:19;flex-wrap:wrap}
.d-steps ol{display:flex;gap:14px;margin:0;padding:0;list-style:none;flex-wrap:wrap}
.d-steps li{display:flex;align-items:center;gap:6px}
.d-steps li span{display:grid;place-items:center;width:18px;height:18px;border-radius:50%;background:#ed622d;color:#fff;font-size:10px;font-weight:700}
.d-steps-back{color:#d4572a;font-weight:650;text-decoration:none}
@media(max-width:640px){.d-steps{padding:6px 12px;gap:8px;font-size:11px}.d-steps ol{gap:8px}}
@media(min-width:641px){body:has(.d-steps) .d-shell{height:calc(100vh - 70px - 33px)}}
.step-rail,.step,.step-body{min-width:0}
body[data-guided="true"] .sidebar-scroll{overflow-x:hidden}
.step-field{display:grid;grid-template-columns:1fr;gap:3px;justify-content:stretch}
.step-field select{max-width:100%;width:100%;min-width:0}
.step-body .step-actions{flex-direction:column;align-items:stretch}
.step-body .step-actions .button{justify-content:center}
.step-fixes{display:grid;gap:6px;margin:4px 0 8px}
/* Step 3 gripper picker, mounting toggle and finger chat (Claude, gripper presets 2026-11-06) */
.gripper-pick{display:grid;gap:4px;margin:0 0 10px}
.gripper-pick .gripper-main{display:grid;gap:4px;font-weight:600;font-size:12px}
.gripper-pick .gripper-main select{width:100%;font-size:13px;padding:6px 8px}
.gripper-keys{margin:0;font-size:12px;color:#334;font-variant-numeric:tabular-nums}
.gripper-check{margin:0;font-size:11px}
.mount-toggle{display:flex;justify-content:space-between;align-items:center;width:100%;margin-top:10px;font-size:12px}
.mount-toggle b{font-size:12px}
.finger-chat{margin-top:10px;display:grid;gap:4px;font-size:12px}
.finger-chat label{font-weight:600}
.finger-chat-row{display:flex;gap:6px}
.finger-chat-row input{flex:1;min-width:0;padding:6px 8px;font-size:12px}
.finger-chat-log p{margin:2px 0;padding:4px 6px;border-radius:6px;font-size:11.5px}
.finger-chat-log .chat-you{background:#eef3f2;text-align:right}
.finger-chat-log .chat-studio{background:#fff4ec}
.download-fingers .button{width:100%;justify-content:center;font-size:14px;padding:11px 12px}
/* Part request: per-part setup (default, first part free) or a printed tray only (2026-11-13). */
.part-request-modal .pr-want{border:0;padding:0;margin:0 0 6px;display:grid;grid-template-columns:1fr 1fr;gap:8px}
.part-request-modal .pr-choice{display:flex;gap:9px;align-items:flex-start;border:1px solid #dfe5e6;border-radius:10px;padding:10px 12px;cursor:pointer}
.part-request-modal .pr-choice:has(input:checked){border-color:var(--orange,#e86c37);background:#fff6f1}
.part-request-modal .pr-choice input{margin:3px 0 0;width:auto;height:auto;flex:none;accent-color:var(--orange,#e86c37)}
.part-request-modal .pr-choice span{display:flex;flex-direction:column;gap:2px}
.part-request-modal .pr-choice small{font-size:11px;color:#6f7f85;line-height:1.35}
@media(max-width:640px){.part-request-modal .pr-want{grid-template-columns:1fr}}
