/*
Theme Name: Friendship Integrity
Theme URI: http://friendship-house.org
Description: Custom theme for Friendship House community services resource
Version: 1.0
Author: Friendship House
Text Domain: friendship-integrity
*/

/* === Design Tokens (PBN-safe names) === */
:root {
  --fh-forest: #1f4438;
  --fh-forest-deep: #052e23;
  --fh-terracotta: #984803;
  --fh-terracotta-bright: #c66b2a;
  --fh-cream: #f7fbed;
  --fh-cream-warm: #fcfaf7;
  --fh-text: #181d14;
  --fh-text-muted: #414845;
  --fh-border: #d9d1bd;
  --fh-outline: #717975;
  --fh-surface: #ebf0e1;
  --fh-surface-low: #f1f5e7;
  --fh-surface-high: #e5eadc;
  --fh-surface-variant: #e0e4d6;
  --fh-inverse: #2d3229;
  --fh-inverse-text: #eef3e4;
  --fh-mint: #a7cfbf;
  --fh-mint-light: #c3ebda;
  --fh-orange-bright: #fd9752;
  --fh-white: #ffffff;
  --fh-container: 1140px;
  --fh-gutter: 24px;
  --fh-radius: 4px;
}

/* === Reset & Base === */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 16px; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }

body {
  background-color: var(--fh-cream);
  color: var(--fh-text);
  font-family: 'Cabin', 'Public Sans', system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.6;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--fh-forest); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--fh-terracotta-bright); }

h1, h2, h3, h4, h5, h6 {
  font-family: 'Newsreader', Georgia, serif;
  color: var(--fh-forest);
  line-height: 1.2;
}
h1 { font-size: 48px; font-weight: 600; letter-spacing: -0.02em; line-height: 1.2; }
h2 { font-size: 36px; font-weight: 600; line-height: 1.3; }
h3 { font-size: 24px; font-weight: 500; line-height: 1.4; }

p { margin-bottom: 1em; }

ul { list-style-type: square; list-style-position: inside; color: var(--fh-forest); }

/* === Layout === */
.wrap {
  max-width: var(--fh-container);
  margin: 0 auto;
  padding: 0 var(--fh-gutter);
}

/* === Brand Bar (Header) === */
.brand-bar {
  background: var(--fh-cream-warm);
  border-bottom: 1px solid var(--fh-border);
}
.brand-bar__inner {
  max-width: var(--fh-container);
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px var(--fh-gutter);
}
.wordmark {
  font-family: 'Newsreader', Georgia, serif;
  font-size: 24px;
  font-weight: 700;
  color: var(--fh-forest);
  letter-spacing: -0.01em;
  display: flex;
  align-items: center;
  gap: 8px;
}
.wordmark__icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #eae2cd;
  border: 1px solid var(--fh-outline);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Newsreader', Georgia, serif;
  font-size: 18px;
  font-weight: 500;
  color: var(--fh-forest-deep);
}

/* === Top Nav === */
.top-nav {
  display: flex;
  align-items: center;
  gap: var(--fh-gutter);
}
.top-nav a {
  font-family: 'Cabin', sans-serif;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.05em;
  color: #555;
  transition: color 0.2s;
}
.top-nav a:hover { color: var(--fh-terracotta-bright); }
.top-nav a.is-active {
  color: var(--fh-forest);
  border-bottom: 2px solid var(--fh-terracotta-bright);
  padding-bottom: 2px;
}

.brand-bar__actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

/* === Buttons === */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'Cabin', sans-serif;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.05em;
  padding: 10px 24px;
  border-radius: var(--fh-radius);
  border: none;
  cursor: pointer;
  transition: opacity 0.2s, background-color 0.2s;
}
.btn:hover { opacity: 0.9; }
.btn--forest { background: var(--fh-forest); color: var(--fh-white); }
.btn--forest:hover { background: var(--fh-forest-deep); color: var(--fh-white); }
.btn--terra { background: var(--fh-terracotta); color: var(--fh-white); }
.btn--terra:hover { background: var(--fh-terracotta-bright); color: var(--fh-white); }
.btn--ghost {
  background: transparent;
  color: var(--fh-forest);
  border: 1px solid var(--fh-outline);
}
.btn--ghost:hover { background: var(--fh-surface-high); color: var(--fh-forest); }

