/* pc-edu-hub.css: the Education Hub "My Courses" layout (assets/pc-edu-hub.js). Vortex 2026-10-21.
 * Colours (Waqas 2026-10-21: the first cover colours "dont looks nice"): the PureBrain palette only. Covers are deep navy
 * to brand blue (varied by angle and shade, never by hue) with faint line-art; orange is a small accent; status pills are
 * the page's own .module-status pills. --eh-navy / --eh-navy-2 are the navy of the page's own banner (.edu-hero,
 * rgba(13,26,42)) and of the logo chip: covers stay navy in both themes, like the brand mark.
 * Only the page's design tokens (--card, --border, --text, --muted, --blue, --blue-dim, --blue-border, --orange,
 * --gradient-btn, --radius-*, --shadow-card); every token has a light value, so the same
 * rules serve both themes. Right-hand column from 1200px; below that it follows the main column (end of the page). */

.pc-eh { --eh-on-cover: #fff; --eh-navy: #0d1a2a; --eh-navy-2: #08111d; --eh-blue-text: var(--blue); --eh-gap: 20px; display: flex; flex-direction: column; gap: var(--eh-gap); }

/* small blue text needs a darker blue on the light theme to reach 4.5:1 (the reader's --blue-text value) */
[data-theme="light"] .pc-eh { --eh-blue-text: #1a6a94; }
/* the "Saved" pill sits on the navy cover in both themes */
.pc-eh-chip.locked { color: rgba(255,255,255,0.82); }

/* from 1200px the hub uses the whole main column (the page's 960px cap is lifted), like the other pages' main column */
@media (min-width: 1200px) {
  .page-content-inner:has(.pc-eh) { max-width: none; }
}

/* ── stats header ─────────────────────────────────────────────────────────── */
.pc-eh-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.pc-eh-stat { display: flex; align-items: center; gap: 12px; padding: 14px 16px; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius-md); min-width: 0; }
.pc-eh-stat-ico { flex-shrink: 0; width: 38px; height: 38px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; color: var(--eh-blue-text); background: var(--blue-dim); border: 1px solid var(--blue-border); }
.pc-eh-stat-certs .pc-eh-stat-ico { color: var(--orange); background: rgba(241,66,11,0.10); border-color: rgba(241,66,11,0.28); }
.pc-eh-stat-txt { display: flex; flex-direction: column; min-width: 0; }
.pc-eh-stat-n { font-family: 'Oswald', sans-serif; font-weight: 600; font-size: 24px; line-height: 1.1; color: var(--text); }
.pc-eh-stat-l { font-size: 12px; font-weight: 600; color: var(--muted); }

.pc-eh-signin { display: flex; align-items: center; gap: 14px; padding: 14px 16px; background: var(--card); border: 1px solid var(--blue-border); border-radius: var(--radius-md); }
.pc-eh-signin p { margin: 0; font-size: 14px; color: var(--muted); line-height: 1.5; }
.pc-eh-signin b { color: var(--text); }
.pc-eh-signin a { color: var(--eh-blue-text); font-weight: 700; }

/* ── columns ──────────────────────────────────────────────────────────────── */
.pc-eh-cols { display: flex; flex-direction: column; gap: 28px; }
.pc-eh-main { display: flex; flex-direction: column; gap: 28px; min-width: 0; }
.pc-eh-side { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.pc-eh-side:empty, .pc-eh-paths:empty { display: none; }
@media (min-width: 1200px) {
  .pc-eh-cols { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 28px; align-items: start; }
  .pc-eh-side { position: sticky; top: 84px; }
}
@media (min-width: 1600px) {
  .pc-eh-cols { grid-template-columns: minmax(0, 1fr) 340px; gap: 32px; }
}

/* ── hero ─────────────────────────────────────────────────────────────────── */
.pc-eh-hero { display: flex; background: var(--card); border: 1px solid var(--blue-border); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-card); }
.pc-eh-hero-cover { flex: 0 0 230px; min-height: 210px; }
.pc-eh-hero-cover svg { width: 56px; height: 56px; }
.pc-eh-hero-body { flex: 1; min-width: 0; padding: 22px 24px; display: flex; flex-direction: column; gap: 8px; }
.pc-eh-kicker { font-size: 11px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--eh-blue-text); }
.pc-eh-hero-title { margin: 0; font-size: 24px; line-height: 1.2; color: var(--text); text-transform: none; letter-spacing: .01em; }
.pc-eh-hero-desc { margin: 0; font-size: 14px; color: var(--muted); line-height: 1.55; max-width: 60ch; }
.pc-eh-hero-next { margin: 2px 0 0; font-size: 13.5px; color: var(--text); }
.pc-eh-hero-next span { font-size: 11px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin-right: 4px; }
.pc-eh-hero .pc-eh-acts { margin-top: 6px; }
.pc-eh-hero .pc-eh-prog { max-width: 420px; }

