/* Motchill Theme for maccms10 */

* { margin: 0; padding: 0; box-sizing: border-box; }
html, body { background: #0f1014; color: #d6d6d6; font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif; font-size: 14px; line-height: 1.5; }
a { color: #d6d6d6; text-decoration: none; transition: color .2s; }
a:hover { color: #ff6600; }
img { max-width: 100%; display: block; }
ul, ol { list-style: none; }

:root {
    --bg: #0f1014;
    --bg-2: #1a1c22;
    --bg-3: #23262e;
    --border: #2a2d36;
    --text: #d6d6d6;
    --text-dim: #8a8f9a;
    --accent: #ff6600;
    --accent-2: #ff8533;
    --hot: #e50914;
    --hd: #00b96b;
}

.container { max-width: 1280px; margin: 0 auto; padding: 0 16px; }
.clearfix::after { content: ''; display: block; clear: both; }
.hide { display: none !important; }

/* ===== Header ===== */
.mch-header { position: sticky; top: 0; z-index: 100; background: rgba(15, 16, 20, .96); backdrop-filter: blur(8px); border-bottom: 1px solid var(--border); }
.mch-header-inner { display: flex; align-items: center; height: 64px; gap: 24px; }
.mch-logo { display: flex; align-items: center; gap: 8px; font-size: 24px; font-weight: 800; color: #fff; letter-spacing: -.5px; }
.mch-logo span { color: var(--accent); }
.mch-logo .mch-logo-icon { width: 32px; height: 32px; background: var(--accent); border-radius: 6px; display: flex; align-items: center; justify-content: center; color: #fff; font-size: 18px; }
.mch-nav { display: flex; gap: 4px; flex: 1; }
.mch-nav a { padding: 8px 14px; border-radius: 4px; font-weight: 500; font-size: 14px; }
.mch-nav a:hover, .mch-nav a.active { background: var(--bg-3); color: #fff; }
.mch-search { display: flex; align-items: center; background: var(--bg-2); border: 1px solid var(--border); border-radius: 24px; padding: 0 6px 0 16px; width: 280px; height: 38px; }
.mch-search input { background: transparent; border: 0; outline: 0; flex: 1; color: var(--text); font-size: 13px; }
.mch-search button { background: var(--accent); border: 0; color: #fff; width: 30px; height: 30px; border-radius: 50%; cursor: pointer; font-size: 14px; }
.mch-user { display: flex; align-items: center; gap: 10px; }
.mch-user a { font-size: 13px; padding: 8px 14px; border-radius: 4px; }
.mch-user a.btn-login { background: var(--accent); color: #fff; }
.mch-user a.btn-login:hover { background: var(--accent-2); color: #fff; }

/* ===== Hero/Slider ===== */
.mch-hero { margin: 20px 0; position: relative; }
.mch-slider { position: relative; height: 420px; overflow: hidden; border-radius: 10px; }
.mch-slider-item { position: absolute; inset: 0; background-size: cover; background-position: center; opacity: 0; transition: opacity .6s; }
.mch-slider-item.active { opacity: 1; }
.mch-slider-item::before { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(15,16,20,.95) 0%, rgba(15,16,20,.6) 50%, rgba(15,16,20,.2) 100%); }
.mch-slider-meta { position: absolute; left: 40px; bottom: 40px; max-width: 600px; z-index: 2; }
.mch-slider-meta .badge { display: inline-block; padding: 4px 10px; background: var(--accent); color: #fff; font-size: 12px; font-weight: 600; border-radius: 4px; margin-bottom: 12px; }
.mch-slider-meta h2 { font-size: 36px; color: #fff; margin-bottom: 12px; font-weight: 700; }
.mch-slider-meta .desc { color: #c0c4cc; font-size: 14px; margin-bottom: 20px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.mch-slider-meta .btn-play { display: inline-flex; align-items: center; gap: 8px; padding: 12px 26px; background: var(--accent); color: #fff; border-radius: 6px; font-weight: 600; }
.mch-slider-meta .btn-play:hover { background: var(--accent-2); color: #fff; }
.mch-slider-dots { position: absolute; bottom: 16px; right: 24px; display: flex; gap: 8px; z-index: 3; }
.mch-slider-dots span { width: 8px; height: 8px; border-radius: 50%; background: rgba(255,255,255,.35); cursor: pointer; transition: all .2s; }
.mch-slider-dots span.active { background: var(--accent); width: 24px; border-radius: 4px; }

/* ===== Section ===== */
.mch-section { margin: 32px 0; }
.mch-section-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; padding-bottom: 8px; border-bottom: 1px solid var(--border); }
.mch-section-head h3 { font-size: 18px; color: #fff; font-weight: 700; position: relative; padding-left: 14px; }
.mch-section-head h3::before { content: ''; position: absolute; left: 0; top: 50%; transform: translateY(-50%); width: 4px; height: 18px; background: var(--accent); border-radius: 2px; }
.mch-section-head .more { color: var(--text-dim); font-size: 13px; }
.mch-section-head .more:hover { color: var(--accent); }

/* ===== Card grid ===== */
.mch-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px; }
.mch-grid.col-5 { grid-template-columns: repeat(5, 1fr); }
.mch-grid.col-4 { grid-template-columns: repeat(4, 1fr); }
.mch-card { background: var(--bg-2); border-radius: 6px; overflow: hidden; transition: transform .25s, box-shadow .25s; }
.mch-card:hover { transform: translateY(-4px); box-shadow: 0 10px 24px rgba(0,0,0,.4); }
.mch-card-poster { position: relative; aspect-ratio: 2/3; overflow: hidden; background: #181a20; }
.mch-card-poster img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s; }
.mch-card:hover .mch-card-poster img { transform: scale(1.06); }
.mch-card-badge { position: absolute; top: 8px; left: 8px; padding: 2px 8px; border-radius: 3px; font-size: 11px; font-weight: 600; color: #fff; background: var(--accent); }
.mch-card-badge.hd { background: var(--hd); }
.mch-card-badge.hot { background: var(--hot); }
.mch-card-ep { position: absolute; bottom: 0; left: 0; right: 0; padding: 6px 8px; background: linear-gradient(to top, rgba(0,0,0,.85), transparent); font-size: 12px; color: #fff; font-weight: 500; }
.mch-card-body { padding: 8px 10px 12px; }
.mch-card-body h4 { font-size: 13px; color: #e7e7e7; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-bottom: 4px; }
.mch-card-body .meta { font-size: 11px; color: var(--text-dim); display: flex; gap: 6px; }
.mch-card:hover .mch-card-body h4 { color: var(--accent); }

/* ===== Detail page ===== */
.mch-detail { margin: 24px 0; }
.mch-detail-top { display: flex; gap: 28px; background: var(--bg-2); border-radius: 10px; padding: 24px; position: relative; overflow: hidden; }
.mch-detail-bg { position: absolute; inset: 0; background-size: cover; background-position: center; opacity: .12; filter: blur(20px); z-index: 0; }
.mch-detail-top > * { position: relative; z-index: 1; }
.mch-detail-poster { flex: 0 0 220px; aspect-ratio: 2/3; border-radius: 8px; overflow: hidden; box-shadow: 0 8px 24px rgba(0,0,0,.5); }
.mch-detail-poster img { width: 100%; height: 100%; object-fit: cover; }
.mch-detail-info { flex: 1; }
.mch-detail-info h1 { font-size: 28px; color: #fff; margin-bottom: 6px; }
.mch-detail-info .subname { color: var(--text-dim); font-size: 14px; margin-bottom: 14px; }
.mch-detail-info .tags { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.mch-detail-info .tags span { padding: 3px 10px; background: var(--bg-3); border-radius: 12px; font-size: 12px; color: #c5cad3; }
.mch-detail-info .tags span.score { background: var(--accent); color: #fff; font-weight: 600; }
.mch-detail-info .meta-row { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px 24px; margin-bottom: 16px; font-size: 13px; }
.mch-detail-info .meta-row > div { color: var(--text-dim); }
.mch-detail-info .meta-row > div b { color: var(--text); font-weight: 500; }
.mch-detail-info .meta-row a { color: var(--accent); }
.mch-detail-actions { display: flex; gap: 10px; margin-top: 16px; }
.mch-detail-actions a { display: inline-flex; align-items: center; gap: 6px; padding: 10px 22px; border-radius: 6px; font-weight: 600; font-size: 14px; }
.mch-detail-actions .btn-primary { background: var(--accent); color: #fff; }
.mch-detail-actions .btn-primary:hover { background: var(--accent-2); color: #fff; }
.mch-detail-actions .btn-ghost { background: var(--bg-3); color: #fff; }
.mch-detail-actions .btn-ghost:hover { background: var(--border); color: #fff; }

.mch-detail-desc { background: var(--bg-2); border-radius: 10px; padding: 20px 24px; margin-top: 20px; }
.mch-detail-desc h3 { font-size: 16px; color: #fff; margin-bottom: 10px; padding-left: 12px; position: relative; }
.mch-detail-desc h3::before { content: ''; position: absolute; left: 0; top: 4px; bottom: 4px; width: 3px; background: var(--accent); border-radius: 2px; }
.mch-detail-desc p { color: #c0c4cc; font-size: 14px; line-height: 1.7; }

/* Episodes/Playlist */
.mch-playlist { background: var(--bg-2); border-radius: 10px; margin-top: 20px; }
.mch-playlist-tabs { display: flex; gap: 4px; padding: 16px 24px 0; border-bottom: 1px solid var(--border); overflow-x: auto; }
.mch-playlist-tabs .tab { padding: 10px 16px; cursor: pointer; color: var(--text-dim); font-size: 13px; border-bottom: 2px solid transparent; white-space: nowrap; }
.mch-playlist-tabs .tab.active { color: var(--accent); border-bottom-color: var(--accent); }
.mch-playlist-body { padding: 20px 24px; }
.mch-eps { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 10px; }
.mch-eps a { padding: 10px 8px; background: var(--bg-3); color: #d6d6d6; text-align: center; border-radius: 4px; font-size: 13px; transition: all .2s; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mch-eps a:hover, .mch-eps a.active { background: var(--accent); color: #fff; }
.mch-pane { display: none; }
.mch-pane.active { display: block; }

/* Sidebar */
.mch-layout { display: grid; grid-template-columns: 1fr 320px; gap: 24px; margin-top: 24px; }
.mch-sidebar { display: flex; flex-direction: column; gap: 20px; }
.mch-side-box { background: var(--bg-2); border-radius: 10px; padding: 16px 18px; }
.mch-side-box h3 { font-size: 15px; color: #fff; margin-bottom: 12px; padding-left: 12px; position: relative; font-weight: 600; }
.mch-side-box h3::before { content: ''; position: absolute; left: 0; top: 3px; bottom: 3px; width: 3px; background: var(--accent); border-radius: 2px; }
.mch-rank-list { display: flex; flex-direction: column; gap: 10px; }
.mch-rank-item { display: flex; gap: 10px; align-items: center; }
.mch-rank-item .rank-num { flex: 0 0 24px; width: 24px; height: 24px; display: flex; align-items: center; justify-content: center; background: var(--bg-3); color: var(--text-dim); font-weight: 700; font-size: 12px; border-radius: 4px; }
.mch-rank-item:nth-child(1) .rank-num { background: var(--hot); color: #fff; }
.mch-rank-item:nth-child(2) .rank-num { background: var(--accent); color: #fff; }
.mch-rank-item:nth-child(3) .rank-num { background: var(--accent-2); color: #fff; }
.mch-rank-item .rank-info { flex: 1; min-width: 0; }
.mch-rank-item .rank-info h4 { font-size: 13px; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-bottom: 2px; }
.mch-rank-item .rank-info p { font-size: 11px; color: var(--text-dim); }
.mch-rank-item:hover .rank-info h4 { color: var(--accent); }

/* ===== Filter (type page) ===== */
.mch-filter { background: var(--bg-2); border-radius: 10px; padding: 6px 20px; margin: 20px 0; }
.mch-filter-row { display: flex; padding: 10px 0; border-bottom: 1px dashed var(--border); align-items: flex-start; }
.mch-filter-row:last-child { border-bottom: 0; }
.mch-filter-row .label { flex: 0 0 70px; color: var(--text-dim); font-size: 13px; padding-top: 4px; }
.mch-filter-row .items { flex: 1; display: flex; flex-wrap: wrap; gap: 4px; }
.mch-filter-row .items a { padding: 4px 12px; border-radius: 14px; font-size: 13px; color: #d6d6d6; }
.mch-filter-row .items a:hover { color: var(--accent); }
.mch-filter-row .items a.active { background: var(--accent); color: #fff; }

/* ===== Pagination ===== */
.mch-page { display: flex; justify-content: center; gap: 6px; margin: 30px 0; flex-wrap: wrap; }
.mch-page a, .mch-page span { padding: 8px 14px; background: var(--bg-2); border-radius: 4px; font-size: 13px; color: var(--text); }
.mch-page a:hover { background: var(--bg-3); color: var(--accent); }
.mch-page .current, .mch-page .active { background: var(--accent); color: #fff; }

/* ===== Player page ===== */
.mch-player-wrap { background: #000; border-radius: 10px; overflow: hidden; aspect-ratio: 16/9; margin: 16px 0; }
.mch-player-wrap iframe { width: 100%; height: 100%; border: 0; }
.mch-player-bar { background: var(--bg-2); border-radius: 8px; padding: 12px 18px; display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.mch-player-bar h1 { font-size: 18px; color: #fff; }
.mch-player-bar .meta { color: var(--text-dim); font-size: 13px; }

/* ===== Footer ===== */
.mch-footer { margin-top: 60px; padding: 30px 0 20px; background: var(--bg-2); border-top: 1px solid var(--border); text-align: center; color: var(--text-dim); font-size: 13px; }
.mch-footer .links { margin-bottom: 14px; }
.mch-footer .links a { margin: 0 10px; }
.mch-footer .copyright { font-size: 12px; opacity: .7; }

/* ===== Responsive ===== */
@media (max-width: 1024px) {
    .mch-grid { grid-template-columns: repeat(4, 1fr); }
    .mch-grid.col-5, .mch-grid.col-4 { grid-template-columns: repeat(4, 1fr); }
    .mch-layout { grid-template-columns: 1fr; }
    .mch-search { width: 200px; }
}
@media (max-width: 768px) {
    .mch-header-inner { height: auto; flex-wrap: wrap; padding: 10px 0; gap: 10px; }
    .mch-nav { order: 3; flex-basis: 100%; overflow-x: auto; }
    .mch-search { width: 100%; order: 4; }
    .mch-grid { grid-template-columns: repeat(3, 1fr); gap: 10px; }
    .mch-grid.col-5, .mch-grid.col-4 { grid-template-columns: repeat(3, 1fr); }
    .mch-slider { height: 240px; }
    .mch-slider-meta { left: 16px; bottom: 16px; }
    .mch-slider-meta h2 { font-size: 20px; }
    .mch-detail-top { flex-direction: column; }
    .mch-detail-poster { flex: 0 0 auto; width: 160px; margin: 0 auto; }
    .mch-detail-info .meta-row { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
    .mch-grid { grid-template-columns: repeat(2, 1fr); }
    .mch-grid.col-5, .mch-grid.col-4 { grid-template-columns: repeat(2, 1fr); }
}