/* === Mobile Toggle === */
.mobile-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--fh-forest);
  cursor: pointer;
  font-size: 24px;
}

/* === Cards === */
.card {
  border: 1px solid var(--fh-border);
  border-radius: var(--fh-radius);
  background: var(--fh-white);
  overflow: hidden;
  transition: border-color 0.2s;
}
.card:hover { border-color: var(--fh-forest); }
.card__body { padding: var(--fh-gutter); }
.card__img {
  width: 100%;
  height: 240px;
  object-fit: cover;
  border-bottom: 1px solid var(--fh-border);
}

/* === Hero Section === */
.hero {
  border: 1px solid var(--fh-outline);
  background: var(--fh-surface);
  border-radius: var(--fh-radius);
  overflow: hidden;
  display: flex;
}
.hero__content {
  padding: 64px;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.hero__content h1 { margin-bottom: 16px; }
.hero__content p {
  font-size: 18px;
  line-height: 1.6;
  color: var(--fh-text-muted);
  max-width: 500px;
  margin-bottom: 32px;
}
.hero__image {
  flex: 1;
  min-height: 300px;
  border-left: 1px solid var(--fh-outline);
  position: relative;
}
.hero__image img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* === Section Headers === */
.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--fh-outline);
  padding-bottom: 8px;
  margin-bottom: 24px;
}
.section-head h2 { margin: 0; }
.section-head a {
  font-family: 'Cabin', sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: var(--fh-terracotta);
  display: flex;
  align-items: center;
  gap: 4px;
}
.section-head a:hover { text-decoration: underline; }

/* === Grid === */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--fh-gutter); }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--fh-gutter); }

/* === Icon Box === */
.icon-box {
  width: 48px;
  height: 48px;
  background: var(--fh-surface);
  border: 1px solid var(--fh-outline);
  border-radius: var(--fh-radius);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

/* === Dark Banner === */
.dark-banner {
  background: var(--fh-forest-deep);
  color: var(--fh-white);
  border-radius: var(--fh-radius);
  padding: 64px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.dark-banner h2 { color: var(--fh-white); margin-bottom: 16px; }
.dark-banner p { color: var(--fh-mint-light); font-size: 18px; line-height: 1.6; max-width: 640px; margin: 0 auto 32px; }

/* === Label/Tag === */
.label {
  font-family: 'Cabin', sans-serif;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.label--terra { color: var(--fh-terracotta); }
.label--forest { color: var(--fh-forest); }

/* === Blog Cards === */
.blog-card { display: flex; flex-direction: column; }
.blog-card__img {
  height: 192px;
  object-fit: cover;
  border-bottom: 1px solid var(--fh-border);
}
.blog-card__meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}
.blog-card__title {
  font-family: 'Newsreader', Georgia, serif;
  font-size: 24px;
  font-weight: 500;
  line-height: 1.4;
  color: var(--fh-text);
  margin-bottom: 12px;
  transition: color 0.2s;
}
.blog-card:hover .blog-card__title { color: var(--fh-forest); }
.blog-card__excerpt {
  color: var(--fh-text-muted);
  font-size: 16px;
  line-height: 1.6;
  flex-grow: 1;
}
.blog-card__footer {
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid var(--fh-border);
}

/* === Featured Blog Card (wide) === */
.blog-card--featured {
  flex-direction: row;
}
.blog-card--featured .blog-card__img {
  width: 50%;
  height: auto;
  min-height: 300px;
  border-bottom: none;
  border-right: 1px solid var(--fh-border);
}
.blog-card--featured .card__body {
  width: 50%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: var(--fh-surface-low);
}

/* === Category Filters === */
.cat-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  border-bottom: 1px solid var(--fh-border);
  padding-bottom: 16px;
  margin-bottom: 32px;
}
.cat-filters a, .cat-filters button {
  font-family: 'Cabin', sans-serif;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.05em;
  color: var(--fh-text-muted);
  background: none;
  border: none;
  cursor: pointer;
  padding-bottom: 8px;
  transition: color 0.2s;
}
.cat-filters a:hover, .cat-filters button:hover { color: var(--fh-forest); }
.cat-filters a.is-active, .cat-filters button.is-active {
  color: var(--fh-forest);
  border-bottom: 2px solid var(--fh-terracotta-bright);
}

/* === Pagination === */
.pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 32px;
}
.pagination a, .pagination span {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--fh-border);
  border-radius: var(--fh-radius);
  font-family: 'Cabin', sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: var(--fh-text-muted);
  transition: background-color 0.2s;
}
.pagination a:hover { background: var(--fh-surface-high); color: var(--fh-forest); }
.pagination .current {
  background: var(--fh-forest);
  color: var(--fh-white);
  border-color: var(--fh-forest);
}

