/* ==========================================================================
   Addend Analytics — Editorial Blog Archive Layout
   Compact Hero Layout (1240px Container)
   - Left: Post 1 — ONE single card with compact 16:9 featured image + text
   - Right: Post 2 & Post 3 — Two compact stacked text-only cards
   - Hero size: Reduced to ~60% of original height (compact, sleek, balanced)
   - Titles: Strictly truncated to <= 2 lines
   - Excerpts: Strictly truncated to <= 2 lines
   - Fonts: Strictly 'Poppins' for Headings & 'IBM Plex Sans' for Body
   - Border radius: Strictly <= 10px everywhere
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Sans:wght@400;500;600;700&family=Poppins:wght@500;600;700;800&display=swap');

:root {
  --addend-navy: #0B1930;
  --addend-navy-dark: #070e1c;
  --addend-navy-mid: #162549;
  --addend-orange: #FF5E00;
  --addend-orange-hover: #e04e00;
  --addend-slate-dark: #0B1930;
  --addend-slate: #475569;
  --addend-slate-muted: #64748B;
  --addend-bg-card: #F4F6F9;
  --addend-bg-card-hover: #ECF0F5;
  --addend-border: #E2E8F0;
  --addend-border-card: rgba(11, 25, 48, 0.035);
  --addend-white: #ffffff;

  /* Typography: Strictly Poppins & IBM Plex Sans only */
  --font-heading: 'Poppins', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-body: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'IBM Plex Sans', monospace;

  /* Strict border-radius <= 10px everywhere */
  --radius-card: 10px;
  --radius-img: 10px;
  --radius-btn: 8px;
  --radius-pill: 8px;
}

/* ── MAIN WRAPPER ── */
.blog-archive-page {
  background-color: #ffffff;
  color: var(--addend-slate-dark);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  padding: 100px 0 60px; /* 100px top padding for sticky header */
}

/* Exact requested 1240px width */
.blog-container {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ── BREADCRUMBS (GUARANTEED VISIBILITY) ── */
.blog-breadcrumbs-section {
  padding-bottom: 12px;
}

.blog-breadcrumbs {
  display: flex !important;
  align-items: center;
  flex-wrap: wrap;
  gap: 7px;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  color: #64748b;
  visibility: visible !important;
  opacity: 1 !important;
}

.blog-breadcrumbs a {
  color: #64748b;
  text-decoration: none;
  transition: color 0.2s ease;
}

.blog-breadcrumbs a:hover {
  color: var(--addend-orange);
}

.blog-breadcrumbs .sep {
  font-size: 11px;
  color: #94a3b8;
}

.blog-breadcrumbs .current {
  color: var(--addend-navy);
  font-weight: 700;
}

/* ── HEADING ── */
.blog-heading-section {
  padding-bottom: 18px;
}

.blog-heading {
  font-family: var(--font-heading);
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: var(--addend-navy);
  margin: 0;
  line-height: 1.15;
}

/* ── COMPACT HERO SECTION (60% SIZE, 3 POSTS TOTAL) ── */
.blog-featured-section {
  margin-bottom: 32px;
}

.hero-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  align-items: stretch;
}

/* ── LEFT: POST 1 (ONE SINGLE COMPACT CARD WITH FEATURED IMAGE) ── */
.hero-card-left {
  background-color: var(--addend-bg-card);
  border: 1px solid var(--addend-border-card);
  border-radius: var(--radius-card); /* 10px */
  overflow: hidden;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
  transition: all 0.22s ease;
}

