/* ============================================
   RHPT India - Rural Health Progress Trust
   Custom Stylesheet
   ============================================ */

/* ---------- CSS Custom Properties ---------- */
:root {
  --primary: #0d9488;
  --primary-dark: #0a7c72;
  --primary-light: #14b8a6;
  --red: #e74c3c;
  --blue: #3498db;
  --orange: #f39c12;
  --green: #27ae60;

  --bg-white: #ffffff;
  --bg-light: #f8f9fa;
  --bg-achievement: #0d9488;
  --bg-footer: #1a2332;
  --bg-top-bar: #333333;

  --text-primary: #333333;
  --text-secondary: #666666;
  --text-light: #999999;
  --text-white: #ffffff;
  --text-heading: #222222;

  --border-light: #eeeeee;
  --border-card: #e0e0e0;

  --font-body: 'Open Sans', Arial, sans-serif;
  --font-heading: 'Montserrat', 'Open Sans', Arial, sans-serif;

  --container-max: 1200px;
  --header-height: 70px;
}

/* ---------- Reset & Base ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

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

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

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: var(--primary-dark);
}

ul {
  list-style: none;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  color: var(--text-heading);
  line-height: 1.3;
}

/* ---------- Utility ---------- */
.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 15px;
}

.section-header {
  text-align: center;
  margin-bottom: 40px;
}

.section-header h2 {
  font-size: 28px;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 10px;
}

.section-divider {
  width: 60px;
  height: 3px;
  background: var(--primary);
  margin: 0 auto;
}

/* ============================================
   1. TOP CONTACT BAR
   ============================================ */
.top-bar {
  background: var(--bg-top-bar);
  color: var(--text-white);
  padding: 8px 0;
  font-size: 13px;
}

.top-bar-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.top-bar-contact {
  display: flex;
  gap: 20px;
}

.top-bar-contact span {
  display: flex;
  align-items: center;
  gap: 6px;
}

.top-bar-contact i {
  color: var(--primary-light);
}

.top-bar-social {
  display: flex;
  gap: 12px;
}

.top-bar-social a {
  color: var(--text-white);
  font-size: 14px;
  transition: color 0.3s ease;
}

.top-bar-social a:hover {
  color: var(--primary-light);
}

/* ============================================
   2. NAVIGATION HEADER
   ============================================ */
.site-header {
  background: var(--bg-white);
  position: sticky;
  top: 0;
  z-index: 1000;
  transition: box-shadow 0.3s ease;
  border-bottom: 1px solid var(--border-light);
}

.site-header.scrolled {
  box-shadow: 0 2px 15px rgba(0, 0, 0, 0.1);
}

.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: var(--header-height);
}

.logo {
  display: flex;
  align-items: center;
  text-decoration: none;
}

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

.nav-menu {
  display: flex;
  gap: 5px;
}

.nav-menu li a {
  display: block;
  padding: 8px 16px;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  border-radius: 4px;
  transition: all 0.3s ease;
}

.nav-menu li a:hover,
.nav-menu li a.active {
  color: var(--primary);
  background: rgba(13, 148, 136, 0.08);
}

.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 24px;
  color: var(--text-primary);
  cursor: pointer;
  padding: 5px;
}

/* ============================================
   3. HERO IMAGE SLIDER
   ============================================ */
.hero-slider {
  position: relative;
  overflow: hidden;
  background: #e8e8e8;
}

.slider-container {
  position: relative;
  width: 100%;
  max-height: 520px;
  overflow: hidden;
}

.slides {
  position: relative;
  width: 100%;
  height: 520px;
}

.slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 0.8s ease;
}

.slide.active {
  opacity: 1;
}

.slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.slider-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.8);
  border: none;
  width: 45px;
  height: 45px;
  border-radius: 50%;
  font-size: 18px;
  color: var(--text-primary);
  cursor: pointer;
  z-index: 10;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.slider-btn:hover {
  background: var(--primary);
  color: var(--text-white);
}

.slider-prev {
  left: 20px;
}

.slider-next {
  right: 20px;
}

.slider-dots {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
  z-index: 10;
}

.dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: background 0.3s ease;
}

.dot.active {
  background: var(--primary);
}

/* ============================================
   4. ABOUT THE NGO
   ============================================ */
.about-section {
  padding: 70px 0;
  background: var(--bg-light);
}

.about-content {
  display: flex;
  gap: 40px;
  align-items: flex-start;
}

.about-text {
  flex: 1;
}

.about-text p {
  color: var(--text-secondary);
  margin-bottom: 15px;
  font-size: 15px;
  line-height: 1.8;
}

.about-icons {
  flex: 0 0 320px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 25px;
  justify-items: center;
}

.icon-box-full {
  grid-column: 1 / -1;
}

.icon-box {
  text-align: center;
  width: 140px;
}

