/* ==========================================================================
   Coven Night — portal pages (#/learn, #/blog, #/plans, #/profile, #/admin…)
   in the homepage's palette: ink black, parchment text, candle gold.
   Applies in dark mode (the default); light mode keeps Mystic Classic.
   ========================================================================== */
html[data-theme="dark"] body:not([data-cvx]) {
  color-scheme: dark;
  --bg: #09080c; --bg-2: #100e15; --surface: #14111a; --surface-2: #1a1621; --surface-3: #221d2b;
  --line: rgba(239, 232, 220, .10); --line-2: rgba(239, 232, 220, .18);
  --text: #efe8dc; --muted: rgba(239, 232, 220, .66); --dim: rgba(239, 232, 220, .46);
  --violet: #d8b46a; --violet-2: #b8944f; --violet-soft: rgba(216, 180, 106, .12); --lav: #f0d79c; --indigo: #d8b46a;
  --gold: #d8b46a; --gold-soft: rgba(216, 180, 106, .14);
  --cv-btn: #d8b46a; --cv-btn-hover: #f0d79c;
  --accent: #d8b46a; --accent-soft: rgba(216, 180, 106, .14); --green: #4ade80; --amber: #e0b04a;
  --shadow: none;
  --serif: "Noto Serif Display", "EB Garamond", Georgia, serif;
  background: #09080c; background-image: none;
}
html[data-theme="dark"] body:not([data-cvx]) .sky { display: none; }
html[data-theme="dark"] body:not([data-cvx])::selection { background: rgba(216, 180, 106, .35); }

/* type */
html[data-theme="dark"] body:not([data-cvx]) .h1, html[data-theme="dark"] body:not([data-cvx]) h1 { font-family: var(--serif); font-weight: 300; letter-spacing: -.025em; }
html[data-theme="dark"] body:not([data-cvx]) .h2, html[data-theme="dark"] body:not([data-cvx]) h2, html[data-theme="dark"] body:not([data-cvx]) .serif { font-family: var(--serif); font-weight: 300; letter-spacing: -.02em; }
html[data-theme="dark"] body:not([data-cvx]) .page .h1 { font-size: clamp(2.4rem, 5vw, 3.8rem); line-height: 1.04; }
html[data-theme="dark"] body:not([data-cvx]) .eyebrow { color: var(--gold); letter-spacing: .18em; }
html[data-theme="dark"] body:not([data-cvx]) a.lav, html[data-theme="dark"] body:not([data-cvx]) .lav { color: var(--lav); }

