/* Responsive layout correction shared by every public page. */
*, *::before, *::after { box-sizing: border-box; }
html { width: 100%; max-width: 100%; min-width: 0; overflow-x: clip; }
body { width: 100%; max-width: 100%; min-width: 0; margin: 0; overflow-x: clip; }
img, video, iframe, canvas, svg { max-width: 100%; }
.container { width: min(100% - 48px, 1240px); max-width: 1240px; min-width: 0; margin-left: auto; margin-right: auto; }
header, footer, main, section, nav, .top-ticker-bar, .hero-wrap { max-width: 100%; }
footer { width: 100%; }
.footer-grid { min-width: 0; }
.footer-col, .footer-bottom { min-width: 0; overflow-wrap: anywhere; }
@media (max-width: 768px) {
  html, body { width: 100% !important; max-width: 100% !important; min-width: 0 !important; overflow-x: clip !important; }
  body > *, header, footer, main, section, nav, .top-ticker-bar, .hero-wrap { width: 100%; max-width: 100%; min-width: 0; }
  .container { width: 100% !important; max-width: 100% !important; min-width: 0 !important; padding-left: 18px !important; padding-right: 18px !important; }
  .header-wrap { width: 100% !important; max-width: 100% !important; min-width: 0 !important; }
  .footer-grid { grid-template-columns: minmax(0, 1fr) !important; gap: 28px !important; }
  .footer-col, .footer-bottom { width: 100%; min-width: 0; }
  .footer-contact li { min-width: 0; overflow-wrap: anywhere; }
  .footer-contact li a, .footer-links a { overflow-wrap: anywhere; }
  .hero-slider-bg, .hero-overlay, .hero-content { width: 100% !important; max-width: 100% !important; min-width: 0 !important; }
  .hero-content h1 { overflow-wrap: anywhere; }
  .btn-group { flex-wrap: wrap; justify-content: center; }
  table { display: block; max-width: 100%; overflow-x: auto; }
  input, select, textarea, button { max-width: 100%; }
}
@media (max-width: 420px) {
  .container { padding-left: 14px !important; padding-right: 14px !important; }
  .footer-grid { gap: 22px !important; }
}


