:root {
    --bg: #0a0a0a;
    --bg-elev: #151515;
    --bg-card: #1c1c1c;
    --red: #e50914;
    --red-dark: #b20710;
    --yellow: #ffd700;
    --text: #f2f2f2;
    --text-dim: #a0a0a0;
    --border: #2a2a2a;
  }
  * { margin: 0; padding: 0; box-sizing: border-box; }
  html { scroll-behavior: smooth; }
  body {
    background: var(--bg);
    color: var(--text);
    font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
  }
  img { display: block; max-width: 100%; }
  a { color: inherit; text-decoration: none; }
  .container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }

  /* 顶部导航 */
  .site-header {
    position: sticky; top: 0; z-index: 100;
    background: rgba(10,10,10,0.95);
    border-bottom: 1px solid var(--border);
    backdrop-filter: blur(10px);
  }
  .header-inner {
    display: flex; align-items: center; justify-content: space-between;
    padding: 12px 0;
  }
  .brand { display: flex; align-items: center; gap: 10px; }
  .brand img { height: 32px; width: auto; border-radius: 6px; }
  .brand-name { font-size: 18px; font-weight: 700; color: var(--red); letter-spacing: 1px; }
  .menu-toggle {
    background: var(--red); color: #fff; border: none;
    padding: 8px 16px; border-radius: 6px; font-size: 14px;
    cursor: pointer; font-weight: 600;
  }
  .main-nav {
    display: none;
    flex-direction: column;
    background: var(--bg-elev);
    border-top: 1px solid var(--border);
    padding: 8px 0;
  }
  .main-nav.open { display: flex; }
  .main-nav a {
    padding: 10px 20px; font-size: 14px; color: var(--text-dim);
    border-bottom: 1px solid var(--border);
  }
  .main-nav a:last-child { border-bottom: none; }
  .main-nav a:hover { color: var(--yellow); }

  /* 首屏 */
  .hero {
    position: relative;
    padding: 40px 0 50px;
    background: radial-gradient(ellipse at top, rgba(229,9,20,0.18), transparent 60%);
    overflow: hidden;
  }
  .hero-inner { display: flex; flex-direction: column; gap: 24px; }
  .hero-text h1 {
    font-size: 28px; line-height: 1.3; margin-bottom: 14px;
    color: #fff;
  }
  .hero-text h1 span { color: var(--red); }
  .hero-text p { color: var(--text-dim); font-size: 15px; margin-bottom: 22px; }
  .download-btn {
    display: inline-block;
    background: var(--yellow);
    color: #111;
    font-weight: 800;
    font-size: 17px;
    padding: 14px 32px;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(255,215,0,0.3);
    transition: transform .2s, box-shadow .2s;
  }
  .download-btn:hover { transform: translateY(-2px); box-shadow: 0 6px 28px rgba(255,215,0,0.5); }
  .update-time { margin-top: 12px; font-size: 12px; color: var(--text-dim); }
  .hero-visual img { width: 100%; border-radius: 12px; box-shadow: 0 10px 40px rgba(0,0,0,0.8); }

  /* 滚动横幅 */
  .marquee-bar {
    background: var(--red-dark);
    padding: 10px 0;
    overflow: hidden;
    white-space: nowrap;
  }
  .marquee-track {
    display: inline-block;
    animation: marquee 22s linear infinite;
    font-size: 14px;
    font-weight: 600;
    color: #fff;
  }
  .marquee-track span { margin: 0 28px; }
  @keyframes marquee {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
  }

  /* 通用区块 */
  section { padding: 50px 0; }
  .section-title {
    font-size: 22px; margin-bottom: 8px;
    display: flex; align-items: center; gap: 10px;
  }
  .section-title::before {
    content: ''; width: 4px; height: 22px;
    background: var(--red); border-radius: 2px;
  }
  .section-sub { color: var(--text-dim); font-size: 14px; margin-bottom: 26px; }

  /* 轮播 */
  .carousel-wrap { position: relative; overflow: hidden; padding: 20px 0; }
  .carousel-track {
    display: flex;
    gap: 16px;
    transition: transform .5s ease;
    will-change: transform;
  }
  .carousel-card {
    flex: 0 0 78%;
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    box-shadow: 0 8px 30px rgba(0,0,0,0.7);
  }
  .carousel-card img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 3/4; }
  .play-overlay {
    position: absolute; inset: 0;
    display: flex; align-items: center; justify-content: center;
    background: rgba(0,0,0,0.25);
    transition: background .2s;
  }
  .carousel-card:hover .play-overlay,
  .grid-card:hover .play-overlay { background: rgba(0,0,0,0.45); }
  .play-icon {
    width: 52px; height: 52px; border-radius: 50%;
    background: rgba(255,255,255,0.22);
    border: 2px solid rgba(255,255,255,0.85);
    display: flex; align-items: center; justify-content: center;
    backdrop-filter: blur(4px);
  }
  .play-icon::after {
    content: '';
    border-left: 16px solid #fff;
    border-top: 10px solid transparent;
    border-bottom: 10px solid transparent;
    margin-left: 4px;
  }
  .carousel-nav {
    display: flex; justify-content: center; gap: 12px; margin-top: 18px;
  }
  .carousel-nav button {
    width: 40px; height: 40px; border-radius: 50%;
    background: var(--bg-card); border: 1px solid var(--border);
    color: #fff; font-size: 18px; cursor: pointer;
  }
  .carousel-nav button:hover { background: var(--red); border-color: var(--red); }

  /* 剧库网格 */
  .grid-6 {
    display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px;
  }
  .grid-card {
    position: relative; border-radius: 10px; overflow: hidden;
    background: var(--bg-card); cursor: pointer;
  }
  .grid-card img { width: 100%; aspect-ratio: 3/4; object-fit: cover; }
  .grid-card-info {
    padding: 10px 12px;
  }
  .grid-card-info p { font-size: 13px; color: var(--text); line-height: 1.5; }
  .grid-card-info small { color: var(--text-dim); font-size: 12px; }

  /* 优势 */
  .advantage-box {
    background: var(--bg-elev);
    border-left: 4px solid var(--red);
    padding: 24px 22px;
    border-radius: 8px;
    font-size: 15px;
    color: #ddd;
  }

  /* 排行榜 */
  .rank-list { display: flex; flex-direction: column; gap: 12px; }
  .rank-item {
    display: flex; align-items: center; gap: 14px;
    background: var(--bg-card); border-radius: 10px;
    padding: 10px; cursor: pointer;
    border: 1px solid transparent;
    transition: border-color .2s;
  }
  .rank-item:hover { border-color: var(--red); }
  .rank-num {
    font-size: 22px; font-weight: 900; width: 34px; text-align: center;
    color: var(--red); flex-shrink: 0; font-style: italic;
  }
  .rank-item img { width: 56px; height: 76px; object-fit: cover; border-radius: 6px; flex-shrink: 0; }
  .rank-info { flex: 1; min-width: 0; }
  .rank-info h4 { font-size: 15px; margin-bottom: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .rank-meta { font-size: 12px; color: var(--text-dim); display: flex; gap: 14px; }
  .rank-meta b { color: var(--yellow); font-weight: 600; }

  /* 弹幕播放器 */
  .danmaku-player {
    position: relative; border-radius: 12px; overflow: hidden;
    background: #000;
  }
  .danmaku-player > img { width: 100%; aspect-ratio: 16/10; object-fit: cover; opacity: 0.85; }
  .danmaku-layer {
    position: absolute; inset: 0; overflow: hidden; pointer-events: none;
  }
  .dm {
    position: absolute; white-space: nowrap;
    font-size: 13px; font-weight: 600;
    color: #fff; text-shadow: 0 1px 3px #000;
    animation: dmMove 9s linear infinite;
  }
  @keyframes dmMove {
    0% { transform: translateX(100vw); }
    100% { transform: translateX(-120%); }
  }

  /* 历程 */
  .history-box p { margin-bottom: 14px; color: #ccc; font-size: 15px; }

  /* FAQ */
  .faq-item {
    border-bottom: 1px solid var(--border);
  }
  .faq-q {
    width: 100%; text-align: left; background: none; border: none;
    color: var(--text); font-size: 15px; font-weight: 600;
    padding: 16px 0; cursor: pointer;
    display: flex; justify-content: space-between; align-items: center; gap: 12px;
  }
  .faq-q::after { content: '+'; color: var(--red); font-size: 20px; }
  .faq-item.open .faq-q::after { content: '−'; }
  .faq-a {
    max-height: 0; overflow: hidden; transition: max-height .3s ease;
    color: var(--text-dim); font-size: 14px;
  }
  .faq-item.open .faq-a { max-height: 300px; }
  .faq-a p { padding-bottom: 16px; }

  /* 评论 */
  .comment-list { display: flex; flex-direction: column; gap: 16px; margin-bottom: 24px; }
  .comment-item {
    display: flex; gap: 12px; background: var(--bg-card);
    padding: 14px; border-radius: 10px;
  }
  .comment-item img { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
  .comment-body h5 { font-size: 14px; color: var(--yellow); margin-bottom: 4px; }
  .comment-body p { font-size: 14px; color: #ccc; }
  .comment-form { display: flex; flex-direction: column; gap: 10px; }
  .comment-form textarea {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: 8px; padding: 12px; color: var(--text);
    font-size: 14px; min-height: 90px; resize: vertical;
    font-family: inherit;
  }
  .comment-form textarea:focus { outline: none; border-color: var(--red); }
  .comment-form button {
    align-self: flex-end; background: var(--red); color: #fff;
    border: none; padding: 10px 26px; border-radius: 6px;
    font-size: 14px; font-weight: 600; cursor: pointer;
  }
  .comment-form button:hover { background: var(--red-dark); }

  /* 弹窗 */
  .modal-mask {
    display: none; position: fixed; inset: 0; z-index: 999;
    background: rgba(0,0,0,0.8);
    align-items: center; justify-content: center; padding: 20px;
  }
  .modal-mask.show { display: flex; }
  .modal-box {
    background: var(--bg-elev); border: 1px solid var(--red);
    border-radius: 12px; padding: 28px 24px; text-align: center;
    max-width: 360px; width: 100%;
  }
  .modal-box h3 { font-size: 18px; margin-bottom: 10px; color: #fff; }
  .modal-box p { font-size: 14px; color: var(--text-dim); margin-bottom: 20px; }
  .modal-box .download-btn { font-size: 15px; padding: 12px 26px; }
  .modal-close {
    margin-top: 14px; background: none; border: none;
    color: var(--text-dim); font-size: 13px; cursor: pointer;
  }

  /* 页脚 */
  .site-footer {
    background: var(--bg-elev); border-top: 1px solid var(--border);
    padding: 30px 0 40px; font-size: 12px; color: #777;
  }
  .site-footer p { margin-bottom: 8px; }
  .site-footer a { color: #888; }
  .site-footer a:hover { color: var(--red); }
  .friend-links { margin-top: 18px; }
  .friend-links details summary {
    cursor: pointer; color: #777; font-size: 12px;
    padding: 6px 0; list-style: none;
  }
  .friend-links details summary::-webkit-details-marker { display: none; }
  .friend-links details summary::before { content: '▸ '; }
  .friend-links details[open] summary::before { content: '▾ '; }
  .friend-links .links-body { margin-top: 8px; display: flex; flex-wrap: wrap; gap: 10px 18px; }

  /* 桌面端 */
  @media (min-width: 768px) {
    .menu-toggle { display: none; }
    .main-nav {
      display: flex !important; flex-direction: row;
      background: none; border: none; padding: 0; gap: 4px;
    }
    .main-nav a {
      padding: 8px 12px; border: none; font-size: 13px;
      border-radius: 4px;
    }
    .main-nav a:hover { background: rgba(229,9,20,0.2); }
    .hero-inner { flex-direction: row; align-items: center; }
    .hero-text { flex: 1; }
    .hero-visual { flex: 1; }
    .hero-text h1 { font-size: 36px; }
    .carousel-card { flex: 0 0 42%; }
    .grid-6 { grid-template-columns: repeat(3, 1fr); }
    .rank-list { display: grid; grid-template-columns: repeat(2, 1fr); }
  }
  @media (min-width: 1024px) {
    .hero { padding: 60px 0 70px; }
    .hero-text h1 { font-size: 46px; }
    .carousel-card { flex: 0 0 30.5%; }
    .grid-6 { grid-template-columns: repeat(3, 1fr); gap: 20px; }
    .rank-list { grid-template-columns: repeat(3, 1fr); }
    section { padding: 70px 0; }
    .section-title { font-size: 26px; }
  }