/* QuadSync shared course cards. Source file: shared/course-ui/course-card.css
   Do not edit the copies in website/ or lms-frontend/. Edit here, then run: python tools/sync_shared.py
   One card look for the LMS home page, the student portal "Courses" page and the website "Courses" page.
   Wrap the heading, the chips and the cards in <div class="qc">.  Add class "qc-dark" for a page that is always dark.
   The dark colours are also used when <html data-theme="dark"> or "night" is set. */
.qc {
  --qc-card: #ffffff; --qc-line: #dbe8f5; --qc-chip-line: #cfe0f2; --qc-text: #0b2230; --qc-muted: #4a5f6d;
  --qc-accent: #1e88e5; --qc-accent-dark: #1565c0; --qc-accent-soft: #e8f3ff;
  --qc-green-bg: #e7f8ee; --qc-green-text: #168a4a; --qc-meta: #243b4a; --qc-sub: #6b7f8d; --qc-old: #9aa9b4;
  --qc-cover: #0b1220; --qc-shadow: 0 6px 24px rgba(11,34,48,.07); --qc-shadow-hover: 0 18px 40px rgba(21,101,192,.16);
  font-family: "Poppins", "Segoe UI", Arial, sans-serif; color: var(--qc-text); text-align: left;
}
html[data-theme="dark"] .qc, html[data-theme="night"] .qc, .qc.qc-dark {
  --qc-card: #172036; --qc-line: #27334f; --qc-chip-line: #27334f; --qc-text: #ffffff; --qc-muted: #b4c0d6;
  --qc-accent: #4f8ff7; --qc-accent-dark: #3b7ae6; --qc-accent-soft: rgba(79,143,247,.18);
  --qc-green-bg: rgba(74,222,128,.14); --qc-green-text: #4ade80; --qc-meta: #d3dbeb; --qc-sub: #9fb0c7; --qc-old: #7d8ba6;
  --qc-shadow: 0 6px 24px rgba(0,0,0,.4); --qc-shadow-hover: 0 18px 40px rgba(21,101,192,.16);
}
.qc, .qc *, .qc *::before, .qc *::after { box-sizing: border-box; }

/* heading and chips */
.qc-head { margin: 0 0 26px; }
.qc-head h2 { margin: 0; font-family: inherit; font-size: clamp(26px, calc(3.2vw / var(--qs-z, 1)), 38px); font-weight: 600; letter-spacing: -.5px; line-height: 1.25; color: var(--qc-text); }
.qc-head h2 span { color: var(--qc-accent); }
.qc-filters { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 30px; justify-content: flex-start; }
.qc-chip { display: inline-flex; align-items: center; gap: 8px; padding: 9px 16px; border-radius: 100px; border: 1px solid var(--qc-chip-line); background: var(--qc-card); color: var(--qc-text); font: inherit; font-size: 14px; font-weight: 600; line-height: 1.4; cursor: pointer; }
.qc-chip span { min-width: 22px; padding: 1px 7px; border-radius: 100px; background: var(--qc-accent-soft); color: var(--qc-accent); font-size: 12px; text-align: center; }
.qc-chip:hover { border-color: var(--qc-accent); }
.qc-chip.active { background: var(--qc-accent); border-color: var(--qc-accent); color: #fff; }
.qc-chip.active span { background: rgba(255,255,255,.25); color: #fff; }
.qc-chip:focus-visible, .qc-card:focus-visible { outline: 3px solid var(--qc-accent); outline-offset: 2px; }

/* cards: the whole card is a link to the course */
.qc-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
@media (max-width: 980px) { .qc-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .qc-grid { grid-template-columns: 1fr; } .qc-filters { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 6px; scrollbar-width: none; } .qc-chip { flex-shrink: 0; } }
.qc-card { display: flex; flex-direction: column; background: var(--qc-card); border: 1px solid var(--qc-line); border-radius: 14px; overflow: hidden; color: inherit; text-decoration: none; box-shadow: var(--qc-shadow); transition: transform .2s, box-shadow .2s, border-color .2s; }
.qc-card:hover { transform: translateY(-3px); border-color: var(--qc-accent); box-shadow: var(--qc-shadow-hover); }
.qc-cover { aspect-ratio: 16/9; background: var(--qc-cover); overflow: hidden; }
.qc-cover img { width: 100%; height: 100%; object-fit: contain; display: block; }
.qc-cover-gen { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; padding: 14px; text-align: center; color: #fff; background: radial-gradient(60% 90% at 100% 0%, rgba(30,136,229,.35), transparent 70%), linear-gradient(135deg, #0b1f3a, #050f1a); }
.qc-cover-gen b { font-size: 19px; line-height: 1.25; }
.qc-cover-gen em { font-style: normal; font-size: 14px; color: #4dabff; }
.qc-cover-gen span { margin-top: 6px; font-size: 12px; opacity: .8; }
.qc-body { display: flex; flex-direction: column; flex: 1; padding: 16px 18px 18px; }
.qc-tags { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.qc-tag { padding: 5px 12px; border-radius: 6px; background: var(--qc-accent-soft); color: var(--qc-accent); font-size: 12px; font-weight: 700; }
.qc-off { padding: 4px 10px; border-radius: 6px; background: var(--qc-green-bg); color: var(--qc-green-text); font-size: 12px; font-weight: 700; text-align: right; }
.qc-card h3 { margin: 14px 0 0; font-family: inherit; font-size: 19px; font-weight: 600; line-height: 1.3; letter-spacing: 0; color: var(--qc-text); }
.qc-accent { display: block; margin-top: 2px; color: var(--qc-accent); }
.qc-short { margin: 8px 0 0; font-size: 14px; line-height: 1.55; color: var(--qc-muted); }
.qc-meta { margin: 12px 0 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 13px; font-weight: 500; color: var(--qc-meta); }
.qc-meta li { display: inline-flex; align-items: center; }
.qc-meta svg { width: 14px; height: 14px; flex: none; margin-right: 6px; fill: none; stroke: var(--qc-accent); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.qc-foot { margin-top: auto; padding-top: 16px; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.qc-pbox small { display: block; font-size: 12px; font-weight: 600; color: var(--qc-sub); }
.qc-price { display: flex; align-items: baseline; flex-wrap: nowrap; gap: 8px; }
.qc-price strong { font-size: 24px; font-weight: 700; color: var(--qc-text); }
.qc-price s { color: var(--qc-old); font-size: 14px; }
.qc-more { padding: 10px 18px; border-radius: 6px; background: var(--qc-accent); color: #fff; font-size: 14px; font-weight: 700; border-bottom: 3px solid var(--qc-accent-dark); white-space: nowrap; }
.qc-card:hover .qc-more { background: var(--qc-accent-dark); }
.qc-empty { padding: 50px 16px; text-align: center; color: var(--qc-muted); font-size: 16px; background: var(--qc-card); border: 1px dashed var(--qc-line); border-radius: 14px; }
@media (prefers-reduced-motion: reduce) { .qc-card { transition: none; } .qc-card:hover { transform: none; } }
