/* Mouse Tester — tools/utilities/mouse-tester.php */
.ms-stagewrap { grid-column: 1 / -1; min-width: 0; }
.ms-badge { margin-left: auto; font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; padding: 2px 9px; border-radius: 10px; border: 1px solid var(--border); color: var(--text-tertiary); }
.ms-badge.is-example { border-color: var(--accent-border); color: var(--accent); background: var(--accent-muted); }
.ms-badge.is-live { border-color: #2f9e5b; color: #2f9e5b; }
.ms-pad { position: relative; display: block; flex: 0 0 auto; padding: 0; height: 360px; min-height: 0; overflow: hidden; cursor: crosshair; outline: none; user-select: none; -webkit-user-select: none; background-image: radial-gradient(var(--border) 1px, transparent 1px); background-size: 22px 22px; }
.ms-pad.is-testing { touch-action: none; }
.ms-pad:focus-visible { box-shadow: inset 0 0 0 2px var(--accent); }
.ms-pad.is-locked { cursor: none; }
.ms-trail { position: absolute; inset: 0; pointer-events: none; }
.ms-mouse { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: min(92%, 460px); height: auto; pointer-events: none; }
.ms-hint { position: absolute; left: 0; right: 0; bottom: 8px; text-align: center; font-size: .78rem; color: var(--text-tertiary); pointer-events: none; padding: 0 12px; }
.ms-lockdot { position: absolute; left: -9px; top: -9px; width: 18px; height: 18px; border: 2px solid var(--accent); border-radius: 50%; pointer-events: none; }
.ms-lockdot[hidden] { display: none; }
.ms-body { fill: var(--bg-input); stroke: var(--border); stroke-width: 2; }
.ms-part { fill: var(--bg-card); stroke: var(--text-tertiary); stroke-width: 1.5; transition: fill .06s; }
.ms-part.is-tested { fill: var(--accent-muted); stroke: var(--accent); }
.ms-part.is-down, .ms-part.is-flash { fill: var(--accent); stroke: var(--accent); }
.ms-part.is-fault { stroke: #e5534b; stroke-width: 3; }
.ms-lab { fill: var(--text-secondary); font-family: var(--font-body); font-size: 12px; font-weight: 600; }
.ms-cnt { fill: var(--text-primary); font-family: var(--font-mono); font-size: 18px; font-weight: 700; }
.ms-cnt.sm { font-size: 14px; }
.ms-rev { fill: #e5534b; font-family: var(--font-body); font-size: 12px; font-weight: 700; }
.ms-verdict { margin: 0; padding: 10px 16px 12px; font-size: .88rem; color: var(--text-secondary); border-top: 1px solid var(--border-subtle); line-height: 1.5; }
.ms-bad { color: #e5534b; font-weight: 700; }
.ms-muted { color: var(--text-tertiary); font-weight: 400; }
.ms-modes { flex-wrap: wrap; }
.ms-modes .ub-solve-btn { min-width: calc(33.33% - 6px); }
#btn-start.is-stop { background: #e5534b; border-color: #e5534b; color: #fff; }
.ms-msg { font-size: .82rem; color: var(--text-tertiary); min-height: 1.3em; margin: 10px 0 0; line-height: 1.45; }
.ms-msg.is-warn { color: var(--accent); font-weight: 600; }
.ms-presets { margin-top: 14px; padding: 12px; border: 1px solid var(--border); border-radius: 8px; background: var(--bg-input); }
.ms-presets__title { font-size: .75rem; color: var(--text-tertiary); text-transform: uppercase; letter-spacing: .05em; margin-bottom: 8px; font-weight: 600; }
.ms-presets__row { display: flex; gap: 6px; flex-wrap: wrap; }
.ms-presets__row .ub-tool-btn { flex: 1 1 auto; font-size: .82rem; padding: 10px 12px; }
.ms-presets__row .ub-tool-btn.is-active { border-color: var(--accent); color: var(--accent); }
.ms-lock { margin-top: 14px; padding: 12px; border: 1px solid var(--border); border-radius: 8px; }
.ms-lock .ub-tool-btn { width: 100%; }
.ms-lock .ub-tool-btn:disabled { opacity: .55; cursor: not-allowed; }
.ms-lockout { font-size: .8rem; color: var(--text-secondary); margin-top: 8px; line-height: 1.5; overflow-wrap: anywhere; }
.ms-note { font-size: .78rem; color: var(--text-tertiary); margin: 12px 0 0; line-height: 1.5; }
.ms-live .ub-tool-panel__body { display: flex; flex-direction: column; gap: 12px; }
.ms-sub { font-size: .7rem; text-transform: uppercase; letter-spacing: .05em; color: var(--text-tertiary); font-weight: 700; margin: 0 0 4px; }
.ms-chart svg { width: 100%; height: auto; display: block; }
.ms-cap { font-size: .76rem; color: var(--text-tertiary); margin: 2px 0 0; }
.ms-grid { stroke: var(--border); stroke-width: 1; }
.ms-axis { fill: var(--text-tertiary); font-size: 11px; font-family: var(--font-body); }
.ms-acc { fill: var(--accent); font-weight: 700; }
.ms-badt { fill: #e5534b; }
.ms-line { fill: none; stroke: var(--accent); stroke-width: 2.5; stroke-linejoin: round; }
.ms-ref { stroke: var(--accent); stroke-width: 1.5; stroke-dasharray: 5 4; }
.ms-ref.is-bad { stroke: #e5534b; }
.ms-bar { fill: var(--accent); }
.ms-bar.is-alt { fill: var(--text-tertiary); }
.ms-bar.is-bad { fill: #e5534b; }
.ms-bar.b1 { fill: #3d8bd4; }
.ms-bar.b2 { fill: #2f9e5b; }
.ms-bar.b3, .ms-bar.b4 { fill: #9a6fd0; }
.ms-dot { fill: var(--accent); }
.ms-dot.is-bad { fill: #e5534b; }
.ms-table { width: 100%; border-collapse: collapse; font-size: .76rem; }
.ms-table th { text-align: left; padding: 4px 6px; color: var(--text-tertiary); font-size: .64rem; text-transform: uppercase; letter-spacing: .04em; border-bottom: 1px solid var(--border); position: sticky; top: 0; background: var(--bg-card); white-space: nowrap; }
.ms-table td { padding: 3px 6px; border-bottom: 1px solid var(--border-subtle); color: var(--text-secondary); white-space: nowrap; font-family: var(--font-mono); }
.ms-table td:last-child { white-space: normal; }
.ms-log td:last-child { font-family: var(--font-body); min-width: 140px; }
.ms-table tr.is-bad td { color: #e5534b; }
.ms-table tr.is-warn td { color: var(--accent); }
.ms-logwrap { max-height: 240px; overflow: auto; border: 1px solid var(--border); border-radius: 8px; }
.ms-scroll { overflow-x: auto; }
.ms-bar2 { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.ms-mini { font-size: .76rem; padding: 6px 10px; border-radius: 6px; border: 1px solid var(--border); background: transparent; color: var(--text-primary); cursor: pointer; min-height: 32px; }
.ms-mini:hover { border-color: var(--accent); color: var(--accent); }
.ms-sw-note { font-size: .84rem; color: var(--text-tertiary); margin: 0 0 10px; }
@media (max-width: 600px) { .ms-pad { height: 300px; } }
