/* Shared question / live-result service UI. Uses Phase 1 tokens. */
.tool-service{max-width:1248px}.tool-service h1{font-size:clamp(1.45rem,3vw,2.15rem)}
.tool-shell{display:grid!important;grid-template-columns:minmax(0,1.1fr) minmax(0,.9fr)!important;align-items:start;gap:24px!important;margin:24px 0}
.tool-progress{grid-column:1/-1;display:flex;gap:6px;flex-wrap:wrap;padding:0 0 16px;border-bottom:1px solid var(--border)}
.tool-progress button,.tool-edit-bar button{width:auto;min-width:44px;min-height:44px;padding:9px 15px;border-radius:6px;background:transparent;color:var(--muted);font-size:.875rem;border:1px solid transparent;justify-content:center}
.tool-progress button[aria-current=step]{background:#e5f1eb;color:var(--accent);border-color:#99b9ae;font-weight:750}
.tool-question-panel{padding:28px!important;border-radius:var(--radius-lg)!important;background:var(--surface);min-width:0;border:1px solid var(--border)}
.tool-question-panel form{margin:0}.tool-question{margin:0!important;padding:0;min-width:0}.tool-question>legend{font-size:1.5rem!important;line-height:1.5;margin:0 0 24px;font-weight:750;max-width:100%;color:var(--text)}
.tool-question>legend b,.tool-question>legend small{display:none}.tool-question fieldset{margin:18px 0!important}.tool-question fieldset legend{font-size:1rem!important;margin-bottom:12px}.tool-question fieldset legend b{display:none}
.tool-step-off{display:none!important}.tool-finished{display:none!important}.tool-show-result{grid-template-columns:1fr!important;margin-bottom:0!important}
.tool-question label{font-size:1rem!important}.tool-question input[type=number]{font-size:1.25rem!important;min-height:48px;color:var(--text)}
.tool-question input[type=number]:not(label>span>input){border:1px solid #a5b8b0;border-radius:8px;background:#fafbf8;padding:12px;width:100%;margin-top:8px}
.tool-question .bed-choices,.tool-question .curtain-choices,.tool-question .tc-choices{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.tool-question .tc-choice span,.tool-question .bed-choice span,.tool-question .curtain-choice span{min-height:64px;padding:12px!important;align-items:center;background:#fafbf8;border-radius:8px!important}
.tool-question input:checked+span{background:#e5f1eb!important;border-color:var(--accent)!important;box-shadow:inset 0 0 0 1px var(--accent)}
.tool-question input:focus-visible+span{outline:3px solid #bd7b17;outline-offset:3px}
.tool-question .measure-figure{max-width:200px;margin:12px auto}.tool-question .measure-figure img{max-height:120px;width:100%;object-fit:contain}.tool-question .measure-figure figcaption{font-size:.75rem}
.tool-question .muted,.tool-note{color:var(--muted);font-size:.875rem;line-height:1.75;margin:12px 0}.tool-question small{font-size:.8125rem!important;line-height:1.6}.tool-question .bed-grid,.tool-question .sofa-fields{gap:14px}
.tool-presets,.tool-segments,.tool-modes{display:flex;flex-wrap:wrap;gap:8px;margin:0 0 18px}.tool-presets button,.tool-segments button,.tool-modes button{width:auto;min-height:44px;padding:10px 16px;justify-content:center;border:1px solid var(--border);color:var(--text);background:#fafbf8;font-size:1rem;font-weight:600}
.tool-presets button:hover,.tool-segments button:hover,.tool-modes button:hover{background:#eaf3ee}.tool-presets button[aria-pressed=true],.tool-segments button[aria-pressed=true],.tool-modes button[aria-pressed=true]{background:var(--accent);color:white;border-color:var(--accent)}
.tool-question .sofa-presets button{min-height:44px}
.tool-modes{margin-bottom:22px}.tool-modes button{font-size:.875rem;flex:1}.tool-select-original{position:absolute!important;width:1px!important;height:1px!important;overflow:hidden;clip-path:inset(50%);opacity:0;pointer-events:none}
.tool-select-original:focus-visible+.tool-segments{outline:3px solid #bd7b17;outline-offset:4px}
.tool-flow-footer{display:grid;grid-template-columns:auto 1fr;gap:12px;margin-top:24px;border-top:1px solid var(--border);padding-top:20px}.tool-flow-footer>[role=alert],.tool-question-message{grid-column:1/-1;margin:0!important;color:#72511d!important;line-height:1.7;font-size:.875rem}.tool-question-message:empty,.tool-flow-footer>[role=alert]:empty{display:none}
.tool-flow-footer button{min-height:48px}.tool-flow-footer .tool-back{background:white;border:1px solid var(--border);color:var(--text);width:auto;padding:12px 20px}.tool-back:disabled{opacity:.35;cursor:default}.tool-next{justify-content:center}
.tool-original-submit{display:none!important}.tool-question-panel .privacy{font-size:.75rem}.tool-question-panel button[type=reset]{margin-top:14px;padding:9px;min-height:44px;background:transparent;border:0;color:var(--muted);font-size:.8125rem}
.tool-live-preview{background:#eaf1ed;border:1px solid #d5e1da;border-radius:var(--radius-lg);padding:28px;position:sticky;top:16px;max-height:calc(100vh - 32px);overflow:auto;min-width:0}
.tool-live-preview h2{font-size:1.35rem}.tool-preview-status{font-size:1.125rem;font-weight:750;color:var(--accent);margin:10px 0}.tool-preview-number{font-size:clamp(1.5rem,3.2vw,2.6rem);line-height:1.35!important;font-weight:750;letter-spacing:-.03em;color:var(--accent);margin:8px 0;overflow-wrap:anywhere; font-variant-numeric:tabular-nums}.tool-preview-name{font-size:.875rem;color:var(--muted);margin:6px 0}.tool-live-preview svg{display:block;max-width:100%;height:auto;max-height:235px;width:100%;margin:10px auto}.tool-live-preview>.tool-note{font-size:.75rem;margin-bottom:0}
.tool-full-result{margin:24px 0;padding:28px!important;width:100%;max-width:100%;border-radius:var(--radius-lg)!important;position:static!important}.tool-full-result[hidden],.tool-live-preview[hidden]{display:none!important}
.tool-edit-bar{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:24px;padding-bottom:16px;border-bottom:1px solid var(--border)}.tool-edit-bar button{border-color:var(--border);background:white;color:var(--accent);max-width:100%;white-space:normal;text-align:left}.tool-edit-bar:before{content:'入力済み条件';align-self:center;font-size:.875rem;color:var(--muted);margin-right:6px}
.tool-full-result .result-summary{display:flex;flex-direction:column;align-items:flex-start;background:#edf5f0;border-color:#d2e2d8}.tool-full-result .result-status,.tool-full-result #bed-selected-status{order:-1;font-size:1.125rem}.tool-full-result .result-value,.tool-full-result .total,.tool-full-result .result-metric strong{font-size:clamp(2rem,4vw,3.5rem);line-height:1.3;color:var(--accent);font-variant-numeric:tabular-nums}
.tool-full-result svg{max-width:100%;height:auto;max-height:380px}.tool-full-result #bed-layout,.tool-full-result #tv-result-diagram{max-width:660px;margin:20px auto}.tool-full-result .bed-compare,.tool-full-result #sofa-candidates{grid-template-columns:repeat(auto-fit,minmax(170px,1fr))}.tool-full-result .tc-answer{font-size:1.8rem}
.tool-measure-help{margin:24px 0 32px;border-block:1px solid var(--border);padding:0 16px}.tool-measure-help>h2{font-size:1.125rem}.tool-measure-help .measure-figure{max-width:300px;margin:20px auto}.tool-measure-help summary{min-height:48px}.tool-box-link{display:inline-flex;align-items:center;min-height:44px;font-weight:650;margin:8px 0}
.tool-service .tc-steps{display:none}.tool-service .tc-panel{position:static}.tool-question .tc-quick button{min-height:44px}.tool-inch-status{font-size:1.4rem;color:var(--accent);font-weight:750}.tool-inch-value{font-size:3rem;color:var(--accent);margin:10px 0;line-height:1.3}.tool-inch-result>svg{max-width:560px;display:block;margin:16px auto}.tool-inch-result .product-grid{font-size:1rem}
@media(max-width:760px){.tool-service{padding-top:18px}.tool-service>.intro>p,.tool-service .tc-intro>p{font-size:.875rem}.tool-shell{grid-template-columns:1fr!important;gap:14px!important;margin-top:20px}.tool-progress{gap:4px;padding-bottom:10px}.tool-progress button{font-size:.8125rem;padding:8px 10px}.tool-question-panel{padding:20px 16px!important}.tool-question>legend{font-size:1.3rem!important;margin-bottom:18px}.tool-question .bed-choices,.tool-question .curtain-choices,.tool-question .tc-choices{gap:8px}.tool-question label strong{font-size:.9375rem}.tool-question .tool-presets{gap:7px}.tool-presets button,.tool-segments button{font-size:.9375rem;padding:9px 12px}.tool-live-preview{position:static;max-height:none;overflow:visible;padding:18px;display:grid;grid-template-columns:1.05fr .95fr;gap:0 10px}.tool-live-preview>.eyebrow{grid-column:1/-1;font-size:.75rem}.tool-preview-status{font-size:.9375rem}.tool-preview-number{font-size:1.7rem;margin:4px 0}.tool-preview-name{font-size:.8125rem}.tool-live-preview>svg{grid-column:2;grid-row:2/5;max-height:150px;align-self:center}.tool-live-preview>.tool-note,.tool-live-preview>h2{grid-column:1/-1}.tool-preview-status,.tool-preview-number,.tool-preview-name{grid-column:1}.tool-full-result{padding:20px 16px!important}.tool-full-result .tc-answer{font-size:1.4rem;overflow-wrap:anywhere}.tool-full-result .bed-compare{grid-template-columns:1fr}.tool-edit-bar{gap:6px}.tool-edit-bar button{padding:8px 11px;font-size:.8125rem}.tool-full-result .result-value,.tool-full-result .result-metric strong{font-size:2rem}.tool-full-result #bed-main-passage{display:flex;flex-direction:column}.tool-full-result .total{font-size:3.5rem}.tool-inch-value{font-size:2.5rem}.tool-question .tc-choices small{font-size:.75rem!important}.tool-measure-help{padding:0 8px}}
@media(prefers-reduced-motion:reduce){.tool-service *{transition:none!important;animation:none!important}}
.tool-inline-help summary{padding:10px 0;min-height:44px;font-size:.8125rem;color:var(--muted)}.tool-inline-help .muted{margin:4px 0 12px}.tool-inline-help{margin:8px 0}
@media(max-width:760px){.tool-question-panel .tool-live-preview{margin-top:18px;padding:14px;border-radius:8px}.tool-service .intro p,.tool-service .tc-intro p{margin:8px 0}.tool-service .trust-line{margin:8px 0}.tool-service .breadcrumbs{margin-bottom:12px}.tool-flow-footer{margin-top:16px;padding-top:16px}.tool-service .tool-question .tool-note{font-size:.8125rem;margin:10px 0}}
.tool-full-result>.tc-result{border:0;padding:0;background:transparent}.tc-result-hero{padding:22px;background:#eaf3ed;border-radius:10px;margin:20px 0}.tc-result-hero .tc-recommendation{background:transparent;padding:0;margin:0;border:0}.tc-result-hero .tc-answer{font-size:1.35rem!important}.tc-dimension-value{color:var(--accent);font-size:1.7rem;font-weight:750;line-height:1.5}.tc-condition-detail{margin:16px 0}.tool-question-panel.tool-finished{display:none!important}
.tool-preview-metric{display:block;font-size:.75rem;font-weight:500;letter-spacing:0;color:var(--muted);margin-bottom:4px}
.tool-prefilled{display:inline-flex;align-items:center;width:max-content;max-width:100%;padding:8px 12px;border-radius:999px;background:#fff;color:var(--accent);font-weight:750;font-size:.875rem}
.edge-query-state{margin:18px 0 24px;padding:20px 24px;border:1px solid #b9d0c5;background:#edf5f0;border-radius:10px}.edge-query-state h2{margin:3px 0 8px;color:var(--accent);font-size:clamp(1.3rem,3vw,1.8rem)}.edge-query-state p{margin:4px 0}.edge-query-result{font-size:1.35rem;font-weight:750;color:var(--accent)}
.requirement-products{margin:28px 0;min-width:0}.requirement-products h2{font-size:1.35rem}.requirement-products .tc-buy-guide,.product-dimension-proof{padding:16px;background:#f0f5f1;border:1px solid #d3dfd8;border-radius:8px;margin:16px 0}.requirement-products .tc-product-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,300px),1fr));gap:16px}.requirement-products .tc-product{border:1px solid #d3dfd8;border-radius:8px;background:#fff;padding:18px;min-width:0}.requirement-products .tc-product h3{font-size:1.1rem}.requirement-products .tc-product-grade{font-weight:700;color:#09695b}.requirement-products .tc-product dl,.product-dimension-proof dl{display:grid;grid-template-columns:1fr;gap:6px;margin:16px 0}.requirement-products dd,.product-dimension-proof dd{margin:0 0 8px}.requirement-products .tc-product-links{display:flex;flex-wrap:wrap;gap:10px;margin-top:16px}.requirement-products .tc-product-links a{display:inline-flex;align-items:center;min-height:44px;padding:8px 12px;border:1px solid #96b5ab;border-radius:6px;text-decoration:none}.requirement-products .tc-product-image img{width:100%;height:180px;object-fit:contain}.product-comparison{margin:20px 0}.product-comparison summary{min-height:44px;padding:12px 0;cursor:pointer}.product-comparison ul{list-style:none;padding:0}.product-comparison li{display:grid;gap:8px;padding:16px 0;border-bottom:1px solid #d3dfd8}.product-empty{padding:16px;border-left:3px solid #96b5ab}.requirement-products,.product-comparison,.product-dimension-proof{overflow-wrap:anywhere}@media(max-width:760px){.requirement-products .tc-product-grid,#tc-products .tc-product-grid{grid-template-columns:1fr}.requirement-products .tc-product{padding:16px}}
