/* ============================================================
   CIM GLOBAL STYLESHEET
   Tokens → Reset → Typography → Layout → Nav → Cards →
   Badges → Buttons → Newsletter → Ads → Sidebar → Footer →
   Pagination → Article → Magazine → Social → Responsive → Utils
   ============================================================ */

/* ── 1. DESIGN TOKENS ─────────────────────────────────── */
:root {
  /* Accent — CIM yellow (primary colour is black, see --text). Yellow is a
     FILL colour with black text; labels/links stay near-black via --accent-text. */
  --accent:        #FFD200;   /* yellow — fills, buttons, badges (black text) */
  --accent-deep:   #E6BD00;   /* darker yellow — fill hovers */
  --accent-dim:    rgba(255,210,0,0.12);
  --accent-text:   #141414;   /* near-black — labels/links on light bg */
  --accent-2:      #FFD200;   /* yellow — highlight / ::selection */

  /* Light theme (default) */
  --bg:            #FFFFFF;
  --surface:       #F5F5F5;
  --card:          #FFFFFF;
  --card-hover:    #F9F9F9;
  --border:        rgba(0,0,0,0.07);
  --border-strong: rgba(0,0,0,0.13);
  --text:          #0F0F0F;
  --text-sec:      #595959;
  --text-muted:    #AAAAAA;
  --img-ph:        #E8E8E8;

  /* Semantic */
  --red:   #D94F3A;
  --green: #4CAF82;

  /* Typography */
  --f-head: 'Playfair Display', serif;
  --f-body: 'Inter', sans-serif;
  /* UI / label font — Inter for a single, readable, uniform label system */
  --f-mono: 'Inter', sans-serif;

  /* Layout */
  --maxw:      1600px;
  --article-w: 720px;
  --nav-h:     60px;
  --gap:       30px;
  --px:        20px;

  /* Radius */
  --r:      8px;
  --r-card: 14px;
  --r-pill: 20px;

  /* Soft, layered shadows for the smooth minimal feel */
  --shadow-card:       0 1px 2px rgba(0,0,0,0.04), 0 8px 24px rgba(0,0,0,0.05);
  --shadow-card-hover: 0 2px 6px rgba(0,0,0,0.05), 0 16px 40px rgba(0,0,0,0.10);

  /* Motion */
  --t-fast: 150ms ease;
  --t-med:  250ms ease;
}

/* Dark theme */
html.dark {
  --bg:            #0D0D0D;
  --surface:       #141414;
  --card:          #1A1A1A;
  --card-hover:    #202020;
  --border:        rgba(255,255,255,0.08);
  --border-strong: rgba(255,255,255,0.15);
  --text:          #F0EDE6;
  --text-sec:      #8A8680;
  --text-muted:    #504E4A;
  --accent:        #FFD200;
  --accent-deep:   #E6BD00;
  --accent-dim:    rgba(255,210,0,0.16);
  --accent-text:   #F0EDE6;   /* near-white — labels/links on dark */
  --accent-2:      #FFD200;
  --img-ph:        #1E1C18;
  /* On near-black surfaces shadows don't read; rely on borders instead */
  --shadow-card:       none;
  --shadow-card-hover: none;
}

/* ── 2. RESET & BASE ──────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--f-body);
  font-size: 15px;
  line-height: 1.6;
  transition: background var(--t-med), color var(--t-med);
  overflow-x: hidden;
}

img, video { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
::selection { background: var(--accent-2); color: #000; }
ul, ol { list-style: none; }
button { cursor: pointer; border: none; background: none; font: inherit; color: inherit; }
input, textarea, select { font: inherit; }
svg { fill: currentColor; }

/* ── 3. TYPOGRAPHY ────────────────────────────────────── */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--f-head);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.label {
  font-family: var(--f-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.label-accent { color: var(--accent-text); font-weight: 700; }

/* Headline scale */
.h-display { font-size: clamp(32px, 5vw, 52px); }
.h-hero    { font-size: clamp(26px, 4vw, 40px); }
.h-xl      { font-size: clamp(22px, 3vw, 32px); }
.h-lg      { font-size: clamp(18px, 2.5vw, 26px); }
.h-md      { font-size: 18px; }
.h-sm      { font-size: 16px; }
.h-xs      { font-size: 14px; }

/* ── 4. ARTICLE BODY ──────────────────────────────────── */
.article-body {
  font-size: 17px;
  line-height: 1.78;
}
.article-body p  { margin-bottom: 1.4em; }
.article-body h2 { font-family: var(--f-head); font-size: 28px; font-weight: 700; margin: 1.6em 0 0.5em; letter-spacing: -0.02em; line-height: 1.2; }
.article-body h3 { font-family: var(--f-head); font-size: 23px; font-weight: 700; margin: 1.5em 0 0.45em; letter-spacing: -0.015em; line-height: 1.25; }
.article-body h4 { font-family: var(--f-head); font-size: 19px; font-weight: 700; margin: 1.4em 0 0.4em; line-height: 1.3; }
.article-body h5 { font-family: var(--f-body); font-size: 16px; font-weight: 700; margin: 1.3em 0 0.35em; }
.article-body h6 { font-family: var(--f-body); font-size: 14px; font-weight: 700; margin: 1.2em 0 0.35em; }
.article-body ul,
.article-body ol  { padding-left: 1.5em; margin-bottom: 1.4em; }
.article-body ul  { list-style: disc; }
.article-body ol  { list-style: decimal; }
.article-body li  { margin-bottom: 0.4em; }
/* In-content links stand out: black text + bold yellow underline (highlighter) */
.article-body a   {
  color: var(--text);
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
  transition: background var(--t-fast), text-decoration-color var(--t-fast);
}
.article-body a:hover { background: rgba(255,210,0,0.28); text-decoration-color: var(--accent-deep); }
.article-body blockquote {
  border-left: 3px solid var(--accent-deep);
  padding: 2px 0 2px 22px;
  margin: 1.8em 0;
  background: none;
  border-radius: 0;
  font-family: var(--f-head);
  font-style: normal;
  font-weight: 500;
  font-size: 21px;
  line-height: 1.5;
  color: var(--text);
}
.article-body blockquote p { margin-bottom: 0.5em; }
.article-body blockquote p:last-child { margin-bottom: 0; }
.article-body blockquote cite {
  display: block;
  margin-top: 12px;
  font-family: var(--f-body);
  font-style: normal;
  font-weight: 400;
  font-size: 14px;
  color: var(--text-sec);
}
.article-body code {
  font-family: var(--f-mono);
  font-size: 13px;
  background: var(--surface);
  padding: 2px 6px;
  border-radius: var(--r);
}
.article-body pre {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-card);
  padding: 1.2em;
  overflow-x: auto;
  margin-bottom: 1.4em;
}
.article-body pre code { background: none; padding: 0; }
.article-body img {
  border-radius: var(--r-card);
  margin: 1.4em 0;
  width: 100%;
}
.article-body figcaption {
  font-family: var(--f-mono);
  font-size: 11px;
  color: var(--text-muted);
  text-align: center;
  margin-top: -0.8em;
  margin-bottom: 1.4em;
}
.article-standfirst {
  font-size: 18px;
  font-weight: 300;
  color: var(--text-sec);
  border-left: 3px solid var(--accent);
  padding-left: 1em;
  margin-bottom: 2em;
  line-height: 1.6;
}
/* Links inside excerpts / standfirsts — visible but not loud */
.article-standfirst a,
.ac-lesson-standfirst a,
.post-card-excerpt a,
.cim-feature-dek a {
  color: inherit;
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 2px;
  text-underline-offset: 2px;
}
.article-standfirst a:hover,
.ac-lesson-standfirst a:hover,
.post-card-excerpt a:hover,
.cim-feature-dek a:hover { color: var(--text); }

/* ── 5. LAYOUT ────────────────────────────────────────── */
.wrap         { width: min(var(--maxw), 92vw); max-width: none; margin: 0 auto; padding: 0; }
.wrap-article { max-width: var(--article-w); margin: 0 auto; padding: 0 var(--px); }

.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--gap); }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gap); }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gap); }

.layout-article {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 48px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--px);
}
/* Stop any grid child (wide embed, widget, long word) from forcing the
   column wider than the screen — the cause of mobile content shifting right. */
.layout-article > * { min-width: 0; }
.article-body { overflow-wrap: break-word; }
.article-body :is(img, iframe, video, table, pre) { max-width: 100%; }

/* ── Tables in article & lesson body ── */
.article-body figure.wp-block-table {
  margin: 0 0 2em;                 /* breathing room after the table */
  overflow-x: auto;                /* wide tables scroll instead of squishing */
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--border);
  border-radius: 10px;
}
.article-body figure.wp-block-table table { margin: 0; border: 0; }
.article-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 2em;                 /* space after bare (non-figure) tables too */
  background: var(--card);
  font-size: 14.5px;
  line-height: 1.55;
  border: 1px solid var(--border);
}
.article-body th,
.article-body td {
  padding: 12px 16px;
  border: 1px solid var(--border);
  text-align: left;
  vertical-align: middle;
}
.article-body thead th,
.article-body table > tr:first-child > th,
.article-body tbody tr:first-child > th {
  background: rgba(255, 210, 0, 0.16);   /* pale brand-yellow header */
  font-weight: 700;
  color: var(--text);
}
.article-body tbody tr:nth-child(even) { background: rgba(255, 210, 0, 0.05); }  /* faint warm zebra */
.article-body td:first-child { font-weight: 600; color: var(--text); }
.article-body table a { word-break: break-word; }

/* ── Opt-in article Table of Contents (sticky sidebar + mobile collapsible) ── */
.article-body h2 { scroll-margin-top: calc(var(--nav-h) + 20px); }

.cim-toc-head {
  font-family: var(--f-mono);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-sec);
  margin: 0 0 12px;
}
.cim-toc-list { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--border); }
.cim-toc-list li { margin: 0; }
.cim-toc-list a {
  display: block;
  padding: 7px 0 7px 14px;
  margin-left: -1px;
  border-left: 2px solid transparent;
  color: var(--text-sec);
  font-size: 13.5px;
  line-height: 1.4;
  text-decoration: none;
  transition: color var(--t-fast), border-color var(--t-fast);
}
.cim-toc-list a:hover { color: var(--text); }
.cim-toc-list a.is-active { color: var(--text); border-left-color: var(--accent); font-weight: 600; }
/* The mobile ToC lives inside .article-body — override its list styling (no bullets/indent) */
.article-body .cim-toc-list { list-style: none; padding-left: 0; margin: 0; }
.article-body .cim-toc-list li { margin: 0; }

/* Desktop: sticky card at the top of the article sidebar */
.cim-toc-side {
  display: block;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px 18px;
  margin: 0 0 20px;
  background: var(--card);
}
.cim-toc-mobile { display: none; }

/* Mobile: collapsible box inline, before the first H2 */
@media (max-width: 1024px) {
  .cim-toc-side { display: none; }
  .cim-toc-mobile {
    display: block;
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 4px 18px;
    margin: 0 0 2em;
    background: rgba(255, 210, 0, 0.05);
  }
  .cim-toc-mobile .cim-toc-head {
    margin: 0;
    padding: 14px 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    list-style: none;
  }
  .cim-toc-mobile .cim-toc-head::-webkit-details-marker { display: none; }
  .cim-toc-mobile .cim-toc-head::after {
    content: "";
    width: 8px; height: 8px;
    border-right: 2px solid var(--text-sec);
    border-bottom: 2px solid var(--text-sec);
    transform: rotate(45deg);
    transition: transform .2s;
  }
  .cim-toc-mobile[open] .cim-toc-head::after { transform: rotate(-135deg); }
  .cim-toc-mobile .cim-toc-list { border-left: 0; padding-bottom: 12px; }
  .cim-toc-mobile .cim-toc-list a { padding-left: 0; border-left: 0; }
  .cim-toc-mobile .cim-toc-list a.is-active { border-left: 0; color: var(--text); }
}

.section-pad    { padding: 48px 0; }
.section-pad-sm { padding: 32px 0; }

.section-heading {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
}
.section-heading > .label { font-size: 14px; font-weight: 700; letter-spacing: 0.07em; }
.section-heading > .label::before {
  content: '';
  display: inline-block;
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 2px;
  margin-right: 9px;
  vertical-align: middle;
  position: relative;
  top: -1px;
}
.section-heading::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

