/* ═══════════════════════════════════════════════════════════════
   OH Predictive Insights — Main Stylesheet
   Modern responsive design, mobile-first
   ═══════════════════════════════════════════════════════════════ */

/* ── Custom Properties ───────────────────────────────────────── */
:root {
  --brand-primary:   #0055a5;
  --brand-dark:      #003d7a;
  --brand-light:     #e8f1fb;
  --brand-accent:    #e8830a;
  --text-base:       #1a1a2e;
  --text-muted:      #5a6478;
  --text-light:      #8a94a6;
  --bg-page:         #f7f8fc;
  --bg-card:         #ffffff;
  --bg-dark:         #0d1b2a;
  --border:          #e2e8f0;
  --border-strong:   #c8d4e3;
  --radius-sm:       6px;
  --radius-md:       12px;
  --radius-lg:       18px;
  --shadow-sm:       0 1px 4px rgba(0,0,0,.07);
  --shadow-md:       0 4px 16px rgba(0,0,0,.10);
  --shadow-lg:       0 8px 32px rgba(0,0,0,.14);
  --font-sans:       'Inter', 'Inter-fallback', system-ui, -apple-system, sans-serif;
  --font-serif:      'Merriweather', 'Merriweather-fallback', Georgia, serif;
  --max-w:           1200px;
  --header-h:        64px;
  --transition:      .2s ease;
}

/* ── 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 {
  font-family: var(--font-sans);
  background: var(--bg-page);
  color: var(--text-base);
  line-height: 1.65;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main { flex: 1; }

img, video, svg { max-width: 100%; height: auto; display: block; }

a { color: var(--brand-primary); text-decoration: none; }
a:hover { color: var(--brand-dark); text-decoration: underline; }

ul, ol { padding-left: 1.5rem; }
h1,h2,h3,h4,h5,h6 { line-height: 1.25; font-weight: 700; color: var(--text-base); }

/* ── Utility ─────────────────────────────────────────────────── */
.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;
}

.container {
  width: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: 1rem;
}

@media (min-width: 480px)  { .container { padding-inline: 1.5rem; } }
@media (min-width: 640px)  { .container { padding-inline: 2rem; } }
@media (min-width: 1280px) { .container { padding-inline: 1.5rem; } }

