/* ============================================================
   IMAM.NGO — Main Stylesheet
   Brand: Blue #1a51a8 · Gold #d1c24b · Bg #f4f6fb
   ============================================================ */

/* === CUSTOM PROPERTIES ===================================== */
:root {
  --blue:        #1a51a8;
  --blue-dark:   #153f85;
  --gold:        #d1c24b;
  --gold-dim:    rgba(209, 194, 75, 0.18);
  --bg:          #f4f6fb;
  --white:       #ffffff;
  --text:        #111827;
  --text-muted:  #5c6478;
  --border:      rgba(0, 0, 0, 0.09);
  --card-radius: 12px;
  --card-border: 0.5px solid rgba(0, 0, 0, 0.09);
  --shadow-sm:   0 1px 4px rgba(0,0,0,0.06);
  --shadow-md:   0 4px 20px rgba(0,0,0,0.08);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI',
               Helvetica, Arial, sans-serif;
  font-weight: 400;
  font-size: 16px;
  line-height: 1.6;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
}

img  { display: block; max-width: 100%; height: auto; }
a    { color: inherit; text-decoration: none; }
ul   { list-style: none; }

/* === LAYOUT HELPERS ======================================== */
.container {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 28px;
}

/* === SECTION HEADING ======================================= */
.section-heading {
  display: inline-block;
  font-size: 1.45rem;
  font-weight: 500;
  color: var(--blue);
  padding-bottom: 10px;
  border-bottom: 2.5px solid var(--gold);
  margin-bottom: 32px;
}

/* === TOP / BOTTOM BARS ===================================== */
.top-bar,
.bottom-bar {
  height: 4px;
  background: var(--gold);
}

/* === PILLS ================================================= */
.pill {
  display: inline-block;
  font-size: 0.67rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 3px 9px;
  border-radius: 4px;
  margin-bottom: 14px;
}

.pill--white {
  background: var(--white);
  color: var(--blue);
}

.pill--gold-outline {
  border: 1px solid rgba(209,194,75,0.7);
  color: var(--gold);
}

.pill--blue-outline {
  border: 1px solid rgba(26,81,168,0.35);
  color: var(--blue);
}

/* === BUTTONS =============================================== */
.btn-cta {
  flex-shrink: 0;
  display: inline-block;
  background: var(--gold);
  color: var(--blue);
  font-weight: 500;
  font-size: 0.875rem;
  padding: 9px 20px;
  border-radius: 6px;
  white-space: nowrap;
  transition: opacity 0.18s, box-shadow 0.18s;
}
.btn-cta:hover { opacity: 0.88; box-shadow: 0 2px 10px rgba(0,0,0,0.15); }

.btn-gold {
  display: inline-block;
  background: var(--gold);
  color: var(--blue);
  font-weight: 500;
  font-size: 0.875rem;
  padding: 10px 26px;
  border-radius: 6px;
  margin-top: 4px;
  transition: opacity 0.18s;
}
.btn-gold:hover { opacity: 0.88; }

.btn-link {
  display: inline-block;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--blue);
  margin-top: 16px;
  transition: color 0.15s;
}
.btn-link:hover { color: var(--blue-dark); text-decoration: underline; }

/* === META ================================================== */
.meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 20px;
}
.meta__sep { opacity: 0.4; }

/* ==========================================================
   ② NAVIGATION
   ========================================================== */
.site-header {
  background: var(--blue);
  position: sticky;
  top: 0;
  z-index: 200;
  box-shadow: 0 2px 16px rgba(0,0,0,0.18);
}

/* Hidden checkbox — drives mobile toggle */
.nav-toggle-input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}

.nav-container {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 28px;
  height: 88px;
  display: flex;
  align-items: center;
  gap: 0;
}

