/* ============================================================
   MOTIVATION.SE — Wagtail-Specific Overrides
   Handles: admin bar spacing, StreamField blocks,
            page-type body classes, member paywall gate.

   Load order in base.html:
     1. motivation.css   (= motivation-se.css renamed)
     2. richtext.css
     3. categories.css
     4. wagtail-overrides.css  ← this file
   ============================================================ */


/* ── Wagtail admin bar spacing ────────────────────────────── */
body.wagtail-userbar-enabled .site-header {
  top: 60px;   /* offset below the Wagtail editor bar */
}

/* ── StreamField: common block wrapper ────────────────────── */
.streamfield > * + * {
  margin-top: 2rem;
}

/* ── StreamField: image block ─────────────────────────────── */
.block-image {
  margin: 2rem 0;
}

.block-image img {
  width: 100%;
  height: auto;
  border-radius: 10px;
  display: block;
}

.block-image figcaption {
  font-size: 0.78rem;
  color: var(--muted);
  font-style: italic;
  margin-top: 6px;
  padding-left: 4px;
}

/* ── StreamField: quote block ─────────────────────────────── */
.block-quote {
  margin: 2rem 0;
  padding: 24px 28px;
  background: var(--sidebar-dark);
  border-radius: 10px;
  position: relative;
}

.block-quote::before {
  content: '\201C';
  font-family: 'Archivo', sans-serif;
  font-size: 5rem;
  font-weight: 800;
  color: var(--accent);
  opacity: 0.4;
  position: absolute;
  top: -10px;
  left: 20px;
  line-height: 1;
}

.block-quote blockquote {
  font-family: 'Archivo', sans-serif;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--white);
  line-height: 1.5;
  font-style: italic;
  border: none;
  background: none;
  padding: 0;
  margin: 0;
  border-radius: 0;
}

.block-quote .attribution {
  font-family: 'Inter', sans-serif;
  font-size: 0.82rem;
  color: #7ABBC8;
  margin-top: 12px;
  font-style: normal;
}

/* ── StreamField: call-to-action block ────────────────────── */
.block-cta {
  background: var(--tag-bg);
  border: 1.5px solid rgba(31,163,184,0.2);
  border-radius: 10px;
  padding: 28px 32px;
  margin: 2rem 0;
  display: flex;
  align-items: center;
  gap: 24px;
}

.block-cta-text { flex: 1; }

.block-cta-title {
  font-family: 'Archivo', sans-serif;
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--ink);
  margin-bottom: 6px;
  letter-spacing: -0.02em;
}

.block-cta-body {
  font-size: 0.88rem;
  color: var(--ink-light);
  line-height: 1.5;
}

.block-cta-btn {
  font-family: 'Inter', sans-serif;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: var(--accent);
  color: var(--white);
  padding: 11px 22px;
  border-radius: 7px;
  white-space: nowrap;
  transition: background 0.2s, transform 0.15s;
  flex-shrink: 0;
  text-decoration: none;
  display: inline-block;
}

.block-cta-btn:hover {
  background: var(--accent-dark);
  transform: translateY(-1px);
}

/* ── StreamField: key facts / stats block ─────────────────── */
.block-keyfacts {
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  margin: 2rem 0;
}

.block-keyfacts-heading {
  font-family: 'Inter', sans-serif;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 12px 20px;
  border-bottom: 1.5px solid var(--border);
}

.block-keyfacts ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.block-keyfacts li {
  padding: 13px 20px;
  border-bottom: 1px solid var(--border);
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--ink-light);
  line-height: 1.5;
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.block-keyfacts li:last-child { border-bottom: none; }

.block-keyfacts li::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
  margin-top: 7px;
}

/* ── Paywall / member gate ────────────────────────────────── */
.paywall-gate {
  position: relative;
}

.paywall-fade {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 160px;
  background: linear-gradient(to bottom, transparent, var(--bg) 80%);
  pointer-events: none;
}

.paywall-cta {
  background: var(--white);
  border: 1.5px solid var(--border);
  border-top: 3px solid var(--accent);
  border-radius: 10px;
  padding: 32px;
  text-align: center;
  margin-top: -40px;
  position: relative;
  z-index: 1;
}