/* ── covers (gradients from the brand tokens) ─────────────────────────────── */
.pc-eh-cover { position: relative; display: flex; align-items: center; justify-content: center; color: var(--eh-on-cover); overflow: hidden; background-color: var(--eh-navy); }
/* faint line-art: a fine grid and two arcs */
.pc-eh-cover::before { content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(circle at 100% 0%, transparent 38%, rgba(255,255,255,0.10) 38.4%, transparent 39.2%),
    radial-gradient(circle at 100% 0%, transparent 56%, rgba(255,255,255,0.07) 56.4%, transparent 57.2%),
    repeating-linear-gradient(0deg, rgba(255,255,255,0.045) 0 1px, transparent 1px 22px),
    repeating-linear-gradient(90deg, rgba(255,255,255,0.045) 0 1px, transparent 1px 22px); }
/* the orange accent, sparingly: a short rule at the foot of the cover */
.pc-eh-cover::after { content: ""; position: absolute; left: 16px; bottom: 0; width: 36px; height: 3px; border-radius: 3px 3px 0 0; background: var(--orange); pointer-events: none; }
.pc-eh-cover svg { position: relative; z-index: 1; opacity: .92; }
.pc-eh-cover-0 { background-image: linear-gradient(135deg, var(--eh-navy-2) 0%, var(--eh-navy) 35%, var(--blue) 130%); }
.pc-eh-cover-1 { background-image: linear-gradient(200deg, var(--eh-navy-2) 10%, color-mix(in srgb, var(--blue) 55%, var(--eh-navy)) 100%); }
.pc-eh-cover-2 { background-image: linear-gradient(100deg, color-mix(in srgb, var(--blue) 80%, var(--eh-navy)) 0%, var(--eh-navy) 75%); }
.pc-eh-cover-3 { background-image: linear-gradient(325deg, var(--eh-navy-2) 15%, var(--eh-navy) 50%, color-mix(in srgb, var(--blue) 70%, var(--eh-navy)) 100%); }
.pc-eh-cover-kicker { position: absolute; z-index: 1; top: 10px; left: 12px; font-size: 10px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; opacity: .9; }

/* ── sections + catalogue grid ────────────────────────────────────────────── */
.pc-eh-sec { display: flex; flex-direction: column; gap: 14px; }
.pc-eh-sec-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding-bottom: 8px; border-bottom: 1px solid var(--border); }
.pc-eh-sec-head h2 { margin: 0; font-size: 17px; color: var(--text); }
.pc-eh-sec-sub { font-size: 12.5px; font-weight: 600; color: var(--muted); }
.pc-eh-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 16px; }
.pc-eh-card { display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius-md); overflow: hidden; transition: border-color var(--transition), transform var(--transition), box-shadow var(--transition); margin: 0; padding: 0; }
.pc-eh-card:hover { border-color: var(--blue-border); box-shadow: var(--shadow-card); transform: translateY(-2px); }
.pc-eh-card .pc-eh-cover { height: 118px; }
/* status pills: the page's own .module-status pills (completed / in-progress / locked), placed on the cover over a navy
   backing so they read the same on every cover */
