/* SermonWave church directory hubs: /churches/ landing, /churches/{state}/, /churches/{city}-{st}/.
   Mobile first. Builds on style.css tokens + seo-pages.css + church-directory.css (search form, badges).
   Every box that loads late (map) has a fixed height: no layout shift. */

.hub-page { background: var(--bg-white); }
.hub-hero { padding-bottom: var(--space-xl); }
.hub-hero .seo-breadcrumbs { margin-bottom: var(--space-md); }
.hub-eyebrow {
    font-family: var(--font-heading); font-weight: 700; font-size: 0.78rem; letter-spacing: 0.12em; text-transform: uppercase;
    color: var(--aqua); margin: 0 0 var(--space-sm);
}
.hub-hero .seo-hero__subtitle { color: var(--text-white-80, rgba(255,255,255,0.8)); max-width: 680px; }
.hub-chips { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: var(--space-md) 0 0; }
.hub-chip {
    font-family: var(--font-heading); font-size: 0.8rem; font-weight: 600; color: #fff; padding: 5px 12px;
    border: 1px solid rgba(255,255,255,0.22); border-radius: 999px; background: rgba(255,255,255,0.06);
}
.hub-chip--hi { background: var(--aqua); border-color: var(--aqua); color: var(--navy); }
.hub-hero__ctas { margin: var(--space-md) 0 0; }
.hub-search { margin-top: var(--space-md); }

/* headings */
.hub-h2 {
    font-family: var(--font-heading); font-weight: 800; color: var(--navy); font-size: clamp(1.3rem, 3vw, 1.75rem);
    line-height: 1.2; margin: 0 0 var(--space-sm); letter-spacing: -0.01em;
}
.seo-section--dark .hub-h2 { color: #fff; }
.hub-h3 { font-family: var(--font-heading); font-weight: 700; color: var(--navy); font-size: 1.02rem; margin: 0 0 var(--space-sm); line-height: 1.3; }
.hub-sub { color: var(--text-muted); margin: 0 0 var(--space-lg); max-width: var(--max-narrow); }
.hub-sub a { color: var(--blue); font-family: var(--font-heading); font-weight: 600; }

/* intro + stats */
.hub-intro-section { padding-top: var(--space-xl); padding-bottom: var(--space-xl); }
.hub-intro { max-width: var(--max-narrow); }
.hub-intro__p { font-size: 1.05rem; line-height: 1.75; color: var(--text-body); margin: 0 0 var(--space-lg); }
.hub-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-sm); margin: 0 0 var(--space-lg); }
.hub-stats__item {
    background: var(--bg-cool); border-radius: var(--radius-md); padding: var(--space-md); display: flex; flex-direction: column-reverse; gap: 2px;
}
.hub-stats dt { font-size: 0.82rem; color: var(--text-muted); font-family: var(--font-heading); font-weight: 600; }
.hub-stats dd { margin: 0; font-family: var(--font-heading); font-weight: 800; font-size: 1.6rem; color: var(--navy); line-height: 1.1; }
@media (min-width: 640px) { .hub-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 960px) { .hub-stats { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); } }

/* filters */
.hub-filters {
    display: grid; grid-template-columns: 1fr; gap: var(--space-sm); background: var(--bg-cool); border: 1px solid var(--border-light);
    border-radius: var(--radius-lg); padding: var(--space-md); margin: var(--space-md) 0 var(--space-lg);
}
.hub-filters__field span { display: block; font-family: var(--font-heading); font-weight: 600; font-size: 0.8rem; color: var(--text-muted); margin-bottom: 4px; }
.hub-filters select {
    width: 100%; min-height: 44px; padding: 0 var(--space-sm); border-radius: var(--radius-md); border: 1px solid var(--border-light);
    font: inherit; font-size: 0.95rem; background: #fff; color: var(--text-dark);
}
.hub-filters__checks { display: flex; flex-wrap: wrap; gap: 4px 16px; align-items: center; }
.hub-check { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; font-size: 0.95rem; cursor: pointer; }
.hub-check input { width: 18px; height: 18px; accent-color: var(--blue); }
.hub-filters__actions { display: flex; align-items: center; gap: var(--space-md); }
.hub-filters__apply[hidden] { display: none; }
.hub-filters__clear { font-family: var(--font-heading); font-weight: 600; font-size: 0.9rem; color: var(--rose-dark); }
@media (min-width: 760px) {
    .hub-filters { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: end; }
    .hub-filters__checks, .hub-filters__actions { grid-column: 1 / -1; }
}
@media (min-width: 1100px) {
    .hub-filters { grid-template-columns: 220px 220px minmax(0, 1fr) auto; }
    .hub-filters__checks, .hub-filters__actions { grid-column: auto; }
}

