/*
Theme Name:   CareerIntel Blog (Astra Child)
Theme URI:    https://careerintel.com.ng
Description:  Astra child theme that adds the CareerIntel blog page layout — trending posts, styled categories, paginated cards — without changing any existing pages.
Author:       CareerIntel Nigeria
Author URI:   https://careerintel.com.ng
Template:     astra
Version:      1.0.0
License:      GNU General Public License v2 or later
License URI:  https://www.gnu.org/licenses/gpl-2.0.html
Text Domain:  careerintel-child
*/

/* =====================================================
   IMPORT PARENT (ASTRA) STYLES FIRST
   Everything below this line is additive only —
   your existing Astra / Elementor pages are untouched.
===================================================== */

/* =====================================================
   CSS CUSTOM PROPERTIES
===================================================== */
:root {
  --ci-green:       #1a7a4a;
  --ci-green-dark:  #145e38;
  --ci-green-light: #e8f5ee;
  --ci-green-mid:   #2d9e63;
  --ci-accent:      #f0a500;
  --ci-text:        #1c1c1c;
  --ci-muted:       #6b7280;
  --ci-border:      #e5e7eb;
  --ci-bg:          #f9fafb;
  --ci-white:       #ffffff;
  --ci-card-shadow: 0 1px 6px rgba(0,0,0,.07);
  --ci-card-hover:  0 4px 20px rgba(0,0,0,.12);
  --radius-sm:      6px;
  --radius-md:      10px;
  --radius-lg:      14px;
  --font-head:      'Merriweather', Georgia, serif;
  --font-body:      'DM Sans', sans-serif;
}

/* =====================================================
   BLOG PAGE LAYOUT  (.ci-blog-wrap scopes everything)
   None of these rules affect Elementor pages.
===================================================== */

/* Page wrapper */
.ci-blog-wrap {
  background: var(--ci-bg);
  padding: 36px 0 60px;
}

.ci-blog-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Two-column grid */
.ci-blog-grid {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 32px;
  align-items: start;
}

/* ---- Archive heading ---- */
.ci-archive-header {
  margin-bottom: 28px;
}
.ci-archive-header h1 {
  font-family: var(--font-head);
  font-size: 1.6rem;
  color: var(--ci-green);
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 6px;
}
.ci-archive-header h1::after {
  content: '';
  flex: 1;
  height: 2px;
  background: linear-gradient(to right, var(--ci-green), transparent);
  border-radius: 2px;
}
.ci-archive-header p { color: var(--ci-muted); font-size: .9rem; margin: 0; }

/* ---- POST CARD ---- */
.ci-post-card {
  background: var(--ci-white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--ci-border);
  overflow: hidden;
  display: flex;
  margin-bottom: 20px;
  box-shadow: var(--ci-card-shadow);
  transition: box-shadow .22s, margin-top .22s, margin-bottom .22s;
  text-decoration: none;
  color: inherit;
  position: relative;
  z-index: 1;
}
.ci-post-card:hover {
  box-shadow: var(--ci-card-hover);
  /* margin shift instead of transform — transform creates a new
     stacking context that overlaps Astra's sticky header */
  margin-top: -2px;
  margin-bottom: 22px;
}

.ci-post-card-thumb {
  flex-shrink: 0;
  width: 220px;
  overflow: hidden;
  position: relative;
  background: var(--ci-border);
}
.ci-post-card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .35s ease;
}
.ci-post-card:hover .ci-post-card-thumb img { transform: scale(1.04); }

.ci-cat-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  background: var(--ci-green);
  color: #fff;
  font-size: .68rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: .05em;
}

.ci-post-card-body {
  padding: 22px 24px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 10px;
  flex: 1;
  min-width: 0;
}

.ci-post-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: .8rem;
  color: var(--ci-muted);
  flex-wrap: wrap;
}
.ci-post-meta span { display: flex; align-items: center; gap: 5px; }
.ci-post-meta svg { width: 14px; height: 14px; flex-shrink: 0; }

