* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
	font-family: Arial, sans-serif;
	background-color: #f0f0f0;
}

header {
    background-color: #333;
    color: white;
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 0 3% 0 5%;
	flex-wrap: wrap;
}

nav ul {
	display: flex;
	gap: 2rem;
	list-style: none;
	margin: 0;
	padding: 0;
	flex-wrap: wrap;
}

nav ul.prefs {
	gap: 0rem;
}

nav ul li {
    margin: 0 15px;
}

nav ul li a {
	display: block;
    color: white;
	padding: 3px;
    text-decoration: none;
    font-size: 18px;
}

nav ul li a:hover {
  color: #A4FFEE;
}

li a, .dropbtn {
  display: inline-block;
  color: white;
  text-align: center;
  /*padding: 14px 16px;*/
  text-decoration: none;
}

li.dropdown {
  display: inline-block;
}

li#language {
  margin: 10px;
}

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

.dropdown-content a {
  color: white;
  padding: 12px 16px;
  text-decoration: none;
  display: block;
  text-align: left;
}

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

.current_nav {
    color: #A4FFEE;
}

main {
    margin: auto;
    width: 90%;
}

section {
	margin-top: 10px;
    margin-bottom: 50px;
}

div {
  text-align: center;
  padding-bottom: 20px;
}

.dark-mode {
    background-color: #4b4b4b;
    color: #f6f6f6;
}

.no-scroll {
  overflow: hidden;
}

#dark-mode-btn {
	list-style: none;
	cursor: pointer;
	user-select: none;
	font-size: 2rem;
}

.overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  padding-bottom: 0;
  background-color: rgba(0, 0, 0, 0.8);
  display: none;
  justify-content: center;
  align-items: center;
}

.overlay button {
  background-color: transparent;
  border: none;
  color: white;
  font-size: 2rem;
  cursor: pointer;
}

.overlay button:hover {
  color: #ddd;
}

button.close-btn {
  position: absolute;
  top: 1%;
  right: 2%;
  background-color: transparent;
  border: none;
  color: red;
  font-size: 3rem;
  cursor: pointer;
  z-index:12;
}

button.close-btn:hover {
  color:#ff8181;
}

/* --- General styling for the clickable areas --- */
.prev-area, .next-area {
  position: fixed;
  top: 10%;
  height: 90%;
  width: 8%;
  z-index: 10;
}

/* Left side for prevBtn */
.prev-area {
  left: 0;
}

/* Right side for nextBtn */
.next-area {
  right: 20%;
}

/* Style for buttons (position them visually) */
#prevBtn, #nextBtn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background-color: #04AA6D;
  border: none;
  padding: 40px 25px;
  color: white;
  cursor: pointer;
}

/* Position buttons within their respective areas */
#prevBtn {
  left: 10px;
}

#nextBtn {
  right: 10px;
}

.controls .prev-area , .controls .next-area {
  opacity: 0;
  transition: opacity 0.5s linear;
}

.controls:has(+ .image-box:hover, .prev-area:hover, .next-area:hover) .prev-area, .controls:has(+ .image-box:hover, .prev-area:hover, .next-area:hover) .next-area {
  opacity: 1;
}

/* -------------------- image-box styling -------------------- */
.image-box {
  position: relative;
  width: 80%;
  height: 100%;
  display: flex;
  justify-content: center; /* Center the image horizontally */
  align-items: center;     /* Center the image vertically */
  padding-bottom: 0;
}

.image-box img {
  max-width: 100%;
  max-height: calc(100% - 10px);
  margin: 5px 0;
  object-fit: contain;
}

.info-box {
  position: relative;
  top: 5%;
  right: 0;
  width: 20%;
  height: 95%;
  background-color: rgba(51, 51, 51, 0.9);
  color: white;
  padding: 0 20px;
  text-align: left;
  overflow-y: auto;  /* Enables scrolling within the info-box if content is too long */
}

.info-box ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: left;
  border-bottom: 2px solid #aaa;
  user-select: none;
}

.info-box li {
  display: block;
  text-decoration: none;
  padding: 3px;
  margin: 0 5px 5px;
  font-size: 30px;;
  cursor: pointer;
}

.info-box li#first-img {
  margin-right: 10%;
}

.info-box h3 {
  margin-top: 5%;
  word-wrap: break-word;
}

.image-details {
	margin-top: 10%;
	text-align: left;
}

footer {
    background-color: #333;
    color: white;
    text-align: center;
    padding: 10px 0;
    position: relative;
    width: 100%;
    bottom: 0;
}
