/* ==========================================================================
   Ace Professionals: Courses area (Option C) - cx.css
   Loaded ONLY by pages in /courses/. Never loads css/style.css.
   Every rule is scoped to .cx and every class starts with cx- so nothing
   here can reach the homepage, and nothing on the homepage can reach here.

   Brand values copied from /css/style.css :root (keep in step if they change):
     --charcoal #282828 · --charcoal-soft #3a3a3a · --gold #d1a53c
     --gold-deep #b0862a · --gold-light #e6c877 · --off-white #faf9f6
     --stone #f3f1ec · --border #e4e1da · --ink-70 #55524d · --radius 4px
   ========================================================================== */

/* ---------------------------------------------------------------- tokens */
.cx {
  /* brand (theme-independent) */
  --cx-charcoal: #282828;
  --cx-charcoal-soft: #3a3a3a;
  --cx-gold: #d1a53c;
  --cx-gold-deep: #b0862a;
  --cx-gold-light: #e6c877;
  --cx-radius: 4px;
  --cx-wrap: 1240px;
  --cx-ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --cx-font: "Manrope", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;

  /* light theme (default) */
  --cx-bg: #faf9f6;
  --cx-surface: #ffffff;
  --cx-surface-2: #f3f1ec;
  --cx-line: #e4e1da;
  --cx-text: #282828;
  --cx-text-2: #55524d;
  --cx-text-3: #6b675f;
  --cx-on-gold: #282828;
  --cx-gold-text: #8a6a1f;
  --cx-progress: #d1a53c;
  --cx-head-gold: #b0862a;
  --cx-card-line: rgba(255, 255, 255, 0.06);
  --cx-header-bg: #ffffff;
  --cx-header-shadow: 0 6px 24px rgba(40, 40, 40, 0.08);
  --cx-outline: #282828;
  --cx-outline-hover-text: #ffffff;
  --cx-stage: #1e1e1e;
  --cx-tile-charcoal: #282828;
  --cx-tile-stone: #ece8df;
  --cx-tile-stone-line: #e0dbd0;
  --cx-band: #282828;
  --cx-shadow: 0 1px 2px rgba(40, 40, 40, 0.05), 0 8px 24px rgba(40, 40, 40, 0.05);
  --cx-shadow-md: 0 2px 4px rgba(40, 40, 40, 0.05), 0 18px 48px rgba(40, 40, 40, 0.09);
  color-scheme: light;
}

/* dark theme: device setting, unless the visitor picked light */
@media (prefers-color-scheme: dark) {
  html:not([data-cx-theme="light"]):not([data-theme="light"]) .cx {
    --cx-bg: #141414;
    --cx-surface: #1e1e1e;
    --cx-surface-2: #262626;
    --cx-line: #2e2e2e;
    --cx-text: #ffffff;
    --cx-text-2: #c9c6c0;
    --cx-text-3: #9c9890;
    --cx-on-gold: #141414;
    --cx-gold-text: #e6c877;
    --cx-progress: #e6c877;
  --cx-head-gold: #d1a53c;
  --cx-card-line: rgba(255, 255, 255, 0.14);
    --cx-head-gold: #d1a53c;
    --cx-card-line: rgba(255, 255, 255, 0.14);
    --cx-header-bg: #1b1b1b;
    --cx-header-shadow: 0 6px 24px rgba(0, 0, 0, 0.45);
    --cx-outline: rgba(255, 255, 255, 0.6);
    --cx-outline-hover-text: #141414;
    --cx-stage: #1e1e1e;
    --cx-tile-charcoal: #262626;
    --cx-tile-stone: #ece8df;
    --cx-tile-stone-line: #ece8df;
    --cx-band: #1e1e1e;
    --cx-shadow: none;
    --cx-shadow-md: 0 18px 48px rgba(0, 0, 0, 0.5);
    color-scheme: dark;
  }
}
/* dark theme: picked with the toggle (or set by the viewer) */
html[data-cx-theme="dark"] .cx,
html[data-theme="dark"]:not([data-cx-theme="light"]) .cx {
  --cx-bg: #141414;
  --cx-surface: #1e1e1e;
  --cx-surface-2: #262626;
  --cx-line: #2e2e2e;
  --cx-text: #ffffff;
  --cx-text-2: #c9c6c0;
  --cx-text-3: #9c9890;
  --cx-on-gold: #141414;
  --cx-gold-text: #e6c877;
  --cx-progress: #e6c877;
  --cx-header-bg: #1b1b1b;
  --cx-header-shadow: 0 6px 24px rgba(0, 0, 0, 0.45);
  --cx-outline: rgba(255, 255, 255, 0.6);
  --cx-outline-hover-text: #141414;
  --cx-stage: #1e1e1e;
  --cx-tile-charcoal: #262626;
  --cx-tile-stone: #ece8df;
  --cx-tile-stone-line: #ece8df;
  --cx-band: #1e1e1e;
  --cx-shadow: none;
  --cx-shadow-md: 0 18px 48px rgba(0, 0, 0, 0.5);
  color-scheme: dark;
}

/* ------------------------------------------------------------------ base */
.cx {
  margin: 0;
  font-family: var(--cx-font);
  font-size: 17px;
  line-height: 1.65;
  color: var(--cx-text);
  background: var(--cx-bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  transition: background-color 0.25s var(--cx-ease), color 0.25s var(--cx-ease);
}
.cx *, .cx *::before, .cx *::after { box-sizing: border-box; }
.cx img, .cx svg { max-width: 100%; }
.cx a { color: inherit; }
.cx h1, .cx h2, .cx h3 { text-wrap: balance; }
.cx :where(a, button, [tabindex]):focus-visible {
  outline: 2px solid var(--cx-gold-text);
  outline-offset: 3px;
  border-radius: 2px;
}
.cx .cx-sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.cx .cx-wrap {
  width: 100%;
  max-width: var(--cx-wrap);
  margin: 0 auto;
  padding: 0 24px;
}
.cx .cx-skip {
  position: absolute; left: 16px; top: -60px; z-index: 200;
  background: var(--cx-charcoal); color: #fff; padding: 12px 18px;
  border-radius: var(--cx-radius); font-weight: 700; text-decoration: none;
  transition: top 0.2s var(--cx-ease);
}
.cx .cx-skip:focus { top: 12px; }
.cx .cx-eyebrow {
  margin: 0;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--cx-gold-text);
  line-height: 1.4;
}