/* Logo */
.nav-logo {
  flex-shrink: 0;
  margin-right: auto;
  display: flex;
  align-items: center;
  gap: 10px;
}
.nav-logo img { height: 57px; width: auto; }
.nav-logo__tag {
  font-family: 'Roboto', Arial, sans-serif;
  font-size: 0.83rem;
  font-weight: 400;
  color: var(--gold);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  opacity: 0.85;
  white-space: nowrap;
}

/* Desktop nav links */
.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}
.nav-links a {
  color: rgba(255,255,255,0.82);
  font-weight: 500;
  font-size: 0.875rem;
  letter-spacing: 0.01em;
  transition: color 0.15s;
}
.nav-links a:hover { color: var(--gold); }

/* CTA */
.btn-cta { margin-left: 28px; }

/* Header date */
.header-date {
  margin-left: 20px;
  font-size: 0.78rem;
  color: rgba(255,255,255,0.65);
  white-space: nowrap;
  flex-shrink: 0;
}

/* Hamburger icon (hidden on desktop) */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 38px;
  height: 38px;
  margin-left: 16px;
  cursor: pointer;
  flex-shrink: 0;
}
.hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: rgba(255,255,255,0.9);
  border-radius: 2px;
  transition: transform 0.25s, opacity 0.25s;
}

/* Mobile nav drawer */
.mobile-nav {
  display: none;
  background: var(--blue-dark);
  border-top: 1px solid rgba(255,255,255,0.1);
}
.mobile-nav ul { padding: 12px 0 20px; }
.mobile-nav li a {
  display: block;
  padding: 11px 28px;
  color: rgba(255,255,255,0.85);
  font-weight: 500;
  font-size: 0.9rem;
  transition: background 0.15s;
}
.mobile-nav li a:hover { background: rgba(255,255,255,0.06); color: var(--gold); }
.mobile-cta {
  display: inline-block !important;
  margin: 8px 28px 0;
  background: var(--gold);
  color: var(--blue) !important;
  border-radius: 6px;
  padding: 10px 20px !important;
  font-weight: 500;
}

/* Toggle open state */
.nav-toggle-input:checked ~ .mobile-nav { display: block; }
.nav-toggle-input:checked ~ .nav-container .hamburger span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-toggle-input:checked ~ .nav-container .hamburger span:nth-child(2) {
  opacity: 0;
}
.nav-toggle-input:checked ~ .nav-container .hamburger span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ==========================================================
   ③ HERO SECTION
   ========================================================== */
.hero-section {
  background: var(--blue);
  padding: 52px 0 60px;
}

.hero-container {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 28px;
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 28px;
  align-items: stretch;
}

/* Featured article card */
.hero-card {
  background: var(--white);
  border: var(--card-border);
  border-radius: var(--card-radius);
  border-top: 3px solid var(--blue);
  padding: 0;
  box-shadow: var(--shadow-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.hero-card__img-wrap {
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
}
.hero-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s;
}
.hero-card:hover .hero-card__img { transform: scale(1.02); }

.hero-card__content {
  padding: 24px 28px 28px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.hero-card__title {
  font-size: 1.55rem;
  font-weight: 500;
  line-height: 1.35;
  color: var(--text);
  margin-bottom: 10px;
}

.hero-card__excerpt {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 14px;
}

.hero-card__content .meta { margin-bottom: 14px; }
.hero-card__content .btn-gold { margin-top: auto; align-self: flex-start; }

/* Recent articles sidebar */
.hero-recent {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: var(--card-radius);
  padding: 24px 20px;
  display: flex;
  flex-direction: column;
}

.recent-see-all {
  display: block;
  margin-top: auto;
  padding-top: 16px;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--gold);
  letter-spacing: 0.02em;
  transition: opacity 0.15s;
}
.recent-see-all:hover { opacity: 0.75; }

.recent-label {
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 20px;
}

.recent-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  flex: 1;
}

