/* v48: cancellable Opening overlays and clean workspace reset. */
#extension-guides .passage-cancel{position:absolute;top:-34px;right:8px;width:28px;height:28px;min-width:28px;padding:0;display:flex;align-items:center;justify-content:center;line-height:1;font-size:22px;border:1px solid #86232c;border-radius:50%;background:#fff4df;color:#712d35;cursor:pointer;z-index:9;pointer-events:auto;touch-action:manipulation}
#extension-guides .passage-cancel:hover{background:#f4dfb2}
#extension-guides .passage-cancel:focus-visible{outline:3px solid #996e2b;outline-offset:2px}
#cell-grid>button{position:relative;overflow:hidden}
.mini-opening-zone{position:absolute;pointer-events:none;z-index:2;border:1px solid #ad1526;background:repeating-linear-gradient(45deg,#d91d2e99 0 1px,transparent 1px 6px),repeating-linear-gradient(-45deg,#d91d2e99 0 1px,transparent 1px 6px),#ee343449}
#drop-zone{background-image:none;background-color:#e8ddc8}
#extension-guides .main-target{background:#fff8e8;border-color:#996e2b;box-shadow:inset 0 0 0 2px #e2c78e}
#extension-guides .main-target:hover:not(:disabled){background:#f4dfb2;border-color:#712d35}
#extension-guides .main-target[aria-pressed=true]{background:#e4bd7a;box-shadow:inset 0 0 0 2px #f4dda8}
#map-scene .vacant-preview-cell{background:#e8ddc8}
@charset "UTF-8";
/* v22: the map is the workspace; controls are readable, not miniaturized. */
:root{--ink:#35271f;--muted:#55432f;--line:#c5ad82;--gold:#b99751;--wine:#712d35;--paper:#f4ecd9;font-family:system-ui,-apple-system,"Segoe UI",sans-serif;color:var(--ink);background:#e5d7bb;color-scheme:light}
*{box-sizing:border-box}[hidden]{display:none!important}body{margin:0;background:linear-gradient(110deg,#eee4cf,#e1cfaa);font-size:15px;line-height:1.5}h1,h2,h3,p{margin-top:0}h1,h2,h3{font-family:Georgia,"Times New Roman",serif;font-weight:400;line-height:1.2}p{line-height:1.55}a{color:inherit}button,input,textarea,select{font:inherit}button,a,summary{touch-action:manipulation}button{cursor:pointer}button:disabled{cursor:not-allowed;opacity:.48}button,a,summary{-webkit-tap-highlight-color:transparent}button:focus-visible,a:focus-visible,textarea:focus-visible,select:focus-visible,input:focus-visible,summary:focus-visible,.grid-scroll:focus-visible,#map-box:focus-visible{outline:3px solid #8b4d14;outline-offset:3px}
.site-header{padding:14px 26px;background:linear-gradient(100deg,#33221b,#51372a 58%,#35241c);border:1px solid #8e7245;box-shadow:inset 0 0 0 4px #39271e,inset 0 0 0 5px #927643;display:flex;justify-content:space-between;align-items:center;gap:16px;color:#f2e4c1}.brand{text-decoration:none;font:22px Georgia,serif;letter-spacing:.5px}.brand small{display:block;font:14px system-ui,sans-serif;margin-top:4px;color:#eadab8}.beta-badge{font-size:14px;color:#eadab8}.eyebrow,.step-heading>span{display:none}
.bench-actions{display:flex;align-items:center;justify-content:flex-end;flex-wrap:wrap;gap:8px;min-width:0}#daily-quota-info{font-size:13px;white-space:nowrap}#daily-limit-dialog{box-sizing:border-box}@media(max-width:480px){.bench-actions{width:100%;justify-content:space-between}}
main{max-width:2200px;margin:20px auto;padding:0 24px}.workbench{border:1px solid #ad8b54;background:var(--paper);box-shadow:0 4px 14px #3a291319}.bench-header{padding:16px 22px;background:#e9d9b5;border-bottom:1px solid var(--line);display:flex;justify-content:space-between;align-items:center;gap:16px}h1{font-size:30px;margin:0}.workspace{display:grid;grid-template-columns:minmax(340px,390px) minmax(0,1fr)}.controls{min-width:0;padding:20px;background:linear-gradient(100deg,#f6eedc,#eee2c8);border-right:1px solid var(--line)}.control-section{margin-bottom:20px;padding-bottom:18px;border-bottom:1px solid #d5c39f}.step-heading{margin-bottom:12px}.step-heading h2{font-size:23px;margin:0}.controls p{font-size:14px;color:var(--muted);margin-bottom:12px}.mode-guide{margin:0 0 8px!important}.bench-note{margin:12px 0 0;font-size:14px!important}
.primary-button,.secondary-button,.quiet-button,.retry-button,#download,select{min-height:44px;border:1px solid #a68a54;border-radius:3px;padding:10px 14px;font-weight:650;font-size:14px;line-height:1.4}.primary-button{background:var(--wine);color:#fff5df;border-color:#58212a;width:100%;display:flex;justify-content:space-between;align-items:center;gap:12px}.primary-button:hover:not(:disabled){background:#5e222b}.secondary-button,.retry-button{background:#dfc58b;color:#46331d}.quiet-button{background:#faf4e7;color:#503b26}.quiet-button:hover:not(:disabled),.secondary-button:hover:not(:disabled){border-color:#712d35;background:#ead8b5}.file-hint{display:block;color:var(--muted);font-size:14px;line-height:1.5;margin-top:10px}#file-input,#reference-input,.sr-only{position:absolute;width:1px;height:1px;padding:0;border:0;overflow:hidden;clip:rect(0,0,0,0);clip-path:inset(50%);white-space:nowrap}
.help-disclosure{margin:8px 0 12px;color:var(--muted);font-size:14px}.help-disclosure summary{cursor:pointer;min-height:44px;padding:10px 0;font-weight:600}.help-disclosure p{margin:0 0 12px;overflow-wrap:anywhere}.help-disclosure[open]{padding-bottom:4px}.work-mode{display:flex;padding:4px;background:#e4d4b2;border:1px solid #bda273;gap:8px;margin:0 0 18px}.work-mode button{flex:1;border:0;background:transparent;color:#543d26;min-height:44px;padding:8px;font-size:15px;font-weight:700}.work-mode button[aria-pressed=true]{background:#712d35;color:#fff3d9}
.grid-scroll{height:288px;min-height:288px;max-height:360px;overflow:auto;padding:4px 3px 8px;scrollbar-width:auto;scroll-padding:8px}#cell-grid{display:grid;grid-auto-rows:84px;gap:8px;max-width:340px;margin:auto;min-width:min-content}.occupied-cell,.target-cell{min-width:84px;min-height:84px;padding:6px;display:flex;flex-direction:column;justify-content:center;align-items:center;line-height:1.3;border-radius:2px;aspect-ratio:auto!important}.occupied-cell{background:#7a6950;color:#fff7e2;border:1px solid #65533a;font-size:14px;position:relative;isolation:isolate;background-repeat:no-repeat;text-shadow:0 1px 3px #000,0 0 3px #000}.occupied-cell::before{content:'';position:absolute;inset:0;background:#21160e65;z-index:-1;pointer-events:none}.target-cell{border:1px dashed #92733f;background:#fbf4e4;color:#694d21;font-size:26px}.target-cell small,.occupied-cell small{display:block;font:14px system-ui,sans-serif;margin-top:4px;white-space:nowrap}.occupied-cell:hover:not(:disabled),.target-cell:hover:not(:disabled){outline:2px solid #99733b;outline-offset:-3px}.occupied-cell[aria-pressed=true],.target-cell[aria-pressed=true]{background-color:#772f37;border:2px solid #54212b;color:#fff3ce;box-shadow:inset 0 0 0 2px #d5b168;outline:2px solid #712d35;outline-offset:1px}.unit-label{font-weight:650}.grid-legend{display:flex;justify-content:center;flex-wrap:wrap;gap:8px 14px;font-size:14px;color:var(--muted);margin:8px 0}
label{font-size:15px;font-weight:650}label span,summary span{font-weight:400;color:var(--muted)}textarea{display:block;width:100%;max-width:100%;margin-top:8px;background:#fffcf4;border:1px solid #a88d63;border-radius:3px;padding:12px;color:var(--ink);resize:vertical;line-height:1.55;font-size:16px;min-height:104px}.field-help{font-size:14px!important;margin:8px 0 12px}.selection-label{font-size:14px;font-weight:650;margin:4px 0 12px}#tile-modes{min-width:0;margin:0 0 16px;padding:8px 12px;border:1px solid var(--line)}#tile-modes legend{font-size:14px;color:var(--muted)}#tile-modes label{display:flex;align-items:center;gap:8px;min-height:44px;font-size:14px}input[type=checkbox],input[type=radio]{width:20px;height:20px;flex:none;accent-color:var(--wine)}#seam-option{margin:12px 0;padding:12px;background:#eee1c6;border-left:3px solid #a48243}#seam-option label{display:flex;align-items:center;gap:8px;min-height:44px}#seam-option p{margin:6px 0 0}
.reference-disclosure{margin-top:14px;border:1px solid var(--line)}.reference-disclosure summary{padding:12px;background:#e8d5a8;cursor:pointer;font-size:14px;font-weight:650;min-height:44px}.reference-zone{padding:0 12px 12px;overflow-wrap:anywhere}.reference-zone img{display:block;max-width:100%;width:100%;max-height:180px;object-fit:contain;margin:12px 0;background:#dfd4be}.reference-zone #reference-browse{margin-top:12px;width:100%}.reference-zone #reference-status{margin:10px 0 0}.plan-summary{border-left:3px solid #a48243;background:#e9ddc3;padding:10px 12px;font-size:14px;font-weight:600;color:#4f3c25!important;line-height:1.5;margin:14px 0}.plan-summary:empty{display:none}.error{border-left:3px solid #923d36;background:#f3ded3;padding:12px;font-size:14px;line-height:1.5;margin:12px 0;overflow-wrap:anywhere}.retry-button{margin-bottom:12px;max-width:100%}
.map-column{min-width:0;padding:20px;background:#faf4e6}.result-header{display:flex;align-items:flex-start;gap:12px;justify-content:space-between;border-bottom:1px solid var(--line);padding-bottom:12px;margin-bottom:12px}.result-header h2{font-size:25px;margin:0}.generation-status{min-width:0;max-width:68%;display:flex;flex-direction:column;align-items:flex-end;gap:8px}.status{font-size:14px;line-height:1.5;text-align:right;color:#493628;overflow-wrap:anywhere}.status.busy{font-weight:650;color:#712d35}.status.busy:before{content:'';display:inline-block;width:8px;height:8px;background:#92662d;border-radius:50%;margin-right:8px;animation:pulse 1.5s infinite}@keyframes pulse{50%{opacity:.3}}#generation-clock{display:block;font-size:26px;line-height:1.2;font-weight:800;font-variant-numeric:tabular-nums;color:#fff9eb;background:#712d35;border-radius:3px;padding:8px 12px;white-space:nowrap}.inspection-toolbar{display:flex;align-items:center;flex-wrap:wrap;gap:8px;margin-bottom:12px}.inspection-toolbar>span{font-size:14px;line-height:1.5;color:var(--muted);flex:1;min-width:160px}#view-controls{display:flex;align-items:center;gap:8px;flex-wrap:wrap}#view-controls button{min-height:44px;min-width:44px;padding:8px;border:1px solid #b49c70;background:#faf4e7;color:var(--ink);font-size:14px}#view-controls button[aria-pressed=true]{background:#712d35;color:#fff5df}#zoom-level{min-width:48px;text-align:center;font-size:14px}
.stage{height:540px;min-height:260px;padding:14px;position:relative;display:flex;align-items:center;justify-content:center;overflow:hidden;border:1px solid #bca982;background-color:#ded8ca;background-image:conic-gradient(#cbc4b5 25%,#ded8ca 0 50%,#cbc4b5 0 75%,#ded8ca 0);background-size:24px 24px}.stage.drag-over{outline:3px solid #8c6325;outline-offset:3px}#map-box{position:relative;flex:none;max-width:100%;overflow:hidden;transform-origin:center;will-change:transform;cursor:zoom-in}#map-image{display:block;width:100%;height:100%;object-fit:contain;user-select:none}#map-box::after{content:'⌕';position:absolute;right:10px;top:10px;font-size:24px;line-height:1;background:#fff6dfeb;color:#35271f;border:1px solid #9b8053;border-radius:50%;padding:8px;pointer-events:none;opacity:0;z-index:4}#map-box:hover::after,#map-box:focus-visible::after{opacity:1}#map-box.drawing::after,#map-box.zoom-disabled::after{display:none}#map-box.drawing{cursor:crosshair}#map-box.moving #sketch-canvas{cursor:grab}#map-box.moving #sketch-canvas:active{cursor:grabbing}.vacant-preview-cell{position:absolute;pointer-events:none;background:conic-gradient(#cbc4b5 25%,#ded8ca 0 50%,#cbc4b5 0 75%,#ded8ca 0);background-size:24px 24px;z-index:1}#target-highlight{position:absolute;z-index:2;pointer-events:none;box-shadow:inset 0 0 0 2px #f5d88d,inset 0 0 0 4px #712d35aa}.empty-state{text-align:center;max-width:410px;padding:24px 16px;background:#f9f3e7f5;border:1px solid #c4b28e}.empty-state h3{font-size:26px;margin:12px 0}.empty-state p{font-size:15px;color:var(--muted)}.empty-state .primary-button{width:auto;margin:auto;display:inline-flex}.compass{font-size:40px;color:#916f35}
.map-footer{display:flex;justify-content:space-between;flex-wrap:wrap;gap:8px;font-size:14px;color:var(--muted);padding:10px 0;border-bottom:1px solid var(--line)}.toolbar{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin:12px 0}.download-controls{display:flex;align-items:center;gap:8px;flex-wrap:wrap;max-width:100%;min-width:0;margin-left:auto}.download-controls label{font-size:14px;color:var(--muted)}select{max-width:100%;background:#fffbf1;color:var(--ink);font-weight:400}#download{background:#684b2d;color:#fff5df;text-decoration:none;text-align:center;display:inline-flex;align-items:center;justify-content:center}#download.disabled{opacity:.45;pointer-events:none}.download-legend{font-size:14px;line-height:1.5;color:var(--muted);margin:0}.site-footer{max-width:2200px;margin:auto;padding:0 24px 16px;font-size:14px;color:#604b30;display:flex;justify-content:space-between;flex-wrap:wrap;gap:8px}
.draw-steps{display:none}.draw-steps li{display:flex;flex-direction:column;font-size:15px}.draw-steps span{font-size:14px;color:var(--muted)}.brush-row{display:flex;flex-direction:column;gap:8px}.brush-row label{display:flex;justify-content:space-between}.brush-row output{font-size:14px;color:var(--muted);font-weight:400}#brush-size{width:100%;accent-color:var(--wine);min-height:44px;margin:0}.sketch-actions{display:flex;flex-wrap:wrap;gap:8px;margin:8px 0 12px}.sketch-actions button{flex:1}#clear-sketch{background:var(--wine);color:#fff5df;border-color:#58212a}#region-info{padding:10px 12px;background:#eadfc8;border-left:3px solid #b99751;margin:0 0 12px;font-size:14px}#sketch-canvas{position:absolute;inset:0;width:100%;height:100%;z-index:5;touch-action:none;cursor:crosshair}#sketch-canvas:focus-visible{outline:3px solid #712d35;outline-offset:-3px}#region-rectangle{position:absolute;z-index:4;border:2px dashed #fff0a5;box-shadow:0 0 0 1px #712d35,inset 0 0 0 1px #712d35;background:#b9975129;pointer-events:none}#region-rectangle>small{position:absolute;top:0;left:0;padding:3px 6px;background:#712d35;color:#fff3d9;font-size:14px;white-space:nowrap}.region-affected{outline:3px solid #b99751;outline-offset:-3px!important}.region-tile-highlight{position:absolute;z-index:3;pointer-events:none;border:1px solid #f6d586a6;box-shadow:inset 0 0 0 1px #35271f99;background:#b997510c}.region-tile-highlight small:empty{display:none}
.video-panel{border:1px solid var(--line);background:#eee0c4;padding:16px;margin-bottom:12px}.video-panel h3{font-size:23px;margin-bottom:8px}.video-panel p{font-size:14px}.video-panel video{display:block;width:100%;max-height:300px;background:#28201c}.video-actions{display:flex;gap:8px;flex-wrap:wrap}.video-actions .primary-button{width:auto}
#map-enlargement{position:fixed;inset:0;z-index:9999;display:grid;grid-template-rows:auto minmax(0,1fr) auto;gap:12px;background:#18120ef5;padding:16px;overflow:auto;color:#fff5df}#enlargement-close{grid-column:1;grid-row:1;justify-self:end;z-index:2;min-height:44px;padding:10px 16px;background:#fff5df;color:#35271f;border:1px solid #b99751;font-size:14px}.preview-controls{grid-row:1;grid-column:1;align-self:start;display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-right:120px;font-size:14px}.preview-controls button{min-width:44px;min-height:44px;background:#fff5df;color:#35271f;border:1px solid #b99751;font-size:15px}.preview-controls output{min-width:48px;text-align:center}#preview-quality{font-size:14px;flex-basis:100%}#preview-viewport{grid-row:2;width:100%;height:100%;min-height:120px;display:flex;align-items:center;justify-content:center;overflow:hidden;touch-action:none}#enlarged-map{position:relative;flex:none;max-width:none;overflow:hidden;transform-origin:center;cursor:zoom-in;touch-action:none;user-select:none;box-shadow:0 0 0 2px #b99751;background:#ded8ca}#enlarged-map>img{display:block;width:100%;height:100%;object-fit:fill;pointer-events:none}#enlarged-map:active{cursor:grabbing}.enlargement-hint{grid-row:3;text-align:center;font-size:14px;line-height:1.5;margin:0;color:#fff5df;pointer-events:none}
#download-dialog,#reset-dialog,#daily-limit-dialog{max-width:min(480px,calc(100vw - 32px));max-height:calc(100dvh - 32px);overflow:auto;padding:24px;background:var(--paper);color:var(--ink);border:1px solid #ad8b54;box-shadow:0 12px 48px #0005}dialog::backdrop{background:#21160e99}dialog h2{font-size:26px}dialog p{font-size:15px}.dialog-links{display:grid;gap:8px;margin:18px 0}.dialog-links a{min-height:44px;padding:12px;border:1px solid #b49c70;background:#e9d9b5;font-weight:650;overflow-wrap:anywhere}.reset-actions{display:flex;gap:8px;justify-content:flex-end}
@media(min-width:1000px) and (min-height:600px){body{height:100dvh;display:flex;flex-direction:column}.site-header{flex:none;padding:10px 22px}.brand{font-size:20px}.brand small{font-size:14px;margin-top:2px}main{width:100%;max-width:2200px;margin:0 auto;padding:12px 16px 0;flex:1;min-height:0;display:flex;flex-direction:column}.workbench{flex:1;min-height:0;display:flex;flex-direction:column}.bench-header{padding:10px 18px;flex:none}h1{font-size:28px}.workspace{flex:1;min-height:0;grid-template-rows:minmax(0,1fr);grid-template-columns:minmax(350px,390px) minmax(0,1fr)}.controls{min-height:0;contain:layout paint;padding:14px;display:flex;flex-direction:column;overflow:hidden}.controls-main{flex:1;min-height:0;overflow:auto;scrollbar-width:auto;display:flex;flex-direction:column;gap:12px;padding:0 8px 12px 0;scroll-padding-block:12px}.controls-main>*{flex:none}.control-section{margin:0;padding-bottom:16px}.step-heading h2{font-size:22px}.controls-main>.control-section:first-child{display:grid;grid-template-columns:1fr auto;align-items:center;gap:8px}.controls-main>.control-section:first-child .step-heading{grid-column:1;margin:0}#browse-file{grid-column:2;grid-row:1}.controls-main>.control-section:first-child .help-disclosure,.controls-main>.control-section:first-child .file-hint{grid-column:1/-1}.controls-main>.mode-guide,.controls-main>.bench-note{display:none}.work-mode{margin:0}.help-disclosure{margin:0 0 8px}.controls-actions{flex:none;display:flex;flex-direction:column;gap:8px;background:var(--paper);border-top:1px solid var(--line);padding-top:10px;max-height:52%;overflow:auto}.controls:has(#prompt-panel[hidden]):not(:has(#error:not([hidden]))) .controls-actions{display:none}.controls:has(#prompt-panel[hidden]) .controls-actions #generate,.controls:has(#prompt-panel[hidden]) .controls-actions #plan-summary{display:none}.controls-actions .plan-summary{margin:0;padding:8px 10px}.controls-actions .error{margin:0;max-height:120px;overflow:auto}.controls-actions .retry-button{margin:0}.controls-main #prompt-panel{min-height:0}.prompt-options{overflow:visible}.map-column{padding:14px 18px;min-height:0;contain:layout paint;display:flex;flex-direction:column}.result-header,.inspection-toolbar,.map-footer,.toolbar,.download-legend{flex:none}.stage{flex:1;height:auto;min-height:80px}.result-header{margin-bottom:8px;padding-bottom:10px}.inspection-toolbar{margin-bottom:8px}.map-footer{padding:8px 0}.toolbar{margin:10px 0}.download-controls label{display:none}.download-legend{font-size:14px}.site-footer{width:100%;max-width:2200px;flex:none;padding:6px 16px 8px}.video-panel{flex:none;max-height:54%;overflow:auto;padding:12px}.video-panel video{max-height:140px}.video-panel p{margin-bottom:8px}}
@media(max-width:999px){main{margin:14px auto;padding:0 14px}.workspace{display:flex;flex-direction:column}.controls{display:contents;border:0}.controls>.control-section:first-child{margin:18px 18px 0}.controls>.mode-guide{margin:12px 18px 8px!important}.controls>.work-mode{margin:0 18px 16px}.controls>#placement-section,.controls>#draw-tools{margin:0 18px 16px}.controls>.bench-note{display:none}.map-column{padding:18px;border-top:1px solid var(--line)}.stage{height:clamp(280px,48vw,500px);min-height:240px;padding:10px}#prompt-panel{margin:20px 0 0}#prompt-panel>.control-section{margin-bottom:0}.map-column>#error,.map-column>#retry{margin-top:12px}.grid-scroll{height:288px;min-height:288px;max-height:360px}#cell-grid{max-width:440px}.draw-steps{grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.result-header{flex-wrap:wrap}.generation-status{max-width:100%;align-items:flex-start}.status{text-align:left}.download-controls{flex-basis:100%;margin-left:0;justify-content:flex-start}.download-controls label{flex-basis:100%}.mobile-drawing .stage{height:clamp(220px,calc((100vw - 70px)/var(--map-ratio,1) + 20px),500px);min-height:220px}.site-footer{padding:0 14px 16px}}
@media(max-width:480px){.site-header{padding:14px 16px;gap:8px}.brand{font-size:19px}.brand small{font-size:14px}.beta-badge{font-size:14px}.bench-header{padding:14px;align-items:flex-start;flex-wrap:wrap;gap:12px}h1{font-size:27px}#reset-workspace{max-width:none}.controls>.control-section:first-child{margin:16px 14px 0}.controls>.mode-guide{margin-left:14px!important;margin-right:14px!important}.controls>.work-mode{margin-left:14px;margin-right:14px}.controls>#placement-section,.controls>#draw-tools{margin-left:14px;margin-right:14px}.map-column{padding:14px}.stage{height:290px;min-height:240px;padding:8px}.inspection-toolbar>span{flex-basis:100%}.draw-steps{grid-template-columns:1fr;gap:8px}.draw-steps li{display:block}.draw-steps span{display:block}.toolbar>.quiet-button{flex:1}.download-controls select,.download-controls #download{flex:1;min-width:0}.download-controls #download{flex-basis:100%}.grid-legend{gap:8px}.preview-controls{margin-right:0;grid-row:2}.preview-controls #preview-quality{flex-basis:100%}#map-enlargement{grid-template-rows:auto auto minmax(120px,1fr) auto;padding:12px;gap:10px}#enlargement-close{grid-row:1}#preview-viewport{grid-row:3}.enlargement-hint{grid-row:4}.empty-state{padding:18px 12px}.empty-state h3{font-size:23px}.compass{display:none}}
/* v24: minimal workstation, fewer vertical layers, no tutorial furniture. */
.help-disclosure,.grid-legend,.unit-label,.mode-guide,.bench-note,.selection-label,#prompt-panel .step-heading,#placement-section .step-heading,.plan-summary,#seam-option .field-help{display:none!important}
.result-header{align-items:center;border:0;padding:0;margin:0 0 6px;min-height:36px;gap:6px}.inspection-toolbar{margin:0;gap:4px;flex:none}.generation-status{display:none;max-width:none;flex:1}.generation-status.active{display:flex}.status{font-size:14px}.result-header .inspection-toolbar>span{display:none}#generation-clock{font-size:24px;padding:3px 8px}.map-footer{padding:4px 0;border:0;min-height:24px}.toolbar{margin:4px 0 0;gap:4px}.download-controls{gap:4px}.download-controls label{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
#cell-grid{max-width:none;grid-auto-rows:72px;gap:4px}.occupied-cell,.target-cell{min-width:72px;min-height:72px;padding:3px}.occupied-cell small,.target-cell small{font-size:13px;margin-top:1px}.grid-scroll{height:232px;min-height:232px;max-height:232px;padding:4px;scroll-padding:4px}.control-section{margin-bottom:8px;padding-bottom:6px}.step-heading{margin-bottom:4px}.work-mode{margin-bottom:6px;gap:4px;padding:2px}.prompt-options{display:grid;grid-template-columns:1fr 1fr;gap:4px 8px}.prompt-options>.prompt-label-block,.prompt-options>#prompt,.prompt-options>#prompt-help{grid-column:1/-1}textarea{margin:0;padding:6px 8px;min-height:64px;height:64px;line-height:1.4;resize:vertical}#seam-option{margin:0;padding:0;background:none;border:0;align-self:start}#seam-option label{font-size:14px;gap:4px}.reference-disclosure{margin:0;align-self:start}.reference-disclosure summary{padding:7px 8px}.reference-zone{padding:0 8px 8px}.reference-zone img{max-height:100px;margin:4px 0}.reference-zone #reference-browse{margin-top:4px}.reference-zone #reference-status{margin:4px 0 0}#tile-modes{margin:0 0 4px;padding:0;border:0;display:flex;flex-wrap:wrap;gap:4px 12px}#tile-modes legend{display:none}#tile-modes label{min-height:32px;font-size:14px}#region-info{margin:4px 0;padding:4px 8px}.brush-row{gap:0}.sketch-actions{gap:4px;margin:4px 0}.brush-row output{font-size:14px}
@media(min-width:1000px) and (min-height:600px){
.site-header{padding:5px 18px}.brand{font-size:18px}.brand small{display:inline;font-size:13px;margin-left:8px}.bench-header{padding:6px 12px}h1{font-size:25px}main{padding:8px 12px 0}.site-footer{padding:3px 12px 5px;font-size:12px}.workspace{grid-template-columns:clamp(440px,38vw,540px) minmax(0,1fr)}.controls{padding:8px 10px}.controls-main{gap:6px;padding:0 4px 4px 0}.controls-main>.control-section:first-child{gap:4px;padding-bottom:4px;min-height:36px}.step-heading h2{font-size:21px}.control-section{padding-bottom:0;border:0}.work-mode{margin:0}.controls-actions{gap:4px;padding-top:4px;max-height:40%}.map-column{padding:8px 10px;gap:0}.result-header{flex:none;min-height:36px;margin:0 0 4px}.stage{min-height:120px;padding:8px}.map-footer{flex:none}.toolbar{flex:none}.primary-button,.secondary-button,.quiet-button,.retry-button,#download,select{min-height:36px;padding:6px 10px}.work-mode button{min-height:36px;padding:5px 8px}#view-controls{gap:4px}#view-controls button{min-height:36px;min-width:36px;padding:5px}#seam-option label,.reference-disclosure summary{min-height:36px}#tile-modes label{min-height:32px}.download-controls{flex-wrap:nowrap}.toolbar{flex-wrap:nowrap}.reference-disclosure:only-child{grid-column:1/-1}
}
@media(min-width:1000px) and (min-height:600px) and (max-height:740px){.grid-scroll{height:216px;min-height:216px;max-height:216px}#cell-grid{grid-auto-rows:66px}.occupied-cell,.target-cell{min-height:66px}textarea{min-height:56px;height:56px}.controls-main{gap:4px}}
@media(max-width:999px){.controls>.control-section:first-child{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-top:10px}.controls>.control-section:first-child .step-heading{margin:0}.controls>.work-mode{margin-top:4px;margin-bottom:8px}.controls>#placement-section,.controls>#draw-tools{margin-bottom:8px}.grid-scroll{height:232px;min-height:232px;max-height:232px}.map-column{padding-top:8px}.result-header{flex-wrap:nowrap}.generation-status{align-items:flex-end}.status{font-size:13px}.map-footer{padding:4px 0}.toolbar{margin:4px 0}#prompt-panel{margin-top:8px}.download-controls{flex-basis:auto;margin-left:auto}.download-controls #download{flex-basis:auto}#prompt-panel>.control-section{border:0}.prompt-options{gap:4px}.reference-disclosure summary{font-size:13px}.site-footer{padding-top:4px}}
@media(max-width:480px){.bench-header{padding:8px;gap:6px;align-items:center}h1{font-size:23px}#reset-workspace{padding:8px;font-size:13px}.site-header{padding:8px 12px}.brand{font-size:18px}.brand small{font-size:12px}.step-heading h2{font-size:21px}.toolbar{flex-wrap:wrap}.download-controls{width:100%;margin:0}.download-controls select{flex:0 1 95px}.download-controls #download{flex:1;min-width:0}.reference-disclosure summary{padding:8px 4px}#seam-option label{font-size:13px}.generation-status.active{max-width:70%}.status{font-size:12px}}
.prompt-options{grid-template-columns:minmax(0,1fr) minmax(0,1fr)}.prompt-options>*{min-width:0}.reference-disclosure summary{overflow-wrap:anywhere}
@media(max-width:999px){.result-header .inspection-toolbar{min-width:0;flex:1;flex-wrap:wrap}.result-header #view-controls{min-width:0;max-width:100%}.result-header{align-items:flex-start}.generation-status.active{flex-basis:100%}.result-header:has(.generation-status.active){flex-wrap:wrap}}
@media(min-width:1000px) and (min-height:600px){.grid-scroll{height:auto;min-height:216px;max-height:clamp(216px,calc(100dvh - 420px),360px)}}
@media(min-width:1000px) and (min-height:600px){.prompt-options:has(#seam-option[hidden])>.prompt-label-block{grid-column:1;grid-row:1;align-self:center}.prompt-options:has(#seam-option[hidden])>.reference-disclosure{grid-column:2;grid-row:1}.prompt-options:has(#seam-option[hidden])>#prompt{grid-row:2}.reference-zone>.field-help:first-of-type{display:none}}
.reference-disclosure summary{font-size:13px;padding-left:4px;padding-right:4px}
@media(min-width:1000px) and (min-height:600px){.prompt-options:has(.reference-disclosure[open])>.reference-disclosure{grid-column:1/-1;grid-row:3}.prompt-options:has(.reference-disclosure[open])>.prompt-label-block{grid-column:1/-1;grid-row:1}.prompt-options:has(.reference-disclosure[open])>#prompt{grid-row:2}}
.reference-zone>.field-help:first-of-type{display:none}
@media(max-width:999px){.prompt-options:has(#seam-option[hidden])>.reference-disclosure{grid-column:1/-1}}
@media(prefers-reduced-motion:reduce){.status.busy:before{animation:none}}

/* v24: automatic edge blending; primary action unmistakable, active-job timer only. */
#seam-option{display:none!important}
#generate{min-height:56px;font-size:18px;padding:12px 18px;justify-content:center;gap:8px;font-weight:750}
@media(min-width:1000px) and (min-height:600px){.control-section{margin:0}.controls-main{gap:2px}.controls-actions{padding-top:2px}}

/* v25: canonical WP14 navigation; only its footprint is compacted locally. */
#gmct-shared-header{flex:none}
/* The canonical menu replaces the duplicate local brand strip. */
.site-header{display:none}
#gmct-shared-header .gkit20bd4e>.gkit-block__inner{min-height:76px!important;gap:12px!important}
#gmct-shared-header .gkit20bd4e .gkit886b3b{width:160px!important;max-width:160px!important;flex-basis:160px!important}
#gmct-shared-header .gkit20bd4e .gkit6fed38 img{width:160px!important}
#gmct-shared-header .gkit20bd4e .gkite3a3b9{max-width:calc(100% - 172px)!important}
#gmct-shared-header .gkit20bd4e{border-bottom-width:3px!important}
@media(max-width:1024px){#gmct-shared-header .gkit20bd4e>.gkit-block__inner{min-height:76px!important}#gmct-shared-header .gkit20bd4e .gkit886b3b{width:140px!important;max-width:140px!important;flex-basis:140px!important}#gmct-shared-header .gkit20bd4e .gkit6fed38 img{width:140px!important}#gmct-shared-header .gkit20bd4e .gkite3a3b9{max-width:calc(100% - 152px)!important}}

@media(min-width:1000px) and (min-height:600px){#gmct-shared-header .gkit20bd4e>.gkit-block__inner{min-height:60px!important}#gmct-shared-header .gkit20bd4e .gkit6fed38 img{width:120px!important}#cell-grid{grid-auto-rows:66px}.occupied-cell,.target-cell{min-height:66px}}
@media(min-width:1000px) and (min-height:600px) and (max-height:740px){#cell-grid{grid-auto-rows:66px}.occupied-cell,.target-cell{min-height:66px}textarea{min-height:48px;height:48px}}

@media(min-width:1000px) and (min-height:600px){.bench-header{padding:4px 12px}main{padding-top:6px}textarea{min-height:56px;height:56px}}
@media(min-width:1000px) and (min-height:600px) and (max-height:740px){textarea{min-height:48px;height:48px}}

@media(min-width:1000px) and (min-height:600px) and (max-height:740px){.bench-header{padding-top:0;padding-bottom:0}h1{font-size:22px}main{padding-top:4px}.controls{padding-top:6px;padding-bottom:6px}}

/* v41: fixed-size future cells and UI-only passage rulers. */
#map-scene{position:relative;flex:none;transform-origin:center;touch-action:none}
#map-scene>#map-box{position:absolute;max-width:none}
#extension-guides{position:absolute;pointer-events:none;z-index:6}
.main-target{position:absolute;pointer-events:auto;border:2px dashed #99733b;background:#faf4e7b8;color:#60451f;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;padding:2px;line-height:1.1}
.main-target>span{font-size:28px}.main-target>small{font-size:12px}.main-target[aria-pressed=true]{border:3px solid #712d35;background:#dfbc8277;box-shadow:inset 0 0 0 2px #f4dda8}
.passage-zone{position:absolute;background:#dc24244d;border:1px solid #a91d29;pointer-events:none;z-index:2}
.passage-control{position:absolute;pointer-events:auto;z-index:4;touch-action:none;user-select:none}
.passage-add{width:auto!important;height:auto!important;min-height:32px;padding:5px 7px;border:1px solid #712d35;border-radius:3px;background:#fff4df;color:#712d35;font-size:12px;white-space:nowrap;transform:translate(-50%,-50%)}
#passage-actions{display:flex;gap:6px;flex-wrap:wrap;flex:none;margin-bottom:4px}#passage-actions .passage-add{position:static;transform:none;min-height:36px}
.passage-control:focus-visible{outline:3px solid #8b4d14;outline-offset:2px}.passage-control[aria-disabled=true]{opacity:.5;cursor:not-allowed}
#passage-legend{font-size:12px;line-height:1.35;color:#712d35;margin:5px 0;flex:none;max-width:100%}
@media(max-width:480px){.passage-add{font-size:11px;padding:4px;min-height:28px}.main-target>small{font-size:11px}.main-target>span{font-size:22px}}
/* v39: interface-only orientation and a compact directional prompt tip. */
.stage{padding:28px}
.map-direction{position:absolute;z-index:8;pointer-events:none;user-select:none;display:flex;align-items:center;justify-content:center;width:22px;height:22px;border:1px solid #9b8053;border-radius:3px;background:#faf4e7f5;color:#503b26;font-size:12px;font-weight:750;line-height:1;box-shadow:0 1px 3px #35271f20}
.map-direction.north{top:3px;left:50%;transform:translateX(-50%)}
.map-direction.east{right:3px;top:50%;transform:translateY(-50%)}
.map-direction.south{bottom:3px;left:50%;transform:translateX(-50%)}
.map-direction.west{left:3px;top:50%;transform:translateY(-50%)}
.controls #direction-tip{font-size:12px;line-height:1.35;margin:5px 0 2px;color:var(--muted)}
@media(min-width:1000px) and (min-height:600px) and (max-height:800px){#cell-grid{grid-auto-rows:60px}.occupied-cell,.target-cell{min-height:60px}}
@media(min-width:1000px) and (min-height:600px) and (max-height:740px){#cell-grid{grid-auto-rows:56px}.occupied-cell,.target-cell{min-height:56px}}

/* v45: actual editable rectangle; hit areas exceed the visible square handles. */
.passage-zone.passage-move{width:auto;height:auto;min-width:0;min-height:0;display:block;transform:none;border:2px solid #a91d29;border-radius:0;background:#dc24244d;cursor:move;z-index:5}
.passage-handle{position:absolute;width:10px;height:10px;border:1px solid #86232c;background:#fff4df;transform:translate(-50%,-50%);z-index:6;box-sizing:border-box}
.passage-handle:before{content:'';position:absolute;inset:0}
.passage-handle[data-handle=n]:before{inset:-10px -8px 0}
.passage-handle[data-handle=s]:before{inset:0 -8px -10px}
.passage-handle[data-handle=w]:before{inset:0 0 0 -10px}
.passage-handle[data-handle=e]:before{inset:0 -10px 0 0}
.passage-handle[data-handle=nw]:before{inset:-10px 0 0 -10px}
.passage-handle[data-handle=ne]:before{inset:-10px -10px 0 0}
.passage-handle[data-handle=sw]:before{inset:0 0 -10px -10px}
.passage-handle[data-handle=se]:before{inset:0 -10px -10px 0}
.passage-handle[data-handle=n]{left:50%;top:0;cursor:ns-resize}.passage-handle[data-handle=s]{left:50%;top:100%;cursor:ns-resize}
.passage-handle[data-handle=w]{left:0;top:50%;cursor:ew-resize}.passage-handle[data-handle=e]{left:100%;top:50%;cursor:ew-resize}
.passage-handle[data-handle=nw]{left:0;top:0;cursor:nwse-resize}.passage-handle[data-handle=ne]{left:100%;top:0;cursor:nesw-resize}
.passage-handle[data-handle=sw]{left:0;top:100%;cursor:nesw-resize}.passage-handle[data-handle=se]{left:100%;top:100%;cursor:nwse-resize}

/* v47 occupied hit surfaces stay below opening rulers, without obscuring map art. */
#extension-guides .main-occupied{position:absolute;pointer-events:auto;padding:0;border-radius:0;background:transparent;border:1px solid transparent;box-shadow:none;z-index:0;color:transparent}
#extension-guides .main-occupied:hover:not(:disabled){background:#fff4cd22;border-color:#99733b}
#extension-guides .main-occupied[aria-pressed=true],#extension-guides .main-occupied:focus-visible{background:transparent;border:2px solid #712d35;box-shadow:inset 0 0 0 1px #f4dda8}

/* v49: honest job-only, stage-centered waiting card. */
#edit-choices{border:1px solid var(--line);padding:8px;margin:4px 0}#edit-choices label{display:flex;align-items:center;gap:8px;min-height:40px;font-size:14px}#edit-choices p{margin:4px 0;font-size:13px}#edit-choices legend{font-weight:700}#forge-wait{position:relative;box-sizing:border-box;width:100%;min-height:84px;margin:0 0 12px;padding:6px 14px;display:flex;align-items:center;gap:14px;border:1px solid #a88a57;border-radius:8px;background:linear-gradient(110deg,#1b2228,#2e2924);color:#f7ead1;box-shadow:0 3px 10px #21160e20}#forge-wait video,.forge-wait-poster{flex:0 0 72px;width:72px;height:72px;object-fit:contain;border-radius:5px}.forge-wait-poster{display:none}.forge-wait-content{flex:1;min-width:0;display:grid;grid-template-columns:minmax(120px,1fr) auto;align-items:center;gap:4px 18px}#forge-wait #status{grid-column:1;grid-row:2;text-align:left;font-size:13px;color:#e2d5bd;margin:0}#forge-wait #generation-clock{grid-column:1;grid-row:1;font-size:17px;color:#ffe2a3;margin:0;white-space:normal}#forge-wait #cancel-generation{grid-column:2;grid-row:1/3;min-height:40px;margin:0;background:#f5ebda;color:#3d2c20;white-space:nowrap}#forge-wait .busy:before{display:none}@media(prefers-reduced-motion:reduce){#forge-wait video{display:none}.forge-wait-poster{display:block}}@media(max-width:480px){#forge-wait{padding:6px;gap:8px;min-height:78px}#forge-wait video,.forge-wait-poster{width:64px;height:64px;flex-basis:64px}.forge-wait-content{grid-template-columns:minmax(0,1fr) auto;gap:3px 6px}#forge-wait #generation-clock{font-size:13px}#forge-wait #status{font-size:11px}#forge-wait #cancel-generation{font-size:11px;padding:6px;white-space:normal;max-width:82px}}

#forge-wait #generation-clock{background:none;padding:0}

/* v52: centered in-flow waiting group; avoid a low-resolution promoted map layer. */
#forge-wait{width:fit-content;max-width:100%;margin:0 auto 12px;justify-content:center}
#forge-wait .forge-wait-content{flex:0 1 auto;grid-template-columns:minmax(120px,340px) auto}
.generation-status:not(:has(#status)){display:none}
#map-scene>#map-box{will-change:auto}
#map-scrollbars{position:absolute;inset:0;pointer-events:none;z-index:12}
.map-scrollbar{position:absolute;display:flex;align-items:stretch;gap:2px;pointer-events:auto;background:#e8ddc8;border:1px solid #a58a60;border-radius:4px;padding:1px;box-sizing:border-box;touch-action:none}
.map-scrollbar.horizontal{left:6px;right:30px;bottom:5px;height:20px}
.map-scrollbar.vertical{top:6px;bottom:30px;right:5px;width:20px;flex-direction:column}
.map-scrollbar button{display:flex;align-items:center;justify-content:center;flex:0 0 16px;width:16px;height:16px;min-height:0;padding:0;border:0;border-radius:2px;background:#f9efd9;color:#593f26;font-size:12px;line-height:1}
.map-scroll-track{position:relative;flex:1;min-width:0;min-height:0;background:#d5c7ad;border-radius:3px}
.map-scroll-thumb{position:absolute;border:1px solid #8a6a3d;border-radius:3px;background:linear-gradient(90deg,#f3dfba,#bb965d);cursor:grab;box-sizing:border-box;touch-action:none}
.horizontal .map-scroll-thumb{height:100%;top:0}.vertical .map-scroll-thumb{width:100%;left:0}
.map-scroll-thumb:active{cursor:grabbing}.map-scroll-thumb:focus-visible{outline:2px solid #712d35;outline-offset:1px}
.stage .map-direction.south{bottom:27px}.stage .map-direction.east{right:27px}
@media(max-width:480px){#forge-wait .forge-wait-content{grid-template-columns:minmax(0,1fr) auto}}

/* v53: language guidance directly below every scene-description label. */
.prompt-label-block{min-width:0}.prompt-label-block label{display:block}#prompt-language-note{display:block;margin:2px 0 5px;font-size:11px;line-height:1.35;font-weight:400;color:var(--muted)}

.project-tools{display:flex;gap:.5rem;flex-wrap:wrap;margin-top:.5rem}.project-tools [hidden]{display:none!important}.recovery-warning{font-size:.8rem;line-height:1.45;color:#dbc7a0;background:#211c18;border:1px solid #665139;border-radius:8px;padding:.6rem .8rem;margin:.65rem 0}.download-name{display:flex;flex-direction:column;gap:.25rem;font-size:.75rem;min-width:130px;max-width:220px}.download-controls .download-name{position:static;clip:auto;clip-path:none;width:auto;height:auto;overflow:visible;white-space:normal;margin:0;display:flex}.control-section:has(>.project-tools){flex-wrap:wrap}.project-tools{flex-basis:100%}.download-name input{min-width:0;width:100%;box-sizing:border-box;color:#f7ebd1;background:#211c18;border:1px solid #776246;border-radius:5px;padding:.45rem}.download-controls{flex-wrap:wrap}.project-downloads{display:flex;flex-direction:column;gap:.7rem;margin:1rem 0}.project-downloads a{text-align:center}@media(max-width:600px){.download-name{max-width:none;width:100%}.project-tools .quiet-button{flex:1 1 130px}.recovery-warning{font-size:.75rem}}

/* v55: more map space; retain every control and desktop/mobile access. */
.recovery-warning{margin:3px 0;padding:4px 8px;line-height:1.3;border-radius:4px}
@media(min-width:1000px) and (min-height:600px){
main{padding:3px 6px 0}
.bench-header{padding:3px 8px;gap:8px}h1{font-size:22px}
.workspace{grid-template-columns:clamp(330px,25vw,400px) minmax(0,1fr)}
.controls{padding:6px}.controls-main{gap:4px;padding-right:3px}
.step-heading h2{font-size:19px}.project-tools{margin-top:2px;gap:4px}
.grid-scroll{height:200px;min-height:200px;max-height:200px}
#cell-grid{grid-auto-rows:60px}.occupied-cell,.target-cell{min-height:60px;min-width:56px}
.map-column{padding:4px 6px}.result-header{margin-bottom:3px;min-height:32px}
#forge-wait{min-height:52px;padding:3px 10px;gap:8px;margin:2px auto 4px}
#forge-wait video,#forge-wait .forge-wait-poster{width:44px;height:44px;flex-basis:44px}
#forge-wait #generation-clock{font-size:15px}#forge-wait #status{font-size:12px}
#forge-wait #cancel-generation{min-height:34px;padding:5px 8px}
.map-footer{min-height:16px;padding:1px 0;font-size:12px}
.toolbar{margin-top:2px;align-items:center;gap:4px}
.download-controls .download-name{flex-direction:row;align-items:center;gap:5px;min-width:0;max-width:200px;font-size:12px}
.download-name input{width:132px;padding:5px 6px}
.download-controls{flex-wrap:nowrap;min-width:0}
#download{white-space:nowrap}.site-footer{padding:2px 8px;font-size:11px}
#passage-legend{font-size:11px;line-height:1.25;margin:3px 0}
}

/* v63: compact upper-left status, never a workspace-height row. */
#forge-wait{width:100%;max-width:400px;min-height:60px;margin:0 0 6px;padding:6px;gap:8px;justify-content:flex-start;flex:none}
#forge-wait video,#forge-wait .forge-wait-poster{width:40px;height:40px;flex-basis:40px}
#forge-wait .forge-wait-content{flex:1;grid-template-columns:minmax(0,1fr) auto;gap:3px 6px}
#forge-wait #generation-clock{font-size:14px;line-height:1.25}
#forge-wait #status{font-size:12px;line-height:1.3}
#forge-wait #cancel-generation{font-size:12px;min-height:36px;max-width:78px;padding:5px;white-space:normal}
@media(min-width:1000px) and (min-height:600px){.result-header{min-height:26px}.map-column{padding-top:2px;padding-bottom:2px}}
@media(max-width:999px){#forge-wait{margin:10px 14px;max-width:calc(100% - 28px);position:sticky;top:8px;z-index:40;align-self:flex-start}}

@media(min-width:1000px) and (min-height:600px){.result-header{padding-bottom:4px}.stage{padding-block:20px}}

.inspection-toolbar .map-footer{padding:0;min-height:0;align-self:center;gap:4px;font-size:12px}
.inspection-toolbar #passage-actions{margin:0;min-width:0;max-width:100%;align-self:center}

/* v65: paired project actions; preserve conditional recovery availability. */
.project-tools{display:grid;grid-column:1/-1;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;width:100%;margin-top:8px}
.project-tools .project-action{display:flex;align-items:center;justify-content:flex-start;gap:9px;min-width:0;min-height:58px;margin:0;padding:10px;border:1px solid #87704d;border-radius:10px;background:linear-gradient(145deg,#383129,#252321);color:#f5e5c8;box-shadow:inset 0 1px 0 #ffffff0d,0 2px 5px #0002;text-align:left;font-family:inherit;font-size:12px;font-weight:600;line-height:1.35;cursor:pointer;transition:border-color .15s,background .15s}
.project-tools .project-action span{min-width:0;font-size:12px;line-height:1.35;font-weight:600}
.project-tools .project-action svg{width:19px;height:19px;flex:0 0 19px;fill:none;stroke:#e6be77;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.project-tools .project-action:hover:not(:disabled){border-color:#e6be77;background:linear-gradient(145deg,#493d2e,#302b24)}
.project-tools .project-action:focus-visible{outline:2px solid #e6be77;outline-offset:3px}
.project-tools .project-action:disabled{opacity:.45;cursor:not-allowed}
.project-tools #recover-local{grid-column:1/-1}

/* v66: description first, optional advice collapsed and openings directly on map. */
#tile-modes{display:none!important}
.prompt-options{display:flex!important;flex-direction:column;gap:6px}
.prompt-options>.prompt-label-block{order:0;align-self:stretch!important}
.prompt-options>#prompt{order:1;flex:none;width:100%;min-height:80px;height:80px}
#opening-hint{order:2;font-size:11px;line-height:1.35;color:var(--muted);margin:0}
.prompt-options>.reference-disclosure{order:3;align-self:stretch!important;width:100%}
.prompt-options>.prompt-tips{order:4}
.prompt-options>#seam-option{order:5}
.prompt-tips{border-top:1px solid #d5c39f;margin:0;padding:0}
.prompt-tips>summary{cursor:pointer;min-height:32px;padding:7px 2px;color:var(--muted);font-size:12px;font-weight:600}
.prompt-tips>summary:focus-visible{outline:2px solid var(--wine);outline-offset:2px}
.prompt-tips .tips-body{padding:2px 0 8px;font-size:12px;line-height:1.45}
.prompt-tips .tips-body p,.prompt-tips .tips-body small{font-size:12px;margin:0 0 8px}
.prompt-tips .draw-steps{display:none}
.reference-disclosure summary{min-height:32px;padding:7px 8px}

/* v67: compact export dock; preserve native controls, labels and handlers. */
.map-column>.toolbar{display:flex;align-items:center;flex-wrap:wrap;gap:8px;margin:7px 0 2px;padding:7px 8px;border:1px solid #c3ab7c;border-radius:10px;background:linear-gradient(180deg,#fffaf0,#eee2c9);box-shadow:0 2px 6px #49341b0d,inset 0 1px 0 #fff9;min-width:0}
.toolbar>#undo,.toolbar>#redo{flex:0 0 auto;min-height:36px;padding:7px 12px;border:1px solid #c4ae87;background:#fffbf2;color:#574229;font-size:12px;font-weight:600;box-shadow:none;transition:background .15s,border-color .15s}
.toolbar>#undo{border-radius:7px 0 0 7px;margin-right:-9px}
.toolbar>#redo{border-radius:0 7px 7px 0}
.toolbar>#undo:hover:not(:disabled),.toolbar>#redo:hover:not(:disabled){background:#ead8b2;border-color:#a4824b}
.toolbar>#undo:disabled,.toolbar>#redo:disabled{opacity:.42;background:#f5eddd}
.toolbar .download-controls{display:flex;align-items:center;flex-wrap:nowrap;gap:8px;min-width:0;max-width:100%;margin-left:auto}
.toolbar .download-controls .download-name{display:flex;flex-direction:row;align-items:center;gap:8px;min-width:0;max-width:260px;width:auto;font-size:11px;color:#776344;font-weight:600;white-space:nowrap}
.toolbar #download-name{width:150px;min-width:0;min-height:36px;padding:7px 10px;border:1px solid #c6b28d;border-radius:7px;background:#fffaf0;color:#493722;font-family:inherit;font-size:12px;font-weight:500;box-shadow:inset 0 1px 2px #5a41200a}
.toolbar #download-format{flex:0 0 auto;max-width:100%;min-height:36px;border:1px solid #c6b28d;border-radius:7px;background:#fffaf0;color:#574229;padding:7px 8px;font-family:inherit;font-size:12px}
.toolbar #download{flex:0 0 auto;min-height:36px;min-width:0;padding:8px 14px;border:1px solid #593e20;border-radius:7px;background:linear-gradient(180deg,#836035,#624423);color:#fff7e7;box-shadow:inset 0 1px 0 #ffffff24,0 2px 3px #49321c1a;font-size:12px;font-weight:700;letter-spacing:.01em;white-space:nowrap;text-decoration:none;transition:background .15s,box-shadow .15s}
.toolbar #download:hover:not(.disabled){background:linear-gradient(180deg,#957044,#72522e);box-shadow:inset 0 1px 0 #ffffff24,0 2px 5px #49321c30}
.toolbar :is(button,input,select,a):focus-visible{outline:2px solid #805c30;outline-offset:2px}
@media(min-width:601px) and (max-width:1199px){.toolbar .download-controls{flex:1 1 100%;justify-content:flex-end}.toolbar .download-controls .download-name{margin-right:auto}}
@media(max-width:600px){
 .map-column>.toolbar{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;padding:8px;border-radius:10px}
 .toolbar>#undo,.toolbar>#redo{width:100%;min-width:0;margin:0;border-radius:7px}
 .toolbar .download-controls{display:grid;grid-column:1/-1;grid-template-columns:minmax(0,.9fr) minmax(0,1.3fr);gap:8px;width:100%;margin:0}
 .toolbar .download-controls .download-name{grid-column:1/-1;width:100%;max-width:none;gap:10px}
 .toolbar #download-name{width:0;flex:1;min-height:38px}
 .toolbar #download-format{width:100%;min-width:0;min-height:44px;padding:7px 4px;font-size:11px}
 .toolbar #download{min-height:44px;white-space:normal;padding:7px 8px;line-height:1.3;font-size:11px}
}