.pc-eh-chip { position: absolute; z-index: 1; top: 10px; right: 10px; isolation: isolate; }
.pc-eh-chip::before { content: ""; position: absolute; inset: -1px; z-index: -1; border-radius: inherit; background: var(--eh-navy-2); }
.pc-eh-card-body { flex: 1; display: flex; flex-direction: column; gap: 8px; padding: 14px 16px 16px; }
.pc-eh-card .pc-course-title { margin: 0; font-size: 16.5px; line-height: 1.25; color: var(--text); text-transform: none; letter-spacing: .01em; }
.pc-eh-card .pc-course-desc { margin: 0; font-size: 13px; line-height: 1.5; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.pc-eh-by { font-size: 12px; color: var(--muted); }
.pc-eh-by b { color: var(--text); }
.pc-eh-tag { display: inline-block; font-size: 10.5px; font-weight: 700; padding: 1px 7px; border-radius: var(--radius-pill); border: 1px solid var(--border); color: var(--muted); }
.pc-eh-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 5px; font-size: 12px; font-weight: 600; color: var(--muted); }
.pc-eh-meta svg { flex-shrink: 0; }
.pc-eh-dot { width: 3px; height: 3px; border-radius: 50%; background: currentColor; opacity: .6; margin: 0 3px; }
.pc-eh-card .pc-eh-acts { margin-top: auto; padding-top: 6px; }
.pc-eh-empty { grid-column: 1 / -1; }

/* the lesson list of a course opens under its card row, full width */
.pc-eh-modules { grid-column: 1 / -1; padding: 14px; background: var(--card); border: 1px solid var(--blue-border); border-radius: var(--radius-md); }
.pc-eh-modules[hidden] { display: none; }

/* ── progress ─────────────────────────────────────────────────────────────── */
.pc-eh-prog { display: flex; flex-direction: column; gap: 5px; }
.pc-eh-bar { height: 6px; border-radius: var(--radius-pill); background: var(--blue-dim); overflow: hidden; }
.pc-eh-bar-fill { height: 100%; border-radius: inherit; background: var(--gradient-btn); transition: width var(--transition); }
.pc-eh-count { font-size: 12px; font-weight: 700; color: var(--muted); }

/* ── buttons ──────────────────────────────────────────────────────────────── */
.pc-eh-acts { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.pc-eh-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 40px; padding: 0 18px; font: inherit; font-size: 13.5px; font-weight: 700; border-radius: var(--radius-pill); text-decoration: none; cursor: pointer; border: 1px solid transparent; transition: background var(--transition), border-color var(--transition), color var(--transition); }
.pc-eh-btn-sm { min-height: 34px; padding: 0 14px; font-size: 12.5px; }
.pc-eh-btn-primary { color: var(--eh-on-cover); background: var(--gradient-btn); }
.pc-eh-btn-primary:hover { background: var(--gradient-btn-hover); }
.pc-eh-btn-ghost { color: var(--eh-blue-text); background: var(--blue-dim); border-color: var(--blue-border); }
.pc-eh-btn-ghost:hover { border-color: var(--blue); }
.pc-eh-btn-link { color: var(--muted); background: transparent; padding: 0 8px; }
.pc-eh-btn-link:hover { color: var(--text); }

/* ── learning paths (pcExtrasHtml markup) ─────────────────────────────────── */
.pc-eh-paths .section-header { margin: 0 0 14px; }
.pc-eh-paths .pc-path-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius-md); padding: 16px 18px; }
.pc-eh-paths .pc-path-step { gap: 12px; }

