#js-tool-container-stair-riser-height-calculator .stb-app { display: flex; flex-direction: column; gap: 22px; color: var(--text-primary); }
#js-tool-container-stair-riser-height-calculator .stb-app, #js-tool-container-stair-riser-height-calculator .stb-app * { box-sizing: border-box; }
#js-tool-container-stair-riser-height-calculator .tbcalc-fieldset { border: 1px solid var(--border-color); border-radius: var(--radius-md); padding: 16px 18px 18px; margin: 0; background: var(--bg-secondary); }
#js-tool-container-stair-riser-height-calculator .tbcalc-legend { padding: 0 6px; font-weight: 600; font-size: 0.95rem; color: var(--text-secondary); }
#js-tool-container-stair-riser-height-calculator .tbcalc-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px 18px; }
#js-tool-container-stair-riser-height-calculator .tbcalc-field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
#js-tool-container-stair-riser-height-calculator .tbcalc-hint { font-size: 0.8rem; line-height: 1.35; color: var(--text-muted); }
#js-tool-container-stair-riser-height-calculator .stb-outcome { display: flex; flex-direction: column; gap: 16px; }
#js-tool-container-stair-riser-height-calculator .stb-hero { border-left: 4px solid var(--accent-primary); background: var(--accent-light); border-radius: var(--radius-md); padding: 18px 20px; display: flex; flex-direction: column; gap: 6px; min-height: 118px; }
#js-tool-container-stair-riser-height-calculator .stb-hero-label { font-size: 0.9rem; color: var(--text-secondary); }
#js-tool-container-stair-riser-height-calculator .stb-hero-row { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
#js-tool-container-stair-riser-height-calculator .stb-hero-value { font-size: clamp(2rem, 5vw, 3rem); font-weight: 700; line-height: 1.05; color: var(--text-primary); }
#js-tool-container-stair-riser-height-calculator .stb-hero-note { margin: 0; font-size: 0.86rem; line-height: 1.4; color: var(--text-secondary); }
#js-tool-container-stair-riser-height-calculator .tbcalc-unit { font-size: 1rem; color: var(--text-secondary); }
#js-tool-container-stair-riser-height-calculator .tbcalc-status { border: 1px solid var(--border-color); border-left: 4px solid var(--accent-primary); border-radius: var(--radius-sm); padding: 10px 14px; font-size: 0.9rem; line-height: 1.4; color: var(--text-secondary); }
#js-tool-container-stair-riser-height-calculator .tbcalc-status.warn { border-left-color: var(--warning); background: var(--warning-light); color: var(--text-primary); }
#js-tool-container-stair-riser-height-calculator .stb-gauge-wrap { border: 1px solid var(--border-color); border-radius: var(--radius-md); padding: 18px 16px 14px; background: var(--bg-secondary); }
#js-tool-container-stair-riser-height-calculator .stb-gauge-track { position: relative; height: 14px; border-radius: 999px; background: var(--bg-tertiary); margin: 26px 6px 6px; }
#js-tool-container-stair-riser-height-calculator .stb-gauge-zone { position: absolute; top: 0; bottom: 0; border-radius: 999px; background: var(--success-light); border: 1px solid var(--success); }
#js-tool-container-stair-riser-height-calculator .stb-gauge-marker { position: absolute; top: -8px; bottom: -8px; width: 3px; border-radius: 2px; background: var(--accent-primary); display: block; }
#js-tool-container-stair-riser-height-calculator .stb-marker-flag { position: absolute; bottom: calc(100% + 6px); left: 50%; transform: translateX(-50%); padding: 2px 8px; border-radius: var(--radius-sm); background: var(--accent-primary); color: var(--bg-secondary, #ffffff); font-size: 0.8rem; font-weight: 650; font-variant-numeric: tabular-nums; white-space: nowrap; }
#js-tool-container-stair-riser-height-calculator .stb-gauge-marker::after { content: ''; position: absolute; top: 100%; left: 50%; transform: translateX(-50%); border: 5px solid transparent; border-top-color: var(--accent-primary); }
#js-tool-container-stair-riser-height-calculator .stb-ticks { display: flex; justify-content: space-between; margin: 2px 6px 0; font-size: 0.78rem; color: var(--text-muted); font-variant-numeric: tabular-nums; }
#js-tool-container-stair-riser-height-calculator .stb-gauge-desc { margin: 10px 0 0; font-size: 0.8rem; line-height: 1.4; color: var(--text-muted); }
#js-tool-container-stair-riser-height-calculator .stb-pair { display: grid; grid-template-columns: 1.4fr 0.6fr; gap: 14px; align-items: stretch; }
#js-tool-container-stair-riser-height-calculator .stb-formula { border: 1px solid var(--border-color); border-radius: var(--radius-md); background: var(--bg-secondary); padding: 14px 16px; display: flex; flex-direction: column; gap: 6px; justify-content: center; min-height: 96px; }
#js-tool-container-stair-riser-height-calculator .stb-formula-code { font-family: var(--font-mono, ui-monospace, monospace); font-size: clamp(1.05rem, 3vw, 1.35rem); font-weight: 600; color: var(--text-primary); font-variant-numeric: tabular-nums; }
#js-tool-container-stair-riser-height-calculator .stb-f-sum { color: var(--accent-primary); }
#js-tool-container-stair-riser-height-calculator .stb-formula-cap { font-size: 0.8rem; color: var(--text-muted); }
#js-tool-container-stair-riser-height-calculator .stb-slope { border: 1px solid var(--border-color); border-radius: var(--radius-md); background: var(--bg-secondary); padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; align-items: center; justify-content: center; }
#js-tool-container-stair-riser-height-calculator .stb-slope-box { position: relative; width: 120px; height: 64px; overflow: hidden; }
#js-tool-container-stair-riser-height-calculator .stb-slope-box::before { content: ''; position: absolute; left: 0; right: 0; bottom: 0; border-bottom: 2px solid var(--border-color); }
#js-tool-container-stair-riser-height-calculator .stb-slope-line { position: absolute; left: 0; bottom: 0; width: 118px; border-top: 3px solid var(--accent-primary); transform-origin: 0 0; display: block; }
#js-tool-container-stair-riser-height-calculator .stb-slope-cap { margin: 0; font-size: 0.84rem; color: var(--text-secondary); text-align: center; }
#js-tool-container-stair-riser-height-calculator .stb-slope-val { font-size: 1.1rem; font-weight: 700; color: var(--text-primary); font-variant-numeric: tabular-nums; }
#js-tool-container-stair-riser-height-calculator .stb-details { display: flex; flex-direction: column; gap: 12px; }
#js-tool-container-stair-riser-height-calculator .tbcalc-table-wrap { overflow-x: auto; border: 1px solid var(--border-color); border-radius: var(--radius-md); background: var(--bg-secondary); }
#js-tool-container-stair-riser-height-calculator .tbcalc-table { width: 100%; border-collapse: collapse; font-size: 0.88rem; font-variant-numeric: tabular-nums; }
#js-tool-container-stair-riser-height-calculator .stb-table-caption { caption-side: top; text-align: left; padding: 10px 14px 2px; font-size: 0.84rem; color: var(--text-secondary); }
#js-tool-container-stair-riser-height-calculator .tbcalc-table th, #js-tool-container-stair-riser-height-calculator .tbcalc-table td { padding: 8px 12px; text-align: right; border-top: 1px solid var(--border-color); white-space: nowrap; }
#js-tool-container-stair-riser-height-calculator .tbcalc-table thead th { color: var(--text-secondary); font-weight: 600; border-top: 0; }
#js-tool-container-stair-riser-height-calculator .tbcalc-table th[scope="row"], #js-tool-container-stair-riser-height-calculator .tbcalc-table thead th:first-child { text-align: left; }
#js-tool-container-stair-riser-height-calculator .stb-ok { color: var(--success); font-weight: 650; }
#js-tool-container-stair-riser-height-calculator .stb-bad { color: var(--warning); font-weight: 650; }
#js-tool-container-stair-riser-height-calculator .stb-limits { margin: 0; font-size: 0.84rem; line-height: 1.45; color: var(--text-muted); }
@media (max-width: 720px) { #js-tool-container-stair-riser-height-calculator .stb-pair { grid-template-columns: 1fr; } }
@media (max-width: 600px) { #js-tool-container-stair-riser-height-calculator .tbcalc-grid-3 { grid-template-columns: 1fr; } }