:root {
  color-scheme: dark;
  font: 16px system-ui, sans-serif;
  background: #0f0f0f;
  color: #f1f1f1;
}
* { box-sizing: border-box; }
body { margin: 0; }
button, input, select { font: inherit; }
button { cursor: pointer; }
button:focus-visible, input:focus-visible, summary:focus-visible { outline: 2px solid #ff9f1c; outline-offset: 2px; }
main { max-width: 900px; margin: auto; padding: 20px 16px 56px; }
.site-header { margin-bottom: 22px; }
.brand { display: inline-flex; align-items: baseline; gap: 7px; color: inherit; text-decoration: none; }
.brand strong { color: #ff9f1c; font-size: 2rem; letter-spacing: -.08rem; }
.brand span, small, #status, #result-count, .video-meta { color: #aaa; }
#search-form { display: flex; gap: 8px; }
input { flex: 1; min-width: 0; border: 1px solid #3f3f3f; border-radius: 999px; padding: 11px 15px; background: #1c1c1c; color: inherit; }
button { border: 0; border-radius: 999px; padding: 10px 14px; background: #292929; color: inherit; }
button:hover { background: #3b3b3b; }
#search-form button { background: #ff9f1c; color: #181818; font-weight: 700; }
#status { min-height: 1.5em; margin: 10px 0; }
#watch { margin: 20px 0 34px; }
.media-shell { position: relative; overflow: hidden; background: #000; border-radius: 12px; }
#video-media { display: block; width: 100%; max-height: 65vh; background: #000; }
.mode-toggle { position: absolute; top: 10px; right: 10px; background: rgb(20 20 20 / 88%); font-size: .875rem; }
.watch-info { padding-top: 14px; }
h1, h2, p { margin: 0; }
h1 { font-size: 1.25rem; line-height: 1.35; }
.video-meta { display: flex; flex-wrap: wrap; gap: 6px 12px; margin: 8px 0 12px; font-size: .925rem; }
#video-channel { color: #b7dbad; font-weight: 650; }
.watch-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 12px; }
.watch-actions label { color: #aaa; font-size: .875rem; }
.watch-actions select { border: 0; border-radius: 999px; padding: 10px 12px; background: #292929; color: inherit; }
.watch-actions button:disabled { cursor: default; color: #ddd; opacity: 1; }
details, .detail-block { border-top: 1px solid #303030; padding: 13px 0; }
summary { cursor: pointer; font-weight: 700; }
#description { margin-top: 10px; color: #d0d0d0; line-height: 1.45; white-space: pre-wrap; overflow-wrap: anywhere; }
.detail-block h2, .section-heading h2 { font-size: 1rem; }
.chips { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 10px; }
.chips span { border: 1px solid #464646; border-radius: 999px; padding: 4px 9px; color: #ccc; font-size: .85rem; }
#comments { padding: 0; margin: 11px 0 0; list-style: none; }
#comments li { padding: 12px 0; border-top: 1px solid #292929; }
#comments p { margin: 4px 0 6px; line-height: 1.4; white-space: pre-wrap; overflow-wrap: anywhere; }
#comments small { font-size: .8rem; }
.section-heading { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 2px; }
ol { padding: 0; margin: 0; list-style: none; }
#results { border-top: 1px solid #2b2b2b; }
li { border-bottom: 1px solid #2b2b2b; }
.result { display: flex; width: 100%; gap: 13px; text-align: left; border-radius: 0; padding: 13px 0; background: transparent; }
.result:hover { background: transparent; }
.result img { width: 168px; aspect-ratio: 16 / 9; object-fit: cover; background: #242424; border-radius: 8px; }
.result span { min-width: 0; display: grid; align-content: start; gap: 7px; }
.result b { line-height: 1.3; }
.result small { line-height: 1.35; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
@media (max-width: 560px) {
  main { padding: 16px 12px 40px; }
  .site-header { margin-bottom: 16px; }
  #search-form button { padding-inline: 12px; }
  .result img { width: 128px; }
  .result b { font-size: .94rem; }
  .result small { font-size: .8rem; }
}