.paywall-eyebrow {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-dark);
  margin-bottom: 12px;
}

.paywall-title {
  font-family: 'Archivo', sans-serif;
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--ink);
  letter-spacing: -0.02em;
  margin-bottom: 10px;
  line-height: 1.2;
}

.paywall-sub {
  font-size: 0.88rem;
  color: var(--muted);
  line-height: 1.55;
  margin-bottom: 22px;
  max-width: 420px;
  margin-left: auto;
  margin-right: auto;
}

.paywall-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.paywall-btn-primary {
  font-family: 'Inter', sans-serif;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: var(--accent);
  color: var(--white);
  padding: 12px 24px;
  border-radius: 7px;
  transition: background 0.2s, transform 0.15s;
  text-decoration: none;
}

.paywall-btn-primary:hover {
  background: var(--accent-dark);
  transform: translateY(-1px);
}

.paywall-btn-secondary {
  font-family: 'Inter', sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--ink-light);
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color 0.2s;
}

.paywall-btn-secondary:hover { color: var(--ink); }

/* ── Paywall snippet (editor HTML uses Bootstrap classes) ───
   The snippet in /admin/snippets/ is written against Bootstrap.
   Redesigned pages no longer load Bootstrap, so restyle the same
   class names inside .paywall-gate to the new design language. */
.paywall-gate .card {
  background: var(--white);
  border: 1.5px solid var(--border);
  border-top: 3px solid var(--accent);
  border-radius: 10px;
  text-align: center;
  overflow: hidden;
  margin: 24px 0;
}
.paywall-gate .card-body { padding: 32px 24px 20px; }
.paywall-gate .card-title {
  font-family: 'Archivo', sans-serif;
  font-size: 1.3rem; font-weight: 800;
  color: var(--ink); letter-spacing: -0.02em;
  margin-bottom: 14px; line-height: 1.25;
}
.paywall-gate .card-text {
  font-size: 0.9rem; color: var(--muted);
  line-height: 1.55; margin-bottom: 14px;
}
.paywall-gate .btn {
  display: inline-block;
  font-family: 'Inter', sans-serif;
  font-size: 0.82rem; font-weight: 700;
  letter-spacing: 0.04em; text-transform: uppercase;
  background: var(--accent) !important;
  border: none !important;
  color: var(--white) !important;
  padding: 12px 24px !important;
  border-radius: 7px;
  text-decoration: none;
  transition: background 0.2s;
}
.paywall-gate .btn:hover { background: var(--accent-dark) !important; }
.paywall-gate hr { border: none; border-top: 1px solid var(--border); margin: 18px 0; }
.paywall-gate .card-footer {
  background: var(--bg);
  border-top: 1.5px solid var(--border);
  padding: 14px;
  font-size: 0.85rem;
  color: var(--muted);
}
.paywall-gate .card-footer a,
.paywall-gate .card-text a { color: var(--accent-dark); text-decoration: underline; }

/* ── Legacy Bootstrap modals (e.g. #signup_modal) ───────────
   Bootstrap CSS normally hides .modal until its JS opens it with an
   inline display:block. Without Bootstrap the markup renders as
   visible text — restore the hidden base state. */
.modal { display: none; }