.recent-item {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 16px 0;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
.recent-item:first-child { padding-top: 0; }
.recent-item:last-child { border-bottom: none; padding-bottom: 0; }

.recent-item__thumb-wrap {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 6px;
  overflow: hidden;
}
.recent-item__thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.25s;
}
.recent-item__thumb-wrap:hover .recent-item__thumb { transform: scale(1.05); }

.recent-item__text {
  display: flex;
  flex-direction: column;
  gap: 5px;
  flex: 1;
}

.recent-item__title {
  font-size: 0.875rem;
  font-weight: 500;
  color: rgba(255,255,255,0.88);
  line-height: 1.45;
  transition: color 0.15s;
}
.recent-item__title:hover { color: var(--gold); }

.recent-item__date {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.45);
}

/* ==========================================================
   ④ WHO WE ARE
   ========================================================== */
.who-we-are {
  background: var(--white);
  padding: 68px 0;
}

.lead-text {
  font-size: 1.05rem;
  color: var(--text-muted);
  line-height: 1.8;
  max-width: 800px;
}

/* ==========================================================
   ⑤ REPORTS & REFLECTIONS
   ========================================================== */
.reports-section {
  background: var(--white);
  padding: 68px 0;
}

.reports-grid {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 28px;
  align-items: start;
}

/* Featured report card */
.report-featured {
  background: var(--white);
  border: var(--card-border);
  border-radius: var(--card-radius);
  border-top: 3px solid var(--blue);
  padding: 32px 28px;
  box-shadow: var(--shadow-sm);
}

.report-featured__title {
  font-size: 1.2rem;
  font-weight: 500;
  color: var(--text);
  line-height: 1.45;
  margin-bottom: 12px;
}

.report-featured__excerpt {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 8px;
}

/* Small report card stack */
.report-stack {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.report-small {
  background: var(--bg);
  border: var(--card-border);
  border-radius: var(--card-radius);
  padding: 20px 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.report-small__title {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text);
  line-height: 1.45;
}

/* ==========================================================
   ⑥ FOCUS AREAS
   ========================================================== */
.focus-section {
  background: var(--bg);
  padding: 68px 0;
}

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

.focus-card {
  background: var(--white);
  border: var(--card-border);
  border-radius: var(--card-radius);
  border-top: 3px solid var(--gold);
  padding: 24px 20px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.2s, transform 0.2s;
}
.focus-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.focus-card h4 {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--blue);
  margin-bottom: 10px;
}

.focus-card p {
  font-size: 0.84rem;
  color: var(--text-muted);
  line-height: 1.65;
}

/* ==========================================================
   ⑦ MISSION BANNER
   ========================================================== */
.mission-banner {
  background: var(--blue);
  padding: 72px 0;
}

.mission-inner {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 28px;
  display: grid;
  grid-template-columns: 110px 1fr auto;
  gap: 52px;
  align-items: center;
}

.mission-logo img {
  width: 130px;
  height: auto;
}

.mission-text h2 {
  font-size: 1.35rem;
  font-weight: 500;
  color: var(--white);
  margin-bottom: 14px;
  line-height: 1.35;
}

.mission-text p {
  font-size: 0.95rem;
  color: rgba(255,255,255,0.78);
  line-height: 1.75;
}

/* ECOSOC Badge */
.ecosoc-badge { flex-shrink: 0; }

.ecosoc-badge__inner {
  border: 1.5px solid rgba(209,194,75,0.6);
  border-radius: 12px;
  padding: 22px 26px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  min-width: 160px;
}

.ecosoc-badge__icon {
  width: 44px;
  height: 44px;
  margin-bottom: 4px;
}

.ecosoc-badge__label {
  display: block;
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
}

.ecosoc-badge__status {
  display: block;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--white);
  line-height: 1.4;
}

/* ==========================================================
   ⑧ NEWS (homepage)
   ========================================================== */
.home-news-section {
  background: var(--bg);
  padding: 68px 0;
}

.home-news-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 28px;
}
.home-news-head .section-heading { margin-bottom: 0; }