/* === Article/Single Post === */
.article-header { text-align: center; margin-bottom: 32px; }
.article-header h1 { margin-bottom: 16px; }
.article-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  color: var(--fh-text-muted);
  font-size: 14px;
  font-weight: 600;
}
.article-featured-img {
  border: 1px solid var(--fh-border);
  border-radius: var(--fh-radius);
  overflow: hidden;
  margin-bottom: 48px;
}
.article-featured-img img { width: 100%; max-height: 500px; object-fit: cover; }

.article-body {
  max-width: 760px;
  margin: 0 auto;
}
.article-body h2 { margin-top: 48px; margin-bottom: 16px; }
.article-body h3 { margin-top: 32px; margin-bottom: 8px; }
.article-body p { font-size: 18px; line-height: 1.6; }
.article-body blockquote {
  border-left: 4px solid var(--fh-terracotta);
  padding-left: 16px;
  margin: 32px 0;
  font-family: 'Newsreader', Georgia, serif;
  font-size: 24px;
  font-weight: 500;
  line-height: 1.4;
  color: var(--fh-text-muted);
  font-style: italic;
}
.article-body blockquote cite {
  display: block;
  font-size: 14px;
  font-weight: 600;
  font-style: normal;
  margin-top: 8px;
  color: var(--fh-outline);
  font-family: 'Cabin', sans-serif;
}
.article-body ul {
  list-style: none;
  padding-left: 16px;
  margin-bottom: 16px;
}
.article-body ul li {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-bottom: 8px;
}
.article-body ul li::before {
  content: "\25A0";
  color: var(--fh-forest);
  flex-shrink: 0;
  margin-top: 4px;
}

/* === Author Box === */
.author-box {
  display: flex;
  align-items: center;
  gap: var(--fh-gutter);
  border-top: 1px solid var(--fh-border);
  padding-top: 24px;
  margin-top: 48px;
}
.author-box__photo {
  width: 64px;
  height: 64px;
  border-radius: var(--fh-radius);
  border: 1px solid var(--fh-border);
  object-fit: cover;
  flex-shrink: 0;
}
.author-box__name {
  font-family: 'Cabin', sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: var(--fh-forest);
  margin-bottom: 4px;
}
.author-box__bio {
  font-size: 14px;
  color: var(--fh-text-muted);
  line-height: 1.5;
}

/* === Contact Page === */
.contact-grid {
  display: grid;
  grid-template-columns: 5fr 7fr;
  gap: var(--fh-gutter);
}
.contact-info-block {
  border: 1px solid var(--fh-border);
  border-radius: var(--fh-radius);
  background: var(--fh-white);
  padding: 32px;
}
.contact-info-block h2 {
  font-size: 24px;
  border-bottom: 1px solid var(--fh-border);
  padding-bottom: 8px;
  margin-bottom: 16px;
}
.contact-item {
  display: flex;
  gap: 12px;
  margin-top: 16px;
}
.contact-item h3 {
  font-family: 'Cabin', sans-serif;
  font-size: 14px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}
