/* =============================================
   OSIYA FOUNDATION — Main Stylesheet
   Brand: #074d88 (deep blue) / White
   ============================================= */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,600;0,700;1,400&family=DM+Sans:wght@300;400;500;600&display=swap');

:root {
  --blue: #074d88;
  --blue-light: #0d6cbf;
  --blue-dark: #053870;
  --blue-pale: #e8f1fb;
  --blue-mid: #1a6db5;
  --white: #ffffff;
  --off-white: #f8fafd;
  --gray-50: #f4f6f9;
  --gray-100: #e8ecf2;
  --gray-300: #c5cdd9;
  --gray-500: #7a8899;
  --gray-700: #3d4a5c;
  --gray-900: #1a2332;
  --gold: #c8973a;
  --gold-light: #f0c870;
  --success: #1d7a4e;
  --danger: #c0392b;
  --font-display: 'Playfair Display', Georgia, serif;
  --font-body: 'DM Sans', system-ui, sans-serif;
  --shadow-sm: 0 1px 3px rgba(7,77,136,0.08), 0 1px 2px rgba(7,77,136,0.04);
  --shadow-md: 0 4px 16px rgba(7,77,136,0.12), 0 2px 6px rgba(7,77,136,0.06);
  --shadow-lg: 0 12px 40px rgba(7,77,136,0.18), 0 4px 12px rgba(7,77,136,0.08);
  --radius: 8px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; font-size: 16px; }

body {
  font-family: var(--font-body);
  color: var(--gray-900);
  background: var(--white);
  line-height: 1.7;
  overflow-x: hidden;
}

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

/* ---- TYPOGRAPHY ---- */
h1, h2, h3, h4 { font-family: var(--font-display); line-height: 1.2; }
h1 { font-size: clamp(2.2rem, 5vw, 3.8rem); }
h2 { font-size: clamp(1.8rem, 4vw, 2.8rem); }
h3 { font-size: clamp(1.2rem, 2.5vw, 1.6rem); }
h4 { font-size: 1.1rem; }
p { color: var(--gray-700); }

.section-label {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--blue);
  background: var(--blue-pale);
  padding: 5px 14px;
  border-radius: 99px;
  margin-bottom: 12px;
}
.section-label.white { color: var(--blue-pale); background: rgba(255,255,255,0.15); }

.section-title { color: var(--gray-900); margin-bottom: 16px; }
.section-title.white { color: var(--white); }
.section-subtitle { font-size: 1.5rem; color: var(--gray-500); max-width: 860px; margin: 0 auto 48px; }
.section-subtitle.white { color: rgba(255,255,255,0.75); }

/* ---- LAYOUT ---- */
.container { max-width: 1700px; margin: 0 auto; padding: 0 24px; }
.section { padding: 96px 0; }
.section-sm { padding: 64px 0; }
.section-blue { background: var(--blue); }
.section-pale { background: var(--off-white); }
.section-dark { background: var(--gray-900); }

/* ---- NAVBAR ---- */
.navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  padding: 0 24px;
  transition: var(--transition);
  background: transparent;
}
.navbar.scrolled {
  background: rgba(7,77,136,0.97);
  backdrop-filter: blur(12px);
  box-shadow: var(--shadow-md);
}
.navbar-inner {
  max-width: 1500px; margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  height: 150px;
}
.navbar-logo {
  display: flex; align-items: center; gap: 12px;
  font-family: var(--font-display); font-size: 2rem; font-weight: 700;
  color: var(--white);
}
.navbar-logo img { height: 130px; width: auto; border-radius: 4px; }
.navbar-logo .logo-text { line-height: 1.1; }
.navbar-logo .logo-sub { display: block; font-size: 1rem; font-weight: 400; letter-spacing: 0.12em; text-transform: uppercase; opacity: 0.8; font-family: var(--font-body); }
.navbar-links { display: flex; align-items: center; gap: 4px; }
.navbar-links a {
  color: rgba(255,255,255,0.85); font-size: 1.5rem; font-weight: 500;
  padding: 8px 14px; border-radius: var(--radius);
  transition: var(--transition);
}
.navbar-links a:hover { color: var(--white); background: rgba(255,255,255,0.1); }
.navbar-cta {
  background: var(--gold) !important; color: var(--gray-900) !important;
  padding: 8px 20px !important; border-radius: 99px !important; font-weight: 600 !important;
}
.navbar-cta:hover { background: var(--gold-light) !important; transform: translateY(-1px); }
.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 8px; }
.nav-toggle span { display: block; width: 24px; height: 2px; background: white; margin: 5px 0; transition: var(--transition); border-radius: 2px; }

/* ---- HERO ---- */
.hero {
  min-height: 100vh; position: relative;
  display: flex; align-items: center;
  overflow: hidden;
  background: var(--blue-dark);
}
.hero-bg {
  position: absolute; inset: 0;
  /* background: linear-gradient(135deg, var(--blue-dark) 0%, var(--blue) 60%, var(--blue-mid) 100%); */
}
.hero-bg-pattern {
  position: absolute; inset: 0; opacity: 0.04;
  /* background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='1'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E"); */
}
.hero-image-overlay {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  opacity: 0.18;
}
/* Hero background video */
.hero-video-bg {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; object-position: center;
  opacity: 0; transition: opacity 1.2s ease;
  pointer-events: none;
}
.hero-video-bg.loaded { opacity: 1.5; }
.hero-video-overlay {
  position: absolute; inset: 0; z-index: 0;
  background: linear-gradient(135deg,
    rgba(3,22,46,0.72) 0%,
    rgba(7,77,136,0.60) 50%,
    rgba(5,56,112,0.68) 100%
  );
}
/* When video is present, reduce the static gradient opacity */
.hero.has-video .hero-bg { opacity: 0; }
.hero.has-video .hero-bg-pattern { z-index: 1; }
.hero.has-video .hero-content { z-index: 2; }
.hero.has-video .scroll-indicator { z-index: 2; }