/* ── Motivationsakademin (company page ids 3322/4572) ──────── */
.akademin-hero {
  background-color: var(--sidebar-dark);
  background-size: cover;
  background-position: center;
  border-bottom: 1.5px solid rgba(255,255,255,0.07);
}
.akademin-hero-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 64px 24px 56px;
}
.akademin-hero .category-title { margin-bottom: 0; }
.member-cta .akademin-status {
  font-size: 0.82rem;
  color: #7ABBC8;
  line-height: 1.5;
  margin-bottom: 14px;
}
.akademin-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  padding-bottom: 52px;
}
@media (max-width: 900px) { .akademin-grid { grid-template-columns: 1fr; } }
.akademin-course-card { display: flex; flex-direction: column; }
.akademin-course-card .card-body { display: flex; flex-direction: column; flex: 1; }
.akademin-course-card .card-image { display: block; }
.akademin-card-noimg {
  height: 168px;
  display: flex; align-items: center; justify-content: center;
  background: var(--sidebar-dark);
}
.akademin-card-noimg span {
  font-family: 'Archivo', sans-serif;
  font-size: 2rem; font-weight: 800;
  color: rgba(255,255,255,0.25);
}
.akademin-card-noimg .dot { color: rgba(31,163,184,0.5); }
.akademin-card-meta {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  margin-bottom: 8px;
}
.akademin-card-fact { font-size: 0.72rem; color: var(--muted); }
.akademin-card-note {
  font-size: 0.72rem; color: var(--muted);
  margin: 10px 0 0; line-height: 1.45;
}
.akademin-card-actions {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  margin-top: auto;
  padding-top: 14px;
}
/* get_academy_button emits Bootstrap-classed markup — restyle in place */
.akademin-card-actions .btn {
  font-family: 'Inter', sans-serif;
  font-size: 0.72rem; font-weight: 700;
  letter-spacing: 0.06em; text-transform: uppercase;
  background: var(--accent); color: var(--ink);
  border: none; border-radius: 6px;
  padding: 9px 16px;
  text-decoration: none;
  display: inline-block;
  transition: background 0.2s;
}
.akademin-card-actions .btn:hover { background: var(--accent-dark); color: var(--white); }
.akademin-card-readmore {
  font-size: 0.78rem; font-weight: 600;
  color: var(--accent-dark);
  text-decoration: underline; text-underline-offset: 2px;
}

/* ── Author index (/av/) ───────────────────────────────────── */
.author-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  padding: 28px 0 52px;
}
@media (max-width: 900px) { .author-grid { grid-template-columns: repeat(2, 1fr); } }
.author-card {
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: 10px;
  padding: 24px 16px;
  text-align: center;
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
}
.author-card:hover {
  border-color: var(--accent);
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(10,26,31,0.07);
}
.author-card-avatar {
  width: 80px; height: 80px;
  border-radius: 50%;
  overflow: hidden;
  margin: 0 auto 12px;
  border: 2px solid var(--border);
  background: var(--tag-bg);
}
.author-card-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.author-card-name {
  font-family: 'Archivo', sans-serif;
  font-size: 0.95rem; font-weight: 700;
  color: var(--ink);
  margin-bottom: 4px;
}
.author-card-role { font-size: 0.75rem; color: var(--muted); line-height: 1.4; }

/* ── 404 search form ───────────────────────────────────────── */
.notfound-search {
  display: flex; gap: 8px;
  max-width: 480px;
}
.notfound-search input[type="text"] {
  flex: 1;
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  color: var(--ink);
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: 7px;
  padding: 11px 14px;
  outline: none;
  transition: border-color 0.2s;
}
.notfound-search input[type="text"]:focus { border-color: var(--accent); }
.notfound-search button {
  font-family: 'Inter', sans-serif;
  font-size: 0.8rem; font-weight: 700;
  letter-spacing: 0.04em; text-transform: uppercase;
  background: var(--accent); color: var(--ink);
  border: none; border-radius: 7px;
  padding: 11px 22px;
  cursor: pointer;
  transition: background 0.2s;
}
.notfound-search button:hover { background: var(--accent-dark); color: var(--white); }

/* ── Generic pages (page app: om oss, kontakt, …) ──────────── */
.generic-page {
  max-width: 800px;
  padding: 36px 0 60px;
}
.generic-page .article-title { margin-bottom: 24px; }

/* ── Page body classes (set by Wagtail page type) ─────────── */
body.page-home .site-header { border-bottom-color: transparent; }

body.page-article .article-title,
body.page-article h1 {
  font-family: 'Archivo', sans-serif;
}

/* ── Responsive ───────────────────────────────────────────── */
@media (max-width: 768px) {
  body.wagtail-userbar-enabled .site-header {
    top: 0;
  }

  .block-cta {
    flex-direction: column;
    align-items: flex-start;
  }

  .block-cta-btn {
    align-self: flex-start;
  }

  .paywall-cta {
    padding: 24px 20px;
  }
}

/* Sidebar — upcoming courses (from motivation-se-post mockup, inline styles) */
.course-item {
  display: block;
  padding: 12px 18px;
  border-bottom: 1px solid var(--border);
  transition: background 0.15s;
  text-decoration: none;
}
.course-item:last-child { border-bottom: none; }
.course-item:hover { background: var(--bg); }
.course-provider {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent-dark);
  margin-bottom: 3px;
}
.course-title {
  font-size: 0.82rem;
  font-weight: 500;
  line-height: 1.35;
  color: var(--ink);
}

