* {
	box-sizing:border-box;	
}


body {
  height:100vh;
  width: 100%;
	margin:0;
	display:grid;
}

header{
  display: grid;
  background-color: white;
  max-height: 12vh;
  grid-row: 1;
  grid-column: span 2;
}
.logo {
  max-width: 30vh; 
  height: auto;
  margin-right: 1em;
}
.person-logo{
  width:4ch;
}
.members{
  display: inline;
}
.topbar {
  display: flex;
  justify-content: space-between; 
  align-items: center; 
  padding: 1em;
  width: 100%;
  height: auto; 
  transition: all 0.3s ease; 
}


.nav-links {
  display: flex;
  gap: 20px; 
}

.nav-links a {
  text-decoration: none;
  color: black;
  font-size: 16px;
  padding: 10px;
  
}

.right-nav {
  display: flex;
  gap: 15px;
  align-items: center;
  
}
.right-nav a{
  text-decoration: none;

}

.dropdown {
  position: relative;
}

.dropdown-content {
  display: none;
  position: absolute;
  background-color: #f9f9f9;
  min-width: 160px;
  box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.2);
  z-index: 1;
}

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

main {
  width: 100%;
	overflow:auto;
  grid-row: 2;
  grid-column: span 2;
 
}
.grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}

.grid img {
  width: calc(20% - 10px);
  height: auto;
  object-fit: cover;
  border-radius: 10px;
  cursor: pointer;
  @media (max-width: 768px)  {
    .grid img {
      flex: 1 1 calc(50% - 10px);
    
  }
  @media (max-width: 480px) {
    .grid img {
      flex: 1 1 calc(100% - 10px); /* One photo  */
    }
  }}
}
.grid img:hover{
  transform: scale(1.1);
  box-shadow:0 4px 15px rgba(0, 0, 0, 0.2) ;
}
.gallery {
  display: grid; /* Use grid layout */
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); /* Responsive columns */
  gap: 1em; /* Space between images */
  background-color: #fff;
  padding: 1em;
}

/* Images inside the gallery */
.gallery img {
  --aspect-ratio: 1; /* Default aspect ratio */
  width: 100%; /* Full width of the grid item */
  aspect-ratio: var(--aspect-ratio);
  object-fit: cover; /* Crop to fill the space */
  scroll-snap-align: center; /* Align to the center in scroll */
  transition: transform 0.3s ease, box-shadow 0.3s ease; /* Smooth hover effect */
  border-radius: 10px; /* Optional rounded corners */
}

/* Hover effect */
.gallery img:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2); /* Add shadow effect */
}

/* Dynamic aspect ratios for specific images */
.gallery img:nth-of-type(2n) {
  --aspect-ratio: 1.3;
}

.gallery img:nth-of-type(3n) {
  --aspect-ratio: 1.6;
}

.gallery img:nth-of-type(5n) {
  --aspect-ratio: 1.9;
}

.gallery img:nth-of-type(7n) {
  --aspect-ratio: 0.8;
}

.gallery img:nth-of-type(9n) {
  --aspect-ratio: 1.7;
}


ul {	
  display: grid;
	margin: 0px;
	padding: 1em;
  position:absolute;
}

li {
  overflow: hidden;
  height: 100%;
}



footer {
  background-color: rgba(0, 0, 0, 0); 
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  grid-row: 3;
  grid-column: span 2;
  display: flex;
  width: 100%;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 15px;
  z-index: 10; 
}
.footer-filters{
  background-color: transparent !important;
}


.footer-search {
  display: flex;
  justify-content: center;
  margin: 0 auto 5vh auto;
  
}

.footer-search input {
  width: 100%;
  padding: 12px;
  border: none;
  font-size: 16px;
  display: inline-block;
}


.footer-search button {
  padding: 15px 30px;
  border: none; 
  float: left;
 
}

@media (max-width: 480px) {
  body > header{
    max-height: 15vh;
    
  }
  .nav-links{
    display: none;
  }


}
@media (max-width: 350px) {
  ul{
    grid-template-columns: repeat(1, 1fr);
  }
  
}


/* When dragging, show grabbing cursor */
.popup {
  display: none; /* Initially hidden */
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5); /* Semi-transparent background */
  z-index: 1000;
  display: flex;
  justify-content: center;
  align-items: center;
}

.popup-content {
  background: white;
  padding: 20px;
  border-radius: 10px;
  text-align: center;
  position: relative;
  max-width: 400px;
  width: 90%;
}

.popup-content img {
  max-width: 300px; 
  max-height: 300px; 
  width: auto; 
  height: auto; /* Maintain aspect ratio */
  display: block; /* Align properly */
  margin: 0 auto 15px auto; /* Center the image */
  object-fit: contain; /* Ensure the image fits without cropping */
  border-radius: 8px; /* Rounded corners */
}

#close-popup {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: 20px;
  font-weight: bold;
  cursor: pointer;
}

#popup-text {
  font-size: 16px;
  margin: 0;
}

/*11.12*/
fieldset{
  display: inline-flex;
}

input:user-invalid{
  background-color: blue;
}