/* list + map */
.hub-split { display: grid; grid-template-columns: 1fr; gap: var(--space-lg); }
.hub-map { height: 260px; border-radius: var(--radius-lg); border: 1px solid var(--border-light); background: var(--bg-cool); z-index: 0; }
.hub-map__legend { font-size: 0.82rem; color: var(--text-muted); margin: 6px 0 0; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.hub-dot { display: inline-block; width: 11px; height: 11px; border-radius: 50%; background: #1244C4; border: 2px solid var(--navy); margin-left: 6px; }
.hub-dot--sermons { background: #00BCD4; margin-left: 0; }
@media (min-width: 960px) {
    .hub-split { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); align-items: start; }
    .hub-split__map { order: 2; position: sticky; top: calc(var(--header-height) + 16px); }
    .hub-split__list { order: 1; }
    .hub-map { height: calc(100vh - var(--header-height) - 72px); max-height: 640px; min-height: 380px; }
}
.hub-count { font-family: var(--font-heading); font-weight: 700; color: var(--text-dark); margin: 0 0 var(--space-sm); }
.hub-cards { display: grid; gap: var(--space-sm); }

.hub-card {
    background: #fff; border: 1px solid var(--border-light); border-radius: var(--radius-md); padding: var(--space-md);
    box-shadow: var(--shadow-sm); transition: border-color 0.2s, box-shadow 0.2s;
}
.hub-card:hover { border-color: #c9d3e3; box-shadow: var(--shadow-md); }
.hub-card--active { border-color: var(--aqua); box-shadow: 0 0 0 3px var(--aqua-soft); }
.hub-card__name { font-family: var(--font-heading); font-size: 1.08rem; font-weight: 700; margin: 0; line-height: 1.3; }
.hub-card__name a { color: var(--navy); text-decoration: none; }
.hub-card__name a:hover { color: var(--blue); text-decoration: underline; }
.hub-card__denom { margin: 2px 0 0; font-family: var(--font-heading); font-size: 0.8rem; font-weight: 600; color: var(--blue); }
.hub-card__addr { margin: var(--space-xs) 0 0; color: var(--text-muted); font-size: 0.92rem; }
.hub-card__times { margin: var(--space-sm) 0 0; font-size: 0.93rem; color: var(--text-body); }
.hub-card__times--none { color: var(--text-muted); font-style: italic; font-size: 0.88rem; }
.hub-card__label { font-family: var(--font-heading); font-weight: 700; font-size: 0.78rem; color: var(--text-dark); text-transform: uppercase; letter-spacing: 0.04em; margin-right: 4px; }
.hub-week { display: flex; gap: 4px; margin-top: 6px; }
.hub-week__d {
    width: 30px; height: 24px; display: inline-flex; align-items: center; justify-content: center; border-radius: 6px;
    font-family: var(--font-heading); font-size: 0.7rem; font-weight: 700; background: var(--bg-cool); color: #9AA3B2;
}
.hub-week__d.is-on { background: var(--navy); color: #fff; }
.hub-card__links { display: flex; flex-wrap: wrap; gap: 6px 14px; margin: var(--space-sm) 0 0; padding-top: var(--space-sm); border-top: 1px solid var(--border-light); }
.hub-card__links a { font-family: var(--font-heading); font-weight: 600; font-size: 0.86rem; color: var(--blue); text-decoration: none; min-height: 28px; display: inline-flex; align-items: center; }
.hub-card__links a:hover { text-decoration: underline; }
.hub-card__more { margin-left: auto; color: var(--navy) !important; }
.hub-card__more::after { content: ' \203A'; }
.hub-pagination { flex-wrap: wrap; margin-top: var(--space-lg); }

/* services by day */
.hub-byday { display: grid; grid-template-columns: 1fr; gap: var(--space-md); }
@media (min-width: 760px) { .hub-byday { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .hub-byday { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); } }
.hub-byday__col { background: #fff; border-radius: var(--radius-md); padding: var(--space-md); border: 1px solid var(--border-light); }
.hub-byday__list { list-style: none; margin: 0; padding: 0; }
.hub-byday__list li { padding: 6px 0; border-bottom: 1px dashed var(--border-light); font-size: 0.93rem; display: flex; justify-content: space-between; gap: var(--space-sm); }
.hub-byday__list li:last-child { border-bottom: 0; }
.hub-byday__list a { color: var(--navy); text-decoration: none; }
.hub-byday__list a:hover { color: var(--blue); text-decoration: underline; }
.hub-byday__t { flex-shrink: 0; color: var(--text-muted); font-family: var(--font-heading); font-size: 0.8rem; font-weight: 600; white-space: nowrap; }
.hub-more { display: inline-block; margin-top: var(--space-sm); font-family: var(--font-heading); font-weight: 600; font-size: 0.88rem; color: var(--blue); }

/* raw data tables: real table on wide screens, stacked label/value blocks on phones */
.hub-table-wrap { margin: 0 0 var(--space-xl); }
.hub-table { width: 100%; border-collapse: collapse; font-size: 0.88rem; background: #fff; }
.hub-table caption { text-align: left; font-family: var(--font-heading); font-weight: 700; color: var(--text-dark); padding: 0 0 var(--space-sm); caption-side: top; }
.hub-table th, .hub-table td { text-align: left; vertical-align: top; padding: 8px 10px; border-bottom: 1px solid var(--border-light); }
.hub-table thead th { font-family: var(--font-heading); font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.04em; color: var(--text-muted); background: var(--bg-cool); }
.hub-table tbody th { font-family: var(--font-heading); font-weight: 700; }
.hub-table a { color: var(--blue); text-decoration: none; word-break: break-word; }
.hub-table a:hover { text-decoration: underline; }
.hub-table .is-empty { color: #B0B7C3; }
@media (max-width: 899px) {
    .hub-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
    .hub-table, .hub-table tbody, .hub-table tr, .hub-table th, .hub-table td { display: block; width: 100%; }
    .hub-table caption { display: block; }
    .hub-table tr { border: 1px solid var(--border-light); border-radius: var(--radius-md); margin-bottom: var(--space-sm); padding: 6px 0; }
    .hub-table th, .hub-table td { border-bottom: 0; padding: 4px 12px; display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 8px; }
    .hub-table th::before, .hub-table td::before { content: attr(data-label); font-family: var(--font-heading); font-size: 0.72rem; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.03em; padding-top: 2px; }
    .hub-table td.is-empty { display: none; }
    .hub-table--num tr { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .hub-table--num th { grid-column: 1 / -1; }
    .hub-table--num th, .hub-table--num td { grid-template-columns: 1fr; gap: 0; }
}
@media (min-width: 900px) {
    .hub-table--num td { text-align: right; font-variant-numeric: tabular-nums; }
    .hub-table--num thead th:not(:first-child) { text-align: right; }
}

/* city grids */
.hub-citygrid { list-style: none; padding: 0; margin: 0 0 var(--space-md); display: grid; gap: 8px; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
.hub-cityitem {
    display: flex; flex-direction: column; gap: 2px; background: #fff; border: 1px solid var(--border-light); border-radius: var(--radius-md);
    padding: 12px 14px; text-decoration: none; transition: border-color 0.2s, transform 0.2s;
}
.hub-cityitem:hover { border-color: var(--blue); transform: translateY(-1px); }
.hub-cityitem__n { font-family: var(--font-heading); font-weight: 700; color: var(--navy); }
.hub-cityitem__c { font-size: 0.84rem; color: var(--text-muted); }
.hub-citygrid--big { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.hub-citygrid--big .hub-cityitem { padding: 16px 18px; border-left: 4px solid var(--aqua); }
.hub-statelinks { display: flex; flex-wrap: wrap; gap: 8px 18px; }

/* states */
.hub-states { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.hub-state {
    display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; background: #fff; border: 1px solid var(--border-light);
    border-radius: var(--radius-md); padding: 16px 18px; text-decoration: none; transition: border-color 0.2s;
}
.hub-state:hover { border-color: var(--blue); }
.hub-state__name { font-family: var(--font-heading); font-weight: 800; font-size: 1.1rem; color: var(--navy); }
.hub-state__n { font-family: var(--font-heading); font-weight: 700; color: var(--blue); text-align: right; }
.hub-state__c { grid-column: 1 / -1; font-size: 0.85rem; color: var(--text-muted); }

/* featured sermon churches */
.hub-featured { display: grid; gap: var(--space-md); grid-template-columns: 1fr; }
@media (min-width: 640px) { .hub-featured { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1000px) { .hub-featured { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.hub-feat {
    background: #fff; border-radius: var(--radius-lg); padding: var(--space-lg); border: 1px solid var(--border-light);
    box-shadow: var(--shadow-sm); display: flex; flex-direction: column; gap: 6px; border-top: 4px solid var(--aqua);
}
.hub-feat__place { margin: 0; font-family: var(--font-heading); font-weight: 600; font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-muted); }
.hub-feat__name { margin: 0; font-family: var(--font-heading); font-size: 1.1rem; font-weight: 800; line-height: 1.25; }
.hub-feat__name a { color: var(--navy); text-decoration: none; }
.hub-feat__name a:hover { color: var(--blue); text-decoration: underline; }
.hub-feat__sermon { margin: 0; font-size: 0.95rem; }
.hub-feat__sermon a { color: var(--text-dark); }
.hub-feat__label { display: block; font-family: var(--font-heading); font-weight: 700; font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.05em; color: #00707F; }
.hub-feat__meta { margin: 0; font-size: 0.84rem; color: var(--text-muted); }
.hub-feat__cta {
    margin-top: auto; align-self: flex-start; font-family: var(--font-heading); font-weight: 700; font-size: 0.88rem; color: #fff;
    background: var(--blue); border-radius: 999px; padding: 8px 16px; text-decoration: none;
}
.hub-feat__cta::before { content: '\25B6\00A0'; font-size: 0.75em; }
.hub-feat__cta:hover { background: var(--navy); }

/* denominations */
.hub-denoms { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.hub-denom { background: #fff; border: 1px solid var(--border-light); border-radius: var(--radius-md); padding: 14px 16px; }
.hub-denom__head { display: flex; justify-content: space-between; gap: 10px; margin: 0; align-items: baseline; }
.hub-denom__name { font-family: var(--font-heading); font-weight: 700; color: var(--navy); }
.hub-denom__n { font-family: var(--font-heading); font-weight: 800; color: var(--blue); font-variant-numeric: tabular-nums; }
.hub-denom__cities { margin: 6px 0 0; font-size: 0.84rem; display: flex; flex-wrap: wrap; gap: 4px 12px; }
.hub-denom__cities a { color: var(--text-muted); text-decoration: none; }
.hub-denom__cities a:hover { color: var(--blue); text-decoration: underline; }

/* A-Z */
.hub-az-nav { display: flex; flex-wrap: wrap; gap: 4px; margin: 0 0 var(--space-md); }
.hub-az-nav a {
    width: 34px; height: 34px; display: inline-flex; align-items: center; justify-content: center; border-radius: var(--radius-sm);
    background: var(--bg-cool); color: var(--navy); font-family: var(--font-heading); font-weight: 700; text-decoration: none; font-size: 0.85rem;
}
.hub-az-nav a:hover { background: var(--navy); color: #fff; }
.hub-az { columns: 1; column-gap: var(--space-xl); }
@media (min-width: 640px) { .hub-az { columns: 2; } }
@media (min-width: 960px) { .hub-az { columns: 4; } }
.hub-az__group { break-inside: avoid; margin-bottom: var(--space-md); scroll-margin-top: calc(var(--header-height) + 16px); }
.hub-az__letter { font-family: var(--font-heading); font-weight: 800; color: var(--aqua); margin: 0 0 4px; font-size: 1.1rem; }
.hub-az__list { list-style: none; margin: 0; padding: 0; }
.hub-az__list li { display: flex; justify-content: space-between; gap: 8px; padding: 3px 0; font-size: 0.93rem; }
.hub-az__list a { color: var(--navy); text-decoration: none; }
.hub-az__list a:hover { color: var(--blue); text-decoration: underline; }
.hub-az__list span { color: var(--text-muted); font-variant-numeric: tabular-nums; }

/* FAQ */
.hub-faq { max-width: var(--max-narrow); }
.hub-faq__item { border-bottom: 1px solid var(--border-light); }
.hub-faq__item:first-child { border-top: 1px solid var(--border-light); }
.hub-faq__item summary {
    cursor: pointer; list-style: none; padding: var(--space-md) 32px var(--space-md) 0; position: relative;
    font-family: var(--font-heading); font-weight: 700; color: var(--text-dark); line-height: 1.4;
}
.hub-faq__item summary::-webkit-details-marker { display: none; }
.hub-faq__item summary::after { content: '+'; position: absolute; right: 4px; top: 50%; transform: translateY(-50%); font-size: 1.4rem; color: var(--text-muted); font-weight: 400; }
.hub-faq__item[open] summary::after { content: '\2212'; color: var(--blue); }
.hub-faq__item summary:hover { color: var(--blue); }
.hub-faq__item p { margin: 0 0 var(--space-md); color: var(--text-body); line-height: 1.75; }
.hub-listing-note { max-width: var(--max-narrow); }

.hub-cta { text-align: center; }
.hub-cta .seo-section__title { color: #fff; }
.hub-cta p { color: var(--text-white-80, rgba(255,255,255,0.8)); max-width: 640px; margin: 0 auto var(--space-md); }
.hub-cta .seo-cta-group { justify-content: center; }
.dir-search__geo-msg--error { color: #FFC2CB; font-weight: 600; }
.dir-search__geo[aria-busy="true"] { opacity: 0.75; cursor: progress; }

/* church graphics on hub cards + featured (church_logo.php; base .sw-cg rules in church-directory.css) */
.hub-card__top { display: flex; gap: var(--space-sm); align-items: center; }
.hub-card__g, .hub-feat__g { flex-shrink: 0; line-height: 0; }
.hub-card__g .sw-cg { width: 56px; height: 56px; }
.hub-card__title { min-width: 0; }
.hub-feat__head { display: flex; gap: var(--space-sm); align-items: center; }
.hub-feat__g .sw-cg { width: 64px; height: 64px; }
