/* Ushirika Fundi I — site styles
   Palette drawn from the organization seal:
   gold ring, navy, red, green, white, black */
:root {
  --gold: #F2D13D;
  --gold-deep: #D9B41E;
  --gold-pale: #FBF3CF;
  --navy: #2B2F80;
  --navy-deep: #1E2160;
  --red: #C62F2A;
  --green: #2F5A4B;
  --blue: #2F5BC4;
  --ink: #1b1b1b;
  --text: #2a2a2a;
  --muted: #5d5d66;
  --cream: #FBF8EE;
  --white: #ffffff;
  --line: #e6e0cc;
  --radius: 14px;
  --shadow: 0 10px 30px rgba(30, 33, 96, 0.10);
  --font-head: "Libre Baskerville", "Times New Roman", Georgia, serif;
  --font-body: "Source Sans 3", "Segoe UI", Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.6;
  color: var(--text);
  background: var(--cream);
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--navy); }
h1, h2, h3, h4 { font-family: var(--font-head); color: var(--navy-deep); line-height: 1.2; margin: 0 0 .5em; }
h1 { font-size: clamp(2rem, 4.5vw, 3.25rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.25rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }
.container { width: min(1140px, 100% - 32px); margin-inline: auto; }
.center { text-align: center; }

/* Four-color stripe echoing the seal quadrants */
.stripe { height: 6px; display: grid; grid-template-columns: repeat(4, 1fr); }
.stripe span:nth-child(1) { background: var(--green); }
.stripe span:nth-child(2) { background: var(--navy); }
.stripe span:nth-child(3) { background: var(--red); }
.stripe span:nth-child(4) { background: var(--gold); }

/* Header */
.site-header { background: var(--white); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 50; }
.site-header .container { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 84px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--navy-deep); }
.brand img { width: 56px; height: 56px; }
.brand .name { font-family: var(--font-head); font-weight: 700; font-size: 1.15rem; letter-spacing: .02em; line-height: 1.1; }
.brand .tag { display: block; font-family: var(--font-body); font-size: .78rem; color: var(--muted); letter-spacing: .12em; text-transform: uppercase; }
.nav { display: flex; gap: 4px; }
.nav a { text-decoration: none; color: var(--navy-deep); font-weight: 600; padding: 10px 14px; border-radius: 8px; }
.nav a:hover { background: var(--gold-pale); }
.nav a.active { background: var(--navy); color: var(--white); }
.nav-toggle { display: none; background: none; border: 2px solid var(--navy); color: var(--navy); border-radius: 8px; padding: 6px 10px; font-size: 1.1rem; cursor: pointer; }