.badge {
  display: inline-block;
  padding: .25rem .65rem;
  border-radius: 999px;
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.badge--primary { background: var(--brand-light); color: var(--brand-dark); }
.badge--accent  { background: #fff3e0; color: #b45309; }

/* ── Site Header ─────────────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  height: var(--header-h);
  background: #fff;
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}

.header-inner {
  height: 100%;
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

/* Logo */
.site-logo {
  display: flex;
  align-items: center;
  gap: .5rem;
  text-decoration: none;
  flex-shrink: 0;
}
.logo-oh {
  background: var(--brand-primary);
  color: #fff;
  font-size: 1.3rem;
  font-weight: 800;
  width: 40px; height: 40px;
  border-radius: var(--radius-sm);
  display: grid; place-items: center;
  letter-spacing: -.5px;
}
.logo-text {
  font-size: .78rem;
  color: var(--text-muted);
  line-height: 1.3;
}
.logo-text strong { color: var(--brand-primary); font-size: .9rem; }

.site-logo--sm .logo-oh { width: 34px; height: 34px; font-size: 1.1rem; }

/* Main Nav — hidden on mobile, shown on desktop */
.main-nav { display: none; flex: 1; overflow: visible; }
.main-nav > ul {
  display: flex;
  align-items: center;
  gap: .1rem;
  list-style: none;
  padding: 0;
  margin: 0;
  flex-wrap: nowrap;
}
.main-nav > ul > li { position: relative; }
.main-nav a {
  display: block;
  padding: .4rem .65rem;
  font-size: .82rem;
  font-weight: 500;
  color: var(--text-base);
  border-radius: var(--radius-sm);
  white-space: nowrap;
  transition: background var(--transition), color var(--transition);
}
.main-nav a:hover, .main-nav a.active {
  background: var(--brand-light);
  color: var(--brand-primary);
  text-decoration: none;
}

/* "More" dropdown */
.nav-more { position: relative; }
.nav-more-btn {
  background: none; border: none; cursor: pointer;
  padding: .4rem .65rem;
  font-size: .82rem; font-weight: 500;
  color: var(--text-base);
  border-radius: var(--radius-sm);
  display: flex; align-items: center; gap: .25rem;
  transition: background var(--transition), color var(--transition);
  white-space: nowrap;
  line-height: 1;
}
.nav-more-btn:hover,
.nav-more-btn[aria-expanded="true"] { background: var(--brand-light); color: var(--brand-primary); }

/* Dropdown — always hidden unless .open */
.more-menu {
  display: none !important;
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  min-width: 250px;
  padding: .4rem 0;
  list-style: none;
  z-index: 2000;
}
.more-menu.open { display: block !important; }
.more-menu li { list-style: none; }
.more-menu li a {
  display: flex; justify-content: space-between; align-items: center;
  padding: .5rem 1rem;
  font-size: .83rem; font-weight: 400;
  color: var(--text-base);
  border-radius: 0;
  white-space: nowrap;
}
.more-menu li a:hover { background: var(--bg-page); text-decoration: none; color: var(--brand-primary); }

/* Header search */
.header-search {
  display: none;
  align-items: center;
  border: 1.5px solid var(--border);
  border-radius: 999px;
  overflow: hidden;
  transition: border-color var(--transition);
  margin-left: auto;
}
.header-search:focus-within { border-color: var(--brand-primary); }
.header-search input {
  border: none; outline: none;
  padding: .35rem .8rem;
  font-size: .83rem;
  width: 180px;
  background: transparent;
  font-family: var(--font-sans);
}
.header-search button {
  background: none; border: none; cursor: pointer;
  padding: .35rem .7rem .35rem .4rem;
  color: var(--text-muted);
  display: grid; place-items: center;
  transition: color var(--transition);
}
.header-search button:hover { color: var(--brand-primary); }

/* Hamburger */
.hamburger {
  display: flex; flex-direction: column; justify-content: space-between;
  width: 28px; height: 20px;
  background: none; border: none; cursor: pointer;
  margin-left: auto; padding: 0;
}
.hamburger span {
  display: block; width: 100%; height: 2.5px;
  background: var(--text-base); border-radius: 2px;
  transition: transform var(--transition), opacity var(--transition);
}
.hamburger.open span:nth-child(1) { transform: translateY(8.75px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-8.75px) rotate(-45deg); }

/* ── Mobile nav overlay ───────────────────────────────────────── */
.main-nav.mobile-open {
  display: flex !important;
  position: fixed;
  top: var(--header-h);
  left: 0; right: 0; bottom: 0;
  background: #fff;
  flex-direction: column;
  overflow-y: auto;
  padding: .5rem 0 3rem;
  z-index: 999;
  border-top: 1px solid var(--border);
}

/* In mobile the top-level <ul> stacks vertically */
.main-nav.mobile-open > ul {
  flex-direction: column !important;
  gap: 0 !important;
  width: 100%;
  align-items: stretch !important;
}

/* Every direct child li fills width */
.main-nav.mobile-open > ul > li {
  border-bottom: 1px solid var(--border);
  width: 100%;
}

/* All links & the More button get the same treatment */
.main-nav.mobile-open > ul > li > a,
.main-nav.mobile-open .nav-more-btn {
  display: flex !important;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: .85rem 1.5rem !important;
  font-size: .95rem !important;
  font-weight: 500;
  color: var(--text-base) !important;
  background: none;
  border-radius: 0 !important;
  text-align: left;
}
.main-nav.mobile-open > ul > li > a:hover,
.main-nav.mobile-open > ul > li > a.active,
.main-nav.mobile-open .nav-more-btn:hover,
.main-nav.mobile-open .nav-more-btn[aria-expanded="true"] {
  background: var(--brand-light) !important;
  color: var(--brand-primary) !important;
}

/* More submenu in mobile: static, inset, no absolute positioning */
.main-nav.mobile-open .more-menu {
  position: static !important;
  box-shadow: none !important;
  border: none !important;
  border-top: 1px solid var(--border) !important;
  background: #f9fafc !important;
  border-radius: 0 !important;
  padding: .25rem 0 !important;
  min-width: unset !important;
  width: 100%;
}
.main-nav.mobile-open .more-menu.open {
  display: block !important;
}
.main-nav.mobile-open .more-menu li {
  border-bottom: none;
}
.main-nav.mobile-open .more-menu li a {
  padding: .7rem 1.5rem .7rem 2.5rem !important;
  font-size: .9rem !important;
  color: var(--text-muted) !important;
}
.main-nav.mobile-open .more-menu li a:hover {
  background: var(--brand-light) !important;
  color: var(--brand-primary) !important;
}

/* ── Category count badge ─────────────────────────────────────── */
.cat-count {
  background: var(--brand-light);
  color: var(--brand-primary);
  font-size: .7rem;
  font-weight: 700;
  padding: .1rem .4rem;
  border-radius: 999px;
  min-width: 24px;
  text-align: center;
}

/* ── Breakpoint: show desktop nav ────────────────────────────── */
@media (min-width: 960px) {
  /* Show inline nav, hide hamburger */
  .main-nav {
    display: flex !important;
    position: static !important;
    flex-direction: row !important;
    overflow: visible !important;
    padding: 0 !important;
    background: transparent !important;
    border-top: none !important;
  }
  /* Reset any mobile-open overrides on desktop */
  .main-nav > ul {
    flex-direction: row !important;
    align-items: center !important;
    flex-wrap: nowrap !important;
  }
  .main-nav > ul > li {
    border-bottom: none !important;
    width: auto !important;
  }
  .main-nav > ul > li > a {
    padding: .4rem .65rem !important;
    font-size: .82rem !important;
    justify-content: flex-start !important;
    border-bottom: none !important;
  }
  .nav-more { position: relative !important; }
  .nav-more-btn {
    padding: .4rem .65rem !important;
    font-size: .82rem !important;
    justify-content: flex-start !important;
    width: auto !important;
  }
  /* More menu goes back to absolute positioning on desktop */
  .more-menu {
    position: absolute !important;
    top: calc(100% + 6px) !important;
    right: 0 !important;
    background: #fff !important;
    border: 1px solid var(--border) !important;
    border-radius: var(--radius-md) !important;
    box-shadow: var(--shadow-lg) !important;
    padding: .4rem 0 !important;
    border-top: initial !important;
    width: 250px;
  }
  .more-menu li a {
    padding: .5rem 1rem !important;
    font-size: .83rem !important;
    color: var(--text-base) !important;
  }
  .header-search { display: flex; }
  .hamburger { display: none !important; }
}

/* ══════════════════════════════════════════════════════════════
   HOMEPAGE
   ══════════════════════════════════════════════════════════════ */

/* Hero */
.hero {
  background: linear-gradient(135deg, var(--brand-dark) 0%, var(--brand-primary) 60%, #1a6bc4 100%);
  color: #fff;
  padding: 5rem 0 4rem;
  text-align: center;
  position: relative;
  overflow: hidden;
  contain: layout paint;
}
.hero::before {
  content: '';
  position: absolute; inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.04'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}
.hero-inner { position: relative; z-index: 1; max-width: 720px; margin: 0 auto; }
.hero h1 { font-size: 32px; font-weight: 800; letter-spacing: -.02em; margin-bottom: .75rem; line-height: 1.2; }
.hero p { font-size: 17px; opacity: .88; margin-bottom: 2rem; line-height: 1.6; }
.hero-stats {
  display: flex; justify-content: center; gap: 2.5rem; flex-wrap: wrap;
  margin-top: 2rem;
}
.hero-stat { text-align: center; }
.hero-stat-n { font-size: 35px; font-weight: 800; line-height: 1; }
.hero-stat-l { font-size: 12px; opacity: .75; text-transform: uppercase; letter-spacing: .08em; margin-top: .2rem; }
@media (min-width: 640px) {
  .hero h1 { font-size: 42px; }
  .hero p  { font-size: 18px; }
  .hero-stat-n { font-size: 40px; }
}
@media (min-width: 960px) {
  .hero h1 { font-size: 52px; }
  .hero-stat-n { font-size: 44px; }
}

.hero-search {
  display: flex;
  max-width: 480px;
  margin: 0 auto;
  background: rgba(255,255,255,.12);
  border: 1.5px solid rgba(255,255,255,.3);
  border-radius: 999px;
  overflow: hidden;
  backdrop-filter: blur(8px);
}
.hero-search input {
  flex: 1; background: none; border: none; outline: none;
  padding: .75rem 1.2rem;
  font-size: .95rem; color: #fff;
  font-family: var(--font-sans);
}
.hero-search input::placeholder { color: rgba(255,255,255,.65); }
.hero-search button {
  background: rgba(255,255,255,.18); border: none; cursor: pointer;
  padding: .75rem 1.2rem;
  color: #fff; font-weight: 600; font-size: .9rem;
  transition: background var(--transition);
}
.hero-search button:hover { background: rgba(255,255,255,.3); }

/* Categories grid */
.section { padding: 3.5rem 0; contain: layout; }
.section--gray { background: #f0f3f8; }
.section-header {
  display: flex; align-items: baseline; justify-content: space-between;
  margin-bottom: 1.75rem; gap: 1rem; flex-wrap: wrap;
}
.section-header h2 { font-size: 1.4rem; }
.section-header a { font-size: .85rem; color: var(--brand-primary); font-weight: 500; }

.categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem;
}
.category-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 1.25rem 1.5rem;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 1rem;
  min-height: 72px;
  transition: box-shadow var(--transition), border-color var(--transition), transform var(--transition);
  color: var(--text-base);
}
.category-card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--brand-primary);
  translate: 0 -2px;
  text-decoration: none;
  color: var(--text-base);
}
.category-card-icon {
  width: 44px; height: 44px; border-radius: var(--radius-sm);
  background: var(--brand-light);
  display: grid; place-items: center;
  font-size: 1.3rem;
  flex-shrink: 0;
}
.category-card-info { min-width: 0; }
.category-card-name { font-weight: 600; font-size: .88rem; line-height: 1.3; }
.category-card-count { font-size: .78rem; color: var(--text-muted); margin-top: .15rem; }

/* Post cards grid */
.posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
}
.posts-grid--featured {
  grid-template-columns: 1fr;
}
@media (min-width: 640px) {
  .posts-grid--featured { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 900px) {
  .posts-grid--featured { grid-template-columns: repeat(3, 1fr); }
  .posts-grid--featured .post-card:first-child {
    grid-column: span 2;
    grid-row: span 2;
  }
}

.post-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow var(--transition), transform var(--transition);
}
.post-card:hover { box-shadow: var(--shadow-md); translate: 0 -3px; }
.post-card:hover .post-card-title a { color: var(--brand-primary); }

