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

body {
  font-family: "Inter", "Segoe UI", sans-serif;
  background-color: #f4f7f9;
  color: #222;
  line-height: 1.6;
}

h1, h2, h3, .logo {
  font-family: 'Poppins', sans-serif;
}

a {
  text-decoration: none;
  color: inherit;
}

img {
  width: 100%;
  display: block;
}

/* Layout Wrapper */
.page-wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* Header Navigation */
.mast-nav {
  background-color: #111f2b;
  color: white;
  padding: 1rem 0;
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}

.logo {
  font-size: 1.8rem;
  font-weight: bold;
  color: white;
}

.main-nav {
  display: flex;
  gap: 1.5rem;
  align-items: center;
}

.main-nav a {
  font-size: 1.1rem;
  color: white;
  transition: color 0.3s;
}

.main-nav a:hover {
  color: #00bcd4;
}

/* Dropdown */
.dropdown {
  position: relative;
}

.dropbtn {
  background: none;
  border: none;
  color: white;
  font-size: 1.1rem;
  cursor: pointer;
}

.dropdown-content {
  display: none;
  position: absolute;
  top: 2rem;
  left: 0;
  background-color: #ffffff;
  min-width: 160px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  z-index: 1000;
  border-radius: 4px;
  overflow: hidden;
}

.dropdown-content a {
  display: block;
  padding: 0.75rem 1rem;
  color: #111;
  white-space: nowrap;
}

.dropdown-content a:hover {
  background-color: #f2f2f2;
}

.dropdown:hover .dropdown-content {
  display: block;
}

/* Carousel */
.carousel {
  position: relative;
  max-height: 90vh;
  overflow: hidden;
}

.carousel-wrapper {
  position: relative; /* Keep this here */
}

.carousel-slide {
  width: 100%;
  height: 80vh;
  position: relative;
}

.carousel-slide img {
  width: 100%;
  height: 80vh;
  object-fit: cover;
  display: block;
}

.carousel-slide .caption {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(0, 0, 0, 0.5); /* Semi-transparent dark background */
  color: white;
  padding: 1.5rem 2rem;
  border-radius: 10px;
  text-align: center;
  z-index: 2;
  width: max-content;
  max-width: 80%;
}

.carousel-slide .caption h2 {
  margin-bottom: 0.5rem;
  font-size: 2rem;
}

.carousel-slide .caption p {
  font-size: 1.1rem;
}


/* Navigation arrows */
.prev, .next {
  cursor: pointer;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: auto;
  padding: 12px;
  color: white;
  font-weight: bold;
  font-size: 28px;
  background-color: rgba(0, 0, 0, 0.4);
  border-radius: 50%;
  z-index: 2;
}

.prev:hover, .next:hover {
  background-color: rgba(0, 0, 0, 0.7);
}

.prev {
  left: 20px;
}

.next {
  right: 20px;
}

/* Dots */
.dots-container {
  text-align: center;
  position: absolute;
  bottom: 15px;
  width: 100%;
  z-index: 2;
}

.dot {
  cursor: pointer;
  height: 14px;
  width: 14px;
  margin: 0 4px;
  background-color: #bbb;
  border-radius: 50%;
  display: inline-block;
  transition: background-color 0.3s;
}

.dot.active,
.dot:hover {
  background-color: #717171;
}

/* Section Layout */
.section-center {
  max-width: 1200px;
  margin: 4rem auto;
  padding: 0 2rem;
  text-align: center;
}

.section-center h1 {
  font-size: 2.5rem;
  margin-bottom: 2rem;
}

/* Card Grid */
.card-grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.card {
  background-color: #111f2b;
  color: white;
  padding: 2rem;
  border-radius: 1rem;
  font-size: 1.5rem;
  transition: transform 0.3s ease, background-color 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 150px;
}

.card.large {
  font-size: 1.25rem;
  height: 200px;
}

.card:hover {
  transform: translateY(-5px);
  background-color: #0c1822;
}

/* Contact Section */
.contact-info {
  font-size: 1.1rem;
  line-height: 1.8;
}

.contact-info a {
  color: #00bcd4;
}

/* Footer */
.mast-footer {
  background-color: #111f2b;
  color: white;
  text-align: center;
  padding: 1rem;
  margin-top: auto;
}

.page-title {
  font-size: 2.5rem;
  margin-bottom: 2rem;
  text-align: center;
}

.about-text {
  text-align: left;
  font-size: 1.1rem;
  max-width: 900px;
  margin: 0 auto 4rem;
  line-height: 1.8;
}

.image-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 1.5rem;
  padding: 2rem;
  justify-items: center;
}

.grid-img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  cursor: pointer;
  box-shadow: 0 0 10px rgba(0,0,0,0.1);
  transition: transform 0.2s ease;
}

.grid-img:hover {
  transform: scale(1.03);
}

/* Modal */
.modal {
  display: none;
  position: fixed;
  z-index: 9999;
  padding-top: 80px;
  left: 0; top: 0;
  width: 100%; height: 100%;
  background-color: rgba(0,0,0,0.8);
}