/* --------------------------------------------- buttons (match homepage .btn) */
.cx .cx-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 50px;
  padding: 13px 26px;
  border-radius: var(--cx-radius);
  border: 1.5px solid transparent;
  font: inherit;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.25s var(--cx-ease), color 0.25s var(--cx-ease),
    border-color 0.25s var(--cx-ease), transform 0.25s var(--cx-ease), box-shadow 0.25s var(--cx-ease);
}
.cx .cx-btn:hover { transform: translateY(-2px); }
.cx .cx-btn--gold {
  background: var(--cx-gold);
  color: var(--cx-on-gold);
  box-shadow: 0 8px 22px rgba(176, 134, 42, 0.24);
}
.cx .cx-btn--gold:hover { background: var(--cx-gold-deep); color: #fff; }
.cx .cx-btn--outline { border-color: var(--cx-outline); color: var(--cx-text); background: transparent; }
.cx .cx-btn--outline:hover { background: var(--cx-text); border-color: var(--cx-text); color: var(--cx-outline-hover-text); }
.cx .cx-btn--outline-light { border-color: rgba(255, 255, 255, 0.55); color: #fff; background: transparent; }
.cx .cx-btn--outline-light:hover { background: #fff; color: var(--cx-charcoal); }
.cx .cx-btn--sm { min-height: 42px; padding: 9px 18px; font-size: 0.86rem; }

/* ------------------------------------- header (same as homepage .header) */
.cx .cx-header {
  position: sticky;
  top: 0;
  z-index: 90;
  background: var(--cx-header-bg);
  border-bottom: 1px solid var(--cx-line);
  transition: box-shadow 0.3s var(--cx-ease), background-color 0.25s var(--cx-ease);
}
.cx .cx-header.is-stuck { box-shadow: var(--cx-header-shadow); }
.cx .cx-header .cx-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 82px;
}
.cx .cx-brand { display: flex; align-items: center; flex: 0 0 auto; border-radius: var(--cx-radius); transition: background-color 0.25s var(--cx-ease); }
.cx .cx-brand img { height: 52px; width: auto; display: block; }
.cx .cx-nav { display: flex; align-items: center; gap: 30px; }
.cx .cx-nav__list {
  display: flex;
  align-items: center;
  gap: 26px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.cx .cx-nav__list a {
  font-size: 0.94rem;
  font-weight: 700;
  text-decoration: none;
  position: relative;
  padding: 6px 0;
  color: var(--cx-text);
}
.cx .cx-nav__list a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 2px;
  background: var(--cx-gold);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.28s var(--cx-ease);
}
.cx .cx-nav__list a:hover::after,
.cx .cx-nav__list a[aria-current="page"]::after { transform: scaleX(1); }
.cx .cx-nav__cta { display: flex; align-items: center; gap: 10px; }
.cx .cx-burger {
  display: none;
  width: 46px; height: 46px;
  border: 1px solid var(--cx-line);
  border-radius: var(--cx-radius);
  background: var(--cx-header-bg);
  cursor: pointer;
  padding: 0;
  position: relative;
}
.cx .cx-burger span,
.cx .cx-burger span::before,
.cx .cx-burger span::after {
  position: absolute;
  left: 50%;
  width: 20px; height: 2px;
  background: var(--cx-text);
  transform: translateX(-50%);
  transition: transform 0.25s var(--cx-ease), opacity 0.2s var(--cx-ease);
}
.cx .cx-burger span { top: 50%; margin-top: -1px; }
.cx .cx-burger span::before { content: ""; top: -6px; }
.cx .cx-burger span::after { content: ""; top: 6px; }
.cx .cx-burger[aria-expanded="true"] span { background: transparent; }
.cx .cx-burger[aria-expanded="true"] span::before { transform: translateX(-50%) translateY(6px) rotate(45deg); }
.cx .cx-burger[aria-expanded="true"] span::after { transform: translateX(-50%) translateY(-6px) rotate(-45deg); }

/* the logo has a dark suit on a transparent background, so in dark mode it sits on
   a white plate, the same way the homepage footer shows it on charcoal */
@media (prefers-color-scheme: dark) {
  html:not([data-cx-theme="light"]):not([data-theme="light"]) .cx .cx-brand { background: #fff; padding: 4px 10px; }
}
html[data-cx-theme="dark"] .cx .cx-brand,
html[data-theme="dark"]:not([data-cx-theme="light"]) .cx .cx-brand { background: #fff; padding: 4px 10px; }

/* ------------------------------------------------- Courses bar (sub-nav) */
.cx .cx-bar { background: var(--cx-surface-2); border-bottom: 1px solid var(--cx-line); transition: background-color 0.25s var(--cx-ease); }
.cx .cx-bar .cx-wrap { display: flex; align-items: center; gap: 12px 20px; min-height: 60px; flex-wrap: wrap; padding-top: 8px; padding-bottom: 8px; }
.cx .cx-bar__title { margin: 0; font-size: 1rem; font-weight: 800; letter-spacing: -0.01em; white-space: nowrap; }
.cx .cx-bar__title span { color: var(--cx-gold-text); font-weight: 700; }
.cx .cx-jump { display: flex; gap: 6px; list-style: none; margin: 0; padding: 0; overflow-x: auto; scrollbar-width: none; flex: 1 1 320px; min-width: 0; }
.cx .cx-jump::-webkit-scrollbar { display: none; }
.cx .cx-jump a {
  display: inline-flex; align-items: center; height: 36px; padding: 0 14px;
  border-radius: 999px; border: 1px solid var(--cx-line); background: var(--cx-surface);
  font-size: 0.82rem; font-weight: 700; text-decoration: none; white-space: nowrap; color: var(--cx-text);
  transition: border-color 0.2s var(--cx-ease);
}
.cx .cx-jump a:hover { border-color: var(--cx-text); }
.cx .cx-theme {
  margin-left: auto;
  display: inline-flex; align-items: center; gap: 8px;
  height: 38px; padding: 0 14px 0 10px;
  border-radius: 999px; border: 1px solid var(--cx-line); background: var(--cx-surface);
  font: inherit; font-size: 0.82rem; font-weight: 700; color: var(--cx-text); cursor: pointer;
  transition: border-color 0.2s var(--cx-ease);
}
.cx .cx-theme:hover { border-color: var(--cx-text); }
.cx .cx-theme svg { width: 18px; height: 18px; flex: 0 0 auto; }
.cx .cx-theme .cx-i-sun { display: none; }
@media (prefers-color-scheme: dark) {
  html:not([data-cx-theme="light"]):not([data-theme="light"]) .cx .cx-theme .cx-i-sun { display: block; }
  html:not([data-cx-theme="light"]):not([data-theme="light"]) .cx .cx-theme .cx-i-moon { display: none; }
}
html[data-cx-theme="dark"] .cx .cx-theme .cx-i-sun,
html[data-theme="dark"]:not([data-cx-theme="light"]) .cx .cx-theme .cx-i-sun { display: block; }
html[data-cx-theme="dark"] .cx .cx-theme .cx-i-moon,
html[data-theme="dark"]:not([data-cx-theme="light"]) .cx .cx-theme .cx-i-moon { display: none; }

/* ------------------------------------------------------- featured hero */
.cx .cx-feature { padding: 48px 0 44px; }
.cx .cx-feature .cx-wrap { display: flex; flex-wrap: wrap-reverse; align-items: center; gap: 40px; }
.cx .cx-feature__info { flex: 1 1 420px; min-width: 0; max-width: 500px; }
.cx .cx-feature__visual { flex: 1.35 1 480px; min-width: 0; }
.cx .cx-feature h1 {
  margin: 12px 0 0;
  font-size: clamp(2.3rem, 4.6vw, 3.5rem);
  line-height: 1.04;
  font-weight: 800;
  letter-spacing: -0.03em;
}
.cx .cx-meta { margin: 16px 0 0; display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 0.86rem; font-weight: 600; color: var(--cx-text-2); padding: 0; list-style: none; }
.cx .cx-meta li + li::before { content: "·"; margin-right: 14px; color: var(--cx-text-3); }
.cx .cx-feature p.cx-lead { margin: 16px 0 0; font-size: 1.04rem; line-height: 1.7; color: var(--cx-text-2); }
.cx .cx-actions { margin-top: 26px; display: flex; flex-wrap: wrap; gap: 12px; }
.cx .cx-stage {
  position: relative; display: block; aspect-ratio: 16 / 9; max-width: 100%;
  background: var(--cx-stage); border-radius: var(--cx-radius); overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08); color: #fff; text-decoration: none;
  box-shadow: var(--cx-shadow-md);
}
.cx .cx-stage .cx-hex { position: absolute; right: -9%; top: -16%; width: 52%; height: auto; opacity: 0.3; }
.cx .cx-stage__label { position: absolute; left: 22px; top: 18px; font-size: 0.7rem; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: rgba(255, 255, 255, 0.62); }
.cx .cx-stage__ring {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  width: 82px; height: 82px; border-radius: 50%; background: var(--cx-gold);
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 8px 22px rgba(176, 134, 42, 0.3);
  transition: transform 0.25s var(--cx-ease);
}
.cx .cx-stage:hover .cx-stage__ring { transform: translate(-50%, -50%) scale(1.06); }
.cx .cx-stage__caption { position: absolute; left: 22px; right: 22px; bottom: 18px; display: flex; flex-direction: column; gap: 2px; }
.cx .cx-stage__caption b { font-size: 1.1rem; line-height: 1.3; }
.cx .cx-stage__caption span { font-size: 0.82rem; color: rgba(255, 255, 255, 0.72); }

/* ---------------------------------------------------------------- rows */
.cx .cx-rows { display: flex; flex-direction: column; gap: 44px; padding: 8px 0 64px; }
.cx .cx-row__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 14px; }
.cx .cx-row__head h2 { margin: 0; font-size: 1.4rem; line-height: 1.25; font-weight: 800; letter-spacing: -0.015em; }
.cx .cx-row__head p { margin: 2px 0 0; font-size: 0.88rem; color: var(--cx-text-3); }
.cx .cx-row__nav { display: flex; gap: 8px; flex: 0 0 auto; }
.cx .cx-row__nav button {
  width: 40px; height: 40px; border-radius: 50%;
  border: 1px solid var(--cx-line); background: var(--cx-surface); color: var(--cx-text);
  display: inline-flex; align-items: center; justify-content: center; cursor: pointer;
  transition: border-color 0.2s var(--cx-ease), opacity 0.2s;
}
.cx .cx-row__nav button:hover:not([disabled]) { border-color: var(--cx-text); }
.cx .cx-row__nav button[disabled] { opacity: 0.35; cursor: default; }
.cx .cx-rail {
  list-style: none; margin: 0; padding: 6px 2px 14px;
  display: flex; gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth;
  scrollbar-width: thin; scrollbar-color: var(--cx-line) transparent;
}
.cx .cx-rail > li { flex: 0 0 min(292px, 78vw); scroll-snap-align: start; }

/* tile */
.cx .cx-tile { display: block; text-decoration: none; color: var(--cx-text); border-radius: var(--cx-radius); }
.cx .cx-tile__box {
  position: relative; display: block; aspect-ratio: 16 / 9; max-width: 100%;
  border-radius: var(--cx-radius); overflow: hidden;
  transition: transform 0.25s var(--cx-ease), box-shadow 0.25s var(--cx-ease);
  box-shadow: var(--cx-shadow);
}
.cx .cx-tile:hover .cx-tile__box { transform: translateY(-3px); box-shadow: var(--cx-shadow-md); }
.cx .cx-tile:focus-visible { outline-offset: 4px; }
.cx .cx-tile .cx-hex { position: absolute; right: -26px; top: -24px; width: 150px; height: auto; opacity: 0.45; }
.cx .cx-tile__tag { position: absolute; left: 14px; top: 12px; font-size: 0.64rem; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; }
.cx .cx-tile__name { position: absolute; left: 14px; right: 14px; bottom: 13px; font-size: 1.1rem; line-height: 1.25; font-weight: 800; letter-spacing: -0.01em; }
.cx .cx-tile__play {
  position: absolute; right: 12px; bottom: 12px; width: 34px; height: 34px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; background: rgba(0, 0, 0, 0.55);
}
.cx .cx-tile__meta { display: flex; justify-content: space-between; gap: 10px; margin-top: 10px; font-size: 0.8rem; font-weight: 600; color: var(--cx-text-2); }
.cx .cx-tile__meta b { color: var(--cx-text); font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; }
.cx .cx-tile--charcoal .cx-tile__box { background: var(--cx-tile-charcoal); color: #fff; }
.cx .cx-tile--charcoal .cx-tile__tag { color: var(--cx-gold-light); }
.cx .cx-tile--gold .cx-tile__box { background: var(--cx-gold); color: #282828; }
.cx .cx-tile--gold .cx-tile__tag { color: #282828; }
.cx .cx-tile--stone .cx-tile__box { background: var(--cx-tile-stone); color: #282828; box-shadow: inset 0 0 0 1px var(--cx-tile-stone-line); }
.cx .cx-tile--stone .cx-tile__tag { color: #7a5d18; }
.cx .cx-tile--preview .cx-tile__name { right: 56px; }

/* ------------------------------------------------------------ team band */
.cx .cx-band { background: var(--cx-band); color: #fff; }
.cx .cx-band .cx-wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px 32px; padding-top: 52px; padding-bottom: 52px; }
.cx .cx-band h2 { margin: 8px 0 0; font-size: clamp(1.5rem, 2.6vw, 2rem); line-height: 1.2; font-weight: 800; letter-spacing: -0.02em; max-width: 24ch; }
.cx .cx-band p { margin: 10px 0 0; color: rgba(255, 255, 255, 0.78); max-width: 56ch; }
.cx .cx-band .cx-eyebrow { color: var(--cx-gold-light); }

/* ------------------------------------- footer (same as homepage .footer) */
.cx .cx-footer {
  background: var(--cx-charcoal);
  color: rgba(255, 255, 255, 0.78);
  padding: clamp(52px, 6vw, 78px) 0 26px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}
.cx .cx-footer__grid { display: grid; grid-template-columns: 1.4fr repeat(3, minmax(0, 1fr)); gap: 40px; }
.cx .cx-footer__logo { display: inline-block; background: #fff; padding: 14px 18px; border-radius: var(--cx-radius); margin-bottom: 20px; }
.cx .cx-footer__logo img { height: 52px; width: auto; display: block; }
.cx .cx-footer h4 { color: #fff; font-size: 0.78rem; letter-spacing: 0.18em; text-transform: uppercase; margin: 0 0 16px; }
.cx .cx-footer p { color: rgba(255, 255, 255, 0.7); font-size: 0.94rem; max-width: 34ch; margin: 0; }
.cx .cx-footer ul { list-style: none; margin: 0; padding: 0; }
.cx .cx-footer li { margin-bottom: 10px; }
.cx .cx-footer li a { font-size: 0.94rem; color: rgba(255, 255, 255, 0.78); text-decoration: none; transition: color 0.2s var(--cx-ease); }
.cx .cx-footer li a:hover { color: var(--cx-gold-light); }
.cx .cx-footer :where(a, button):focus-visible { outline-color: var(--cx-gold-light); }
.cx .cx-footer__bottom {
  margin-top: 46px; padding-top: 22px; border-top: 1px solid rgba(255, 255, 255, 0.14);
  display: flex; flex-wrap: wrap; gap: 10px 24px; justify-content: space-between;
  font-size: 0.86rem; color: rgba(255, 255, 255, 0.6);
}

/* toast (preview only) */
.cx .cx-toast {
  position: fixed; z-index: 120; left: 50%; bottom: calc(20px + env(safe-area-inset-bottom, 0px));
  transform: translateX(-50%); max-width: calc(100vw - 32px);
  background: var(--cx-charcoal); color: #fff; border: 1px solid rgba(255, 255, 255, 0.12);
  padding: 12px 18px; border-radius: var(--cx-radius); font-size: 0.9rem; font-weight: 600;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.3);
}

/* ---------------------------------------------------------- breakpoints
   Same widths as the homepage: 1080, 940, 560 */
@media (max-width: 1080px) {
  .cx .cx-footer__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 940px) {
  .cx .cx-nav__list, .cx .cx-nav__cta { display: none; }
  .cx .cx-burger { display: block; margin-left: auto; }
  .cx .cx-nav:not(.is-open) { position: absolute; }
  .cx .cx-header .cx-wrap { position: relative; }
  .cx .cx-nav.is-open {
    position: absolute; left: 0; right: 0; top: 100%;
    background: var(--cx-header-bg);
    border-bottom: 1px solid var(--cx-line);
    box-shadow: var(--cx-shadow-md);
    padding: 20px 24px 28px;
    flex-direction: column; align-items: stretch; gap: 16px;
  }
  .cx .cx-nav.is-open .cx-nav__list { display: flex; flex-direction: column; align-items: stretch; gap: 4px; }
  .cx .cx-nav.is-open .cx-nav__list a { display: block; padding: 12px 0; border-bottom: 1px solid var(--cx-line); }
  .cx .cx-nav.is-open .cx-nav__list a::after { display: none; }
  .cx .cx-nav.is-open .cx-nav__list a[aria-current="page"] { color: var(--cx-gold-text); }
  .cx .cx-nav.is-open .cx-nav__cta { display: flex; flex-direction: column; align-items: stretch; }
  .cx .cx-row__nav { display: none; }
}
@media (max-width: 560px) {
  .cx { font-size: 16px; }
  .cx .cx-brand img { height: 42px; }
  .cx .cx-footer__grid { grid-template-columns: 1fr; }
  .cx .cx-feature { padding-top: 28px; }
  .cx .cx-actions .cx-btn { flex: 1 1 100%; }
  .cx .cx-theme .cx-theme__word { display: none; }
  .cx .cx-theme { padding: 0 10px; order: 2; }
  .cx .cx-bar__title { order: 1; }
  .cx .cx-bar__title span { display: none; }
  .cx .cx-jump { order: 3; flex-basis: 100%; }
  .cx .cx-stage__caption { display: none; }
  .cx .cx-stage__ring { width: 64px; height: 64px; }
}
@media (prefers-reduced-motion: reduce) {
  .cx *, .cx *::before, .cx *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}

/* ======================================================================
   Course page and video player
   ====================================================================== */
.cx .cx-back { display: inline-flex; align-items: center; gap: 6px; font-size: 0.86rem; font-weight: 700; text-decoration: none; color: var(--cx-text); white-space: nowrap; }
.cx .cx-back:hover { color: var(--cx-gold-text); }
.cx .cx-bar__sep { width: 1px; height: 22px; background: var(--cx-line); }
.cx .cx-bar__here { font-size: 0.86rem; font-weight: 600; color: var(--cx-text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }

/* course layout */
.cx .cx-course { display: flex; flex-wrap: wrap; gap: 48px; align-items: flex-start; padding: 8px 0 64px; }
.cx .cx-course__main { flex: 999 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 48px; }
.cx .cx-course__aside { flex: 1 1 300px; max-width: 380px; position: sticky; top: 104px; }
.cx .cx-h2 { margin: 0 0 16px; font-size: 1.4rem; line-height: 1.25; font-weight: 800; letter-spacing: -0.015em; }
.cx .cx-prose { display: grid; gap: 14px; max-width: 68ch; color: var(--cx-text-2); }
.cx .cx-prose p { margin: 0; }

/* lesson list (episodes) */
.cx .cx-eps { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--cx-line); }
.cx .cx-eps__mod { padding: 18px 4px 6px; font-size: 0.72rem; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; color: var(--cx-text-3); }
.cx .cx-ep { display: flex; gap: 18px; align-items: center; padding: 14px 8px; border-bottom: 1px solid var(--cx-line); text-decoration: none; color: var(--cx-text); border-radius: var(--cx-radius); }
a.cx-ep:hover { background: var(--cx-surface-2); }
.cx .cx-ep__n { width: 28px; flex: 0 0 auto; text-align: center; font-size: 1.15rem; font-weight: 800; color: var(--cx-text-3); font-variant-numeric: tabular-nums; }
.cx .cx-ep__thumb { width: 132px; flex: 0 0 auto; aspect-ratio: 16 / 9; border-radius: var(--cx-radius); background: var(--cx-tile-charcoal); display: flex; align-items: center; justify-content: center; position: relative; overflow: hidden; }
.cx .cx-ep__thumb svg { position: relative; }
.cx .cx-ep__body { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.cx .cx-ep__body b { font-size: 1rem; line-height: 1.35; }
.cx .cx-ep__body span { font-size: 0.82rem; color: var(--cx-text-3); }
.cx .cx-ep--locked { color: var(--cx-text-2); }
.cx .cx-tag { display: inline-flex; align-items: center; flex: 0 0 auto; font-size: 0.66rem; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; border: 1px solid currentColor; border-radius: var(--cx-radius); padding: 2px 7px; color: var(--cx-gold-text); line-height: 1.5; }
.cx .cx-lockword { flex: 0 0 auto; font-size: 0.8rem; font-weight: 600; color: var(--cx-text-3); display: inline-flex; gap: 6px; align-items: center; }

/* outcomes */
.cx .cx-outcomes { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.cx .cx-outcomes li { display: flex; gap: 12px; align-items: flex-start; padding: 16px 18px; background: var(--cx-surface); border: 1px solid var(--cx-line); border-radius: var(--cx-radius); font-size: 0.95rem; line-height: 1.5; }
.cx .cx-outcomes svg { flex: 0 0 auto; margin-top: 2px; }

/* programme path */
.cx .cx-path { background: var(--cx-surface-2); border-radius: var(--cx-radius); padding: 24px; }
.cx .cx-path ol { list-style: none; margin: 16px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.cx .cx-path li a, .cx .cx-path li > div { display: block; height: 100%; padding: 14px 16px; border-radius: var(--cx-radius); background: var(--cx-surface); border: 1px solid var(--cx-line); text-decoration: none; color: var(--cx-text); }
.cx .cx-path li a:hover { border-color: var(--cx-text); }
.cx .cx-path li > div { background: var(--cx-charcoal); border-color: var(--cx-charcoal); color: #fff; }
.cx .cx-path li > div .cx-eyebrow { color: var(--cx-gold-light); }
.cx .cx-path b { display: block; margin-top: 4px; font-weight: 800; }

/* summary card */
.cx .cx-sum { background: var(--cx-surface); border: 1px solid var(--cx-line); border-radius: var(--cx-radius); box-shadow: var(--cx-shadow-md); padding: 26px; }
.cx .cx-sum__price { margin: 8px 0 0; font-size: 2.5rem; line-height: 1.1; font-weight: 800; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.cx .cx-sum__note { margin: 4px 0 0; font-size: 0.88rem; color: var(--cx-text-2); }
.cx .cx-sum .cx-btn { width: 100%; margin-top: 18px; }
.cx .cx-sum .cx-btn + .cx-btn { margin-top: 10px; }
.cx .cx-sum hr { border: 0; border-top: 1px solid var(--cx-line); margin: 22px 0; }
.cx .cx-ticks { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 10px; font-size: 0.92rem; line-height: 1.45; }
.cx .cx-ticks li { display: flex; gap: 10px; }
.cx .cx-ticks svg { flex: 0 0 auto; margin-top: 2px; }

/* enquiry form */
.cx .cx-enquire { background: var(--cx-surface); border: 1px solid var(--cx-line); border-radius: var(--cx-radius); padding: 28px; scroll-margin-top: 110px; }
.cx .cx-enquire > p { margin: 6px 0 20px; color: var(--cx-text-2); max-width: 60ch; }
.cx .cx-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 18px; }
.cx .cx-field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.cx .cx-field--full { grid-column: 1 / -1; }
.cx .cx-field label { font-size: 0.86rem; font-weight: 700; }
.cx .cx-field label .cx-opt { font-weight: 500; color: var(--cx-text-3); }
.cx .cx-field input, .cx .cx-field select, .cx .cx-field textarea {
  width: 100%; min-height: 48px; padding: 11px 14px; font: inherit; font-size: 0.95rem;
  color: var(--cx-text); background: var(--cx-bg); border: 1.5px solid var(--cx-line); border-radius: var(--cx-radius);
  transition: border-color 0.2s var(--cx-ease);
}
.cx .cx-field textarea { min-height: 120px; resize: vertical; }
.cx .cx-field :is(input, select, textarea):focus { outline: none; border-color: var(--cx-gold); box-shadow: 0 0 0 3px rgba(209, 165, 60, 0.22); }
.cx .cx-field [aria-invalid="true"] { border-color: #b3261e; }
.cx .cx-err { margin: 0; min-height: 0; font-size: 0.8rem; font-weight: 600; color: #b3261e; }
@media (prefers-color-scheme: dark) { html:not([data-cx-theme="light"]):not([data-theme="light"]) .cx .cx-err { color: #f2a59c; } }
html[data-cx-theme="dark"] .cx .cx-err { color: #f2a59c; }
.cx .cx-hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.cx .cx-status { grid-column: 1 / -1; margin: 0; font-size: 0.9rem; font-weight: 600; }
.cx .cx-status.is-ok { color: var(--cx-gold-text); }
.cx .cx-status.is-bad { color: #b3261e; }
.cx .cx-form .cx-btn { width: 100%; }

/* ------------------------------------------------------------ player */
.cx .cx-theatre { background: #0d0d0d; color: #fff; }
.cx .cx-theatre__in { max-width: 1240px; margin: 0 auto; padding: 24px 24px 28px; }
.cx .cx-screen { position: relative; aspect-ratio: 16 / 9; max-width: 100%; background: #161616; border-radius: var(--cx-radius); overflow: hidden; border: 1px solid rgba(255, 255, 255, 0.08); }
.cx .cx-screen iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.cx .cx-screen .cx-hex { position: absolute; right: -6%; top: -14%; width: 44%; height: auto; opacity: 0.22; }
.cx .cx-screen__state { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; text-align: center; padding: 24px; }
.cx .cx-screen__state h2 { margin: 0; font-size: clamp(1.2rem, 2.4vw, 1.7rem); line-height: 1.25; font-weight: 800; max-width: 26ch; }
.cx .cx-screen__state p { margin: 0; font-size: 0.95rem; color: rgba(255, 255, 255, 0.72); max-width: 46ch; }
.cx .cx-screen__state--locked { background: rgba(13, 13, 13, 0.82); }
.cx .cx-screen__label { position: absolute; left: 20px; top: 16px; font-size: 0.68rem; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: rgba(255, 255, 255, 0.6); }
.cx .cx-nowplaying { display: flex; flex-wrap: wrap; gap: 16px 24px; align-items: flex-end; justify-content: space-between; margin-top: 22px; }
.cx .cx-nowplaying h1 { margin: 6px 0 0; font-size: clamp(1.5rem, 3vw, 2.1rem); line-height: 1.15; font-weight: 800; letter-spacing: -0.02em; }
.cx .cx-nowplaying p { margin: 6px 0 0; color: rgba(255, 255, 255, 0.72); font-size: 0.92rem; }
.cx .cx-theatre .cx-eyebrow { color: var(--cx-gold-light); }
.cx .cx-pn { display: flex; flex-wrap: wrap; gap: 10px; }
.cx .cx-tile--current .cx-tile__box { outline: 2px solid var(--cx-gold); outline-offset: 2px; }
.cx .cx-tile--locked .cx-tile__box::after { content: ""; position: absolute; inset: 0; background: rgba(0, 0, 0, 0.35); }

@media (max-width: 940px) {
  .cx .cx-course__aside { position: static; max-width: none; order: -1; }
  .cx .cx-outcomes, .cx .cx-path ol { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 560px) {
  .cx .cx-ep__thumb { width: 84px; }
  .cx .cx-ep__n { display: none; }
  .cx .cx-form { grid-template-columns: minmax(0, 1fr); }
  .cx .cx-enquire { padding: 22px 18px; }
  .cx .cx-theatre__in { padding: 0 0 20px; }
  .cx .cx-screen { border-radius: 0; border-left: 0; border-right: 0; min-height: 270px; }
  .cx .cx-nowplaying { padding: 0 16px; }
  .cx .cx-pn .cx-btn { flex: 1 1 100%; }
}

/* ======================================================================
   Intro (Courses home top), breadcrumbs, anchor offsets
   ====================================================================== */
/* rows and the form stop below the sticky header (82px) with their title in view */
.cx .cx-row, .cx [id^="cx-row-"] { scroll-margin-top: 100px; }

.cx .cx-intro { padding: 56px 0 52px; }
.cx .cx-intro .cx-wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.12fr); gap: 56px; align-items: center; }
.cx .cx-intro h1 { margin: 14px 0 0; font-size: clamp(2.2rem, 3.9vw, 3.1rem); line-height: 1.06; font-weight: 800; letter-spacing: -0.03em; }
.cx .cx-intro h1 span { color: var(--cx-head-gold); display: block; }
.cx .cx-rule { width: 44px; height: 3px; background: var(--cx-gold); border-radius: 2px; margin-top: 14px; }
.cx .cx-intro .cx-lead { margin: 18px 0 0; font-size: 1.05rem; line-height: 1.7; color: var(--cx-text-2); max-width: 46ch; }
.cx .cx-points { list-style: none; margin: 20px 0 0; padding: 0; display: grid; gap: 10px; font-size: 0.95rem; font-weight: 600; }
.cx .cx-points li { display: flex; gap: 10px; align-items: flex-start; }
.cx .cx-points svg { flex: 0 0 auto; margin-top: 3px; color: var(--cx-gold-text); }
.cx .cx-intro__actions { margin-top: 28px; display: flex; flex-wrap: wrap; align-items: center; gap: 14px 26px; }

/* redesigned buttons: a play button with its own round badge, and a quiet text link */
.cx .cx-playbtn {
  display: inline-flex; align-items: center; gap: 14px; min-height: 58px; padding: 8px 26px 8px 8px;
  border: 0; border-radius: 999px; background: var(--cx-gold); color: var(--cx-on-gold);
  font: inherit; font-size: 0.98rem; font-weight: 800; text-decoration: none; cursor: pointer; text-align: left;
  box-shadow: 0 10px 26px rgba(176, 134, 42, 0.28);
  transition: background-color 0.25s var(--cx-ease), transform 0.25s var(--cx-ease);
}
.cx .cx-playbtn:hover { background: var(--cx-gold-deep); transform: translateY(-2px); }
.cx .cx-playbtn__badge { width: 42px; height: 42px; flex: 0 0 auto; border-radius: 50%; background: var(--cx-charcoal); display: flex; align-items: center; justify-content: center; }
.cx .cx-playbtn__text { display: flex; flex-direction: column; line-height: 1.2; }
.cx .cx-playbtn__text small { font-size: 0.74rem; font-weight: 600; opacity: 0.8; }
.cx .cx-textlink { display: inline-flex; align-items: center; gap: 8px; font-size: 0.95rem; font-weight: 800; text-decoration: none; color: var(--cx-text); padding: 6px 0; border-bottom: 2px solid var(--cx-gold); }
.cx .cx-textlink svg { transition: transform 0.25s var(--cx-ease); }
.cx .cx-textlink:hover svg { transform: translateY(3px); }

/* welcome video card (always dark, like the player) */
.cx .cx-welcome { background: #121212; border-radius: 10px; overflow: hidden; box-shadow: var(--cx-shadow-md); border: 1px solid var(--cx-card-line); color: #fff; }
.cx .cx-welcome__screen { position: relative; aspect-ratio: 16 / 9; max-width: 100%; background: #1a1a1a; overflow: hidden; }
.cx .cx-welcome__screen iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.cx .cx-welcome__screen .cx-hex { position: absolute; left: -10%; bottom: -30%; width: 48%; height: auto; opacity: 0.22; }
.cx .cx-welcome__cover { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; padding: 0; background: none; color: #fff; cursor: pointer; font: inherit; }
.cx .cx-welcome__cover .cx-stage__ring { width: 88px; height: 88px; }
.cx .cx-welcome__cover:hover .cx-stage__ring { transform: translate(-50%, -50%) scale(1.06); }
.cx .cx-welcome__quote { position: absolute; left: 24px; right: 24px; top: 20px; text-align: left; font-size: 0.7rem; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: rgba(255, 255, 255, 0.62); }
.cx .cx-welcome__msg { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; padding: 24px; text-align: center; }
.cx .cx-welcome__msg b { font-size: 1.15rem; }
.cx .cx-welcome__msg span { font-size: 0.9rem; color: rgba(255, 255, 255, 0.72); max-width: 40ch; }
.cx .cx-welcome__by { display: flex; align-items: center; gap: 14px; padding: 16px 20px; border-top: 1px solid rgba(255, 255, 255, 0.08); }
.cx .cx-avatar { width: 44px; height: 44px; flex: 0 0 auto; border-radius: 50%; background: var(--cx-charcoal); border: 2px solid var(--cx-gold); color: var(--cx-gold-light); display: flex; align-items: center; justify-content: center; font-size: 0.9rem; font-weight: 800; }
.cx .cx-welcome__by b { display: block; font-size: 0.98rem; }
.cx .cx-welcome__by span { font-size: 0.82rem; color: rgba(255, 255, 255, 0.66); }
.cx .cx-welcome__by .cx-welcome__tag { margin-left: auto; font-size: 0.68rem; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; color: var(--cx-gold-light); }

/* breadcrumbs in the Courses bar */
.cx .cx-crumbs { display: flex; align-items: center; gap: 8px; min-width: 0; flex: 1 1 auto; font-size: 0.86rem; font-weight: 600; color: var(--cx-text-2); }
.cx .cx-crumbs a { color: var(--cx-text); font-weight: 800; text-decoration: none; white-space: nowrap; }
.cx .cx-crumbs a:hover { color: var(--cx-gold-text); text-decoration: underline; text-underline-offset: 3px; }
.cx .cx-crumbs .cx-crumbs__sep { color: var(--cx-text-3); }
.cx .cx-crumbs .cx-crumbs__c { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.cx .cx-crumbs [aria-current] { white-space: nowrap; color: var(--cx-text-2); }

@media (max-width: 940px) {
  .cx .cx-intro .cx-wrap { grid-template-columns: minmax(0, 1fr); gap: 32px; }
  .cx .cx-intro { padding-top: 36px; }
}
@media (max-width: 560px) {
  .cx .cx-playbtn { width: 100%; }
  .cx .cx-welcome__by .cx-welcome__tag { display: none; }
  .cx .cx-crumbs .cx-crumbs__lesson { display: none; }
}

/* ======================================================================
   Back button, view switch (Rows | Table) and the course table (Option D)
   ====================================================================== */
.cx .cx-backbtn {
  display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 14px 0 10px; flex: 0 0 auto;
  border-radius: 999px; border: 1px solid var(--cx-line); background: var(--cx-surface); color: var(--cx-text);
  font: inherit; font-size: 0.82rem; font-weight: 800; text-decoration: none; cursor: pointer;
  transition: border-color 0.2s var(--cx-ease);
}
.cx .cx-backbtn:hover { border-color: var(--cx-text); }

.cx .cx-views { display: inline-flex; padding: 3px; gap: 2px; border-radius: 999px; background: var(--cx-surface); border: 1px solid var(--cx-line); flex: 0 0 auto; }
.cx .cx-views button {
  display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px; border: 0; border-radius: 999px;
  background: transparent; color: var(--cx-text-2); font: inherit; font-size: 0.8rem; font-weight: 800; cursor: pointer;
}
.cx .cx-views button[aria-pressed="true"] { background: var(--cx-text); color: var(--cx-bg); }
.cx .cx-views svg { width: 15px; height: 15px; }

.cx .cx-tablepanel { padding: 12px 0 72px; scroll-margin-top: 100px; }
.cx .cx-tablehead { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 14px 24px; margin-bottom: 16px; }
.cx .cx-tablehead h2 { margin: 0; font-size: 1.4rem; line-height: 1.25; font-weight: 800; letter-spacing: -0.015em; }
.cx .cx-tablehead p { margin: 2px 0 0; font-size: 0.88rem; color: var(--cx-text-3); }
.cx .cx-search { position: relative; display: block; flex: 0 1 320px; min-width: 0; }
.cx .cx-search svg { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--cx-text-3); pointer-events: none; }
.cx .cx-search input {
  width: 100%; height: 44px; padding: 0 14px 0 40px; border-radius: 999px; border: 1.5px solid var(--cx-line);
  background: var(--cx-surface); color: var(--cx-text); font: inherit; font-size: 0.92rem;
}
.cx .cx-search input:focus { outline: none; border-color: var(--cx-gold); box-shadow: 0 0 0 3px rgba(209, 165, 60, 0.22); }
.cx .cx-filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.cx .cx-filters button {
  display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 14px; border-radius: 999px;
  border: 1px solid var(--cx-line); background: var(--cx-surface); color: var(--cx-text);
  font: inherit; font-size: 0.82rem; font-weight: 700; cursor: pointer;
}
.cx .cx-filters button:hover { border-color: var(--cx-text); }
.cx .cx-filters button[aria-pressed="true"] { background: var(--cx-text); border-color: var(--cx-text); color: var(--cx-bg); }
.cx .cx-filters .n { opacity: 0.65; font-variant-numeric: tabular-nums; }

.cx .cx-tablewrap { background: var(--cx-surface); border: 1px solid var(--cx-line); border-radius: var(--cx-radius); overflow-x: auto; box-shadow: var(--cx-shadow); }
.cx .cx-table { width: 100%; border-collapse: collapse; font-size: 0.92rem; }
.cx .cx-table th { text-align: left; padding: 12px 16px; font-size: 0.7rem; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; color: var(--cx-text-3); border-bottom: 1px solid var(--cx-line); white-space: nowrap; background: var(--cx-surface-2); }
.cx .cx-table th button { display: inline-flex; align-items: center; gap: 6px; padding: 0; border: 0; background: none; font: inherit; letter-spacing: inherit; text-transform: inherit; color: inherit; cursor: pointer; }
.cx .cx-table th button:hover, .cx .cx-table th[aria-sort="ascending"] button, .cx .cx-table th[aria-sort="descending"] button { color: var(--cx-text); }
.cx .cx-table th .cx-sorticon { width: 12px; height: 12px; opacity: 0.45; transition: transform 0.2s var(--cx-ease); }
.cx .cx-table th[aria-sort="ascending"] .cx-sorticon, .cx .cx-table th[aria-sort="descending"] .cx-sorticon { opacity: 1; color: var(--cx-gold-text); }
.cx .cx-table th[aria-sort="descending"] .cx-sorticon { transform: rotate(180deg); }
.cx .cx-table td { padding: 14px 16px; border-bottom: 1px solid var(--cx-line); vertical-align: middle; color: var(--cx-text-2); }
.cx .cx-table tbody tr:last-child td { border-bottom: 0; }
.cx .cx-table tbody tr { transition: background-color 0.15s; }
.cx .cx-table tbody tr:hover { background: var(--cx-surface-2); }
.cx .cx-table .cx-num { font-variant-numeric: tabular-nums; white-space: nowrap; }
.cx .cx-table .cx-price { font-weight: 800; color: var(--cx-text); }
.cx .cx-tname { display: flex; align-items: center; gap: 14px; text-decoration: none; color: var(--cx-text); min-width: 260px; }
.cx .cx-tname b { display: block; font-size: 0.98rem; line-height: 1.3; }
.cx .cx-tname span span { display: block; margin-top: 2px; font-size: 0.82rem; color: var(--cx-text-3); max-width: 46ch; }
.cx .cx-tname:hover b { color: var(--cx-gold-text); }
.cx .cx-tthumb { width: 64px; flex: 0 0 auto; aspect-ratio: 16 / 9; border-radius: 3px; position: relative; overflow: hidden; }
.cx .cx-tthumb .cx-hex { position: absolute; right: -10px; top: -10px; width: 46px; height: auto; opacity: 0.5; }
.cx .cx-tthumb--charcoal { background: var(--cx-tile-charcoal); box-shadow: inset 0 0 0 1px var(--cx-line); }
.cx .cx-tthumb--gold { background: var(--cx-gold); }
.cx .cx-tthumb--stone { background: var(--cx-tile-stone); box-shadow: inset 0 0 0 1px var(--cx-tile-stone-line); }
.cx .cx-pill { display: inline-flex; align-items: center; height: 24px; padding: 0 10px; border-radius: 999px; background: var(--cx-surface-2); border: 1px solid var(--cx-line); font-size: 0.76rem; font-weight: 700; color: var(--cx-text); white-space: nowrap; }
.cx .cx-free { color: var(--cx-gold-text); }
.cx .cx-table .cx-btn { white-space: nowrap; }
.cx .cx-empty { padding: 40px 20px; text-align: center; color: var(--cx-text-2); margin: 0; }

/* phones: each table row becomes a compact card */
@media (max-width: 760px) {
  .cx .cx-tablewrap { background: transparent; border: 0; box-shadow: none; overflow: visible; }
  .cx .cx-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .cx .cx-table, .cx .cx-table tbody { display: block; }
  .cx .cx-table tbody tr { display: grid; grid-template-columns: 1fr auto; gap: 6px 12px; padding: 14px; margin-bottom: 10px; background: var(--cx-surface); border: 1px solid var(--cx-line); border-radius: var(--cx-radius); }
  .cx .cx-table td { display: block; padding: 0; border: 0; }
  .cx .cx-table td.cx-tc { grid-column: 1 / -1; }
  .cx .cx-tname { min-width: 0; }
  .cx .cx-table td[data-label="Area"], .cx .cx-table td[data-label="Level"] { display: none; }
  .cx .cx-table td[data-label="Lessons"]::after { content: " · " attr(data-level); }
  .cx .cx-table td[data-label="Lessons"] { font-size: 0.85rem; align-self: center; }
  .cx .cx-table td[data-label="Price"] { text-align: right; align-self: center; }
  .cx .cx-table td.cx-tact { grid-column: 1 / -1; }
  .cx .cx-table td.cx-tact .cx-btn { width: 100%; }
  .cx .cx-search { flex-basis: 100%; }
}
@media (max-width: 560px) {
  .cx .cx-views button span { display: none; }
  .cx .cx-views button { padding: 0 10px; }
  .cx .cx-views { order: 2; margin-left: auto; }
}
@media (max-width: 560px) { .cx .cx-bar .cx-views ~ .cx-theme { margin-left: 0; } }
/* long lesson names in Previous / Next buttons wrap instead of widening the page */
.cx .cx-pn .cx-btn { white-space: normal; text-align: center; max-width: 100%; height: auto; }
.cx .cx-pn .cx-btn span { overflow-wrap: anywhere; }

/* hidden always wins over component display rules (e.g. Rows panel in Table view) */
.cx [hidden] { display: none !important; }

/* ------------------------------------------------ Vimeo thumbnails */
.cx .cx-thumb { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.cx .cx-tile--img .cx-tile__box { background: #1e1e1e; color: #fff; box-shadow: none; }
.cx .cx-tile--img .cx-tile__box::before { content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(180deg, rgba(0,0,0,.45) 0%, rgba(0,0,0,0) 34%, rgba(0,0,0,0) 46%, rgba(0,0,0,.82) 100%); }
.cx .cx-tile--img .cx-tile__tag, .cx .cx-tile--img .cx-tile__name, .cx .cx-tile--img .cx-tile__play { z-index: 2; }
.cx .cx-tile--img .cx-tile__tag { color: var(--cx-gold-light); text-shadow: 0 1px 2px rgba(0,0,0,.5); }
.cx .cx-tile--img .cx-tile__name { color: #fff; text-shadow: 0 1px 3px rgba(0,0,0,.45); }
.cx .cx-tile--img .cx-thumb { transition: transform .4s var(--cx-ease); }
.cx .cx-tile--img:hover .cx-thumb { transform: scale(1.04); }
.cx .cx-tile--img.cx-tile--locked .cx-tile__box::after { z-index: 1; }
.cx .cx-stage--img .cx-thumb { opacity: .9; }
.cx .cx-stage--img::before { content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(180deg, rgba(0,0,0,.4) 0%, rgba(0,0,0,0) 30%, rgba(0,0,0,0) 55%, rgba(0,0,0,.8) 100%); }
.cx .cx-stage--img .cx-stage__label, .cx .cx-stage--img .cx-stage__ring, .cx .cx-stage--img .cx-stage__caption { z-index: 2; }
.cx .cx-stage--img .cx-stage__label { color: rgba(255,255,255,.85); }
.cx .cx-ep__thumb .cx-thumb + svg { position: relative; z-index: 1; filter: drop-shadow(0 1px 4px rgba(0,0,0,.6)); }
.cx .cx-ep__thumb:has(.cx-thumb)::after { content: ""; position: absolute; inset: 0; background: rgba(0,0,0,.22); }
.cx .cx-ep__thumb .cx-thumb + svg { z-index: 2; }
.cx .cx-tthumb .cx-thumb { border-radius: inherit; }
.cx .cx-screen__poster { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .35; }

/* ------------------------------------------- inline play + progress */
.cx .cx-stage--playing { background: #000; }
.cx .cx-stage--playing iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.cx .cx-stage--playing .cx-screen__state { color: #fff; }
.cx .cx-stage .cx-upnext { z-index: 3; }
.cx .cx-ep--done .cx-ep__n { color: var(--cx-gold-text); font-size: 0; }
.cx .cx-ep--done .cx-ep__n::before { content: "✓"; font-size: 1.15rem; }
.cx .cx-ep--done .cx-ep__body > span::after { content: " · Watched"; color: var(--cx-gold-text); font-weight: 700; }
.cx .cx-ep--last:not(.cx-ep--done) .cx-ep__body > span::after { content: " · Up to here"; color: var(--cx-gold-text); font-weight: 700; }
