/* =============================================================
   ARCHIVE — page-hero band, stats bar, filter bar,
              archive grids, KB archive
   ============================================================= */

/* ── Page hero band ─────────────────────────────────────────── */
.page-hero {
  background:
    radial-gradient(ellipse 55% 60% at 88% 50%, rgba(45,158,68,.12) 0%, transparent 60%),
    linear-gradient(140deg, #1e3a7b 0%, #0f204e 55%, #081428 100%);
  padding: 80px 0 64px; position: relative; overflow: hidden;
}
.page-hero::before {
  content: ''; position: absolute; inset: 0;
  background-image:
    radial-gradient(rgba(255,255,255,.09) 1px, transparent 1px),
    linear-gradient(rgba(255,255,255,.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.025) 1px, transparent 1px);
  background-size: 40px 40px;
  -webkit-mask-image: radial-gradient(ellipse 80% 85% at 50% 50%, black 15%, transparent 100%);
  mask-image:         radial-gradient(ellipse 80% 85% at 50% 50%, black 15%, transparent 100%);
  pointer-events: none; z-index: 0;
}
.page-hero .container,
.page-hero-inner  { position: relative; z-index: 1; }
.page-hero h1     { font-size: 2.2rem; font-weight: 900; color: #fff; margin-bottom: 10px; line-height: 1.2; }
.page-hero p      { color: rgba(255,255,255,.8); font-size: 1rem; max-width: 600px; }
.page-hero-search { margin-top: 20px; display: flex; max-width: 560px; }
.page-hero-search input  { flex: 1; padding: 12px 18px; border: none; border-radius: 8px 0 0 8px; font-size: .95rem; outline: none; }
.page-hero-search button { padding: 12px 20px; background: var(--green); color: #fff; border: none; border-radius: 0 8px 8px 0; font-size: .95rem; cursor: pointer; }

/* Hero section links */
.page-hero a         { color: rgba(255,255,255,.85); }
.page-hero a:not(.btn):hover { color: #fff; }

/* ── Archive stats bar ──────────────────────────────────────── */
.archive-stats-bar { background: var(--blue); padding: 20px 0; }
.archive-stats     { display: flex; justify-content: center; flex-wrap: wrap; gap: 0; }
.archive-stat      { text-align: center; padding: 10px 36px; border-right: 1px solid rgba(255,255,255,.15); color: #fff; }
.archive-stat:last-child { border: none; }
.archive-stat strong { display: block; font-size: 1.6rem; font-weight: 900; }
.archive-stat span   { font-size: .78rem; color: rgba(255,255,255,.65); }

/* ── Filter bar ─────────────────────────────────────────────── */
.filter-bar   { background: #fff; border-bottom: 1px solid var(--border); padding: 14px 0; position: sticky; top: var(--header-h); z-index: 100; }
.admin-bar .filter-bar { top: calc(32px + var(--header-h)); }
@media (max-width: 782px) { .admin-bar .filter-bar { top: calc(46px + var(--header-h)); } }
.filter-form  { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.filter-group { display: flex; align-items: center; gap: 8px; }
.filter-group label  { font-size: .82rem; font-weight: 700; color: var(--text-3); white-space: nowrap; }
.filter-group select { padding: 7px 12px; border: 1px solid var(--border); border-radius: 6px; font-size: .85rem; background: #fff; }
.filter-reset { color: var(--text-3); font-size: .82rem; text-decoration: underline; }
.filter-count { margin-left: auto; font-size: .85rem; color: var(--text-3); }
.filter-count strong { color: var(--blue); }

/* ── Archive grids ──────────────────────────────────────────── */
.services-archive-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 24px; }

/* ── KB archive ─────────────────────────────────────────────── */
.kb-archive-grid    { display: grid; grid-template-columns: 240px 1fr; gap: 36px; align-items: start; }
.kb-archive-sidebar { position: sticky; top: calc(var(--header-h) + 24px); }

/* ── Features grid — shared across archive-service + homepage ─ */
.features-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.feat-card {
  background: #fff; border-radius: var(--radius); padding: 28px 22px; text-align: center;
  border: 1px solid var(--border); box-shadow: var(--shadow);
  transition: transform var(--transition), box-shadow var(--transition);
}
.feat-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.feat-icon { width: 64px; height: 64px; border-radius: 14px; background: var(--blue); color: #fff; display: flex; align-items: center; justify-content: center; margin: 0 auto 16px; }
.feat-icon svg { width: 30px; height: 30px; }
.feat-title { font-size: 1rem; font-weight: 800; color: var(--blue); margin-bottom: 8px; }
.feat-desc  { font-size: .85rem; color: var(--text-2); line-height: 1.6; }
@media (max-width: 1024px) { .features-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 768px)  { .features-grid { grid-template-columns: 1fr; } }

/* ── CTA section — shared across archive + single pages ────── */
.cta-section    { background: #1E3A7B; padding: 56px 0; text-align: center; }
.cta-section h2 { font-size: 2rem; font-weight: 900; color: #fff !important; margin-bottom: 10px; }
.cta-section p  { color: rgba(255,255,255,.8) !important; margin-bottom: 28px; font-size: 1rem; }
.cta-btns       { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.cta-inline {
  background: var(--off-white); border-radius: var(--radius);
  padding: 28px; display: flex; align-items: center;
  justify-content: space-between; gap: 24px; flex-wrap: wrap; margin: 48px 0;
}
.cta-inline-text h3 { font-size: 1.1rem; font-weight: 800; color: var(--blue); margin-bottom: 4px; }
.cta-inline-text p  { font-size: .875rem; color: var(--text-2); }
.cta-inline-actions { display: flex; gap: 10px; flex-wrap: wrap; }
@media (max-width: 768px) { .cta-inline { flex-direction: column; } }

/* ── Blog archive wrapper ───────────────────────────────────── */
.blog-archive-wrapper { padding: 48px 0 64px; }
.blog-archive-grid    { display: grid; grid-template-columns: 1fr 300px; gap: 40px; align-items: start; }
.blog-archive-posts   { min-width: 0; } /* prevent grid blowout */

/* Responsive */
@media (max-width: 900px) {
  .blog-archive-grid      { grid-template-columns: 1fr; }
  .blog-archive-grid aside { display: none; }
}
@media (max-width: 768px) {
  .archive-stats      { flex-direction: column; gap: 8px; }
  .archive-stat       { border: none; }
  .kb-archive-grid    { display: block !important; width: 100% !important; }
  .kb-archive-sidebar { display: block !important; position: static !important; width: 100% !important; margin-top: 32px; }
  .kb-cards-list      { grid-template-columns: 1fr !important; gap: 16px; width: 100%; }
}