/* Video mute toggle button */
.hero-video-mute {
  position: absolute; bottom: 32px; right: 32px; z-index: 10;
  width: 40px; height: 40px; border-radius: 50%;
  background: rgba(255,255,255,0.15); backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.25);
  color: white; font-size: 0.9rem;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: var(--transition);
}
.hero-video-mute:hover { background: rgba(255,255,255,0.25); }

.hero-content {
  position: relative; z-index: 1;
  max-width: 1750px; margin: 0 auto; padding: 120px 24px 80px;
  display: grid; grid-template-columns: 2fr 1fr; gap: 64px; align-items: center;
}
.hero-text .section-label { color: var(--gold-light); background: rgba(200,151,58,0.2); }
.hero-text h1 { color: var(--white); margin-bottom: 20px; }
.hero-text h1 em { color: var(--gold-light); font-style: normal; display: block; }
.hero-text p { color: rgba(255,255,255,0.8); font-size: 1.1rem; margin-bottom: 40px; max-width: 1000px; }
.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; }
.hero-stats {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px;
  background: rgba(255,255,255,0.1); border-radius: var(--radius-lg);
  overflow: hidden; margin-top: 56px;
}
.hero-stat {
  background: rgba(7,77,136,0.6); backdrop-filter: blur(8px);
  padding: 20px 16px; text-align: center;
}
.hero-stat .value { font-family: var(--font-display); font-size: 2rem; font-weight: 700; color: var(--gold-light); line-height: 1; }
.hero-stat .label { font-size: 0.75rem; color: rgba(255,255,255,0.7); text-transform: uppercase; letter-spacing: 0.08em; margin-top: 4px; }
.hero-visual { position: relative; }
.hero-image-card {
  border-radius: var(--radius-xl); overflow: hidden;
  border: 3px solid rgba(255,255,255,0.15);
  box-shadow: var(--shadow-lg);
  aspect-ratio: 4/5;
}
.hero-image-card img { width: 100%; height: 100%; object-fit: cover; }
.hero-image-card .placeholder {
  width: 100%; height: 100%; min-height: 400px;
  background: linear-gradient(135deg, rgba(255,255,255,0.1), rgba(255,255,255,0.05));
  display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 12px;
}
.hero-image-card .placeholder i { font-size: 3rem; color: rgba(255,255,255,0.3); }
.hero-image-card .placeholder span { color: rgba(255,255,255,0.4); font-size: 0.85rem; }
.hero-badge {
  position: absolute; bottom: 24px; left: -24px;
  background: var(--white); border-radius: var(--radius-lg);
  padding: 16px 20px; box-shadow: var(--shadow-lg);
  display: flex; align-items: center; gap: 12px;
}
.hero-badge .icon { width: 44px; height: 44px; border-radius: 50%; background: var(--blue-pale); display: flex; align-items: center; justify-content: center; color: var(--blue); font-size: 1.2rem; flex-shrink: 0; }
.hero-badge .text strong { display: block; color: var(--gray-900); font-size: 0.95rem; }
.hero-badge .text span { color: var(--gray-500); font-size: 0.78rem; }
.scroll-indicator {
  position: absolute; bottom: 32px; left: 50%; transform: translateX(-50%);
  z-index: 1; display: flex; flex-direction: column; align-items: center; gap: 8px;
  color: rgba(255,255,255,0.5); font-size: 0.7rem; letter-spacing: 0.1em; text-transform: uppercase;
}
.scroll-indicator .mouse {
  width: 22px; height: 36px; border: 2px solid rgba(255,255,255,0.3);
  border-radius: 11px; position: relative;
}
.scroll-indicator .mouse::after {
  content: ''; position: absolute; top: 6px; left: 50%; transform: translateX(-50%);
  width: 3px; height: 6px; background: rgba(255,255,255,0.5); border-radius: 2px;
  animation: scrollDown 2s ease infinite;
}
@keyframes scrollDown { 0%,100%{transform:translateX(-50%) translateY(0);opacity:1} 80%{transform:translateX(-50%) translateY(10px);opacity:0} }

/* ---- BUTTONS ---- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 28px; border-radius: 99px; font-size: 0.9rem;
  font-weight: 600; font-family: var(--font-body);
  cursor: pointer; border: 2px solid transparent;
  transition: var(--transition); white-space: nowrap;
}
.btn-primary { background: var(--gold); color: var(--gray-900); }
.btn-primary:hover { background: var(--gold-light); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(200,151,58,0.35); }
.btn-outline { background: rgb(241, 158, 4); color: var(--white); border-color: rgba(255,255,255,0.4); }
.btn-outline:hover { background: rgba(255,255,255,0.1); border-color: rgba(255,255,255,0.7); }
.btn-blue { background: var(--blue); color: var(--white); }
.btn-blue:hover { background: var(--blue-light); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(7,77,136,0.3); }
.btn-blue-outline { background: transparent; color: var(--blue); border-color: var(--blue); }
.btn-blue-outline:hover { background: var(--blue); color: var(--white); }
.btn-white { background: var(--white); color: var(--blue); }
.btn-white:hover { background: var(--blue-pale); }
.btn-sm { padding: 8px 20px; font-size: 0.82rem; }
.btn-lg { padding: 16px 40px; font-size: 1rem; }

/* ---- ABOUT ---- */
/* 3-col: photo | text | social feed */
.about-grid {
  display: grid;
  grid-template-columns: 0.6fr 1.5fr 400px;
  gap: 48px;
  align-items: start;
}
.about-image-wrap { position: relative; }
.about-image-main { border-radius: var(--radius-xl); overflow: hidden; aspect-ratio: 4/5; box-shadow: var(--shadow-lg); }
.about-image-main img { width: 100%; height: 100%; object-fit: cover; }
.about-image-main .placeholder { width: 100%; height: 100%; min-height: 460px; background: var(--blue-pale); display: flex; align-items: center; justify-content: center; color: var(--blue); }
.about-image-main .placeholder i { font-size: 3rem; opacity: 0.4; }
.about-accent {
  position: absolute; bottom: -24px; right: -24px;
  background: var(--blue); color: var(--white);
  border-radius: var(--radius-lg); padding: 24px 28px;
  box-shadow: var(--shadow-lg); min-width: 180px;
}
.about-accent .num { font-family: var(--font-display); font-size: 2.4rem; font-weight: 700; color: var(--gold-light); line-height: 1; }
.about-accent .txt { font-size: 0.8rem; opacity: 0.8; margin-top: 4px; }
.about-text .section-title { text-align: left; }
.about-text .section-subtitle { text-align: left; margin: 0 0 32px; }
.values-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 32px; }
.value-card {
  display: flex; align-items: flex-start; gap: 14px;
  padding: 16px; border-radius: var(--radius); background: var(--off-white);
  border: 1px solid var(--gray-100);
}
.value-card .icon { width: 40px; height: 40px; border-radius: var(--radius); background: var(--blue-pale); display: flex; align-items: center; justify-content: center; color: var(--blue); font-size: 1rem; flex-shrink: 0; }
.value-card h4 { font-size: 0.9rem; color: var(--gray-900); margin-bottom: 2px; font-family: var(--font-body); font-weight: 600; }
.value-card p { font-size: 0.8rem; color: var(--gray-500); margin: 0; }