/* Hero */
.hero { background: linear-gradient(135deg, var(--navy-deep) 0%, var(--navy) 55%, #3c40a0 100%); color: var(--white); position: relative; overflow: hidden; }
.hero::after { content: ""; position: absolute; inset: auto -10% -40% auto; width: 60vw; max-width: 720px; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(circle, rgba(242,209,61,.22), transparent 65%); pointer-events: none; }
.hero .container { display: grid; grid-template-columns: 1.3fr 1fr; gap: 40px; align-items: center; padding: 72px 0; position: relative; }
.hero h1 { color: var(--white); margin-bottom: .4em; }
.hero .lead { font-size: 1.25rem; color: #e9e8f7; max-width: 44ch; }
.hero .eyebrow { display: inline-block; background: var(--gold); color: var(--ink); font-weight: 700; letter-spacing: .14em; text-transform: uppercase; font-size: .78rem; padding: 6px 12px; border-radius: 999px; margin-bottom: 18px; }
.hero .seal { justify-self: center; width: min(340px, 70vw); filter: drop-shadow(0 18px 30px rgba(0,0,0,.35)); }
.btn { display: inline-block; text-decoration: none; font-weight: 700; padding: 13px 24px; border-radius: 10px; border: 2px solid transparent; transition: transform .15s ease, background .15s ease; }
.btn:hover { transform: translateY(-2px); }
.btn-gold { background: var(--gold); color: var(--ink); }
.btn-gold:hover { background: var(--gold-deep); }
.btn-outline { border-color: rgba(255,255,255,.7); color: var(--white); }
.btn-outline:hover { background: rgba(255,255,255,.12); }
.btn-navy { background: var(--navy); color: var(--white); }
.btn-navy:hover { background: var(--navy-deep); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }

/* Sections */
section { padding: 64px 0; }
.section-title { text-align: center; margin-bottom: 40px; }
.section-title .kicker { display: block; color: var(--red); font-weight: 700; letter-spacing: .16em; text-transform: uppercase; font-size: .8rem; margin-bottom: 8px; }
.section-title p { color: var(--muted); max-width: 60ch; margin: 0 auto; }
.alt { background: var(--white); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; }
.card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow); }
.card .icon { width: 52px; height: 52px; border-radius: 12px; display: grid; place-items: center; margin-bottom: 16px; color: var(--white); font-weight: 700; font-family: var(--font-head); font-size: 1.3rem; }
.icon.green { background: var(--green); } .icon.navy { background: var(--navy); } .icon.red { background: var(--red); } .icon.gold { background: var(--gold); color: var(--ink); }
.card h3 { margin-bottom: .4em; }
.card p:last-child { margin-bottom: 0; }

/* Quote */
.quote { background: var(--gold); color: var(--ink); text-align: center; padding: 56px 0; }
.quote blockquote { margin: 0 auto; max-width: 42ch; font-family: var(--font-head); font-size: clamp(1.4rem, 2.6vw, 2rem); line-height: 1.35; }
.quote cite { display: block; font-style: normal; font-family: var(--font-body); font-weight: 700; letter-spacing: .14em; text-transform: uppercase; font-size: .8rem; margin-top: 18px; }

/* Lists */
ul.checks { list-style: none; padding: 0; margin: 0 0 1em; }
ul.checks li { position: relative; padding-left: 32px; margin-bottom: 10px; }
ul.checks li::before { content: "✓"; position: absolute; left: 0; top: 0; width: 22px; height: 22px; border-radius: 50%; background: var(--green); color: var(--white); font-size: .8rem; font-weight: 700; display: grid; place-items: center; margin-top: 4px; }

/* Trades */
.trades { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; }
.trade { background: var(--white); border-left: 6px solid var(--gold); border-radius: 10px; padding: 20px 22px; border-top: 1px solid var(--line); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.trade:nth-child(4n+2) { border-left-color: var(--navy); }
.trade:nth-child(4n+3) { border-left-color: var(--red); }
.trade:nth-child(4n+4) { border-left-color: var(--green); }
.trade h3 { font-size: 1.1rem; margin-bottom: .3em; }
.trade p { margin: 0; color: var(--muted); font-size: 1rem; }

/* Photo feature */
.feature-img { border-radius: var(--radius); box-shadow: var(--shadow); object-fit: cover; width: 100%; aspect-ratio: 16/10; }
.portrait { width: 220px; border-radius: var(--radius); box-shadow: var(--shadow); border: 6px solid var(--white); }
.letter { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 40px; box-shadow: var(--shadow); }
.letter .sig { font-family: var(--font-head); font-weight: 700; color: var(--navy-deep); }
.motto { text-align: center; font-family: var(--font-head); color: var(--navy-deep); font-size: 1.4rem; line-height: 1.5; }

/* Officers */
.officers { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 20px; }
.officer { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; text-align: center; box-shadow: var(--shadow); }
.officer .avatar { width: 72px; height: 72px; border-radius: 50%; margin: 0 auto 14px; display: grid; place-items: center; font-family: var(--font-head); font-weight: 700; font-size: 1.4rem; color: var(--white); background: var(--navy); }
.officer:nth-child(2) .avatar { background: var(--green); }
.officer:nth-child(3) .avatar { background: var(--red); }
.officer:nth-child(4) .avatar { background: var(--gold); color: var(--ink); }
.officer .role { color: var(--red); font-weight: 700; letter-spacing: .12em; text-transform: uppercase; font-size: .75rem; }
.officer h3 { margin: 4px 0 6px; }
.officer a { word-break: break-all; font-size: .95rem; }

/* Album */
.album { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 18px; }
.album a { display: block; border-radius: 12px; overflow: hidden; box-shadow: var(--shadow); background: var(--white); border: 1px solid var(--line); text-decoration: none; color: var(--text); }
.album img { width: 100%; aspect-ratio: 4/5; object-fit: cover; transition: transform .3s ease; }
.album a:hover img { transform: scale(1.04); }
.album figcaption { padding: 12px 14px; font-size: .95rem; color: var(--muted); }
.album figure { margin: 0; }
.lightbox { position: fixed; inset: 0; background: rgba(10,10,20,.92); display: none; align-items: center; justify-content: center; z-index: 100; padding: 24px; }
.lightbox.open { display: flex; }
.lightbox img { max-width: min(92vw, 1000px); max-height: 82vh; border-radius: 8px; box-shadow: 0 20px 60px rgba(0,0,0,.6); }
.lightbox .cap { position: absolute; bottom: 20px; left: 0; right: 0; text-align: center; color: #eee; font-size: 1rem; padding: 0 60px; }
.lightbox button { position: absolute; background: rgba(255,255,255,.12); color: #fff; border: 0; font-size: 2rem; width: 52px; height: 52px; border-radius: 50%; cursor: pointer; }
.lightbox button:hover { background: var(--gold); color: var(--ink); }
.lightbox .close { top: 18px; right: 18px; }
.lightbox .prev { left: 14px; top: 50%; transform: translateY(-50%); }
.lightbox .next { right: 14px; top: 50%; transform: translateY(-50%); }

/* Contact */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: start; }
form .field { margin-bottom: 16px; }
form label { display: block; font-weight: 700; margin-bottom: 6px; color: var(--navy-deep); }
form input, form textarea, form select { width: 100%; font: inherit; padding: 12px 14px; border: 1px solid #cfc8b0; border-radius: 8px; background: var(--white); }
form input:focus, form textarea:focus, form select:focus { outline: 2px solid var(--gold); border-color: var(--gold-deep); }
.note { font-size: .95rem; color: var(--muted); }

/* Page banner */
.banner { background: var(--navy); color: var(--white); padding: 48px 0; }
.banner h1 { color: var(--white); margin: 0; }
.banner p { color: #d9d8ee; margin: 8px 0 0; max-width: 60ch; }

/* Footer */
.site-footer { background: var(--ink); color: #cfcfcf; padding: 48px 0 28px; }
.site-footer .container { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 32px; }
.site-footer h4 { color: var(--gold); margin-bottom: .6em; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { color: var(--gold); }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 8px; }
.site-footer .foot-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.site-footer .foot-brand img { width: 48px; }
.site-footer .copyright { display: block; text-align: center; color: #8a8a8a; font-size: .9rem; margin-top: 32px; border-top: 1px solid #333; padding-top: 20px; }

@media (max-width: 900px) {
  .hero .container { grid-template-columns: 1fr; text-align: center; padding: 48px 0; }
  .hero .lead { margin-inline: auto; }
  .actions { justify-content: center; }
  .hero .seal { order: -1; width: min(220px, 55vw); }
  .grid-3, .grid-2, .contact-grid, .site-footer .container { grid-template-columns: 1fr; }
  .nav { display: none; position: absolute; top: 84px; left: 0; right: 0; background: var(--white); flex-direction: column; padding: 10px 16px 16px; border-bottom: 1px solid var(--line); box-shadow: var(--shadow); }
  .nav.open { display: flex; }
  .nav-toggle { display: inline-block; }
  section { padding: 48px 0; }
  .letter { padding: 24px; }
}

/* Trade contact blocks (union directory) */
.trade .contact { margin: 10px 0 12px; padding: 10px 12px; background: var(--cream); border-radius: 8px; font-size: .95rem; line-height: 1.45; }
.trade .contact + .contact { margin-top: -4px; }
.trade .contact .local { font-weight: 700; color: var(--navy-deep); }
.trade .contact a { word-break: break-all; }
.trade p { margin-top: 4px; }