.hero-card-left:hover {
  background-color: var(--addend-bg-card-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(12, 26, 53, 0.05);
}

/* Featured Image (Native 16:9 Aspect Ratio - Full Uncropped Visibility) */
.hero-media-wrap {
  width: 100%;
  aspect-ratio: 16 / 9;
  height: auto;
  overflow: hidden;
  background-color: #ffffff;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-media-wrap img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  transition: transform 0.4s ease;
  display: block;
}

.hero-card-left:hover .hero-media-wrap img {
  transform: scale(1.025);
}

/* Content Area below Image */
.hero-card-body {
  padding: 14px 20px 16px;
  display: flex;
  flex-direction: column;
  flex: 1;
  justify-content: space-between;
}

/* ── RIGHT: POST 2 & POST 3 (2 COMPACT STACKED TEXT CARDS) ── */
.hero-right-col {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.hero-side-card {
  background-color: var(--addend-bg-card);
  border: 1px solid var(--addend-border-card);
  border-radius: var(--radius-card); /* 10px */
  padding: 14px 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  flex: 1;
  text-decoration: none;
  color: inherit;
  transition: all 0.22s ease;
}

.hero-side-card:hover {
  background-color: var(--addend-bg-card-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(12, 26, 53, 0.05);
}

/* Date Meta */
.card-meta-date {
  font-family: var(--font-heading);
  font-size: 11.5px;
  font-weight: 600;
  color: var(--addend-slate-muted);
  letter-spacing: 0.1px;
  margin-bottom: 5px;
  display: block;
}

/* Card Title (STRICTLY TRUNCATED TO NOT MORE THAN 2 LINES) */
.card-title-compact {
  font-family: var(--font-heading);
  font-size: 17px;
  font-weight: 800;
  line-height: 1.25;
  letter-spacing: -0.3px;
  color: var(--addend-navy);
  margin: 0 0 6px;
  transition: color 0.2s ease;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hero-card-left:hover .card-title-compact,
.hero-side-card:hover .card-title-compact {
  color: var(--addend-orange);
}

/* Card Excerpt (STRICTLY TRUNCATED TO NOT MORE THAN 2 LINES) */
.card-excerpt-compact {
  font-size: 12.5px;
  line-height: 1.45;
  color: var(--addend-slate);
  margin: 0 0 10px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Read More Link (Dark Navy, Inline Arrow) */
.read-more-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--addend-navy);
  margin-top: auto;
  transition: gap 0.2s ease, color 0.2s ease;
}

.read-more-link svg {
  width: 13px;
  height: 13px;
  transition: transform 0.2s ease;
}

.hero-card-left:hover .read-more-link,
.hero-side-card:hover .read-more-link,
.archive-card:hover .read-more-link {
  color: var(--addend-orange);
  gap: 8px;
}

.hero-card-left:hover .read-more-link svg,
.hero-side-card:hover .read-more-link svg,
.archive-card:hover .read-more-link svg {
  transform: translateX(3px);
}

/* ── DIVIDER LINE ── */
.blog-divider {
  border: 0;
  height: 1px;
  background: var(--addend-border);
  margin: 0 0 28px;
}

/* ── CATEGORY FILTER MENU (WP MENU: Blog Category Filter Menu) ── */
.blog-category-filter-nav {
  margin-bottom: 30px;
}

.blog-pills-list,
#menu-blog-category-filter-menu {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  padding: 0;
  margin: 0;
}

/* Pill Button (Border radius <= 10px) */
.blog-pills-list .menu-item a,
.blog-pills-list li a,
.blog-pills-list li button,
.blog-pill-btn {
  display: inline-block;
  padding: 6px 14px;
  font-family: var(--font-heading);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.35px;
  text-transform: uppercase;
  color: var(--addend-navy);
  background: #ffffff;
  border: 1px solid var(--addend-border);
  border-radius: var(--radius-pill); /* 8px <= 10px */
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s ease;
  line-height: 1.35;
}

.blog-pills-list .menu-item a:hover,
.blog-pills-list li a:hover,
.blog-pills-list li button:hover,
.blog-pill-btn:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
  color: var(--addend-orange);
}

.blog-pills-list .current-menu-item a,
.blog-pills-list li.active a,
.blog-pill-btn.active {
  background-color: var(--addend-orange) !important;
  border-color: var(--addend-orange) !important;
  color: #ffffff !important;
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(255, 94, 0, 0.25);
}

/* ── 3-COLUMN ARCHIVE ARTICLES GRID (POST 4 ONWARDS) ── */
.blog-archive-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px 20px;
  margin-bottom: 45px;
}

.archive-card {
  background: #ffffff;
  border: 1px solid #eef2f6;
  border-radius: var(--radius-card); /* 10px */
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.archive-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(12, 26, 53, 0.06);
  border-color: #e2e8f0;
}

/* 16:9 Image Container */
.archive-card-media {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background-color: #f1f5f9;
  overflow: hidden;
  border-top-left-radius: var(--radius-card);
  border-top-right-radius: var(--radius-card);
}