.ci-post-title {
  font-family: var(--font-head);
  font-size: 1.08rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--ci-text);
  margin: 0;
  transition: color .18s;
}
.ci-post-card:hover .ci-post-title { color: var(--ci-green); }

.ci-post-excerpt {
  font-size: .875rem;
  color: var(--ci-muted);
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 0;
}

.ci-read-more {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--ci-green);
  font-weight: 600;
  font-size: .875rem;
  text-decoration: none;
  transition: gap .2s;
}
.ci-read-more:hover { gap: 9px; }
.ci-read-more svg { width: 14px; height: 14px; transition: transform .2s; }
.ci-read-more:hover svg { transform: translateX(3px); }

/* ---- NO POSTS ---- */
.ci-no-posts {
  background: var(--ci-white);
  border: 1px solid var(--ci-border);
  border-radius: var(--radius-lg);
  padding: 48px 32px;
  text-align: center;
}
.ci-no-posts h3 { font-size: 1.1rem; margin-bottom: 8px; }
.ci-no-posts p  { color: var(--ci-muted); font-size: .9rem; }

/* ---- PAGINATION ---- */
.ci-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid var(--ci-border);
  flex-wrap: wrap;
}
.ci-pagination a,
.ci-pagination span {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 10px;
  border-radius: var(--radius-sm);
  font-size: .88rem;
  font-weight: 500;
  border: 1px solid var(--ci-border);
  background: var(--ci-white);
  color: var(--ci-text);
  text-decoration: none;
  transition: background .18s, color .18s, border-color .18s;
}
.ci-pagination a:hover {
  background: var(--ci-green-light);
  color: var(--ci-green);
  border-color: var(--ci-green);
}
.ci-pagination .ci-page-current {
  background: var(--ci-green);
  color: #fff;
  border-color: var(--ci-green);
  font-weight: 700;
}
.ci-pagination .ci-page-dots {
  border: none;
  background: none;
  color: var(--ci-muted);
  pointer-events: none;
}
.ci-pagination .ci-prev-next {
  font-size: .82rem;
  color: var(--ci-muted);
  gap: 4px;
}
.ci-pagination .ci-prev-next:hover { color: var(--ci-green); }

/* ---- SIDEBAR ---- */
.ci-sidebar {
  display: flex;
  flex-direction: column;
  gap: 24px;
  position: sticky;
  top: 100px;
}

.ci-widget {
  background: var(--ci-white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--ci-border);
  overflow: hidden;
  box-shadow: var(--ci-card-shadow);
}

.ci-widget-header {
  padding: 14px 20px;
  border-bottom: 1px solid var(--ci-border);
  display: flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-head);
  font-size: .95rem;
  font-weight: 700;
  color: var(--ci-text);
}
.ci-widget-header svg { width: 17px; height: 17px; color: var(--ci-green); flex-shrink: 0; }

/* Trending */
.ci-trending-list { padding: 6px 0; }
.ci-trending-item {
  display: flex;
  align-items: flex-start;
  gap: 13px;
  padding: 11px 20px;
  border-bottom: 1px solid var(--ci-border);
  transition: background .18s;
  text-decoration: none;
  color: inherit;
}
.ci-trending-item:last-child { border-bottom: none; }
.ci-trending-item:hover { background: var(--ci-green-light); }

.ci-trending-num {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  background: var(--ci-green-light);
  color: var(--ci-green);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .72rem;
  font-weight: 700;
  margin-top: 2px;
}
.ci-trending-item:first-child .ci-trending-num { background: var(--ci-green); color: #fff; }

.ci-trending-title {
  font-size: .845rem;
  font-weight: 600;
  line-height: 1.35;
  color: var(--ci-text);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color .18s;
}
.ci-trending-item:hover .ci-trending-title { color: var(--ci-green); }
.ci-trending-views { font-size: .72rem; color: var(--ci-muted); margin-top: 3px; }

/* Categories */
.ci-cat-list { padding: 6px 0; }
.ci-cat-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 20px;
  border-bottom: 1px solid var(--ci-border);
  transition: background .18s;
  text-decoration: none;
  color: var(--ci-text);
  font-size: .875rem;
  font-weight: 500;
}
.ci-cat-item:last-child { border-bottom: none; }
.ci-cat-item:hover { background: var(--ci-green-light); color: var(--ci-green); }

