/* =====================================================================
   Nghe Nhạc Thánh Ca - giao diện mới 2026
   Sáng thanh nhã + chế độ Tối · tự co giãn theo thiết bị
   ===================================================================== */

:root {
    --bg: #FBF8F3;
    --surface: #FFFFFF;
    --surface-2: #F4EFE6;
    --surface-3: #EFE7D8;
    --line: #E9E3D8;
    --line-2: #D8CFBF;
    --text: #1E2433;
    --text-2: #3A4052;
    --muted: #5F6473;
    --primary: #1F3A5F;
    --primary-ink: #FFFFFF;
    --gold: #B5862E;
    --gold-ink: #8A6420;
    --gold-soft: #E3C27A;
    --purple: #4B3478;
    --green: #2F6B4F;
    --green-soft: #E4F0E8;
    --red: #B4413C;
    --shadow: 0 6px 24px rgba(30, 36, 51, .08);
    --radius: 20px;
    --radius-sm: 12px;
    --font: 'Be Vietnam Pro', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
    --serif: 'Lora', Georgia, 'Times New Roman', serif;
    --player-h: 76px;
    --tabbar-h: 0px;
    color-scheme: light;
}

[data-theme="dark"] {
    --bg: #12161F;
    --surface: #1A2030;
    --surface-2: #232A3B;
    --surface-3: #2A3246;
    --line: #2B3346;
    --line-2: #3A4359;
    --text: #F2EEE6;
    --text-2: #D9D4CB;
    --muted: #A3A9B8;
    --primary: #E3C27A;
    --primary-ink: #12161F;
    --gold: #E3C27A;
    --gold-ink: #E8C987;
    --green-soft: #1E3A2D;
    --red: #E8746D;
    --shadow: 0 8px 28px rgba(0, 0, 0, .35);
    color-scheme: dark;
}

