/* =========================================================
   MUSIC FM — GLOBAL PREMIUM DARK MODE
   Single source of truth for dark mode across the site.
   Loads after all page CSS and safely overrides old light styles.
========================================================= */

html[data-theme="dark"]{
    color-scheme:dark;
    --bg:#07111f;
    --surface:#0d1726;
    --surface-2:#111d2d;
    --surface-3:#152238;
    --line:rgba(255,255,255,.09);
    --text:#eef4ff;
    --muted:#a9b8cc;
    --muted-2:#7f91aa;
    --blue:#2f7dff;
    --blue2:#005bea;
    --cyan:#59b0ff;
}

/* BASE */

html[data-theme="dark"] body,
html[data-theme="dark"] body.mf-contact-body,
html[data-theme="dark"] body.mf-social-profile-body,
html[data-theme="dark"] body.mf-user-dashboard-body,
html[data-theme="dark"] body.auth-body{
    background:
        radial-gradient(circle at 82% 8%, rgba(47,125,255,.18), transparent 26%),
        radial-gradient(circle at 18% 22%, rgba(89,176,255,.10), transparent 30%),
        linear-gradient(180deg,#06101c 0%,#091423 45%,#0b1727 100%) !important;
    color:var(--text) !important;
}

/* Keep the live background subtle in dark */
html[data-theme="dark"] body::before,
html[data-theme="dark"] body::after,
html[data-theme="dark"] .live-bg{
    opacity:.22 !important;
}

/* HEADER */

html[data-theme="dark"] .topbar{
    background:
        linear-gradient(180deg,rgba(9,15,27,.97),rgba(7,12,22,.94)) !important;
    color:#fff !important;
    border:1px solid rgba(255,255,255,.06) !important;
    box-shadow:
        0 18px 55px rgba(0,0,0,.45),
        inset 0 1px 0 rgba(255,255,255,.04) !important;
}

html[data-theme="dark"] .topbar a,
html[data-theme="dark"] .topbar i,
html[data-theme="dark"] .nav a{
    color:#eef4ff !important;
}

html[data-theme="dark"] .mf-theme-toggle,
html[data-theme="dark"] [data-theme-toggle]{
    background:linear-gradient(135deg,#2f7dff,#005bea) !important;
    color:#fff !important;
    box-shadow:0 10px 25px rgba(47,125,255,.30) !important;
}

/* TEXT */

html[data-theme="dark"] h1,
html[data-theme="dark"] h2,
html[data-theme="dark"] h3,
html[data-theme="dark"] h4,
html[data-theme="dark"] h5,
html[data-theme="dark"] h6,
html[data-theme="dark"] strong,
html[data-theme="dark"] label{
    color:#f8fbff !important;
}

html[data-theme="dark"] p,
html[data-theme="dark"] small,
html[data-theme="dark"] span,
html[data-theme="dark"] li,
html[data-theme="dark"] .meta,
html[data-theme="dark"] .muted,
html[data-theme="dark"] .text-muted{
    color:var(--muted) !important;
}

html[data-theme="dark"] a{
    color:inherit;
}


html[data-theme="dark"] .tag,
html[data-theme="dark"] .mf-badge{
    background:#147cff !important;
    color:#fff !important;
}

/* NEWS / CARDS */

html[data-theme="dark"] .card-body,
html[data-theme="dark"] .card-img + .card-body,
html[data-theme="dark"] .news-card,
html[data-theme="dark"] .article-card,
html[data-theme="dark"] .song-card,
html[data-theme="dark"] .dedication-card{
    background:#0f1a2b !important;
    color:#f8fbff !important;
}

html[data-theme="dark"] .card-body h3,
html[data-theme="dark"] .section-head h2,
html[data-theme="dark"] .section-head-user h2{
    color:#fff !important;
}

html[data-theme="dark"] .card-body p{
    color:#b9c8dc !important;
}


html[data-theme="dark"] .dedication-like-btn,
html[data-theme="dark"] .all-dedication-like{
    background:transparent !important;
    border:0 !important;
    box-shadow:none !important;
    color:#ff3b6b !important;
}

html[data-theme="dark"] .dedication-like-btn i,
html[data-theme="dark"] .all-dedication-like i{
    background:transparent !important;
    color:#ff3b6b !important;
}

html[data-theme="dark"] .dedication-like-count{
    background:transparent !important;
    color:#dbe7ff !important;
}

/* FORMS */

html[data-theme="dark"] input,
html[data-theme="dark"] textarea,
html[data-theme="dark"] select{
    background:#0b1624 !important;
    border:1px solid rgba(255,255,255,.10) !important;
    color:#fff !important;
    box-shadow:none !important;
}

html[data-theme="dark"] input::placeholder,
html[data-theme="dark"] textarea::placeholder{
    color:#7f91aa !important;
}


/* RIGHT SIDEBAR / EVENT / FOLLOW */

html[data-theme="dark"] .follow-row,
html[data-theme="dark"] .trend,
html[data-theme="dark"] .chart-row{
    border-color:rgba(255,255,255,.08) !important;
}

html[data-theme="dark"] .event h2{
    color:#fff !important;
    -webkit-text-fill-color:#fff !important;
    text-shadow:0 10px 30px rgba(0,0,0,.55) !important;
}

html[data-theme="dark"] .follow-row:hover,
html[data-theme="dark"] .trend:hover,
html[data-theme="dark"] .chart-row:hover{
    background:rgba(47,125,255,.10) !important;
}

/* NEXT USER */

html[data-theme="dark"] .next-user-strip{
    background:linear-gradient(180deg,#101b2c,#0b1422) !important;
}

html[data-theme="dark"] .next-user-strip p,
html[data-theme="dark"] .next-user-content p{
    color:#b9c8dc !important;
}

html[data-theme="dark"] .next-user-cup{
    background:#14233a !important;
    color:#3b8cff !important;
}


/* ABOUT PAGE */

html[data-theme="dark"] .mf-about-page,
html[data-theme="dark"] .mf-about-card,
html[data-theme="dark"] .mf-founder-box,
html[data-theme="dark"] .mf-side-card,
html[data-theme="dark"] .mf-about-quote,
html[data-theme="dark"] .mf-side-note{
    background:linear-gradient(180deg,#111c2d,#0b1422) !important;
    border-color:var(--line) !important;
    color:#f8fbff !important;
}

html[data-theme="dark"] .mf-about-content,
html[data-theme="dark"] .mf-about-content p,
html[data-theme="dark"] .mf-about-excerpt{
    color:#dbe7ff !important;
}

/* ARTICLE / CUSTOM PAGE */

html[data-theme="dark"] .article-page,
html[data-theme="dark"] .article-content,
html[data-theme="dark"] .article-card,
html[data-theme="dark"] .custom-page,
html[data-theme="dark"] .page-content,
html[data-theme="dark"] .mf-card{
    background:linear-gradient(180deg,#111c2d,#0b1422) !important;
    border-color:var(--line) !important;
    color:#f8fbff !important;
}


/* PUBLIC PROFILE */

html[data-theme="dark"] .mf-social-profile{
    background:
        radial-gradient(circle at 75% 10%, rgba(47,125,255,.18), transparent 34%),
        radial-gradient(circle at 20% 30%, rgba(89,176,255,.10), transparent 28%),
        #07111f !important;
    color:#f8fbff !important;
    --mf-text:#f8fbff;
    --mf-muted:#b9c8dc;
    --mf-line:rgba(255,255,255,.10);
}


html[data-theme="dark"] .name-row h1,
html[data-theme="dark"] .mf-profile-identity h1,
html[data-theme="dark"] .post-user strong,
html[data-theme="dark"] .info-card h3,
html[data-theme="dark"] .card-head h3{
    color:#fff !important;
}

html[data-theme="dark"] .handle,
html[data-theme="dark"] .profile-meta,
html[data-theme="dark"] .mf-profile-identity p,
html[data-theme="dark"] .post-text,
html[data-theme="dark"] .profile-comment{
    color:#b9c8dc !important;
}

html[data-theme="dark"] .mf-profile-tabs a{
    color:#b9c8dc !important;
}

html[data-theme="dark"] .mf-profile-tabs a.active{
    color:#59b0ff !important;
}

/* AUTH PAGES */

html[data-theme="dark"] .auth-container,
html[data-theme="dark"] .auth-card,
html[data-theme="dark"] .auth-box,
html[data-theme="dark"] .auth-panel,
html[data-theme="dark"] .auth-form{
    background:linear-gradient(180deg,#111c2d,#0b1422) !important;
    border-color:var(--line) !important;
    color:#f8fbff !important;
}

/* PLAYER */

html[data-theme="dark"] .mf-player-shell{
    background:transparent !important;
    box-shadow:none !important;
    border:0 !important;
}

html[data-theme="dark"] .mf-player-card,
html[data-theme="dark"] .mf-mini-toggle,
html[data-theme="dark"] .musicfm-player,
html[data-theme="dark"] .music-player,
html[data-theme="dark"] .player{
    background:linear-gradient(180deg,#101b2c,#0b1422) !important;
    border:1px solid rgba(255,255,255,.12) !important;
    color:#f8fbff !important;
    box-shadow:0 20px 55px rgba(0,0,0,.45) !important;
}

html[data-theme="dark"] .mf-player-card *,
html[data-theme="dark"] .mf-mini-toggle *,
html[data-theme="dark"] .musicfm-player *,
html[data-theme="dark"] .music-player *,
html[data-theme="dark"] .player *{
    color:#f8fbff !important;
}

html[data-theme="dark"] .mf-player-btn,
html[data-theme="dark"] .mf-player-icon-btn,
html[data-theme="dark"] .mf-mini-icon{
    background:#1b2a42 !important;
    color:#ffffff !important;
    border-color:rgba(255,255,255,.10) !important;
}

html[data-theme="dark"] .mf-player-btn.main{
    background:linear-gradient(135deg,#2f7dff,#005bea) !important;
}

/* FOOTER */

html[data-theme="dark"] .site-footer,
html[data-theme="dark"] footer{
    background:
        linear-gradient(180deg,#07111d,#091524) !important;
    color:#cbd5e1 !important;
    border-color:rgba(255,255,255,.06) !important;
}

/* SCROLLBAR */

html[data-theme="dark"] ::-webkit-scrollbar{
    width:10px;
}

html[data-theme="dark"] ::-webkit-scrollbar-track{
    background:#08111c;
}

html[data-theme="dark"] ::-webkit-scrollbar-thumb{
    background:#1d3557;
    border-radius:999px;
}

html[data-theme="dark"] ::-webkit-scrollbar-thumb:hover{
    background:#2c4b77;
}