/* ---- SOCIAL FEED COLUMN ---- */
.about-social {
  display: flex;
  flex-direction: column;
  border-radius: var(--radius-lg);
  border: 1px solid var(--gray-100);
  overflow: hidden;
  background: var(--white);
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: 96px;
  max-height: calc(100vh - 120px);
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--gray-100) transparent;
}
.about-social::-webkit-scrollbar { width: 4px; }
.about-social::-webkit-scrollbar-thumb { background: var(--gray-100); border-radius: 2px; }

.about-social-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 16px 12px;
  background: var(--blue);
  color: var(--white);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  position: sticky;
  top: 0;
  z-index: 1;
  flex-shrink: 0;
}
.about-social-header i { color: var(--gold-light); }

.social-platform-block { border-bottom: 1px solid var(--gray-100); }
.social-platform-block:last-child { border-bottom: none; }

.social-platform-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 14px 8px;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--gray-700);
  background: var(--gray-50);
  border-bottom: 1px solid var(--gray-100);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  gap: 8px;
}
.spl-left { display: flex; align-items: center; gap: 7px; }

.social-follow-link {
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--blue);
  display: flex;
  align-items: center;
  gap: 3px;
  white-space: nowrap;
  transition: color 0.2s ease;
  flex-shrink: 0;
}
.social-follow-link:hover { color: var(--blue-light); }
.social-follow-link i { font-size: 0.58rem; }

.social-post-card {
  display: block;
  padding: 12px 14px;
  border-bottom: 1px solid var(--gray-100);
  text-decoration: none;
  transition: background 0.2s ease;
}
.social-post-card:last-child { border-bottom: none; }
.social-post-card:hover { background: var(--off-white); }
.social-post-card--fb:hover { background: #f0f5ff; }
.social-post-card--tw:hover { background: #f7f9f9; }

.social-post-image {
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 8px;
  aspect-ratio: 16/9;
  background: var(--gray-100);
}
.social-post-image img {
  width: 100%; height: 100%; object-fit: cover; display: block;
  transition: transform 0.4s ease;
}
.social-post-card:hover .social-post-image img { transform: scale(1.04); }

.social-post-text {
  font-size: 0.81rem;
  color: var(--gray-700);
  line-height: 1.55;
  margin: 0 0 6px;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.social-post-age {
  font-size: 0.68rem;
  color: var(--gray-500);
  display: flex;
  align-items: center;
  gap: 4px;
}

.social-post-empty {
  padding: 20px 14px;
  text-align: center;
  color: var(--gray-500);
}
.social-post-empty p { font-size: 0.8rem; margin: 0; line-height: 1.5; color: var(--gray-500); }

/* ---- THEMATIC AREAS ----
.areas-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.area-card {
  border-radius: var(--radius-lg); overflow: hidden;
  border: 1px solid var(--gray-100); background: var(--white);
  transition: var(--transition); cursor: pointer;
  box-shadow: var(--shadow-sm);
}
.area-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); border-color: var(--blue-pale); }
.area-card-cover { height: 200px; position: relative; overflow: hidden; background: var(--blue); }
.area-card-cover img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s ease; }
.area-card:hover .area-card-cover img { transform: scale(1.06); }
.area-card-cover .placeholder { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, var(--blue), var(--blue-mid)); }
.area-card-cover .placeholder i { font-size: 3rem; color: rgba(255,255,255,0.4); }
.area-card-icon {
  position: absolute; bottom: 16px; left: 16px;
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--white); display: flex; align-items: center; justify-content: center;
  color: var(--blue); font-size: 1.1rem; box-shadow: var(--shadow-md);
}
.area-card-body { padding: 24px; }
.area-card-body h3 { font-size: 1.2rem; color: var(--gray-900); margin-bottom: 8px; }
.area-card-body p { font-size: 0.88rem; color: var(--gray-500); margin-bottom: 16px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.area-card-footer { display: flex; align-items: center; justify-content: space-between; padding-top: 16px; border-top: 1px solid var(--gray-100); }
.project-count { font-size: 0.78rem; color: var(--gray-500); }
.project-count strong { color: var(--blue); }
.area-link { font-size: 0.82rem; color: var(--blue); font-weight: 600; display: flex; align-items: center; gap: 4px; }
.area-link:hover { color: var(--blue-light); gap: 8px; } */

/* ---- THEMATIC AREAS ---- */
.areas-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }

/* Gentle continuous sway animation */
@keyframes cardSway {
  0%   { transform: rotate(-0.4deg) translateY(0px); }
  25%  { transform: rotate(0.3deg)  translateY(-3px); }
  50%  { transform: rotate(-0.2deg) translateY(-5px); }
  75%  { transform: rotate(0.4deg)  translateY(-2px); }
  100% { transform: rotate(-0.4deg) translateY(0px); }
}
@keyframes cardPop {
  0%   { transform: translateY(0)   scale(1)    rotate(0deg); }
  40%  { transform: translateY(-14px) scale(1.035) rotate(-0.6deg); }
  65%  { transform: translateY(-10px) scale(1.04)  rotate(0.4deg); }
  80%  { transform: translateY(-12px) scale(1.038) rotate(-0.2deg); }
  100% { transform: translateY(-12px) scale(1.038) rotate(0deg); }
}

.area-card {
  border-radius: var(--radius-lg); overflow: hidden;
  border: 1px solid var(--gray-100); background: var(--white);
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  animation: cardSway 6s ease-in-out infinite;
  transform-origin: center bottom;
  transition: box-shadow 0.35s cubic-bezier(0.34,1.56,0.64,1),
              border-color 0.3s ease;
  will-change: transform;
}
/* Stagger the sway so cards don't all move in sync */
.area-card:nth-child(1) { animation-delay: 0s; }
.area-card:nth-child(2) { animation-delay: -2s; }
.area-card:nth-child(3) { animation-delay: -4s; }
.area-card:nth-child(4) { animation-delay: -1s; }
.area-card:nth-child(5) { animation-delay: -3s; }
.area-card:nth-child(6) { animation-delay: -5s; }

.area-card:hover {
  animation: cardPop 0.45s cubic-bezier(0.34,1.56,0.64,1) forwards;
  box-shadow: 0 20px 60px rgba(7,77,136,0.22), 0 6px 20px rgba(7,77,136,0.12);
  border-color: var(--blue);
  z-index: 2;
}
.area-card-cover { height: 200px; position: relative; overflow: hidden; background: var(--blue); }
.area-card-cover img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s ease; }
.area-card:hover .area-card-cover img { transform: scale(1.08); }
.area-card-cover .placeholder { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, var(--blue), var(--blue-mid)); }
.area-card-cover .placeholder i { font-size: 3rem; color: rgba(255,255,255,0.4); }
.area-card-icon {
  position: absolute; bottom: 16px; left: 16px;
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--white); display: flex; align-items: center; justify-content: center;
  color: var(--blue); font-size: 1.1rem; box-shadow: var(--shadow-md);
  transition: transform 0.3s ease;
}
.area-card:hover .area-card-icon { transform: scale(1.15) rotate(-8deg); }
.area-card-body { padding: 24px; }
.area-card-body h3 { font-size: 1.3rem; color: var(--gray-900); margin-bottom: 8px; transition: color 0.25s ease; }
.area-card:hover .area-card-body h3 { color: var(--blue); }
.area-card-body p { font-size: 1rem; color: var(--gray-800); margin-bottom: 16px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.area-card-footer { display: flex; align-items: center; justify-content: space-between; padding-top: 16px; border-top: 1px solid var(--gray-100); }
.project-count { font-size: 0.98rem; color: var(--gray-800); }
.project-count strong { color: var(--blue); }
.area-link { font-size: 0.82rem; color: var(--blue); font-weight: 600; display: flex; align-items: center; gap: 4px; transition: gap 0.2s ease; }
.area-link:hover { color: var(--blue-light); gap: 8px; }

/* ---- IMPACT STATS ---- */
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2px; border-radius: var(--radius-xl); overflow: hidden; }
.stat-card { padding: 40px 24px; text-align: center; background: rgba(255,255,255,0.06); }
.stat-card:hover { background: rgba(255,255,255,0.1); }
.stat-icon { width: 56px; height: 56px; border-radius: 50%; background: rgba(255,255,255,0.1); display: flex; align-items: center; justify-content: center; margin: 0 auto 16px; font-size: 1.4rem; color: var(--gold-light); }
.stat-number { font-family: var(--font-display); font-size: clamp(2rem, 4vw, 3rem); font-weight: 700; color: var(--white); line-height: 1; }
.stat-number .suffix { color: var(--gold-light); }
.stat-label { font-size: 0.82rem; color: rgba(255,255,255,0.65); text-transform: uppercase; letter-spacing: 0.08em; margin-top: 8px; }