/* ── Off-canvas profile menu (redesign mode) ──────────────────
   base.html swaps the legacy class="sidebar" for this one under
   ?redesign=1 so the article sidebar styles don't collide.
   Toggled by motivation.js via .toggled, same as the old menu. */
.redesign-profile-menu {
  position: fixed;
  top: 0; right: 0;
  width: 320px;
  max-width: 90vw;
  height: 100vh;
  background: var(--white);
  border-left: 1.5px solid var(--border);
  box-shadow: -8px 0 40px rgba(10,26,31,0.12);
  z-index: 300;
  overflow-y: auto;
  transform: translateX(105%);
  transition: transform 0.3s ease;
  font-size: 0.9rem;
}
.redesign-profile-menu.toggled { transform: translateX(0); }
/* Interior styling lives in profile-panel.css (mockup .pp-* set). */

/* ── Faktaruta (fact box) below the author bio ──────────────
   No mockup exists — card geometry mirrors .author-bio, with an
   accent edge and eyebrow to mark it as a fact box. */
.faktaruta {
  background: var(--white);
  border: 1.5px solid var(--border);
  border-left: 4px solid var(--accent);
  border-radius: 10px;
  padding: 22px 24px;
  margin-top: 24px;
  font-size: 0.88rem;
  line-height: 1.6;
  color: var(--ink-light);
}
.faktaruta-label {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-dark);
  margin-bottom: 8px;
}
.faktaruta h2,
.faktaruta h3,
.faktaruta h4 {
  font-family: 'Archivo', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  margin: 0 0 10px;
  color: var(--ink);
}
.faktaruta p { margin-bottom: 12px; }
.faktaruta p:last-child { margin-bottom: 0; }
.faktaruta a { color: var(--accent-dark); text-decoration: underline; text-underline-offset: 2px; }

/* ── Pull-quote attribution (quote pages) ─────────────────── */
.pull-quote cite {
  display: block;
  margin-top: 10px;
  font-style: normal;
  font-size: 0.82rem;
  color: #7ABBC8;
}

/* ── Video / audio embeds on content pages ────────────────── */
.article-hero-embed { margin-bottom: 32px; }
.article-hero-embed iframe,
.article-hero-embed video {
  width: 100%;
  aspect-ratio: 16 / 9;
  height: auto;
  border: 0;
  border-radius: 10px;
  display: block;
}
.article-audio-embed { margin-bottom: 28px; }
.article-audio-embed iframe { width: 100%; border: 0; display: block; }

/* ── Bulleted lists in article bodies ───────────────────────
   The post mockup renders its statistics list as a bordered card
   (.stats-list). Applying that to every <ul> would be too loud, so
   only "substantial" lists qualify: 3+ items, nothing nested, no
   block-level content inside. Everything else keeps richtext.css's
   plain teal-dot bullets. Browsers without :has() also fall back to
   the plain bullets. */
.article-body.rich-text ul:not(.nav-tabs):has(> li:nth-child(3)):not(:has(ul, ol, p, img, h2, h3, h4)) {
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  margin: 28px 0;
}
.article-body.rich-text ul:not(.nav-tabs):has(> li:nth-child(3)):not(:has(ul, ol, p, img, h2, h3, h4)) > li {
  padding: 14px 20px 14px 38px;
  margin-bottom: 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--ink-light);
  line-height: 1.5;
}
.article-body.rich-text ul:not(.nav-tabs):has(> li:nth-child(3)):not(:has(ul, ol, p, img, h2, h3, h4)) > li:last-child {
  border-bottom: none;
}
.article-body.rich-text ul:not(.nav-tabs):has(> li:nth-child(3)):not(:has(ul, ol, p, img, h2, h3, h4)) > li::before {
  left: 20px;
  top: calc(14px + 0.55em);
}

/* ── "Andra har också läst" under the article newsletter ────
   No mockup exists for the collaborative recommender — rendered as
   the homepage's .section-label + .list-article rows. */
