:root {
  --bg-color: #0a0c10;
  --surface-color: #14171e;
  --surface-hover: #1c2029;
  --primary-color: #5b8cff;
  --primary-hover: #7aa2ff;
  --accent-color: #e5c07b;
  --text-main: #e0e6ed;
  --text-muted: #8b949e;
  --border-color: #2a313c;
  --radius-md: 8px;
  --radius-lg: 12px;
  --spacing-sm: 12px;
  --spacing-md: 20px;
  --spacing-lg: 40px;
  --font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body { background-color: var(--bg-color); color: var(--text-main); font-family: var(--font-family); line-height: 1.6; overflow-x: hidden; }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: var(--bg-color); }
::-webkit-scrollbar-thumb { background: var(--border-color); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }
a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; object-fit: cover; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 var(--spacing-md); }

/* Progress Bar */
#scroll-progress { position: fixed; top: 0; left: 0; height: 3px; background: var(--primary-color); width: 0%; z-index: 9999; transition: width 0.1s; }

/* Header */
header { position: fixed; top: 0; left: 0; right: 0; height: 64px; background: rgba(10, 12, 16, 0.85); backdrop-filter: blur(10px); border-bottom: 1px solid var(--border-color); z-index: 1000; display: flex; align-items: center; }
.header-inner { display: flex; justify-content: space-between; align-items: center; width: 100%; }
.logo-brand { display: flex; align-items: center; gap: 8px; font-size: 18px; font-weight: 700; }
.logo-brand img { height: 32px; border-radius: 4px; }
.nav-links { display: flex; gap: 24px; font-size: 15px; color: var(--text-muted); }
.nav-links a:hover, .nav-links a.active { color: var(--text-main); }
.header-actions { display: flex; align-items: center; gap: 16px; }
.search-box { background: var(--surface-color); border: 1px solid var(--border-color); border-radius: 20px; padding: 6px 16px; color: var(--text-main); outline: none; font-size: 14px; width: 180px; }
.btn-download { background: var(--primary-color); color: #fff; padding: 8px 16px; border-radius: var(--radius-md); font-size: 14px; font-weight: 500; transition: background 0.2s; }
.btn-download:hover { background: var(--primary-hover); }

/* Section Common */
section { padding: 60px 0; border-bottom: 1px solid var(--border-color); }
section:nth-child(even) { background-color: var(--surface-color); }
.section-header { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 24px; border-bottom: 1px solid var(--border-color); padding-bottom: 12px; }
.section-header h2 { font-size: 24px; font-weight: 600; color: var(--text-main); }
.section-header a { font-size: 14px; color: var(--text-muted); transition: color 0.2s; }
.section-header a:hover { color: var(--primary-color); }

/* Hero */
.hero { padding-top: 100px; display: grid; grid-template-columns: 1fr 1fr; gap: 40px; background: var(--bg-color); border-bottom: 1px solid var(--border-color); }
.hero-left { display: flex; gap: 24px; }
.hero-poster { width: 220px; flex-shrink: 0; border-radius: var(--radius-lg); overflow: hidden; border: 1px solid var(--border-color); }
.hero-poster img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 2/3; }
.hero-info { display: flex; flex-direction: column; justify-content: center; }
.hero-info h1 { font-size: 32px; margin-bottom: 12px; line-height: 1.2; }
.hero-tags { display: flex; gap: 8px; margin-bottom: 16px; }
.tag { background: rgba(91, 140, 255, 0.15); color: var(--primary-color); padding: 4px 10px; border-radius: 4px; font-size: 12px; }
.hero-meta { font-size: 14px; color: var(--text-muted); margin-bottom: 16px; }
.hero-desc { font-size: 14px; color: var(--text-muted); margin-bottom: 24px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.hero-btns { display: flex; gap: 12px; }
.btn-primary { background: var(--primary-color); color: #fff; padding: 10px 24px; border-radius: var(--radius-md); font-size: 15px; font-weight: 500; display: inline-block; text-align: center; transition: background 0.2s; }
.btn-primary:hover { background: var(--primary-hover); }
.btn-outline { background: transparent; border: 1px solid var(--border-color); color: var(--text-main); padding: 10px 24px; border-radius: var(--radius-md); font-size: 15px; font-weight: 500; display: inline-block; text-align: center; transition: border-color 0.2s; }
.btn-outline:hover { border-color: var(--text-main); }

.hero-right { background: var(--surface-color); border: 1px solid var(--border-color); border-radius: var(--radius-lg); overflow: hidden; display: flex; flex-direction: column; }
.video-placeholder { position: relative; width: 100%; aspect-ratio: 16/9; background: linear-gradient(135deg, #1c2029, #0a0c10); display: flex; align-items: center; justify-content: center; }
.video-placeholder img { width: 100%; height: 100%; object-fit: cover; opacity: 0.6; }
.play-btn { position: absolute; width: 60px; height: 60px; background: rgba(255, 255, 255, 0.2); backdrop-filter: blur(4px); border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; transition: transform 0.2s; }
.play-btn:hover { transform: scale(1.1); background: rgba(255, 255, 255, 0.3); }
.play-btn::after { content: ''; display: block; width: 0; height: 0; border-top: 10px solid transparent; border-bottom: 10px solid transparent; border-left: 16px solid #fff; margin-left: 6px; }
.episode-strip { display: flex; gap: 8px; padding: 12px; overflow-x: auto; scrollbar-width: none; }
.episode-strip::-webkit-scrollbar { display: none; }
.ep-item { flex-shrink: 0; width: 60px; height: 60px; border-radius: var(--radius-md); background: var(--bg-color); border: 1px solid var(--border-color); display: flex; align-items: center; justify-content: center; font-size: 12px; color: var(--text-muted); cursor: pointer; transition: all 0.2s; }
.ep-item:hover, .ep-item.active { border-color: var(--primary-color); color: var(--primary-color); background: rgba(91, 140, 255, 0.1); }
.today-update { border-top: 1px solid var(--border-color); padding: 16px; }
.today-update h3 { font-size: 14px; color: var(--text-muted); margin-bottom: 12px; font-weight: 500; }
.update-list { display: flex; flex-direction: column; gap: 12px; }
.update-item { display: flex; align-items: center; gap: 12px; font-size: 13px; cursor: pointer; }
.update-item img { width: 40px; height: 56px; border-radius: 4px; }
.update-item .info { flex: 1; }
.update-item .info p { color: var(--text-main); margin-bottom: 2px; }
.update-item .info span { color: var(--text-muted); font-size: 12px; }

/* Ranking */
.rank-tabs { display: flex; gap: 24px; margin-bottom: 20px; border-bottom: 1px solid var(--border-color); }
.rank-tab { padding: 12px 0; font-size: 16px; color: var(--text-muted); cursor: pointer; border-bottom: 2px solid transparent; transition: all 0.2s; }
.rank-tab.active { color: var(--primary-color); border-bottom-color: var(--primary-color); }
.rank-list { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.rank-item { display: flex; align-items: center; gap: 16px; padding: 12px; background: var(--surface-color); border: 1px solid var(--border-color); border-radius: var(--radius-md); transition: transform 0.2s; }
.rank-item:hover { transform: translateY(-2px); background: var(--surface-hover); }
.rank-num { font-size: 20px; font-weight: bold; color: var(--text-muted); width: 24px; text-align: center; }
.rank-num.top-1 { color: #f5a623; }
.rank-num.top-2 { color: #c0c0c0; }
.rank-num.top-3 { color: #cd7f32; }
.rank-item img { width: 48px; height: 64px; border-radius: 4px; }
.rank-info h4 { font-size: 15px; margin-bottom: 4px; }
.rank-info .tags { font-size: 12px; color: var(--text-muted); margin-bottom: 4px; }
.rank-info .heat { font-size: 12px; color: var(--accent-color); }

/* Genre */
.genre-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 16px; margin-bottom: 24px; }
.genre-card { background: var(--surface-color); border: 1px solid var(--border-color); border-radius: var(--radius-md); padding: 20px; text-align: center; cursor: pointer; transition: all 0.2s; }
.genre-card:hover { border-color: var(--primary-color); background: rgba(91, 140, 255, 0.05); }
.genre-card h3 { font-size: 16px; margin-bottom: 4px; }
.genre-card span { font-size: 12px; color: var(--text-muted); }
.genre-featured { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; }

/* Calendar */
.calendar-list { display: flex; flex-direction: column; gap: 12px; }
.calendar-item { display: flex; align-items: center; padding: 16px; background: var(--surface-color); border: 1px solid var(--border-color); border-radius: var(--radius-md); gap: 20px; }
.calendar-item img { width: 60px; height: 80px; border-radius: 4px; }
.calendar-info { flex: 1; }
.calendar-info h4 { font-size: 16px; margin-bottom: 4px; }
.calendar-info p { font-size: 14px; color: var(--text-muted); }
.status-tag { background: rgba(91, 140, 255, 0.1); color: var(--primary-color); padding: 4px 12px; border-radius: 20px; font-size: 13px; }

/* Drama Wall */
.wall-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 20px; }
.wall-card { cursor: pointer; }
.wall-card .poster { position: relative; border-radius: var(--radius-lg); overflow: hidden; aspect-ratio: 2/3; margin-bottom: 12px; }
.wall-card .poster img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
.wall-card:hover .poster img { transform: scale(1.05); }
.wall-card .poster .play-icon { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 40px; height: 40px; background: rgba(0, 0, 0, 0.6); border-radius: 50%; display: flex; align-items: center; justify-content: center; opacity: 0; transition: opacity 0.2s; }
.wall-card:hover .poster .play-icon { opacity: 1; }
.wall-card .poster .play-icon::after { content: ''; display: block; width: 0; height: 0; border-top: 6px solid transparent; border-bottom: 6px solid transparent; border-left: 10px solid #fff; margin-left: 3px; }
.wall-card h4 { font-size: 15px; margin-bottom: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wall-card p { font-size: 12px; color: var(--text-muted); }

/* Detail */
.detail-section { display: flex; gap: 40px; background: var(--surface-color); border: 1px solid var(--border-color); border-radius: var(--radius-lg); padding: 32px; }
.detail-poster { width: 260px; flex-shrink: 0; border-radius: var(--radius-md); overflow: hidden; }
.detail-poster img { width: 100%; aspect-ratio: 2/3; object-fit: cover; }
.detail-info { flex: 1; display: flex; flex-direction: column; }
.detail-info h2 { font-size: 28px; margin-bottom: 12px; }
.detail-info .meta { display: flex; gap: 16px; font-size: 14px; color: var(--text-muted); margin-bottom: 16px; }
.stars { color: #f5a623; letter-spacing: 2px; }
.detail-info .desc { font-size: 14px; color: var(--text-muted); margin-bottom: 20px; line-height: 1.8; }
.cast-list { display: flex; gap: 16px; margin-bottom: 24px; }
.cast-item { font-size: 14px; color: var(--text-main); background: var(--bg-color); padding: 6px 12px; border-radius: 4px; }
.episode-selector { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 12px; margin-bottom: 24px; scrollbar-width: none; }
.episode-selector::-webkit-scrollbar { display: none; }
.ep-btn { flex-shrink: 0; width: 44px; height: 44px; border-radius: 4px; background: var(--bg-color); border: 1px solid var(--border-color); color: var(--text-muted); display: flex; align-items: center; justify-content: center; font-size: 14px; cursor: pointer; transition: all 0.2s; }
.ep-btn:hover, .ep-btn.active { border-color: var(--primary-color); color: var(--primary-color); background: rgba(91, 140, 255, 0.1); }

/* Stats */
.stats-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; text-align: center; margin-bottom: 40px; }
.stat-item h3 { font-size: 36px; color: var(--primary-color); font-weight: 700; margin-bottom: 8px; }
.stat-item p { font-size: 14px; color: var(--text-muted); }
.marquee-container { overflow: hidden; white-space: nowrap; border-top: 1px solid var(--border-color); padding-top: 24px; }
.marquee-content { display: inline-block; animation: marquee 20s linear infinite; }
.marquee-content span { margin: 0 40px; font-size: 16px; color: var(--text-muted); font-weight: 600; opacity: 0.5; }
@keyframes marquee { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }

/* Reviews */
.review-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.review-card { background: var(--surface-color); border: 1px solid var(--border-color); border-radius: var(--radius-md); padding: 20px; }
.review-header { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.avatar { width: 40px; height: 40px; border-radius: 50%; background: var(--border-color); display: flex; align-items: center; justify-content: center; color: var(--text-muted); font-size: 12px; }
.review-user h4 { font-size: 14px; }
.review-user .stars { font-size: 12px; }
.review-card p { font-size: 14px; color: var(--text-muted); margin-bottom: 12px; }
.review-likes { font-size: 12px; color: var(--text-muted); }

/* Cast */
.cast-carousel { display: flex; gap: 20px; overflow-x: auto; padding-bottom: 20px; scrollbar-width: none; }
.cast-carousel::-webkit-scrollbar { display: none; }
.cast-card { flex-shrink: 0; width: 200px; background: var(--surface-color); border: 1px solid var(--border-color); border-radius: var(--radius-md); overflow: hidden; transition: transform 0.2s; }
.cast-card:hover { transform: translateY(-4px); }
.cast-card img { width: 100%; aspect-ratio: 4/3; object-fit: cover; }
.cast-card-info { padding: 16px; text-align: center; }
.cast-card-info h3 { font-size: 16px; margin-bottom: 4px; }
.cast-card-info p { font-size: 13px; color: var(--text-muted); }

/* Download App */
.download-section { display: flex; align-items: center; gap: 60px; }
.phone-mockup { width: 260px; height: 520px; background: var(--surface-color); border: 8px solid var(--border-color); border-radius: 36px; overflow: hidden; position: relative; box-shadow: 0 20px 40px rgba(0,0,0,0.5); }
.phone-screen { width: 100%; height: 100%; background: linear-gradient(180deg, #1c2029, #0a0c10); display: flex; flex-direction: column; }
.phone-header { height: 24px; background: #000; border-radius: 0 0 16px 16px; width: 120px; margin: 0 auto; }
.feature-list { flex: 1; display: flex; flex-direction: column; gap: 20px; }
.feature-item { display: flex; align-items: flex-start; gap: 16px; }
.feature-icon { width: 40px; height: 40px; background: rgba(91, 140, 255, 0.1); border-radius: 8px; display: flex; align-items: center; justify-content: center; color: var(--primary-color); font-weight: bold; flex-shrink: 0; }
.feature-text h3 { font-size: 16px; margin-bottom: 4px; }
.feature-text p { font-size: 14px; color: var(--text-muted); }

/* FAQ */
.faq-list { display: flex; flex-direction: column; gap: 12px; max-width: 800px; margin: 0 auto; }
.faq-item { background: var(--surface-color); border: 1px solid var(--border-color); border-radius: var(--radius-md); overflow: hidden; }
.faq-question { padding: 16px 20px; font-size: 16px; font-weight: 500; cursor: pointer; display: flex; justify-content: space-between; align-items: center; }
.faq-question::after { content: '+'; font-size: 20px; color: var(--text-muted); transition: transform 0.3s; }
.faq-item.open .faq-question::after { transform: rotate(45deg); }
.faq-answer { padding: 0 20px; max-height: 0; overflow: hidden; transition: max-height 0.3s, padding 0.3s; font-size: 14px; color: var(--text-muted); }
.faq-item.open .faq-answer { padding: 0 20px 16px; max-height: 200px; }

/* Footer */
footer { padding: 60px 0 20px; background: var(--bg-color); font-size: 14px; color: var(--text-muted); }
.footer-cta { text-align: center; padding: 40px; background: var(--surface-color); border: 1px solid var(--border-color); border-radius: var(--radius-lg); margin-bottom: 40px; }
.footer-cta h2 { font-size: 24px; color: var(--text-main); margin-bottom: 20px; }
.footer-links { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-bottom: 40px; }
.footer-col h4 { font-size: 15px; color: var(--text-main); margin-bottom: 16px; }
.footer-col a { display: block; margin-bottom: 12px; transition: color 0.2s; }
.footer-col a:hover { color: var(--primary-color); }
.footer-bottom { border-top: 1px solid var(--border-color); padding-top: 20px; text-align: center; font-size: 12px; display: flex; flex-direction: column; gap: 8px; }
.footer-bottom a { color: var(--text-muted); }
.footer-bottom a:hover { color: var(--text-main); }

/* Floating Widget */
.floating-btn { position: fixed; bottom: 30px; right: 30px; width: 50px; height: 50px; background: var(--primary-color); border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; box-shadow: 0 4px 12px rgba(0,0,0,0.3); z-index: 1001; transition: transform 0.2s; }
.floating-btn:hover { transform: scale(1.1); }
.floating-btn::after { content: '?'; color: #fff; font-size: 24px; font-weight: bold; }
.feedback-popup { position: fixed; bottom: 90px; right: 30px; width: 300px; background: var(--surface-color); border: 1px solid var(--border-color); border-radius: var(--radius-lg); padding: 20px; box-shadow: 0 10px 30px rgba(0,0,0,0.5); z-index: 1000; transform: scale(0.9); opacity: 0; pointer-events: none; transition: all 0.2s; }
.feedback-popup.show { transform: scale(1); opacity: 1; pointer-events: auto; }
.feedback-popup h3 { font-size: 16px; margin-bottom: 12px; }
.feedback-popup textarea { width: 100%; height: 80px; background: var(--bg-color); border: 1px solid var(--border-color); border-radius: 4px; padding: 8px; color: var(--text-main); resize: none; margin-bottom: 12px; outline: none; font-family: inherit; }
.feedback-popup .btn-primary { width: 100%; padding: 8px; }

/* Animations */
.fade-up { opacity: 0; transform: translateY(20px); transition: opacity 0.6s, transform 0.6s; }
.fade-up.visible { opacity: 1; transform: translateY(0); }

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
  .fade-up { opacity: 1; transform: none; }
}

/* Responsive */
@media (max-width: 1024px) {
  .hero { grid-template-columns: 1fr; }
  .hero-left { flex-direction: column; align-items: center; text-align: center; }
  .hero-poster { width: 100%; max-width: 300px; }
  .hero-btns { justify-content: center; }
  .rank-list { grid-template-columns: 1fr; }
  .wall-grid { grid-template-columns: repeat(3, 1fr); }
  .genre-featured { grid-template-columns: repeat(3, 1fr); }
  .detail-section { flex-direction: column; align-items: center; }
  .detail-poster { width: 100%; max-width: 300px; }
  .detail-info { text-align: center; align-items: center; }
  .cast-list { justify-content: center; }
  .stats-row { grid-template-columns: repeat(2, 1fr); }
  .review-grid { grid-template-columns: 1fr 1fr; }
  .download-section { flex-direction: column; }
  .footer-links { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
  .nav-links, .search-box { display: none; }
  .hero-info h1 { font-size: 24px; }
  .wall-grid { grid-template-columns: repeat(2, 1fr); }
  .genre-featured { grid-template-columns: repeat(2, 1fr); }
  .review-grid { grid-template-columns: 1fr; }
  .stats-row { grid-template-columns: 1fr; }
  .footer-links { grid-template-columns: 1fr; }
  .feedback-popup { width: calc(100% - 60px); left: 30px; }
}