/* A4QCloud theme — built on Bootstrap 5, kept intentionally small.
   Brand colors taken from the official A4Q logo. */
:root {
  --a4q-blue: #1c75bc;
  --a4q-blue-dark: #155a91;
  --a4q-light-blue: #42a9ce;
  --a4q-dark: #414042;
}

body { color: var(--a4q-dark); }

/* Brand bits */
.a4q-brand-text { color: var(--a4q-blue); letter-spacing: .5px; }
.a4q-navbar { box-shadow: 0 2px 8px rgba(16,42,67,.06); }
/* Member feedback floating action button (portal pages). */
.a4q-feedback-fab {
  position: fixed; right: 1.25rem; bottom: 1.25rem; z-index: 1045;
  border-radius: 2rem; padding: .55rem 1.1rem;
}
@media (max-width: 575.98px) { .a4q-feedback-fab { right: 1rem; bottom: 1rem; } }
/* Keep a long user name from forcing the navbar to wrap: clip with an ellipsis on desktop. */
@media (min-width: 992px) {
  .a4q-nav-username { display: inline-block; max-width: 11rem; vertical-align: middle; }
  /* When a link is squeezed onto two lines, center the icon above its label. */
  .a4q-navbar .nav-link { text-align: center; }
}

/* Primary button in A4Q blue */
.btn-a4q {
  background-color: var(--a4q-blue);
  border-color: var(--a4q-blue);
  color: #fff;
}
.btn-a4q:hover, .btn-a4q:focus {
  background-color: var(--a4q-blue-dark);
  border-color: var(--a4q-blue-dark);
  color: #fff;
}
.text-a4q { color: var(--a4q-blue) !important; }
.bg-a4q { background-color: var(--a4q-blue) !important; }

/* Cards: boxed, soft */
.card { border: 1px solid rgba(0,0,0,.06); border-radius: .75rem; }
.card-hover { transition: transform .12s ease, box-shadow .12s ease; }
.card-hover:hover { transform: translateY(-2px); box-shadow: 0 .5rem 1.5rem rgba(0,0,0,.08); }

/* Material card description: a fixed 3-line block so every card is the same
   height regardless of how long the description is. When the text overflows,
   a "More" link appears (over a soft fade) to open the full text in a modal. */