.ci-cat-count {
  background: var(--ci-bg);
  color: var(--ci-muted);
  font-size: .72rem;
  font-weight: 700;
  padding: 2px 9px;
  border-radius: 20px;
  border: 1px solid var(--ci-border);
  min-width: 34px;
  text-align: center;
  flex-shrink: 0;
}

/* Recent posts */
.ci-recent-list { padding: 6px 0; }
.ci-recent-item {
  display: flex;
  gap: 12px;
  padding: 11px 20px;
  border-bottom: 1px solid var(--ci-border);
  align-items: flex-start;
  transition: background .18s;
  text-decoration: none;
  color: inherit;
}
.ci-recent-item:last-child { border-bottom: none; }
.ci-recent-item:hover { background: var(--ci-green-light); }

.ci-recent-thumb {
  flex-shrink: 0;
  width: 58px;
  height: 48px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--ci-bg);
}
.ci-recent-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }

.ci-recent-title {
  font-size: .82rem;
  font-weight: 600;
  line-height: 1.35;
  color: var(--ci-text);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color .18s;
}
.ci-recent-item:hover .ci-recent-title { color: var(--ci-green); }
.ci-recent-date { font-size: .72rem; color: var(--ci-muted); margin-top: 4px; }

/* ---- RESPONSIVE ---- */
@media (max-width: 960px) {
  .ci-blog-grid { grid-template-columns: 1fr; }
  .ci-sidebar { position: static; }
}
@media (max-width: 640px) {
  .ci-post-card { flex-direction: column; }
  .ci-post-card-thumb { width: 100%; height: 200px; }
  .ci-post-card-body { padding: 16px; }
  .ci-blog-container { padding: 0 14px; }
}

/* =====================================================
   SINGLE POST PAGE
   All scoped under .ci-single-wrap / .ci-single-*
===================================================== */

/* Container shorthand for single/category pages */
.ci-sc {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Breadcrumb */
.ci-single-breadcrumb {
  background: var(--ci-white);
  border-bottom: 1px solid var(--ci-border);
  padding: 11px 0;
  font-size: .82rem;
  color: var(--ci-muted);
}
.ci-single-breadcrumb a { color: var(--ci-green); }
.ci-single-breadcrumb a:hover { text-decoration: underline; }
.ci-single-breadcrumb svg { vertical-align: middle; margin: 0 4px; color: var(--ci-border); }
.ci-single-breadcrumb span { color: var(--ci-muted); }

/* Wrap */
.ci-single-wrap {
  background: var(--ci-bg);
  padding: 36px 0 60px;
}

/* Two-col grid */
.ci-single-grid {
  display: grid;
  grid-template-columns: 1fr 308px;
  gap: 32px;
  align-items: start;
}

/* Hero image */
.ci-single-hero {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 28px;
  background: var(--ci-border);
  max-height: 460px;
}
.ci-single-hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  max-height: 460px;
}
.ci-single-cat-badge {
  position: absolute;
  top: 16px;
  left: 16px;
  background: var(--ci-green);
  color: #fff;
  font-size: .72rem;
  font-weight: 700;
  padding: 4px 13px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: .05em;
  text-decoration: none;
  z-index: 2;
  transition: background .18s;
}
.ci-single-cat-badge:hover { background: var(--ci-green-dark); }

/* Title */
.ci-single-title {
  font-family: var(--font-head);
  font-size: clamp(1.45rem, 3vw, 2rem);
  font-weight: 900;
  line-height: 1.28;
  color: var(--ci-text);
  margin: 0 0 18px;
}

