/* style.css */
* {
  box-sizing: border-box;
}

body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  background: #f9f9f9;
  color: #333;
  line-height: 1.6;
}

.container {
  max-width: 900px;
  margin: 0 auto;
}

/* Header section */
.full-image-header {
  max-width: 900px;
  margin: 0 auto;
  overflow: hidden;
  border-radius: 6px 6px 0 0;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
  height: 220px; /* Adjust this to your taste */
}

.full-image-header img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 40%; /* moves the image down more */
  display: block;
}

.project-title-section {
  max-width: 900px;
  margin: 20px auto 0 auto;
  text-align: center;
  font-weight: bold;
  font-size: 1.5em;
  color: #5d5387; /* same purple tone */
}

nav {
  background-color: #4a4370;
  padding: 10px 20px;
  text-align: right;
}

nav a {
  color: white;
  font-weight: bold;
  text-decoration: none;
  margin-left: 15px;
}

nav a:hover {
  text-decoration: underline;
}

main {
  background: white;
  padding: 20px;
  box-shadow: 0 0 8px rgba(0,0,0,0.1);
  border-radius: 6px;
  margin-top: 20px;
}

main img {
  max-width: 100%;
  height: auto;
  margin: 10px 0;
  border-radius: 6px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
  transition: transform 0.3s ease;
  display: block;
}

main img:hover {
  transform: scale(1.03);
  box-shadow: 0 4px 12px rgba(0,0,0,0.25);
}

h2 {
  color: #5d5387;
  margin-top: 30px;
}

footer {
  text-align: center;
  background-color: #5d5387;
  color: white;
  padding: 15px 10px;
  margin-top: 40px;
  font-size: 0.9em;
  border-radius: 6px;
}

footer a {
  color: #eee;
  text-decoration: none;
  margin-left: 10px;
}

footer a:hover {
  text-decoration: underline;
}



/* ----------------------------------------- */
/* Interactive Responsive Gallery            */
/* ----------------------------------------- */

.gallery-container {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  padding: 20px;
}

.gallery {
  flex: 1 1 200px;
  max-width: 200px;
  cursor: pointer;
  border: 1px solid #ccc;
  border-radius: 4px;
  overflow: hidden;
  transition: transform 0.2s ease;
}

.gallery img {
  width: 100%;
  height: 180px; /* fixed height for all images */
  object-fit: cover; /* this crops nicely */
  display: block;
  border-radius: 4px;
}


.gallery:hover {
  transform: scale(1.05);
  border-color: #5d5387;
}

/* Modal Styles */
.modal {
  display: none;
  position: fixed;
  z-index: 999;
  padding-top: 60px;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0,0,0,0.9);
}

.modal-content {
  margin: auto;
  display: block;
  max-width: 90%;
  max-height: 80vh;
}

/* Next & Previous buttons inside modal */

.prev, .next {
  cursor: pointer;
  position: absolute;
  top: 50%;
  padding: 16px;
  color: white;
  font-weight: bold;
  font-size: 30px;
  user-select: none;
  transition: 0.3s;
  transform: translateY(-50%);
}

.prev {
  left: 10px;
  border-radius: 3px 0 0 3px;
}

.next {
  right: 10px;
  border-radius: 0 3px 3px 0;
}

.prev:hover,
.next:hover {
  background-color: rgba(0, 0, 0, 0.6);
}



.close {
  position: absolute;
  top: 30px;
  right: 45px;
  color: #fff;
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
}

#caption {
  margin: auto;
  text-align: center;
  color: #ccc;
  padding: 10px 0;
}




@media (max-width: 768px) {
  .gallery-container {
    flex-direction: column;
    align-items: center;
    padding-bottom: 30px; /* <-- this is extra */
  }

  .gallery {
    max-width: 90%;
  }
}