/* ---- PROJECTS ---- */
.projects-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
/* Inside sidebar layout the column is narrower — switch to auto-fill */
.page-main .projects-grid {
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
}
.project-card {
  border-radius: var(--radius-lg); overflow: hidden;
  border: 1px solid var(--gray-100); background: var(--white);
  box-shadow: var(--shadow-sm);
  animation: cardSway 7s ease-in-out infinite;
  transform-origin: center bottom;
  transition: box-shadow 0.35s cubic-bezier(0.34,1.56,0.64,1),
              border-color 0.3s ease;
  will-change: transform;
}
.project-card:nth-child(1) { animation-delay: -0.5s; }
.project-card:nth-child(2) { animation-delay: -2.5s; }
.project-card:nth-child(3) { animation-delay: -4.5s; }
.project-card:nth-child(4) { animation-delay: -1.5s; }
.project-card:nth-child(5) { animation-delay: -3.5s; }
.project-card:nth-child(6) { animation-delay: -5.5s; }

.project-card:hover {
  animation: cardPop 0.45s cubic-bezier(0.34,1.56,0.64,1) forwards;
  box-shadow: 0 20px 60px rgba(7,77,136,0.2), 0 6px 20px rgba(7,77,136,0.1);
  border-color: var(--blue);
  z-index: 2;
}
.project-card-image { height: 300px; overflow: hidden; background: var(--blue-pale); position: relative; }
.project-card-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease; }
.project-card:hover .project-card-image img { transform: scale(1.05); }
.project-card-image .placeholder { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; }
.project-card-image .placeholder i { font-size: 2.5rem; color: var(--blue); opacity: 0.3; }
.status-badge {
  position: absolute; top: 12px; right: 12px;
  padding: 4px 12px; border-radius: 99px; font-size: 0.7rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em;
}
.status-ongoing { background: #d4edda; color: #155724; }
.status-completed { background: var(--blue-pale); color: var(--blue); }
.status-planned { background: #fff3cd; color: #856404; }
.project-card-body { padding: 20px; }
.project-area-tag { display: inline-block; font-size: 0.85rem; font-weight: 600; color: var(--blue); background: var(--blue-pale); padding: 3px 10px; border-radius: 99px; margin-bottom: 10px; text-transform: uppercase; letter-spacing: 0.05em; }
.project-card-body h3 { font-size: 1.5rem; color: var(--gray-900); margin-bottom: 8px; }
.project-card-body p { font-size: 1rem; color: black; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; margin-bottom: 16px; }
.project-meta { display: flex; align-items: center; gap: 16px; font-size: 0.85rem; color: var(--gray-600); padding-top: 12px; border-top: 1px solid var(--gray-100); }
.project-meta i { color: var(--blue); }


/* ---- GALLERY ---- */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 200px;
  gap: 8px;
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.gallery-item {
  position: relative; overflow: hidden; cursor: pointer;
  background: var(--gray-100);
}
.gallery-item:nth-child(1) { grid-column: span 2; grid-row: span 2; }
.gallery-item:nth-child(5) { grid-column: span 2; }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease; }
.gallery-item:hover img { transform: scale(1.06); }
.gallery-item-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(7,77,136,0.85) 0%, transparent 60%);
  opacity: 0; transition: var(--transition);
  display: flex; align-items: flex-end; padding: 20px;
}
.gallery-item:hover .gallery-item-overlay { opacity: 1; }
.gallery-item-overlay p { color: var(--white); font-size: 0.85rem; margin: 0; }
.gallery-video { display: flex; align-items: center; justify-content: center; background: var(--gray-900); }
.gallery-video .play-btn { width: 56px; height: 56px; border-radius: 50%; background: rgba(255,255,255,0.9); display: flex; align-items: center; justify-content: center; color: var(--blue); font-size: 1.2rem; transition: var(--transition); }
.gallery-video:hover .play-btn { background: var(--white); transform: scale(1.1); }