/* ── right column cards ───────────────────────────────────────────────────── */
.pc-eh-side-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius-md); padding: 16px; }
.pc-eh-side-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.pc-eh-side-head h2 { margin: 0; font-size: 14.5px; color: var(--text); }
.pc-eh-side-n { font-size: 11.5px; font-weight: 800; min-width: 22px; height: 22px; padding: 0 7px; border-radius: var(--radius-pill); display: inline-flex; align-items: center; justify-content: center; color: var(--eh-blue-text); background: var(--blue-dim); }
.pc-eh-cert-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.pc-eh-cert { display: flex; gap: 12px; align-items: flex-start; padding: 10px 0; border-top: 1px solid var(--border); margin: 0; background: none; border-radius: 0; border-left: 0; border-right: 0; border-bottom: 0; }
.pc-eh-cert:first-child { border-top: 0; padding-top: 0; }
.pc-eh-cert-thumb { flex-shrink: 0; text-decoration: none; border-radius: 6px; }
.pc-eh-cert-body { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.pc-eh-cert-kicker { font-size: 10px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--eh-blue-text); }
.pc-eh-cert-title { font-size: 13.5px; font-weight: 700; color: var(--text); line-height: 1.3; overflow-wrap: anywhere; }
.pc-eh-cert-date { font-size: 11.5px; color: var(--muted); }
.pc-eh-cert-acts { display: flex; flex-wrap: wrap; gap: 4px 12px; margin-top: 4px; }
.pc-eh-cert-acts a { font-size: 12px; font-weight: 700; color: var(--eh-blue-text); text-decoration: none; }
.pc-eh-cert-acts a:hover { text-decoration: underline; }
.pc-eh-cert-empty { display: flex; gap: 12px; align-items: center; }
.pc-eh-cert-empty p { margin: 0; font-size: 12.5px; color: var(--muted); line-height: 1.5; }
.pc-eh-cert-empty .pc-eh-thumb { opacity: .55; }

/* the small certificate thumbnail: a landscape sheet with a dark band, two lines and a seal */
.pc-eh-thumb { position: relative; display: block; width: 64px; height: 46px; border-radius: 5px; background: var(--bg); border: 1px solid var(--blue-border); overflow: hidden; }
.pc-eh-thumb-band { position: absolute; left: 0; right: 0; top: 0; height: 11px; background: linear-gradient(90deg, var(--eh-navy), var(--blue)); }
.pc-eh-thumb-l1, .pc-eh-thumb-l2 { position: absolute; left: 10px; height: 3px; border-radius: 2px; background: var(--muted); opacity: .7; }
.pc-eh-thumb-l1 { top: 19px; width: 34px; }
.pc-eh-thumb-l2 { top: 27px; width: 24px; opacity: .45; }
.pc-eh-thumb-seal { position: absolute; right: 7px; bottom: 6px; width: 11px; height: 11px; border-radius: 50%; background: var(--orange); }

/* the locked "Create & sell your own course" card: small and secondary */
.pc-eh-create .pc-author-card { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; margin: 0; padding: 14px 16px; background: var(--card); border: 1px dashed var(--border); border-radius: var(--radius-md); box-shadow: none; }
.pc-eh-create .pc-author-lockicon { display: none; }
.pc-eh-create .pc-author-copy h3 { margin: 0 0 4px; font-size: 13px; color: var(--muted); }
.pc-eh-create .pc-author-copy p { margin: 0; font-size: 12px; line-height: 1.5; color: var(--muted); }
.pc-eh-create .pc-author-cta .pc-mc-btn { min-height: 30px; padding: 0 12px; font-size: 12px; }
.pc-eh-create .pc-author-form { margin-top: 10px; }

/* ── narrow screens ───────────────────────────────────────────────────────── */
@media (max-width: 720px) {
  .pc-eh { --eh-gap: 16px; }
  .pc-eh-hero { flex-direction: column; }
  .pc-eh-hero-cover { flex: 0 0 auto; min-height: 0; height: 112px; }
  .pc-eh-hero-cover svg { width: 40px; height: 40px; }
  .pc-eh-hero-body { padding: 16px; }
  .pc-eh-hero-title { font-size: 20px; }
}
@media (max-width: 480px) {
  .pc-eh-stats { gap: 8px; }
  .pc-eh-stat { flex-direction: column; align-items: flex-start; gap: 6px; padding: 10px; }
  .pc-eh-stat-ico { width: 30px; height: 30px; border-radius: 8px; }
  .pc-eh-stat-ico svg { width: 14px; height: 14px; }
  .pc-eh-stat-n { font-size: 20px; }
  .pc-eh-stat-l { font-size: 11px; line-height: 1.3; }
  .pc-eh-grid { grid-template-columns: 1fr; }
  .pc-eh-hero .pc-eh-btn { flex: 1 1 auto; }
}

@media (prefers-reduced-motion: reduce) {
  .pc-eh-card, .pc-eh-bar-fill, .pc-eh-btn { transition: none; }
  .pc-eh-card:hover { transform: none; }
}