/* Meta bar */
.ci-single-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: .83rem;
  color: var(--ci-muted);
  flex-wrap: wrap;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--ci-border);
  margin-bottom: 20px;
}
.ci-single-meta-item {
  display: flex;
  align-items: center;
  gap: 5px;
}
.ci-single-meta-sep { color: var(--ci-border); font-size: 1rem; }

/* Share bar */
.ci-share-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 28px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--ci-border);
  flex-wrap: wrap;
}
.ci-share-label {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: .85rem;
  font-weight: 600;
  color: var(--ci-text);
}
.ci-share-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: #fff;
  text-decoration: none;
  transition: opacity .2s;
  flex-shrink: 0;
}
.ci-share-btn:hover { opacity: .8; }
.ci-share-fb { background: #1877f2; }
.ci-share-tw { background: #1da1f2; }
.ci-share-li { background: #0a66c2; }
.ci-share-wa { background: #25d366; }

/* Post content */
.ci-single-content {
  font-size: .95rem;
  line-height: 1.8;
  color: var(--ci-text);
  margin-bottom: 32px;
}
.ci-single-content h2 { font-family: var(--font-head); font-size: 1.3rem; margin: 32px 0 12px; }
.ci-single-content h3 { font-family: var(--font-head); font-size: 1.1rem; margin: 24px 0 10px; }
.ci-single-content p  { margin-bottom: 18px; }
.ci-single-content ul, .ci-single-content ol { padding-left: 24px; margin-bottom: 18px; }
.ci-single-content li { margin-bottom: 7px; }
.ci-single-content a  { color: var(--ci-green); text-decoration: underline; }
.ci-single-content blockquote {
  border-left: 3px solid var(--ci-green);
  padding: 14px 20px;
  background: var(--ci-green-light);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin: 24px 0;
  font-style: italic;
  color: var(--ci-green-dark);
}
.ci-single-content table { width: 100%; border-collapse: collapse; margin: 20px 0; font-size: .9rem; }
.ci-single-content th { background: var(--ci-green); color: #fff; padding: 10px 14px; text-align: left; }
.ci-single-content td { padding: 9px 14px; border-bottom: 1px solid var(--ci-border); }
.ci-single-content tr:hover td { background: var(--ci-green-light); }
.ci-single-content img { border-radius: var(--radius-md); max-width: 100%; margin: 20px 0; }

/* Tags */
.ci-single-tags {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 28px;
}
.ci-tags-label { font-size: .82rem; font-weight: 600; color: var(--ci-muted); }
.ci-tag-pill {
  background: var(--ci-bg);
  color: var(--ci-text);
  border: 1px solid var(--ci-border);
  border-radius: 20px;
  padding: 3px 12px;
  font-size: .78rem;
  font-weight: 500;
  text-decoration: none;
  transition: background .18s, color .18s, border-color .18s;
}
.ci-tag-pill:hover { background: var(--ci-green-light); color: var(--ci-green); border-color: var(--ci-green); }

/* Prev/next post nav */
.ci-post-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 36px;
}
.ci-post-nav-item {
  background: var(--ci-white);
  border: 1px solid var(--ci-border);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  text-decoration: none;
  transition: border-color .18s, box-shadow .18s;
}
.ci-post-nav-item:hover { border-color: var(--ci-green); box-shadow: 0 2px 10px rgba(26,122,74,.1); }
.ci-post-nav-next { text-align: right; }
.ci-post-nav-dir {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: .75rem;
  color: var(--ci-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .04em;
  margin-bottom: 5px;
}
.ci-post-nav-next .ci-post-nav-dir { justify-content: flex-end; }
.ci-post-nav-title {
  font-size: .85rem;
  font-weight: 700;
  color: var(--ci-text);
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color .18s;
}
.ci-post-nav-item:hover .ci-post-nav-title { color: var(--ci-green); }

/* =====================================================
   RELATED POSTS
===================================================== */
.ci-related-posts {
  background: var(--ci-white);
  border: 1px solid var(--ci-border);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--ci-card-shadow);
}
.ci-related-header { margin-bottom: 20px; }
.ci-related-title {
  font-family: var(--font-head);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--ci-text);
  margin: 0;
}
.ci-related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.ci-related-card {
  border: 1px solid var(--ci-border);
  border-radius: var(--radius-md);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: box-shadow .22s;
  display: flex;
  flex-direction: column;
}
.ci-related-card:hover {
  box-shadow: var(--ci-card-hover);
}
.ci-related-thumb {
  height: 130px;
  overflow: hidden;
  background: var(--ci-bg);
  flex-shrink: 0;
}
.ci-related-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .35s ease;
}
.ci-related-card:hover .ci-related-thumb img { transform: scale(1.06); }
.ci-related-body {
  padding: 14px;
  flex: 1;
}
.ci-related-cat {
  display: block;
  font-size: .68rem;
  font-weight: 700;
  color: var(--ci-green);
  text-transform: uppercase;
  letter-spacing: .05em;
  margin-bottom: 6px;
}
.ci-related-post-title {
  font-family: var(--font-head);
  font-size: .855rem;
  font-weight: 700;
  line-height: 1.38;
  color: var(--ci-text);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color .18s;
}
.ci-related-card:hover .ci-related-post-title { color: var(--ci-green); }

/* Single page sidebar search widget */
.ci-search-widget-body {
  padding: 14px 16px;
}
.ci-search-widget-input {
  width: 100%;
  border: 1.5px solid var(--ci-border);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  font-size: .88rem;
  font-family: var(--font-body);
  color: var(--ci-text);
  background: var(--ci-bg);
  outline: none;
  transition: border-color .18s, box-shadow .18s;
}
.ci-search-widget-input:focus {
  border-color: var(--ci-green);
  box-shadow: 0 0 0 3px rgba(26,122,74,.1);
  background: var(--ci-white);
}

/* Sticky sidebar for single */
.ci-single-sidebar { position: sticky; top: 90px; }

/* =====================================================
   ASTRA LAYOUT RESET
   Force our category + single templates to occupy the
   full viewport width, breaking out of Astra's content
   column / sidebar grid entirely.
===================================================== */

/* Astra wraps content in .site-content > .ast-container > #primary
   We reset all of those when our templates are active so nothing
   from Astra's layout bleeds in. */
.ci-cat-page .site-content,
.ci-cat-page #primary,
.ci-cat-page .ast-container,
.ci-cat-page .content-area,
.ci-cat-page #content,
.ci-single-page .site-content,
.ci-single-page #primary,
.ci-single-page .ast-container,
.ci-single-page .content-area,
.ci-single-page #content {
  max-width: 100% !important;
  width: 100% !important;
  padding: 0 !important;
  margin: 0 !important;
  float: none !important;
  display: block !important;
}

/* Remove any Astra sidebar that might appear */
.ci-cat-page #secondary,
.ci-single-page #secondary {
  display: none !important;
}