.also-read { margin-top: 36px; }
.also-read .section-label { margin-bottom: 18px; }

/* ── Sponsored banner above the article title ─────────────── */
.native-banner {
  display: inline-block;
  font-size: 0.68rem; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: #9A6B0A;
  background: #FBF0D0;
  border: 1.5px solid #D6A537;
  padding: 4px 10px; border-radius: 4px;
  margin-bottom: 14px;
}

/* ── Save/bookmark button reuses .share-btn look ──────────── */
.share-btn.saved {
  border-color: var(--accent);
  color: var(--accent-dark);
  background: var(--tag-bg);
}

/* ════════════════════════════════════════════════════════════
   Mockup reconciliation
   Johan's mockups are internally inconsistent: the homepage mockup
   (motivation-se-redesign.html, whose values went into
   motivation-se.css) uses a slightly smaller footer and sidebar
   blocks than the post & ledarskap mockups. These rules adopt the
   post/ledarskap values where those pages' sketches differ.
   ════════════════════════════════════════════════════════════ */

/* Footer — taller post/ledarskap variant, site-wide */
.footer-inner { padding: 28px 24px; }
/* Brand logo image in the footer (white wordmark + byline for the dark
   footer); byline is baked into the image so no separate tagline text. */
.footer-logo-img {
  height: 34px;
  width: auto;
  display: block;
}
.footer-links { gap: 24px; }
.footer-links a { font-size: 0.8rem; }
/* The post mockup adds breathing room above the footer on article pages */
body:has(.post-grid) .footer-strip { margin-top: 20px; }

/* Article body typography — post mockup values where richtext.css differs.
   Lead size follows the client v6 feedback (1.45rem). */
.article-body.rich-text p.lead {
  font-size: 1.45rem;
  margin-bottom: 28px;
}
.article-body.rich-text h3 {
  margin: 36px 0 14px;
  line-height: 1.25;
}

/* Tag chips live inside the .rich-text wrapper, whose generic link
   colour would otherwise beat .tag-chip — mockup wants ink-light. */
.rich-text .tag-chip,
.rich-text .tag-chip:visited {
  color: var(--ink-light);
  text-decoration: none;
  border-bottom: none;
}
.rich-text .tag-chip:hover { color: var(--accent-dark); }

/* Sidebar blocks — post/ledarskap variant on article + subject pages
   (.sidebar only exists in the post layout; subject pages scope by body class) */
.sidebar .sidebar-block,
body.page-collection .sidebar-block { margin-bottom: 24px; }
.sidebar .sidebar-block-header,
body.page-collection .sidebar-block-header { padding: 14px 20px; }
.sidebar .newsletter-block,
body.page-collection .newsletter-block { padding: 24px 22px; margin-bottom: 24px; }
.sidebar .newsletter-logo,
body.page-collection .newsletter-logo { margin-bottom: 4px; }
.sidebar .newsletter-sub-label,
body.page-collection .newsletter-sub-label { font-size: 0.62rem; }
.sidebar .newsletter-headline,
body.page-collection .newsletter-headline { font-size: 0.95rem; margin-bottom: 8px; }
.sidebar .newsletter-desc,
body.page-collection .newsletter-desc { font-size: 0.78rem; margin-bottom: 16px; }
.sidebar .newsletter-form input,
body.page-collection .newsletter-form input { font-size: 0.83rem; padding: 10px 14px; }
.sidebar .newsletter-form button,
body.page-collection .newsletter-form button { font-size: 0.78rem; padding: 11px; }

/* Subject pages — ledarskap mockup variants of the shared components */
body.page-collection .most-read-item { padding: 12px 20px; gap: 14px; }
body.page-collection .most-read-num { font-size: 1.1rem; min-width: 22px; }
body.page-collection .most-read-title { font-size: 0.82rem; }
.article-list .list-article { margin-bottom: 16px; }
.article-list .list-title { font-size: 1.08rem; line-height: 1.3; margin-bottom: 8px; }
.article-list .list-excerpt { font-size: 0.83rem; }
.article-list .list-meta { gap: 10px; margin-bottom: 8px; }
body.page-collection .akademi-card { height: 150px; }
body.page-collection .akademi-overlay { padding: 16px; }
body.page-collection .akademi-footer { padding: 14px 20px; }