/* ── 6. NAVIGATION ────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--nav-h);
  background: rgba(255,255,255,0.96);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  transition: background var(--t-med);
}
html.dark .site-header { background: rgba(13,13,13,0.96); }

.nav-inner {
  display: flex;
  align-items: center;
  gap: 4px;
  height: 100%;
  width: min(var(--maxw), 92vw);
  max-width: none;
  margin: 0 auto;
  padding: 0;
}

.site-logo { flex-shrink: 0; display: flex; align-items: center; margin-right: 16px; }
.site-logo img { height: 34px; width: auto; }
/* Dark-mode logo swap (only active when a dark logo is uploaded) */
.site-logo-dark { display: none; }
html.dark .site-logo--swap .site-logo-light { display: none; }
html.dark .site-logo--swap .site-logo-dark  { display: block; }
.site-logo-text {
  font-family: var(--f-head);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
}

.nav-menu { display: flex; align-items: center; gap: 2px; flex: 1; }

/* WordPress inserts a <ul> directly */
.nav-menu > ul,
.nav-menu ul { display: flex; align-items: center; gap: 2px; flex: 1; list-style: none; }

.nav-menu a {
  font-family: var(--f-mono);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-sec);
  padding: 6px 10px;
  border-radius: var(--r);
  transition: color var(--t-fast), background var(--t-fast);
  white-space: nowrap;
  display: block;
}
.nav-menu a:hover,
.nav-menu .current-menu-item > a,
.nav-menu .current-menu-ancestor > a {
  color: var(--text);
  background: var(--surface);
}

/* Dropdowns */
.nav-menu .menu-item-has-children { position: relative; }
.nav-menu .sub-menu {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 180px;
  background: var(--card);
  border: 1px solid var(--border-strong);
  border-radius: var(--r-card);
  padding: 6px;
  box-shadow: 0 8px 20px rgba(0,0,0,0.12);
  z-index: 10;
  list-style: none;
}
/* Transparent bridge across the gap so the dropdown stays open while the
   cursor travels from the menu item down to the submenu. */
.nav-menu .sub-menu::before {
  content: '';
  position: absolute;
  top: -10px;
  left: 0;
  right: 0;
  height: 10px;
}
.nav-menu .menu-item-has-children:hover > .sub-menu,
.nav-menu .menu-item-has-children:focus-within > .sub-menu { display: block; }
.nav-menu .sub-menu a {
  display: block;
  width: 100%;
  padding: 8px 12px;
  border-radius: var(--r);
  color: var(--text-sec);
  font-size: 14px;
}
.nav-menu .sub-menu a:hover { color: var(--text); background: var(--surface); }

/* Nav actions */
.nav-actions { display: flex; align-items: center; gap: 6px; margin-left: auto; flex-shrink: 0; }

.btn-search,
.btn-theme {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: var(--r);
  color: var(--text-sec);
  transition: color var(--t-fast), background var(--t-fast);
}
.btn-search:hover,
.btn-theme:hover { color: var(--text); background: var(--surface); }

/* Sun/moon icons swap with theme */
.btn-theme .icon-sun  { display: block; }
.btn-theme .icon-moon { display: none; }
html.dark .btn-theme .icon-sun  { display: none; }
html.dark .btn-theme .icon-moon { display: block; }

.btn-google {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'Roboto', var(--f-body);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
  background: #fff;
  color: #3c4043;
  padding: 7px 14px;
  border: 1px solid #dadce0;
  border-radius: 4px;
  white-space: nowrap;
  box-shadow: 0 1px 2px rgba(60,64,67,0.08);
  transition: background var(--t-fast), box-shadow var(--t-fast), border-color var(--t-fast);
}
.btn-google:hover { background: #f8f9fa; border-color: #d2d5d9; box-shadow: 0 1px 3px rgba(60,64,67,0.18); }
.btn-google-icon { width: 16px; height: 16px; flex-shrink: 0; display: block; }

.btn-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 34px;
  height: 34px;
  align-items: center;
  justify-content: center;
  border-radius: var(--r);
  color: var(--text-sec);
}
.btn-hamburger span {
  display: block;
  width: 18px;
  height: 1.5px;
  background: currentColor;
  transition: transform var(--t-fast), opacity var(--t-fast);
}

/* Mobile nav drawer */
.mobile-nav {
  display: none;
  position: fixed;
  inset: var(--nav-h) 0 0 0;
  background: var(--bg);
  z-index: 99;
  overflow-y: auto;
  padding: 16px var(--px);
  border-top: 1px solid var(--border);
}
.mobile-nav.is-open { display: block; }

.mobile-nav ul { list-style: none; }
.mobile-nav > ul > li > a,
.mobile-nav a {
  display: block;
  font-family: var(--f-mono);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-sec);
  padding: 13px 0;
  border-bottom: 1px solid var(--border);
  transition: color var(--t-fast);
}
.mobile-nav a:hover { color: var(--text); }
.mobile-nav .sub-menu { padding-left: 16px; list-style: none; }
.mobile-nav .sub-menu a { font-size: 11px; }

/* Ad slot below nav */
.ad-below-nav {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}
.ad-below-nav .widget { text-align: center; padding: 8px 0; }

/* Search overlay */
.search-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.88);
  z-index: 200;
  align-items: flex-start;
  justify-content: center;
  padding-top: 100px;
}
.search-overlay.is-open { display: flex; }
.search-inner { width: 100%; max-width: 600px; padding: 0 var(--px); }

.search-form {
  display: flex;
  align-items: center;
  background: var(--card);
  border: 1px solid var(--border-strong);
  border-radius: var(--r-card);
  overflow: hidden;
}
.search-form input[type="search"] {
  flex: 1;
  background: none;
  border: none;
  padding: 16px 20px;
  font-size: 18px;
  color: var(--text);
  outline: none;
}
.search-form input[type="search"]::placeholder { color: var(--text-muted); }
.search-form button[type="submit"] {
  padding: 16px 20px;
  color: var(--accent);
  transition: color var(--t-fast);
  background: none;
  border: none;
  cursor: pointer;
}
.search-form button[type="submit"]:hover { color: var(--accent-deep); }
.search-close {
  display: block;
  text-align: center;
  margin-top: 14px;
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  cursor: pointer;
}

/* ── 7. POST CARDS ────────────────────────────────────── */
.post-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r-card);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  transition: background var(--t-fast), border-color var(--t-fast), transform var(--t-fast), box-shadow var(--t-fast);
  display: flex;
  flex-direction: column;
}
.post-card:hover {
  background: var(--card-hover);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-card-hover);
  transform: translateY(-3px);
}

.post-card-thumb {
  display: block;
  aspect-ratio: 16/9;
  overflow: hidden;
  background: var(--img-ph);
}
.post-card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 350ms ease;
}
.post-card:hover .post-card-thumb img { transform: scale(1.03); }

.post-card-body { padding: 16px; flex: 1; display: flex; flex-direction: column; }

.post-card-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.post-card-title {
  font-family: var(--f-head);
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.01em;
  margin-bottom: 8px;
}
.post-card-title a { transition: color var(--t-fast); }
.post-card-title a:hover { color: var(--accent-text); }
/* Uniform card title size (grid cards); hero keeps its own large .h-hero size */
.post-card .post-card-title { font-size: 17px; }

.post-card-excerpt {
  font-size: 14px;
  color: var(--text-sec);
  line-height: 1.5;
  flex: 1;
}
.post-card-author {
  margin-top: 12px;
  font-size: 12.5px;
  color: var(--text-muted);
}
.post-card-author a { color: var(--text); font-weight: 500; }
.post-card-author a:hover { text-decoration: underline; }