/* Kill Astra's inner article padding on these pages */
.ci-cat-page .ast-article-single,
.ci-cat-page .entry-content,
.ci-cat-page .post-content,
.ci-single-page .ast-article-single,
.ci-single-page .entry-content,
.ci-single-page .post-content {
  padding: 0 !important;
  margin: 0 !important;
  max-width: 100% !important;
}

/* =====================================================
   SHARED FULL-WIDTH CONTAINER
   Used inside both .ci-cat-hero, .ci-all-cats-strip,
   .ci-blog-wrap, .ci-single-wrap
===================================================== */
.ci-sc {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  width: 100%;
  box-sizing: border-box;
}

/* =====================================================
   CATEGORY PAGE – HERO BANNER
===================================================== */
.ci-cat-hero {
  background: var(--cat-light, #e8f5ee);
  border-bottom: 1px solid var(--ci-border);
  padding: 48px 0 40px;
  position: relative;
  overflow: hidden;
  width: 100%;
  box-sizing: border-box;
}
.ci-cat-hero-inner {
  display: flex;
  align-items: center;
  gap: 28px;
  position: relative;
  z-index: 2;
}
.ci-cat-hero-icon {
  flex-shrink: 0;
  width: 80px;
  height: 80px;
  background: var(--cat-accent, #1a7a4a);
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  box-shadow: 0 8px 24px rgba(0,0,0,.15);
}
.ci-cat-hero-eyebrow {
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--cat-accent, #1a7a4a);
  margin-bottom: 6px;
}
.ci-cat-hero-title {
  font-family: var(--font-head);
  font-size: clamp(1.6rem, 4vw, 2.2rem);
  font-weight: 900;
  color: var(--ci-text);
  margin: 0 0 8px;
}
.ci-cat-hero-desc {
  font-size: .9rem;
  color: var(--ci-muted);
  max-width: 520px;
  margin: 0 0 14px;
  line-height: 1.55;
}
.ci-cat-hero-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.ci-cat-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: var(--cat-accent, #1a7a4a);
  color: #fff;
  font-size: .78rem;
  font-weight: 700;
  padding: 5px 13px;
  border-radius: 20px;
}
.ci-cat-hero-page {
  font-size: .78rem;
  color: var(--ci-muted);
  background: var(--ci-white);
  padding: 4px 12px;
  border-radius: 20px;
  border: 1px solid var(--ci-border);
}

/* Decorative circles */
.ci-cat-hero-deco {
  position: absolute;
  border-radius: 50%;
  background: var(--cat-accent, #1a7a4a);
  opacity: .07;
  pointer-events: none;
  z-index: 1;
}
.ci-deco-1 { width: 320px; height: 320px; right: -80px; top: -120px; }
.ci-deco-2 { width: 200px; height: 200px; right: 120px; bottom: -80px; }

/* =====================================================
   CATEGORY PILLS STRIP
===================================================== */
.ci-all-cats-strip {
  background: var(--ci-white);
  border-bottom: 1px solid var(--ci-border);
  padding: 14px 0;
  width: 100%;
  box-sizing: border-box;
}
.ci-all-cats-strip .ci-sc {
  display: flex;
  gap: 8px;
  flex-wrap: nowrap;
  overflow-x: auto;
  scrollbar-width: none;
  padding-bottom: 2px;
}
.ci-all-cats-strip .ci-sc::-webkit-scrollbar { display: none; }

.ci-cats-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 20px;
  border: 1.5px solid var(--ci-border);
  font-size: .82rem;
  font-weight: 600;
  color: var(--ci-text);
  white-space: nowrap;
  text-decoration: none;
  background: var(--ci-white);
  transition: border-color .18s, color .18s, background .18s;
  flex-shrink: 0;
}
.ci-cats-pill:hover,
.ci-cats-pill.active {
  border-color: var(--ci-green);
  color: var(--ci-green);
  background: var(--ci-green-light);
}
.ci-cats-pill span {
  background: var(--ci-bg);
  color: var(--ci-muted);
  font-size: .7rem;
  padding: 1px 7px;
  border-radius: 20px;
  border: 1px solid var(--ci-border);
}
.ci-cats-pill.active span { background: var(--ci-green); color: #fff; border-color: var(--ci-green); }

/* Also ensure .ci-blog-wrap inside category page is full-width */
.ci-cat-page .ci-blog-wrap,
.ci-cat-page .ci-single-wrap {
  width: 100%;
  box-sizing: border-box;
}

/* =====================================================
   RESPONSIVE – SINGLE & CATEGORY
===================================================== */
@media (max-width: 960px) {
  .ci-single-grid    { grid-template-columns: 1fr; }
  .ci-single-sidebar { position: static; }
  .ci-related-grid   { grid-template-columns: 1fr 1fr; }
  .ci-cat-hero-inner { flex-direction: column; text-align: center; }
  .ci-cat-hero-meta  { justify-content: center; }
}
@media (max-width: 640px) {
  .ci-related-grid { grid-template-columns: 1fr; }
  .ci-post-nav     { grid-template-columns: 1fr; }
  .ci-single-title { font-size: 1.4rem; }
  .ci-cat-hero     { padding: 32px 0 28px; }
  .ci-cat-hero-icon { width: 64px; height: 64px; border-radius: 16px; }
  .ci-sc { padding: 0 14px; }
}

/* =====================================================
   ASTRA STICKY HEADER — Z-INDEX FIX
   Ensures Astra's header always sits above blog post
   cards when scrolling. The card hover transform was
   creating a new stacking context that beat the header.
===================================================== */

/* Astra's sticky header — all known selectors */
#masthead,
.site-header,
.main-header-bar,
.main-header-bar-wrap,
.ast-primary-header-bar,
.ast-hfb-header,
.ast-desktop-header,
.ast-mobile-header,
.ast-above-header,
.ast-below-header,
.ast-sticky-active,
.ast-header-break-point {
  z-index: 99999 !important;
}

/* Ground blog content so it can never exceed the header */
.cib-wrap,
.cib-single-wrap,
.cib-breadcrumb,
.cib-cat-hero,
.cib-pills-strip {
  position: relative;
  z-index: 1;
}

/* Card hover transform must stay below the header */
.cib-card:hover {
  z-index: 2;
  position: relative;
}

/* =====================================================
   BLOG PAGE — ELEMENTOR STACKING CONTEXT FIX
   On /blog, Elementor wraps the [careerintel_blog]
   shortcode in .elementor-section / .e-con containers
   that create a stacking context overriding the header.
   We force them below the header z-index on that page.
===================================================== */

/* Astra's sticky header — absolute top of stack */
#masthead,
.site-header,
.main-header-bar,
.main-header-bar-wrap,
.ast-primary-header-bar,
.ast-hfb-header,
.ast-sticky-active,
.ast-main-header-sticky,
.ast-header-break-point {
  z-index: 99999 !important;
  position: sticky !important;
  top: 0 !important;
}

/* Elementor page sections — must never exceed header */
.elementor-section,
.elementor-container,
.elementor-widget-wrap,
.elementor-widget,
.e-con,
.e-con-inner,
.elementor-top-section {
  z-index: auto !important;
}

/* The shortcode output wrappers */
.cib-wrap,
.cib-single-wrap,
.cib-cat-hero,
.cib-pills-strip,
.cib-breadcrumb {
  position: relative;
  z-index: 1;
  isolation: isolate;
}

/* Cards on hover must stay grounded */
.cib-card {
  position: relative;
  z-index: 1;
}
.cib-card:hover {
  z-index: 2;
}

/* =====================================================
   REAL FIX — based on console diagnosis
   Header is: .elementor.elementor-location-header
   Header z-index: 960, position: sticky
   Cards sit inside body.hfeed.site directly.
   Solution: boost Elementor header above page content.
===================================================== */
.elementor-location-header {
  z-index: 99999 !important;
  position: sticky !important;
  top: 0 !important;
}

/* =====================================================
   DEFINITIVE FIX — confirmed via browser console
   
   Header: .elementor.elementor-location-header
   Header z-index: 960, position: sticky
   
   The blog shortcode outputs .ci-blog-wrap directly
   inside body.hfeed with no stacking context —
   Elementor's canvas lets it paint above the header.
   
   Fix: explicitly set z-index on the blog wrapper
   BELOW the header's 960, and force the Elementor
   header to always be on top.
===================================================== */

/* Keep blog content strictly below the header */
.ci-blog-wrap,
.ci-blog-container,
.ci-blog-grid,
.ci-main-col,
.ci-sidebar {
  position: relative;
  z-index: 1;
}

/* Force every post card below header */
.ci-post-card {
  position: relative;
  z-index: 1;
  isolation: isolate;
}

/* Elementor header — always on top, no exceptions */
.elementor-location-header,
.elementor-location-header.elementor {
  z-index: 99999 !important;
  position: sticky !important;
  top: 0 !important;
}

/* Elementor mobile nav panel — also must be on top */
.elementor-nav-menu--dropdown,
.elementor-menu-toggle,
div[data-elementor-type="header"] {
  z-index: 99999 !important;
}