.contact-item p, .contact-item a {
  font-size: 16px;
  color: var(--fh-text-muted);
  line-height: 1.6;
}

/* === About Page === */
.about-hero { text-align: center; margin-bottom: 48px; }
.about-hero h1 { margin-bottom: 16px; }
.about-hero p { font-size: 18px; line-height: 1.6; color: var(--fh-text-muted); max-width: 760px; margin: 0 auto; }

.history-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: var(--fh-gutter);
}
.history-main {
  background: var(--fh-surface);
  border: 1px solid var(--fh-border);
  border-radius: var(--fh-radius);
  padding: 32px;
}
.history-side {
  display: flex;
  flex-direction: column;
  gap: var(--fh-gutter);
}
.history-milestone {
  background: var(--fh-cream);
  border: 1px solid var(--fh-border);
  border-radius: var(--fh-radius);
  padding: 16px;
  flex: 1;
}
.history-milestone .year {
  font-family: 'Newsreader', Georgia, serif;
  font-size: 24px;
  font-weight: 500;
  color: var(--fh-terracotta);
  margin-bottom: 8px;
}

/* === Board Grid === */
.board-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--fh-gutter); }
.board-member {
  border: 1px solid var(--fh-border);
  border-radius: var(--fh-radius);
  background: var(--fh-cream);
  padding: 16px;
  text-align: center;
}
.board-member__photo {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  border: 1px solid var(--fh-border);
  object-fit: cover;
  margin: 0 auto 8px;
}

/* === Service Locator === */
.locator {
  border: 1px solid var(--fh-outline);
  background: var(--fh-surface-low);
  border-radius: var(--fh-radius);
  overflow: hidden;
}
.locator__head {
  background: var(--fh-cream);
  border-bottom: 1px solid var(--fh-outline);
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.locator__head h2 {
  font-size: 24px;
  color: var(--fh-text);
}
.locator__body {
  padding: var(--fh-gutter);
  display: flex;
  gap: var(--fh-gutter);
}
.locator__search { flex: 1; }
.locator__results {
  flex: 2;
  border-left: 1px solid var(--fh-outline);
  padding-left: var(--fh-gutter);
}
.locator__results h3 {
  font-family: 'Cabin', sans-serif;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--fh-text-muted);
  margin-bottom: 16px;
}

/* === Form Elements === */
input[type="text"],
input[type="email"],
input[type="search"],
select,
textarea {
  width: 100%;
  border: 1px solid var(--fh-border);
  background: var(--fh-white);
  border-radius: var(--fh-radius);
  padding: 10px 12px;
  font-family: 'Cabin', sans-serif;
  font-size: 16px;
  color: var(--fh-text);
  transition: border-color 0.2s;
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--fh-forest);
}
label {
  font-family: 'Cabin', sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: var(--fh-forest);
  display: block;
  margin-bottom: 4px;
}

/* === Location Card === */
.loc-card {
  border: 1px solid var(--fh-outline);
  background: var(--fh-white);
  padding: 16px;
  border-radius: var(--fh-radius);
  display: flex;
  gap: 12px;
  transition: border-color 0.2s;
  cursor: pointer;
}
.loc-card:hover { border-color: var(--fh-forest); }
.loc-card h4 {
  font-family: 'Cabin', sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: var(--fh-forest);
  margin-bottom: 4px;
}
.loc-card p { font-size: 14px; color: var(--fh-text-muted); margin: 0; }
.loc-card .badge {
  display: inline-block;
  margin-top: 8px;
  font-size: 12px;
  font-weight: 600;
  background: var(--fh-surface-high);
  color: var(--fh-orange-bright);
  padding: 2px 8px;
  border-radius: var(--fh-radius);
}