/* ── Header search (mockups omit search; site needs it) ───── */
.header-search { margin-left: 8px; }
.header-search input[type="search"] {
  font-family: 'Inter', sans-serif;
  font-size: 0.82rem;
  width: 90px;
  color: var(--ink);
  background: var(--tag-bg);
  border: 1.5px solid transparent;
  border-radius: 100px;
  padding: 7px 14px;
  outline: none;
  transition: width 0.2s ease, border-color 0.2s, background 0.2s;
}
.header-search input[type="search"]::placeholder { color: var(--muted); }
.header-search input[type="search"]:focus {
  width: 180px;
  background: var(--white);
  border-color: var(--accent);
}

/* Profile pill in the redesign header for logged-in users */
.site-header nav .profile-menu-trigger {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px 6px 6px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--white);
  color: var(--ink);
  text-decoration: none;
  transition: border-color 0.2s;
}
.site-header nav .profile-menu-trigger:hover { border-color: var(--accent); }
.site-header nav .profile-menu-trigger .fa-user {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--tag-bg);
  color: var(--accent-dark);
  font-size: 0.85rem;
}

/* ── Legacy green retint (redesign mode, global) ───────────────
   Legacy motivation.css paints #66CC00 (lime) / #009a93 (teal-green)
   on many class selectors. On every page that keeps legacy CSS in
   redesign mode (course/event/company/job/payment/newsletter detail
   pages) these bleed into the new chrome. The redesign bundle loads
   after motivation.css, so retint each legacy-green class to the
   brand accent. All of these classes are legacy-only — they don't
   appear in converted redesign markup — so the rules are inert there
   and we don't need per-page scoping. */

/* Buttons (incl. the green <hr class="btn-primary"> dividers) */
.btn-primary, .btn-outline-primary {
  font-family: 'Inter', sans-serif;
  background-color: var(--accent) !important;
  border-color: var(--accent) !important;
  color: var(--ink) !important;
}
.btn-primary:hover, .btn-outline-primary:hover {
  background-color: var(--accent-dark) !important;
  border-color: var(--accent-dark) !important;
  color: var(--white) !important;
}
/* Coloured fills: format icon circles, etc. */
.formats > li.event, .formats > li.course,
.course, .event,
.course-bclr, .event-bclr, .bg-primary {
  background-color: var(--accent) !important;
}
/* Coloured text / headings */
.meta, .course-clr, .event-clr, .event-color,
.coming_events-container h3, .job-container h3,
.benefits .card-title {
  color: var(--accent-dark) !important;
}
/* Content links on legacy detail pages (.body-content is legacy-only) */
.body-content a { color: var(--accent-dark); }
/* Hardcoded inline green in legacy company list-item templates
   (<p style="color:#66CC00">). !important overrides the inline style. */
[style*="#66CC00" i] { color: var(--accent-dark) !important; }
/* Premium / Plus pills */
.badge-primary { background-color: var(--accent) !important; color: var(--ink) !important; }
.badge-success { background-color: var(--accent-dark) !important; color: var(--white) !important; }

/* ── Legacy detail-page typography lift ────────────────────────
   Archivo headings / Inter on the legacy course/event/company
   detail pages (these classes are legacy-only). */
.course-type {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--ink);
  border-bottom-color: var(--accent) !important;
}
.display-4 {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  letter-spacing: -0.03em;
}
.card .lead { font-family: 'Inter', sans-serif; }

/* ── Brand logo image in the redesign header (client point 4) ──
   Replaces the text MOTIVATION.SE wordmark with the supplied PNG. */
.site-header .logo-img {
  height: 34px;
  width: auto;
  display: block;
}
@media (max-width: 600px) {
  .site-header .logo-img { height: 28px; }
}

/* ── Footer link colour on legacy-CSS pages ───────────────────
   The global redesign footer is shared by every page, but pages
   that keep legacy motivation.css (course/event/company details)
   inherit its `footer a { color:#66CC00 !important }`, turning the
   footer links green. Force the brand colour with matching weight. */
.footer-strip .footer-links a { color: #4A8D9B !important; }
.footer-strip .footer-links a:hover { color: var(--accent) !important; }
