/* Chemistry Points palette for the course & account pages
   (courses, course-details, watch-course, my-courses, my-payments).
   The site header on top is partials_chemistry_header.php (css/cp-public-nav.css);
   same navy + gold tokens as css/cp-app-theme.css. */

:root {
    --cp-navy: #0d1b2a;
    --cp-navy-2: #1b263b;
    --cp-steel: #415a77;
    --cp-blue: #778da9;
    --cp-mist: #e0e1dd;
    --cp-muted: #aab9c9;
    --cp-gold: #ffae00;
    --cp-gold-hover: #ffc44d;
    --cp-line: rgba(119,141,169,.26);

    --bg: var(--cp-navy) !important;
    --bg-app: var(--cp-navy) !important;
    --bg-default: var(--cp-navy) !important;
    --surface: rgba(27,38,59,.92) !important;
    --card: var(--cp-navy-2) !important;
    --bg-card: var(--cp-navy-2) !important;
    --border: var(--cp-line) !important;
    --primary: var(--cp-gold) !important;
    --primary-dark: #e09900 !important;
    --primary-glow: rgba(255,174,0,.15) !important;
    --accent: var(--cp-gold) !important;
    --accent2: var(--cp-steel) !important;
    --accent3: var(--cp-blue) !important;
    --accent-soft: rgba(255,174,0,.14) !important;
    --accent-light: rgba(255,174,0,.14) !important;
    --gold: var(--cp-gold) !important;
    --success: #35c96a !important;
    --danger: #ff715b !important;
    --text: var(--cp-mist) !important;
    --ink: var(--cp-mist) !important;
    --text-primary: var(--cp-mist) !important;
    --text-secondary: var(--cp-muted) !important;
    --muted: var(--cp-muted) !important;
    --shadow-sm: 0 6px 22px rgba(0,0,0,.18) !important;
    --shadow-md: 0 16px 42px rgba(0,0,0,.24) !important;
    --shadow-lg: 0 28px 64px rgba(0,0,0,.32) !important;
    --nav-h: 0px !important;
    color-scheme: dark;
}

