/* =================================================================
   KINGDOM HUB HOME — Homepage Styles
   Design system: mirrors Vani theme overrides
   Fonts: DM Sans (body) · Cormorant Garamond (headings)
   Palette: warm ivory bg · crimson #c0392b · near-black text
   ================================================================= */

/* ---------------------------------------------------------------
   VARIABLES
--------------------------------------------------------------- */
:root {
  --khh-bg:           #fafaf8;
  --khh-surface:      #f5f3ef;
  --khh-border:       #e6e2d8;
  --khh-border-hover: rgba(192, 57, 43, 0.45);
  --khh-text:         #1a1918;
  --khh-muted:        rgba(26, 25, 24, 0.50);
  --khh-muted-2:      rgba(26, 25, 24, 0.30);
  --khh-primary:      #c0392b;
  --khh-primary-dim:  rgba(192, 57, 43, 0.10);
  --khh-font-sans:    'DM Sans', system-ui, -apple-system, sans-serif;
  --khh-font-serif:   'Cormorant Garamond', Georgia, serif;
  --khh-transition:   0.28s cubic-bezier(0.16, 1, 0.3, 1);
  --khh-max:          1100px;
}

/* ---------------------------------------------------------------
   PAGE WRAPPER
--------------------------------------------------------------- */
.khh-page {
  background: transparent;
  font-family: var(--khh-font-sans);
  -webkit-font-smoothing: antialiased;
  color: var(--khh-text);
}

/* ---------------------------------------------------------------
   HERO — two-column grid: text + stats left, network map right
--------------------------------------------------------------- */
.khh-hero {
  max-width: var(--khh-max);
  margin: 0 auto;
  padding: 0 0 3.5rem;
  display: grid;
  grid-template-columns: 1fr 0.65fr;
  gap: 3.5rem;
  align-items: start;
  justify-items: stretch;
}

.khh-hero-left {
  min-width: 0;
}

.khh-hero-inner {
  margin-bottom: 2rem;
}

.khh-eyebrow {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--khh-primary);
  margin: 0 0 1.25rem;
}

.khh-hero-title {
  font-family: var(--khh-font-serif);
  font-size: clamp(2.5rem, 4.5vw, 4.5rem);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: var(--khh-text);
  margin: 0 0 1.5rem;
}

.khh-hero-accent {
  color: var(--khh-primary);
}

.khh-hero-sub {
  font-size: 1rem;
  line-height: 1.75;
  color: var(--khh-muted);
  margin: 0;
}

/* ---------------------------------------------------------------
   MAP VISUAL (hero right column)
--------------------------------------------------------------- */
.khh-hero-right {
  min-width: 0;
}

.khh-map-wrap {
  display: flex;
  flex-direction: column;
  margin-left: auto;
  width: 100%;
}

.khh-map-header {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: space-between !important;
  margin-bottom: 0.6rem;
}

.khh-map-label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--khh-muted);
}

.khh-map-link {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--khh-primary);
  text-decoration: none;
  transition: opacity var(--khh-transition);
}

.khh-map-link:hover {
  opacity: 0.7;
  text-decoration: none;
}

.khh-map-visual {
  background: var(--khh-surface);
  border: 1px solid var(--khh-border);
  border-radius: 4px;
  overflow: hidden;
  line-height: 0;
}

.khh-map-visual svg {
  width: 100%;
  height: auto;
  display: block;
}

.khh-map-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1rem;
  margin-top: 0.7rem;
}

.khh-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.65rem;
  font-weight: 500;
  color: var(--khh-muted);
}

.khh-legend-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
  display: inline-block;
}

/* ---------------------------------------------------------------
   STAT BAR
--------------------------------------------------------------- */
.khh-stat-bar {
  display: flex !important;
  align-items: center !important;
  flex-wrap: nowrap;
  gap: 0;
  background: var(--khh-surface);
  border: 1px solid var(--khh-border);
  border-radius: 4px;
  overflow: hidden;
}

.khh-stat {
  flex: 1 1 0;
  min-width: 0;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  padding: 1rem 0.5rem;
}

.khh-stat-divider {
  width: 1px;
  height: 2.5rem;
  background: var(--khh-border);
  flex-shrink: 0;
}

.khh-stat-number {
  font-family: var(--khh-font-serif);
  font-size: 2.25rem;
  font-weight: 600;
  line-height: 1;
  color: var(--khh-text);
  letter-spacing: -0.02em;
}

.khh-stat-label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--khh-muted);
  margin-top: 0.3rem;
}

/* ---------------------------------------------------------------
   SECTION LABEL (reusable eyebrow above sections)
--------------------------------------------------------------- */
.khh-section-label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--khh-muted);
  margin: 0 0 1.25rem;
}

/* ---------------------------------------------------------------
   ACTION CARDS
--------------------------------------------------------------- */
.khh-cards-section {
  max-width: var(--khh-max);
  margin: 0 auto;
  padding: 3.5rem 1.5rem;
  border-top: 1px solid var(--khh-border);
}

.khh-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.khh-card {
  display: flex;
  flex-direction: column;
  background: var(--khh-surface);
  border: 1px solid var(--khh-border);
  border-radius: 4px;
  padding: 1.75rem 1.5rem 1.25rem;
  text-decoration: none;
  color: inherit;
  transition: border-color var(--khh-transition), background var(--khh-transition);
  position: relative;
  overflow: hidden;
}

.khh-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 100%;
  background: transparent;
  transition: background var(--khh-transition);
}

.khh-card:hover {
  border-color: var(--khh-border-hover);
  background: #f0ede8;
  text-decoration: none;
  color: inherit;
}