/* Responsive refinement: keep every public page inside the phone viewport. */
html, body { width:100%; max-width:100%; min-width:320px; margin:0; overflow-x:hidden; }
body { position:relative; }
body > *, header, footer, main, section, .top-ticker-bar, .hero-wrap { max-width:100%; min-width:0; }
.container { width:100%; max-width:1240px; margin-inline:auto; }
img, video, iframe { max-width:100%; }
@media (max-width: 768px) {
  html, body { width:100% !important; max-width:100% !important; min-width:320px !important; overflow-x:hidden !important; }
  body > *, header, footer, main, section, .top-ticker-bar, .hero-wrap { width:100%; max-width:100%; min-width:0; }
  .container { width:100% !important; max-width:100% !important; min-width:0 !important; padding-left:16px !important; padding-right:16px !important; margin-left:auto !important; margin-right:auto !important; }
  .header-wrap { display:flex !important; flex-direction:row !important; justify-content:space-between !important; align-items:center !important; gap:9px !important; width:100% !important; padding:10px 0 !important; }
  .logo { display:flex !important; align-items:center !important; gap:9px !important; flex:1 1 auto !important; min-width:0 !important; max-width:calc(100% - 132px) !important; }
  .logo-img-box { flex:0 0 42px !important; width:42px !important; height:42px !important; border-radius:11px !important; }
  .logo-text-wrap { min-width:0 !important; overflow:hidden; }
  .logo-title { font-size:clamp(1rem,4.4vw,1.3rem) !important; line-height:1.15 !important; overflow-wrap:anywhere; }
  .logo-subtitle { font-size:clamp(.48rem,2.3vw,.65rem) !important; letter-spacing:.8px !important; line-height:1.15 !important; overflow-wrap:anywhere; }
  .nav-actions { flex:0 0 auto !important; min-width:0 !important; }
  .menu-trigger-btn { display:flex !important; align-items:center !important; justify-content:center !important; gap:6px !important; white-space:nowrap !important; padding:9px 11px !important; font-size:.77rem !important; max-width:128px !important; }
  .nav-dropdown { width:min(320px, calc(100vw - 24px)) !important; max-width:calc(100vw - 24px) !important; right:0 !important; top:calc(100% + 8px) !important; max-height:70vh; overflow-y:auto; }
  .top-ticker-bar { width:100% !important; height:38px !important; }
  .ticker-badge { padding:0 10px !important; font-size:.72rem !important; flex:0 0 auto; }
  .ticker-content { font-size:.78rem !important; animation-duration:26s !important; }
  .hero-wrap { width:100% !important; min-height:600px !important; height:auto !important; }
  .hero-slider-bg, .hero-overlay { inset:0 !important; width:100% !important; height:100% !important; }
  .hero-content { width:100% !important; max-width:100% !important; min-width:0 !important; padding:65px 16px 58px !important; margin:0 auto !important; }
  .hero-tag { max-width:100% !important; white-space:normal !important; justify-content:center; font-size:.78rem !important; padding:8px 13px !important; line-height:1.45; }
  .hero-content h1 { font-size:clamp(2rem,8vw,2.65rem) !important; line-height:1.18 !important; letter-spacing:-.5px !important; overflow-wrap:anywhere; }
  .hero-content p { font-size:clamp(1rem,4vw,1.12rem) !important; line-height:1.7 !important; margin-bottom:28px !important; }
  .btn-group { display:flex !important; flex-direction:column !important; align-items:stretch !important; justify-content:center !important; gap:12px !important; width:min(100%,340px); margin-inline:auto; }
  .btn-group a, .btn-group button { width:100% !important; justify-content:center; text-align:center; }
  .section-box { padding-top:58px !important; padding-bottom:58px !important; }
  .section-header { margin-bottom:30px !important; padding-inline:4px; }
  .section-title { font-size:clamp(1.65rem,6vw,2.15rem) !important; line-height:1.3 !important; overflow-wrap:anywhere; }
  .hero-wrap, .page-banner, .custom-blood-banner, .section-box, .stats-wrap, footer { min-width:0 !important; }
  .about-grid, .leaders-grid, .info-grid, .events-grid, .showcase-grid, .video-gallery-grid, .mega-projects-grid, .activities-grid, .donation-box-wrap, .footer-grid { grid-template-columns:minmax(0,1fr) !important; }
  .gallery-grid { grid-template-columns:repeat(2,minmax(0,1fr)) !important; gap:12px !important; }
  .stats-grid { grid-template-columns:repeat(2,minmax(0,1fr)) !important; gap:12px !important; }
  .stat-item { min-width:0; padding:20px 12px !important; border-radius:16px !important; }
  .stat-number-wrapper, .stat-number { font-size:clamp(1.9rem,7vw,2.6rem) !important; }
  .stat-item p { font-size:.9rem !important; line-height:1.45; }
  .page-banner h1 { font-size:clamp(1.8rem,7vw,2.35rem) !important; line-height:1.25 !important; }
  .page-banner p { font-size:.98rem !important; }
  .event-img-box, .act-img-box, .news-img-box { height:190px !important; }
  .event-img-box img, .act-img-box img, .news-img-box img, .gallery-item img, .gallery-card img, .showcase-img-wrap img, .member-photo-wrap img { display:block; width:100%; max-width:100%; object-fit:cover !important; object-position:center center; }
  .gallery-item { height:185px !important; border-radius:14px !important; }
  .filter-nav { display:flex; flex-wrap:wrap; gap:8px; }
  .filter-nav .tab-btn { width:auto !important; flex:1 1 135px; }
  .search-control-panel { flex-direction:column !important; align-items:stretch !important; gap:12px; }
  .search-field-box { width:100% !important; min-width:0 !important; }
  .donor-table-wrapper, .table-scroll { max-width:100%; overflow-x:auto; -webkit-overflow-scrolling:touch; }
  .donor-table { min-width:720px; }
  .footer-grid { gap:24px !important; }
  .footer-col, .footer-bottom { width:100%; min-width:0; overflow-wrap:anywhere; }
  .footer-contact li { align-items:flex-start !important; overflow-wrap:anywhere; }
  .footer-contact li a, .footer-links a { overflow-wrap:anywhere; }
  input, select, textarea, button { max-width:100%; }
}
@media (max-width: 390px) {
  .container { padding-left:13px !important; padding-right:13px !important; }
  .logo { max-width:calc(100% - 116px) !important; }
  .logo-img-box { flex-basis:38px !important; width:38px !important; height:38px !important; }
  .menu-trigger-btn { max-width:112px !important; padding:8px 8px !important; font-size:.7rem !important; }
  .gallery-grid { grid-template-columns:1fr !important; }
  .gallery-item { height:210px !important; }
  .stats-grid { gap:9px !important; }
  .stat-item { padding:17px 8px !important; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior:auto !important; animation-duration:.01ms !important; animation-iteration-count:1 !important; transition-duration:.01ms !important; }
}


