:root {
  color-scheme: dark;
  --qy-blue: #0a59f7;
  --qy-blue-soft: #6095ff;
  --qy-navy: #061329;
  --qy-panel: #0a1933;
  --qy-line: rgba(255, 255, 255, 0.13);
  font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
}

* { box-sizing: border-box; }

html, body { margin: 0; min-height: 100%; background: var(--qy-navy); }
body { color: #fff; }
button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }

.qy-video-skip {
  position: fixed; top: 8px; left: 8px; z-index: 1000; padding: 9px 13px;
  border-radius: 8px; background: #fff; color: #071631; transform: translateY(-150%);
}
.qy-video-skip:focus { transform: translateY(0); }

.qy-video-site-header {
  position: relative; z-index: 20; display: grid; grid-template-columns: 240px 1fr 150px;
  align-items: center; min-height: 72px; padding: 0 max(28px, calc((100vw - 1380px) / 2));
  border-bottom: 1px solid #edf0f5; background: #fff; color: #1b2333;
}
.qy-video-brand { display: flex; align-items: center; width: 190px; color: #0b1f4d; text-decoration: none; }
.qy-video-brand img { display: block; width: 190px; height: auto; }
.qy-video-site-header nav { display: flex; justify-content: center; gap: 34px; }
.qy-video-site-header nav a, .qy-video-header-back { color: #252b37; font-size: 15px; text-decoration: none; }
.qy-video-site-header nav a:hover, .qy-video-header-back:hover { color: var(--qy-blue); }
.qy-video-header-back { justify-self: end; padding: 9px 16px; border: 1px solid #dde5f0; border-radius: 999px; }

.qy-video-app { min-height: calc(100vh - 72px); padding: 28px; background: radial-gradient(circle at 58% 22%, #102b5b 0, #07152e 34%, #030b19 78%); }
.qy-video-shell { display: grid; grid-template-columns: minmax(210px, 260px) minmax(300px, 430px) minmax(270px, 340px); justify-content: center; gap: clamp(20px, 3vw, 52px); min-height: calc(100vh - 128px); }

.qy-video-playlist { align-self: center; min-width: 0; }
.qy-video-playlist h1 { margin: 0 0 38px; font-size: 30px; }
.qy-video-playlist h2 { margin: 0 0 16px; font-size: 16px; font-weight: 600; }
.qy-video-playlist__items { display: grid; gap: 12px; max-height: 590px; overflow-y: auto; padding-right: 5px; scrollbar-color: #305996 transparent; }
.qy-video-list-item { display: grid; grid-template-columns: 84px 1fr; gap: 12px; align-items: center; padding: 9px; border: 1px solid transparent; border-radius: 12px; background: rgba(255,255,255,.035); color: #fff; text-align: left; cursor: pointer; }
.qy-video-list-item:hover { background: rgba(255,255,255,.08); }
.qy-video-list-item.is-active { border-color: var(--qy-blue); background: rgba(10,89,247,.12); box-shadow: 0 0 0 1px rgba(10,89,247,.5); }
.qy-video-list-item img { width: 84px; height: 72px; object-fit: cover; border-radius: 9px; background: #14284b; }
.qy-video-list-item b { display: -webkit-box; overflow: hidden; font-size: 14px; line-height: 1.45; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.qy-video-list-item small { display: block; margin-top: 7px; color: #aebbd0; }

.qy-video-stage { align-self: center; justify-self: center; width: min(430px, calc((100vh - 150px) * 9 / 16)); min-width: 300px; }
.qy-video-frame { position: relative; overflow: hidden; aspect-ratio: 9/16; border-radius: 18px; background: #020611; box-shadow: 0 28px 80px rgba(0,0,0,.45); isolation: isolate; }
.qy-video-frame video, .qy-video-frame > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.qy-video-frame video { z-index: 2; background: #020611; }
.qy-video-frame > img { z-index: 1; }
.qy-video-frame.has-video > img { opacity: 0; }
.qy-video-frame__shade { position: absolute; z-index: 3; inset: 0; pointer-events: none; background: linear-gradient(180deg, rgba(0,0,0,.05) 45%, rgba(0,0,0,.78) 100%); }
.qy-video-notice { position: absolute; z-index: 9; left: 50%; bottom: 115px; max-width: 82%; padding: 9px 13px; border-radius: 999px; background: rgba(3,11,27,.82); color: #fff; font-size: 13px; text-align: center; opacity: 0; transform: translate(-50%,10px); transition: .2s ease; pointer-events: none; }
.qy-video-notice.is-visible { opacity: 1; transform: translate(-50%,0); }

.qy-video-controls { display: grid; grid-template-columns: 34px 48px 1fr 48px 34px; align-items: center; gap: 9px; margin-top: 14px; color: #c7d0df; font-size: 12px; }
.qy-video-controls button { border: 0; background: transparent; color: #fff; cursor: pointer; }
.qy-video-controls input { width: 100%; accent-color: var(--qy-blue); }

.qy-video-info { align-self: center; min-width: 0; }
.qy-video-info h2 { margin: 0 0 16px; font-size: clamp(23px, 2vw, 32px); line-height: 1.35; }
.qy-video-info > p { margin: 0 0 18px; color: #b9c5d9; font-size: 15px; line-height: 1.8; }
.qy-video-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 24px; }
.qy-video-tags span { padding: 6px 10px; border: 1px solid rgba(10,89,247,.4); border-radius: 7px; background: rgba(10,89,247,.12); color: #8bb4ff; font-size: 12px; }
.qy-video-actions { display: grid; grid-template-columns: repeat(2,1fr); gap: 10px; margin-bottom: 20px; }
.qy-video-actions button { display: flex; align-items: center; gap: 9px; min-height: 48px; padding: 8px 12px; border: 1px solid var(--qy-line); border-radius: 12px; background: rgba(255,255,255,.045); color: #fff; cursor: pointer; }
.qy-video-actions button:hover { border-color: rgba(96,149,255,.8); background: rgba(10,89,247,.12); }
.qy-video-actions button span { font-size: 24px; }
.qy-video-actions button small { margin-left: auto; color: #b9c5d9; }
.qy-video-actions button.is-liked span, .qy-video-mobile-actions button.is-liked span { color: #ff4d6d; }
.qy-video-consult { display: block; padding: 14px 20px; border-radius: 8px; background: var(--qy-blue); color: #fff; font-size: 18px; font-weight: 700; text-align: center; text-decoration: none; box-shadow: 0 12px 26px rgba(10,89,247,.24); }
.qy-video-consult:hover { background: #004de2; }
.qy-video-switcher { display: grid; grid-template-columns: 42px 1fr 42px; align-items: center; gap: 10px; margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--qy-line); color: #acb8cb; font-size: 13px; text-align: center; }
.qy-video-switcher button { width: 42px; height: 42px; border: 1px solid rgba(255,255,255,.35); border-radius: 50%; background: transparent; color: #fff; font-size: 29px; cursor: pointer; }

.qy-video-mobile-topbar, .qy-video-mobile-actions, .qy-video-mobile-copy { display: none; }

@media (max-width: 920px) {
  html, body { height: 100%; overflow: hidden; }
  .qy-video-site-header { display: none; }
  .qy-video-app { min-height: 100vh; padding: 0; background: #000; }
  .qy-video-mobile-topbar { position: fixed; z-index: 30; top: 0; right: 0; left: 0; display: grid; grid-template-columns: 40px 1fr 40px; align-items: center; height: calc(56px + env(safe-area-inset-top)); padding: env(safe-area-inset-top) 10px 0; background: linear-gradient(rgba(0,0,0,.65),transparent); }
  .qy-video-mobile-topbar a { display: grid; place-items: center; color: #fff; font-size: 34px; text-decoration: none; }
  .qy-video-mobile-topbar strong { text-align: center; }
  .qy-video-shell { display: block; min-height: 100vh; }
  .qy-video-playlist, .qy-video-info, .qy-video-controls { display: none; }
  .qy-video-stage, .qy-video-frame { width: 100%; height: 100vh; }
  .qy-video-stage { min-width: 0; }
  .qy-video-frame { aspect-ratio: auto; border-radius: 0; box-shadow: none; }
  .qy-video-mobile-actions { position: absolute; z-index: 8; right: 12px; bottom: 174px; display: grid; gap: 16px; }
  .qy-video-mobile-actions button { display: grid; justify-items: center; gap: 2px; width: 58px; padding: 0; border: 0; background: transparent; color: #fff; text-shadow: 0 1px 4px rgba(0,0,0,.8); }
  .qy-video-mobile-actions button span { font-size: 34px; line-height: 1; }
  .qy-video-mobile-actions button b { font-size: 13px; }
  .qy-video-mobile-actions button small { font-size: 11px; }
  .qy-video-mobile-copy { position: absolute; z-index: 7; right: 82px; bottom: max(24px,env(safe-area-inset-bottom)); left: 16px; display: block; }
  .qy-video-mobile-copy h2 { margin: 0 0 8px; font-size: 18px; line-height: 1.45; }
  .qy-video-mobile-copy p { margin: 0 0 13px; color: #d6deeb; font-size: 13px; }
  .qy-video-mobile-copy a { display: inline-block; min-width: 150px; padding: 11px 18px; border-radius: 7px; background: var(--qy-blue); color: #fff; font-weight: 700; text-align: center; text-decoration: none; }
  .qy-video-notice { bottom: 250px; }
}

@media (max-height: 690px) and (max-width: 920px) {
  .qy-video-mobile-actions { bottom: 120px; gap: 10px; }
  .qy-video-mobile-copy { bottom: 14px; }
  .qy-video-mobile-copy p { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .qy-video-notice { transition: none; }
}
