<!-- Test Template Modal -->
<div id="test-template-modal" class="modal" role="dialog" aria-modal="true" aria-labelledby="test-template-modal-title">
    <div class="modal-content">
        <div class="modal-header">
            <h2 id="test-template-modal-title" data-i18n="templates.test.title">Test Capture Template</h2>
            <button class="modal-close-btn" onclick="closeTestTemplateModal()" title="Close" data-i18n-aria-label="aria.close">&#x2715;</button>
        </div>
        <div class="modal-body">
            <div class="form-group">
                <label data-i18n="templates.test.display">Display:</label>
                <input type="hidden" id="test-template-display" value="">
                <button type="button" class="btn btn-display-picker" id="test-display-picker-btn" onclick="openDisplayPicker(onTestDisplaySelected, document.getElementById('test-template-display').value, window._engineHasOwnDisplays?.(window.currentTestingTemplate?.engine_type) ? window.currentTestingTemplate.engine_type : null)">
                    <span id="test-display-picker-label" data-i18n="displays.picker.select">Select display...</span>
                </button>
            </div>

            <div class="form-group">
                <label for="test-template-duration">
                    <span data-i18n="templates.test.duration">Capture Duration (s):</span>
                    <span id="test-template-duration-value">5</span>
                </label>
                <input type="range" id="test-template-duration" min="1" max="10" step="1" value="5" oninput="updateCaptureDuration(this.value)" />
            </div>

            <button type="button" class="btn btn-primary" onclick="runTemplateTest()" style="margin-top: 16px;">
<svg class="icon" viewBox="0 0 24 24"><path d="M14 2v6a2 2 0 0 0 .245.96l5.51 10.08A2 2 0 0 1 18 22H6a2 2 0 0 1-1.755-2.96l5.51-10.08A2 2 0 0 0 10 8V2"/><path d="M6.453 15h11.094"/><path d="M8.5 2h7"/></svg> <span data-i18n="templates.test.run">Run</span>
            </button>

        </div>
    </div>
</div>