html, html body {
    background: radial-gradient(circle at 82% -10%, rgba(119,141,169,.22), transparent 32%),
                linear-gradient(135deg, #0d1b2a 0%, #1b263b 58%, #22385a 100%) fixed !important;
    color: var(--cp-mist) !important;
}
html body .mesh, html body .ambient { background: transparent !important; }
html body .mesh::before, html body .mesh::after, html body .orb, html body .grain { display: none !important; }

/* ---------- page buttons under the site header (Logout, Download PDF, ← Course) ---------- */
.cp-page-actions {
    max-width: 1180px; margin: 0 auto; padding: 0 5%;
    display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 10px;
}
.cp-page-actions + .container .wrap, .cp-page-actions + .container .layout { padding-top: 18px !important; }

/* ---------- surfaces ---------- */
html body .glass,
html body .course,
html body .profile,
html body .stat,
html body .table-card,
html body .modal-box,
html body .card {
    background: linear-gradient(145deg, rgba(27,38,59,.96), rgba(19,33,52,.96)) !important;
    border: 1px solid var(--cp-line) !important;
    box-shadow: 0 18px 44px rgba(0,0,0,.22) !important;
    color: var(--cp-mist) !important;
    backdrop-filter: none !important;
}
html body .course:hover { border-color: rgba(255,174,0,.45) !important; }
html body .course::after { background: radial-gradient(120% 60% at 50% 0%, rgba(255,174,0,.08), transparent 60%) !important; }
html body .thumb { background: linear-gradient(135deg, #243b55, #415a77) !important; }
html body .summary {
    background: linear-gradient(125deg, #1b263b, #2b4264 70%, #415a77) !important;
    border: 1px solid rgba(119,141,169,.3) !important; color: #fff !important;
}
html body .summary .big, html body .summary .lbl { color: #fff !important; }
html body .summary .big { color: var(--cp-gold) !important; }
html body .lesson-row, html body .opt, html body .pl-num {
    background: rgba(65,90,119,.18) !important; border-color: var(--cp-line) !important; color: var(--cp-mist) !important;
}
html body .lesson-row:hover, html body .opt:hover { background: rgba(255,174,0,.08) !important; border-color: rgba(255,174,0,.4) !important; }
html body footer { background: rgba(9,19,31,.85) !important; border-top: 1px solid var(--cp-line) !important; color: var(--cp-muted) !important; }
html body .modal, html body .modal-overlay { background: rgba(4,12,22,.72) !important; }

/* ---------- text ---------- */
html body h1, html body h2, html body h3, html body h4,
html body .course h3, html body .course .title, html body .profile-info h1, html body .head h1, html body .sec-h { color: #fff !important; }
html body .hero h1 { color: #fff !important; }
html body .hero h1 .grad, html body .grad {
    background: none !important; color: var(--cp-gold) !important; -webkit-text-fill-color: var(--cp-gold) !important;
}
html body .hero p, html body .muted, html body .meta, html body .sub { color: var(--cp-muted) !important; }
html body .eyebrow {
    background: rgba(255,174,0,.12) !important; border-color: rgba(255,174,0,.35) !important;
    color: var(--cp-gold) !important; box-shadow: none !important;
}
html body .hero .count b, html body .stat .n, html body .sec-h i, html body .float-ic { color: var(--cp-gold) !important; }
html body .float-ic { opacity: .08 !important; }
html body .stat .n.green { color: #35c96a !important; }
html body .price, html body .price.free {
    background: none !important; color: var(--cp-gold) !important; -webkit-text-fill-color: var(--cp-gold) !important;
}

/* ---------- buttons & chips ---------- */
html body .btn:not(.btn-dark):not(.ghost):not(.green):not(.g),
html body .pill.buy, html body .owned, html body .c-watch, html body .btn-full:not(.ghost) {
    background: var(--cp-gold) !important; color: var(--cp-navy) !important;
    border-color: var(--cp-gold) !important; box-shadow: 0 9px 22px rgba(255,174,0,.2) !important;
}
html body .btn:not(.btn-dark):not(.ghost):not(.green):not(.g):hover, html body .pill.buy:hover, html body .c-watch:hover,
html body .btn-full:not(.ghost):hover { background: var(--cp-gold-hover) !important; }
html body .btn-dark, html body .btn.ghost, html body .btn-full.ghost {
    background: rgba(65,90,119,.32) !important; color: var(--cp-mist) !important;
    border: 1px solid rgba(119,141,169,.4) !important; box-shadow: none !important;
}
html body .btn-dark:hover, html body .btn.ghost:hover, html body .btn-full.ghost:hover { border-color: var(--cp-gold) !important; color: var(--cp-gold) !important; }
html body .owned-chip { background: rgba(31,157,87,.92) !important; color: #fff !important; }
html body .tag.lock { background: rgba(65,90,119,.35) !important; color: var(--cp-muted) !important; }

/* ---------- forms & tables ---------- */
html body input:not([type=checkbox]):not([type=radio]):not([type=submit]):not([type=button]),
html body select, html body textarea, html body .inp {
    background: rgba(13,27,42,.78) !important; color: #fff !important; border-color: rgba(119,141,169,.4) !important;
}
html body input::placeholder, html body textarea::placeholder { color: #8294a8 !important; }
html body input:focus, html body select:focus, html body textarea:focus, html body .inp:focus {
    border-color: var(--cp-gold) !important; box-shadow: 0 0 0 3px rgba(255,174,0,.14) !important; outline: none !important;
}
html body input[type=file]::file-selector-button { background: rgba(65,90,119,.45); color: #fff; border: 0; border-radius: 8px; padding: 6px 12px; }
html body table { background: transparent !important; }
html body th { background: rgba(65,90,119,.28) !important; color: #cfd8e3 !important; border-color: var(--cp-line) !important; }
html body td { color: var(--cp-mist) !important; border-color: var(--cp-line) !important; }
html body tbody tr:hover td { background: rgba(255,174,0,.05) !important; }

/* status badges */
html body .b-approved, html body .b-paid, html body .ok, html body .badge-success {
    background: rgba(53,201,106,.14) !important; color: #86e3a9 !important; border-color: rgba(53,201,106,.38) !important;
}
html body .b-pending, html body .warn { background: rgba(255,174,0,.13) !important; color: #ffd27a !important; border-color: rgba(255,174,0,.38) !important; }
html body .b-rejected, html body .err { background: rgba(255,113,91,.14) !important; color: #ffb3a6 !important; border-color: rgba(255,113,91,.4) !important; }

html body * { scrollbar-color: var(--cp-steel) rgba(13,27,42,.5); }

/* watch-course playlist + actions */
html body .pl-item { color: var(--cp-mist) !important; }
html body .pl-item.playable:hover { background: rgba(119,141,169,.12) !important; }
html body .pl-item.active { background: rgba(255,174,0,.12) !important; box-shadow: inset 3px 0 0 var(--cp-gold); }
html body .pl-item.active .pl-num { background: var(--cp-gold) !important; color: var(--cp-navy) !important; }
html body .pl-item.active .pl-title { color: var(--cp-gold) !important; }
html body .tute-btn, html body .btn-lg:not(.green) {
    background: var(--cp-gold) !important; color: var(--cp-navy) !important; box-shadow: 0 10px 24px rgba(255,174,0,.2) !important;
}
html body .btn-lg.green, html body .btn.green, html body .btn.g { background: #1f9d57 !important; color: #fff !important; }
html body .bankbox { background: rgba(65,90,119,.2) !important; border-color: var(--cp-line) !important; color: var(--cp-mist) !important; }
html body .top a { color: var(--cp-gold) !important; }

@media (max-width: 520px) {
    html body .cp-page-actions .btn { padding: 9px 12px !important; font-size: 12px !important; }
    html body .container, html body .wrap { padding-left: 16px !important; padding-right: 16px !important; }
}

/* ---------- course-tutes.php ---------- */
html body .drow, html body .empty {
    background: linear-gradient(145deg, rgba(27,38,59,.96), rgba(19,33,52,.96)) !important;
    border: 1px solid var(--cp-line) !important; color: var(--cp-mist) !important;
}
html body .drow strong { color: #fff; }
html body .sec-title { color: var(--cp-blue) !important; }
html body .mbox {
    background: linear-gradient(145deg, #1b263b, #13213a) !important; color: var(--cp-mist) !important;
    border: 1px solid rgba(119,141,169,.3); box-shadow: 0 28px 70px rgba(0,0,0,.4);
}
html body .fg label { color: var(--cp-muted) !important; }
html body .ov { background: rgba(4,12,22,.72) !important; backdrop-filter: blur(4px); }
html body .alert.success { background: rgba(53,201,106,.14) !important; color: #86e3a9 !important; border-color: rgba(53,201,106,.38) !important; }
html body .alert.error { background: rgba(255,113,91,.14) !important; color: #ffb3a6 !important; border-color: rgba(255,113,91,.4) !important; }
html body .btn[style*="#94a3b8"] {
    background: rgba(65,90,119,.32) !important; color: var(--cp-mist) !important; border: 1px solid rgba(119,141,169,.4) !important; box-shadow: none !important;
}

/* ---------- other public pages (articles, footer pages, course login/register, seminars, quiz) ---------- */
html body .head h1, html body .page-card h1 {
    background: linear-gradient(120deg, #fff 55%, var(--cp-gold)) !important;
    -webkit-background-clip: text !important; background-clip: text !important; -webkit-text-fill-color: transparent !important;
}
html body .note { background: rgba(53,201,106,.12) !important; color: #86e3a9 !important; }
html body .crumb, html body .art-date, html body .meta { color: var(--cp-muted) !important; }
html body .back-btn { color: var(--cp-gold) !important; }
/* stand-alone form cards (course login/register, seminar ticket) sit centred under the header */
html body > .card { margin: 10px auto 48px !important; }
html body .brand img.logo-invert { filter: invert(1); }