/* ---- VOLUNTEER ---- */
.volunteer-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: center; }
.volunteer-reasons { margin-top: 40px; display: flex; flex-direction: column; gap: 20px; }
.reason-item { display: flex; align-items: flex-start; gap: 16px; }
.reason-item .icon { width: 44px; height: 44px; border-radius: 50%; background: rgba(255,255,255,0.1); display: flex; align-items: center; justify-content: center; color: var(--gold-light); font-size: 1rem; flex-shrink: 0; }
.reason-item h4 { color: var(--white); font-size: 1rem; margin-bottom: 4px; font-family: var(--font-body); font-weight: 600; }
.reason-item p { color: rgba(255,255,255,0.65); font-size: 0.85rem; margin: 0; }

/* ---- DONATIONS ---- */
.donations-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; max-width: 900px; margin: 0 auto; }
.donation-card {
  border-radius: var(--radius-lg); border: 2px solid var(--gray-100);
  padding: 36px 28px; text-align: center; background: var(--white);
  transition: var(--transition); position: relative;
}
.donation-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-color: var(--blue); }
.donation-card.featured { border-color: var(--blue); background: var(--blue); color: var(--white); transform: scale(1.04); box-shadow: var(--shadow-lg); }
.donation-card .badge { position: absolute; top: -14px; left: 50%; transform: translateX(-50%); background: var(--gold); color: var(--gray-900); font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; padding: 4px 16px; border-radius: 99px; white-space: nowrap; }
.donation-card .tier-name { font-size: 1.5rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.12em; color: var(--gray-500); margin-bottom: 12px; }
.donation-card.featured .tier-name { color: rgba(255,255,255,0.65); }
.donation-card .amount { font-family: var(--font-display); font-size: 2.8rem; font-weight: 700; color: var(--blue); line-height: 1; margin-bottom: 8px; }
.donation-card.featured .amount { color: var(--gold-light); }
.donation-card .currency { font-size: 1rem; color: var(--gray-500); margin-bottom: 16px; }
.donation-card.featured .currency { color: rgba(255,255,255,0.7); }
.donation-card p { font-size: 1.2rem; color: var(--gray-500); margin-bottom: 24px; }
.donation-card.featured p { color: rgba(255,255,255,0.7); }
.donate-info { background: var(--blue-pale); border-radius: var(--radius-lg); padding: 32px; margin-top: 48px; max-width: 700px; margin-left: auto; margin-right: auto; }
.donate-info h4 { color: var(--blue); font-family: var(--font-display); margin-bottom: 16px; }
.donate-details { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.donate-detail { display: flex; align-items: center; gap: 10px; }
.donate-detail i { color: var(--blue); width: 20px; }
.donate-detail span { font-size: 0.98rem; color: var(--gray-700); }

/* ---- PARTNERS ---- */
.partners-strip { display: flex; flex-wrap: wrap; gap: 34px; align-items: center; justify-content: center; }
.partner-item { opacity: 5; transition: var(--transition); }
.partner-item:hover { filter: none; opacity: 1; }
.partner-item img { height: 88px; width: auto; object-fit: contain; }
.partner-item .name-fallback { font-weight: 600; color: var(--gray-500); font-size: 0.9rem; padding: 8px 20px; border: 1px solid var(--gray-300); border-radius: var(--radius); }

/* ---- TESTIMONIALS ---- */
.testimonials-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.testimonial-card {
  background: var(--white); border-radius: var(--radius-lg);
  padding: 28px; border: 1px solid var(--gray-100);
  box-shadow: var(--shadow-sm); transition: var(--transition);
  position: relative;
}
.testimonial-card::before {
  content: '\201C'; font-family: var(--font-display); font-size: 5rem;
  color: var(--blue-pale); position: absolute; top: 8px; left: 20px;
  line-height: 1; z-index: 0;
}
.testimonial-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.testimonial-card p { position: relative; z-index: 1; font-size: 0.9rem; color: var(--gray-700); font-style: italic; line-height: 1.7; margin-bottom: 20px; }
.testimonial-author { display: flex; align-items: center; gap: 12px; }
.testimonial-avatar { width: 48px; height: 48px; border-radius: 50%; overflow: hidden; background: var(--blue-pale); flex-shrink: 0; display: flex; align-items: center; justify-content: center; color: var(--blue); font-weight: 700; font-size: 1.1rem; }
.testimonial-avatar img { width: 100%; height: 100%; object-fit: cover; }
.testimonial-author-info strong { display: block; font-size: 0.9rem; color: var(--gray-900); }
.testimonial-author-info span { font-size: 0.78rem; color: var(--blue); }

/* ---- CONTACT ---- */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: start; }
.contact-info { display: flex; flex-direction: column; gap: 24px; }
.contact-item { display: flex; align-items: flex-start; gap: 16px; }
.contact-item .icon { width: 52px; height: 52px; border-radius: var(--radius); background: var(--blue-pale); display: flex; align-items: center; justify-content: center; color: var(--blue); font-size: 1rem; flex-shrink: 0; }
.contact-item h4 { font-size: 1.3rem; text-transform: uppercase; letter-spacing: 0.08em; color: white; margin-bottom: 4px; font-family: var(--font-body); font-weight: 600; }
.contact-item p, .contact-item a { font-size: 1.2rem; color: black; margin: 0; }
.contact-item a:hover { color: yellow }
.map-embed { margin-top: 24px; border-radius: var(--radius-lg); overflow: hidden; border: 1px solid var(--gray-100); }
.map-embed iframe { width: 100%; height: 240px; border: none; display: block; }
.map-placeholder { width: 100%; height: 200px; background: var(--blue-pale); display: flex; align-items: center; justify-content: center; color: var(--blue); border-radius: var(--radius-lg); }