/* Hero card (large) — complete image with title on a bottom gradient overlay */
.post-card-hero {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: var(--r-card);
  background: #111;
  box-shadow: var(--shadow-card);
}
.post-card-hero-img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.post-card-hero-body {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 72px 28px 22px;
  background: linear-gradient(to top,
    rgba(0,0,0,0.94) 0%,
    rgba(0,0,0,0.80) 30%,
    rgba(0,0,0,0.38) 65%,
    rgba(0,0,0,0) 100%);
}
.post-card-hero .post-card-title { color: #fff; margin-bottom: 6px; }
.post-card-hero .post-card-meta .label { color: rgba(255,255,255,0.72); }
/* Category on the hero becomes a yellow pill with black text */
.post-card-hero .post-card-meta .label-accent {
  background: var(--accent);
  color: #141414;
  padding: 5px 11px;
  border-radius: 6px;
  font-weight: 700;
}

/* Horizontal row card (trending / sidebar) */
.post-card-row {
  display: flex;
  gap: 14px;
  align-items: center;
  padding: 11px 0;
  border-bottom: 1px solid var(--border);
}
.post-card-row:last-child { border-bottom: none; }
.post-card-row-thumb {
  flex-shrink: 0;
  width: 96px;
  height: 64px;
  border-radius: var(--r);
  overflow: hidden;
  /* Background-image (not an <img>) so the image-optimizer plugin can't force
     height:auto and leave a grey strip — background-size:cover always fills. */
  background-color: var(--img-ph);
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
}
.post-card-row .post-card-title { font-size: 17px; margin-bottom: 4px; line-height: 1.3; }
/* Shortcode row list ([cim_posts style="row"]) */
.cim-row-list { display: flex; flex-direction: column; }

/* Hero side cards — larger, to fill the column height next to the hero */
.hero-side .post-card-row { gap: 16px; padding: 6px 0; }
.hero-side .post-card-row-thumb { width: 124px; height: 82px; }
.hero-side .post-card-row .post-card-title { line-height: 1.25; -webkit-line-clamp: 3; }

/* Numbered list ([cim_posts style="list"]) */
.cim-numbered-list { list-style: none; margin: 0; padding: 0; }
.cim-numbered-item {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
}
.cim-numbered-item:last-child { border-bottom: none; }
.cim-numbered-num {
  font-family: var(--f-head);
  font-size: 32px;
  font-weight: 800;
  line-height: 1;
  color: var(--accent);
  flex-shrink: 0;
  min-width: 46px;
}
.cim-numbered-text .label-accent { display: inline-block; margin-bottom: 4px; }
.cim-numbered-text .post-card-title { font-size: 17px; margin: 0 0 4px; }

/* Feature story ([cim_feature]) */
.cim-feature { display: flex; gap: 36px; align-items: center; }
.cim-feature-media { flex: 1 1 56%; display: block; border-radius: var(--r-card); overflow: hidden; background: var(--img-ph); }
.cim-feature-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cim-feature-body { flex: 1 1 44%; min-width: 0; }
.cim-feature-title { font-family: var(--f-head); font-weight: 700; font-size: clamp(24px, 3vw, 38px); line-height: 1.14; letter-spacing: -0.02em; margin: 12px 0; }
.cim-feature-title a { color: inherit; }
.cim-feature-dek { font-size: 16px; color: var(--text-sec); line-height: 1.6; margin-bottom: 16px; }
.cim-feature-meta { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 18px; }

/* Feature — image on the right */
.cim-feature--image-right { flex-direction: row-reverse; }

/* Feature — stacked (image on top) */
.cim-feature--stacked { flex-direction: column; align-items: stretch; gap: 18px; }
.cim-feature--stacked .cim-feature-media { aspect-ratio: 16/9; }

/* Feature — text overlaid on the image */
.cim-feature--overlay { position: relative; display: block; border-radius: var(--r-card); overflow: hidden; background: #111; }
.cim-feature--overlay .cim-feature-media { border-radius: 0; }
.cim-feature--overlay .cim-feature-media img { width: 100%; height: auto; }
.cim-feature--overlay .cim-feature-body {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 90px 36px 30px;
  background: linear-gradient(to top, rgba(0,0,0,0.93) 0%, rgba(0,0,0,0.6) 45%, rgba(0,0,0,0) 100%);
}
.cim-feature--overlay .cim-feature-title { color: #fff; }
.cim-feature--overlay .cim-feature-dek { color: rgba(255,255,255,0.82); }
.cim-feature--overlay .cim-feature-meta .label { color: rgba(255,255,255,0.72); }

@media (max-width: 768px) {
  .cim-feature,
  .cim-feature--image-right { flex-direction: column; align-items: stretch; gap: 16px; }
  .cim-feature:not(.cim-feature--overlay) .cim-feature-media { aspect-ratio: 16/9; }
}

/* ── 8. BADGES & TAGS ─────────────────────────────────── */
.badge {
  display: inline-block;
  font-family: var(--f-mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 3px 9px;
  border-radius: var(--r);
  line-height: 1.4;
}
.badge-cat   { background: var(--accent);      color: #000; }
.badge-break { background: var(--red);         color: #fff; }
.badge-new   { background: var(--accent-deep); color: #fff; }
/* Sponsored / partnered — neutral outlined pill, distinct from editorial categories */
.badge-partnered {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: transparent;
  color: var(--text-sec);
  border: 1px solid var(--border-strong);
}
.badge-partnered svg { flex-shrink: 0; }

/* ── 9. BUTTONS ───────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--f-mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 10px 20px;
  border-radius: var(--r);
  border: 1px solid transparent;
  transition: background var(--t-fast), color var(--t-fast), border-color var(--t-fast);
  cursor: pointer;
  line-height: 1;
}
.btn-primary { background: var(--accent); color: #000; }
.btn-primary:hover { background: var(--accent-deep); color: #000; }
.btn-ghost {
  background: transparent;
  border-color: var(--border-strong);
  color: var(--text-sec);
}
.btn-ghost:hover { border-color: var(--accent); color: var(--accent-text); background: var(--accent-dim); }
.btn-sm { font-size: 10px; padding: 7px 14px; }

/* ── 10. NEWSLETTER BOX ───────────────────────────────── */
.newsletter-box {
  background: var(--accent-dim);
  border: 1px solid var(--accent-dim);
  border-radius: var(--r-card);
  padding: 24px;
}
.newsletter-box h3 { font-size: 18px; margin-bottom: 6px; }
.newsletter-box p  { font-size: 13px; color: var(--text-sec); margin-bottom: 16px; }

/* Email input — plain form and plugin forms (MC4WP / Newsletter) */
.newsletter-form,
.newsletter-box .mc4wp-form-fields,
.newsletter-box form { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
/* MC4WP "Newspaper" form wraps email + submit in .subscribe_holder — make it a spaced row */
.subscribe_holder { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; width: 100%; }
.subscribe_holder input[type="email"] { flex: 1 1 200px; }
.newsletter-form input[type="email"],
.newsletter-box input[type="email"] {
  flex: 1 1 160px;
  background: var(--card);
  border: 1px solid var(--border-strong);
  border-radius: var(--r);
  padding: 9px 13px;
  font-size: 14px;
  color: var(--text);
  outline: none;
  transition: border-color var(--t-fast);
}
.newsletter-form input[type="email"]:focus,
.newsletter-box input[type="email"]:focus { border-color: var(--accent); }
.newsletter-form input[type="email"]::placeholder,
.newsletter-box input[type="email"]::placeholder { color: var(--text-muted); }

/* Subscribe button — covers <button>, plugin input[type=submit], and .btn */
.newsletter-box button,
.newsletter-box input[type="submit"] {
  background: var(--accent);
  color: #141414;
  font-family: var(--f-mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 10px 16px;
  border-radius: var(--r);
  border: none;
  cursor: pointer;
  white-space: nowrap;
  transition: background var(--t-fast);
  -webkit-appearance: none;
  appearance: none;
}
.newsletter-box button:hover,
.newsletter-box input[type="submit"]:hover { background: var(--accent-deep); }

/* Consent / fine-print line inside plugin forms */
.newsletter-box label,
.newsletter-box .mc4wp-form-fields p,
.newsletter-box small {
  flex-basis: 100%;
  font-size: 11px;
  line-height: 1.45;
  color: var(--text-muted);
  margin: 6px 0 0;
}
.newsletter-box label a,
.newsletter-box .mc4wp-form-fields p a { color: var(--accent-text); text-decoration: underline; }
.newsletter-box .mc4wp-response { flex-basis: 100%; font-size: 12px; color: var(--text-sec); margin-top: 6px; }

/* ── 11. AD SLOTS ─────────────────────────────────────── */
.ad-slot {
  background: var(--surface);
  border: 1px dashed var(--border-strong);
  border-radius: var(--r-card);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 16px;
  min-height: 90px;
}
.ad-slot:empty::before {
  content: 'Advertisement';
  font-family: var(--f-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.ad-slot-leaderboard { min-height: 90px; }
.ad-slot-rectangle   { min-height: 250px; }
.ad-slot-inline      { min-height: 90px; margin: 32px 0; }

/* ── 12. SIDEBAR ──────────────────────────────────────── */
.sidebar { display: flex; flex-direction: column; gap: 28px; }
.sidebar-sticky { position: sticky; top: calc(var(--nav-h) + 20px); }
.widget-title { font-size: 12px; margin-bottom: 12px; color: var(--text-sec); }

/* ── 13. FOOTER ───────────────────────────────────────── */
.site-footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 40px 0 24px;
  margin-top: 64px;
}
.footer-inner {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 32px;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 var(--px) 32px;
  border-bottom: 1px solid var(--border);
}
.footer-logo { margin-bottom: 10px; }
.footer-logo img { height: 30px; width: auto; }
.footer-logo .site-logo-text { font-family: var(--f-head); font-weight: 700; font-size: 15px; }
.footer-tagline { font-size: 13px; color: var(--text-muted); max-width: 220px; }

.footer-nav { display: flex; flex-direction: column; gap: 8px; }
.footer-nav ul { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.footer-nav a {
  font-family: var(--f-mono);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-sec);
  transition: color var(--t-fast);
}
.footer-nav a:hover { color: var(--accent-text); }

.footer-social { display: flex; gap: 10px; }
.footer-social a {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-strong);
  border-radius: var(--r);
  color: var(--text-sec);
  transition: color var(--t-fast), border-color var(--t-fast), background var(--t-fast);
}
.footer-social a:hover {
  color: var(--accent-text);
  border-color: var(--accent);
  background: var(--accent-dim);
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 20px var(--px) 0;
}
.footer-copy {
  font-family: var(--f-mono);
  font-size: 11px;
  color: var(--text-muted);
  letter-spacing: 0.04em;
}

/* ── 14. PAGINATION ───────────────────────────────────── */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 40px 0;
}
/* the_posts_pagination() nests the links in .nav-links — keep them in a row */
.pagination .nav-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 6px;
}
.pagination a,
.pagination span {
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--r);
  border: 1px solid var(--border);
  color: var(--text-sec);
  transition: all var(--t-fast);
}
.pagination a:hover { color: var(--text); border-color: var(--border-strong); background: var(--surface); }
.pagination .current { background: var(--accent); color: #000; border-color: var(--accent); font-weight: 700; }
.pagination .dots { border: none; cursor: default; }

/* ── 15. ARTICLE PAGE ─────────────────────────────────── */
.article-header { padding: 0 0 4px; }
.article-header-meta { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.article-header h1 { font-size: clamp(26px, 4vw, 42px); line-height: 1.15; letter-spacing: -0.03em; margin-bottom: 14px; }

/* Header + featured image span the full width (first fold); body + sidebar sit below */
/* Article hero — header text beside the featured image on desktop */
.layout-article > .article-hero { grid-column: 1 / -1; margin-bottom: 10px; }
.article-hero.has-media { display: grid; grid-template-columns: 1.15fr 1fr; gap: 40px; align-items: center; }
.article-hero .article-featured-img { margin: 0; box-shadow: var(--shadow-card); }

.article-byline { display: flex; align-items: center; gap: 10px; }
.article-byline-avatar { width: 36px; height: 36px; border-radius: 50%; overflow: hidden; background: var(--img-ph); flex-shrink: 0; }
.article-byline-avatar img { width: 100%; height: 100%; object-fit: cover; }
.article-byline-name { font-size: 14px; font-weight: 500; }
.article-byline-meta { font-family: var(--f-mono); font-size: 10px; color: var(--text-muted); letter-spacing: 0.06em; }

.article-featured-img { width: 100%; border-radius: var(--r-card); overflow: hidden; margin: 24px 0; background: var(--img-ph); }
/* Show the full image (no crop) */
.article-featured-img img { width: 100%; height: auto; display: block; }

/* Share bar */
.share-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  padding: 18px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  margin: 28px 0;
}
/* Tighten the space between the byline/hero and the first share bar */
.article-content > .share-bar:first-child { margin-top: 4px; }
.share-bar-label {
  font-family: var(--f-mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-right: 4px;
}
.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--f-mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 7px 12px;
  border: 1px solid var(--border-strong);
  border-radius: var(--r);
  color: var(--text-sec);
  transition: all var(--t-fast);
}
.share-btn:hover { border-color: var(--accent); color: var(--accent-text); background: var(--accent-dim); }

/* "Make CIM preferred on Google" pill — right side of the share bar */
.btn-prefer {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'Roboto', var(--f-body);
  font-size: 13px;
  font-weight: 500;
  color: #3c4043;
  background: #fff;
  border: 1px solid #dadce0;
  border-radius: 20px;
  padding: 6px 14px;
  white-space: nowrap;
  transition: background var(--t-fast), box-shadow var(--t-fast), border-color var(--t-fast);
}
.btn-prefer:hover { background: #f8f9fa; border-color: #d2d5d9; box-shadow: 0 1px 3px rgba(60,64,67,0.18); }
.btn-prefer strong { font-weight: 700; color: #202124; }
.btn-prefer .btn-google-icon { width: 15px; height: 15px; flex-shrink: 0; display: block; }
@media (max-width: 560px) {
  .btn-prefer { margin-left: 0; }
}

/* Author bio box */
.author-bio {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-card);
  padding: 20px;
  margin: 40px 0;
}
.author-bio-avatar { width: 56px; height: 56px; border-radius: 50%; overflow: hidden; flex-shrink: 0; background: var(--img-ph); }
.author-bio-avatar img { width: 100%; height: 100%; object-fit: cover; }
.author-bio-name { font-size: 15px; font-weight: 600; margin-bottom: 4px; }
.author-bio-desc { font-size: 13px; color: var(--text-sec); line-height: 1.5; }
.author-socials { display: flex; gap: 8px; margin-top: 10px; }
.author-social { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 50%; border: 1px solid var(--border-strong); color: var(--text-sec); transition: color var(--t-fast), border-color var(--t-fast), background var(--t-fast); }
.author-social:hover { color: var(--accent-text); background: var(--accent); border-color: var(--accent); }

/* Reading progress */
.reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 2px;
  background: var(--accent);
  z-index: 300;
  width: 0%;
  transition: width 100ms linear;
  pointer-events: none;
}

/* Related posts */
.related-posts { margin-top: 48px; }
.related-posts-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gap); margin-top: 20px; }

/* ── 16. SOCIAL FOLLOW BUTTONS ────────────────────────── */
.social-follow { display: flex; gap: 10px; flex-wrap: wrap; }
.social-follow-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 14px;
  border-radius: var(--r);
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-weight: 700;
  transition: opacity var(--t-fast);
}
.social-follow-btn:hover { opacity: 0.85; }
.social-follow-btn-x        { background: #000; color: #fff; border: 1px solid var(--border-strong); }
.social-follow-btn-linkedin { background: #0A66C2; color: #fff; }

/* ── 17. MAGAZINE PAGE ────────────────────────────────── */
.magazine-current {
  display: flex;
  gap: 32px;
  align-items: flex-start;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r-card);
  padding: 32px;
  margin-bottom: 48px;
}
.magazine-current-img {
  flex-shrink: 0;
  width: 200px;
  border-radius: var(--r);
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(0,0,0,0.4);
}
.magazine-current-img img { width: 100%; height: auto; display: block; }
.magazine-current-body { flex: 1; }
.magazine-current-label { margin-bottom: 8px; }
.magazine-current-title { font-size: clamp(20px, 3vw, 30px); margin-bottom: 12px; }
.magazine-current-desc { font-size: 15px; color: var(--text-sec); line-height: 1.65; margin-bottom: 20px; }
.magazine-current-actions { display: flex; gap: 10px; flex-wrap: wrap; }

.magazine-subscribe-banner {
  background: var(--accent);
  border-radius: var(--r-card);
  padding: 36px 32px;
  text-align: center;
  margin: 48px 0;
}
.magazine-subscribe-banner h2 { font-size: 22px; color: #000; margin-bottom: 8px; }
.magazine-subscribe-banner p  { font-size: 14px; color: rgba(0,0,0,0.65); margin-bottom: 20px; }
.magazine-subscribe-banner .btn-primary { background: #000; color: var(--accent); }
.magazine-subscribe-banner .btn-primary:hover { background: #111; }

.magazine-archive-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gap); }
.magazine-archive-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r-card);
  overflow: hidden;
  transition: border-color var(--t-fast), transform var(--t-fast);
}
.magazine-archive-card:hover { border-color: var(--border-strong); transform: translateY(-2px); }
.magazine-archive-thumb { aspect-ratio: 3/4; background: var(--img-ph); overflow: hidden; }
.magazine-archive-thumb img { width: 100%; height: 100%; object-fit: cover; }
.magazine-archive-body { padding: 16px; }
.magazine-archive-title { font-size: 15px; font-weight: 600; margin-bottom: 6px; }
.magazine-archive-desc  { font-size: 13px; color: var(--text-sec); margin-bottom: 12px; line-height: 1.5; }

/* ── 18. RESPONSIVE ───────────────────────────────────── */
@media (max-width: 1024px) {
  .grid-4            { grid-template-columns: repeat(2, 1fr); }
  .related-posts-grid { grid-template-columns: repeat(2, 1fr); }
  .layout-article    { grid-template-columns: 1fr 260px; gap: 32px; }
  .magazine-archive-grid { grid-template-columns: repeat(2, 1fr); }
  .btn-google        { display: none; }
}

@media (max-width: 768px) {
  :root { --nav-h: 56px; --gap: 16px; }

  .nav-menu          { display: none; }
  .btn-hamburger     { display: flex; }

  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .layout-article    { grid-template-columns: 1fr; }
  .article-hero.has-media { grid-template-columns: 1fr; gap: 20px; }
  .article-hero .article-featured-img { margin: 4px 0 0; }
  .sidebar-sticky    { position: static; }
  .related-posts-grid { grid-template-columns: 1fr; }

  /* Simpler hero on mobile — just the image and title.
     !important is required to beat the inline display:block on these spans. */
  .post-card-hero-body { padding: 56px 18px 16px; }
  .post-card-hero-body .post-card-meta { display: none !important; } /* category + time */
  .post-card-hero-body .line-clamp-2   { display: none !important; } /* excerpt */

  .magazine-current  { flex-direction: column; }
  .magazine-current-img { width: 100%; max-width: 180px; }
  .magazine-archive-grid { grid-template-columns: repeat(2, 1fr); }

  .newsletter-form   { flex-direction: column; }

  .footer-inner      { flex-direction: column; gap: 24px; }
  .footer-bottom     { flex-direction: column; text-align: center; }
}

@media (max-width: 480px) {
  .magazine-archive-grid { grid-template-columns: 1fr; }
  .share-bar         { gap: 6px; }
}

/* ── 19. HOMEPAGE ─────────────────────────────────────── */

/* Hero grid */
.hero-grid {
  display: grid;
  grid-template-columns: 1fr 460px;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--r-card);
  overflow: hidden;
  margin-bottom: 24px;
}
.hero-main { background: var(--bg); }
.hero-side {
  background: var(--bg);
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 2px;
}
.hero-main-card {
  display: block;
  height: 100%;
}

/* Magazine promo fold — standout band */
.fold-magazine {
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 32px 0;
  margin: 8px 0;
}
.magazine-promo {
  display: flex;
  align-items: center;
  gap: 28px;
}
.magazine-promo-cover {
  flex-shrink: 0;
  width: 150px;
  border-radius: var(--r);
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0,0,0,0.35);
}
.magazine-promo-cover img { width: 100%; height: auto; display: block; }
.magazine-promo-body { flex: 1; }
.magazine-promo-issue {
  font-family: var(--f-mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent-text);
  margin-bottom: 6px;
}
.magazine-promo-issue::before {
  content: '';
  display: inline-block;
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 2px;
  margin-right: 9px;
  vertical-align: middle;
  position: relative;
  top: -1px;
}
html.dark .magazine-promo-issue { color: var(--accent-text); }
.magazine-promo-title {
  font-size: clamp(18px, 2.5vw, 24px);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 6px;
  line-height: 1.2;
}
.magazine-promo-desc {
  font-size: 13px;
  color: var(--text-sec);
  margin-bottom: 14px;
  line-height: 1.5;
  max-width: 520px;
}
.magazine-promo-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.magazine-promo-right { flex-shrink: 0; text-align: right; }

/* YouTube fold */
.fold-youtube {
  background: #080808;
  border-top: 1px solid rgba(255,255,255,0.05);
  border-bottom: 1px solid rgba(255,255,255,0.05);
  padding: 44px 0 52px;
}

/* ── YouTube fold: featured video + side list ── */
.yt-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 26px; }
.yt-eyebrow { display: flex; align-items: center; gap: 9px; color: #fff; font-family: var(--f-mono); font-size: 12px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; }
.yt-eyebrow::before { content: ""; width: 8px; height: 8px; border-radius: 2px; background: var(--accent); }
.yt-head h2 { font-family: var(--f-head); font-weight: 800; color: #fff; font-size: clamp(22px, 3vw, 36px); margin: 8px 0 0; letter-spacing: -0.01em; }
.yt-channel { flex-shrink: 0; display: inline-flex; align-items: center; gap: 8px; color: #141414; background: var(--accent); font-weight: 700; font-size: 13.5px; padding: 11px 18px; border-radius: 999px; text-decoration: none; white-space: nowrap; transition: background var(--t-fast); }
.yt-channel:hover { background: var(--accent-deep); }

.yt-grid { display: grid; grid-template-columns: 1.75fr 1fr; gap: 26px; align-items: start; }

/* play button (shared) */
.yt-play { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 64px; height: 64px; border-radius: 50%; background: var(--accent); display: flex; align-items: center; justify-content: center; transition: transform var(--t-fast), background var(--t-fast); box-shadow: 0 8px 30px rgba(0,0,0,0.45); }
.yt-play svg { width: 24px; height: 24px; margin-left: 4px; }
.yt-play-sm { width: 40px; height: 40px; box-shadow: 0 4px 14px rgba(0,0,0,0.4); }
.yt-play-sm svg { width: 15px; height: 15px; margin-left: 2px; }

/* featured */
.yt-feature { position: relative; border-radius: var(--r-card); overflow: hidden; aspect-ratio: 16/9; cursor: pointer; background: #1a1a1a; }
.yt-feature-thumb { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.yt-scrim { position: absolute; inset: 0; background: linear-gradient(to top, rgba(0,0,0,0.82) 0%, rgba(0,0,0,0.12) 46%, rgba(0,0,0,0.08) 100%); }
.yt-feature:hover .yt-play { transform: translate(-50%, -50%) scale(1.08); background: #fff; }
.yt-feature-cap { position: absolute; left: 24px; right: 24px; bottom: 20px; }
.yt-feature-ttl { font-family: var(--f-head); font-weight: 700; color: #fff; font-size: clamp(17px, 1.9vw, 24px); line-height: 1.22; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.yt-feature.is-playing { cursor: default; }
.yt-iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; }

/* side list — stretches to the featured video's height; cards share that height */
.yt-side { display: flex; flex-direction: column; gap: 14px; align-self: stretch; }
.yt-card { display: grid; grid-template-columns: 148px 1fr; gap: 13px; align-items: center; flex: 1 1 0; min-height: 0; width: 100%; text-align: left; background: none; border: 0; padding: 8px; margin: -8px; border-radius: 12px; cursor: pointer; transition: background var(--t-fast); font: inherit; }
.yt-card:hover { background: rgba(255,255,255,0.05); }
.yt-card-thumb { position: relative; border-radius: 10px; overflow: hidden; aspect-ratio: 16/9; background: #1a1a1a; }
.yt-card-thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.yt-card:hover .yt-card-thumb .yt-play { background: #fff; transform: translate(-50%, -50%) scale(1.08); }
.yt-card-body { min-width: 0; padding-top: 2px; }
.yt-card-ttl { font-family: var(--f-head); font-weight: 700; color: #fff; font-size: 15px; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; transition: color var(--t-fast); }
.yt-card:hover .yt-card-ttl { color: var(--accent); }

/* empty state */
.yt-empty { display: flex; align-items: center; gap: 18px; position: relative; min-height: 120px; padding: 28px; border-radius: var(--r-card); background: #111; border: 1px solid rgba(255,255,255,0.07); text-decoration: none; color: rgba(255,255,255,0.7); font-size: 15px; }
.yt-empty .yt-play { position: static; transform: none; width: 56px; height: 56px; flex-shrink: 0; }
.yt-empty:hover .yt-play { background: var(--accent-deep); }
.youtube-inner {
  display: flex;
  align-items: center;
  gap: 40px;
}
.youtube-copy { flex: 1; }
.youtube-copy .label { color: #fff; font-size: 13px; font-weight: 600; margin-bottom: 10px; display: block; }
.youtube-copy .label::before {
  content: '';
  display: inline-block;
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 2px;
  margin-right: 9px;
  vertical-align: middle;
  position: relative;
  top: -1px;
}
.youtube-copy h2 { font-size: clamp(22px, 3vw, 36px); margin-bottom: 12px; color: #fff; }
.youtube-copy p {
  font-size: 15px;
  color: rgba(255,255,255,0.5);
  margin-bottom: 24px;
  line-height: 1.65;
  max-width: 420px;
}
.youtube-embed {
  flex-shrink: 0;
  width: 420px;
  max-width: 100%;
  aspect-ratio: 16/9;
  border-radius: var(--r-card);
  overflow: hidden;
  background: #111;
}
.youtube-embed iframe { width: 100%; height: 100%; border: none; display: block; }
.youtube-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #111;
  border: 1px solid rgba(255,255,255,0.07);
  transition: border-color var(--t-fast);
  text-decoration: none;
}
.youtube-placeholder:hover { border-color: var(--accent); }
.youtube-play-btn {
  width: 64px;
  height: 64px;
  background: var(--accent);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--t-fast), transform var(--t-fast);
  flex-shrink: 0;
}
.youtube-placeholder:hover .youtube-play-btn {
  background: var(--accent-deep);
  transform: scale(1.08);
}

/* Markets + Opinions two-column */
.markets-opinions-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}
.markets-opinions-col { min-width: 0; }

/* Homepage newsletter banner */
/* Homepage newsletter — dark card ([cim_newsletter]) */
.fold-newsletter {
  padding: 8px 0;
  margin: 40px 0;
}
.newsletter-banner-inner {
  display: block;
  background: #141414;
  border-radius: var(--r-card);
  padding: 40px 44px;
}
.newsletter-eyebrow { display: inline-block; color: #fff; margin-bottom: 10px; }
.newsletter-eyebrow::before {
  content: '';
  display: inline-block;
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 2px;
  margin-right: 9px;
  vertical-align: middle;
  position: relative;
  top: -1px;
}
.newsletter-banner-copy h2 { font-family: var(--f-head); font-size: clamp(22px, 2.6vw, 28px); color: #fff; margin-bottom: 8px; }
.newsletter-banner-copy p  { font-size: 14px; color: rgba(255,255,255,0.6); margin-bottom: 18px; line-height: 1.5; }
.newsletter-banner-form { display: flex; gap: 12px; flex-wrap: wrap; max-width: 480px; }
.newsletter-banner-form input[type="email"] {
  flex: 1 1 200px;
  background: #1f1f1f;
  border: 1px solid #333;
  border-radius: var(--r);
  padding: 12px 15px;
  font-size: 14px;
  color: #fff;
  outline: none;
  transition: border-color var(--t-fast);
}
.newsletter-banner-form input[type="email"]::placeholder { color: rgba(255,255,255,0.4); }
.newsletter-banner-form input[type="email"]:focus { border-color: var(--accent); }
.newsletter-banner-form button,
.newsletter-banner-form input[type="submit"] {
  background: var(--accent);
  color: #141414;
  font-family: var(--f-mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 12px 20px;
  border-radius: var(--r);
  border: none;
  cursor: pointer;
  white-space: nowrap;
  transition: background var(--t-fast);
  -webkit-appearance: none;
  appearance: none;
}
.newsletter-banner-form button:hover,
.newsletter-banner-form input[type="submit"]:hover { background: var(--accent-deep); }

/* MC4WP / generic plugin form layout inside the dark card */
.newsletter-banner-form .mc4wp-form,
.newsletter-banner-form form { width: 100%; }
.newsletter-banner-form .mc4wp-form-fields {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}
.newsletter-banner-form .mc4wp-form-fields input[type="email"] { flex: 1 1 200px; }
.newsletter-banner-form label,
.newsletter-banner-form .mc4wp-form-fields p,
.newsletter-banner-form small {
  flex-basis: 100%;
  font-size: 12px;
  line-height: 1.4;
  color: rgba(255,255,255,0.45);
  margin: 8px 0 0;
}
.newsletter-banner-form label a,
.newsletter-banner-form .mc4wp-form-fields p a { color: var(--accent); text-decoration: underline; }
.newsletter-banner-form .mc4wp-response { flex-basis: 100%; font-size: 13px; color: rgba(255,255,255,0.7); margin-top: 6px; }

/* Responsive — homepage additions */
@media (max-width: 1024px) {
  .youtube-embed { width: 380px; }
}
@media (max-width: 860px) {
  .yt-grid { grid-template-columns: 1fr; }
  .yt-head { flex-direction: column; align-items: flex-start; gap: 14px; }
  /* stop the desktop "fill the featured height" behaviour collapsing cards on mobile */
  .yt-side { align-self: auto; }
  .yt-card { flex: 0 0 auto; min-height: 0; align-items: start; }
}
@media (max-width: 768px) {
  .hero-grid { grid-template-columns: 1fr; }
  .youtube-inner { flex-direction: column; gap: 28px; }
  .youtube-embed { width: 100%; }
  .yt-card { grid-template-columns: 136px 1fr; }
  .markets-opinions-grid { grid-template-columns: 1fr; }
  .newsletter-banner-inner { padding: 26px 22px; }
  .newsletter-banner-form { max-width: 100%; flex-direction: column; }
  .newsletter-banner-form button,
  .newsletter-banner-form input[type="submit"] { width: 100%; }
  .magazine-promo { flex-direction: column; gap: 16px; }
}

/* Media partners strip ([cim_partners]) */
.fold-partners {
  padding: 34px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.cim-partners-head { text-align: center; margin-bottom: 22px; }
.cim-partners-marquee {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
          mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
}
.cim-partners-track {
  display: flex;
  align-items: center;
  gap: 56px;
  width: max-content;
  animation: cim-partners-scroll 34s linear infinite;
}
.cim-partners-marquee:hover .cim-partners-track { animation-play-state: paused; }
@keyframes cim-partners-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}
.cim-partner-logo { flex-shrink: 0; display: inline-flex; align-items: center; }
/* Higher specificity + !important so Elementor / SVG intrinsic size can't
   blow the logos up (the strip sits inside an Elementor Shortcode widget). */
.fold-partners .cim-partner-logo img {
  height: 44px !important;
  width: auto !important;
  max-width: 150px !important;
  object-fit: contain;
  filter: grayscale(1);
  opacity: 0.62;
  transition: filter var(--t-fast), opacity var(--t-fast);
}
.fold-partners .cim-partner-logo:hover img { filter: grayscale(0); opacity: 1; }
.cim-partners-cta { text-align: center; margin-top: 24px; }
@media (max-width: 768px) {
  .cim-partners-track { gap: 40px; }
  .fold-partners .cim-partner-logo img { height: 34px !important; max-width: 130px !important; }
}

/* Magazine archive ([cim_magazine_archive]) */
.cim-mag-mast { text-align: center; padding: 8px 0 26px; border-bottom: 1px solid var(--border); margin-bottom: 30px; }
.cim-mag-mast .label-accent { letter-spacing: 0.16em; }
.cim-mag-mast h1 { font-family: var(--f-head); font-weight: 800; font-size: clamp(40px, 7vw, 58px); letter-spacing: 0.03em; margin: 10px 0; }
.cim-mag-mast p { font-size: 15px; color: var(--text-sec); max-width: 560px; margin: 0 auto; line-height: 1.6; }

.cim-mag-feat { display: flex; gap: 28px; align-items: center; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-card); padding: 24px; margin-bottom: 36px; }
.cim-mag-feat > .cim-mag-cover { width: 160px; flex-shrink: 0; }
.cim-mag-feat-body { min-width: 0; }
.cim-mag-feat-body .label { display: inline-block; margin-bottom: 8px; }
.cim-mag-feat-body h2 { font-family: var(--f-head); font-weight: 700; font-size: clamp(22px, 3vw, 28px); line-height: 1.14; margin-bottom: 10px; }
.cim-mag-feat-body p { font-size: 14px; color: var(--text-sec); line-height: 1.6; margin-bottom: 18px; max-width: 480px; }

.cim-mag-year { display: flex; align-items: baseline; gap: 14px; margin: 0 0 18px; }
.cim-mag-year h3 { font-family: var(--f-head); font-weight: 800; font-size: 22px; margin: 0; }
.cim-mag-year .rule { flex: 1; height: 1px; background: var(--border); }
.cim-mag-year .cnt { font-size: 12px; color: var(--text-sec); }
.cim-mag-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 22px; margin-bottom: 38px; }

.cim-mag-cover { display: block; aspect-ratio: 3 / 4; border-radius: var(--r); overflow: hidden; background: var(--img-ph); box-shadow: 0 10px 26px rgba(0,0,0,0.22); }
.cim-mag-cover img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform var(--t-med); }
.cim-mag-item:hover .cim-mag-cover img { transform: scale(1.03); }
.cim-mag-cover-ph { width: 100%; height: 100%; display: flex; flex-direction: column; justify-content: space-between; padding: 14px; background: linear-gradient(160deg, #2a1c33, #0d0d11); color: #fff; }
.cim-mag-cover-ph .mh { font-family: var(--f-head); font-weight: 800; font-size: 12px; letter-spacing: 0.1em; text-align: center; }
.cim-mag-cover-ph .t { font-family: var(--f-head); font-weight: 700; font-size: 15px; line-height: 1.15; }
.cim-mag-meta { margin: 11px 2px 0; }
.cim-mag-meta b { font-family: var(--f-head); font-weight: 700; font-size: 15px; }
.cim-mag-meta span { display: block; font-size: 12px; color: var(--text-sec); margin-top: 2px; }

@media (max-width: 600px) {
  .cim-mag-feat { flex-direction: column; align-items: flex-start; }
  .cim-mag-grid { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 16px; }
}

/* Magazine issue landing (Template: Magazine Issue) — full-bleed bands */
.cim-issue-inner { max-width: 1100px; margin: 0 auto; padding: 0 var(--px); }
.cim-issue-back { display: inline-block; font-family: var(--f-mono); font-size: 13px; font-weight: 600; color: var(--text-sec); margin-bottom: 22px; transition: color var(--t-fast); }
.cim-issue-back:hover { color: var(--accent-text); }

/* Hero band — light, full-bleed, sized to content (no forced viewport height) */
.cim-issue-hero-band { position: relative; overflow: hidden; background: var(--surface); padding: 40px 0 52px; }
.cim-issue-hero-band::before { content: ""; position: absolute; left: 8%; top: 50%; width: 480px; height: 480px; max-width: 55%; transform: translateY(-50%); border-radius: 50%; background: radial-gradient(circle, rgba(255,210,0,0.18), rgba(255,210,0,0) 68%); pointer-events: none; }
.cim-issue-hero { position: relative; display: flex; gap: 56px; align-items: center; }
.cim-issue-cover { width: 340px; flex-shrink: 0; aspect-ratio: 3 / 4; border-radius: var(--r); overflow: hidden; background: var(--img-ph); box-shadow: 0 26px 60px rgba(0,0,0,0.30); }
.cim-issue-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cim-issue-intro { min-width: 0; }
.cim-issue-eyebrow { display: inline-block; margin-bottom: 12px; font-size: 13px; letter-spacing: 0.12em; }
.cim-issue-title { font-family: var(--f-head); font-weight: 800; font-size: clamp(32px, 4.8vw, 50px); line-height: 1.05; letter-spacing: -0.02em; margin: 0 0 16px; }
.cim-issue-desc { font-size: 16px; color: var(--text-sec); line-height: 1.6; max-width: 480px; margin: 0 0 24px; }
.cim-issue-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.cim-issue-actions .btn { padding: 14px 30px; font-size: 12px; }

/* "In this issue" band — full-bleed, card items */
.cim-issue-body-band { background: var(--bg); padding: 48px 0; }
.cim-issue-body-band .section-heading { margin-bottom: 26px; }
.cim-issue-body { font-size: 15px; line-height: 1.6; }
.cim-issue-body > ul { column-count: 2; column-gap: 20px; }
.cim-issue-body ul { list-style: none; padding-left: 0; margin: 0; }
.cim-issue-body li { list-style: none; break-inside: avoid; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); padding: 20px 22px; margin: 0 0 16px; color: var(--text-sec); }
.cim-issue-body li::marker { content: ""; }
.cim-issue-body li strong { display: block; font-family: var(--f-head); font-size: 20px; font-weight: 700; line-height: 1.2; letter-spacing: -0.01em; color: var(--text); margin-bottom: 8px; }
.cim-issue-body li br { display: none; }
.cim-issue-body li p { margin: 0; color: var(--text-sec); }
.cim-issue-body li p:not(:last-child) { margin-bottom: 0.6em; }

/* Subscribe band */
.cim-issue-sub-band { background: var(--bg); padding: 0 0 56px; }

@media (max-width: 768px) {
  .cim-issue-hero-band { padding: 28px 0 34px; }
  .cim-issue-hero-band::before { display: none; }
  .cim-issue-hero { flex-direction: column; align-items: flex-start; gap: 24px; }
  .cim-issue-cover { width: 230px; }
  .cim-issue-actions { width: 100%; }
  .cim-issue-actions .btn { flex: 1 1 auto; justify-content: center; text-align: center; }
  .cim-issue-body-band { padding: 34px 0; }
  .cim-issue-body > ul { column-count: 1; }
}

/* ── Elementor pages inherit CIM fonts (About, Magazine, etc.) ──
   Elementor has its own font settings; this forces its text widgets to use
   the site fonts so every page matches: Inter for body, Playfair for headings. */
.elementor-widget-text-editor,
.elementor-widget-text-editor p,
.elementor-widget-text-editor li,
.elementor-widget-text-editor a,
.elementor-widget-text-editor span,
.elementor-button-text,
.elementor-widget-icon-list .elementor-icon-list-text,
.elementor-widget-icon-box .elementor-icon-box-description {
  font-family: var(--f-body) !important;
}
.elementor-heading-title,
.elementor-widget-icon-box .elementor-icon-box-title {
  font-family: var(--f-head) !important;
}

/* ── 20. UTILITIES ────────────────────────────────────── */
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
.text-accent  { color: var(--accent-text); }
.text-muted   { color: var(--text-muted); }
.text-sec     { color: var(--text-sec); }
.mt-auto      { margin-top: auto; }
.truncate     { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.line-clamp-2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.line-clamp-3 { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

/* ============================================================
   CIM ACADEMY (/academy/ hub, pillar + lesson pages)
   Minimal black & white; animated hero on the hub only.
   ============================================================ */
.ac-wrap{width:min(1180px,92vw);margin:0 auto}
.ac-wrap-narrow{width:min(760px,92vw);margin:0 auto}
.ac-k{font-family:var(--f-mono);font-size:12px;font-weight:600;letter-spacing:.28em;text-transform:uppercase;color:#999}
.ac-sh{font-family:var(--f-head);font-weight:800;font-size:clamp(28px,4vw,42px);letter-spacing:-.02em;line-height:1.1;color:#0b0b0b}
.ac-ar{transition:transform .2s}

/* Hero (animated, dark) */
/* Hero — Indian palace image + Bitcoin cursor trail, text bottom-left */
.ac-hero{position:relative;min-height:100vh;overflow:hidden;background:#0a0a0a}
.ac-hero-img{position:absolute;inset:0;background-size:cover;background-position:center 42%;background-repeat:no-repeat;z-index:0}
.ac-hero-scrim{position:absolute;inset:0;z-index:1;background:linear-gradient(to top,rgba(5,5,5,.85) 0%,rgba(5,5,5,.25) 40%,rgba(5,5,5,0) 70%),linear-gradient(to right,rgba(5,5,5,.7) 0%,rgba(5,5,5,.15) 45%,rgba(5,5,5,0) 75%),linear-gradient(to bottom,rgba(5,5,5,.5) 0%,rgba(5,5,5,0) 30%)}
#academy-bg{position:absolute;inset:0;width:100%;height:100%;display:block;z-index:6;pointer-events:none}
.ac-hero-content{position:absolute;left:0;right:0;bottom:0;z-index:5;padding-bottom:72px}
.ac-eyebrow{font-family:var(--f-mono);font-size:12px;font-weight:600;letter-spacing:.3em;text-transform:uppercase;color:rgba(255,255,255,.7);margin-bottom:18px}
.ac-h1{font-family:var(--f-head);font-weight:800;color:#fff;font-size:clamp(38px,6vw,76px);line-height:1.03;letter-spacing:-.02em;margin:0 0 18px;max-width:720px}
.ac-h1 em{font-style:italic;font-weight:600}
.ac-lead{font-size:clamp(15px,1.7vw,19px);line-height:1.6;color:rgba(255,255,255,.82);max-width:540px;margin:0 0 28px}
.ac-search{display:flex;gap:8px;width:min(480px,86vw)}
.ac-search input{flex:1;background:rgba(255,255,255,.1);border:1px solid rgba(255,255,255,.22);border-radius:999px;padding:13px 20px;color:#fff;font-size:14px;font-family:inherit;outline:none;backdrop-filter:blur(4px)}
.ac-search input::placeholder{color:rgba(255,255,255,.55)}
.ac-search button{background:#fff;color:#0a0a0a;border:0;border-radius:999px;padding:0 24px;font-weight:600;font-size:14px;cursor:pointer}
.ac-scroll{position:absolute;bottom:24px;right:28px;z-index:5;color:rgba(255,255,255,.6);font-size:11px;letter-spacing:.2em;text-transform:uppercase}
@media(max-width:820px){ .ac-hero-content{padding-bottom:52px} }

/* Translucent CIM nav — Academy hub only (solid on scroll) */
body.academy-hub .site-header{position:fixed;top:0;left:0;right:0;width:100%;background:transparent;border-bottom:0;backdrop-filter:none;-webkit-backdrop-filter:none}
/* Don't let the logged-in WP admin bar cover the fixed Academy header */
body.admin-bar.academy-hub .site-header{top:32px}
@media screen and (max-width:782px){body.admin-bar.academy-hub .site-header{top:46px}}
body.academy-hub .site-header, body.academy-hub .site-header a{color:#fff;text-shadow:0 1px 10px rgba(0,0,0,.5)}
body.academy-hub .nav-menu > ul > li > a{color:rgba(255,255,255,.88)}
body.academy-hub .nav-menu > ul > li > a:hover,
body.academy-hub .nav-menu > ul > li.current-menu-item > a,
body.academy-hub .nav-menu > ul > li.current-menu-ancestor > a{color:#fff;background:rgba(255,255,255,.15)}
/* Dropdown panels keep their own dark-on-white styling (don't inherit the white hero text) */
body.academy-hub .nav-menu .sub-menu{background:#fff;border-color:rgba(0,0,0,.12);box-shadow:0 10px 26px rgba(0,0,0,.2)}
body.academy-hub .nav-menu .sub-menu a,
body.academy-hub .nav-menu .sub-menu a:link,
body.academy-hub .nav-menu .sub-menu a:visited{color:#141414;text-shadow:none}
body.academy-hub .nav-menu .sub-menu a:hover,
body.academy-hub .nav-menu .sub-menu a:focus{color:#141414;background:#f0f0f0;text-shadow:none}
body.academy-hub .site-logo-img{filter:brightness(0) invert(1)}
body.academy-hub .btn-google, body.academy-hub .btn-theme{display:none}
body.academy-hub .btn-search{color:#fff}
body.academy-hub .btn-search:hover{color:#fff;background:rgba(255,255,255,.14)}
body.academy-hub .btn-hamburger span{background:#fff}
/* Back to CIM button (Academy hub only) */
.btn-back-cim{display:inline-flex;align-items:center;gap:6px;height:34px;padding:0 15px;border:1px solid rgba(255,255,255,.55);border-radius:999px;color:#fff;font-size:13px;font-weight:600;letter-spacing:.02em;white-space:nowrap;text-shadow:0 1px 10px rgba(0,0,0,.5);transition:background .2s,border-color .2s,color .2s}
.btn-back-cim:hover{background:rgba(255,255,255,.14);border-color:#fff;color:#fff}
body.academy-hub.nav-solid .btn-back-cim{border-color:rgba(255,255,255,.4);text-shadow:none}
@media (max-width:1100px){.btn-back-cim{display:none}}
body.academy-hub.nav-solid .site-header{background:rgba(10,10,10,.85);backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px)}
body.academy-hub.nav-solid .site-header, body.academy-hub.nav-solid .site-header a{text-shadow:none}

/* Sections */
.ac-sec{padding:80px 0}
.ac-overview{text-align:center}
.ac-overview .ac-k{margin-bottom:14px}
.ac-overview h2{margin-bottom:20px}
.ac-overview p{font-size:17px;line-height:1.75;color:#6b6b6b;max-width:760px;margin:0 auto 14px}

/* Start cards */
.ac-start .ac-sh{margin-bottom:30px}
.ac-steps{display:grid;grid-template-columns:repeat(4,1fr);gap:18px}
.ac-step{border:1px solid #e7e7e7;border-radius:16px;padding:24px;transition:.25s}
.ac-step:hover{background:#0b0b0b;color:#fff;border-color:#0b0b0b}
.ac-num{font-family:var(--f-head);font-size:14px;font-weight:700;color:#bbb;margin-bottom:16px}
.ac-step:hover .ac-num{color:#777}
.ac-step h4{font-family:var(--f-head);font-size:19px;font-weight:700;line-height:1.2;margin-bottom:6px}
.ac-step p{font-size:13px;color:#6b6b6b}
.ac-step:hover p{color:#bbb}

/* Topic cards */
.ac-topics-head{text-align:center;margin-bottom:46px}
.ac-topics-head .ac-k{margin-bottom:14px}
.ac-catgrid{display:grid;grid-template-columns:repeat(2,1fr);gap:22px}
.ac-catcard{border:1px solid #e7e7e7;border-radius:18px;padding:34px 32px;min-height:220px;display:flex;flex-direction:column;justify-content:space-between;transition:.25s;color:#0b0b0b}
.ac-catcard .ac-glyph{font-family:var(--f-head);font-size:40px;line-height:1;margin-bottom:auto}
.ac-catcard h3{font-family:var(--f-head);font-weight:700;font-size:26px;margin:20px 0 8px}
.ac-catcard p{font-size:14px;line-height:1.55;color:#6b6b6b;max-width:420px}
.ac-catmeta{display:flex;align-items:center;justify-content:space-between;margin-top:22px;font-size:12px;letter-spacing:.06em;text-transform:uppercase;color:#999}
.ac-catcard:hover{background:#0b0b0b;color:#fff;border-color:#0b0b0b;transform:translateY(-4px)}
.ac-catcard:hover p{color:#bdbdbd}
.ac-catcard:hover .ac-catmeta{color:#888}
.ac-catcard:hover .ac-ar{transform:translateX(5px);color:#fff}

/* Reader favourites (dark list) */
.ac-fav{background:#0b0b0b;color:#fff;padding:80px 0}
.ac-fav .ac-k{color:#8a8a8a}
.ac-flist{list-style:none;max-width:900px;margin:0}
.ac-flist li{border-top:1px solid #242424}
.ac-flist li:last-child{border-bottom:1px solid #242424}
.ac-flist li a{display:grid;grid-template-columns:120px 1fr auto;gap:16px;align-items:center;padding:18px 4px;transition:padding .15s;color:#fff}
.ac-fl-cat{font-size:11px;letter-spacing:.1em;text-transform:uppercase;color:#8a8a8a}
.ac-fl-t{font-family:var(--f-head);font-size:18px;font-weight:700}
.ac-fl-rt{font-size:12px;color:#777;white-space:nowrap}
.ac-flist li a:hover{padding-left:10px}

/* FAQ */
.ac-faq-head{text-align:center;margin-bottom:40px}
.ac-faq-head .ac-k{margin-bottom:14px}
.ac-faq-wrap{max-width:820px;margin:0 auto}
.ac-qa{border-bottom:1px solid #e7e7e7;padding:22px 0}
.ac-qa .q{font-family:var(--f-head);font-size:19px;font-weight:700;margin-bottom:8px;color:#0b0b0b}
.ac-qa .a{font-size:15px;color:#6b6b6b;line-height:1.65}

/* CTA */
.ac-ctaband{background:#0b0b0b;color:#fff;text-align:center;padding:70px 0}
.ac-ctaband p{color:#b0b0b0;font-size:15px;margin-bottom:26px}
.ac-cta-btn{display:inline-block;background:#fff;color:#0b0b0b;font-weight:600;font-size:14px;padding:15px 30px;border-radius:999px}
/* Newsletter form on the Academy band: reuse the homepage form styling, centered */
.ac-ctaband .ac-cta-form{margin:0 auto;justify-content:center}

/* ── Lesson layout: content + sticky Table of Contents ── */
.ac-lesson-grid{width:min(1040px,92vw);margin:0 auto;padding:36px 0 64px}
.ac-lesson-grid.has-toc{display:grid;grid-template-columns:minmax(0,1fr) 230px;grid-template-areas:"main toc";gap:52px;align-items:start}
.ac-lesson-main{grid-area:main;min-width:0}
.ac-lesson-aside{grid-area:toc}
.ac-lesson-body h2,.ac-lesson-body h3{scroll-margin-top:calc(var(--nav-h) + 24px)}
.ac-toc{position:sticky;top:calc(var(--nav-h) + 24px);max-height:calc(100vh - var(--nav-h) - 48px);overflow:auto}
.ac-toc-h{font-family:var(--f-mono);text-transform:uppercase;letter-spacing:.08em;font-size:11px;color:var(--text-sec);margin:0 0 12px;list-style:none;cursor:default;pointer-events:none}
.ac-toc-h::-webkit-details-marker{display:none}
.ac-toc-h::marker{content:""}
.ac-toc-list{list-style:none;margin:0;padding:0;border-left:1px solid var(--border)}
.ac-toc-list li{margin:0}
.ac-toc-list a{display:block;padding:7px 0 7px 16px;margin-left:-1px;border-left:2px solid transparent;color:var(--text-sec);font-size:13.5px;line-height:1.4;text-decoration:none;transition:color .15s,border-color .15s}
.ac-toc-list a:hover{color:var(--text)}
.ac-toc-list a.is-active{color:var(--text);border-left-color:var(--accent);font-weight:600}
.ac-toc-list .ac-toc-sub a{padding-left:30px;font-size:13px}
@media (max-width:980px){
  .ac-lesson-grid.has-toc{grid-template-columns:1fr;grid-template-areas:"toc" "main";gap:0}
  .ac-lesson-aside{margin:0 0 24px}
  .ac-toc{position:static;max-height:none;overflow:visible;border:1px solid var(--border);border-radius:var(--r-card);padding:4px 18px}
  .ac-toc-h{pointer-events:auto;cursor:pointer;display:flex;align-items:center;justify-content:space-between;margin:0;padding:14px 0}
  .ac-toc-h::after{content:"";width:8px;height:8px;border-right:2px solid var(--text-sec);border-bottom:2px solid var(--text-sec);transform:rotate(45deg);transition:transform .2s;margin-right:4px}
  .ac-toc[open] .ac-toc-h::after{transform:rotate(-135deg)}
  .ac-toc[open] .ac-toc-list{padding-bottom:12px}
  .ac-toc-list{border-left:0}
  .ac-toc-list a{padding-left:0}
  .ac-toc-list a.is-active{border-left:0;color:var(--text)}
  .ac-toc-list .ac-toc-sub a{padding-left:16px}
}

/* Breadcrumbs */
.ac-crumbs{padding:26px 0 10px}
.ac-crumbs ol{list-style:none;display:flex;flex-wrap:wrap;gap:8px;font-size:12px;color:#999;padding:0;margin:0}
.ac-crumbs li:not(:last-child)::after{content:"›";margin-left:8px;color:#ccc}
.ac-crumbs a{color:#777}
.ac-crumbs a:hover{color:#0b0b0b}

/* Pillar page */
.ac-pillar{padding:0 0 70px}
.ac-eyebrow-dark{font-family:var(--f-mono);font-size:12px;font-weight:600;letter-spacing:.2em;text-transform:uppercase;color:#999;margin-bottom:12px}
.ac-pillar-head{padding:10px 0 34px;border-bottom:1px solid #eee;margin-bottom:34px}
.ac-pillar-h1{font-family:var(--f-head);font-weight:800;font-size:clamp(34px,5vw,54px);letter-spacing:-.02em;line-height:1.05;margin-bottom:16px}
.ac-pillar-intro{font-size:18px;line-height:1.7;color:#555;max-width:780px}
.ac-lesson-list{display:grid;grid-template-columns:1fr 1fr;gap:0 40px}
.ac-lesson-row{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:20px 0;border-top:1px solid #eee;transition:padding .15s;color:#0b0b0b}
.ac-lesson-row:hover{padding-left:8px}
.ac-lesson-txt h3{font-family:var(--f-head);font-size:18px;font-weight:700;line-height:1.25;margin:0 0 4px}
.ac-lesson-txt p{font-size:13px;color:#777;margin:0}
.ac-lesson-meta{font-size:12px;color:#999;white-space:nowrap}
.ac-empty{color:#999;padding:30px 0}
.ac-backhub{margin-top:34px;font-size:13px}
.ac-backhub a{color:#555;border-bottom:1px solid #ddd;padding-bottom:2px}
.ac-backhub a:hover{color:#0b0b0b}

/* Lesson page */
.ac-lesson{padding:0 0 70px}
.ac-lesson-head{padding:6px 0 10px}
.ac-lesson-topic{display:inline-block;font-family:var(--f-mono);font-size:11px;font-weight:700;letter-spacing:.12em;text-transform:uppercase;color:#777;margin-bottom:14px}
.ac-lesson-topic:hover{color:#0b0b0b}
.ac-lesson-h1{font-family:var(--f-head);font-weight:800;font-size:clamp(30px,4.4vw,46px);line-height:1.1;letter-spacing:-.02em;margin-bottom:14px}
.ac-lesson-byline{display:flex;gap:8px;font-size:12px;color:#999;margin-bottom:18px}
.ac-lesson-standfirst{font-size:19px;line-height:1.6;color:#444;margin-bottom:24px}
.ac-lesson-img{border-radius:14px;overflow:hidden;margin:10px 0 28px;box-shadow:var(--shadow-card)}
.ac-lesson-img img{width:100%;height:auto;display:block}
.ac-lesson-body{font-size:17px}
/* Keep Academy monochrome — override the news yellow link/quote accents */
.ac-lesson-body a{color:#0b0b0b;text-decoration:underline;text-decoration-color:#0b0b0b;text-decoration-thickness:2px;text-underline-offset:3px}
.ac-lesson-body a:hover{background:#f1f1f1;text-decoration-color:#0b0b0b}
.ac-lesson-body blockquote{border-left-color:#0b0b0b}
.ac-lesson-disclaimer{margin-top:30px;padding-top:18px;border-top:1px solid #eee;font-size:13px;color:#999}
.ac-related{margin-top:44px;padding-top:30px;border-top:1px solid #eee}
.ac-related .ac-k{margin-bottom:18px}
.ac-related-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:14px}
.ac-related-card{display:flex;align-items:center;justify-content:space-between;gap:12px;border:1px solid #e7e7e7;border-radius:12px;padding:18px;transition:.2s;color:#0b0b0b}
.ac-related-card:hover{background:#0b0b0b;color:#fff;border-color:#0b0b0b}
.ac-related-card h4{font-family:var(--f-head);font-size:16px;font-weight:700;line-height:1.25;margin:0}

@media(max-width:820px){
  .ac-steps,.ac-catgrid,.ac-lesson-list,.ac-related-grid{grid-template-columns:1fr}
  .ac-flist li a{grid-template-columns:1fr;gap:4px}
  .ac-fl-rt{display:none}
  .ac-sec,.ac-fav,.ac-ctaband{padding:56px 0}
}

/* ── Editorial callouts (auto-styled in article body) ── */
/* Key points — card with yellow square markers */
.article-body .cim-keypoints { background: var(--card); border: 1px solid var(--border); border-radius: var(--r-card); box-shadow: var(--shadow-card); padding: 22px 24px; margin: 0 0 30px; }
.article-body .cim-keypoints-h { font-family: var(--f-head); font-size: 18px; font-weight: 700; margin: 0 0 14px; }
.article-body .cim-keypoints ul { list-style: none; margin: 0; padding: 0; }
.article-body .cim-keypoints li { position: relative; padding-left: 22px; margin: 0 0 10px; font-size: 16px; line-height: 1.55; }
.article-body .cim-keypoints li:last-child { margin-bottom: 0; }
.article-body .cim-keypoints li::before { content: ""; position: absolute; left: 0; top: 9px; width: 7px; height: 7px; background: var(--accent); border-radius: 2px; }

/* Editorial note — hairline bordered box, secondary */
.article-body .cim-ednote { border: 1px solid var(--border-strong); border-radius: 10px; padding: 16px 18px; margin: 30px 0; }
.article-body .cim-ednote p { margin: 0; font-size: 14px; line-height: 1.65; color: var(--text-sec); }
.article-body .cim-ednote strong { color: var(--text); }

/* ============================================================
   ADVERTISE PAGE (Template: Advertise) — content in block editor,
   sections via [cim_ad_*] shortcodes
   ============================================================ */
.adv { width: min(var(--maxw), 92vw); margin: 0 auto; padding: 48px 0 40px; }
.adv-eyebrow { display: inline-flex; align-items: center; gap: 9px; font-size: 13px; letter-spacing: 0.12em; margin-bottom: 16px; }
.adv-eyebrow::before { content: ''; display: inline-block; width: 9px; height: 9px; background: var(--accent); border-radius: 2px; }
.adv-h1 { font-family: var(--f-head); font-weight: 800; font-size: clamp(34px, 4.6vw, 52px); line-height: 1.06; letter-spacing: -0.02em; margin: 0 0 24px; max-width: 980px; }

/* Body (block-editor content) */
.adv-body p { font-size: 17px; color: var(--text-sec); line-height: 1.75; margin: 0 0 18px; max-width: 860px; }
.adv-body h2 { font-family: var(--f-head); font-weight: 800; font-size: clamp(26px, 3vw, 36px); letter-spacing: -0.01em; line-height: 1.12; margin: 72px 0 18px; display: flex; align-items: center; gap: 12px; }
.adv-body h2::before { content: ''; flex-shrink: 0; width: 10px; height: 10px; background: var(--accent); border-radius: 2px; }
.adv-body h3 { font-family: var(--f-mono); font-size: 13px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-muted); margin: 30px 0 14px; }
.adv-body a { color: var(--accent-text); text-decoration: underline; }
/* Buttons: uniform size + correct colours (override the generic link styles) */
.adv-body .btn { text-decoration: none; padding: 14px 28px; font-size: 13px; }
.adv-body .btn-primary { color: #141414; }
.adv-body .btn-ghost { color: var(--text); }
.adv-body .btn-ghost-light { color: #fff; }
.adv-body ul { margin: 0 0 18px; padding-left: 1.4em; max-width: 860px; color: var(--text-sec); font-size: 17px; }
.adv-body li { margin-bottom: 6px; }

/* Light ghost button for dark bands */
.btn-ghost-light { background: transparent; border: 1px solid rgba(255,255,255,0.28); color: #fff; }
.btn-ghost-light:hover { border-color: rgba(255,255,255,0.6); background: rgba(255,255,255,0.06); color: #fff; }

/* CTA row */
.cim-ad-cta { display: flex; gap: 12px; flex-wrap: wrap; margin: 20px 0 8px; }
.cim-ad-cta.center { justify-content: center; }

/* Reach band */
.cim-ad-reach { background: #141414; border-radius: 18px; padding: 34px 20px; display: grid; grid-template-columns: repeat(3, 1fr); text-align: center; color: #fff; margin: 32px 0 8px; }
.cim-ad-reach .cell { padding: 8px 18px; border-right: 1px solid #2a2a2a; }
.cim-ad-reach .cell:last-child { border-right: 0; }
.cim-ad-reach .n { font-family: var(--f-head); font-size: clamp(30px, 3.4vw, 44px); font-weight: 700; line-height: 1; }
.cim-ad-reach .t { color: #9a9a9a; font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; margin-top: 10px; }

/* Offer / mini cards */
.cim-ad-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; margin: 20px 0 8px; }
/* Centre a lone card on the last row instead of leaving it hanging left */
.cim-ad-cards > .cim-ad-card:last-child:nth-child(3n+1) { grid-column: 2; }
.cim-ad-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--r-card); box-shadow: var(--shadow-card); padding: 26px; }
.cim-ad-card .pill { display: inline-block; background: var(--surface); color: var(--text-sec); font-family: var(--f-mono); font-size: 10px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; padding: 4px 10px; border-radius: 5px; margin-bottom: 12px; }
.cim-ad-card h4 { font-family: var(--f-head); font-size: 20px; font-weight: 700; margin: 0 0 10px; line-height: 1.2; }
.cim-ad-card p { font-size: 15px; color: var(--text-sec); line-height: 1.6; margin: 0; }
.cim-ad-card.mini { background: var(--surface); box-shadow: none; }
.cim-ad-card.mini h4 { font-size: 18px; }

/* Standards dark panel */
.cim-ad-standards { background: #141414; border-radius: 18px; padding: 34px; display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 20px 0 8px; }
.cim-ad-std { background: #1a1a1a; border: 1px solid #2a2a2a; border-left: 3px solid var(--accent); border-radius: 10px; padding: 18px 20px; display: flex; gap: 13px; align-items: flex-start; }
.cim-ad-std .cim-ad-std-ic { flex-shrink: 0; width: 22px; height: 22px; color: var(--accent); margin-top: 1px; }
.cim-ad-std p { font-size: 15px; color: #d2d2d2; line-height: 1.55; margin: 0; }

/* Travel stats (inside magazine band) — number over label, 3 across */
.cim-ad-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px 30px; margin: 6px 0 22px; max-width: none; }
.cim-ad-stat { display: block; }
.cim-ad-stat b { display: block; font-family: var(--f-head); font-size: 30px; font-weight: 800; line-height: 1; margin-bottom: 7px; }
.cim-ad-stat span { font-size: 13.5px; color: var(--text-sec); line-height: 1.45; }

/* Magazine (NARRATIVE) band */
.cim-ad-mag { background: var(--surface); border: 1px solid var(--border); border-radius: 18px; padding: 40px; display: grid; grid-template-columns: 280px 1fr; gap: 48px; align-items: center; margin: 20px 0 8px; }
.cim-ad-mag-cover { border-radius: 10px; overflow: hidden; box-shadow: 0 20px 46px rgba(0,0,0,0.24); }
.cim-ad-mag-cover img { display: block; width: 100%; height: auto; }
.cim-ad-mag-body p { font-size: 16px; line-height: 1.7; max-width: none; margin: 0 0 16px; }
.cim-ad-mag-body h4 { font-family: var(--f-mono); font-size: 12px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-muted); margin: 24px 0 14px; }

/* Logo strip — flex + centred so a short last row sits in the middle */
.cim-ad-logos { display: flex; flex-wrap: wrap; justify-content: center; gap: 20px; margin: 20px 0 8px; }
.cim-ad-logo { flex: 0 0 200px; height: 84px; display: flex; align-items: center; justify-content: center; padding: 0 18px; border: 1px solid var(--border); border-radius: 12px; background: var(--card); box-shadow: var(--shadow-card); }
.cim-ad-logo img { max-height: 46px; max-width: 100%; width: auto; object-fit: contain; filter: grayscale(1); opacity: 0.78; }
.cim-ad-logos-empty { color: var(--text-muted); font-size: 13px; }

/* FAQ (with FAQPage schema) */
.cim-ad-faq { max-width: 900px; margin: 12px 0 8px; }
.cim-ad-qa { border-bottom: 1px solid var(--border); padding: 22px 0; }
.cim-ad-qa .q { font-family: var(--f-head); font-size: 19px; font-weight: 700; margin-bottom: 8px; }
.cim-ad-qa .a { font-size: 15.5px; color: var(--text-sec); line-height: 1.7; }

/* Contact band */
.cim-ad-contact { background: #141414; border-radius: 18px; padding: 44px 48px; color: #fff; display: flex; align-items: center; justify-content: space-between; gap: 40px; flex-wrap: wrap; margin: 24px 0 8px; }
.cim-ad-contact-left h2 { font-family: var(--f-head); font-size: 32px; font-weight: 800; margin: 0 0 8px; display: block; }
.cim-ad-contact-left h2::before { content: none; }
.cim-ad-contact-left p { color: #9a9a9a; font-size: 15px; margin: 0; max-width: none; }
.cim-ad-contact-right { display: flex; flex-direction: column; gap: 12px; align-items: flex-start; }
.cim-ad-contact-right .row { display: flex; gap: 12px; flex-wrap: wrap; }
.cim-ad-contact-email { font-size: 13px; color: #9a9a9a; }
.cim-ad-contact-email a { color: var(--accent); }

@media (max-width: 900px) {
  .adv { padding: 32px 0 52px; }
  .cim-ad-reach { grid-template-columns: 1fr; }
  .cim-ad-reach .cell { border-right: 0; border-bottom: 1px solid #2a2a2a; padding: 18px 0; }
  .cim-ad-reach .cell:last-child { border-bottom: 0; }
  .cim-ad-cards, .cim-ad-standards, .cim-ad-stats { grid-template-columns: 1fr; }
  .cim-ad-cards > .cim-ad-card:last-child:nth-child(3n+1) { grid-column: auto; }
  .cim-ad-mag { grid-template-columns: 1fr; gap: 26px; padding: 28px; }
  .cim-ad-mag-cover { width: 200px; }
  .cim-ad-logo { flex-basis: 45%; }
  .cim-ad-contact { flex-direction: column; align-items: flex-start; padding: 32px 24px; }
}

/* ══════════════════════════════════════════════════════════════
   NEWS HOMEPAGE FOLDS (hp-)  — News theme homepage
══════════════════════════════════════════════════════════════ */
.hp-sec{padding:44px 0;border-bottom:1px solid var(--border)}
.hp-head{display:flex;align-items:center;gap:9px;margin-bottom:22px;flex-wrap:wrap}
.hp-head h2{font-family:var(--f-head);font-size:26px;font-weight:800;letter-spacing:-.01em}
.hp-head .hp-ar{color:#ab9330;font-size:22px;font-weight:700}
.hp-all{margin-left:auto;font-family:var(--f-mono);font-size:11.5px;font-weight:600;letter-spacing:.05em;text-transform:uppercase;color:var(--text-sec)}
.hp-all:hover{color:var(--text)}
.hp-note{font-family:var(--f-mono);font-size:10.5px;font-weight:600;letter-spacing:.03em;text-transform:uppercase;color:var(--text-muted);background:var(--surface);border:1px solid var(--border);border-radius:999px;padding:4px 12px}
.hp-cat{font-family:var(--f-mono);font-size:10.5px;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:#ab9330;display:inline-block}
.hp-time{font-family:var(--f-mono);font-size:11px;color:var(--text-muted);font-variant-numeric:tabular-nums}
.hp-byline{font-size:12.5px;color:var(--text-sec)} .hp-byline b{color:var(--text);font-weight:600}
.hp-ph{background:linear-gradient(135deg,#2b3340,#11161d)!important}
[class*="hp-"][style*="background-image"]{background-size:cover;background-position:center;background-repeat:no-repeat}

/* ticker */
.hp-ticker{background:#141414;color:#fff;overflow:hidden}
.hp-ticker .wrap{display:flex;align-items:center;height:46px}
.hp-live{display:flex;align-items:center;gap:7px;font-family:var(--f-mono);font-weight:700;font-size:12px;letter-spacing:.06em;text-transform:uppercase;padding-right:18px;margin-right:6px;border-right:1px solid rgba(255,255,255,.15);white-space:nowrap}
.hp-live::before{content:"";width:7px;height:7px;border-radius:50%;background:var(--accent);box-shadow:0 0 8px var(--accent)}
.hp-ti-track{display:flex;gap:24px;overflow:hidden}
.hp-ti{display:flex;align-items:center;gap:7px;white-space:nowrap;font-family:var(--f-mono);font-size:12.5px;font-variant-numeric:tabular-nums}
.hp-ti .s{color:rgba(255,255,255,.6);font-weight:600}
.hp-ti .p{color:#fff;font-weight:700}
.hp-ti .u{color:#4ade80;font-weight:600}
.hp-ti .d{color:#ff6b6b;font-weight:600}

/* top news */
.hp-lead{display:grid;grid-template-columns:260px 1fr 300px;gap:34px;align-items:start}
.hp-col-h{font-family:var(--f-mono);font-size:12px;font-weight:700;letter-spacing:.1em;text-transform:uppercase;padding-bottom:12px;border-bottom:2px solid var(--text);margin-bottom:4px}
.hp-sl{display:block;padding:14px 0;border-bottom:1px solid var(--border)}
.hp-sl .hp-cat{margin-bottom:5px}
.hp-sl h4{font-size:15px;font-weight:700;line-height:1.28;margin:0 0 6px}
.hp-sl:hover h4{color:#ab9330}
.hp-seemore{display:inline-block;margin-top:14px;font-family:var(--f-mono);font-size:11.5px;font-weight:700;letter-spacing:.05em;text-transform:uppercase;color:#ab9330}
.hp-feature .hp-fimg{aspect-ratio:16/9;border-radius:6px;margin-bottom:14px;background-color:#e4e2da}
.hp-feature .hp-cat-pill{background:var(--accent);color:var(--accent-text,#141414);padding:4px 9px;border-radius:5px;margin-bottom:10px}
.hp-feature h1{font-family:var(--f-head);font-size:33px;font-weight:800;line-height:1.12;margin:0 0 12px}
.hp-feature a:hover h1{color:#333}
.hp-stand{font-size:16px;color:var(--text-sec);line-height:1.55;margin:0 0 14px;max-width:620px}
.hp-meta{display:flex;align-items:center;gap:10px}
.hp-av{width:30px;height:30px;border-radius:50%}
.hp-side .hp-vid .hp-vimg{aspect-ratio:16/9;border-radius:6px;margin-bottom:10px;display:flex;align-items:center;justify-content:center;background-color:#222}
.hp-play{width:46px;height:46px;border-radius:50%;background:var(--accent);display:flex;align-items:center;justify-content:center}
.hp-vid h4{font-family:var(--f-head);font-size:15px;font-weight:700;line-height:1.3;margin:0}
.hp-mr{display:grid;grid-template-columns:26px 1fr;gap:12px;padding:12px 0;border-top:1px solid var(--border)}
.hp-mr .hp-n{font-family:var(--f-head);font-weight:800;font-size:20px;color:var(--text-muted)}
.hp-mr h4{font-family:var(--f-head);font-size:14px;font-weight:700;line-height:1.3;margin:0}
.hp-mr:hover h4{color:#ab9330}

/* expert grid-4 */
.hp-grid4{display:grid;grid-template-columns:repeat(4,1fr);gap:22px}
.hp-ncard .hp-nimg{aspect-ratio:16/10;border-radius:6px;margin-bottom:12px;background-color:#e4e2da}
.hp-ncard h3{font-family:var(--f-head);font-size:17px;font-weight:700;line-height:1.26;margin:8px 0}
.hp-ncard:hover h3{color:#ab9330}

/* opinion dense */
.hp-op-grid{display:grid;grid-template-columns:1fr 1fr;gap:40px}
.hp-op-block{display:grid;grid-template-columns:1fr 1fr;gap:22px}
.hp-op-feat .hp-op-img{aspect-ratio:16/10;border-radius:6px;margin-bottom:12px;background-color:#e4e2da}
.hp-op-feat h3{font-family:var(--f-head);font-size:20px;font-weight:700;line-height:1.22;margin:8px 0}
.hp-op-list .hp-oi{padding:0 0 16px;border-bottom:1px solid var(--border);margin-bottom:16px}
.hp-op-list .hp-oi:last-child{border-bottom:0;margin-bottom:0}
.hp-op-list h4{font-family:var(--f-head);font-size:16px;font-weight:700;line-height:1.28;margin:6px 0 7px}
.hp-op-list .hp-oi:hover h4,.hp-op-feat:hover h3{color:#ab9330}

/* category fold (switchable) */
.hp-cat-grid{display:grid;grid-template-columns:1.25fr 1fr;gap:34px;align-items:start}
.hp-cat-grid.feat-left{grid-template-columns:1fr 1.25fr}
.hp-cat-feature{position:relative;border-radius:8px;overflow:hidden;min-height:420px;display:flex;align-items:flex-end;color:#fff;background-color:#1a1a1a;order:2}
.hp-cat-grid .hp-cat-sec{order:1}
.hp-cat-grid.feat-left .hp-cat-feature{order:1}
.hp-cat-grid.feat-left .hp-cat-sec{order:2}
.hp-scrim{position:absolute;inset:0;background:linear-gradient(to top,rgba(0,0,0,.9) 8%,rgba(0,0,0,.25) 55%,rgba(0,0,0,.08))}
.hp-fc{position:relative;padding:26px 28px}
.hp-cat-feature .hp-cat{color:var(--accent)}
.hp-cat-feature h3{font-family:var(--f-head);color:#fff;font-size:26px;font-weight:800;line-height:1.14;margin:10px 0;max-width:94%}
.hp-fp{display:block;font-size:14.5px;color:rgba(255,255,255,.82);line-height:1.5;margin-bottom:14px;max-width:90%}
.hp-cat-feature .hp-byline b{color:#fff}
.hp-cat-sec{display:grid;grid-template-columns:1fr 1fr;gap:22px 24px}
.hp-cat-col .hp-cimg{aspect-ratio:16/10;border-radius:6px;margin-bottom:10px;background-color:#e4e2da}
.hp-cat-col .s1 h4,.hp-cat-col .s2 h4{font-family:var(--f-head);font-size:16px;font-weight:700;line-height:1.26;margin:0 0 7px}
.hp-cat-col .s2{padding-top:16px;margin-top:16px;border-top:1px solid var(--border)}
.hp-cat-col .s1:hover h4,.hp-cat-col .s2:hover h4{color:#ab9330}

/* heatmap */
.hp-heat{display:grid;grid-template-columns:repeat(12,1fr);grid-auto-rows:92px;gap:6px}
.hp-tile{border-radius:7px;padding:12px 14px;display:flex;flex-direction:column;justify-content:space-between;color:#fff;overflow:hidden}
.hp-tsym{font-family:var(--f-mono);font-weight:800;letter-spacing:.02em}
.hp-tmeta{display:flex;flex-direction:column}
.hp-tprice{font-family:var(--f-mono);font-size:13px;opacity:.82;font-variant-numeric:tabular-nums}
.hp-tchg{font-family:var(--f-mono);font-weight:700;font-variant-numeric:tabular-nums}
.hp-tile-xl{padding:16px 18px} .hp-tile-xl .hp-tsym{font-size:30px} .hp-tile-xl .hp-tchg{font-size:22px;margin-top:2px}
.hp-tile-lg .hp-tsym{font-size:24px} .hp-tile-lg .hp-tchg{font-size:18px;margin-top:2px}
.hp-tile-md{flex-direction:row;align-items:center;justify-content:space-between} .hp-tile-md .hp-tsym{font-size:17px} .hp-tile-md .hp-tmeta{flex-direction:row} .hp-tile-md .hp-tchg{font-size:14px}
.hp-tile-sm .hp-tsym{font-size:15px} .hp-tile-sm .hp-tchg{font-size:13px}

@media (max-width:980px){
  .hp-lead{grid-template-columns:1fr}
  .hp-op-grid{grid-template-columns:1fr}
  .hp-grid4{grid-template-columns:1fr 1fr}
  .hp-cat-grid,.hp-cat-grid.feat-left{grid-template-columns:1fr}
  .hp-cat-grid .hp-cat-feature,.hp-cat-grid.feat-left .hp-cat-feature{order:1}
  .hp-cat-grid .hp-cat-sec,.hp-cat-grid.feat-left .hp-cat-sec{order:2}
}
@media (max-width:560px){ .hp-grid4{grid-template-columns:1fr} .hp-op-block{grid-template-columns:1fr} .hp-cat-sec{grid-template-columns:1fr} }

/* heatmap — mobile: simple 2-col grid, ignore the desktop spans */
@media (max-width:640px){
  .hp-heat{grid-template-columns:repeat(2,1fr);grid-auto-rows:78px}
  .hp-heat>a{grid-column:span 1!important;grid-row:span 1!important}
  .hp-tile-xl .hp-tsym,.hp-tile-lg .hp-tsym{font-size:18px}
  .hp-tile-xl .hp-tchg,.hp-tile-lg .hp-tchg{font-size:14px}
}

/* category/opinion fold — align the secondary 2×2 (uniform image-story height, clamped titles) */
.hp-cat-col .s1 h4{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;min-height:2.6em}
.hp-cat-col .s2 h4{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.hp-cat-col .s2{padding-top:18px;margin-top:18px}
.hp-cat-col .s1 .hp-byline{display:block;margin-top:2px}

/* category/opinion fold — more breathing room for the text story under each image card */
.hp-cat-col{display:flex;flex-direction:column}
.hp-cat-col .s1{margin-bottom:0}
.hp-cat-col .s1 h4,.hp-cat-col .s2 h4{margin:0 0 9px;line-height:1.32}
.hp-cat-col .s1 .hp-byline,.hp-cat-col .s2 .hp-byline{display:block}
.hp-cat-col .s2{margin-top:24px;padding-top:24px;border-top:1px solid var(--border)}
.hp-cat-col .hp-cimg{margin-bottom:12px}
