/* Act for the Poor Association (APA) — Kagadi District, Western Uganda
   Lightweight, mobile-first stylesheet */

:root {
  --bg: #f5f3ec;
  --surface: #ffffff;
  --surface-alt: #ebe7dc;
  --green: #1b4332;
  --green-dark: #122e22;
  --green-soft: #e3efe8;
  --amber: #b87314;
  --amber-dark: #92590c;
  --gold: #e09f3e;
  --ink: #1d231f;
  --muted: #505b54;
  --border: #dcd6c7;
  --radius: 14px;
  --shadow: 0 8px 24px rgba(27, 67, 50, 0.08);
  --maxw: 1120px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.65;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--green); text-decoration-thickness: 1.5px; text-underline-offset: 3px; }
a:hover { color: var(--amber); }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 20px;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(245, 243, 236, 0.96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 74px;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--ink);
}

.brand img { width: 46px; height: 46px; flex-shrink: 0; }

.brand-text strong {
  display: block;
  font-size: 1.04rem;
  color: var(--green);
  line-height: 1.15;
}

.brand-text span {
  display: block;
  font-size: 0.78rem;
  color: var(--muted);
}

.nav-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 8px 12px;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--green);
  cursor: pointer;
}

.nav-links {
  display: none;
  flex-direction: column;
  position: absolute;
  top: 74px;
  left: 0;
  right: 0;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 16px 20px 22px;
  gap: 12px;
  box-shadow: var(--shadow);
}

.nav-links.open { display: flex; }

.nav-links a {
  text-decoration: none;
  font-weight: 600;
  color: var(--ink);
  padding: 8px 10px;
  border-radius: 8px;
}

.nav-links a[aria-current="page"] {
  background: var(--green-soft);
  color: var(--green);
}

.nav-links a.nav-cta {
  background: var(--green);
  color: #fff;
  text-align: center;
  padding: 10px 16px;
}

.nav-links a.nav-cta:hover { background: var(--green-dark); color: #fff; }

@media (min-width: 820px) {
  .nav-toggle { display: none; }
  .nav-links {
    display: flex;
    position: static;
    flex-direction: row;
    align-items: center;
    background: transparent;
    border: 0;
    box-shadow: none;
    padding: 0;
    gap: 6px;
  }
  .nav-links a { padding: 8px 14px; font-size: 0.95rem; }
  .nav-links a.nav-cta { margin-left: 8px; }
}

/* Typography & Sections */
h1, h2, h3 {
  font-family: 'Fraunces', Georgia, 'Times New Roman', serif;
  color: var(--green-dark);
  line-height: 1.2;
  margin-top: 0;
}

h1 { font-size: clamp(1.9rem, 4vw, 2.85rem); margin-bottom: 16px; }
h2 { font-size: clamp(1.5rem, 3vw, 2.05rem); margin-bottom: 14px; }
h3 { font-size: 1.22rem; margin-bottom: 8px; }

.eyebrow {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--amber);
  margin-bottom: 10px;
}

.section { padding: 56px 0; }
.section-alt { background: var(--surface-alt); }
.section-white { background: var(--surface); }
.lead { font-size: 1.07rem; color: var(--muted); max-width: 65ch; }

/* Buttons */
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 22px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  border: 1.5px solid transparent;
  transition: background 0.18s ease, color 0.18s ease;
}