/* ---------- Nền tảng ---------- */
.nct [hidden] { display: none !important; }
#timeoutsess { display: none; position: fixed; left: 12px; right: 12px; top: 12px; z-index: 95; background: #fff3cd; color: #5c4400; padding: 10px 14px; border-radius: 12px; box-shadow: var(--shadow); }
html { -webkit-text-size-adjust: 100%; }
body.nct {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font);
    font-size: 15px;
    line-height: 1.55;
    padding-bottom: calc(var(--player-h) + var(--tabbar-h) + env(safe-area-inset-bottom));
}
body.nct.nct-noplayer { padding-bottom: var(--tabbar-h); }
.nct a { color: var(--primary); text-decoration: none; }
.nct a:hover, .nct a:focus { color: var(--gold-ink); text-decoration: none; }
[data-theme="dark"] .nct a { color: var(--gold-soft); }
[data-theme="dark"] .nct a:hover { color: #F2D99A; }
.nct h1, .nct h2, .nct h3, .nct h4 { font-family: var(--serif); color: var(--primary); }
[data-theme="dark"] .nct h1, [data-theme="dark"] .nct h2, [data-theme="dark"] .nct h3 { color: var(--text); }
.nct img { max-width: 100%; }
.nct :focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; border-radius: 6px; }
.sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.nct-skip { position: absolute; left: -9999px; top: 8px; z-index: 100; background: var(--surface); padding: 8px 14px; border-radius: 8px; }
.nct-skip:focus { left: 8px; }
.nct-wrap { max-width: 1280px; margin: 0 auto; padding: 0 24px; box-sizing: border-box; width: 100%; }
.nct-ic { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; vertical-align: middle; }
.nct-nojs { background: #fff3cd; padding: 10px; text-align: center; }

/* ---------- Nút ---------- */
.nct-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 18px; border-radius: 999px; border: 0; font: 600 15px var(--font); cursor: pointer; white-space: nowrap; text-decoration: none !important; transition: background .15s, color .15s, transform .1s; background: var(--surface-2); color: var(--primary); }
.nct-btn:active { transform: scale(.98); }
.nct-btn--primary { background: var(--primary); color: var(--primary-ink) !important; }
.nct-btn--primary:hover { filter: brightness(1.12); color: var(--primary-ink) !important; }
.nct-btn--gold { background: var(--gold-soft); color: #2A1E45 !important; }
.nct-btn--gold:hover { background: #EDD08E; color: #2A1E45 !important; }
.nct-btn--ghost { background: transparent; color: var(--primary) !important; border: 1.5px solid var(--line-2); }
.nct-btn--ghost:hover { background: var(--surface-2); }
.nct-btn--soft { background: var(--surface-2); color: var(--primary) !important; }
.nct-btn--soft:hover { background: var(--surface-3); }
.nct-btn--light { background: rgba(255,255,255,.14); color: #fff !important; border: 1.5px solid rgba(255,255,255,.35); }
.nct-btn--light:hover { background: rgba(255,255,255,.24); color: #fff !important; }
.nct-btn--sm { min-height: 38px; padding: 0 14px; font-size: 14px; }
[data-theme="dark"] .nct-btn--ghost, [data-theme="dark"] .nct-btn--soft { color: var(--text) !important; }
.nct-ibtn { width: 44px; height: 44px; border-radius: 999px; border: 0; background: transparent; color: inherit; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; position: relative; padding: 0; }
.nct-ibtn:hover { background: rgba(127, 127, 127, .12); }
.nct-ibtn[aria-pressed="true"] { color: var(--gold); }
.nct-ibtn--lg .nct-ic { width: 30px; height: 30px; }
.nct-play { width: 52px; height: 52px; background: var(--primary); color: var(--primary-ink); }
.nct-play:hover { background: var(--primary); filter: brightness(1.12); }
.nct-play .nct-ic--pause { display: none; }
.is-playing .nct-play .nct-ic--play { display: none; }
.is-playing .nct-play .nct-ic--pause { display: inline-block; }
.nct-play--xl { width: 76px; height: 76px; background: var(--gold-soft); color: #12161F; }
.nct-play--xl .nct-ic { width: 32px; height: 32px; }
.nct-repeat-one { position: absolute; right: 6px; bottom: 6px; font: 700 9px var(--font); display: none; }
[data-repeat="one"] .nct-repeat-one { display: block; }

/* ---------- Đầu trang ---------- */
.nct-header { background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 40; }
.nct-header__row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; padding-top: 12px; padding-bottom: 10px; }
.nct-logo { display: flex; align-items: center; gap: 12px; }
.nct-logo__mark { width: 46px; height: 46px; border-radius: 14px; background: #1F3A5F; color: #E3C27A; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.nct-logo__mark svg { width: 26px; height: 26px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.nct-logo__text { display: flex; flex-direction: column; line-height: 1.15; }
.nct-logo__name { font: 700 22px var(--serif); color: var(--primary); }
[data-theme="dark"] .nct-logo__name { color: var(--text); }
.nct-logo__sub { font-size: 12.5px; color: var(--muted); }
.nct-search { flex: 1 1 320px; max-width: 620px; display: flex; align-items: center; gap: 10px; background: var(--surface-2); border-radius: 999px; padding: 0 6px 0 18px; min-height: 48px; color: var(--muted); }
.nct-search input[type="search"] { flex: 1; border: 0; background: transparent; font: 15px var(--font); color: var(--text); outline: none; min-width: 0; height: 44px; }
.nct-search input::placeholder { color: var(--muted); }
.nct-header__tools { display: flex; align-items: center; gap: 6px; margin-left: auto; }
.nct-header__tools .nct-ibtn { color: var(--primary); }
[data-theme="dark"] .nct-header__tools .nct-ibtn { color: var(--gold-soft); }
.nct-ic--sun { display: none; }
[data-theme="dark"] .nct-ic--sun { display: inline-block; }
[data-theme="dark"] .nct-ic--moon { display: none; }
.nct-nav { display: flex; gap: 4px; overflow-x: auto; padding-bottom: 8px; scrollbar-width: none; }
.nct-nav::-webkit-scrollbar { display: none; }
.nct-nav a { padding: 9px 14px; border-radius: 999px; font-weight: 500; white-space: nowrap; color: var(--text-2) !important; }
.nct-nav a:hover { background: var(--surface-2); }
.nct-nav a.active { background: var(--primary); color: var(--primary-ink) !important; }
.nct-nav a.is-season { color: #5A3E85 !important; font-weight: 600; }
[data-theme="dark"] .nct-nav a.is-season { color: #C9B4F0 !important; }

/* ---------- Khung nội dung ---------- */
.nct-main { min-height: 50vh; outline: none; }
.nct-crumbs { display: flex; flex-wrap: wrap; gap: 6px 8px; font-size: 14px; color: var(--muted); padding-top: 16px; }
.nct-crumbs a { color: var(--muted) !important; }
.nct-content { padding-top: 22px; padding-bottom: 40px; }
.nct-ad { padding-bottom: 32px; }
.nct-ad:empty { display: none; }
body.is-loading .nct-main { opacity: .55; transition: opacity .2s; }
.nct-loadbar { position: fixed; left: 0; top: 0; height: 3px; background: var(--gold); z-index: 100; width: 0; transition: width .3s; }

/* ---------- Thành phần chung ---------- */
.nct-section { display: flex; flex-direction: column; gap: 16px; margin-bottom: 44px; }
.nct-section__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; }
.nct-section__head > div:first-child { display: flex; flex-direction: column; gap: 2px; }
.nct-h2 { font: 700 26px/1.25 var(--serif); margin: 0; color: var(--primary); }
[data-theme="dark"] .nct-h2 { color: var(--text); }
.nct-sub { font-size: 14px; color: var(--muted); }
.nct-more { font-weight: 600; color: var(--gold-ink) !important; }
.nct-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.nct-eyebrow { font-size: 12.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.nct-pills { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.nct-pill { padding: 8px 14px; border-radius: 999px; border: 0; background: transparent; color: var(--muted); font: 600 14px var(--font); cursor: pointer; min-height: 38px; }
.nct-pill[aria-selected="true"] { background: var(--primary); color: var(--primary-ink); }
.nct-badge { font-size: 11.5px; font-weight: 700; color: var(--green); background: var(--green-soft); padding: 3px 8px; border-radius: 6px; white-space: nowrap; }
[data-theme="dark"] .nct-badge { color: #9FD8B5; }
.nct-thumb { border-radius: 10px; object-fit: cover; background: var(--surface-3); flex-shrink: 0; display: block; }

/* Dòng bài hát */
.nct-tracks { display: flex; flex-direction: column; }
.nct-track { display: flex; align-items: center; gap: 12px; padding: 8px; border-radius: 14px; min-width: 0; }
.nct-track:hover, .nct-track.is-current { background: var(--surface-2); }
.nct-track__rank { width: 28px; text-align: center; font: 700 19px var(--serif); color: var(--muted); flex-shrink: 0; }
.nct-track__rank.is-top { color: var(--gold); }
.nct-track__cover { position: relative; flex-shrink: 0; width: 48px; height: 48px; border: 0; padding: 0; background: none; cursor: pointer; border-radius: 10px; }
.nct-track__cover img { width: 48px; height: 48px; }
.nct-track__cover::after { content: ""; position: absolute; inset: 0; border-radius: 10px; background: rgba(18,22,31,.45) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M8 5v14l11-7z' fill='white'/%3E%3C/svg%3E") center/22px no-repeat; opacity: 0; transition: opacity .15s; }
.nct-track:hover .nct-track__cover::after, .nct-track__cover:focus-visible::after { opacity: 1; }
.nct-track__info { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.nct-track__title { font-weight: 600; color: var(--text) !important; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nct-track__meta { font-size: 13.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nct-track__meta a { color: var(--muted) !important; }
.nct-track__extra { font-size: 12.5px; color: var(--gold-ink); }
.nct-track__views { font-size: 13px; color: var(--muted); white-space: nowrap; }
.nct-track .nct-ibtn { color: var(--muted); width: 40px; height: 40px; }
.nct-track .nct-ibtn.is-play { color: var(--primary); }
[data-theme="dark"] .nct-track .nct-ibtn.is-play { color: var(--gold-soft); }

.nct-tilegrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(232px, 1fr)); gap: 4px 14px; }
.nct-tilegrid .nct-track__cover, .nct-tilegrid .nct-track__cover img { width: 64px; height: 64px; }
.nct-tilegrid .nct-rankbox { width: 64px; height: 64px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font: 700 24px var(--serif); color: #fff; flex-shrink: 0; position: relative; overflow: hidden; }
.nct-tilegrid .nct-rankbox img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .35; }
.nct-tilegrid .nct-rankbox span { position: relative; text-shadow: 0 1px 4px rgba(0,0,0,.5); }

/* ---------- Ô "Hôm nay" ---------- */
.nct-today { display: flex; flex-wrap: wrap; gap: 24px; margin-bottom: 44px; }
.nct-hero { flex: 999 1 600px; min-width: 0; color: #fff; border-radius: 24px; padding: 30px 34px; display: flex; flex-direction: column; gap: 16px; background: var(--lit, #24543F); position: relative; overflow: hidden; }
.nct-hero a { color: #E3C27A !important; }
.nct-hero__top { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; }
.nct-hero__eyebrow { color: #E3C27A; }
.nct-hero__chip { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; padding: 4px 10px; border-radius: 999px; background: rgba(255,255,255,.14); }
.nct-hero__chip i { width: 10px; height: 10px; border-radius: 999px; background: var(--lit-dot, #7FC79A); display: inline-block; }
.nct-hero__auto { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: rgba(255,255,255,.78); margin-left: auto; }
.nct-hero__title { margin: 0; font: 700 38px/1.15 var(--serif); color: #fff !important; }
.nct-hero__memorial { margin: -8px 0 0; font-size: 16px; color: rgba(255,255,255,.85); }
.nct-hero__readings { display: flex; flex-wrap: wrap; gap: 4px 18px; font-size: 15px; color: rgba(255,255,255,.85); }
.nct-hero__readings b { color: #fff; font-weight: 600; }
.nct-hero__album { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 16px; background: rgba(255,255,255,.1); border-radius: 18px; padding: 14px; }
.nct-hero__album img { width: 84px; height: 84px; border-radius: 14px; object-fit: cover; flex-shrink: 0; }
.nct-hero__album-info { flex: 1 1 240px; display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.nct-hero__album-info strong { font: 700 21px var(--serif); color: #fff; }
.nct-hero__album-info span { font-size: 14px; color: rgba(255,255,255,.8); }
.nct-hero__chips { display: flex; flex-wrap: wrap; gap: 10px; }
.nct-hero__chips > .nct-chip { display: flex; flex-direction: column; padding: 10px 14px; border-radius: 14px; background: rgba(255,255,255,.12); min-width: 160px; color: #fff !important; }
.nct-hero__chips > .nct-chip:first-child { background: rgba(0,0,0,.18); }
.nct-hero__chips small { font-size: 12.5px; color: #E3C27A; font-weight: 600; }
.nct-hero__chips span { font-weight: 600; }
.nct .nct-verse { margin: auto 0 0 !important; padding: 22px 24px 18px; border-radius: 18px; background: rgba(0,0,0,.2); display: flex; flex-direction: column; gap: 10px; position: relative; }
.nct-verse::before { content: "\201C"; position: absolute; left: 18px; top: -6px; font: 700 72px/1 var(--serif); color: rgba(227,194,122,.45); }
.nct-verse .nct-eyebrow { color: #E3C27A; padding-left: 40px; }
.nct-verse blockquote { margin: 0; padding: 0; border: 0; font: italic 600 25px/1.45 var(--serif); color: #fff; }
.nct-verse figcaption { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; font-size: 14.5px; color: rgba(255,255,255,.82); }
.nct-verse figcaption b { color: #fff; }
.nct-verse__song { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; background: none; border: 0; color: #E3C27A; cursor: pointer; padding: 0; font: 600 14.5px var(--font); text-align: left; }
.nct-side { flex: 1 1 340px; display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.nct-mass { padding: 22px; display: flex; flex-direction: column; gap: 8px; }
.nct-mass__title { font: 700 20px/1.3 var(--serif); color: var(--primary); margin: 0; }
[data-theme="dark"] .nct-mass__title { color: var(--text); }
.nct-mass__row { display: flex; align-items: center; gap: 10px; padding: 7px 0; border-top: 1px solid var(--line); }
.nct-mass__part { width: 70px; font-size: 13px; font-weight: 600; color: var(--muted); flex-shrink: 0; }
.nct-mass__missing { color: var(--red); font-weight: 600; font-size: 14px; }
.nct-month { padding: 16px 18px; display: flex; align-items: center; gap: 14px; }
.nct-month img { width: 60px; height: 60px; border-radius: 12px; object-fit: cover; }
.nct-month > div { flex: 1; min-width: 0; display: flex; flex-direction: column; }

/* ---------- Ca sĩ thịnh hành ---------- */
.nct-artists { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 18px; }
.nct-artist { overflow: hidden; display: flex; flex-direction: column; }
.nct-artist__photo { height: 196px; position: relative; display: flex; align-items: center; justify-content: center; background: var(--a-bg, #1F3A5F); overflow: hidden; }
.nct-artist__photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.nct-artist__photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(10,12,18,.78), rgba(10,12,18,0) 60%); }
.nct-artist__ini { font: 700 64px var(--serif); color: rgba(255,255,255,.25); }
.nct-artist__bar { position: absolute; left: 14px; right: 12px; bottom: 12px; z-index: 1; display: flex; align-items: flex-end; justify-content: space-between; gap: 8px; }
.nct-artist__name { display: flex; flex-direction: column; min-width: 0; color: #fff; }
.nct-artist__name a { color: #fff !important; font-weight: 700; font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nct-artist__name small { font-size: 12.5px; color: #E6E9EF; }
.nct-artist__follow { min-height: 34px; padding: 0 12px; border-radius: 999px; border: 1.5px solid rgba(255,255,255,.7); background: transparent; color: #fff; font: 600 13px var(--font); flex-shrink: 0; cursor: pointer; }
.nct-artist__follow[aria-pressed="true"] { background: #fff; color: #1F3A5F; }
.nct-artist .nct-tracks { padding: 6px 8px 8px; }
.nct-artist .nct-track { padding: 6px; gap: 10px; }
.nct-artist .nct-track__rank { width: 16px; font: 700 14px var(--font); color: var(--gold); }
.nct-artist .nct-track__title { font-size: 14px; }
.nct-artist .nct-track__meta { font-size: 12px; }

/* ---------- Album ---------- */
.nct-albums { display: grid; grid-template-columns: repeat(auto-fill, minmax(176px, 1fr)); gap: 22px; }
.nct-album { display: flex; flex-direction: column; gap: 10px; color: var(--text) !important; }
.nct-album__cover { position: relative; aspect-ratio: 1; border-radius: 18px; overflow: hidden; background: var(--surface-3); }
.nct-album__cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.nct-album__play { position: absolute; right: 12px; bottom: 12px; width: 46px; height: 46px; border-radius: 999px; border: 0; background: #fff; color: #1F3A5F; display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 14px rgba(0,0,0,.2); cursor: pointer; opacity: .95; }
.nct-album__play:hover { transform: scale(1.06); }
.nct-album__title { font-weight: 600; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; color: var(--text) !important; }
.nct-album__sub { font-size: 13.5px; color: var(--muted); margin-top: -4px; }
.nct-two { display: flex; flex-wrap: wrap; gap: 24px; margin-bottom: 44px; }
.nct-two > .nct-card { flex: 1 1 460px; min-width: 0; padding: 22px 14px 14px; display: flex; flex-direction: column; gap: 6px; }
.nct-two .nct-section__head { padding: 0 8px 8px; }
.nct-empty { color: var(--muted); padding: 8px; }

.nct-cats { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.nct-cat { display: flex; align-items: center; gap: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 14px 16px; color: var(--text) !important; }
.nct-cat:hover { border-color: var(--line-2); box-shadow: var(--shadow); }
.nct-cat i { width: 10px; height: 40px; border-radius: 6px; flex-shrink: 0; }
.nct-cat span { display: flex; flex-direction: column; }
.nct-cat b { font-weight: 600; }
.nct-cat small { font-size: 13.5px; color: var(--muted); }

.nct-videos { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 22px; }
.nct-video { display: flex; flex-direction: column; gap: 10px; color: var(--text) !important; }
.nct-video__thumb { aspect-ratio: 16 / 9; border-radius: 16px; overflow: hidden; position: relative; background: #3B3350; display: flex; align-items: center; justify-content: center; }
.nct-video__thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.nct-video__thumb span { position: relative; width: 56px; height: 56px; border-radius: 999px; background: rgba(255,255,255,.92); color: #1F3A5F; display: flex; align-items: center; justify-content: center; }
.nct-video__title { font-weight: 600; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* ---------- Trang bài hát / album ---------- */
.nct-songhead { display: flex; flex-wrap: wrap; gap: 28px; align-items: flex-end; padding: 26px; margin-bottom: 26px; }
.nct-songhead__cover { width: 240px; height: 240px; border-radius: 22px; object-fit: cover; flex-shrink: 0; box-shadow: var(--shadow); background: var(--surface-3); }
.nct-songhead__info { flex: 1 1 420px; min-width: 0; display: flex; flex-direction: column; gap: 12px; }
.nct-songhead__info .nct-eyebrow { color: var(--gold-ink); }
.nct-songhead h1 { margin: 0; font: 700 42px/1.12 var(--serif); }
.nct-songhead__meta { display: flex; flex-wrap: wrap; gap: 4px 20px; color: var(--muted); }
.nct-songhead__meta a { font-weight: 600; }
.nct-songhead__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.nct-big-play { min-height: 52px; padding: 0 26px; font-size: 16px; }
.nct-layout { display: flex; flex-wrap: wrap; gap: 28px; align-items: flex-start; }
.nct-layout__main { flex: 999 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 26px; }
.nct-layout__side { flex: 1 1 330px; min-width: 0; display: flex; flex-direction: column; gap: 22px; }
.nct-panel { padding: 20px 14px 14px; }
.nct-panel > .nct-h3 { padding: 0 8px 8px; }
.nct-h3 { font: 700 20px var(--serif); color: var(--primary); margin: 0; }
[data-theme="dark"] .nct-h3 { color: var(--text); }
.nct-tabs { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.nct-tabs [role="tablist"] { display: flex; flex-wrap: wrap; gap: 4px; }
.nct-tabpanel { padding: 26px 34px; }
.nct-tabpanel[hidden] { display: none; }
.nct-lyric { font: 500 var(--lyric-size, 20px)/1.8 var(--serif); color: var(--text-2); white-space: normal; word-wrap: break-word; }
.nct-lyric p { margin: 0 0 1em; }
.nct-fontsize { display: flex; align-items: center; gap: 4px; }
.nct-fontsize .nct-ibtn { border: 1px solid var(--line); font: 700 15px var(--font); color: var(--primary); }
.nct-lyric-pdf { width: 100%; height: 720px; border: 0; border-radius: 12px; background: #fff; }
.nct-note { font-size: 13.5px; color: var(--muted); padding: 12px 34px; border-top: 1px solid var(--line); }
.nct-season-ad { background: var(--purple); color: #fff; border-radius: 22px; padding: 22px 24px; display: flex; flex-direction: column; gap: 8px; }
.nct-season-ad strong { font: 700 20px/1.3 var(--serif); }
.nct-season-ad a { color: #E3C27A !important; font-weight: 600; }
.nct-form { display: grid; gap: 10px; }
.nct-form label { font-weight: 600; font-size: 14px; }
.nct-form input, .nct-form textarea, .nct-form select, .nct input.txt-full, .nct textarea.txt-full, .nct select.txt-full { width: 100%; border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; font: 15px var(--font); background: var(--bg); color: var(--text); box-sizing: border-box; }
.nct-albumhead { background: #1F3A5F; color: #fff; border-radius: 26px; padding: 34px; display: flex; flex-wrap: wrap; gap: 30px; align-items: flex-end; margin-bottom: 26px; }
.nct-albumhead img { width: 230px; height: 230px; border-radius: 20px; object-fit: cover; box-shadow: 0 18px 40px rgba(0,0,0,.25); flex-shrink: 0; }
.nct-albumhead h1 { color: #fff !important; margin: 0; font: 700 40px/1.15 var(--serif); }
.nct-albumhead .nct-eyebrow { color: #E3C27A; }
.nct-albumhead__info { flex: 1 1 400px; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.nct-albumhead__meta { color: #DCE3EE; }
.nct-albumhead__meta a { color: #E3C27A !important; }
.nct-tracktable .nct-track { display: grid; grid-template-columns: 34px 48px minmax(0, 2fr) minmax(0, 1.3fr) 100px 88px; align-items: center; }
.nct-tracktable .nct-track__num { text-align: center; color: var(--muted); font-weight: 600; }
.nct-tracktable .nct-track.is-current .nct-track__num { color: var(--gold); }
.nct-tracktable .nct-track__author, .nct-tracktable .nct-track__views { font-size: 14px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nct-tracktable .nct-track__views { text-align: right; }
.nct-tracktable .nct-track__acts { display: flex; justify-content: flex-end; }
.nct-thead { display: grid; grid-template-columns: 34px 48px minmax(0, 2fr) minmax(0, 1.3fr) 100px 88px; gap: 12px; padding: 8px; font-size: 12.5px; font-weight: 700; letter-spacing: .06em; color: var(--muted); border-bottom: 1px solid var(--line); }
.nct-desc { line-height: 1.65; color: var(--text-2); }
.nct-desc img { height: auto; }

/* Bình luận / các khung cũ của module Nhạc (giữ chức năng, đổi kiểu) */
.nct .alboxw, .nct .alwrap { border: 0 !important; background: transparent !important; box-shadow: none !important; }
.nct .alheader { background: transparent !important; border: 0 !important; font: 700 20px var(--serif); color: var(--primary); padding: 0 0 10px !important; height: auto !important; }
.nct .alheader span { background: none !important; padding: 0 !important; color: inherit !important; }
.nct .alcontent { padding: 0 !important; }
.nct .musictable { width: 100%; border-collapse: separate; border-spacing: 0 8px; }
.nct .musictable td { padding: 4px 6px; vertical-align: top; }
.nct .mbutton, .nct input[type="button"].mbutton, .nct input[type="submit"].mbutton { display: inline-flex; align-items: center; min-height: 40px; padding: 0 18px; border-radius: 999px; border: 0; background: var(--primary); color: var(--primary-ink); font: 600 14px var(--font); cursor: pointer; }
.nct .infoerror, .nct .infook, .nct .infoalert, .nct .information { border-radius: 12px; padding: 12px 14px !important; background: var(--surface-2) !important; border: 0 !important; color: var(--text-2); }
.nct .msmall { font-size: 13px; color: var(--muted); }
.nct .mlo-tool, .nct .playlistitem .clicknext { display: none; }

/* Trang danh sách cũ (tìm kiếm, album, playlist...) */
.nct.mod-music .alboxw.mg10, .nct.mod-music .box-border { background: var(--surface) !important; border: 1px solid var(--line) !important; border-radius: var(--radius); padding: 18px; margin-bottom: 20px; }
.nct.mod-music .musicsmalllalbum { border-radius: 10px; object-fit: cover; }
.nct.mod-music #numpage { margin: 20px 0; text-align: center; }
.nct.mod-music #numpage a, .nct.mod-music #numpage b { display: inline-flex; min-width: 40px; height: 40px; align-items: center; justify-content: center; border-radius: 999px; margin: 2px; background: var(--surface-2); color: var(--primary); font-weight: 600; }
.nct.mod-music #numpage b { background: var(--primary); color: var(--primary-ink); }
.nct .pagination > li > a, .nct .pagination > li > span { color: var(--primary); background: var(--surface); border-color: var(--line); }
.nct .pagination > .active > a, .nct .pagination > .active > span { background: var(--primary); border-color: var(--primary); color: var(--primary-ink); }

/* Các module khác (giới thiệu, video, tài khoản...) dùng mẫu NukeViet: chỉnh màu cho hợp */
.nct .panel { background: var(--surface); border-color: var(--line); border-radius: var(--radius-sm); box-shadow: none; }
.nct .panel-heading, .nct .panel-default > .panel-heading { background: var(--surface-2); border-color: var(--line); color: var(--text); }
.nct .well { background: var(--surface-2); border-color: var(--line); }
.nct .table > thead > tr > th, .nct .table > tbody > tr > td { border-color: var(--line); }
.nct .form-control { background: var(--bg); border-color: var(--line); color: var(--text); border-radius: 10px; }
.nct .btn-primary { background: var(--primary); border-color: var(--primary); color: var(--primary-ink); }
[data-theme="dark"] .nct .text-muted { color: var(--muted); }
[data-theme="dark"] .nct .dropdown-menu { background: var(--surface); border-color: var(--line); }

/* ---------- Chân trang ---------- */
.nct-footer { background: #1F3A5F; color: #DCE3EE; }
[data-theme="dark"] .nct-footer { background: #0D1119; }
.nct-footer a { color: #DCE3EE !important; }
.nct-footer a:hover { color: #E3C27A !important; }
.nct-footer__row { display: flex; flex-wrap: wrap; gap: 24px 48px; padding-top: 40px; padding-bottom: 20px; }
.nct-footer__about { flex: 1 1 320px; display: flex; flex-direction: column; gap: 8px; }
.nct-footer__about p { margin: 0; line-height: 1.6; max-width: 460px; }
.nct-footer__about a { color: #E3C27A !important; font-weight: 600; }
.nct-footer__name { font: 700 22px var(--serif); color: #fff; }
.nct-footer__links { display: flex; flex-direction: column; gap: 8px; min-width: 160px; }
.nct-footer__title { font-weight: 700; color: #fff; }
.nct-footer__copy { padding-top: 14px; padding-bottom: 26px; font-size: 13px; color: #9FB0C8; border-top: 1px solid rgba(255,255,255,.1); }

/* ---------- Trình phát cố định ---------- */
.nct-player { position: fixed; left: 0; right: 0; bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom)); z-index: 50; background: var(--surface); border-top: 1px solid var(--line); box-shadow: 0 -6px 24px rgba(30,36,51,.08); }
.nct-player[hidden] { display: none; }
.nct-player__progress { height: 3px; background: var(--line); display: none; }
.nct-player__progress span { display: block; height: 100%; width: 0; background: var(--gold); }
.nct-player__row { display: flex; align-items: center; gap: 10px 22px; min-height: var(--player-h); }
.nct-player__now { flex: 1 1 240px; min-width: 0; display: flex; align-items: center; gap: 12px; border: 0; background: none; padding: 0; text-align: left; cursor: pointer; color: inherit; font: inherit; }
.nct-player__cover { width: 52px; height: 52px; border-radius: 12px; object-fit: cover; background: var(--surface-3); flex-shrink: 0; }
.nct-player__meta { display: flex; flex-direction: column; min-width: 0; }
.nct-player__title { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--text); }
.nct-player__artist { font-size: 13.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nct-player__center { flex: 2 1 380px; display: flex; flex-direction: column; align-items: center; gap: 0; }
.nct-player__controls { display: flex; align-items: center; gap: 6px; color: var(--primary); }
[data-theme="dark"] .nct-player__controls { color: var(--text); }
.nct-player__time { display: flex; align-items: center; gap: 10px; width: 100%; max-width: 560px; font-size: 12.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
.nct-player__right { flex: 1 1 240px; display: flex; align-items: center; justify-content: flex-end; gap: 6px; }
.nct-vol { display: inline-flex; align-items: center; gap: 4px; }
.nct-vol .nct-range { width: 90px; }
.nct-range { -webkit-appearance: none; appearance: none; flex: 1; height: 5px; border-radius: 5px; background: linear-gradient(to right, var(--gold) var(--pct, 0%), var(--line) var(--pct, 0%)); outline: none; cursor: pointer; }
.nct-range::-webkit-slider-thumb { -webkit-appearance: none; width: 14px; height: 14px; border-radius: 999px; background: var(--surface); border: 3px solid var(--gold); }
.nct-range::-moz-range-thumb { width: 10px; height: 10px; border-radius: 999px; background: var(--surface); border: 3px solid var(--gold); }
.nct-player.is-error .nct-player__artist { color: var(--red); }

.nct-queue { position: fixed; right: 16px; bottom: calc(var(--player-h) + var(--tabbar-h) + 12px + env(safe-area-inset-bottom)); width: min(420px, calc(100vw - 32px)); max-height: min(70vh, 640px); z-index: 60; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow); display: flex; flex-direction: column; overflow: hidden; }
.nct-queue[hidden] { display: none; }
.nct-queue__head { display: flex; align-items: center; justify-content: space-between; padding: 12px 12px 12px 18px; border-bottom: 1px solid var(--line); font: 700 18px var(--serif); }
.nct-queue__actions { display: flex; align-items: center; gap: 4px; }
.nct-queue__list { list-style: none; margin: 0; padding: 8px; overflow-y: auto; }
.nct-queue__list li { display: flex; align-items: center; gap: 10px; padding: 6px 8px; border-radius: 12px; cursor: pointer; }
.nct-queue__list li:hover, .nct-queue__list li.is-current { background: var(--surface-2); }
.nct-queue__list li img { width: 40px; height: 40px; border-radius: 8px; object-fit: cover; }
.nct-queue__list li span { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.nct-queue__list li b { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nct-queue__list li small { color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nct-queue__list li.is-current b { color: var(--gold-ink); }

.nct-full { position: fixed; inset: 0; z-index: 70; background: #12161F; color: #F2EEE6; display: flex; flex-direction: column; gap: 16px; padding: calc(12px + env(safe-area-inset-top)) 22px calc(22px + env(safe-area-inset-bottom)); overflow-y: auto; }
.nct-full[hidden] { display: none; }
.nct-full a { color: #E3C27A !important; }
.nct-full__top { display: flex; align-items: center; gap: 8px; margin: 0 -10px; }
.nct-full__from { flex: 1; text-align: center; display: flex; flex-direction: column; min-width: 0; }
.nct-full__from span { font-size: 11.5px; font-weight: 700; letter-spacing: .12em; color: #A3A9B8; }
.nct-full__from strong { font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nct-full__cover { width: min(78vw, 340px); aspect-ratio: 1; object-fit: cover; align-self: center; border-radius: 24px; box-shadow: 0 24px 60px rgba(0,0,0,.45); background: #23365A; margin-top: 8px; }
.nct-full__meta { display: flex; flex-direction: column; gap: 2px; }
.nct-full__title { font: 700 26px var(--serif); color: #F2EEE6 !important; }
.nct-full__artist { color: #A3A9B8; }
.nct-full__time { display: flex; flex-direction: column; gap: 6px; font-size: 12.5px; color: #A3A9B8; }
.nct-full__time > span { display: flex; justify-content: space-between; }
.nct-full__controls { display: flex; align-items: center; justify-content: space-between; color: #F2EEE6; }
.nct-full__actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.nct-full .nct-btn--soft { background: #232A3B; color: #F2EEE6 !important; }
.nct-full .nct-range { background: linear-gradient(to right, #E3C27A var(--pct, 0%), #2B3242 var(--pct, 0%)); }

.nct-tabbar { display: none; }
.nct-toast { position: fixed; left: 50%; bottom: calc(var(--player-h) + var(--tabbar-h) + 24px); transform: translateX(-50%) translateY(20px); background: #1E2433; color: #fff; padding: 10px 18px; border-radius: 999px; font-weight: 600; font-size: 14px; opacity: 0; pointer-events: none; transition: all .25s; z-index: 90; max-width: 90vw; }
.nct-toast.is-show { opacity: 1; transform: translateX(-50%) translateY(0); }
[data-theme="dark"] .nct-toast { background: #F2EEE6; color: #12161F; }

/* ---------- Màn hình nhỏ ---------- */
@media (max-width: 1100px) {
    .nct-artists { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
    .nct-hide-md { display: none !important; }
}
@media (max-width: 900px) {
    .nct-tracktable .nct-track, .nct-thead { grid-template-columns: 30px 44px minmax(0, 1fr) 84px; }
    .nct-tracktable .nct-track__author, .nct-thead .th-author, .nct-tracktable .nct-track__views, .nct-thead .th-views { display: none; }
}
@media (max-width: 760px) {
    :root { --player-h: 64px; --tabbar-h: 62px; }
    body.nct { font-size: 15px; }
    .nct-wrap { padding: 0 14px; }
    .nct-header { position: static; }
    .nct-header__row { gap: 10px; padding-top: 10px; }
    .nct-logo__mark { width: 40px; height: 40px; border-radius: 12px; }
    .nct-logo__name { font-size: 19px; }
    .nct-logo__sub { display: none; }
    .nct-header__tools .nct-btn span { display: none; }
    .nct-header__tools .nct-btn { width: 44px; padding: 0; }
    .nct-search { order: 3; flex-basis: 100%; max-width: none; }
    .nct-content { padding-top: 16px; }
    .nct-h2 { font-size: 22px; }
    .nct-today { gap: 16px; margin-bottom: 30px; }
    .nct-hero { padding: 22px 20px; border-radius: 22px; }
    .nct-hero__title { font-size: 27px !important; }
    .nct-hero__auto { margin-left: 0; }
    .nct-verse blockquote { font-size: 20px; }
    .nct-hero__chips > .nct-chip { min-width: 0; flex: 1 1 140px; }
    .nct-section, .nct-two { margin-bottom: 30px; }
    .nct-tilegrid { grid-template-columns: 1fr; }
    .nct-artists { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 14px; padding-bottom: 6px; margin: 0 -14px; padding-left: 14px; padding-right: 14px; }
    .nct-artist { flex: 0 0 76%; scroll-snap-align: start; }
    .nct-albums { display: flex; overflow-x: auto; gap: 14px; margin: 0 -14px; padding: 0 14px 6px; scroll-snap-type: x mandatory; }
    .nct-album { flex: 0 0 42%; scroll-snap-align: start; }
    .nct-cats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
    .nct-cat { padding: 12px; gap: 10px; }
    .nct-videos { grid-template-columns: 1fr; }
    .nct-songhead { padding: 18px; gap: 18px; }
    .nct-songhead__cover { width: 100%; height: auto; aspect-ratio: 1; max-width: 320px; margin: 0 auto; }
    .nct-songhead h1 { font-size: 30px; }
    .nct-tabpanel { padding: 20px 18px; }
    .nct-note { padding: 12px 18px; }
    .nct-albumhead { padding: 22px; gap: 18px; }
    .nct-albumhead img { width: 100%; height: auto; aspect-ratio: 1; max-width: 300px; margin: 0 auto; }
    .nct-albumhead h1 { font-size: 28px; }
    .nct-hide-sm { display: none !important; }
    .nct-player { border-top: 0; background: transparent; box-shadow: none; padding: 0 8px 6px; }
    .nct-player__row { background: #1F3A5F; color: #fff; border-radius: 16px; padding: 6px 8px; min-height: 58px; gap: 8px; position: relative; overflow: hidden; }
    [data-theme="dark"] .nct-player__row { background: #232A3B; }
    .nct-player__progress { display: block; position: absolute; left: 16px; right: 16px; bottom: 6px; height: 3px; z-index: 2; background: transparent; }
    .nct-player__progress span { background: #E3C27A; }
    .nct-player__cover { width: 44px; height: 44px; }
    .nct-player__title { color: #fff; }
    .nct-player__artist { color: #C9D3E2; }
    .nct-player__center { flex: 0 0 auto; }
    .nct-player__controls { color: #fff; }
    .nct-player .nct-play { width: 44px; height: 44px; background: transparent; color: #fff; }
    .nct-player__right { flex: 0 0 auto; }
    .nct-player__right .nct-btn { display: none; }
    .nct-tabbar { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); position: fixed; left: 0; right: 0; bottom: 0; z-index: 45; background: var(--surface); border-top: 1px solid var(--line); padding: 4px 4px env(safe-area-inset-bottom); height: calc(var(--tabbar-h) + env(safe-area-inset-bottom)); box-sizing: border-box; }
    .nct-tabbar a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; font-size: 11.5px; font-weight: 600; color: var(--muted) !important; }
    .nct-tabbar a.active { color: var(--primary) !important; }
    [data-theme="dark"] .nct-tabbar a.active { color: var(--gold-soft) !important; }
    .nct-queue { right: 8px; left: 8px; width: auto; }
    .nct-mass__part { width: 62px; }
}
@media (prefers-reduced-motion: reduce) {
    * { transition: none !important; scroll-behavior: auto !important; }
}

/* Kết quả tìm kiếm (danh sách bài) */
.nct.mod-music .nct-searchrow { border-bottom: 1px solid var(--line); border-radius: 0; }
.nct.mod-music .nct-searchrow:hover { border-radius: 12px; }
.nct.mod-music .nct-searchrow .nct-track__meta a { color: var(--muted) !important; }
.nct.mod-music .nct-searchrow .nct-track__meta a:hover { color: var(--gold-ink) !important; }

/* Điện thoại: rút gọn danh sách dài */
@media (max-width: 760px) {
    .nct-tilegrid > .nct-track:nth-child(n+9) { display: none; }
    .nct-tracktable .nct-track:nth-child(n+40) { display: grid; }
}