.khh-card:hover::before {
  background: var(--khh-primary);
}

/* Icon */
.khh-card-icon-wrap {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 2px;
  background: var(--khh-primary-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
  flex-shrink: 0;
}

.khh-card-icon {
  width: 1.1rem;
  height: 1.1rem;
  color: var(--khh-primary);
}

/* Body */
.khh-card-body {
  flex: 1;
}

.khh-card-eyebrow {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--khh-primary);
  margin: 0 0 0.4rem;
}

.khh-card-title {
  font-family: var(--khh-font-serif);
  font-size: 1.5rem;
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--khh-text);
  margin: 0 0 0.65rem;
}

.khh-card-desc {
  font-size: 0.85rem;
  line-height: 1.65;
  color: var(--khh-muted);
  margin: 0;
}

/* Footer */
.khh-card-footer {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--khh-border);
}

.khh-card-cta {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--khh-muted);
  transition: color var(--khh-transition);
}

.khh-card-arrow {
  width: 0.9rem;
  height: 0.9rem;
  color: var(--khh-muted-2);
  transition: color var(--khh-transition), transform var(--khh-transition);
  flex-shrink: 0;
}

.khh-card:hover .khh-card-cta,
.khh-card:hover .khh-card-arrow {
  color: var(--khh-primary);
}

.khh-card:hover .khh-card-arrow {
  transform: translateX(3px);
}

/* Pentecost card — slightly elevated treatment */
.khh-card--event {
  background: #f5f3ef;
}

.khh-card--event .khh-card-icon-wrap {
  background: var(--khh-primary);
}

.khh-card--event .khh-card-icon {
  color: #fff;
}

/* ---------------------------------------------------------------
   RECENTLY ADDED
--------------------------------------------------------------- */
.khh-recent {
  max-width: var(--khh-max);
  margin: 0 auto;
  padding: 3.5rem 1.5rem;
  border-top: 1px solid var(--khh-border);
}

.khh-recent-list {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--khh-border);
  border-radius: 4px;
  overflow: hidden;
}

.khh-recent-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.9rem 1.25rem;
  text-decoration: none;
  color: inherit;
  background: #fff;
  border-bottom: 1px solid var(--khh-border);
  transition: background var(--khh-transition);
}

.khh-recent-row:last-child {
  border-bottom: none;
}

.khh-recent-row:hover {
  background: var(--khh-surface);
  text-decoration: none;
  color: inherit;
}

.khh-recent-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--khh-primary);
  flex-shrink: 0;
}

.khh-recent-info {
  flex: 1;
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  min-width: 0;
}

.khh-recent-name {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--khh-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.khh-recent-scope {
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--khh-muted);
  flex-shrink: 0;
}

.khh-recent-focus {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
  flex-shrink: 0;
}

.khh-focus-pill {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.55rem;
  background: var(--khh-primary-dim);
  color: var(--khh-primary);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-radius: 2px;
}

.khh-recent-arrow {
  width: 0.85rem;
  height: 0.85rem;
  color: var(--khh-muted-2);
  flex-shrink: 0;
  transition: color var(--khh-transition), transform var(--khh-transition);
}

.khh-recent-row:hover .khh-recent-arrow {
  color: var(--khh-primary);
  transform: translateX(3px);
}

/* "View all" link */
.khh-recent-all {
  margin-top: 1.25rem;
  text-align: right;
}

.khh-all-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--khh-muted);
  text-decoration: none;
  transition: color var(--khh-transition);
}

.khh-all-link:hover {
  color: var(--khh-primary);
  text-decoration: none;
}

.khh-all-link svg {
  width: 0.85rem;
  height: 0.85rem;
}

/* ---------------------------------------------------------------
   MISSION STRIP
--------------------------------------------------------------- */
.khh-mission {
  background: var(--khh-primary);
  margin-top: 2rem;
}

.khh-mission-inner {
  max-width: var(--khh-max);
  margin: 0 auto;
  padding: 4rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
}

.khh-mission-quote {
  font-family: var(--khh-font-serif);
  font-size: clamp(1.1rem, 2.5vw, 1.4rem);
  font-weight: 400;
  font-style: italic;
  color: rgba(255, 255, 255, 0.90);
  line-height: 1.6;
  max-width: 640px;
  margin: 0;
}

.khh-mission-cta {
  display: inline-flex;
  align-items: center;
  padding: 0.7rem 1.6rem;
  background: #fff;
  color: var(--khh-primary);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 2px;
  white-space: nowrap;
  flex-shrink: 0;
  transition: background var(--khh-transition), color var(--khh-transition);
}

.khh-mission-cta:hover {
  background: #1a1918;
  color: #fff;
  text-decoration: none;
}

/* ---------------------------------------------------------------
   RESPONSIVE
--------------------------------------------------------------- */
@media (max-width: 900px) {
  .khh-hero {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  /* On tablet/mobile, map slides below the text */
  .khh-hero-right {
    order: 2;
  }

  .khh-cards {
    grid-template-columns: 1fr;
  }

  .khh-stat-divider {
    display: none;
  }

  .khh-stat-bar {
    flex-wrap: wrap;
  }

  .khh-stat {
    flex: 1 1 45%;
    border-bottom: 1px solid var(--khh-border);
  }

  .khh-stat:last-child,
  .khh-stat:nth-last-child(2):nth-child(odd) {
    border-bottom: none;
  }

  .khh-mission-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .khh-recent-focus {
    display: none;
  }
}

@media (max-width: 560px) {
  .khh-hero-title {
    font-size: 2.6rem;
  }

  .khh-stat {
    flex: 1 1 100%;
  }
}