.btn-primary { background: var(--green); color: #fff; }
.btn-primary:hover { background: var(--green-dark); color: #fff; }
.btn-amber { background: var(--amber); color: #fff; }
.btn-amber:hover { background: var(--amber-dark); color: #fff; }
.btn-outline { background: transparent; color: var(--green); border-color: var(--green); }
.btn-outline:hover { background: var(--green-soft); color: var(--green-dark); }

/* Hero */
.hero { padding: 40px 0 56px; }
.hero-grid { display: grid; gap: 32px; align-items: center; }

@media (min-width: 860px) {
  .hero { padding: 56px 0 68px; }
  .hero-grid { grid-template-columns: 1.05fr 0.95fr; gap: 44px; }
}

.hero-media {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  background: var(--surface);
  border: 1px solid var(--border);
}

.hero-media img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: center 40%;
}

.photo-caption {
  font-size: 0.84rem;
  color: var(--muted);
  padding: 10px 14px;
  background: var(--surface);
  border-top: 1px solid var(--border);
}

/* Stats Strip */
.stats-strip {
  background: var(--green);
  color: #fff;
  padding: 28px 0;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

@media (min-width: 720px) {
  .stats-grid { grid-template-columns: repeat(4, 1fr); }
}

.stat-item strong {
  display: block;
  font-family: 'Fraunces', Georgia, serif;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  color: #f4cc70;
  line-height: 1.1;
}

.stat-item span {
  display: block;
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.88);
  margin-top: 4px;
}

/* Grids & Cards */
.grid-2 { display: grid; gap: 24px; }
.grid-3 { display: grid; gap: 24px; }
@media (min-width: 720px) {
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.card-body { padding: 22px; flex: 1; }
.card-media img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: center 25%;
}

.tag {
  display: inline-block;
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  background: var(--green-soft);
  color: var(--green);
  padding: 4px 10px;
  border-radius: 999px;
  margin-bottom: 10px;
}

.tag-amber {
  background: #f9ebd2;
  color: var(--amber-dark);
}

.split { display: grid; gap: 28px; align-items: center; }
@media (min-width: 820px) {
  .split { grid-template-columns: 1fr 1fr; gap: 44px; }
}

.rounded-photo {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  background: var(--surface);
}
.rounded-photo img { width: 100%; object-fit: cover; }

.callout {
  background: var(--green-soft);
  border-left: 4px solid var(--green);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 20px 24px;
  margin: 22px 0;
}
.callout h3 { margin-bottom: 6px; font-size: 1.1rem; }
.callout p { margin: 0; }

.check-list { list-style: none; padding: 0; margin: 14px 0 0; }
.check-list li { position: relative; padding-left: 22px; margin-bottom: 10px; }
.check-list li::before {
  content: "•";
  position: absolute;
  left: 5px;
  color: var(--amber);
  font-weight: 800;
}

.values-grid {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  margin-top: 20px;
}

.value-pill {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px;
}
.value-pill strong { display: block; color: var(--green); margin-bottom: 4px; }

.table-wrap { overflow-x: auto; margin-top: 16px; }
table {
  width: 100%;
  border-collapse: collapse;
  background: var(--surface);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
}
th, td {
  padding: 13px 16px;
  text-align: left;
  border-bottom: 1px solid var(--border);
  font-size: 0.95rem;
}
th { background: var(--green); color: #fff; font-weight: 600; }
tr:last-child td { border-bottom: 0; }

.page-banner {
  background: var(--green);
  color: #fff;
  padding: 44px 0;
}
.page-banner h1 { color: #fff; margin-bottom: 10px; }
.page-banner .lead { color: rgba(255, 255, 255, 0.88); }
.page-banner .eyebrow { color: #f4cc70; }

/* Footer */
.site-footer {
  background: var(--green-dark);
  color: rgba(255, 255, 255, 0.88);
  padding: 48px 0 28px;
  font-size: 0.92rem;
}

.footer-grid { display: grid; gap: 28px; }
@media (min-width: 760px) {
  .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; }
}

.site-footer h3, .site-footer strong { color: #fff; }
.site-footer a { color: #f4cc70; }
.site-footer ul { list-style: none; padding: 0; margin: 10px 0 0; }
.site-footer li { margin-bottom: 7px; }

.footer-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.footer-brand img { width: 48px; height: 48px; }

.footer-bottom {
  margin-top: 32px;
  padding-top: 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.84rem;
  color: rgba(255, 255, 255, 0.7);
}