.home-news-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.home-news-card {
  background: var(--white);
  border: var(--card-border);
  border-radius: var(--card-radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.2s;
  display: flex;
  flex-direction: column;
}
.home-news-card:hover { box-shadow: var(--shadow-md); }

.home-news-card__img-wrap {
  display: block;
  aspect-ratio: 16 / 9;
  background: var(--gold-dim);
  overflow: hidden;
}
.home-news-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.home-news-card__body {
  padding: 18px 22px 24px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.home-news-card__date {
  display: block;
  font-size: 0.75rem;
  color: var(--text-muted);
  margin: 10px 0 6px;
}

.home-news-card__title {
  font-size: 0.98rem;
  font-weight: 500;
  line-height: 1.4;
  margin-bottom: 10px;
}
.home-news-card__title a { color: var(--text); }
.home-news-card__title a:hover { color: var(--blue); }

.home-news-card__excerpt {
  font-size: 0.83rem;
  color: var(--text-muted);
  line-height: 1.55;
}

/* ==========================================================
   ⑨ FOOTER
   ========================================================== */
.site-footer {
  background: var(--blue);
  padding: 52px 0 40px;
}

.footer-inner {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 28px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  text-align: center;
}

.footer-brand img {
  height: 34px;
  width: auto;
  margin: 0 auto;
}

.footer-brand__sub {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.45);
  margin-top: 6px;
  letter-spacing: 0.05em;
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 30px;
}

.footer-nav a {
  font-size: 0.875rem;
  font-weight: 500;
  color: rgba(255,255,255,0.7);
  transition: color 0.15s;
}
.footer-nav a:hover { color: var(--gold); }

.footer-copy {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.3);
}

/* ==========================================================
   RESPONSIVE — TABLET  (≤ 1024px)
   ========================================================== */
@media (max-width: 1024px) {
  .nav-links {
    gap: 22px;
  }

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

/* ==========================================================
   RESPONSIVE — MEDIUM  (≤ 860px)
   ========================================================== */
@media (max-width: 860px) {
  /* Nav: hide desktop links, show hamburger */
  .nav-links { display: none; }
  .hamburger { display: flex; }
  .btn-cta     { display: none; }    /* moved into mobile drawer */
  .header-date { display: none; }

  /* Hero stacks vertically */
  .hero-container {
    grid-template-columns: 1fr;
  }
  .hero-card__title { font-size: 1.3rem; }

  /* Recent list goes horizontal (scrollable) */
  .hero-recent { padding: 22px 18px; }

  /* Reports stack */
  .reports-grid {
    grid-template-columns: 1fr;
  }
  .report-stack {
    flex-direction: row;
    flex-wrap: wrap;
  }
  .report-small { flex: 1 1 200px; }

  /* Mission banner stacks */
  .mission-inner {
    grid-template-columns: 1fr;
    gap: 32px;
    text-align: center;
  }
  .mission-logo { display: flex; justify-content: center; }
  .ecosoc-badge { display: flex; justify-content: center; }

  /* News 2-col */
  .home-news-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ==========================================================
   RESPONSIVE — MOBILE  (≤ 600px)
   ========================================================== */
@media (max-width: 600px) {
  .container { padding: 0 18px; }
  .nav-container { padding: 0 18px; }
  .hero-container { padding: 0 18px; }
  .mission-inner { padding: 0 18px; }
  .footer-inner { padding: 0 18px; }

  .hero-section { padding: 32px 0 40px; }
  .hero-card__content { padding: 22px 20px 26px; }
  .hero-card__title { font-size: 1.18rem; }

  .who-we-are,
  .reports-section,
  .focus-section,
  .home-news-section { padding: 48px 0; }

  .mission-banner { padding: 52px 0; }

  .focus-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .home-news-grid {
    grid-template-columns: 1fr;
  }

  .report-stack { flex-direction: column; }

  .section-heading { font-size: 1.2rem; }

  .mission-text h2 { font-size: 1.15rem; }
}