/* Final responsive polish for mobile headers, hero, media and impact counters. */
@media (max-width: 768px) {
  header { width:100% !important; }
  .header-wrap { min-height:64px !important; }
  .logo-title { font-size:clamp(1rem,4.3vw,1.2rem) !important; line-height:1.15 !important; }
  .logo-subtitle { font-size:clamp(.46rem,2vw,.6rem) !important; letter-spacing:.65px !important; }
  .menu-trigger-btn { min-height:40px; }
  .hero-wrap { min-height:560px !important; }
  .hero-content { padding-top:48px !important; padding-bottom:44px !important; }
  .hero-content h1 { font-size:clamp(1.85rem,7.3vw,2.45rem) !important; }
  .hero-content p { font-size:clamp(.98rem,3.8vw,1.08rem) !important; }
  .stats-wrap { padding:52px 0 !important; }
  .stat-item { position:relative; overflow:hidden; border:1px solid rgba(245,158,11,.22) !important; background:linear-gradient(145deg,rgba(255,255,255,.075),rgba(255,255,255,.025)) !important; box-shadow:0 9px 22px rgba(0,0,0,.13); }
  .stat-item::before { content:""; position:absolute; inset:0 auto 0 0; width:3px; background:linear-gradient(180deg,#fbbf24,#d97706); opacity:.9; }
  .stat-icon { display:block; margin:0 auto 8px; color:#fbbf24; font-size:1.35rem; }
  .stat-number { display:inline-block; font-variant-numeric:tabular-nums; text-shadow:0 3px 18px rgba(245,158,11,.18); }
  .stat-item p { margin:6px 0 0; }
  .event-img-box img, .act-img-box img, .news-img-box img,
  .gallery-item img, .gallery-card img, .showcase-img-wrap img,
  .member-photo-wrap img { width:100% !important; max-width:100% !important; height:100% !important; object-fit:cover !important; }
  .showcase-img-wrap video { display:block; width:100% !important; max-width:100% !important; height:100% !important; object-fit:cover !important; }
  .about-img-wrap video { width:100% !important; height:auto !important; max-height:360px; object-fit:contain !important; }
  .section-box { overflow:hidden; }
}
@media (min-width: 769px) {
  .stats-wrap { padding:72px 0; }
  .stat-item { background:linear-gradient(145deg,rgba(255,255,255,.055),rgba(255,255,255,.018)); border-color:rgba(245,158,11,.16); }
  .stat-icon { color:#fbbf24; }
}
@media (max-width: 390px) {
  .header-wrap { gap:6px !important; }
  .logo { gap:7px !important; max-width:calc(100% - 108px) !important; }
  .logo-title { font-size:1rem !important; }
  .menu-trigger-btn { padding:8px 7px !important; font-size:.68rem !important; gap:4px !important; }
  .hero-wrap { min-height:540px !important; }
  .stats-grid { gap:8px !important; }
  .stat-number { font-size:clamp(1.7rem,6.7vw,2.3rem) !important; }
  .stat-item p { font-size:.82rem !important; }
}

/* Preserve image proportions by default; fixed media cards keep their explicit crop box. */
img { height:auto; }
.logo-img, .event-img-box img, .act-img-box img, .news-img-box img,
.gallery-item img, .gallery-card img, .showcase-img-wrap img, .member-photo-wrap img,
.banner-image-bg { height:100%; }
@keyframes statNumberPop {
  from { opacity:.35; transform:translateY(10px) scale(.94); }
  to { opacity:1; transform:translateY(0) scale(1); }
}
.stat-item.reveal-visible .stat-number { animation:statNumberPop .65s cubic-bezier(.2,.75,.25,1) both; }
@media (prefers-reduced-motion: reduce) {
  .stat-item.reveal-visible .stat-number { animation:none !important; }
}


/* === Shared site navigation and targeted layout refinements === */
header { overflow:visible !important; }
.header-wrap { flex-wrap:nowrap !important; gap:16px !important; }
.nav-actions { flex:0 0 auto !important; }
.menu-trigger-btn { display:none !important; }
.site-primary-nav { display:block; width:100%; border-top:1px solid rgba(245,158,11,.18); background:rgba(5,8,17,.96); }
.site-primary-nav-inner { display:flex; align-items:center; justify-content:center; gap:5px; padding-top:7px; padding-bottom:8px; overflow-x:auto; scrollbar-width:none; }
.site-primary-nav-inner::-webkit-scrollbar { display:none; }
.site-primary-nav a { display:inline-flex; align-items:center; justify-content:center; gap:7px; flex:0 0 auto; padding:8px 10px; border-radius:999px; color:#cbd5e1; font-family:'Anek Bangla',sans-serif; font-size:.88rem; font-weight:600; line-height:1.25; text-decoration:none; white-space:nowrap; transition:background .2s ease,color .2s ease,transform .2s ease; }
.site-primary-nav a i { color:#fbbf24; font-size:.88rem; }
.site-primary-nav a:hover, .site-primary-nav a.active { color:#111827; background:linear-gradient(110deg,#fde68a,#f59e0b); }
.site-primary-nav a:hover i, .site-primary-nav a.active i { color:#111827; }

/* Map remains a map even when old CMS rows contain an incorrect video type. */
.map-wrapper { grid-template-columns:minmax(0,1.4fr) minmax(0,1fr); align-items:stretch; }
.map-iframe-box { min-width:0; min-height:420px; overflow:hidden; border-radius:20px; }
.map-iframe-box iframe { display:block; width:100%; height:100%; min-height:420px; border:0; }

/* A balanced, premium impact-counter section with aligned digits and suffix. */
.stats-wrap { padding:76px 0 !important; background:radial-gradient(ellipse at 50% 0%,rgba(245,158,11,.10),transparent 55%),linear-gradient(135deg,#070d1a 0%,#101827 52%,#070d1a 100%) !important; }
.stats-grid { align-items:stretch; gap:clamp(14px,2.1vw,28px) !important; }
.stat-item { position:relative; display:flex; flex-direction:column; align-items:center; justify-content:center; min-width:0; min-height:190px; padding:28px 18px 25px !important; overflow:hidden; isolation:isolate; border:1px solid rgba(251,191,36,.22) !important; border-radius:22px !important; background:linear-gradient(145deg,rgba(255,255,255,.085),rgba(255,255,255,.025)) !important; box-shadow:0 16px 38px rgba(0,0,0,.22),inset 0 1px 0 rgba(255,255,255,.05); transition:transform .28s ease,border-color .28s ease,box-shadow .28s ease; }
.stat-item::before { content:""; position:absolute; z-index:-1; width:180px; height:180px; top:-105px; right:-75px; border-radius:50%; background:radial-gradient(circle,rgba(251,191,36,.22),transparent 70%); pointer-events:none; }
.stat-item::after { content:""; position:absolute; left:18px; right:18px; bottom:0; height:2px; border-radius:2px; background:linear-gradient(90deg,transparent,#fbbf24,transparent); opacity:.55; }
.stat-item:hover { transform:translateY(-6px); border-color:rgba(251,191,36,.65) !important; box-shadow:0 22px 46px rgba(0,0,0,.30),0 0 24px rgba(245,158,11,.08); }
.stat-icon { display:grid !important; place-items:center; width:46px; height:46px; margin:0 auto 13px !important; border:1px solid rgba(251,191,36,.24); border-radius:15px; background:rgba(245,158,11,.12); color:#fbbf24 !important; font-size:1.18rem !important; }
.stat-number-wrapper { display:flex !important; align-items:baseline !important; justify-content:center !important; gap:3px; width:100%; margin:0 0 8px !important; line-height:1 !important; white-space:nowrap; }
.stat-number { display:inline-block; margin:0 !important; font-size:clamp(2.65rem,4.2vw,3.45rem) !important; line-height:1 !important; letter-spacing:-.035em; font-weight:800 !important; font-family:'Outfit','Anek Bangla',sans-serif !important; color:#ffc12f !important; font-variant-numeric:tabular-nums; text-shadow:0 4px 20px rgba(245,158,11,.16); }
.stat-suffix { display:inline-block; position:static !important; margin:0 !important; color:#fff1bf !important; font-family:'Outfit','Anek Bangla',sans-serif; font-size:1.35rem !important; line-height:1 !important; font-weight:800 !important; vertical-align:baseline; }
.stat-item p { margin:0 !important; color:#b9c9dc !important; font-size:1.08rem !important; line-height:1.45 !important; font-weight:700 !important; }
@keyframes statCountGlow { 0%{filter:brightness(.82);transform:translateY(5px)} 70%{filter:brightness(1.12);transform:translateY(-1px)} 100%{filter:brightness(1);transform:translateY(0)} }
.stat-item.reveal-visible .stat-number { animation:statCountGlow .8s cubic-bezier(.2,.75,.25,1) both !important; }

@media (max-width:900px) {
  .menu-trigger-btn { display:inline-flex !important; align-items:center; justify-content:center; min-height:42px; padding:9px 14px !important; gap:7px !important; }
  .site-primary-nav { display:none; border-top:1px solid rgba(245,158,11,.22); box-shadow:0 14px 25px rgba(0,0,0,.22); }
  .site-primary-nav.open { display:block; }
  .site-primary-nav-inner { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:6px; padding:12px 16px 15px; overflow:visible; }
  .site-primary-nav a { justify-content:flex-start; min-width:0; white-space:normal; padding:10px 12px; border:1px solid rgba(255,255,255,.06); border-radius:12px; background:rgba(255,255,255,.035); font-size:.88rem; }
  .site-primary-nav a:hover,.site-primary-nav a.active { border-color:rgba(251,191,36,.38); }
  .map-wrapper { grid-template-columns:minmax(0,1fr) !important; gap:0 !important; }
  .map-iframe-box { min-height:290px !important; height:290px !important; border-radius:18px 18px 0 0; }
  .map-iframe-box iframe { min-height:290px !important; }
  .map-details { padding:28px 22px !important; }
  .stats-wrap { padding:54px 0 !important; }
  .stat-item { min-height:158px; padding:22px 12px 20px !important; }
  .stat-icon { width:40px; height:40px; margin-bottom:10px !important; }
  .stat-number { font-size:clamp(2rem,7.2vw,2.75rem) !important; }
  .stat-suffix { font-size:1.05rem !important; }
  .stat-item p { font-size:.92rem !important; }
}
@media (max-width:768px) {
  html, body { width:100% !important; max-width:100% !important; min-width:0 !important; overflow-x:hidden !important; }
  body { position:relative; }
  body > header, body > section, body > main, body > footer, body > div { width:100% !important; max-width:100% !important; min-width:0 !important; }
  .container { width:100% !important; max-width:100% !important; min-width:0 !important; padding-left:16px !important; padding-right:16px !important; }
  .header-wrap { display:flex !important; width:100% !important; min-width:0 !important; gap:8px !important; padding:10px 0 !important; }
  .logo { flex:1 1 auto !important; min-width:0 !important; max-width:calc(100% - 118px) !important; gap:9px !important; }
  .logo-img-box { flex:0 0 42px !important; width:42px !important; height:42px !important; }
  .logo-text-wrap { min-width:0 !important; }
  .logo-title { font-size:clamp(1rem,4.2vw,1.22rem) !important; overflow-wrap:anywhere; }
  .logo-subtitle { font-size:clamp(.46rem,1.9vw,.62rem) !important; letter-spacing:.7px !important; overflow-wrap:anywhere; }
  .nav-actions { flex:0 0 auto !important; }
  .menu-trigger-btn { max-width:116px !important; padding:8px 9px !important; font-size:.75rem !important; }
  .top-ticker-bar { width:100% !important; max-width:100% !important; }
  .hero-wrap { width:100% !important; max-width:100% !important; min-width:0 !important; min-height:540px !important; }
  .hero-content { width:100% !important; max-width:100% !important; min-width:0 !important; padding-left:16px !important; padding-right:16px !important; }
  .hero-content h1 { font-size:clamp(1.9rem,7vw,2.55rem) !important; line-height:1.2 !important; overflow-wrap:anywhere; }
  .map-section { padding:52px 0 60px !important; }
  .map-wrapper { width:100% !important; min-width:0 !important; }
  .map-iframe-box { width:100% !important; }
  .stats-grid { grid-template-columns:repeat(2,minmax(0,1fr)) !important; gap:12px !important; }
  .gallery-grid { grid-template-columns:repeat(2,minmax(0,1fr)) !important; }
  .footer-grid { grid-template-columns:minmax(0,1fr) !important; }
  .footer-bottom p { text-align:center; line-height:1.7; }
  table { max-width:100%; }
  .table-scroll,.donor-table-wrapper { max-width:100%; overflow-x:auto; -webkit-overflow-scrolling:touch; }
}
@media (max-width:390px) {
  .site-primary-nav-inner { grid-template-columns:minmax(0,1fr) !important; }
  .logo { max-width:calc(100% - 106px) !important; }
  .logo-img-box { flex-basis:38px !important; width:38px !important; height:38px !important; }
  .menu-trigger-btn { max-width:104px !important; padding:8px 7px !important; font-size:.7rem !important; }
  .stat-item { min-height:145px; padding:18px 8px 16px !important; }
  .stat-number { font-size:clamp(1.8rem,7.4vw,2.25rem) !important; }
}
@media (prefers-reduced-motion:reduce) {
  .stat-item.reveal-visible .stat-number { animation:none !important; }
}