/* === Footer === */
.colophon {
  background: var(--fh-cream-warm);
  border-top: 1px solid var(--fh-border);
  margin-top: auto;
}
.colophon__inner {
  max-width: var(--fh-container);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  padding: 48px var(--fh-gutter);
}
.colophon__brand {
  font-family: 'Newsreader', Georgia, serif;
  font-size: 18px;
  font-weight: 700;
  color: var(--fh-forest);
  margin-bottom: 16px;
}
.colophon__legal {
  font-size: 14px;
  color: #6b6b60;
  line-height: 1.5;
}
.colophon__links {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}
.colophon__links a {
  font-size: 14px;
  color: #6b6b60;
  transition: color 0.2s;
}
.colophon__links a:hover { text-decoration: underline; color: var(--fh-forest); }

/* === Responsive === */
@media (max-width: 768px) {
  h1 { font-size: 32px; }
  h2 { font-size: 28px; }

  .top-nav, .brand-bar__actions .btn--ghost { display: none; }
  .mobile-toggle { display: block; }

  .hero { flex-direction: column; }
  .hero__content { padding: 32px; }
  .hero__image { min-height: 200px; border-left: none; border-top: 1px solid var(--fh-outline); }

  .grid-3 { grid-template-columns: 1fr; }
  .grid-2 { grid-template-columns: 1fr; }

  .contact-grid { grid-template-columns: 1fr; }
  .history-grid { grid-template-columns: 1fr; }
  .board-grid { grid-template-columns: repeat(2, 1fr); }

  .locator__body { flex-direction: column; }
  .locator__results { border-left: none; border-top: 1px solid var(--fh-outline); padding-left: 0; padding-top: var(--fh-gutter); }

  .blog-card--featured { flex-direction: column; }
  .blog-card--featured .blog-card__img { width: 100%; min-height: 200px; border-right: none; border-bottom: 1px solid var(--fh-border); }
  .blog-card--featured .card__body { width: 100%; }

  .colophon__inner { grid-template-columns: 1fr; gap: 24px; }
  .colophon__links { align-items: flex-start; }
}

/* === WordPress Specific === */
.alignleft { float: left; margin-right: 16px; margin-bottom: 16px; }
.alignright { float: right; margin-left: 16px; margin-bottom: 16px; }
.aligncenter { display: block; margin: 16px auto; }
.wp-caption { max-width: 100%; }
.wp-caption-text { font-size: 14px; color: var(--fh-text-muted); margin-top: 8px; }
.screen-reader-text {
  clip: rect(1px, 1px, 1px, 1px);
  position: absolute !important;
  height: 1px; width: 1px;
  overflow: hidden;
}

/* === Heroicons inline SVG sizing === */
.heroicon {
  width: 24px;
  height: 24px;
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}
.heroicon--sm { width: 20px; height: 20px; }
.heroicon--lg { width: 32px; height: 32px; }
.heroicon--terra { color: var(--fh-terracotta); }
.heroicon--forest { color: var(--fh-forest); }

/* === Cornerstone Page: Resource Hero === */
.resource-hero {
  text-align: center;
  margin-bottom: 48px;
}
.resource-hero h1 {
  margin: 12px 0 16px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}
.resource-hero__lead {
  font-size: 18px;
  line-height: 1.6;
  color: var(--fh-text-muted);
  max-width: 760px;
  margin: 0 auto;
}

/* === Crisis Strip === */
.crisis-strip {
  background: var(--fh-forest-deep);
  border-radius: var(--fh-radius);
  margin-bottom: 48px;
}
.crisis-strip__inner {
  display: flex;
  justify-content: space-around;
  padding: 16px 24px;
  flex-wrap: wrap;
  gap: 12px;
}
.crisis-strip__item {
  text-align: center;
  color: var(--fh-white);
}
.crisis-strip__item strong {
  display: block;
  font-family: 'Cabin', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fh-mint-light);
  margin-bottom: 2px;
}
.crisis-strip__item span {
  font-family: 'Newsreader', Georgia, serif;
  font-size: 20px;
  font-weight: 600;
  color: var(--fh-white);
}

