.tv-device-toolbar{display:flex;align-items:end;justify-content:space-between;gap:16px;max-width:920px;margin:0 auto 18px}.tv-device-select,.tv-setup-field{display:grid;gap:8px;font-weight:600}.tv-device-select select,.tv-setup-field input,.tv-setup-field select{border:1px solid #cbd8e1;background:#fff;border-radius:12px;min-height:44px;padding:10px 12px;color:#17354c;font:inherit;max-width:100%;width:100%}.tv-device-select{min-width:220px}.tv-setup-wizard,.tv-setup-empty{max-width:720px;margin:12px auto;padding:32px;background:#fff;border:1px solid #dce5ee;border-radius:22px;box-shadow:0 16px 44px #17354c0c;color:#17354c}.tv-setup-wizard h2,.tv-setup-empty h2{font-size:clamp(24px,4vw,32px);margin:24px 0 16px}.tv-setup-wizard p,.tv-setup-empty p{line-height:1.65;color:#526b7f}.tv-setup-progress{display:flex;gap:10px;padding:0;list-style:none;margin:0}.tv-setup-progress li{display:grid;place-items:center;flex:1;height:32px;border-radius:8px;background:#eef3f7;color:#698194;font-weight:600}.tv-setup-progress li.active{background:#173d56;color:#fff}.tv-setup-progress li.done{background:#e5f5ef;color:#176b50}.tv-setup-requirements{padding:16px 20px;border-radius:14px;background:#eff6fa}.tv-setup-actions{display:flex;gap:10px;align-items:center;border-top:1px solid #e2e9ef;padding-top:20px;margin-top:24px}.tv-setup-actions button:last-child{margin-left:auto}.tv-setup-field{margin:18px 0;max-width:100%}.tv-setup-hint{font-size:13px}.tv-setup-help{padding:16px;background:#f6f8fb;border-radius:12px;margin-top:24px}.tv-setup-help summary{cursor:pointer;font-weight:600}.tv-setup-help p{font-size:14px}.tv-setup-error{padding:12px 16px;border-radius:10px;background:#fff1ed;color:#a43628!important}.tv-setup-state{display:block;border-radius:12px;padding:18px;background:#eef3f7}.tv-setup-state.success,.tv-setup-notice{background:#ecf8f2;color:#176b50!important;padding:12px;border-radius:12px}.tv-found-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin-bottom:18px}.tv-found-card{display:grid;text-align:left;gap:8px;border:1px solid #dce5ee;padding:18px;border-radius:14px;background:#fff;color:#17354c;cursor:pointer;overflow-wrap:anywhere}.tv-found-card[aria-pressed=true]{background:#eff6fa;border-color:#2582a8;box-shadow:0 0 0 2px #2582a826}.tv-found-card small{color:#648195}.tv-setup-test-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}.tv-setup-test-grid .tv-key{display:grid;gap:4px;min-height:65px;padding:12px;font-size:14px}.tv-setup-test-grid [data-tested=sent]{border-color:#73b19a;background:#eef9f3}.tv-setup-test-grid small{font-size:10px;color:#377c62}.tv-setup-observed{display:flex;align-items:flex-start;gap:12px;margin-top:22px;line-height:1.5}.tv-setup-observed input{width:20px;height:20px;flex-shrink:0}.tv-setup-success{font-size:40px;border-radius:50%;width:72px;height:72px;display:grid;place-items:center;background:#e5f5ee;color:#176b50;margin:24px auto}.tv-setup-loading{padding:12px;border-radius:10px;background:#eff6fa}.tv-setup-empty-result{padding:18px;background:#f6f8fb;border-radius:12px}.tv-setup-wizard button:focus-visible,.tv-setup-wizard input:focus-visible,.tv-setup-wizard select:focus-visible{outline:3px solid #2689b5;outline-offset:3px}.tv-setup-wizard>button{margin:4px 8px 4px 0}
@media(max-width:600px){.tv-device-toolbar{align-items:stretch;gap:10px}.tv-device-select{min-width:0;flex:1}.tv-device-toolbar button{padding:10px;font-size:13px}.tv-setup-wizard,.tv-setup-empty{padding:20px 16px;border-radius:16px}.tv-setup-progress{gap:5px}.tv-setup-progress li{height:28px;font-size:12px}.tv-found-grid{grid-template-columns:1fr}.tv-setup-test-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.tv-setup-actions{flex-wrap:wrap}.tv-setup-actions button{padding:10px 12px}}

.tv-setup-wizard .button:not(.secondary),.tv-setup-empty .button:not(.secondary){background:#173d56;color:#fff;border:1px solid #173d56}.tv-setup-wizard .button:disabled{opacity:.45;cursor:default}
.tv-device-error{grid-column:1/-1;margin:0;font-size:13px;line-height:1.5}

.tv-device-toolbar{display:grid;grid-template-columns:minmax(0,1fr) auto;grid-template-areas:"title action" "selection selection";align-items:center;width:100%;max-width:none;margin:0 0 18px;gap:10px 12px;padding:16px;border:1px solid #cbd8e1;border-radius:12px;background:#ffffffb8;box-sizing:border-box}.tv-device-select{display:contents;font-size:14px}.tv-device-title{grid-area:title;font-weight:600;color:#17354c}.tv-device-select select{grid-area:selection;min-width:0;font-size:14px;min-height:44px;text-overflow:ellipsis}.tv-device-toolbar>.button{grid-area:action;min-height:44px;white-space:nowrap;font-size:13px}.tv-device-toolbar :focus-visible{outline:3px solid #2689b5;outline-offset:3px}.tv-setup-empty{margin:0 auto 24px;text-align:center;max-width:620px;padding:30px}.tv-setup-empty h2{margin:0 0 12px;font-size:27px}.tv-setup-empty p{margin:0 0 22px}.tv-setup-empty .button{min-height:46px;padding:12px 22px}
@media(max-width:600px){.tv-device-toolbar{margin-bottom:14px;padding:14px;gap:10px}.tv-device-select{font-size:13px}.tv-device-select select{font-size:13px;padding:9px;min-height:44px}.tv-device-toolbar>.button{padding:10px 12px;font-size:12px}.tv-setup-empty{padding:27px 18px}.tv-setup-empty h2{font-size:24px}}

/* One compact device row; setup guidance belongs to the opened wizard. */
.tv-device-toolbar{grid-template-areas:"selection action";margin:0;padding:0;border:0;border-radius:0;background:none;gap:10px 12px}.tv-device-title{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap}.tv-device-select select{font-size:14px;line-height:1.35}.tv-device-toolbar>.button{padding:10px 14px;font-size:14px}.tv-device-error{grid-row:2;margin:0}
.tv-setup-wizard{margin:0 auto 20px;padding:24px;border-radius:16px}.tv-setup-wizard h2{margin:18px 0 12px;font-size:24px;line-height:1.25}.tv-setup-wizard p{font-size:14px;line-height:1.55}.tv-setup-requirements{padding:12px 14px}.tv-setup-help{padding:0 14px;margin-top:16px}.tv-setup-help summary{display:flex;align-items:center;min-height:44px}.tv-setup-actions{padding-top:16px;margin-top:18px}.tv-setup-actions button,.tv-setup-wizard>button{min-height:44px}.tv-found-card{padding:14px}.tv-setup-observed{min-height:44px;align-items:center;padding:8px 0}.tv-setup-empty{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:6px 20px;max-width:none;margin:0 0 20px;padding:24px;text-align:left;border-radius:16px}.tv-setup-empty h2{grid-column:1;font-size:22px;line-height:1.3;margin:0}.tv-setup-empty p{grid-column:1;font-size:14px;line-height:1.55;margin:0}.tv-setup-empty .button{grid-column:2;grid-row:1/span 2;min-height:44px;margin:0;padding:10px 18px;white-space:nowrap}
@media(max-width:600px){.tv-device-toolbar{padding:0;margin:0;gap:10px}.tv-device-toolbar>.button{padding:10px 12px;font-size:13px}.tv-device-select select{font-size:14px;padding:10px}.tv-setup-wizard{padding:18px 16px}.tv-setup-wizard h2{font-size:22px}.tv-setup-empty{grid-template-columns:minmax(0,1fr);padding:20px 16px;gap:8px}.tv-setup-empty h2{font-size:20px}.tv-setup-empty .button{grid-column:1;grid-row:auto;justify-self:start;margin-top:6px;white-space:normal}.tv-setup-actions{gap:8px}.tv-setup-actions button{min-height:44px;flex:1}.tv-setup-actions button:last-child{margin-left:0}.tv-setup-observed input{width:24px;height:24px}}