.icon-circle {
  width: 75px;
  height: 75px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 12px;
  font-size: 28px;
  color: var(--text-white);
  transition: transform 0.3s ease;
}

.icon-circle:hover {
  transform: scale(1.1);
}

.icon-circle.green {
  background: var(--green);
}

.icon-circle.red {
  background: var(--red);
}

.icon-circle.teal {
  background: var(--primary);
}

.icon-box h4 {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

/* ============================================
   5. OUR MISSION
   ============================================ */
.mission-section {
  padding: 70px 0;
  background: var(--bg-white);
}

.mission-content {
  display: flex;
  gap: 50px;
  align-items: center;
}

.mission-gallery {
  flex: 1;
}

.mission-gallery img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  object-fit: cover;
}

.mission-text {
  flex: 1;
}

.mission-text p {
  color: var(--text-secondary);
  font-size: 15px;
  line-height: 1.8;
}

/* ============================================
   6. OUR VISION
   ============================================ */
.vision-section {
  padding: 70px 0;
  background: var(--bg-light);
}

.vision-content {
  display: flex;
  gap: 50px;
  align-items: center;
}

.vision-text {
  flex: 1;
}

.vision-text p {
  color: var(--text-secondary);
  font-size: 15px;
  line-height: 1.8;
  margin-bottom: 15px;
}

.vision-image {
  flex: 1;
}

.vision-image img {
  width: 100%;
  height: 350px;
  object-fit: cover;
  border-radius: 8px;
}

/* ============================================
   7. POPULAR EVENTS
   ============================================ */
.events-section {
  padding: 70px 0;
  background: var(--bg-white);
}

.events-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.event-card {
  background: var(--bg-white);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 3px 15px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.event-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
}

.event-image img {
  width: 100%;
  height: 220px;
  object-fit: cover;
}

.event-body {
  padding: 20px;
}

.event-body h3 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 10px;
  color: var(--text-heading);
}

.event-body p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ============================================
   8. ACHIEVEMENTS BANNER
   ============================================ */
.achievements-section {
  padding: 60px 0;
  background: linear-gradient(rgba(0, 0, 0, 0.12), rgba(0, 0, 0, 0.12)), var(--bg-achievement);
  color: var(--text-white);
}

.achievements-section .section-header h2 {
  color: var(--text-white);
}

.achievements-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
  text-align: center;
}

.achievement-item {
  padding: 20px;
}

.achievement-icon {
  font-size: 36px;
  margin-bottom: 12px;
  opacity: 0.9;
}

.achievement-number {
  font-size: 42px;
  font-weight: 700;
  font-family: var(--font-heading);
}

.achievement-suffix {
  font-size: 32px;
  font-weight: 700;
}

.achievement-item p {
  font-size: 15px;
  margin-top: 5px;
  opacity: 0.9;
}

/* ============================================
   9. MEET OUR TEAM
   ============================================ */
.team-section {
  padding: 70px 0;
  background: var(--bg-light);
}

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

.team-card {
  background: var(--bg-white);
  border-radius: 10px;
  overflow: hidden;
  text-align: center;
  box-shadow: 0 3px 15px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s ease;
}

.team-card:hover {
  transform: translateY(-5px);
}

.team-photo {
  width: 100%;
  height: 220px;
  overflow: hidden;
}

.team-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.team-info {
  padding: 18px 15px 22px;
  border-top: 4px solid transparent;
}

.team-info.accent-teal {
  border-top-color: var(--primary);
}

.team-info.accent-red {
  border-top-color: var(--red);
}

.team-info.accent-blue {
  border-top-color: var(--blue);
}

.team-info.accent-orange {
  border-top-color: var(--orange);
}

.team-info h3 {
  font-size: 17px;
  font-weight: 600;
  margin-bottom: 4px;
}

.team-info p {
  font-size: 14px;
  color: var(--primary);
  font-weight: 500;
}

/* ============================================
   10. OUR VOLUNTEERS
   ============================================ */
.volunteers-section {
  padding: 70px 0;
  background: var(--bg-white);
}

.volunteers-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
}

.volunteer-card {
  display: flex;
  gap: 20px;
  align-items: flex-start;
  background: var(--bg-light);
  border-radius: 10px;
  padding: 20px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  transition: box-shadow 0.3s ease;
}

.volunteer-card:hover {
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.volunteer-photo {
  flex: 0 0 130px;
  width: 130px;
  height: 150px;
  border-radius: 8px;
  overflow: hidden;
}

.volunteer-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

.volunteer-info {
  flex: 1;
}

.volunteer-info h3 {
  font-size: 17px;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--primary);
}

.volunteer-info p {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ============================================
   11. FOOTER
   ============================================ */
.site-footer {
  background: var(--bg-footer);
  color: #cccccc;
  padding-top: 50px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1.5fr;
  gap: 40px;
  padding-bottom: 40px;
}

.footer-col h3 {
  font-size: 20px;
  font-weight: 600;
  color: var(--text-white);
  margin-bottom: 18px;
  position: relative;
  padding-bottom: 10px;
}

.footer-col h3::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 40px;
  height: 2px;
  background: var(--primary);
}

