body {
  font-family: 'Mukta', sans-serif;
  background-color: #f8f9fa;
  color: #222;
}

/* Remove unwanted space below header/navbar */
body {
  margin: 0;
  padding: 0;
  font-family: 'Mukta', sans-serif;
  background-color: #f8f9fa;
  color: #222;
}

/* Fix spacing below navbar */
.navbar {
  margin-bottom: 0 !important;
}

/* Make carousel attach neatly to navbar */
.carousel {
  margin-top: 0 !important;
  padding-top: 0 !important;
}

/* Navbar */

.navbar {
  background-color: #004aad;
}
.navbar-brand, .nav-link {
  color: white !important;
  font-weight: 600;
}
.nav-link:hover {
  text-decoration: underline;
}

/* Carousel */
.carousel-item img {
  height: 60vh;
  object-fit: cover;
}

/* About Section */
#about {
  padding: 60px 20px;
  background-color: #fff;
  text-align: center;
}
#about h2 {
  color: #004aad;
  font-weight: 700;
  margin-bottom: 20px;
}

/* Quick Links */
#quick-links {
  background-color: #e8f0fe;
  padding: 60px 20px;
  text-align: center;
}
#quick-links .card {
  border: none;
  border-radius: 12px;
  transition: transform 0.3s, background-color 0.3s;
  cursor: pointer;
}
#quick-links .card:hover {
  transform: scale(1.05);
  background-color: #dbe9ff;
}

/* News */
#news {
  background-color: #fff;
  padding: 60px 20px;
}
#news h2 {
  color: #004aad;
  text-align: center;
  font-weight: 700;
  margin-bottom: 40px;
}

/* Gallery */
#gallery {
  background-color: #e8f0fe;
  padding: 60px 20px;
}
#gallery h2 {
  color: #004aad;
  text-align: center;
  font-weight: 700;
  margin-bottom: 40px;
}
#gallery img {
  border-radius: 10px;
  transition: 0.3s;
  width: 100%;
}
#gallery img:hover {
  transform: scale(1.05);
}

/* Footer */
footer {
  background-color: #004aad;
  color: white;
  padding: 30px 20px;
  text-align: center;
}
footer a {
  color: #fff;
  text-decoration: underline;
}

/* Responsive Fixes */
@media (max-width: 768px) {
  .carousel-item img {
    height: 40vh;
  }
  #quick-links .card h5 {
    font-size: 15px;
  }
}

/* Responsive Table Wrapper */
.table-responsive {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin-bottom: 20px;
  border-radius: 8px;
}

/* Smooth horizontal scrolling */
.table-responsive::-webkit-scrollbar {
  height: 8px;
}
.table-responsive::-webkit-scrollbar-thumb {
  background: #ccc;
  border-radius: 4px;
}

/* Table Styling */
.member-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
  background-color: #fff;
}

.member-table th,
.member-table td {
  border: 1px solid #ddd;
  padding: 8px 10px;
  text-align: left;
  white-space: nowrap;
}

.member-table th {
  background-color: #0078d4;
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 2;
}

/* Mobile adjustments */
@media (max-width: 768px) {
  .member-table {
    font-size: 13px;
  }
  .member-table th,
  .member-table td {
    padding: 6px 8px;
  }
}

/* Header and address section */
.family-header,
.address {
  font-size: 16px;
  color: #222;
  margin: 10px 0;
  padding: 8px 12px;
  background-color: #f7f9fb;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

/* Prevent horizontal scrolling for header info */
.family-header,
.address {
  overflow: hidden;
  white-space: normal;
}

/* Table container scrolls separately */
.table-responsive {
  width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  margin-top: 10px;
  border-radius: 8px;
  background: #fff;
}

/* Table styling */
.member-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
  background-color: #fff;
  min-width: 600px; /* ensures table scrolls on small screens */
}

.member-table th,
.member-table td {
  border: 1px solid #ddd;
  padding: 8px 10px;
  text-align: left;
  white-space: nowrap;
}

.member-table th {
  background-color: #0078d4;
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 2;
}

/* Mobile adjustments */
@media (max-width: 768px) {
  .member-table {
    font-size: 13px;
  }
  .member-table th,
  .member-table td {
    padding: 6px 8px;
  }
}

@media (max-width: 576px) {
  .navbar-brand {
    font-size: 16px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 180px;
  }
}

/* Family box container */
.family-box {
  background: #fff;
  padding: 15px;
  margin: 20px auto;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  max-width: 98%;
}

/* Header */
.family-header {
  font-size: 18px;
  font-weight: 600;
  color: #004aad;
  margin-bottom: 10px;
}

/* Address */
.address {
  margin-top: 10px;
  font-size: 15px;
}

/* Search box */
.search-container {
  margin-bottom: 10px;
  text-align: right;
}
.search-container input {
  padding: 8px 12px;
  font-size: 15px;
  border: 1px solid #ccc;
  border-radius: 6px;
  width: 100%;
  max-width: 350px;
}

/* Table styles */
.table-responsive {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: 8px;
}

.member-table {
  width: 100%;
  min-width: 800px;
  border-collapse: collapse;
}

.member-table th, .member-table td {
  border: 1px solid #ddd;
  padding: 8px 10px;
  white-space: nowrap;
  text-align: left;
}

.member-table th {
  background-color: #0078d4;
  color: white;
  position: sticky;
  top: 0;
  z-index: 2;
}

/* Scrollbar */
.table-responsive::-webkit-scrollbar {
  height: 8px;
}
.table-responsive::-webkit-scrollbar-thumb {
  background: #ccc;
  border-radius: 4px;
}

/* Mobile adjustments */
@media (max-width: 768px) {
  .member-table {
    font-size: 13px;
    min-width: 700px;
  }
  .family-header {
    font-size: 16px;
  }
  .search-container {
    text-align: left;
  }
}

/* Better spacing and responsiveness for very small screens */
@media (max-width: 480px) {
  .navbar-brand {
    font-size: 15px;
    max-width: 160px;
  }
  .search-container input {
    width: 100%;
    font-size: 14px;
  }
  .family-box {
    margin: 10px auto;
    padding: 10px;
  }
}

@media print {
    body {
        display: none;
    }
}