/* ---- FOOTER ---- */
.footer { background: var(--gray-900); color: var(--white); padding: 72px 0 0; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 48px; padding-bottom: 48px; border-bottom: 1px solid rgba(255,255,255,0.08); }
.footer-brand .logo { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.footer-brand .logo img { height: 60px; }
.footer-brand .logo span { font-family: var(--font-display); font-size: 1.5rem; font-weight: 700; color: var(--white); }
.footer-brand p { color: rgba(255,255,255,0.55); font-size: 0.98rem; line-height: 1.7; margin-bottom: 20px; }
.social-links { display: flex; gap: 10px; }
.social-link { width: 50px; height: 50px; border-radius: 50%; background: rgba(255,255,255,0.08); display: flex; align-items: center; justify-content: center; color: rgba(255,255,255,0.6); font-size: 0.9rem; transition: var(--transition); }
.social-link:hover { background: var(--blue); color: var(--white); transform: translateY(-2px); }
.footer-col h4 { font-family: var(--font-body); font-size: 0.9rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.1em; color: rgba(255,255,255,0.4); margin-bottom: 20px; }
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col ul a { color: rgba(255,255,255,0.65); font-size: 0.98rem; transition: var(--transition); }
.footer-col ul a:hover { color: var(--gold-light); padding-left: 4px; }
.footer-bottom { padding: 20px 0; display: flex; align-items: center; justify-content: space-between; }
.footer-bottom p { color: rgba(255,255,255,0.35); font-size: 0.9rem; }
.footer-bottom a { color: rgba(255,255,255,0.5); font-size: 0.85rem; }
.footer-bottom a:hover { color: var(--gold-light); }

/* ---- MODALS ---- */
.modal-overlay {
  position: fixed; inset: 0; z-index: 2000;
  background: rgba(7, 32, 64, 0.75); backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center; padding: 24px;
  opacity: 0; visibility: hidden; transition: var(--transition);
}
.modal-overlay.active { opacity: 1; visibility: visible; }
.modal {
  background: var(--white); border-radius: var(--radius-xl);
  padding: 48px; max-width: 560px; width: 100%;
  box-shadow: var(--shadow-lg); position: relative;
  transform: translateY(24px) scale(0.97); transition: var(--transition);
  max-height: 90vh; overflow-y: auto;
}
.modal-overlay.active .modal { transform: translateY(0) scale(1); }
.modal-close {
  position: absolute; top: 20px; right: 20px;
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--gray-100); border: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  color: var(--gray-500); font-size: 1rem; transition: var(--transition);
}
.modal-close:hover { background: var(--gray-900); color: var(--white); }
.modal-header { margin-bottom: 28px; }
.modal-header .section-label { margin-bottom: 8px; }
.modal-header h2 { font-size: 1.8rem; margin: 0; }
.modal-header p { color: var(--gray-500); font-size: 0.88rem; margin-top: 8px; }
.modal-success {
  text-align: center; padding: 32px 0;
  display: none;   /* shown by JS when form submits successfully */
}
.modal-success i { font-size: 3rem; color: var(--success); margin-bottom: 16px; display: block; }
.modal-success h3 { margin-bottom: 8px; color: var(--gray-900); }
.modal-success p { color: var(--gray-500); font-size: 0.9rem; }

/* ---- DONATION MODAL ---- */
.donation-payment-panel {
  background: var(--blue);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  margin-bottom: 24px;
}
.donation-payment-header {
  font-size: 1rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: rgba(255,255,255,0.65);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.donation-payment-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}
.donation-pay-item {
  border-radius: var(--radius);
  padding: 12px 14px;
  cursor: default;
}
.donation-pay-mpesa {
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.18);
}
.donation-pay-bank {
  background: rgba(200,151,58,0.2);
  border: 1px solid rgba(200,151,58,0.35);
}
.pay-label {
  font-size: 0.72rem;
  color: rgba(255,255,255,0.65);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 5px;
}
.pay-value {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--white);
  font-family: var(--font-display);
  letter-spacing: 0.04em;
}
.pay-sub {
  font-size: 0.72rem;
  color: rgba(255,255,255,0.6);
  margin-top: 2px;
}
.donation-pay-note {
  font-size: 1rem;
  color: rgba(255,255,255,0.65);
  display: flex;
  align-items: flex-start;
  gap: 7px;
  margin: 0;
  line-height: 1.5;
}
.donation-pay-note i {
  color: var(--gold-light);
  flex-shrink: 0;
  margin-top: 1px;
}