.modal-content {
  margin: auto;
  display: block;
  max-width: 90%;
  max-height: 80vh;
  border-radius: 10px;
}

.close {
  position: absolute;
  top: 30px; right: 50px;
  color: #fff;
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
}

.site-wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* Navbar */
.mast-header {
  background-color: #0d2f4f;
  color: white;
}
.navbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 2rem;
}
.navbar-brand {
  font-size: 2rem;
  color: white;
  text-decoration: none;
}
.nav-links {
  list-style: none;
  display: flex;
  gap: 2rem;
}
.nav-links a, .dropdown > span {
  color: white;
  text-decoration: none;
  font-size: 1.25rem;
  position: relative;
}
.menu-icon {
  display: none;
  font-size: 2rem;
  cursor: pointer;
}
#menu-toggle {
  display: none;
}
.dropdown {
  position: relative;
}
/* DROPDOWN MENU STYLING FIX */
.dropdown-menu {
  list-style: none;
  padding: 0.5rem 0;
  margin: 0;
  background-color: white;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 160px;
  border-radius: 4px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  display: none;
  z-index: 100;
}

.dropdown-menu li {
  padding: 0;
  margin: 0;
}

.dropdown-menu a {
  display: block;
  padding: 0.75rem 1rem;
  color: #333;
  text-decoration: none;
  font-size: 1rem;
  white-space: nowrap;
}

.dropdown-menu a:hover {
  background-color: #f2f2f2;
}

.dropdown:hover .dropdown-menu {
  display: block;
}

.dropdown > span::after {
  content: " ▾";
  font-size: 0.75em;
  margin-left: 0.25rem;
}


/* Hero Banner */
.hero {
  position: relative;
  max-height: 500px;
  overflow: hidden;
}
.hero img {
  width: 100%;
  height: auto;
  object-fit: cover;
}
.hero-text {
  position: absolute;
  bottom: 2rem;
  left: 2rem;
  color: white;
  background-color: rgba(0, 0, 0, 0.4);
  padding: 1rem;
  border-radius: 0.5rem;
}

/* Gallery */
.gallery-section {
  padding: 4rem 2rem;
  text-align: center;
  background-color: #f4f7f9;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

.gallery-item {
  background-color: #ffffff;
  border: 2px solid #111f2b;
  border-radius: 10px;
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease, background-color 0.3s ease-in-out;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  height: 320px;
  cursor: pointer;
}

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

.gallery-item:hover {
  transform: translateY(-6px);
  background-color: #111f2b;
  box-shadow: 0 8px 16px rgba(17, 31, 43, 0.15);
}

/* Contact */
.contact {
  text-align: center;
  padding: 3rem 2rem;
  background-color: #f8f9fa;
}
.contact h1 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}
.contact p, .contact a {
  font-size: 1.1rem;
  color: #333;
}

/* Footer */
.mast-footer {
  background-color: #0d2f4f;
  color: white;
  text-align: center;
  padding: 1rem;
  margin-top: auto;
}

/* Modal */
.modal {
  display: none;
  position: fixed;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.8);
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.modal img {
  max-width: 80vw;
  max-height: 80vh;
  width: auto;
  height: auto;
  object-fit: contain;
  border: 3px solid white;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease;
}

.modal img:hover {
  transform: scale(1.02);
}

@media (max-width: 768px) {
  .modal img {
    max-width: 90vw;
    max-height: 80vh;
  }
}

/* Responsive */
@media (max-width: 768px) {
  .nav-links {
    flex-direction: column;
    display: none;
    background-color: #0d2f4f;
    width: 100%;
    padding: 1rem;
  }
  #menu-toggle:checked + .menu-icon + .nav-links {
    display: flex;
  }
  .dropdown-menu {
    position: static;
    box-shadow: none;
  }
}

/* Contact Cards Styling */
.contact-cards {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  margin-top: 2rem;
}

.contact-card {
  flex: 1 1 260px;
  min-width: 260px;
  max-width: 100%;
  background-color: #ffffff;
  color: #111f2b;
  border: 2px solid #111f2b;
  font-size: 1rem;
  text-align: left;
  padding: 2rem 1.5rem;
  border-radius: 1rem;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  gap: 1rem;
  word-wrap: break-word;
  overflow-wrap: break-word;
  height: 100%;
}

.contact-card h2 {
  font-size: 1.3rem;
  margin-bottom: 0.25rem;
  color: #111f2b;
  font-family: 'Poppins', sans-serif;
}

.contact-card p,
.contact-card a {
  margin: 0;
  font-size: 1.05rem;
  line-height: 1.6;
  word-break: break-word;
}

.contact-card a {
  color: #00bcd4;
  font-weight: 500;
}

.contact-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 8px 16px rgba(17, 31, 43, 0.1);
}

/* Responsive: Stack cards on small screens */
@media (max-width: 768px) {
  .contact-cards {
    flex-direction: column;
  }

  .contact-card {
    width: 100%;
  }
}