/* === Stat Row === */
.stat-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--fh-gutter);
  margin-bottom: 48px;
}
.stat-card {
  border: 1px solid var(--fh-border);
  border-radius: var(--fh-radius);
  background: var(--fh-white);
  padding: 24px;
  text-align: center;
}
.stat-card__value {
  font-family: 'Newsreader', Georgia, serif;
  font-size: 36px;
  font-weight: 600;
  color: var(--fh-forest);
  line-height: 1.1;
  margin-bottom: 4px;
}
.stat-card__label {
  font-family: 'Cabin', sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: var(--fh-text);
  margin-bottom: 2px;
}
.stat-card__note {
  font-size: 13px;
  color: var(--fh-text-muted);
}

/* === Chart Section === */
.chart-section {
  border: 1px solid var(--fh-border);
  border-radius: var(--fh-radius);
  background: var(--fh-white);
  padding: 32px;
  margin-bottom: 48px;
}
.chart-section h3 {
  margin-bottom: 4px;
}
.chart-section__note {
  font-size: 14px;
  color: var(--fh-text-muted);
  margin-bottom: 24px;
}
.chart-wrap {
  position: relative;
  height: 420px;
}
.chart-wrap--half {
  max-width: 500px;
  margin: 0 auto;
  height: 350px;
}

/* === Data Table === */
.data-table-wrap {
  overflow-x: auto;
  margin-bottom: 48px;
  border: 1px solid var(--fh-border);
  border-radius: var(--fh-radius);
}
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-family: 'Cabin', sans-serif;
  font-size: 15px;
}
.data-table th {
  background: var(--fh-surface);
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--fh-forest);
  padding: 12px 16px;
  text-align: left;
  border-bottom: 2px solid var(--fh-border);
}
.data-table td {
  padding: 10px 16px;
  border-bottom: 1px solid var(--fh-surface-high);
  color: var(--fh-text);
}
.data-table tbody tr:hover {
  background: var(--fh-surface-low);
}

/* === Directory Controls === */
.directory-controls {
  background: var(--fh-surface-low);
  border: 1px solid var(--fh-border);
  border-radius: var(--fh-radius);
  padding: 24px;
  margin-bottom: 16px;
}
.directory-search {
  margin-bottom: 16px;
}
.directory-search input {
  font-size: 16px;
  padding: 12px 16px;
}
.directory-filters {
  margin-top: 12px;
}
.filter-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}
.filter-btn {
  font-family: 'Cabin', sans-serif;
  font-size: 13px;
  font-weight: 600;
  background: var(--fh-white);
  border: 1px solid var(--fh-border);
  border-radius: var(--fh-radius);
  padding: 6px 14px;
  cursor: pointer;
  transition: border-color 0.2s, background-color 0.2s;
  color: var(--fh-text-muted);
}
.filter-btn:hover {
  border-color: var(--fh-forest);
  color: var(--fh-forest);
}
.filter-btn.is-active {
  background: var(--fh-forest);
  color: var(--fh-white);
  border-color: var(--fh-forest);
}

/* === Directory Meta === */
.directory-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: 'Cabin', sans-serif;
  font-size: 14px;
  color: var(--fh-text-muted);
  margin-bottom: 24px;
  padding: 8px 0;
}
.directory-meta__sort {
  font-size: 13px;
}

/* === Nonprofit Cards === */
.np-directory {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.np-card {
  border: 1px solid var(--fh-border);
  border-radius: var(--fh-radius);
  background: var(--fh-white);
  overflow: hidden;
  transition: border-color 0.2s;
}
.np-card:hover {
  border-color: var(--fh-forest);
}
.np-card__header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 20px 24px 12px;
  border-bottom: 1px solid var(--fh-surface-high);
}
.np-card__name {
  font-family: 'Newsreader', Georgia, serif;
  font-size: 20px;
  font-weight: 500;
  color: var(--fh-forest);
  margin-bottom: 4px;
}
.np-card__category {
  font-size: 13px;
  font-weight: 600;
  color: var(--fh-terracotta);
}
.np-card__revenue {
  text-align: right;
  font-family: 'Newsreader', Georgia, serif;
  font-size: 24px;
  font-weight: 600;
  color: var(--fh-forest);
  white-space: nowrap;
}
.np-card__revenue span {
  display: block;
  font-family: 'Cabin', sans-serif;
  font-size: 12px;
  font-weight: 600;
  color: var(--fh-text-muted);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.np-card__details {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  padding: 12px 24px;
}
.np-card__detail {
  font-size: 14px;
  color: var(--fh-text-muted);
  line-height: 1.4;
}
.np-card__detail strong {
  display: block;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--fh-text);
  margin-bottom: 2px;
}
.np-card__footer {
  padding: 8px 24px 16px;
}
.np-card__link {
  font-size: 14px;
  font-weight: 600;
  color: var(--fh-terracotta);
}
.np-card__link:hover {
  text-decoration: underline;
}
.np-empty {
  text-align: center;
  padding: 48px;
  color: var(--fh-text-muted);
  font-size: 16px;
  border: 1px dashed var(--fh-border);
  border-radius: var(--fh-radius);
}