.footer-about p {
  font-size: 14px;
  line-height: 1.8;
  margin-bottom: 18px;
}

.footer-social {
  display: flex;
  gap: 12px;
}

.footer-social a {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-white);
  font-size: 14px;
  transition: all 0.3s ease;
}

.footer-social a:hover {
  background: var(--primary);
  transform: translateY(-3px);
}

.footer-links ul {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-links ul li a {
  color: #aaaaaa;
  font-size: 14px;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 6px;
}

.footer-links ul li a::before {
  content: '\f105';
  font-family: 'Font Awesome 6 Free';
  font-weight: 900;
  font-size: 12px;
}

.footer-links ul li a:hover {
  color: var(--primary-light);
  padding-left: 5px;
}

.footer-contact p {
  font-size: 14px;
  line-height: 1.8;
  margin-bottom: 12px;
  display: flex;
  gap: 10px;
}

.footer-contact p i {
  color: var(--primary-light);
  margin-top: 5px;
  flex-shrink: 0;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 18px 0;
  text-align: center;
}

.footer-bottom p {
  font-size: 13px;
  color: #888888;
}

/* ============================================
   SCROLL TO TOP BUTTON
   ============================================ */
.scroll-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 45px;
  height: 45px;
  border-radius: 50%;
  background: var(--primary);
  color: var(--text-white);
  border: none;
  cursor: pointer;
  font-size: 18px;
  z-index: 999;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
}

.scroll-top.visible {
  opacity: 1;
  visibility: visible;
}

.scroll-top:hover {
  background: var(--primary-dark);
  transform: translateY(-3px);
}

/* ============================================
   RESPONSIVE BREAKPOINTS
   ============================================ */

/* ---------- Tablet: <= 992px ---------- */
@media (max-width: 992px) {
  .about-content {
    flex-direction: column;
  }

  .about-icons {
    flex: none;
    width: 100%;
    grid-template-columns: 1fr 1fr 1fr;
  }

  .icon-box-full {
    grid-column: auto;
  }

  .mission-content {
    flex-direction: column;
  }

  .vision-content {
    flex-direction: column;
  }

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

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

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

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

/* ---------- Mobile: <= 768px ---------- */
@media (max-width: 768px) {
  .top-bar {
    display: none;
  }

  .site-header {
    position: sticky;
    top: 0;
  }

  .mobile-menu-toggle {
    display: block;
  }

  .main-nav {
    display: none;
    position: absolute;
    top: var(--header-height);
    left: 0;
    right: 0;
    background: var(--bg-white);
    border-top: 1px solid var(--border-light);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  }

  .main-nav.active {
    display: block;
  }

  .nav-menu {
    flex-direction: column;
    padding: 10px 0;
  }

  .nav-menu li a {
    padding: 12px 20px;
    border-radius: 0;
  }

  .slides {
    height: 300px;
  }

  .slider-container {
    max-height: 300px;
  }

  .section-header h2 {
    font-size: 24px;
  }

  .about-section,
  .mission-section,
  .vision-section,
  .events-section,
  .team-section,
  .volunteers-section {
    padding: 50px 0;
  }

  .about-content {
    flex-direction: column;
    gap: 30px;
  }

  .about-icons {
    grid-template-columns: 1fr 1fr 1fr;
  }

  .icon-box-full {
    grid-column: auto;
  }

  .events-grid {
    grid-template-columns: 1fr;
  }

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

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

  .achievement-number {
    font-size: 32px;
  }

  .volunteers-list {
    grid-template-columns: 1fr;
  }

  .volunteer-card {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .volunteer-photo {
    flex: none;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .footer-col h3::after {
    left: 50%;
    transform: translateX(-50%);
  }

  .footer-about,
  .footer-links,
  .footer-contact {
    text-align: center;
  }

  .footer-social {
    justify-content: center;
  }

  .footer-links ul li a {
    justify-content: center;
  }

  .footer-contact p {
    justify-content: center;
  }
}

/* ---------- Small phone: <= 480px ---------- */
@media (max-width: 480px) {
  .container {
    padding: 0 12px;
  }

  .section-header h2 {
    font-size: 22px;
  }

  .slides {
    height: 220px;
  }

  .slider-container {
    max-height: 220px;
  }

  .slider-btn {
    width: 35px;
    height: 35px;
    font-size: 14px;
  }

  .team-grid {
    grid-template-columns: 1fr;
  }

  .achievements-grid {
    grid-template-columns: 1fr;
  }

  .volunteer-photo {
    width: 150px;
    height: 150px;
  }

  .event-image img {
    height: 180px;
  }

  .vision-image img {
    height: 250px;
  }
}