.material-desc { position: relative; height: 3.9rem; overflow: hidden; }
.material-desc .desc-text {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  line-height: 1.3rem;       /* 3 lines = 3.9rem, matching the wrapper height */
  overflow: hidden;
  margin: 0;
}
.material-desc .desc-more {
  position: absolute; right: 0; bottom: 0;
  border: 0; cursor: pointer;
  font-size: .75rem; line-height: 1.2rem; font-weight: 500;
  color: var(--a4q-blue);
  padding: 0 .1rem 0 1.75rem;
  /* Fade the last clamped line into the card so the link doesn't sit on text. */
  background: linear-gradient(90deg, rgba(255,255,255,0), #fff 1.25rem);
}
.material-desc .desc-more:hover { text-decoration: underline; }

/* Hero */
.a4q-hero {
  background: linear-gradient(135deg, var(--a4q-blue) 0%, var(--a4q-light-blue) 100%);
  color: #fff;
}

/* Footer */
.a4q-footer { background-color: var(--a4q-dark); }
.a4q-footer a { color: rgba(255,255,255,.75); text-decoration: none; }
.a4q-footer a:hover { color: #fff; }

/* Version / file rows */
.version-card { border-left: 4px solid var(--a4q-light-blue); }
.version-card.is-latest { border-left-color: var(--a4q-blue); }
.version-card.is-archived { opacity: .7; }
.file-row { border-bottom: 1px solid rgba(0,0,0,.05); }
.file-row:last-child { border-bottom: none; }
/* `transform` is ignored on display:inline elements, and <i class="bi"> is inline
   by default (Bootstrap Icons only sets ::before to inline-block) — so the chevron
   must be inline-block for the rotation to take effect. */
/* Sortable table headers (e.g. the Members directory). */
.sort-th { cursor: pointer; user-select: none; white-space: nowrap; }
.sort-th:hover { background-color: #eef3f8; }
.sort-th .sort-ic { margin-left: .15rem; }

.revision-toggle { cursor: pointer; }
.revision-toggle .toggle-chevron { display: inline-block; transition: transform .15s ease; }
.revision-toggle:not(.collapsed) .toggle-chevron { transform: rotate(90deg); }

/* Folder tree (revision files) */
.folder-row { border-bottom: 1px solid rgba(0,0,0,.05); cursor: pointer; user-select: none; }
.folder-row:hover { background-color: #f6f9fc; }
.folder-row .tree-chevron { display: inline-block; transition: transform .15s ease; }
.folder-row:not(.collapsed) .tree-chevron { transform: rotate(90deg); }

/* File-type icon colors */
.file-icon-pdf     { color: #e53935; }  /* red */
.file-icon-word    { color: #2b579a; }  /* word blue */
.file-icon-slides  { color: #d24726; }  /* powerpoint orange */
.file-icon-sheet   { color: #217346; }  /* excel green */
.file-icon-image   { color: #00897b; }  /* teal */
.file-icon-text    { color: #607d8b; }  /* slate */
.file-icon-zip     { color: #f9a825; }  /* amber */
.file-icon-default { color: #90a4ae; }  /* grey */

/* Analytics */
.chart-box { position: relative; height: 260px; }
.chart-box-sm { position: relative; height: 220px; }
.heatmap { border-collapse: separate; border-spacing: 2px; width: 100%; }
.heatmap td { width: 3.6%; height: 16px; border-radius: 3px; background: #eef2f6; }
.heatmap th.hm-d { font-size: .72rem; font-weight: 600; color: #6c757d; text-align: right; padding-right: 6px; white-space: nowrap; }
.heatmap th.hm-h { font-size: .65rem; color: #adb5bd; text-align: center; font-weight: 500; }

/* Drag & drop upload zone */
.dropzone {
  border: 2px dashed #cfd8e3; border-radius: .75rem;
  padding: 1.75rem; text-align: center; color: #6c757d; cursor: pointer;
  transition: background-color .12s ease, border-color .12s ease;
}
.dropzone.dragover { background-color: #eef5fb; border-color: var(--a4q-blue); color: var(--a4q-blue); }

/* Login card */
.auth-wrap { max-width: 420px; margin: 3rem auto; }

/* Category color swatch (management list) */
.cat-swatch {
  display: inline-block; width: 1.75rem; height: 1.75rem;
  border-radius: .5rem; border: 1px solid rgba(0,0,0,.12); flex-shrink: 0;
}
.min-w-0 { min-width: 0; }

/* Drag-to-reorder rows on the categories page */
.cat-row .cat-drag-handle { cursor: grab; }
.cat-row.dragging { opacity: .5; }
.cat-row.dragging .card { box-shadow: 0 .5rem 1.5rem rgba(0,0,0,.12); }

/* Elevate the card whose dropdown is open so it paints above sibling cards */
#categoryGrid .cat-row:has(.dropdown.show) .card { z-index: 10; }

/* Category picker chips (new/edit material modal) */
.cat-chip {
  border: 1.5px solid var(--chip, #ced4da); color: var(--chip, #495057);
  background: #fff; border-radius: 2rem; padding: .25rem .75rem;
  font-size: .85rem; line-height: 1.2; cursor: pointer;
  transition: background-color .12s ease, color .12s ease;
}
.cat-chip:hover { background: color-mix(in srgb, var(--chip) 12%, #fff); }
.cat-chip.selected { background: var(--chip); color: var(--chip-text, #fff); border-color: var(--chip); }

/* Traceability matrix (organizations × materials) */
.tm-wrap { overflow: auto; max-height: calc(100vh - 280px); }
.tm-table { border-collapse: separate; border-spacing: 0; margin-bottom: 0; }
.tm-table th, .tm-table td {
  border-bottom: 1px solid rgba(0,0,0,.06); padding: .5rem .6rem; vertical-align: middle;
}
.tm-table thead th { position: sticky; top: 0; z-index: 2; background: #fff; vertical-align: bottom; }
.tm-org-col {
  position: sticky; left: 0; z-index: 1; background: #fff;
  min-width: 240px; max-width: 300px; box-shadow: 1px 0 0 rgba(0,0,0,.08);
}
.tm-table thead th.tm-org-col { z-index: 4; }
.tm-table tbody tr:hover td, .tm-table tbody tr:hover th.tm-org-col { background: #f6f9fc; }
.tm-sortable { cursor: pointer; user-select: none; }
.tm-sortable:hover { background: #eef5fb; }
.tm-mat-col { min-width: 78px; max-width: 120px; }
/* Vertical divider between syllabus (material) columns */
.tm-col-div { border-left: 1px solid rgba(0,0,0,.12); }
.tm-no  { color: #dc8b8b; text-align: center; }
.tm-flags { display: flex; flex-wrap: wrap; gap: 2px; justify-content: center; align-items: center; }
.tm-flag {
  font-size: 28px; line-height: 1; letter-spacing: 0;
  font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif;
}
.tm-flag-code {
  display: inline-block; font-size: .58rem; font-weight: 600; color: #475569;
  background: #eef2f6; border: 1px solid rgba(0,0,0,.1); border-radius: 3px;
  padding: 0 2px; line-height: 1.3; text-transform: uppercase;
}

/* =========================================================================
   LANDING PAGE (marketing) — prefix .lp-
   ========================================================================= */

/* Scroll reveal */
[data-reveal] { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s ease; }
[data-reveal].is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  [data-reveal] { opacity: 1 !important; transform: none !important; transition: none; }
}

/* Shared accent backgrounds for icons */
.lp-ico-blue   { background: linear-gradient(135deg, #1c75bc, #42a9ce); }
.lp-ico-teal   { background: linear-gradient(135deg, #0d9488, #2dd4bf); }
.lp-ico-amber  { background: linear-gradient(135deg, #d97706, #fbbf24); }
.lp-ico-violet { background: linear-gradient(135deg, #6d28d9, #a78bfa); }
.lp-ico-rose   { background: linear-gradient(135deg, #be123c, #fb7185); }
.lp-ico-slate  { background: linear-gradient(135deg, #334155, #64748b); }

/* ---------- Hero ---------- */
.lp-hero {
  position: relative;
  background:
    radial-gradient(1200px 500px at 80% -10%, rgba(66,169,206,.45), transparent 60%),
    linear-gradient(135deg, #114a78 0%, var(--a4q-blue) 45%, #2b96c4 100%);
  overflow: hidden;
  isolation: isolate;
}
.lp-hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background-image:
    radial-gradient(rgba(255,255,255,.10) 1px, transparent 1px);
  background-size: 22px 22px;
  mask-image: linear-gradient(180deg, #000 0%, transparent 85%);
}
.lp-hero-blob {
  position: absolute; border-radius: 50%; filter: blur(60px); opacity: .5; z-index: -1;
  animation: lp-float 9s ease-in-out infinite;
}
.lp-hero-blob-1 { width: 360px; height: 360px; top: -80px; right: -60px; background: #5ec5e6; }
.lp-hero-blob-2 { width: 300px; height: 300px; bottom: -120px; left: -40px; background: #1e88e5; animation-delay: -3s; }
@keyframes lp-float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-22px); } }

.lp-eyebrow {
  display: inline-flex; align-items: center; gap: .45rem;
  background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.28);
  color: #fff; font-weight: 600; font-size: .82rem; letter-spacing: .3px;
  padding: .4rem .85rem; border-radius: 2rem; backdrop-filter: blur(6px);
}
.lp-hero-title {
  font-weight: 800; line-height: 1.08; letter-spacing: -.5px;
  font-size: clamp(2.1rem, 4.4vw, 3.4rem);
}
.lp-grad-text {
  background: linear-gradient(90deg, #8fe3ff 0%, #ffffff 72%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.lp-hero-lead { font-size: 1.12rem; line-height: 1.65; color: rgba(255,255,255,.88); max-width: 36rem; }

.btn-lp-primary {
  background: #fff; color: var(--a4q-blue); font-weight: 700; border: none;
  border-radius: .7rem; padding: .8rem 1.5rem; box-shadow: 0 .6rem 1.4rem rgba(0,0,0,.18);
  transition: transform .12s ease, box-shadow .12s ease;
}
/* Keep the white background on hover — Bootstrap's `.btn:hover` (transparent) is
   more specific than `.btn-lp-primary`, so without this the button goes see-through
   (blue text on the blue hero = unreadable). */
.btn-lp-primary:hover, .btn-lp-primary:focus {
  background: #fff; color: var(--a4q-blue-dark);
  transform: translateY(-2px); box-shadow: 0 .9rem 1.8rem rgba(0,0,0,.25);
}
.btn-lp-ghost {
  background: rgba(255,255,255,.08); color: #fff; font-weight: 600;
  border: 1.5px solid rgba(255,255,255,.45); border-radius: .7rem; padding: .8rem 1.4rem;
  transition: background-color .12s ease, border-color .12s ease;
}
.btn-lp-ghost:hover { background: rgba(255,255,255,.18); color: #fff; border-color: #fff; }

.lp-hero-trust { display: flex; align-items: center; gap: .75rem; color: rgba(255,255,255,.85); }
.lp-avatars { display: inline-flex; }
.lp-avatars span {
  width: 34px; height: 34px; margin-left: -8px; border-radius: 50%;
  background: rgba(255,255,255,.18); border: 2px solid rgba(255,255,255,.55);
  display: grid; place-items: center; color: #fff; font-size: .9rem;
}
.lp-avatars span:first-child { margin-left: 0; }

.lp-hero-wave { position: absolute; left: 0; right: 0; bottom: -1px; line-height: 0; z-index: -1; }
.lp-hero-wave svg { width: 100%; height: 64px; display: block; }
.lp-hero-wave path { fill: var(--bs-tertiary-bg, #f8f9fa); }

/* ---------- Hero product mockup ---------- */
.lp-mockup { position: relative; max-width: 480px; margin: 0 auto; }
.lp-window {
  background: #fff; border-radius: 1rem; box-shadow: 0 1.5rem 3.5rem rgba(8,40,70,.35);
  overflow: hidden; border: 1px solid rgba(255,255,255,.6);
  animation: lp-rise 1s ease both;
}
@keyframes lp-rise { from { opacity: 0; transform: translateY(26px) scale(.98); } to { opacity: 1; transform: none; } }
.lp-window-bar {
  display: flex; align-items: center; gap: 6px;
  padding: .7rem .9rem; background: #f1f4f8; border-bottom: 1px solid rgba(0,0,0,.06);
}
.lp-window-bar > span { width: 11px; height: 11px; border-radius: 50%; background: #d6dde6; }
.lp-window-bar > span:nth-child(1) { background: #ff5f57; }
.lp-window-bar > span:nth-child(2) { background: #febc2e; }
.lp-window-bar > span:nth-child(3) { background: #28c840; }
.lp-window-url {
  margin-left: auto; font-size: .72rem; color: #6b7785; background: #fff;
  border: 1px solid rgba(0,0,0,.07); border-radius: 2rem; padding: .15rem .6rem;
}
.lp-window-body { padding: 1rem; display: grid; gap: .65rem; }
.lp-mat {
  display: flex; align-items: center; gap: .75rem;
  border: 1px solid rgba(0,0,0,.07); border-radius: .7rem; padding: .6rem .75rem;
  background: #fff; transition: transform .15s ease, box-shadow .15s ease;
}
.lp-mat:hover { transform: translateX(3px); box-shadow: 0 .4rem 1rem rgba(0,0,0,.06); }
.lp-mat-ico { width: 38px; height: 38px; border-radius: .55rem; display: grid; place-items: center; color: #fff; font-size: 1.05rem; flex-shrink: 0; }
.lp-mat-meta { min-width: 0; flex: 1; }
.lp-mat-title { font-weight: 600; font-size: .9rem; color: #1f2937; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lp-mat-sub { font-size: .74rem; color: #8a95a3; }
.lp-mat-badge {
  display: inline-flex; align-items: center; gap: .25rem; flex-shrink: 0;
  font-size: .68rem; font-weight: 700; color: #0d9488;
  background: rgba(13,148,136,.1); border-radius: 2rem; padding: .2rem .55rem;
}
.lp-window-cta {
  margin-top: .15rem; text-align: center; font-weight: 600; font-size: .85rem; color: #fff;
  background: linear-gradient(135deg, var(--a4q-blue), var(--a4q-light-blue));
  border-radius: .7rem; padding: .65rem;
}
.lp-seal {
  position: absolute; top: -22px; right: -10px; z-index: 3;
  width: 92px; height: 92px; border-radius: 50%; display: grid; place-items: center;
  text-align: center; color: #fff; line-height: 1; padding: 6px; overflow: hidden;
  background: linear-gradient(135deg, #0d9488, #2dd4bf);
  box-shadow: 0 .6rem 1.4rem rgba(13,148,136,.45);
  animation: lp-spin-soft 8s ease-in-out infinite;
}
.lp-seal i { font-size: 1.35rem; }
.lp-seal small { display: block; font-size: .46rem; font-weight: 800; letter-spacing: .2px; margin-top: 3px; white-space: nowrap; }
@keyframes lp-spin-soft { 0%,100% { transform: rotate(-8deg); } 50% { transform: rotate(8deg); } }

.lp-float-card {
  position: absolute; display: flex; align-items: center; gap: .55rem;
  background: #fff; border-radius: .7rem; padding: .55rem .8rem;
  box-shadow: 0 .8rem 1.8rem rgba(8,40,70,.18); border: 1px solid rgba(0,0,0,.05);
  animation: lp-float 6s ease-in-out infinite;
}
.lp-float-card i { font-size: 1.3rem; }
.lp-float-card strong { display: block; font-size: .8rem; color: #1f2937; line-height: 1.1; }
.lp-float-card span { font-size: .68rem; color: #8a95a3; }
.lp-float-card-1 { left: -28px; top: 38%; animation-delay: -1s; }
.lp-float-card-2 { right: -24px; bottom: 30px; animation-delay: -3.5s; }
@media (max-width: 575.98px) { .lp-float-card { display: none; } }

/* ---------- Trust strip ---------- */
.lp-trust-strip {
  margin-top: -34px; position: relative; z-index: 5;
  background: #fff; border: 1px solid rgba(0,0,0,.06); border-radius: 1rem;
  box-shadow: 0 1rem 2.5rem rgba(8,40,70,.08);
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; padding: 1.25rem 1.5rem;
}
.lp-trust-item { display: flex; align-items: center; gap: .7rem; }
.lp-trust-item i { font-size: 1.6rem; color: var(--a4q-blue); }
.lp-trust-item strong { display: block; font-size: .92rem; color: #1f2937; }
.lp-trust-item span { font-size: .78rem; color: #8a95a3; }
@media (max-width: 767.98px) { .lp-trust-strip { grid-template-columns: repeat(2, 1fr); } }

/* ---------- Section headings ---------- */
.lp-section-head { max-width: 640px; }
.lp-kicker {
  display: inline-block; text-transform: uppercase; letter-spacing: 1.5px;
  font-size: .76rem; font-weight: 700; color: var(--a4q-blue);
  background: rgba(28,117,188,.08); padding: .3rem .7rem; border-radius: 2rem;
}
.lp-section-title { font-weight: 800; letter-spacing: -.4px; margin-top: .8rem; color: #1f2937; font-size: clamp(1.6rem, 3vw, 2.3rem); }
.lp-section-sub { color: #6b7785; font-size: 1.05rem; line-height: 1.6; margin: .8rem auto 0; max-width: 560px; }

/* ---------- Feature cards ---------- */
.lp-feature {
  background: #fff; border: 1px solid rgba(0,0,0,.06); border-radius: 1rem; padding: 1.6rem;
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.lp-feature:hover { transform: translateY(-4px); box-shadow: 0 1rem 2.2rem rgba(8,40,70,.10); border-color: rgba(28,117,188,.25); }
.lp-feature-ico {
  width: 52px; height: 52px; border-radius: .85rem; display: grid; place-items: center;
  color: #fff; font-size: 1.5rem; margin-bottom: 1rem; box-shadow: 0 .5rem 1rem rgba(8,40,70,.15);
}
.lp-feature h5 { font-weight: 700; color: #1f2937; }
.lp-feature p { color: #6b7785; font-size: .92rem; margin-bottom: 0; }

/* ---------- Stats band ---------- */
.lp-stats-band {
  background: linear-gradient(135deg, var(--a4q-blue), #114a78);
  color: #fff; padding: 3rem 0; position: relative; overflow: hidden;
}
.lp-stats-band::before {
  content: ""; position: absolute; inset: 0;
  background-image: radial-gradient(rgba(255,255,255,.10) 1px, transparent 1px);
  background-size: 20px 20px; opacity: .6;
}
.lp-stat { font-weight: 800; line-height: 1; display: inline-flex; align-items: baseline; }
.lp-stat-num { font-size: clamp(2.2rem, 5vw, 3rem); }
.lp-stat-suffix { font-size: 1.4rem; margin-left: .15rem; color: #ffe082; font-weight: 700; }
.lp-stat-label { margin-top: .5rem; color: rgba(255,255,255,.82); font-size: .9rem; }

/* ---------- Accreditation certificate visual ---------- */
.lp-cert {
  position: relative; background: #fff; border-radius: 1.1rem; padding: 2.2rem 2rem 1.6rem;
  border: 1px solid rgba(0,0,0,.06); box-shadow: 0 1.2rem 3rem rgba(8,40,70,.14);
  max-width: 460px; margin: 0 auto;
  background-image: linear-gradient(#fff, #fff), linear-gradient(135deg, var(--a4q-blue), #2dd4bf);
  background-origin: border-box; background-clip: padding-box, border-box; border: 2px solid transparent;
}
.lp-cert-seal {
  position: absolute; top: -26px; left: 50%; transform: translateX(-50%);
  width: 60px; height: 60px; border-radius: 50%; display: grid; place-items: center;
  background: linear-gradient(135deg, #0d9488, #2dd4bf); color: #fff; font-size: 1.7rem;
  box-shadow: 0 .5rem 1.2rem rgba(13,148,136,.4);
}
.lp-cert-ribbon {
  text-align: center; margin-top: 1.2rem; font-size: .72rem; font-weight: 800;
  letter-spacing: 2px; color: var(--a4q-blue);
}
.lp-cert-name { text-align: center; font-weight: 800; color: #1f2937; margin-top: .4rem; }
.lp-cert-line { text-align: center; color: #6b7785; font-size: .88rem; }
.lp-cert-row { display: flex; justify-content: space-around; gap: .5rem; margin: 1.2rem 0; padding: 1rem 0; border-top: 1px dashed rgba(0,0,0,.12); border-bottom: 1px dashed rgba(0,0,0,.12); text-align: center; }
.lp-cert-row span { display: block; font-size: .66rem; text-transform: uppercase; letter-spacing: .5px; color: #9aa4b2; }
.lp-cert-row strong { font-size: .9rem; color: #1f2937; }
.lp-cert-sign { display: flex; align-items: center; gap: .6rem; justify-content: center; }
.lp-cert-sig { font-family: "Segoe Script", "Brush Script MT", cursive; font-size: 1.5rem; color: var(--a4q-blue); font-weight: 700; }
.lp-cert-sign span { font-size: .76rem; color: #9aa4b2; }

/* ---------- Checklist ---------- */
.lp-checklist { list-style: none; padding: 0; margin: 1.4rem 0 0; }
.lp-checklist li { display: flex; align-items: flex-start; gap: .6rem; padding: .45rem 0; color: #374151; font-size: .98rem; }
.lp-checklist i { color: #0d9488; font-size: 1.15rem; flex-shrink: 0; margin-top: .1rem; }

/* ---------- Steps ---------- */
.lp-steps-wrap { background: #fff; border-top: 1px solid rgba(0,0,0,.05); border-bottom: 1px solid rgba(0,0,0,.05); }
.lp-step {
  position: relative; background: var(--bs-tertiary-bg, #f8f9fa); border-radius: 1rem;
  padding: 2rem 1.5rem 1.5rem; text-align: center; border: 1px solid rgba(0,0,0,.05);
  transition: transform .15s ease, box-shadow .15s ease;
}
.lp-step:hover { transform: translateY(-4px); box-shadow: 0 1rem 2.2rem rgba(8,40,70,.10); }
.lp-step-num {
  position: absolute; top: -18px; left: 50%; transform: translateX(-50%);
  width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center;
  background: linear-gradient(135deg, var(--a4q-blue), var(--a4q-light-blue));
  color: #fff; font-weight: 800; box-shadow: 0 .4rem 1rem rgba(28,117,188,.35);
}
.lp-step-ico { font-size: 2.2rem; color: var(--a4q-blue); margin-top: .8rem; }
.lp-step h5 { font-weight: 700; color: #1f2937; margin-top: .6rem; }
.lp-step p { color: #6b7785; font-size: .9rem; margin-bottom: 0; }

/* ---------- Final CTA ---------- */
.lp-cta {
  position: relative; overflow: hidden; text-align: center; color: #fff;
  background: linear-gradient(135deg, #114a78, var(--a4q-blue) 55%, #2b96c4);
  border-radius: 1.5rem; padding: 3.5rem 1.5rem;
  box-shadow: 0 1.5rem 3.5rem rgba(8,40,70,.25);
}
.lp-cta-blob {
  position: absolute; width: 420px; height: 420px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,.18), transparent 70%);
  top: -160px; right: -120px;
}
.lp-cta-title { font-weight: 800; letter-spacing: -.4px; font-size: clamp(1.6rem, 3.4vw, 2.4rem); }
.lp-cta-sub { color: rgba(255,255,255,.88); max-width: 540px; margin: .8rem auto 0; font-size: 1.05rem; }

/* ============================ PUBLIC CATALOG ============================ */
.cat-hero {
  position: relative; overflow: hidden;
  background: linear-gradient(180deg, #f3f8fd 0%, var(--bs-body-bg, #fff) 100%);
  padding: 3rem 0 2rem;
}
.cat-hero-blob {
  position: absolute; width: 460px; height: 460px; border-radius: 50%;
  top: -240px; left: 50%; transform: translateX(-50%);
  background: radial-gradient(circle, rgba(28,117,188,.12), transparent 70%);
  pointer-events: none;
}
.cat-hero-title { font-weight: 800; letter-spacing: -.6px; font-size: clamp(1.8rem, 4vw, 2.7rem); }
/* Readable blue highlight for the light catalog hero (the gold lp-grad-text is for
   the dark landing hero and is unreadable on white). */
.cat-grad-text {
  color: var(--a4q-blue);
  background: linear-gradient(90deg, var(--a4q-blue), var(--a4q-light-blue));
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.cat-hero-lead { color: #5b6675; font-size: 1.05rem; }

/* Prominent search pill */
.cat-search { position: relative; max-width: 560px; margin: 0 auto; }
.cat-search i { position: absolute; left: 1.1rem; top: 50%; transform: translateY(-50%); color: #9aa7b4; }
.cat-search .form-control {
  height: 3.25rem; border-radius: 2rem; padding-left: 2.9rem; font-size: 1.05rem;
  box-shadow: 0 .5rem 1.5rem rgba(28,117,188,.10); border-color: #dbe6f1;
}
.cat-search .form-control:focus { box-shadow: 0 .5rem 1.6rem rgba(28,117,188,.20); }

/* Category filter chips */
.cat-chips { display: flex; flex-wrap: wrap; gap: .4rem; }
.cat-chip {
  border: 1px solid #dbe1e8; background: #fff; color: #44505e;
  border-radius: 2rem; padding: .3rem .85rem; font-size: .85rem; font-weight: 500;
  cursor: pointer; transition: all .12s ease; white-space: nowrap;
}
.cat-chip:hover { border-color: var(--chip, var(--a4q-blue)); color: var(--chip, var(--a4q-blue)); }
.cat-chip.selected {
  background: var(--chip, var(--a4q-blue)); color: var(--chip-text, #fff);
  border-color: var(--chip, var(--a4q-blue));
}

/* Catalog card */
.cat-card {
  position: relative; display: flex; flex-direction: column; height: 100%;
  background: #fff; border: 1px solid rgba(0,0,0,.07); border-radius: .85rem;
  overflow: hidden; text-decoration: none; color: inherit;
}
.cat-card .cat-card-accent {
  display: block; height: 5px; background: var(--accent, var(--a4q-blue));
}
.cat-card-body { display: flex; flex-direction: column; flex-grow: 1; padding: 1rem 1.1rem 1.1rem; }
.cat-title {
  font-weight: 700; font-size: 1.06rem; letter-spacing: -.2px; color: #1f2a37;
  margin: 0 0 .35rem; line-height: 1.25;
}
.cat-card:hover .cat-title { color: var(--accent, var(--a4q-blue)); }
.cat-desc { margin-bottom: .6rem; }
.cat-flags { display: flex; flex-wrap: wrap; gap: .3rem; min-height: 20px; margin-bottom: .75rem; }
.cat-flag { width: 24px; height: 18px; border-radius: 3px; border: 1px solid rgba(0,0,0,.1); object-fit: cover; }
.cat-card-foot {
  margin-top: auto; display: flex; align-items: center; justify-content: space-between;
  gap: .5rem; padding-top: .6rem; border-top: 1px solid rgba(0,0,0,.05);
}
.cat-more { font-size: .85rem; font-weight: 600; color: var(--accent, var(--a4q-blue)); white-space: nowrap; }
.cat-card:hover .cat-more i { transform: translateX(3px); }
.cat-more i { transition: transform .12s ease; }

/* Accredited seal */
.cat-seal { color: #1c9d5c; font-size: 1.1rem; line-height: 1; flex-shrink: 0; }
.cat-seal-lg {
  display: inline-flex; align-items: center; font-size: .8rem; font-weight: 600;
  color: #1c9d5c; background: rgba(28,157,92,.1); border-radius: 2rem; padding: .25rem .7rem;
}

/* Access-state pills */
.cat-acc {
  display: inline-flex; align-items: center; font-size: .75rem; font-weight: 600;
  border-radius: 2rem; padding: .2rem .6rem; white-space: nowrap;
}
.cat-acc-have    { color: #1c7f4b; background: rgba(28,157,92,.12); }
.cat-acc-partial { color: #155a91; background: rgba(28,117,188,.12); }
.cat-acc-locked  { color: #6c757d; background: rgba(108,117,125,.12); }

/* Detail page */
.cat-detail-head {
  border-left: 4px solid var(--accent, var(--a4q-blue));
  padding: .25rem 0 .25rem 1rem;
}
.cat-editions { display: flex; flex-direction: column; gap: .25rem; }
.cat-edition {
  display: flex; align-items: center; gap: .5rem;
  padding: .55rem .25rem; border-bottom: 1px solid rgba(0,0,0,.05);
}
.cat-edition:last-child { border-bottom: none; }
.cat-cta-card { border: 1px solid #dbe6f1; box-shadow: 0 .5rem 1.5rem rgba(28,117,188,.08); }
.cat-foot-cta {
  background: #f3f8fd; border: 1px solid #e3eef8; border-radius: 1rem; padding: 2rem 1rem;
}


/* ---------------------------------------------------------- sync control panel
   The B2B master switch on the Sync activity page. The whole card turns red-tinted
   while processing is stopped, so the state is unmistakable from across the room —
   this is the control someone reaches for when data processing must halt now. */
.sync-control { border-left: 4px solid #1a9d52; }
.sync-control.is-paused {
  border-left-color: #c0392b;
  background: rgba(192, 57, 43, .04);
}
.sync-control .font-monospace { font-variant-numeric: tabular-nums; letter-spacing: .02em; }


/* -------------------------------------------------------------- package editor
   Composing a package is a full page, not a dialog: a real catalogue runs to
   dozens of syllabuses and needs room, filters and a running summary. Two pieces
   of furniture make that workable on a long list — an action bar that keeps Save
   reachable, and a summary column that stays put while you scroll the picker.
   Both stick *below* the navbar, whose height JS measures into --a4q-nav-h. */
.a4q-editor-bar {
  position: sticky; top: var(--a4q-nav-h, 60px); z-index: 1019;
  margin-top: -1.5rem;            /* sit flush under the navbar, above <main>'s padding */
  box-shadow: 0 .125rem .25rem rgba(0,0,0,.04);
}
@media (min-width: 1200px) {
  .a4q-editor-summary { position: sticky; top: calc(var(--a4q-nav-h, 60px) + 4rem); }
}
/* Folded syllabus rows read as one line, so a long list stays scannable. */
.pick-material .pick-head:hover { background: rgba(28,117,188,.04); }
.pick-material .btn-close-sm { width: .5em; height: .5em; padding: .25em; opacity: .6; }
.pick-material .btn-close-sm:hover { opacity: 1; }
.a4q-editor-summary .btn-close-sm { width: .5em; height: .5em; padding: .25em; opacity: .6; }
.a4q-editor-summary .btn-close-sm:hover { opacity: 1; }


/* ------------------------------------------------------------ checkbox visibility
   Bootstrap's default is `1px solid rgba(0,0,0,.25)` — a hairline that is genuinely
   hard to see, especially against the pale card backgrounds the admin lists use.
   Nearly every tick box in this app records a decision (access grants, package
   contents, provider tags, list filters), so an *unticked* box has to read as
   clearly as a ticked one. Site-wide on purpose: portal, admin and public pages.

   Deliberately kept: the brand fill when checked, and a visibly weaker — but still
   outlined — disabled state, because package-granted editions render as disabled
   checkboxes and still have to be legible. */
.form-check-input,
input[type="checkbox"]:not(.form-check-input),
input[type="radio"]:not(.form-check-input) {
  border: 2px solid #6f7c8a;
  background-color: #fff;
}
.form-check-input:hover:not(:disabled):not(:checked) { border-color: #414042; }
.form-check-input:checked { border-color: #1c75bc; }
.form-check-input:indeterminate { border-color: #1c75bc; }
.form-check-input:focus {
  border-color: #1c75bc;
  box-shadow: 0 0 0 .2rem rgba(28, 117, 188, .3);
}
/* Bootstrap fades disabled inputs to .5, which erased the outline again. */
.form-check-input:disabled { opacity: .8; border-color: #8a95a1; }
.form-check-input:disabled:checked { opacity: .85; border-color: #4a90c4; }

/* Package pills in the traceability matrix — colour-coded like provider tags, so the
   box icon is what tells the two apart at a glance. Links, hence the hover lift. */
.tm-pkg { font-weight: 600; }
a.tm-pkg:hover { filter: brightness(1.08); }