/* ---- FORMS ---- */
.form-group { margin-bottom: 20px; }
.form-group label { display: block; font-size: 1rem; font-weight: 600; color: var(--gray-700); margin-bottom: 6px; text-transform: uppercase; letter-spacing: 0.05em; }
.form-control {
  width: 100%; padding: 11px 16px;
  border: 1.5px solid var(--gray-300); border-radius: var(--radius);
  font-family: var(--font-body); font-size: 0.92rem; color: var(--gray-900);
  background: var(--white); transition: var(--transition);
  outline: none;
}
.form-control:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(7,77,136,0.08); }
.form-control::placeholder { color: var(--gray-300); }
select.form-control { cursor: pointer; }
textarea.form-control { resize: vertical; min-height: 100px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-error { font-size: 0.78rem; color: var(--danger); margin-top: 4px; display: block; }

/* ---- THEMATIC AREA PAGE ---- */
.page-hero {
  padding: 200px 0 80px;
  background: linear-gradient(135deg, var(--blue-dark), var(--blue));
  position: relative; overflow: hidden;
}
.page-hero-bg { position: absolute; inset: 0; opacity: 0.2; background-size: cover; background-position: center; }
.page-hero-content { position: relative; z-index: 1; }
.page-hero h1 { color: var(--white); margin-bottom: 16px; }
.page-hero p { color: rgba(255,255,255,0.75); font-size: 1.1rem; max-width: 600px; margin-bottom: 0; }
.breadcrumb { display: flex; align-items: center; gap: 8px; margin-bottom: 16px; }
.breadcrumb a, .breadcrumb span { font-size: 0.82rem; color: rgba(255,255,255,0.55); }
.breadcrumb a:hover { color: var(--gold-light); }
.breadcrumb .sep { color: rgba(255,255,255,0.3); }
.breadcrumb .current { color: rgba(255,255,255,0.85); }

.area-meta-bar { background: var(--blue); padding: 24px 0; }
.area-meta-inner { display: flex; gap: 40px; align-items: center; }
.area-meta-item { display: flex; align-items: center; gap: 10px; color: rgba(255,255,255,0.8); font-size: 0.88rem; }
.area-meta-item i { color: var(--gold-light); }
.area-meta-item strong { color: var(--white); }

.history-block { background: var(--off-white); border-radius: var(--radius-lg); padding: 36px; border-left: 4px solid var(--blue); margin-bottom: 48px; }
.history-block h3 { color: var(--blue); margin-bottom: 12px; font-size: 1.2rem; }
.history-block p { font-size: 0.95rem; color: var(--gray-700); line-height: 1.8; margin: 0; }

.projects-section-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 28px; }
.projects-section-header h3 { font-size: 1.4rem; }
.status-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; margin-right: 6px; }
.dot-ongoing { background: #27ae60; }
.dot-completed { background: var(--blue); }
.dot-planned { background: #f39c12; }

/* ---- PROJECT DETAIL PAGE ---- */
.article-hero { padding: 160px 0 64px; background: linear-gradient(135deg, var(--blue-dark), var(--blue)); }
.article-content { max-width: 1000px; margin: 0 auto; }
.article-content h1 { font-size: clamp(1.8rem, 4vw, 2.8rem); color: var(--white); margin-bottom: 16px; }
.article-meta { display: flex; flex-wrap: wrap; gap: 20px; color: rgba(255,255,255,0.65); font-size: 0.85rem; }
.article-meta span { display: flex; align-items: center; gap: 6px; }
.article-meta i { color: var(--gold-light); }
.article-body { padding: 64px 0; }
.article-body .prose { max-width: 1000px; margin: 0 auto; font-size: 1.3rem; line-height: 1.85; color: var(--gray-700); }
.article-body .prose p { margin-bottom: 20px; }
.article-cover { max-width: 1200px; margin: 0 auto 48px; border-radius: var(--radius-xl); overflow: hidden; box-shadow: var(--shadow-lg); margin-top: -64px; position: relative; z-index: 2; }
.article-cover img { width: 150%; height: 540px; object-fit: cover; }

/* ---- TABS ---- */
.tabs { display: flex; gap: 4px; background: var(--gray-50); border-radius: var(--radius); padding: 4px; margin-bottom: 32px; width: fit-content; }
.tab-btn { padding: 10px 24px; border-radius: 6px; border: none; background: none; font-family: var(--font-body); font-size: 0.88rem; font-weight: 500; color: var(--gray-500); cursor: pointer; transition: var(--transition); }
.tab-btn.active { background: var(--white); color: var(--blue); box-shadow: var(--shadow-sm); }
.tab-btn:hover:not(.active) { color: var(--gray-700); }
.tab-content { display: none; }
.tab-content.active { display: block; }

/* ---- LIGHTBOX ---- */
.lightbox {
  position: fixed; inset: 0; z-index: 3000; background: rgba(0,0,0,0.95);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; visibility: hidden; transition: var(--transition);
}
.lightbox.active { opacity: 1; visibility: visible; }
.lightbox img { max-width: 90vw; max-height: 85vh; object-fit: contain; border-radius: var(--radius); }
.lightbox-close { position: absolute; top: 20px; right: 24px; background: none; border: none; color: white; font-size: 1.8rem; cursor: pointer; opacity: 0.7; }
.lightbox-close:hover { opacity: 1; }

/* ---- WHATSAPP FLOAT ---- */
.whatsapp-float {
  position: fixed; bottom: 92px; right: 32px; z-index: 998;
  width: 52px; height: 52px; border-radius: 50%;
  background: #25d366;
  display: flex; align-items: center; justify-content: center;
  color: var(--white); font-size: 1.5rem;
  box-shadow: 0 4px 20px rgba(37,211,102,0.45);
  transition: var(--transition);
  animation: waBounce 2.5s ease-in-out 3s 3;
}
.whatsapp-float:hover {
  background: #1ebe5d;
  transform: scale(1.1) translateY(-2px);
  box-shadow: 0 8px 28px rgba(37,211,102,0.55);
}
@keyframes waBounce {
  0%, 100% { transform: translateY(0); }
  40%       { transform: translateY(-8px); }
  60%       { transform: translateY(-4px); }
}

/* ---- BACK TO TOP ---- */
.back-to-top {
  position: fixed; bottom: 32px; right: 32px; z-index: 999;
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--blue); color: var(--white); border: none;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; box-shadow: var(--shadow-md);
  opacity: 0; visibility: hidden; transition: var(--transition);
  font-size: 1rem;
}
.back-to-top.visible { opacity: 1; visibility: visible; }
.back-to-top:hover { background: var(--blue-light); transform: translateY(-3px); }

/* ---- TEXT UTILITIES ---- */
.text-center { text-align: center; }
.text-left { text-align: left; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.mt-8 { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-48 { margin-top: 48px; }

/* ---- ANIMATIONS ---- */
/* Defined BEFORE prefers-reduced-motion so the override works correctly */
.fade-in { opacity: 0; transform: translateY(24px); transition: opacity 0.6s ease, transform 0.6s ease; }
.fade-in.visible { opacity: 1; transform: translateY(0); }
.stagger-1 { transition-delay: 0.1s; }
.stagger-2 { transition-delay: 0.2s; }
.stagger-3 { transition-delay: 0.3s; }
.stagger-4 { transition-delay: 0.4s; }

/* Respect user's motion preference */
@media (prefers-reduced-motion: reduce) {
  .area-card, .project-card { animation: none !important; }
  .whatsapp-float { animation: none !important; }
  .fade-in { opacity: 1 !important; transform: none !important; transition: none !important; }
  .hero-video-bg { transition: none !important; }
  * { scroll-behavior: auto !important; }
}

/* ---- RESPONSIVE ---- */

/* ── Page layout: mobile-first (thematic area + project detail) ── */
.page-layout { display: flex; flex-direction: column; gap: 40px; }
.page-main { min-width: 0; }
.page-sidebar { width: 100%; }
/* Inside page-main prose doesn't need its own max-width — column is already constrained */
.page-main .article-body .prose { max-width: none; margin: 0; }

@media (min-width: 900px) {
  .page-layout { display: grid; grid-template-columns: 1fr 300px; gap: 56px; align-items: start; }
  .page-sidebar { position: sticky; top: 96px; }
}

/* Tabs — horizontal scroll, no clipping */
.tabs { max-width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }
@media (max-width: 520px) {
  .tabs { width: 100%; }
  .tab-btn { flex-shrink: 0; padding: 9px 14px; font-size: 0.78rem; }
}

/* Article meta */
.article-meta { flex-wrap: wrap; }

/* Meta bar */
@media (max-width: 600px) {
  .area-meta-inner { gap: 10px 16px; }
  .area-meta-item { font-size: 0.8rem; }
}

/* On mobile place video mute on the left so it doesn't stack with WhatsApp */
@media (max-width: 768px) {
  .hero-video-mute { right: auto; left: 32px; bottom: 32px; }
}

@media (max-width: 1024px) {
  .areas-grid { grid-template-columns: repeat(2, 1fr); }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .projects-grid { grid-template-columns: repeat(2, 1fr); }
  .testimonials-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
}

@media (max-width: 768px) {
  .section { padding: 64px 0; }
  .hero-content { grid-template-columns: 1fr; gap: 48px; padding: 180px 24px 64px; }
  .hero-visual { display: none; }
  .hero-stats { grid-template-columns: repeat(3, 1fr); }
  .about-grid { grid-template-columns: 1fr; gap: 48px; }
  .about-image-wrap { display: none; }
  .volunteer-grid { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; gap: 40px; }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 160px; }
  .gallery-item:nth-child(1) { grid-column: span 1; grid-row: span 1; }
  .gallery-item:nth-child(5) { grid-column: span 1; }
  .donations-grid { grid-template-columns: 1fr; max-width: 360px; margin-left: auto; margin-right: auto; }
  .donation-card.featured { transform: none; }
  .donate-details { grid-template-columns: 1fr; }
  .navbar-links {
    display: none; position: fixed; inset: 0; top: 72px;
    flex-direction: column; background: var(--blue-dark);
    padding: 24px; gap: 8px; z-index: 999;
    overflow-y: auto;
  }
  .navbar-links.open { display: flex; }
  .navbar-links a { padding: 14px 16px; font-size: 1rem; border-radius: var(--radius); }
  .nav-toggle { display: flex; flex-direction: column; justify-content: center; }
  .modal { padding: 32px 24px; }
  .form-grid { grid-template-columns: 1fr; }
  .areas-grid { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .projects-grid { grid-template-columns: 1fr; }
  .testimonials-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; gap: 8px; text-align: center; }
  .values-grid { grid-template-columns: 1fr; }
  .page-hero { padding: 150px 0 56px; }
  .article-hero { padding: 180px 0 70px; }
  .article-cover img { height: 300px; }
  .area-card, .project-card { animation: none; }
  h1 { font-size: clamp(1.8rem, 6vw, 2.8rem); }
  h2 { font-size: clamp(1.5rem, 5vw, 2.2rem); }
}

@media (max-width: 480px) {
  .hero-stats { grid-template-columns: repeat(2, 1fr); }
  .gallery-grid { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: 1fr; }
  .btn { padding: 11px 22px; font-size: 0.85rem; }
  .projects-grid { grid-template-columns: 1fr; }
  .areas-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-badge { display: none; }
}

/* ---- PRINT STYLES ---- */
@media print {
  .navbar, .whatsapp-float, .back-to-top, .hero-video-mute,
  .scroll-indicator, .modal-overlay, .lightbox,
  .hero-actions, .hero-visual, .about-image-wrap,
  .nav-toggle, .footer-col:not(:first-child) { display: none !important; }

  body { font-size: 12pt; color: #000; background: #fff; line-height: 1.5; }
  .container { max-width: 100%; padding: 0 12pt; }
  .section { padding: 16pt 0; }

  .hero { min-height: auto; padding: 20pt 0; background: #074d88 !important; print-color-adjust: exact; }
  .hero-text h1 { font-size: 22pt; color: #fff !important; }
  .hero-stats { display: none; }

  .section-blue { background: #074d88 !important; print-color-adjust: exact; }
  .areas-grid, .projects-grid { grid-template-columns: repeat(2, 1fr); gap: 8pt; }
  .area-card, .project-card { break-inside: avoid; box-shadow: none; border: 1pt solid #ccc; }
  .gallery-grid, .testimonials-grid { display: none; }

  a[href^="http"]::after { content: " (" attr(href) ")"; font-size: 8pt; color: #666; }
  a[href^="mailto"]::after { content: " (" attr(href) ")"; font-size: 8pt; color: #666; }
  a[href^="tel"]::after { content: " (" attr(href) ")"; font-size: 8pt; color: #666; }
}