.post-card-thumb {
  aspect-ratio: 16/9;
  overflow: hidden;
  background: var(--brand-light);
  position: relative;
}
.post-card-thumb img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .4s ease;
}
.post-card:hover .post-card-thumb img { transform: scale(1.04); }
.post-card-thumb-placeholder {
  width: 100%; height: 100%;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: .5rem;
  color: var(--brand-primary); opacity: .5;
  font-size: .8rem; font-weight: 600; text-transform: uppercase; letter-spacing: .08em;
}
.post-card-thumb-placeholder svg { opacity: .4; }

.post-card-body { padding: 1.1rem 1.25rem; flex: 1; display: flex; flex-direction: column; gap: .5rem; }
.post-card-meta { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }
.post-card-cat {
  font-size: .7rem; font-weight: 600; text-transform: uppercase; letter-spacing: .06em;
  color: var(--brand-primary);
  text-decoration: none;
}
.post-card-cat:hover { text-decoration: underline; }
.post-card-date { font-size: .73rem; color: #6b7280; margin-left: auto; }
.post-card-title { font-size: .97rem; font-weight: 700; line-height: 1.4; }
.post-card-title a { color: inherit; text-decoration: none; }
.post-card-title a:hover { color: var(--brand-primary); }
.post-card-desc { font-size: .83rem; color: var(--text-muted); flex: 1; }
.post-card-tags { display: flex; flex-wrap: wrap; gap: .35rem; margin-top: auto; padding-top: .5rem; }
.post-card-tag {
  font-size: .68rem; padding: .15rem .5rem;
  background: var(--bg-page); border: 1px solid var(--border);
  border-radius: 999px; color: var(--text-muted);
  text-decoration: none;
}
.post-card-tag:hover { border-color: var(--brand-primary); color: var(--brand-primary); text-decoration: none; }

/* Featured / large card overrides */
.posts-grid--featured .post-card:first-child .post-card-title { font-size: 1.2rem; }
.posts-grid--featured .post-card:first-child .post-card-desc { font-size: .9rem; }

/* ══════════════════════════════════════════════════════════════
   CATEGORY PAGE
   ══════════════════════════════════════════════════════════════ */
.page-banner {
  background: linear-gradient(135deg, var(--brand-dark), var(--brand-primary));
  color: #fff;
  padding: 2.5rem 0;
}
.page-banner h1 { font-size: 26px; }
@media (min-width: 640px) { .page-banner h1 { font-size: 32px; } }
@media (min-width: 960px) { .page-banner h1 { font-size: 38px; } }
.page-banner p { opacity: .82; margin-top: .4rem; font-size: .95rem; }

.breadcrumb {
  display: flex; align-items: center; gap: .5rem;
  font-size: .8rem; color: rgba(255,255,255,.7);
  margin-bottom: .75rem;
  list-style: none; padding: 0;
}
.breadcrumb a { color: rgba(255,255,255,.85); }
.breadcrumb a:hover { color: #fff; }
.breadcrumb li + li::before { content: '/'; margin-right: .5rem; }

.layout-sidebar {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  padding-block: 2.5rem;
  align-items: start;
}
@media (min-width: 900px) {
  .layout-sidebar { grid-template-columns: 1fr 280px; }
}

.sidebar { display: flex; flex-direction: column; gap: 1.5rem; }
.sidebar-widget {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.sidebar-widget-title {
  padding: .9rem 1.1rem;
  font-size: .82rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .08em;
  border-bottom: 1px solid var(--border);
  color: var(--text-muted);
  background: var(--bg-page);
}
.sidebar-widget-body { padding: .75rem; }

.sidebar-cat-list { list-style: none; padding: 0; }
.sidebar-cat-list li a {
  display: flex; justify-content: space-between; align-items: center;
  padding: .5rem .4rem;
  font-size: .84rem;
  color: var(--text-base);
  border-radius: var(--radius-sm);
  transition: background var(--transition);
}
.sidebar-cat-list li a:hover { background: var(--bg-page); text-decoration: none; }
.sidebar-cat-list li a.active { color: var(--brand-primary); font-weight: 600; }

/* ── Pagination ───────────────────────────────────────────────── */
.pagination {
  display: flex; align-items: center; justify-content: center;
  gap: .4rem; flex-wrap: wrap;
  padding: 2rem 0 1rem;
}
.pagination a, .pagination span {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 38px; height: 38px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: .85rem; font-weight: 500;
  color: var(--text-base);
  text-decoration: none;
  transition: all var(--transition);
  padding: 0 .6rem;
}
.pagination a:hover { border-color: var(--brand-primary); color: var(--brand-primary); background: var(--brand-light); text-decoration: none; }
.pagination .current { background: var(--brand-primary); border-color: var(--brand-primary); color: #fff; }
.pagination .disabled { opacity: .4; pointer-events: none; }

/* ══════════════════════════════════════════════════════════════
   SINGLE POST PAGE
   ══════════════════════════════════════════════════════════════ */
.post-header {
  background: linear-gradient(135deg, var(--brand-dark), var(--brand-primary));
  color: #fff;
  padding-block: 2rem 1.75rem;
}
@media (min-width: 640px) { .post-header { padding-block: 3rem 2.5rem; } }
.post-header-inner { max-width: 860px; }
.post-header h1 { font-size: 24px; font-weight: 800; line-height: 1.25; }
@media (min-width: 640px)  { .post-header h1 { font-size: 32px; } }
@media (min-width: 960px)  { .post-header h1 { font-size: 40px; } }
.post-header-meta {
  display: flex; flex-wrap: wrap; align-items: center; gap: .75rem;
  margin-top: 1rem; font-size: .83rem; opacity: .88;
}
.post-header-meta .dot { opacity: .5; }

.post-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  padding-block: 1.5rem 2rem;
  align-items: start;
}
@media (min-width: 640px) { .post-layout { gap: 2rem; padding-block: 2.5rem 3rem; } }
@media (min-width: 960px) {
  .post-layout { grid-template-columns: 1fr 280px; }
}

/* Article body */
.article-body { min-width: 0; }

.post-banner {
  width: 100%;
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-bottom: 2rem;
  box-shadow: var(--shadow-sm);
  max-height: 480px;
}
.post-banner img { width: 100%; height: 100%; object-fit: cover; }

.prose {
  font-family: var(--font-serif);
  font-size: .97rem;
  line-height: 1.8;
  color: var(--text-base);
  max-width: 720px;
}
@media (min-width: 640px) { .prose { font-size: 1.025rem; line-height: 1.85; } }
.prose h1,.prose h2,.prose h3,.prose h4 {
  font-family: var(--font-sans);
  margin-top: 1.8em; margin-bottom: .6em;
  color: var(--brand-dark);
}
.prose h2 { font-size: 1.4rem; border-bottom: 2px solid var(--brand-light); padding-bottom: .4rem; }
.prose h3 { font-size: 1.15rem; }
.prose p { margin-bottom: 1.1em; }
.prose ul, .prose ol { margin-bottom: 1.1em; }
.prose li { margin-bottom: .35em; }
.prose strong { font-weight: 700; }
.prose em { font-style: italic; }
.prose a { color: var(--brand-primary); }
.prose a:hover { text-decoration: underline; }
.prose blockquote {
  border-left: 4px solid var(--brand-primary);
  margin: 1.5em 0; padding: .75rem 1.2rem;
  background: var(--brand-light);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-style: italic;
}
.prose blockquote p { margin: 0; }
.prose hr { border: none; border-top: 2px solid var(--border); margin: 2em 0; }
.prose code {
  background: #f0f3f8; padding: .1em .4em;
  border-radius: 4px; font-size: .88em;
  font-family: 'Courier New', monospace;
}

/* Tables */
.prose table, .table-responsive table {
  width: 100%; border-collapse: collapse;
  font-family: var(--font-sans); font-size: .88rem;
  margin-bottom: 1.5em;
}
.table-responsive { overflow-x: auto; margin-bottom: 1.5em; border-radius: var(--radius-sm); border: 1px solid var(--border); }
.prose table th, .table-responsive th {
  background: var(--brand-primary); color: #fff;
  padding: .6rem .9rem; text-align: left;
  font-weight: 600; font-size: .82rem;
  white-space: nowrap;
}
.prose table td, .table-responsive td {
  padding: .55rem .9rem;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}
.prose table tr:last-child td, .table-responsive tr:last-child td { border-bottom: none; }
.prose table tr:nth-child(even), .table-responsive tr:nth-child(even) { background: #f7f8fc; }

/* Inline content images */
.prose img, .content-img {
  max-width: 100%;
  border-radius: var(--radius-sm);
  margin: 1.5em auto;
  display: block;
  box-shadow: var(--shadow-sm);
}

/* File attachments */
.file-attachments { margin-top: 2rem; }
.file-attachments h3 {
  font-size: .85rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .08em;
  color: var(--text-muted);
  margin-bottom: .75rem;
  padding-bottom: .5rem;
  border-bottom: 2px solid var(--border);
}
.file-list { display: flex; flex-direction: column; gap: .5rem; }
.file-item {
  display: flex; align-items: center; gap: .9rem;
  padding: .75rem 1rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  text-decoration: none;
  color: var(--text-base);
  transition: all var(--transition);
}
.file-item:hover { border-color: var(--brand-primary); background: var(--brand-light); text-decoration: none; }
.file-icon {
  width: 36px; height: 36px; flex-shrink: 0;
  border-radius: var(--radius-sm);
  display: grid; place-items: center;
  font-size: .65rem; font-weight: 800;
  text-transform: uppercase; letter-spacing: .04em;
}
.file-icon--pdf { background: #fee2e2; color: #b91c1c; }
.file-icon--xlsx,.file-icon--xls { background: #dcfce7; color: #166534; }
.file-icon--docx,.file-icon--doc { background: #dbeafe; color: #1e40af; }
.file-icon--default { background: var(--bg-page); color: var(--text-muted); }
.file-info { min-width: 0; flex: 1; }
.file-name { font-size: .88rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.file-type { font-size: .73rem; color: var(--text-muted); margin-top: .1rem; }
.file-dl {
  flex-shrink: 0; color: var(--brand-primary);
  font-size: .75rem; font-weight: 600;
  display: flex; align-items: center; gap: .3rem;
}

/* Tags */
.post-tags { margin-top: 2rem; }
.post-tags h3 { font-size: .82rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--text-muted); margin-bottom: .6rem; }
.tags-list { display: flex; flex-wrap: wrap; gap: .4rem; }
.tag-item {
  font-size: .78rem; padding: .25rem .7rem;
  background: var(--bg-page); border: 1px solid var(--border);
  border-radius: 999px; color: var(--text-base);
  text-decoration: none; transition: all var(--transition);
}
.tag-item:hover { border-color: var(--brand-primary); color: var(--brand-primary); background: var(--brand-light); text-decoration: none; }

/* Share */
.share-bar {
  display: flex; align-items: center; gap: .6rem; flex-wrap: wrap;
  margin-top: 2rem; padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}
.share-bar span { font-size: .82rem; font-weight: 600; color: var(--text-muted); margin-right: .25rem; }
.share-btn {
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .4rem .9rem;
  border-radius: 999px; font-size: .8rem; font-weight: 600;
  text-decoration: none; transition: opacity var(--transition);
  color: #fff;
}
.share-btn:hover { opacity: .85; text-decoration: none; color: #fff; }
.share-btn--twitter { background: #1da1f2; }
.share-btn--linkedin { background: #0077b5; }
.share-btn--copy { background: var(--text-muted); cursor: pointer; border: none; font-family: var(--font-sans); }

/* Related posts */
.related-section { margin-top: 3rem; padding-top: 2rem; border-top: 2px solid var(--border); }
.related-section h2 { font-size: 1.15rem; margin-bottom: 1.25rem; }
.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem;
}

/* ══════════════════════════════════════════════════════════════
   SEARCH PAGE
   ══════════════════════════════════════════════════════════════ */
.search-header {
  background: var(--bg-card);
  border-bottom: 1px solid var(--border);
  padding: 2rem 0;
}
.search-form-lg {
  display: flex; max-width: 600px;
  border: 2px solid var(--brand-primary);
  border-radius: 999px; overflow: hidden;
}
.search-form-lg input {
  flex: 1; border: none; outline: none;
  padding: .75rem 1.25rem; font-size: 1rem;
  font-family: var(--font-sans);
}
.search-form-lg button {
  background: var(--brand-primary); border: none; cursor: pointer;
  padding: .75rem 1.5rem; color: #fff; font-weight: 600;
  font-size: .9rem; transition: background var(--transition);
}
.search-form-lg button:hover { background: var(--brand-dark); }
.search-results-info { font-size: .88rem; color: var(--text-muted); margin-top: 1.5rem; }
.search-results-info strong { color: var(--text-base); }

/* ══════════════════════════════════════════════════════════════
   SITE FOOTER
   ══════════════════════════════════════════════════════════════ */
.site-footer {
  background: var(--bg-dark);
  color: rgba(255,255,255,.75);
  margin-top: auto;
}
.footer-inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  padding-block: 3.5rem 2rem;
}
@media (min-width: 640px)  { .footer-inner { grid-template-columns: 1fr 1fr; } }
@media (min-width: 960px)  { .footer-inner { grid-template-columns: 1.5fr 1fr 1.5fr; } }

.footer-brand .site-logo { margin-bottom: 1rem; }
.footer-brand p { font-size: .84rem; line-height: 1.7; max-width: 280px; }
.footer-brand .logo-text { color: rgba(255,255,255,.7); }
.footer-brand .logo-text strong { color: #fff; }

.footer-nav h3, .footer-info h3 {
  font-size: .78rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .1em;
  color: #94a3b8;
  margin-bottom: 1rem;
}
.footer-nav ul { list-style: none; padding: 0; display: flex; flex-direction: column; gap: .35rem; }
.footer-nav a { color: rgba(255,255,255,.72); font-size: .84rem; text-decoration: none; transition: color var(--transition); }
.footer-nav a:hover { color: #fff; text-decoration: none; }
.footer-nav .cat-count { background: rgba(255,255,255,.1); color: #94a3b8; }

.footer-info p { font-size: .84rem; line-height: 1.7; margin-bottom: .75rem; }
.footer-search label { display: block; font-size: .78rem; color: #8899aa; margin-bottom: .4rem; }
.footer-search-row { display: flex; border-radius: var(--radius-sm); overflow: hidden; }
.footer-search input {
  flex: 1; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.15);
  border-right: none; outline: none;
  padding: .5rem .8rem; color: #fff; font-size: .85rem;
  font-family: var(--font-sans);
}
.footer-search input::placeholder { color: rgba(255,255,255,.35); }
.footer-search button {
  background: var(--brand-primary); border: none; cursor: pointer;
  padding: .5rem 1rem; color: #fff; font-size: .85rem; font-weight: 600;
  transition: background var(--transition);
}
.footer-search button:hover { background: var(--brand-dark); }

.footer-bar {
  border-top: 1px solid rgba(255,255,255,.08);
  padding-block: 1.25rem;
}
.footer-bar .container {
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: .5rem;
  font-size: .78rem; color: #8899aa;
}
.footer-bar a { color: #a0b0c0; text-decoration: underline; }
.footer-bar a:hover { color: #fff; }

/* ══════════════════════════════════════════════════════════════
   EMPTY STATES & MISC
   ══════════════════════════════════════════════════════════════ */
.empty-state {
  text-align: center; padding: 4rem 1rem;
  color: var(--text-muted);
}
.empty-state svg { margin: 0 auto 1rem; opacity: .3; }
.empty-state h3 { font-size: 1.1rem; margin-bottom: .5rem; }
.empty-state p { font-size: .9rem; }

/* ── Scroll to top ────────────────────────────────────────────── */
#scroll-top {
  position: fixed; bottom: 1.5rem; right: 1.5rem;
  width: 42px; height: 42px;
  background: var(--brand-primary);
  color: #fff; border: none; cursor: pointer;
  border-radius: 50%; box-shadow: var(--shadow-md);
  display: grid; place-items: center;
  opacity: 0; pointer-events: none;
  translate: 0 8px;
  transition: opacity var(--transition), translate var(--transition);
  z-index: 500;
}
#scroll-top.visible { opacity: 1; pointer-events: auto; translate: 0 0; }
#scroll-top:hover { background: var(--brand-dark); }

/* ── Print ────────────────────────────────────────────────────── */
@media print {
  .site-header, .site-footer, .sidebar, .share-bar,
  .related-section, #scroll-top, .hamburger { display: none !important; }
  .post-layout { grid-template-columns: 1fr !important; }
  .prose { font-size: 12pt; }
  a[href]::after { content: " (" attr(href) ")"; font-size: .8em; color: #666; }
}

/* ═══════════════════════════════════════════════ STATIC PAGES ══ */

.static-hero {
  padding: 4rem 0 3rem;
  color: #fff;
  text-align: center;
}
.static-hero h1 {
  font-size: clamp(1.8rem, 4vw, 3rem);
  margin: 0 0 .75rem;
  font-weight: 800;
}
.static-hero p {
  font-size: 1.1rem;
  opacity: .85;
  margin: 0;
}
.static-page {
  padding: 3rem 1rem 4rem;
}
.static-content {
  max-width: 780px;
  margin: 0 auto;
}
.static-content h2 { margin-top: 2rem; }
.static-content h3 { margin-top: 1.5rem; color: var(--blue); }
.static-content p, .static-content li { line-height: 1.75; }
.static-content ul { padding-left: 1.5rem; margin: .5rem 0 1rem; }
.static-content blockquote {
  border-left: 4px solid var(--blue);
  padding: .75rem 1.25rem;
  background: #f0f7ff;
  border-radius: 0 8px 8px 0;
  margin: 1.5rem 0;
  font-size: 1.05rem;
}
.prose h2 { font-size: 1.3rem; margin-top: 2rem; }

/* Contact CTA block */
.contact-cta {
  background: #f0f7ff;
  border: 1px solid #c7ddf7;
  border-radius: 12px;
  padding: 2rem;
  text-align: center;
  margin-top: 2.5rem;
}
.contact-cta h3 { margin: 0 0 1rem; font-size: 1.3rem; }
.btn-primary {
  display: inline-block;
  background: var(--blue);
  color: #fff;
  padding: .7rem 1.75rem;
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
  transition: background .2s;
}
.btn-primary:hover { background: #002f5e; }
.btn-secondary {
  display: inline-block;
  background: #fff;
  color: var(--blue);
  border: 2px solid var(--blue);
  padding: .65rem 1.75rem;
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
  transition: all .2s;
}
.btn-secondary:hover { background: #f0f7ff; }

/* ── Services grid ── */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}
.service-card {
  display: block;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 1.75rem;
  text-decoration: none;
  color: inherit;
  transition: box-shadow .2s, transform .2s;
}
.service-card:hover {
  box-shadow: 0 8px 24px rgba(0,61,122,.12);
  translate: 0 -3px;
}
.service-icon { font-size: 2rem; margin-bottom: .75rem; }
.service-card h3 { margin: 0 0 .5rem; color: var(--blue); font-size: 1.1rem; }
.service-card p  { margin: 0; font-size: .92rem; color: #555; line-height: 1.6; }

/* ── Service offerings grid ── */
.service-offerings {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.25rem;
  margin: 2rem 0;
}
.offering-group {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 1.25rem;
}
.offering-group h3 {
  font-size: .9rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--blue);
  margin: 0 0 .75rem;
}
.offering-group ul { padding-left: 1.1rem; margin: 0; }
.offering-group li { font-size: .88rem; line-height: 1.8; }

/* ── Team ── */
.team-grid { display: flex; flex-direction: column; gap: 2rem; }
.team-card {
  display: flex;
  gap: 2rem;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 2rem;
  align-items: flex-start;
}
.team-avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: var(--blue);
  color: #fff;
  font-size: 1.4rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.team-info h2  { margin: 0 0 .25rem; font-size: 1.3rem; }
.team-role { color: var(--blue); font-weight: 600; margin: 0 0 .75rem; font-size: .95rem; }

/* ── Contact page ── */
.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 3rem;
  max-width: 900px;
  margin: 0 auto;
}
@media (max-width: 700px) {
  .contact-layout { grid-template-columns: 1fr; }
  .team-card { flex-direction: column; }
}
.contact-item {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.5rem;
  align-items: flex-start;
}
.contact-icon { font-size: 1.4rem; flex-shrink: 0; }
.contact-item strong { display: block; margin-bottom: .2rem; }
.contact-item p { margin: 0; }
.contact-form .form-group { margin-bottom: 1.25rem; }
.contact-form label { display: block; font-weight: 600; margin-bottom: .4rem; font-size: .9rem; }
.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: .65rem .9rem;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: .95rem;
  font-family: inherit;
  transition: border-color .2s;
}
.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(0,61,122,.1);
}

/* ── FAQ ── */
.faq-list { max-width: 780px; margin: 0 auto; }
.faq-group { margin-bottom: 2.5rem; }
.faq-group h2 {
  font-size: 1.15rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--blue);
  border-bottom: 2px solid #e2e8f0;
  padding-bottom: .5rem;
  margin-bottom: 1.25rem;
}
.faq-item { margin-bottom: 1.5rem; }
.faq-item h3 { font-size: 1rem; font-weight: 600; margin: 0 0 .4rem; }
.faq-item p  { margin: 0; color: #444; line-height: 1.7; }

/* ── Nav dropdowns (sub-menu) ── */
.nav-has-sub { position: relative; }
.nav-has-sub > a { cursor: pointer; }
.main-nav .sub-menu {
  display: none;
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0,0,0,.12);
  min-width: 260px;
  z-index: 99999;
  padding: .5rem 0;
  /* keep hover active while moving mouse into dropdown */
  padding-top: 4px;
  margin-top: -4px;
}
.nav-has-sub:hover .sub-menu,
.nav-has-sub.open .sub-menu {
  display: block;
}
.main-nav .sub-menu li { display: block; }
.main-nav .sub-menu li a {
  display: block;
  padding: .55rem 1.25rem;
  color: #1e293b;
  font-size: .9rem;
  font-weight: 500;
  white-space: nowrap;
  transition: background .15s, color .15s;
}
.main-nav .sub-menu li a:hover {
  background: #f0f7ff;
  color: var(--blue);
}

/* Social icons in nav */
.nav-social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: #e8f0fe;
  border-radius: 6px;
  font-size: .85rem;
  font-weight: 700;
  color: var(--blue) !important;
  text-decoration: none;
  transition: background .2s;
}
.nav-social a:hover { background: #c7ddf7; }

/* Footer extra columns */
.footer-links-col h3 { font-size: .95rem; font-weight: 700; margin-bottom: .75rem; color: #fff; }
.footer-links-col ul { list-style: none; padding: 0; margin: 0; }
.footer-links-col li { margin-bottom: .4rem; }
.footer-links-col a { color: #94a3b8; font-size: .9rem; text-decoration: none; transition: color .15s; }
.footer-links-col a:hover { color: #fff; }
.footer-social {
  color: #94a3b8 !important;
  font-size: .85rem;
  text-decoration: none;
  transition: color .15s;
}
.footer-social:hover { color: #fff !important; }

/* Mobile: sub-menus stack */
@media (max-width: 959px) {
  .main-nav .sub-menu {
    position: static;
    box-shadow: none;
    border: none;
    background: rgba(0,0,0,.04);
    border-radius: 0;
    padding: 0 0 0 1rem;
    display: none;
  }
  .nav-has-sub.open .sub-menu { display: block; }
  .nav-has-sub > a span { pointer-events: none; }
}

/* ── Real logo image ── */
.logo-img {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
}
.site-logo--sm .logo-img { width: 44px; height: 44px; }