/* nav + footer + tab bar: ink, gold hairline */
html[data-theme="dark"] body:not([data-cvx]) .nav { background: rgba(9, 8, 12, .86); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); box-shadow: inset 0 -1px 0 rgba(239, 232, 220, .10); }
html[data-theme="dark"] body:not([data-cvx]) .nav .logo b, html[data-theme="dark"] body:not([data-cvx]) .nav .logo-mark { color: #d8b46a; }
html[data-theme="dark"] body:not([data-cvx]) .nav-link { color: rgba(239, 232, 220, .66); border-radius: 999px; }
html[data-theme="dark"] body:not([data-cvx]) .nav-link:hover { color: #efe8dc; background: rgba(239, 232, 220, .06); }
html[data-theme="dark"] body:not([data-cvx]) .nav-link.is-active { color: #efe8dc; background: rgba(216, 180, 106, .12); box-shadow: none; }
html[data-theme="dark"] body:not([data-cvx]) .nav .btn:not(.btn-primary):not(.btn-gold) { border-color: rgba(239, 232, 220, .22); }
html[data-theme="dark"] body:not([data-cvx]) .footer { background: #09080c; box-shadow: inset 0 1px 0 rgba(239, 232, 220, .10); color: rgba(239, 232, 220, .5); }
html[data-theme="dark"] body:not([data-cvx]) .footer h5 { color: #efe8dc; }
html[data-theme="dark"] body:not([data-cvx]) .footer a, html[data-theme="dark"] body:not([data-cvx]) .footer .muted { color: rgba(239, 232, 220, .6); }
html[data-theme="dark"] body:not([data-cvx]) .footer a:hover { color: #f0d79c; }
html[data-theme="dark"] body:not([data-cvx]) .tabbar { background: rgba(9, 8, 12, .94); }
html[data-theme="dark"] body:not([data-cvx]) .drawer { background: #100e15; }

/* surfaces */
html[data-theme="dark"] body:not([data-cvx]) .card { background: var(--surface); border-color: var(--line); border-radius: 18px; }
html[data-theme="dark"] body:not([data-cvx]) .card.hover:hover { border-color: rgba(216, 180, 106, .45); transform: translateY(-3px); }
html[data-theme="dark"] body:not([data-cvx]) .modal { border-radius: 22px; }

/* controls */
html[data-theme="dark"] body:not([data-cvx]) .btn { border-radius: 999px; background: rgba(239, 232, 220, .04); border-color: var(--line-2); color: var(--text); }
html[data-theme="dark"] body:not([data-cvx]) .btn:hover { background: rgba(239, 232, 220, .08); border-color: rgba(239, 232, 220, .4); }
html[data-theme="dark"] body:not([data-cvx]) .btn-primary, html[data-theme="dark"] body:not([data-cvx]) .btn-gold { background: #d8b46a; border-color: #d8b46a; color: #140f07; box-shadow: none; }
html[data-theme="dark"] body:not([data-cvx]) .btn-primary:hover, html[data-theme="dark"] body:not([data-cvx]) .btn-gold:hover { background: #f0d79c; border-color: #f0d79c; color: #140f07; }
html[data-theme="dark"] body:not([data-cvx]) .btn-ghost { background: transparent; border-color: transparent; }
html[data-theme="dark"] body:not([data-cvx]) .btn-danger { color: #fca5a5; background: rgba(248, 113, 113, .08); border-color: rgba(248, 113, 113, .35); }
html[data-theme="dark"] body:not([data-cvx]) .btn.is-on { background: rgba(216, 180, 106, .14); border-color: rgba(216, 180, 106, .5); color: #f0d79c; }
html[data-theme="dark"] body:not([data-cvx]) .chip, html[data-theme="dark"] body:not([data-cvx]) .tabs, html[data-theme="dark"] body:not([data-cvx]) .segmented { border-radius: 999px; }
html[data-theme="dark"] body:not([data-cvx]) .tab, html[data-theme="dark"] body:not([data-cvx]) .segmented button { border-radius: 999px; }
html[data-theme="dark"] body:not([data-cvx]) .chip.is-on, html[data-theme="dark"] body:not([data-cvx]) .chip.is-active { background: rgba(216, 180, 106, .14); color: #f0d79c; border-color: rgba(216, 180, 106, .5); }
html[data-theme="dark"] body:not([data-cvx]) .badge { border-radius: 999px; background: rgba(216, 180, 106, .1); color: #f0d79c; border-color: rgba(216, 180, 106, .3); }
html[data-theme="dark"] body:not([data-cvx]) .badge.plain { background: rgba(239, 232, 220, .05); color: var(--muted); border-color: var(--line); }
html[data-theme="dark"] body:not([data-cvx]) .input, html[data-theme="dark"] body:not([data-cvx]) .select, html[data-theme="dark"] body:not([data-cvx]) .textarea { border-radius: 12px; background: #0d0b11; border-color: var(--line-2); }
html[data-theme="dark"] body:not([data-cvx]) .input:focus, html[data-theme="dark"] body:not([data-cvx]) .select:focus, html[data-theme="dark"] body:not([data-cvx]) .textarea:focus { border-color: rgba(216, 180, 106, .7); box-shadow: 0 0 0 4px rgba(216, 180, 106, .14); }
html[data-theme="dark"] body:not([data-cvx]) .progress > i { background: linear-gradient(90deg, #b8944f, #f0d79c); }
html[data-theme="dark"] body:not([data-cvx]) .switch input:checked + span { background: #d8b46a; }
html[data-theme="dark"] body:not([data-cvx]) .av { background: linear-gradient(135deg, #c9b6f0, #6a4fa8); color: #140f07; box-shadow: 0 0 0 2px #09080c; }

/* membership page */
html[data-theme="dark"] body:not([data-cvx]) .plan { border-radius: 22px; padding: 30px; }
html[data-theme="dark"] body:not([data-cvx]) .plan .price { font-family: var(--serif); font-weight: 300; letter-spacing: -.04em; font-size: 3.1rem; }
html[data-theme="dark"] body:not([data-cvx]) .plan.featured { border-color: rgba(216, 180, 106, .45); background: linear-gradient(180deg, rgba(216, 180, 106, .12), rgba(216, 180, 106, 0) 55%), var(--surface); box-shadow: none; }
html[data-theme="dark"] body:not([data-cvx]) .plan li svg.i { color: #d8b46a; }
html[data-theme="dark"] body:not([data-cvx]) .plan-toggle { color: #f0d79c; }
html[data-theme="dark"] body:not([data-cvx]) .plan .ribbon.badge.gold { background: #d8b46a; color: #140f07; border-color: #d8b46a; }

/* portal AdminCP (#/admin) */
html[data-theme="dark"] body[data-area="admin"] .a-side { background: #0d0b11; border-color: var(--line); }
html[data-theme="dark"] body[data-area="admin"] .a-top { background: rgba(9, 8, 12, .86); }
html[data-theme="dark"] body[data-area="admin"] .a-link.is-active { background: rgba(216, 180, 106, .12); color: #f0d79c; box-shadow: inset 3px 0 0 #d8b46a; }
html[data-theme="dark"] body[data-area="admin"] .logo-mark, html[data-theme="dark"] body[data-area="admin"] .logo b { color: #d8b46a; }

/* portal AdminCP tokens (night) */
html[data-theme="dark"] body[data-area="admin"] {
  --bg: #09080c; --bg-2: #0d0b11; --surface: #14111a; --surface-2: #1a1621; --surface-3: #221d2b;
  --line: rgba(239, 232, 220, .10); --line-2: rgba(239, 232, 220, .18); --text: #efe8dc; --muted: rgba(239, 232, 220, .66); --dim: rgba(239, 232, 220, .46);
  --lav: #f0d79c; --violet-soft: rgba(216, 180, 106, .12); --gold: #d8b46a; --gold-soft: rgba(216, 180, 106, .14);
  --card-bg: #14111a; --input-bg: #0d0b11; --border: rgba(239, 232, 220, .12); --accent: #d8b46a; --accent-2: #f0d79c;
  --primary: #d8b46a; --primary-light: rgba(216, 180, 106, .14);
  --cv-side: #0d0b11; --cv-side-text: rgba(239, 232, 220, .78); --cv-side-dim: rgba(239, 232, 220, .46); --cv-primary: #d8b46a; --cv-primary-hover: #f0d79c;
  background: #09080c;
}
html[data-theme="dark"] body[data-area="admin"] .btn-primary, html[data-theme="dark"] body[data-area="admin"] .btn.btn-primary,
html[data-theme="dark"] body[data-area="admin"] .btn-primary:hover, html[data-theme="dark"] body[data-area="admin"] .btn.btn-primary:hover { color: #140f07 !important; }
html[data-theme="dark"] body[data-area="admin"] .a-link.is-active { color: #140f07; }
html[data-theme="dark"] body[data-area="admin"] .a-side .logo b { color: #d8b46a; }
html[data-theme="dark"] body[data-area="admin"] h1, html[data-theme="dark"] body[data-area="admin"] h2 { font-family: var(--serif); font-weight: 300; letter-spacing: -.015em; }