/* === Service Cards === */
.svc-directory {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.svc-category-heading {
  margin-top: 24px;
  margin-bottom: 4px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--fh-forest);
  font-size: 20px;
}
.svc-card {
  display: grid;
  grid-template-columns: 3fr 2fr;
  border: 1px solid var(--fh-border);
  border-radius: var(--fh-radius);
  background: var(--fh-white);
  overflow: hidden;
  transition: border-color 0.2s;
}
.svc-card:hover {
  border-color: var(--fh-forest);
}
.svc-card__main {
  padding: 20px 24px;
}
.svc-card__name {
  font-family: 'Newsreader', Georgia, serif;
  font-size: 18px;
  font-weight: 500;
  color: var(--fh-forest);
  margin-bottom: 8px;
}
.svc-card__desc {
  font-size: 15px;
  color: var(--fh-text-muted);
  line-height: 1.5;
  margin-bottom: 8px;
}
.svc-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.svc-tag {
  font-size: 12px;
  font-weight: 600;
  background: var(--fh-surface);
  color: var(--fh-forest);
  padding: 2px 10px;
  border-radius: var(--fh-radius);
}
.svc-card__contact {
  background: var(--fh-surface-low);
  padding: 20px 24px;
  border-left: 1px solid var(--fh-surface-high);
  display: flex;
  flex-direction: column;
  gap: 8px;
  justify-content: center;
}
.svc-card__detail {
  font-size: 14px;
  color: var(--fh-text-muted);
  line-height: 1.4;
}
.svc-card__detail strong {
  display: block;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--fh-text);
  margin-bottom: 1px;
}
.svc-card__detail a {
  color: var(--fh-forest);
  font-weight: 600;
}
.svc-card__web {
  font-size: 14px;
  font-weight: 600;
  color: var(--fh-terracotta);
  margin-top: 4px;
}
.svc-card__web:hover {
  text-decoration: underline;
}

/* === Data Attribution === */
.data-attribution {
  background: var(--fh-surface-low);
  border: 1px solid var(--fh-border);
  border-radius: var(--fh-radius);
  padding: 24px 32px;
}
.data-attribution h3 {
  font-size: 16px;
  margin-bottom: 8px;
}
.data-attribution p {
  font-size: 14px;
  color: var(--fh-text-muted);
  line-height: 1.6;
}

/* === Subtopic Grid === */
.subtopic-grid .card__body h3 {
  font-size: 20px;
}

/* === Cornerstone Responsive === */
@media (max-width: 768px) {
  .stat-row { grid-template-columns: repeat(2, 1fr); }
  .np-card__header { flex-direction: column; gap: 8px; }
  .np-card__revenue { text-align: left; }
  .np-card__details { grid-template-columns: repeat(2, 1fr); }
  .svc-card { grid-template-columns: 1fr; }
  .svc-card__contact { border-left: none; border-top: 1px solid var(--fh-surface-high); }
  .crisis-strip__inner { flex-direction: column; align-items: center; }
  .chart-wrap { height: 300px; }
  .chart-wrap--half { height: 280px; }
  .subtopic-grid { grid-template-columns: 1fr !important; }
}
