:root {
  --bg: #0d0f13;
  --panel: #151922;
  --panel-2: #1b2130;
  --line: #242b3a;
  --text: #e8ecf4;
  --muted: #8b95a8;
  --accent: #f5a524;
  --accent-2: #ffcf7a;
  --danger: #e5484d;
  --ok: #46a758;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font: 15px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
        "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
.container { max-width: 1080px; margin: 0 auto; padding: 0 20px; }

header.top {
  border-bottom: 1px solid var(--line);
  background: rgba(13,15,19,.9);
  backdrop-filter: blur(8px);
  position: sticky; top: 0; z-index: 10;
}
header.top .inner { display: flex; align-items: center; gap: 18px; height: 60px; }
.brand { font-size: 17px; font-weight: 700; letter-spacing: .3px; display: flex; gap: 8px; align-items: center; }
.brand span.dot { color: var(--accent); }
.nav { margin-left: auto; display: flex; align-items: center; gap: 6px; font-size: 14px; }
.nav a, .nav form button {
  color: var(--muted); padding: 6px 10px; border-radius: 8px;
  background: none; border: 0; font: inherit; cursor: pointer;
}
.nav a:hover, .nav form button:hover { color: var(--text); background: var(--panel-2); }
.nav .who { color: var(--text); }
.nav .who b { color: var(--accent); font-weight: 600; }

main { padding: 34px 0 70px; }
h1 { font-size: 22px; margin: 0 0 4px; letter-spacing: .2px; }
h2 { font-size: 17px; margin: 0 0 14px; }
p.sub { color: var(--muted); margin: 0 0 24px; font-size: 14px; }

.flash { padding: 10px 14px; border-radius: 10px; margin-bottom: 18px; font-size: 14px; }
.flash.ok { background: rgba(70,167,88,.12); color: #8fe0a0; border: 1px solid rgba(70,167,88,.3); }
.flash.err { background: rgba(229,72,77,.12); color: #ff9a9d; border: 1px solid rgba(229,72,77,.3); }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 18px; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; transition: transform .15s, border-color .15s; }
.card:hover { transform: translateY(-2px); border-color: #3a455c; }
.thumb { aspect-ratio: 16/9; background: #0a0c10 center/cover no-repeat; display: block; position: relative; }
.thumb .dur { position: absolute; right: 8px; bottom: 8px; background: rgba(0,0,0,.72); padding: 1px 6px; border-radius: 6px; font-size: 12px; color: #fff; }
.card .body { padding: 12px 14px 14px; }
.card .t { font-size: 14px; font-weight: 600; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card .m { color: var(--muted); font-size: 12px; margin-top: 6px; }

.empty { border: 1px dashed var(--line); border-radius: 14px; padding: 60px 20px; text-align: center; color: var(--muted); }

.searchbar { display: flex; gap: 10px; margin-bottom: 22px; }
input[type=text], input[type=password], input[type=search], input[type=email], textarea, select {
  width: 100%; background: var(--panel); border: 1px solid var(--line); color: var(--text);
  padding: 10px 12px; border-radius: 10px; font: inherit; outline: none;
}
input:focus, textarea:focus { border-color: #46536b; }
textarea { resize: vertical; min-height: 80px; }
button.btn, a.btn {
  display: inline-block; background: var(--accent); color: #171002; border: 0;
  padding: 10px 18px; border-radius: 10px; font: inherit; font-weight: 600; cursor: pointer;
}
button.btn:hover, a.btn:hover { background: var(--accent-2); }
.btn.ghost { background: var(--panel-2); color: var(--text); border: 1px solid var(--line); }
.btn.ghost:hover { background: #232b3d; }
.btn.sm { padding: 6px 12px; font-size: 13px; border-radius: 8px; }
.btn.danger { background: rgba(229,72,77,.16); color: #ff9a9d; border: 1px solid rgba(229,72,77,.35); }
.btn.danger:hover { background: rgba(229,72,77,.28); }

.auth { max-width: 380px; margin: 6vh auto 0; background: var(--panel); border: 1px solid var(--line); border-radius: 16px; padding: 28px; }
.auth h1 { margin-bottom: 20px; }
.auth label { display: block; font-size: 13px; color: var(--muted); margin: 14px 0 6px; }
.auth .btn { width: 100%; margin-top: 20px; }
.auth .alt { text-align: center; margin-top: 16px; font-size: 13px; color: var(--muted); }
.auth .alt a { color: var(--accent); }

.hero { text-align: center; padding: 8vh 0 6vh; }
.hero h1 { font-size: 40px; line-height: 1.2; margin-bottom: 14px; }
.hero p { color: var(--muted); font-size: 16px; margin-bottom: 30px; }
.hero .actions { display: flex; gap: 12px; justify-content: center; }
.hero .cat { font-size: 56px; margin-bottom: 10px; }

.watch-wrap {
  max-width: 1400px; margin: 0 auto; display: grid; grid-template-columns: minmax(0, 1fr);
  gap: 12px; align-items: start;
}
.watch-main { min-width: 0; }
.watch-side { min-width: 0; }
@media (min-width: 1000px) {
  .watch-wrap { grid-template-columns: minmax(0, 1fr) 330px; gap: 22px; }
}
video { width: 100%; border-radius: 14px; background: #000; border: 1px solid var(--line); display: block; }
.watch-title { font-size: 19px; font-weight: 700; margin: 0 0 6px; }
.watch-meta { color: var(--muted); font-size: 13px; margin-bottom: 12px; }
.desc {
  color: #c3cad8; font-size: 14px; white-space: pre-wrap; border-top: 1px solid var(--line);
  padding-top: 12px; max-height: 240px; overflow: auto;
}

table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
th { color: var(--muted); font-weight: 500; font-size: 13px; }
td.actions { display: flex; gap: 8px; }

.panel { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 20px; margin-bottom: 22px; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 14px; margin-bottom: 22px; }
.stat { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 16px; }
.stat .v { font-size: 24px; font-weight: 700; color: var(--accent); }
.stat .k { color: var(--muted); font-size: 12px; margin-top: 2px; }

.formrow { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.formrow label { display: block; font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.formrow > div { margin-bottom: 14px; }
.tabs { display: flex; gap: 6px; margin-bottom: 22px; border-bottom: 1px solid var(--line); }
.tabs a { padding: 9px 14px; color: var(--muted); font-size: 14px; border-bottom: 2px solid transparent; }
.tabs a.on { color: var(--text); border-bottom-color: var(--accent); }
.small { font-size: 12px; color: var(--muted); }
footer.bottom { border-top: 1px solid var(--line); padding: 18px 0; color: #5d6578; font-size: 12px; text-align: center; }

/* ---- 游客试看：播放器遮罩 ---- */
.playerbox {
  position: relative; background: #000; border: 1px solid var(--line); border-radius: 14px;
  overflow: hidden; width: 100%;
}
.playerbox video {
  display: block; margin: 0 auto; height: 100%; width: auto; max-width: 100%;
  border: 0; border-radius: 0; object-fit: contain;
}
/* 播放页专用：整块画面一次铺满，不出现滚动条 */
body.watchpage footer.bottom { display: none; }
body.watchpage main { padding: 14px 0 6px; }
body.watchpage main.container { max-width: 1400px; }
body.is-mobile header.top .inner { height: 52px; }
body.is-mobile main { padding: 10px 0 12px; }
body.is-mobile .watch-title { font-size: 16px; }
body.is-mobile .desc { max-height: 170px; }
.guestcta {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 10px;
  background: rgba(245,165,36,.10); border: 1px solid rgba(245,165,36,.32);
  color: #ffd79a; border-radius: 12px; padding: 9px 12px; font-size: 13.5px; line-height: 1.5;
}
.guestcta b { color: var(--accent-2); }
.guestcta .sp { margin-left: auto; display: flex; gap: 8px; }
.playchip {
  position: absolute; top: 8px; right: 8px; z-index: 4;
  display: inline-flex; align-items: center; gap: 6px;
  background: rgba(13,15,19,.78); border: 1px solid rgba(245,165,36,.5);
  color: #ffd79a; font-size: 12px; padding: 4px 9px; border-radius: 999px;
  backdrop-filter: blur(4px); text-decoration: none; line-height: 1.4;
}
.playchip:hover { background: rgba(245,165,36,.2); }
.playchip .pcdot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.userbar {
  margin-top: 10px; background: rgba(70,167,88,.10); border: 1px solid rgba(70,167,88,.3);
  color: #8fe0a0; border-radius: 12px; padding: 9px 12px; font-size: 13.5px;
}
.userbar b { color: #b7f0c4; }
body.is-mobile .playchip { font-size: 11px; padding: 3px 8px; top: 6px; right: 6px; }
body.is-mobile .guestcta { font-size: 13px; padding: 8px 10px; }
body.is-mobile .guestcta .sp { margin-left: 0; width: 100%; }
body.is-mobile .lockcat { font-size: 26px; }
body.is-mobile .lock h3 { font-size: 17px; }
body.is-mobile .lock p { font-size: 13px; margin-bottom: 12px; }
.lock {
  display: none; position: absolute; inset: 0; z-index: 5;
  align-items: center; justify-content: center; text-align: center;
  background: radial-gradient(ellipse at center, rgba(13,15,19,.82) 0%, rgba(13,15,19,.96) 70%);
  backdrop-filter: blur(6px); border-radius: 14px; padding: 20px;
}
.lock.show { display: flex; }
.lockinner { max-width: 380px; }
.lockcat { font-size: 34px; margin-bottom: 6px; }
.lock h3 { margin: 0 0 8px; font-size: 20px; }
.lock p { color: var(--muted); font-size: 14px; margin: 0 0 18px; }
.lockbtns { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.guesttag {
  display: inline-block; margin-left: 8px; padding: 1px 8px; border-radius: 6px;
  background: rgba(245,165,36,.12); color: var(--accent-2); border: 1px solid rgba(245,165,36,.28);
  font-size: 12px;
}
.guestbar {
  background: rgba(245,165,36,.09); border: 1px solid rgba(245,165,36,.28);
  color: #ffd79a; border-radius: 12px; padding: 11px 14px; font-size: 14px; margin-bottom: 18px;
}
.guestbar a { color: var(--accent); font-weight: 600; }
label.check { display: flex; align-items: center; gap: 8px; color: var(--text); font-size: 14px; }
label.check input { width: auto; }
.sharebox { margin-top: 16px; display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.sharebox .small { word-break: break-all; color: var(--muted); font-size: 12px; }
.sharebox .small a { color: var(--accent-2); }
.hint { color: var(--muted); font-size: 12.5px; margin-top: 8px; line-height: 1.6; }
.hint code { background: #10141b; border: 1px solid var(--line); border-radius: 5px; padding: 1px 5px; }
@media (max-width: 620px) { .formrow { grid-template-columns: 1fr; } .hero h1 { font-size: 30px; } }
