@font-face { font-family: 'Roboto'; font-weight: 400; font-display: swap; src: url(/fonts/roboto-latin-400-normal.woff2) format('woff2'); }
@font-face { font-family: 'Roboto'; font-weight: 500; font-display: swap; src: url(/fonts/roboto-latin-500-normal.woff2) format('woff2'); }
@font-face { font-family: 'Roboto'; font-weight: 700; font-display: swap; src: url(/fonts/roboto-latin-700-normal.woff2) format('woff2'); }

:root {
  --bg: #0f0f0f; --bg2: #212121; --bg3: #272727; --hover: rgba(255,255,255,.1); --hover2: rgba(255,255,255,.2);
  --text: #f1f1f1; --text2: #aaa; --line: rgba(255,255,255,.2); --red: #f03; --blue: #3ea6ff;
  --top: 56px; --side: 240px; --mini-side: 72px; --bottom: 0px;
  --safe-b: env(safe-area-inset-bottom, 0px); --safe-t: env(safe-area-inset-top, 0px);
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--bg); color: var(--text); font: 14px/1.4 Roboto, 'Segoe UI', -apple-system, Arial, sans-serif; }
body { overscroll-behavior-y: none; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
input, select, textarea { font: inherit; color: inherit; }
img { display: block; }
svg { width: 24px; height: 24px; fill: currentColor; flex: none; }
[hidden] { display: none !important; }
::-webkit-scrollbar { width: 8px; height: 8px; } ::-webkit-scrollbar-thumb { background: #555; border-radius: 4px; } ::-webkit-scrollbar-track { background: transparent; }

.icon-btn { width: 40px; height: 40px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; flex: none; }
.icon-btn:hover { background: var(--hover); } .icon-btn:active { background: var(--hover2); }
.btn { height: 36px; padding: 0 16px; border-radius: 18px; background: var(--hover); font-weight: 500; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.btn:hover { background: var(--hover2); } .btn svg { width: 22px; height: 22px; margin-left: -4px; }
.btn.white { background: #f1f1f1; color: #0f0f0f; } .btn.white:hover { background: #d9d9d9; }
.btn.blue { background: var(--blue); color: #0f0f0f; } .btn.text { background: none; color: var(--blue); } .btn.text:hover { background: rgba(62,166,255,.15); }
.btn.sm { height: 32px; padding: 0 12px; font-size: 13px; }
.btn.danger { color: #ff6b6b; }

/* ---------------- top bar ---------------- */
#topbar { position: fixed; z-index: 50; top: 0; left: 0; right: 0; height: calc(var(--top) + var(--safe-t)); padding: var(--safe-t) 16px 0; display: flex; align-items: center; justify-content: space-between; gap: 16px; background: var(--bg); }
.tb-start { display: flex; align-items: center; gap: 12px; flex: none; }
.logo { display: flex; align-items: center; gap: 4px; height: 40px; padding: 0 4px; font-weight: 700; font-size: 19px; letter-spacing: -.6px; }
.logo svg { width: 30px; height: 21px; }
.tb-center { flex: 1; max-width: 720px; display: flex; align-items: center; gap: 8px; }
#searchForm { flex: 1; display: flex; position: relative; margin-left: 40px; }
.search-box { flex: 1; display: flex; align-items: center; height: 40px; border: 1px solid #303030; border-right: 0; border-radius: 20px 0 0 20px; background: #121212; padding-left: 16px; }
.search-box:focus-within { border-color: #1c62b9; box-shadow: inset 0 1px 2px rgba(0,0,0,.3); margin-left: -32px; padding-left: 48px; background: #121212 no-repeat 16px center / 20px url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23aaa'%3E%3Cpath d='M15.5 14h-.79l-.28-.27A6.471 6.471 0 0 0 16 9.5 6.5 6.5 0 1 0 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z'/%3E%3C/svg%3E"); }
#q { flex: 1; min-width: 0; background: none; border: 0; outline: 0; font-size: 16px; height: 100%; }
#q::-webkit-search-cancel-button { display: none; }
#qClear { width: 36px; height: 36px; visibility: hidden; } #qClear.show { visibility: visible; }
.search-btn { width: 64px; height: 40px; border: 1px solid #303030; border-radius: 0 20px 20px 0; background: #222; display: flex; align-items: center; justify-content: center; }
.search-btn:hover { background: #303030; }
#suggest { position: absolute; top: 44px; left: -32px; right: 64px; background: #212121; border-radius: 12px; padding: 16px 0; box-shadow: 0 4px 32px rgba(0,0,0,.5); z-index: 60; }
.sug { display: flex; align-items: center; gap: 14px; padding: 4px 16px; min-height: 36px; cursor: pointer; font-size: 16px; }
.sug:hover, .sug.active { background: #3a3a3a; } .sug svg { width: 20px; color: var(--text2); } .sug span { flex: 1; } .sug b { font-weight: 700; }
.sug .rm { font-size: 13px; color: var(--blue); visibility: hidden; } .sug:hover .rm { visibility: visible; }
.tb-end { display: flex; align-items: center; gap: 8px; flex: none; }
.avatar-btn { width: 32px; height: 32px; border-radius: 50%; font-weight: 500; display: flex; align-items: center; justify-content: center; margin: 0 4px; }
#searchOpen, .mobile-back { display: none; }

/* ---------------- sidebar ---------------- */
#sidebar { position: fixed; z-index: 40; top: calc(var(--top) + var(--safe-t)); bottom: 0; left: 0; width: var(--side); overflow-y: auto; padding: 12px; background: var(--bg); scrollbar-width: thin; }
#sidebar:not(:hover)::-webkit-scrollbar-thumb { background: transparent; }
.nav-item { display: flex; align-items: center; gap: 24px; height: 40px; padding: 0 12px; border-radius: 10px; white-space: nowrap; overflow: hidden; }
.nav-item:hover { background: var(--hover); } .nav-item.active { background: var(--hover); font-weight: 500; }
.nav-item img { width: 24px; height: 24px; border-radius: 50%; object-fit: cover; }
.nav-item span { overflow: hidden; text-overflow: ellipsis; }
.nav-sep { height: 1px; background: var(--line); margin: 12px 0; }
.nav-h { padding: 6px 12px 4px; font-size: 16px; font-weight: 500; display: flex; align-items: center; gap: 8px; }
.nav-foot { padding: 16px 12px; color: #717171; font-size: 12px; }
#scrim { display: none; }
#page { padding-top: calc(var(--top) + var(--safe-t)); padding-left: var(--side); min-height: 100vh; padding-bottom: calc(var(--bottom) + var(--safe-b) + 24px); }
#bottomnav { display: none; }

body.mini-side #sidebar { width: var(--mini-side); padding: 4px; }
body.mini-side #sidebar .nav-item { flex-direction: column; height: 74px; justify-content: center; gap: 6px; padding: 0; font-size: 10px; }
body.mini-side #sidebar .full-only { display: none; }
body.mini-side #page { padding-left: var(--mini-side); }
body.drawer #sidebar { width: var(--side) !important; padding: 12px !important; top: 0; padding-top: calc(var(--top) + var(--safe-t) + 4px) !important; transform: translateX(0); z-index: 70; display: block !important; }
body.drawer #sidebar .nav-item { flex-direction: row !important; height: 40px !important; font-size: 14px !important; padding: 0 12px !important; gap: 24px !important; justify-content: flex-start !important; }
body.drawer #sidebar .full-only { display: block !important; } body.drawer #sidebar .nav-item.full-only { display: flex !important; }
body.drawer #scrim { display: block; position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 65; }
body.drawer .drawer-head { display: flex !important; }
.drawer-head { display: none; position: fixed; top: var(--safe-t); left: 0; width: var(--side); height: var(--top); align-items: center; gap: 12px; padding: 0 16px; z-index: 71; background: var(--bg); }
body.watch-page #sidebar { display: none; } body.watch-page #page { padding-left: 0 !important; }

/* ---------------- chips ---------------- */
.chips { display: flex; gap: 12px; overflow-x: auto; scrollbar-width: none; padding: 12px 0; }
.chips::-webkit-scrollbar { display: none; }
.chip { flex: none; height: 32px; padding: 0 12px; border-radius: 8px; background: var(--hover); font-weight: 500; display: flex; align-items: center; white-space: nowrap; }
.chip:hover { background: var(--hover2); } .chip.active { background: #f1f1f1; color: #0f0f0f; }
.sticky-chips { position: sticky; top: calc(var(--top) + var(--safe-t)); z-index: 30; background: rgba(15,15,15,.98); margin: 0 -24px; padding: 12px 24px; }

/* ---------------- grid & cards ---------------- */
.page-pad { padding: 0 24px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(310px, 1fr)); gap: 40px 16px; padding: 12px 0 24px; }
@media (min-width: 2000px) { .grid { grid-template-columns: repeat(auto-fill, minmax(360px, 1fr)); } }
.card { position: relative; min-width: 0; }
.thumb { position: relative; display: block; aspect-ratio: 16/9; border-radius: 12px; overflow: hidden; background: #272727; }
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.dur { position: absolute; right: 8px; bottom: 8px; background: rgba(0,0,0,.8); color: #fff; font-size: 12px; font-weight: 500; padding: 1px 4px; border-radius: 4px; line-height: 18px; }
.dur.live { background: #cc0000; text-transform: uppercase; display: flex; align-items: center; gap: 3px; }
.prog { position: absolute; left: 0; right: 0; bottom: 0; height: 4px; background: rgba(150,150,150,.6); }
.prog i { display: block; height: 100%; background: var(--red); }
.card:hover .thumb { border-radius: 0; transition: border-radius .15s .2s; }
.meta { display: flex; gap: 12px; padding-top: 12px; position: relative; }
.ava { flex: none; width: 36px; height: 36px; border-radius: 50%; overflow: hidden; background: #333; display: flex; align-items: center; justify-content: center; font-weight: 500; }
.ava img { width: 100%; height: 100%; object-fit: cover; }
.txt { flex: 1; min-width: 0; padding-right: 24px; }
.title { font-size: 16px; font-weight: 500; line-height: 22px; max-height: 44px; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; word-break: break-word; }
.sub { color: var(--text2); font-size: 14px; line-height: 20px; margin-top: 4px; }
.sub a:hover { color: var(--text); }
.sub .line { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.more { position: absolute; right: -10px; top: 6px; opacity: 0; }
.card:hover .more, .more:focus, .crow:hover .more, .lrow:hover .more { opacity: 1; }
@media (hover: none) { .more { opacity: 1; } }
.badge-new { display: inline-block; background: var(--hover); color: var(--text2); font-size: 12px; padding: 0 4px; border-radius: 2px; margin-top: 4px; }

/* compact row (related, queue) */
.crow { display: flex; gap: 8px; position: relative; margin-bottom: 8px; }
.crow .thumb { width: 168px; flex: none; border-radius: 8px; }
.crow .txt { padding-right: 24px; }
.crow .title { font-size: 14px; line-height: 20px; max-height: 40px; }
.crow .sub { font-size: 12px; line-height: 18px; margin-top: 4px; }
.crow .more { top: -4px; }
.crow.playing { background: rgba(255,255,255,.08); border-radius: 8px; }

/* list row (search results on desktop) */
.lrow { display: flex; gap: 16px; position: relative; margin-bottom: 16px; }
.lrow .thumb { width: 360px; max-width: 45%; flex: none; }
.lrow .title { font-size: 18px; line-height: 26px; max-height: 52px; font-weight: 400; }
.lrow .chline { display: flex; align-items: center; gap: 8px; margin: 12px 0; color: var(--text2); font-size: 12px; }
.lrow .chline .ava { width: 24px; height: 24px; font-size: 11px; }
.lrow .desc { color: var(--text2); font-size: 12px; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.lrow .more { top: 0; right: 0; }
.chrow { display: flex; align-items: center; gap: 16px; margin: 8px 0 24px; }
.chrow .bigava { width: 360px; max-width: 45%; display: flex; justify-content: center; flex: none; }
.chrow .bigava .ava { width: 136px; height: 136px; font-size: 48px; }
.chrow .info { flex: 1; min-width: 0; } .chrow .info .sub { font-size: 12px; } .chrow h3 { margin: 0; font-size: 18px; font-weight: 400; }
.plstack { position: relative; }
.plstack::before { content: ''; position: absolute; left: 12px; right: 12px; top: -8px; height: 8px; background: #3a3a3a; border-radius: 8px 8px 0 0; }
.plcount { position: absolute; right: 8px; bottom: 8px; background: rgba(0,0,0,.75); font-size: 12px; font-weight: 500; padding: 2px 6px; border-radius: 4px; display: flex; align-items: center; gap: 4px; }
.plcount svg { width: 16px; height: 16px; }

/* shelves */
.shelf { padding: 24px 0 8px; border-top: 4px solid transparent; }
.shelf-h { display: flex; align-items: center; gap: 10px; font-size: 20px; font-weight: 700; margin-bottom: 16px; }
.shelf-h svg { color: var(--red); }
.shelf-h .grow { flex: 1; }
.hscroll { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(180px, 210px); gap: 12px; overflow-x: auto; scrollbar-width: none; padding-bottom: 4px; scroll-snap-type: x mandatory; }
.hscroll::-webkit-scrollbar { display: none; }
.hscroll.wide { grid-auto-columns: minmax(250px, 300px); }
.scard { scroll-snap-align: start; position: relative; }
.scard .sthumb { aspect-ratio: 9/16; border-radius: 12px; overflow: hidden; background: #272727; display: block; }
.scard .sthumb img { width: 100%; height: 100%; object-fit: cover; }
.scard .title { font-size: 16px; margin-top: 8px; }
.scard .sub { margin-top: 2px; }
.scard .more { top: auto; bottom: 30px; right: -8px; }

/* ---------------- menus / sheets / dialogs / toasts ---------------- */
.menu { position: fixed; z-index: 200; min-width: 220px; max-width: 320px; background: #282828; border-radius: 12px; padding: 8px 0; box-shadow: 0 4px 32px rgba(0,0,0,.6); max-height: 80vh; overflow-y: auto; }
.mi { display: flex; align-items: center; gap: 16px; padding: 0 16px 0 16px; height: 36px; width: 100%; text-align: left; white-space: nowrap; }
.mi:hover { background: #3e3e3e; } .mi svg { width: 24px; } .mi.sep { height: 1px; background: var(--line); margin: 8px 0; padding: 0; pointer-events: none; }
.mi .right { margin-left: auto; color: var(--text2); font-size: 13px; padding-left: 16px; display: flex; align-items: center; }
.sheet-back { position: fixed; inset: 0; z-index: 190; background: rgba(0,0,0,.5); }
.menu.sheet { left: 8px !important; right: 8px !important; top: auto !important; bottom: calc(8px + var(--safe-b)) !important; max-width: none; border-radius: 16px; }
.menu.sheet .mi { height: 48px; font-size: 16px; }
.dialog { position: fixed; z-index: 210; left: 50%; top: 50%; transform: translate(-50%, -50%); width: min(420px, calc(100vw - 32px)); max-height: 85vh; overflow-y: auto; background: #212121; border-radius: 12px; padding: 20px 24px; box-shadow: 0 4px 32px rgba(0,0,0,.6); }
.dialog h2 { margin: 0 0 16px; font-size: 16px; font-weight: 500; }
.dialog .actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 20px; }
.check { display: flex; align-items: center; gap: 16px; padding: 8px 0; cursor: pointer; }
.check input { width: 20px; height: 20px; accent-color: #f1f1f1; }
.field { width: 100%; background: transparent; border: 0; border-bottom: 1px solid var(--line); padding: 8px 0; outline: 0; font-size: 15px; }
.field:focus { border-color: var(--blue); }
#toasts { position: fixed; left: 24px; bottom: calc(24px + var(--bottom) + var(--safe-b)); z-index: 300; display: flex; flex-direction: column; gap: 8px; pointer-events: none; }
.toast { pointer-events: auto; background: #f1f1f1; color: #0f0f0f; border-radius: 8px; padding: 12px 16px; display: flex; align-items: center; gap: 24px; min-width: 280px; max-width: 480px; box-shadow: 0 4px 16px rgba(0,0,0,.4); animation: tin .2s ease-out; }
.toast button { color: #065fd4; font-weight: 500; }
@keyframes tin { from { transform: translateY(20px); opacity: 0; } }

/* ---------------- states ---------------- */
.empty { text-align: center; padding: 80px 24px; color: var(--text2); }
.empty svg { width: 120px; height: 120px; color: #3a3a3a; margin-bottom: 16px; }
.empty h2 { color: var(--text); font-weight: 400; font-size: 22px; margin: 0 0 8px; }
.spinner { width: 40px; height: 40px; margin: 40px auto; border: 3px solid #333; border-top-color: #f1f1f1; border-radius: 50%; animation: spin .9s linear infinite; }
.spinner.sm { width: 24px; height: 24px; margin: 16px auto; border-width: 2px; }
@keyframes spin { to { transform: rotate(360deg); } }
.skel .thumb, .skel .ava, .skel .sk { background: linear-gradient(90deg, #222 0%, #2c2c2c 50%, #222 100%); background-size: 200% 100%; animation: sh 1.4s infinite; }
.skel .sk { height: 18px; border-radius: 4px; margin-bottom: 8px; }
@keyframes sh { to { background-position: -200% 0; } }
.sentinel { height: 1px; }
.err { padding: 24px; color: #ff8a80; text-align: center; }

/* ---------------- watch page ---------------- */
.watch { display: flex; gap: 24px; padding: 24px 24px 0; max-width: 1754px; margin: 0 auto; }
.watch-main { flex: 1; min-width: 0; }
.watch-side { width: 402px; flex: none; }
.watch-player { position: relative; width: 100%; aspect-ratio: 16/9; background: #000; border-radius: 12px; overflow: hidden; }
body.theater .watch { flex-wrap: wrap; padding-top: 0; max-width: none; }
body.theater .watch-player-wrap { position: relative; width: calc(100% + 48px); margin: 0 -24px 0; background: #000; height: min(calc(100vw * 9 / 16), calc(100vh - 169px)); max-height: calc(100vh - 56px); }
body.theater .watch-player { height: 100%; aspect-ratio: auto; border-radius: 0; }
body.theater .watch-side { width: 402px; }
.w-title { font-size: 20px; line-height: 28px; font-weight: 700; margin: 12px 0 0; word-break: break-word; }
.w-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 12px; flex-wrap: wrap; }
.w-owner { display: flex; align-items: center; gap: 12px; min-width: 0; }
.w-owner .ava { width: 40px; height: 40px; }
.w-owner .n { font-weight: 500; font-size: 16px; display: flex; align-items: center; gap: 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.w-owner .n svg { width: 14px; height: 14px; color: var(--text2); }
.w-owner .s { color: var(--text2); font-size: 12px; }
.w-owner .btn { margin-left: 12px; }
.w-actions { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; }
.w-actions::-webkit-scrollbar { display: none; }
.pillgroup { display: flex; background: var(--hover); border-radius: 18px; height: 36px; flex: none; }
.pillgroup button { display: flex; align-items: center; gap: 6px; padding: 0 14px; font-weight: 500; }
.pillgroup button:first-child { border-radius: 18px 0 0 18px; } .pillgroup button:last-child { border-radius: 0 18px 18px 0; }
.pillgroup button + button { border-left: 1px solid var(--line); }
.pillgroup button:hover { background: var(--hover); }
.pillgroup svg { width: 22px; }
.w-desc { background: var(--hover); border-radius: 12px; padding: 12px; margin-top: 12px; font-size: 14px; cursor: pointer; position: relative; }
.w-desc:hover { background: var(--hover2); }
.w-desc.open { cursor: default; } .w-desc.open:hover { background: var(--hover); }
.w-desc .stats { font-weight: 500; }
.w-desc .body { white-space: pre-wrap; word-break: break-word; max-height: 60px; overflow: hidden; margin-top: 4px; }
.w-desc.open .body { max-height: none; }
.w-desc .body a { color: var(--blue); }
.w-desc .tg { font-weight: 500; margin-top: 12px; }
.chap-list { display: flex; gap: 8px; overflow-x: auto; margin-top: 12px; padding-bottom: 4px; }
.chap { flex: none; width: 170px; cursor: pointer; }
.chap img { width: 170px; aspect-ratio: 16/9; object-fit: cover; border-radius: 8px; background: #222; }
.chap div { font-size: 13px; font-weight: 500; margin-top: 6px; line-height: 18px; }
.chap span { color: var(--blue); font-size: 12px; }
.comments { margin-top: 24px; }
.comments-h { display: flex; align-items: center; gap: 32px; margin-bottom: 24px; }
.comments-h h3 { margin: 0; font-size: 20px; font-weight: 700; }
.cmt { display: flex; gap: 16px; margin-bottom: 20px; }
.cmt .ava { width: 40px; height: 40px; }
.cmt.reply .ava { width: 24px; height: 24px; font-size: 11px; }
.cmt .h { font-size: 13px; font-weight: 500; display: flex; gap: 4px; align-items: baseline; flex-wrap: wrap; }
.cmt .h span { color: var(--text2); font-weight: 400; font-size: 12px; }
.cmt .h .owner { background: #444; padding: 0 6px; border-radius: 10px; color: var(--text); }
.cmt .t { white-space: pre-wrap; word-break: break-word; margin-top: 2px; }
.cmt .t a { color: var(--blue); }
.cmt .f { display: flex; align-items: center; gap: 8px; color: var(--text2); font-size: 12px; margin-top: 4px; }
.cmt .f svg { width: 16px; }
.cmt .rbtn { color: var(--blue); font-weight: 500; display: flex; align-items: center; gap: 6px; height: 36px; padding: 0 12px; border-radius: 18px; margin-left: -12px; margin-top: 4px; }
.cmt .rbtn:hover { background: rgba(62,166,255,.15); }
.pinned { font-size: 12px; color: var(--text2); display: flex; align-items: center; gap: 4px; margin-bottom: 4px; }
.cmt-teaser { display: none; }
.queue-panel { border: 1px solid var(--line); border-radius: 12px; margin-bottom: 16px; overflow: hidden; }
.qp-head { padding: 12px 8px 8px 16px; background: #212121; display: flex; align-items: center; gap: 4px; }
.qp-head .t { flex: 1; min-width: 0; } .qp-head h3 { margin: 0; font-size: 18px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qp-head .s { color: var(--text2); font-size: 12px; }
.qp-list { max-height: 420px; overflow-y: auto; padding: 8px 0; }
.qp-list .crow { margin: 0; padding: 4px 8px 4px 0; align-items: center; }
.qp-list .crow .idx { width: 24px; text-align: center; color: var(--text2); font-size: 12px; flex: none; cursor: grab; }
.qp-list .crow .thumb { width: 100px; }
.qp-list .crow.drag-over { box-shadow: inset 0 2px 0 var(--blue); }
.queue-panel.collapsed .qp-list { display: none; }
.related-more { width: 100%; margin: 8px 0 16px; }

/* ---------------- player ---------------- */
.vp { position: absolute; inset: 0; background: #000; overflow: hidden; user-select: none; -webkit-user-select: none; outline: 0; }
.vp video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: #000; }
.vp .poster { position: absolute; inset: 0; background: #000 center/cover no-repeat; transition: opacity .3s; }
.vp.has-video .poster { opacity: 0; pointer-events: none; }
.vp .shade { position: absolute; left: 0; right: 0; bottom: 0; height: 160px; background: linear-gradient(transparent, rgba(0,0,0,.75)); pointer-events: none; opacity: 0; transition: opacity .25s; }
.vp .shade.top { top: 0; bottom: auto; height: 100px; background: linear-gradient(rgba(0,0,0,.6), transparent); }
.vp.show-ui .shade, .vp.paused .shade { opacity: 1; }
.vp .ctrls { position: absolute; left: 12px; right: 12px; bottom: 0; opacity: 0; transition: opacity .25s; }
.vp.show-ui .ctrls, .vp.paused .ctrls { opacity: 1; }
.vp.hide-cursor { cursor: none; }
.vp .bar-row { display: flex; align-items: center; height: 48px; gap: 2px; }
.vp .bar-row .grow { flex: 1; }
.vp .cb { width: 48px; height: 48px; display: flex; align-items: center; justify-content: center; opacity: .92; position: relative; }
.vp .cb:hover { opacity: 1; } .vp .cb svg { width: 28px; height: 28px; filter: drop-shadow(0 0 2px rgba(0,0,0,.5)); }
.vp .cb.sm svg { width: 24px; height: 24px; }
.vp .time { font-size: 13px; padding: 0 8px; white-space: nowrap; text-shadow: 0 0 2px rgba(0,0,0,.5); display: flex; gap: 4px; align-items: center; }
.vp .time .chap-name { color: #ddd; overflow: hidden; text-overflow: ellipsis; max-width: 240px; }
.vp .vol { display: flex; align-items: center; }
.vp .vol input { width: 0; opacity: 0; transition: width .2s, opacity .2s; accent-color: #fff; height: 4px; }
.vp .vol:hover input, .vp .vol input:focus { width: 64px; opacity: 1; margin-right: 6px; }
.vp .toggle { width: 36px; height: 14px; border-radius: 7px; background: rgba(255,255,255,.3); position: relative; transition: background .2s; }
.vp .toggle::after { content: ''; position: absolute; top: -3px; left: -2px; width: 20px; height: 20px; border-radius: 50%; background: #bbb; display: flex; transition: transform .2s, background .2s; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23333'%3E%3Cpath d='M6 6h2v12H6zm3.5 6 8.5 6V6z' transform='rotate(180 12 12)'/%3E%3C/svg%3E"); background-size: 14px; background-position: center; background-repeat: no-repeat; }
.vp .toggle.on { background: rgba(255,255,255,.6); } .vp .toggle.on::after { transform: translateX(20px); background-color: #fff; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23000'%3E%3Cpath d='M8 5v14l11-7z'/%3E%3C/svg%3E"); }
.vp .cb.cc.on::after { content: ''; position: absolute; bottom: 10px; left: 14px; right: 14px; height: 3px; background: var(--red); border-radius: 2px; }
.vp .cb .hd { position: absolute; top: 9px; right: 6px; background: var(--red); font-size: 8px; font-weight: 700; padding: 0 2px; border-radius: 2px; line-height: 10px; }
/* progress */
.vp .prog-wrap { position: relative; height: 16px; display: flex; align-items: flex-end; cursor: pointer; touch-action: none; }
.vp .segs { position: relative; display: flex; gap: 2px; width: 100%; height: 3px; transition: height .1s; }
.vp .prog-wrap:hover .segs, .vp.scrubbing .segs { height: 5px; }
.vp .seg { position: relative; height: 100%; background: rgba(255,255,255,.2); overflow: hidden; }
.vp .seg .buf { position: absolute; left: 0; top: 0; bottom: 0; background: rgba(255,255,255,.4); }
.vp .seg .play { position: absolute; left: 0; top: 0; bottom: 0; background: var(--red); }
.vp .seg .hov { position: absolute; left: 0; top: 0; bottom: 0; background: rgba(255,255,255,.5); }
.vp .seg.hot { transform: scaleY(1.6); }
.vp .sbmark { position: absolute; top: 0; bottom: 0; z-index: 1; opacity: .9; pointer-events: none; }
.vp .scrub { position: absolute; bottom: -4px; width: 13px; height: 13px; margin-left: -6.5px; border-radius: 50%; background: var(--red); transform: scale(0); transition: transform .1s; z-index: 2; pointer-events: none; }
.vp .prog-wrap:hover .scrub, .vp.scrubbing .scrub { transform: scale(1); }
.vp .heat { position: absolute; left: 0; right: 0; bottom: 5px; height: 40px; opacity: 0; transition: opacity .15s; pointer-events: none; }
.vp .prog-wrap:hover .heat, .vp.scrubbing .heat { opacity: 1; }
.vp .heat path { fill: rgba(255,255,255,.25); }
.vp .tip { position: absolute; bottom: 26px; transform: translateX(-50%); display: none; flex-direction: column; align-items: center; pointer-events: none; z-index: 5; }
.vp .tip .frame { border: 2px solid #fff; border-radius: 8px; background-repeat: no-repeat; background-color: #000; box-shadow: 0 0 8px rgba(0,0,0,.6); }
.vp .tip .lbl { font-size: 13px; font-weight: 500; text-shadow: 0 0 4px #000; margin-top: 4px; text-align: center; max-width: 200px; }
.vp .tip .lbl small { display: block; font-weight: 400; }
/* overlays */
.vp .center-ico { position: absolute; left: 50%; top: 50%; width: 52px; height: 52px; margin: -26px; border-radius: 50%; background: rgba(0,0,0,.6); display: flex; align-items: center; justify-content: center; opacity: 0; pointer-events: none; }
.vp .center-ico.go { animation: cpop .5s ease-out; }
@keyframes cpop { 0% { opacity: 1; transform: scale(1); } 100% { opacity: 0; transform: scale(2); } }
.vp .spin { position: absolute; left: 50%; top: 50%; width: 56px; height: 56px; margin: -28px; border: 4px solid rgba(255,255,255,.25); border-top-color: #fff; border-radius: 50%; animation: spin .9s linear infinite; display: none; pointer-events: none; }
.vp.loading .spin { display: block; }
.vp .seek-ripple { position: absolute; top: 0; bottom: 0; width: 40%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; opacity: 0; pointer-events: none; background: rgba(255,255,255,.08); font-size: 12px; font-weight: 500; }
.vp .seek-ripple.l { left: 0; border-radius: 0 50% 50% 0 / 0 100% 100% 0; } .vp .seek-ripple.r { right: 0; border-radius: 50% 0 0 50% / 100% 0 0 100%; }
.vp .seek-ripple.go { animation: rip .6s ease-out; }
@keyframes rip { 0% { opacity: 1; } 100% { opacity: 0; } }
.vp .skip-btn { position: absolute; right: 16px; bottom: 76px; background: rgba(0,0,0,.7); border: 1px solid rgba(255,255,255,.3); padding: 10px 18px; border-radius: 4px; font-weight: 500; display: none; align-items: center; gap: 8px; z-index: 4; }
.vp .skip-btn.show { display: flex; } .vp .skip-btn svg { width: 22px; height: 22px; }
.vp .menu-pop { position: absolute; right: 12px; bottom: 60px; background: rgba(28,28,28,.92); border-radius: 12px; padding: 8px 0; min-width: 250px; max-height: calc(100% - 80px); overflow-y: auto; z-index: 10; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.vp .menu-pop .mi { height: 40px; } .vp .menu-pop .mi:hover { background: rgba(255,255,255,.1); }
.vp .menu-pop .mi.sel::before { content: ''; width: 24px; height: 24px; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23fff'%3E%3Cpath d='M9 16.17 4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z'/%3E%3C/svg%3E") center no-repeat; margin-right: -8px; }
.vp .menu-pop .mi.nosel { padding-left: 56px; }
.vp .menu-pop .mh { display: flex; align-items: center; gap: 8px; padding: 4px 8px 8px; border-bottom: 1px solid rgba(255,255,255,.2); margin-bottom: 8px; font-weight: 500; }
.vp .err-box { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; text-align: center; padding: 24px; background: rgba(0,0,0,.85); z-index: 8; }
.vp .err-box p { max-width: 520px; color: #ddd; margin: 0; }
.vp .endcard { position: absolute; inset: 0; background: rgba(0,0,0,.8); display: flex; align-items: center; justify-content: center; z-index: 7; }
.vp .endcard .box { width: min(420px, 80%); text-align: center; }
.vp .endcard .lbl { color: #ddd; margin-bottom: 8px; font-size: 14px; }
.vp .endcard .nt { font-size: 18px; font-weight: 500; margin-bottom: 4px; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.vp .endcard .ns { color: var(--text2); margin-bottom: 16px; }
.vp .endcard .ring { width: 64px; height: 64px; margin: 0 auto 16px; position: relative; cursor: pointer; }
.vp .endcard .ring svg { width: 64px; height: 64px; }
.vp .endcard .ring circle { fill: none; stroke: #fff; stroke-width: 3; transform: rotate(-90deg); transform-origin: center; }
.vp .endcard .ring .play { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
.vp .endcard .ring .play svg { width: 36px; height: 36px; }
.vp .top-row { position: absolute; top: 0; left: 0; right: 0; display: flex; align-items: center; padding: 8px 12px; gap: 8px; opacity: 0; transition: opacity .25s; }
.vp.show-ui .top-row, .vp.paused .top-row { opacity: 1; }
.vp .top-row .tt { flex: 1; font-size: 18px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-shadow: 0 0 2px #000; display: none; }
.vp.fs .top-row .tt { display: block; }
.vp .mobile-center { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); display: none; align-items: center; gap: 48px; opacity: 0; transition: opacity .2s; }
.vp .mobile-center button { width: 56px; height: 56px; border-radius: 50%; background: rgba(0,0,0,.4); display: flex; align-items: center; justify-content: center; }
.vp .mobile-center .pp { width: 68px; height: 68px; } .vp .mobile-center .pp svg { width: 44px; height: 44px; }
.vp.touch .mobile-center { display: flex; pointer-events: none; }
.vp.touch.show-ui .mobile-center, .vp.touch.paused .mobile-center { opacity: 1; pointer-events: auto; }
.vp.touch .ctrls .pp-btn, .vp.touch .ctrls .next-btn, .vp.touch .vol { display: none; }
.vp video::cue { background: rgba(8,8,8,.75); font-size: 1.1em; }
.vp.mini .ctrls, .vp.mini .top-row, .vp.mini .shade, .vp.mini .mobile-center, .vp.mini .skip-btn { display: none !important; }
.vp.fs video { object-fit: contain; }
.vp:fullscreen { border-radius: 0; } .vp:-webkit-full-screen { width: 100%; height: 100%; }

/* ---------------- miniplayer ---------------- */
#mini { position: fixed; z-index: 80; right: 12px; bottom: 12px; width: 400px; background: #212121; border-radius: 12px; overflow: hidden; box-shadow: 0 4px 24px rgba(0,0,0,.6); }
#mini .mini-video { position: relative; aspect-ratio: 16/9; background: #000; cursor: pointer; }
#mini .mini-info { display: flex; align-items: center; gap: 8px; padding: 10px 8px 10px 12px; }
#mini .mini-text { flex: 1; min-width: 0; cursor: pointer; }
#mini .mini-title { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#mini .mini-sub { color: var(--text2); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#mini .mini-btns { display: flex; }
#mini .mini-progress { height: 2px; background: rgba(255,255,255,.2); } #mini .mini-progress i { display: block; height: 100%; background: var(--red); width: 0; }

/* ---------------- shorts ---------------- */
.shorts { position: relative; height: calc(100vh - var(--top) - var(--safe-t)); height: calc(100dvh - var(--top) - var(--safe-t)); overflow-y: scroll; scroll-snap-type: y mandatory; scrollbar-width: none; }
.shorts::-webkit-scrollbar { display: none; }
.short { height: 100%; scroll-snap-align: start; scroll-snap-stop: always; display: flex; align-items: center; justify-content: center; gap: 12px; padding: 12px 0; }
.short-stage { position: relative; height: 100%; aspect-ratio: 9/16; max-width: 100%; border-radius: 12px; overflow: hidden; background: #000 center/cover no-repeat; }
.short-stage video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.short-info { position: absolute; left: 0; right: 0; bottom: 0; padding: 60px 72px 16px 16px; background: linear-gradient(transparent, rgba(0,0,0,.7)); pointer-events: none; }
.short-info * { pointer-events: auto; }
.short-info .ch { display: flex; align-items: center; gap: 8px; font-weight: 500; margin-bottom: 8px; }
.short-info .ch .ava { width: 32px; height: 32px; }
.short-info .st { font-size: 15px; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.short-actions { display: flex; flex-direction: column; gap: 16px; align-self: flex-end; padding-bottom: 16px; }
.short-actions button { display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 12px; }
.short-actions button span.ic { width: 48px; height: 48px; border-radius: 50%; background: var(--hover); display: flex; align-items: center; justify-content: center; }
.short-actions button.on span.ic { background: #f1f1f1; color: #0f0f0f; }
.short-prog { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: rgba(255,255,255,.3); } .short-prog i { display: block; height: 100%; background: var(--red); width: 0; }
.short-pause { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; pointer-events: none; }
.short-pause svg { width: 72px; height: 72px; opacity: 0; filter: drop-shadow(0 0 8px rgba(0,0,0,.5)); }
.short-stage.paused .short-pause svg { opacity: .9; }
.short-nav { position: fixed; right: 24px; top: 50%; transform: translateY(-50%); display: flex; flex-direction: column; gap: 16px; z-index: 5; }
.short-nav .icon-btn { width: 56px; height: 56px; background: var(--hover); }
.short-mute { position: absolute; top: 12px; right: 12px; z-index: 3; background: rgba(0,0,0,.4); }

/* ---------------- channel ---------------- */
.ch-banner { aspect-ratio: 6.2/1; border-radius: 12px; background: #222 center/cover no-repeat; margin-top: 8px; }
.ch-head { display: flex; gap: 24px; align-items: center; padding: 24px 0 8px; }
.ch-head .ava { width: 160px; height: 160px; font-size: 56px; }
.ch-head h1 { margin: 0 0 8px; font-size: 36px; line-height: 1.1; font-weight: 700; }
.ch-head .sub { margin-bottom: 8px; }
.ch-head .d { color: var(--text2); overflow: hidden; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; margin-bottom: 12px; max-width: 700px; }
.tabs { display: flex; gap: 24px; border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.tab { height: 48px; display: flex; align-items: center; font-weight: 500; font-size: 16px; color: var(--text2); border-bottom: 2px solid transparent; white-space: nowrap; }
.tab:hover { color: var(--text); } .tab.active { color: var(--text); border-color: var(--text); }

/* ---------------- library / history / playlist / settings ---------------- */
.lib-head { display: flex; align-items: center; gap: 16px; padding: 24px 0; }
.lib-head .ava { width: 120px; height: 120px; font-size: 48px; }
.lib-head h1 { margin: 0; font-size: 36px; }
.sec-h { display: flex; align-items: center; justify-content: space-between; margin: 24px 0 12px; }
.sec-h h2 { margin: 0; font-size: 20px; }
.hist { display: flex; gap: 24px; padding-top: 24px; }
.hist-list { flex: 1; max-width: 860px; min-width: 0; }
.hist-side { width: 300px; flex: none; position: sticky; top: 80px; align-self: flex-start; }
.hist-side .field { margin-bottom: 24px; }
.hist-side .btn { width: 100%; justify-content: flex-start; margin-bottom: 8px; background: none; }
.hist-side .btn:hover { background: var(--hover); }
.day-h { font-size: 20px; font-weight: 700; margin: 24px 0 16px; }
.pl-page { display: flex; gap: 24px; padding-top: 24px; }
.pl-side { width: 360px; flex: none; border-radius: 16px; padding: 24px; position: sticky; top: 80px; align-self: flex-start; background: linear-gradient(rgba(70,40,40,.9), rgba(15,15,15,.6)); overflow: hidden; }
.pl-side .thumb { margin-bottom: 16px; }
.pl-side h1 { font-size: 28px; line-height: 36px; margin: 0 0 12px; word-break: break-word; }
.pl-side .sub { margin-bottom: 16px; }
.pl-side .row { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.pl-side .row .btn.white, .pl-side .row .btn.grey { flex: 1; justify-content: center; }
.pl-list { flex: 1; min-width: 0; }
.pl-list .crow { padding: 8px 8px 8px 0; margin: 0; border-radius: 12px; align-items: center; }
.pl-list .crow:hover { background: var(--hover); }
.pl-list .crow .idx { width: 32px; text-align: center; color: var(--text2); flex: none; }
.settings { max-width: 860px; padding-top: 24px; }
.settings h1 { font-size: 28px; margin: 0 0 8px; }
.set-sec { border-top: 1px solid var(--line); padding: 24px 0; }
.set-sec h2 { margin: 0 0 4px; font-size: 18px; } .set-sec > p { color: var(--text2); margin: 0 0 16px; }
.set-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 10px 0; min-height: 48px; }
.set-row .l { flex: 1; } .set-row .l small { display: block; color: var(--text2); }
select.sel { background: #212121; border: 1px solid var(--line); border-radius: 8px; padding: 6px 10px; min-width: 150px; }
.sw { position: relative; width: 36px; height: 14px; border-radius: 7px; background: #717171; flex: none; cursor: pointer; }
.sw::after { content: ''; position: absolute; top: -3px; left: -2px; width: 20px; height: 20px; border-radius: 50%; background: #f1f1f1; transition: transform .15s; box-shadow: 0 1px 3px rgba(0,0,0,.5); }
.sw.on { background: #3ea6ff88; } .sw.on::after { transform: translateX(20px); background: var(--blue); }
.sbdot { display: inline-block; width: 12px; height: 12px; border-radius: 3px; margin-right: 8px; vertical-align: -1px; }
.tags { display: flex; gap: 8px; flex-wrap: wrap; }
.tagc { height: 32px; border-radius: 16px; background: var(--hover); padding: 0 6px 0 12px; display: flex; align-items: center; gap: 4px; }
.tagc button { width: 22px; height: 22px; border-radius: 50%; display: flex; align-items: center; justify-content: center; } .tagc button svg { width: 16px; }
.tagc button:hover { background: var(--hover2); }
pre.diag { background: #1a1a1a; padding: 12px; border-radius: 8px; overflow-x: auto; font-size: 12px; white-space: pre-wrap; }
.imp-steps { color: #ccc; line-height: 1.7; padding-left: 20px; }
.imp-steps b { color: #fff; }
.drop { display: block; border: 2px dashed var(--line); border-radius: 16px; padding: 40px; text-align: center; cursor: pointer; margin: 16px 0; }
.drop.over { border-color: var(--blue); background: rgba(62,166,255,.08); }
.drop svg { width: 48px; height: 48px; color: var(--text2); }
.imp-res { background: #1a1a1a; border-radius: 12px; padding: 16px; margin-top: 12px; }
.sub-list .lrow { align-items: center; }
.sub-list .lrow .ava { width: 88px; height: 88px; font-size: 32px; }

/* ---------------- profiles ---------------- */
.profiles { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 24px; text-align: center; }
.profiles h1 { font-size: 40px; font-weight: 500; margin: 0 0 40px; }
.prof-grid { display: flex; flex-wrap: wrap; justify-content: center; gap: 32px; max-width: 900px; }
.prof { width: 140px; display: flex; flex-direction: column; align-items: center; gap: 12px; color: var(--text2); font-size: 18px; cursor: pointer; position: relative; }
.prof:hover { color: var(--text); }
.prof .pava { width: 128px; height: 128px; border-radius: 16px; display: flex; align-items: center; justify-content: center; font-size: 56px; font-weight: 500; color: #fff; border: 3px solid transparent; transition: border-color .15s, transform .15s; }
.prof:hover .pava { border-color: #f1f1f1; transform: scale(1.03); }
.prof.add .pava { background: #222; color: var(--text2); } .prof.add .pava svg { width: 64px; height: 64px; }
.prof .edit { position: absolute; top: 44px; left: 50%; transform: translateX(-50%); background: rgba(0,0,0,.6); border-radius: 50%; width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; color: #fff; }
.colors { display: flex; gap: 10px; flex-wrap: wrap; margin: 12px 0; }
.colors button { width: 36px; height: 36px; border-radius: 50%; border: 3px solid transparent; }
.colors button.sel { border-color: #fff; }
.login { max-width: 360px; margin: 20vh auto; padding: 24px; text-align: center; }
.login .field { margin: 24px 0; text-align: center; }

/* ---------------- responsive ---------------- */
@media (max-width: 1312px) { .watch-side { width: 360px; } }
@media (max-width: 1016px) {
  .watch { flex-direction: column; padding: 24px 24px 0; }
  .watch-side { width: auto; }
  body.theater .watch-side { width: auto; }
}
@media (max-width: 700px) {
  :root { --top: 48px; --bottom: 48px; }
  #topbar { padding: var(--safe-t) 4px 0 12px; gap: 4px; }
  #menuBtn { display: none; }
  .logo { font-size: 18px; }
  .tb-center { display: none; }
  #searchOpen { display: inline-flex; }
  body.searching .tb-start, body.searching .tb-end { display: none; }
  body.searching .tb-center { display: flex; max-width: none; }
  body.searching .mobile-back { display: inline-flex; }
  #searchForm { margin-left: 0; }
  .search-box { border-radius: 20px; border-right: 1px solid #303030; height: 36px; background: #222; border: 0; }
  .search-box:focus-within { margin-left: 0; padding-left: 16px; background-image: none; }
  .search-btn { display: none; }
  #suggest { position: fixed; top: calc(var(--top) + var(--safe-t)); left: 0; right: 0; bottom: 0; border-radius: 0; background: var(--bg); padding-top: 0; }
  .sug { min-height: 48px; }
  #sidebar { display: none; }
  #page { padding-left: 0 !important; }
  #bottomnav { display: flex; position: fixed; z-index: 50; left: 0; right: 0; bottom: 0; height: calc(var(--bottom) + var(--safe-b)); padding-bottom: var(--safe-b); background: var(--bg); border-top: 1px solid rgba(255,255,255,.1); }
  #bottomnav a { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; font-size: 10px; }
  #bottomnav a svg { width: 24px; height: 24px; } #bottomnav a.active { font-weight: 500; }
  #bottomnav .bn-ava { width: 24px; height: 24px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 500; color: #fff; }
  #bottomnav a.active .bn-ava { box-shadow: 0 0 0 2px #fff; }
  .page-pad { padding: 0; }
  .sticky-chips { margin: 0; padding: 8px 12px; }
  .grid { grid-template-columns: 1fr; gap: 0; padding-top: 0; }
  .grid .card { margin-bottom: 16px; }
  .grid .thumb, .card:hover .thumb { border-radius: 0; }
  .grid .meta { padding: 12px 12px 0; }
  .grid .more { right: 0; top: 6px; }
  .title { font-size: 14px; line-height: 20px; max-height: 40px; }
  .sub { font-size: 12px; line-height: 18px; margin-top: 2px; }
  .sub .line { display: inline; } .sub .line + .line::before { content: ' • '; }
  .shelf { padding: 8px 12px 16px; }
  .shelf-h { font-size: 18px; margin-bottom: 12px; }
  .hscroll { grid-auto-columns: 44vw; }
  .hscroll.wide { grid-auto-columns: 72vw; }
  .scard .title { font-size: 14px; }
  .lrow { flex-direction: column; gap: 0; margin-bottom: 16px; }
  .lrow .thumb { width: 100%; max-width: none; border-radius: 0; }
  .lrow .meta-l { padding: 12px 12px 0; display: flex; gap: 12px; }
  .lrow .title { font-size: 14px; line-height: 20px; }
  .lrow .chline, .lrow .desc { display: none; }
  .lrow .more { top: auto; bottom: 0; }
  .chrow { padding: 0 12px; } .chrow .bigava { width: auto; } .chrow .bigava .ava { width: 64px; height: 64px; font-size: 24px; }
  .page-pad .crow, .page-pad .lst { padding-left: 12px; padding-right: 12px; }
  /* watch */
  body.watch-page #topbar { display: none; }
  body.watch-page #page { padding-top: var(--safe-t); }
  .watch { padding: 0; gap: 0; }
  .watch-player-wrap { position: sticky; top: var(--safe-t); z-index: 30; background: #000; }
  .watch-player { border-radius: 0; }
  .watch-info { padding: 0 12px; }
  .w-title { font-size: 18px; line-height: 24px; margin-top: 10px; }
  .w-row { flex-direction: column; align-items: stretch; flex-wrap: nowrap; }
  .w-owner > a:nth-child(2) { flex: 1; overflow: hidden; }
  .w-owner { justify-content: space-between; } .w-owner .btn { margin-left: auto; }
  .w-actions { margin: 0 -12px; padding: 0 12px; }
  .watch-side { padding: 0 12px; margin-top: 16px; }
  .crow .thumb { width: 160px; }
  .comments { display: none; }
  .comments.open { display: block; position: fixed; inset: auto 0 0 0; top: calc(var(--safe-t) + 56.25vw); z-index: 85; background: #212121; border-radius: 12px 12px 0 0; margin: 0; padding: 12px 12px calc(12px + var(--safe-b)); overflow-y: auto; }
  .cmt-teaser { display: block; background: var(--hover); border-radius: 12px; padding: 12px; margin-top: 12px; cursor: pointer; }
  .cmt-teaser .h { font-weight: 500; } .cmt-teaser .h span { color: var(--text2); font-weight: 400; margin-left: 6px; }
  .cmt-teaser .p { display: flex; gap: 8px; align-items: center; margin-top: 8px; font-size: 13px; } .cmt-teaser .p .ava { width: 24px; height: 24px; font-size: 11px; }
  .cmt-teaser .p div:last-child { overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
  #mini { left: 0; right: 0; bottom: calc(var(--bottom) + var(--safe-b)); width: auto; border-radius: 0; display: flex; flex-wrap: wrap; box-shadow: none; border-top: 1px solid #333; }
  #mini .mini-video { width: 112px; flex: none; }
  #mini .mini-info { flex: 1; min-width: 0; padding: 0 4px 0 12px; }
  #mini .mini-progress { width: 100%; order: -1; }
  body.has-mini #page { padding-bottom: calc(var(--bottom) + var(--safe-b) + 90px); }
  body.has-mini #toasts { bottom: calc(var(--bottom) + var(--safe-b) + 80px); }
  #toasts { left: 12px; right: 12px; } .toast { min-width: 0; max-width: none; }
  .vp .cb { width: 40px; height: 40px; } .vp .cb svg { width: 24px; height: 24px; }
  .vp .bar-row { height: 40px; }
  .vp .time .chap-name { display: none; }
  .vp .skip-btn { bottom: 56px; right: 8px; padding: 8px 12px; }
  /* shorts */
  .shorts { height: calc(100vh - var(--top) - var(--bottom) - var(--safe-t) - var(--safe-b)); height: calc(100dvh - var(--top) - var(--bottom) - var(--safe-t) - var(--safe-b)); }
  .short { padding: 0; position: relative; }
  .short-stage { border-radius: 0; width: 100%; aspect-ratio: auto; }
  .short-actions { position: absolute; right: 8px; bottom: 24px; z-index: 2; }
  .short-actions button span.ic { background: rgba(0,0,0,.3); }
  .short-nav { display: none; }
  .ch-head { flex-direction: column; text-align: center; gap: 12px; padding: 16px 12px; }
  .ch-head .ava { width: 80px; height: 80px; font-size: 32px; }
  .ch-head h1 { font-size: 24px; }
  .ch-banner { border-radius: 0; margin: 0; }
  .tabs { padding: 0 12px; }
  .hist { flex-direction: column-reverse; padding: 12px; } .hist-side { width: auto; position: static; }
  .pl-page { flex-direction: column; padding-top: 0; }
  .pl-side { width: auto; position: static; border-radius: 0; }
  .settings { padding: 12px; }
  .lib-head { padding: 16px 12px; } .lib-head .ava { width: 64px; height: 64px; font-size: 28px; } .lib-head h1 { font-size: 24px; }
  .sec-h { padding: 0 12px; }
  .profiles h1 { font-size: 28px; }
  .prof { width: 110px; } .prof .pava { width: 100px; height: 100px; font-size: 42px; }
  .prof .edit { top: 28px; }
  .empty { padding: 60px 16px; }
}
@media (min-width: 701px) { .lrow .meta-l { display: contents; } }
.vp .menu-pop .mi > span:first-child { display: flex; align-items: center; gap: 4px; }
.vp .menu-pop .mi svg { width: 22px; height: 22px; }
.vp .unmute { position: absolute; left: 12px; top: 12px; z-index: 6; display: flex; align-items: center; gap: 8px; background: rgba(0,0,0,.75); padding: 8px 14px 8px 10px; border-radius: 20px; font-weight: 500; }
.vp .unmute svg { width: 22px; height: 22px; }
.mini-ov { position: absolute; inset: 0; z-index: 5; pointer-events: none; opacity: 0; transition: opacity .2s; background: rgba(0,0,0,.25); }
#mini .mini-video:hover .mini-ov, .touch-dev .mini-ov { opacity: 1; }
.mini-ov button { position: absolute; pointer-events: auto; width: 40px; height: 40px; border-radius: 50%; background: rgba(0,0,0,.6); display: flex; align-items: center; justify-content: center; }
.mini-ov button:hover { background: rgba(0,0,0,.85); }
.mini-ov .mini-close { top: 8px; right: 8px; }
.mini-ov .mini-open { top: 8px; left: 8px; }
.mini-ov .mini-pp { left: 50%; top: 50%; width: 56px; height: 56px; margin: -28px; }
.mini-ov .mini-pp svg { width: 36px; height: 36px; }
@media (max-width: 700px) { .mini-ov { display: none; } }