.archive-card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.archive-card:hover .archive-card-img {
  transform: scale(1.03);
}

/* Archive Card Content */
.archive-card-content {
  padding: 18px 20px 16px;
  display: flex;
  flex-direction: column;
  flex: 1;
  justify-content: space-between;
}

.archive-card-content a {
  text-decoration: none;
  color: inherit;
}

.archive-card-title {
  font-family: var(--font-heading);
  font-size: 16px;
  font-weight: 750;
  line-height: 1.35;
  letter-spacing: -0.2px;
  color: var(--addend-navy);
  margin: 0 0 8px;
  transition: color 0.2s ease;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

.archive-card:hover .archive-card-title {
  color: var(--addend-orange);
}

.archive-card-excerpt {
  font-size: 13px;
  line-height: 1.48;
  color: var(--addend-slate);
  margin: 0 0 12px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Text-only Author & Date Meta (No avatar image) */
.archive-card-meta-text {
  font-family: var(--font-heading);
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 500;
  color: #64748b;
  padding-top: 12px;
  border-top: 1px solid #f1f5f9;
  margin-top: 10px;
}

.archive-card-meta-text .author-name {
  font-weight: 600;
  color: var(--addend-navy);
}

.archive-card-meta-text .dot-sep {
  font-size: 10px;
  color: #94a3b8;
}

/* ── PAGINATION (STRICT <= 10px RADIUS) ── */
.blog-pagination-section {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px 0 12px;
}

.blog-pagination {
  display: flex;
  align-items: center;
  gap: 7px;
}

.blog-pagination a,
.blog-pagination span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 10px;
  border-radius: var(--radius-btn); /* 8px <= 10px */
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
  color: var(--addend-navy);
  border: 1px solid var(--addend-border);
  background: #ffffff;
}

.blog-pagination a:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
  color: var(--addend-orange);
}

.blog-pagination .current {
  background-color: var(--addend-navy);
  color: #ffffff;
  border-color: var(--addend-navy);
  font-weight: 700;
}

.blog-pagination .dots {
  border: none;
  background: transparent;
  color: #94a3b8;
  padding: 0 4px;
  min-width: auto;
}

/* ── RESPONSIVE BREAKPOINTS ── */
@media (max-width: 1024px) {
  .blog-archive-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ── DESKTOP & MOBILE CATEGORY FILTER PRESENTATION ── */
.blog-pills-desktop-wrap {
  display: block;
}

.blog-category-select-wrap {
  display: none;
}

@media (max-width: 768px) {
  /* Hide multi-row pills on mobile */
  .blog-pills-desktop-wrap {
    display: none !important;
  }

  /* Display sleek, full-width native select on mobile */
  .blog-category-select-wrap {
    display: block !important;
    width: 100%;
    margin: 0 0 24px;
  }

  .blog-cat-mobile-form {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 8px;
  }

  .select-field-box {
    position: relative;
    width: 100%;
  }

  .blog-category-select {
    width: 100%;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-color: #ffffff;
    border: 1.5px solid var(--addend-border);
    border-radius: var(--radius-btn); /* 8px <= 10px strict */
    padding: 12px 44px 12px 16px;
    font-family: var(--font-heading);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.3px;
    text-transform: uppercase;
    color: var(--addend-navy);
    cursor: pointer;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 2px 6px rgba(11, 25, 48, 0.04);
  }

  .blog-category-select:focus {
    border-color: var(--addend-orange);
    box-shadow: 0 0 0 3px rgba(255, 94, 0, 0.15);
  }

  .select-arrow-icon {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    color: var(--addend-navy);
    pointer-events: none;
  }

  .nojs-filter-submit {
    align-self: flex-start;
    padding: 9px 20px;
    background-color: var(--addend-orange);
    color: #ffffff;
    border: none;
    border-radius: var(--radius-btn);
    font-family: var(--font-heading);
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    cursor: pointer;
    transition: background 0.2s ease;
  }

  .nojs-filter-submit:hover {
    background-color: var(--addend-orange-hover);
  }

  .blog-heading {
    font-size: 26px;
  }
  .hero-layout {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .hero-media-wrap {
    aspect-ratio: 16 / 9;
    height: auto;
  }
  .blog-archive-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }
}
