/* About Section */
#about-dig-sites.about-dig-sites {
  margin: 40px auto;
  padding: 20px;
  background-color: #f9f9f9;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  width: 80%;
  text-align: center;
}

#about-dig-sites h2 {
  font-size: 2em;
  color: #8b4513;
  margin-bottom: 20px;
}

#about-dig-sites .content-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

#about-dig-sites .text-block {
  flex: 1;
  padding: 10px;
}

#about-dig-sites p {
  font-size: 1.1em;
  line-height: 1.6;
  color: #333;
  margin-bottom: 20px;
}

#about-dig-sites .left-image,
#about-dig-sites .right-image {
  max-width: 30%;
  height: auto;
  border-radius: 8px;
  margin: 10px;
}

#about-dig-sites .left-image {
  order: -1; /* This ensures the image appears to the left */
}

/* CSS for Dig Site List Section */
#digsite-list {
  width: 60%;
  margin: 40px auto;
  padding: 20px;
  background-color: #fff;
  border-radius: 8px;
  border: 1px solid #ccc;
  text-align: center;
}

#digsite-list h2 {
  font-size: 2em;
  color: #8b4513;
  margin-bottom: 20px;
}

.digsite-list-container {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
}

.digsite-list-container ul {
  list-style: none;
  padding: 0;
  margin: 0;
  flex: 1;
}

.digsite-list-container ul li {
  text-align: left;
  margin-bottom: 10px;
}

/* Style for state names */
.digsite-list-container ul li a.state {
  color: #8b4513;
  font-size: 1.4em;
  font-weight: bold;
  text-decoration: none;
  transition: color 0.3s;
}

/* Style for dig sites under each state (indentation and smaller font size) */
.digsite-list-container ul ul {
  margin-left: 20px; /* Indent for sub-lists (dig sites) */
}

.digsite-list-container ul ul li {
  margin-bottom: 8px;
}

.digsite-list-container ul ul li a {
  color: #8b4513;
  font-size: 1.2em;
  text-decoration: none;
  transition: color 0.3s, background-color 0.3s;
}

/* Active state styling for dig sites */
li a.active {
  background-color: #f0e68c; /* Softer background color for the active item */
  color: #8b4513; /* Text color that complements the background */
  font-weight: bold; /* Make the text bold for emphasis */
  border-radius: 4px; /* Slightly rounded corners for a smoother look */
  box-shadow: 0 0 5px rgba(0, 0, 0, 0.1); /* Add a subtle shadow for depth */
  transition: background-color 0.3s, color 0.3s; /* Smooth transition for color changes */
  text-decoration: none; /* Remove underline from the link */
}

/* Hover effects for dig sites */
.digsite-list-container ul ul li a:hover {
  color: white;
  background-color: #8b4513;
  padding: 5px 1px;
  border-radius: 5px;
}

/* Hover effects for state names */
.digsite-list-container ul li a.state:hover {
  color: #a0522d;
}

/* Found Here Section */
#found-here-dig-sites.found-here-dig-sites {
  margin: 40px auto;
  padding: 20px;
  background-color: #f9f9f9;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  width: 80%;
  text-align: center;
}

#found-here-dig-sites h2 {
  font-size: 2em;
  color: #8b4513;
  margin-bottom: 20px;
}

#found-here-dig-sites p {
  font-size: 1.1em;
  line-height: 1.6;
  color: #333;
  margin-bottom: 20px;
}

#found-here-dig-sites ul {
  list-style-type: disc;
  margin: 0 auto 20px auto;
  padding-left: 20px;
  text-align: left;
  width: 75%;
}

#found-here-dig-sites ul li {
  font-size: 1.1em;
  line-height: 1.6;
  color: #333;
  margin-bottom: 10px;
}

#found-here-dig-sites ul li a {
  color: #8b4513;
  text-decoration: none;
}

#found-here-dig-sites ul li a:hover {
  text-decoration: underline;
}

.image-gallery {
  display: flex;
  justify-content: space-between;
  margin-top: 20px;
}

.image-item {
  width: 30%;
  text-align: center;
}

.image-item img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover; /* Ensures the image fills the square without distorting */
  border-radius: 8px;
  margin-bottom: 10px;
}

.image-item p {
  font-size: 1em;
  color: #333;
  margin: 0;
}

 /* Gallery Grid - 4 per row */
 .image-gallery2 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 20px;
}

/* Square gallery items using container technique */
.gallery-square,
.image-item2 {
  position: relative;
  width: 100%;
  padding-top: 100%; /* Force a 1:1 aspect ratio (square) */
  overflow: hidden;
  border-radius: 8px;
}

.gallery-square img,
.image-item2 img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  cursor: pointer; /* Indicates image is clickable */
}

/* Lightbox Modal Styles */
.lightbox {
  display: none; /* Hidden by default */
  position: fixed;
  z-index: 1000;
  padding-top: 60px;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0,0,0,0.9); /* Semi-transparent background */
}

.lightbox-content {
  margin: auto;
  display: block;
  max-width: 80%;
  max-height: 80%;
}

#caption {
  margin: auto;
  display: block;
  width: 80%;
  max-width: 700px;
  text-align: center;
  color: #ccc;
  padding: 10px 0;
}

/* Zoom animation */
@keyframes zoom {
  from { transform: scale(0); }
  to { transform: scale(1); }
}

.lightbox-content, #caption {
  animation: zoom 0.6s;
}

/* Close Button */
.close {
  position: absolute;
  top: 30px;
  right: 35px;
  color: #f1f1f1;
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
  transition: 0.3s;
}

.close:hover {
  color: #bbb;
}

.content-wrapper ul li {
  font-size: 1.1em;
  line-height: 1.6;
  color: #333;
  margin-bottom: 10px;
  align-items: left;
}

/* Location Section */
#location-dig-sites.location-dig-sites {
  margin: 40px auto;
  padding: 20px;
  background-color: #f9f9f9;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  width: 80%;
  text-align: center;
}

#location-dig-sites h2 {
  font-size: 2em;
  color: #8b4513;
  margin-bottom: 20px;
}

#location-dig-sites p {
  font-size: 1.1em;
  line-height: 1.6;
  color: #333;
  margin-bottom: 20px;
}

#location-dig-sites iframe {
  width: 100%;
  height: 450px;
  border: 0;
  border-radius: 8px;
}


/* Recommended Gear and Tips Section */
#recommended-dig-sites.recommended-dig-sites {
  margin: 40px auto;
  padding: 20px;
  background-color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  width: 80%;
  text-align: center;
}

#recommended-dig-sites h1,
#recommended-dig-sites h2 {
  font-size: 2em;
  color: #8b4513;
  margin-bottom: 20px;
}

#recommended-dig-sites p {
  font-size: 1.1em;
  line-height: 1.6;
  color: #333;
  margin-bottom: 20px;
}

#recommended-dig-sites ul {
  list-style-type: disc;
  margin: 0 auto 20px auto;
  padding-left: 20px;
  text-align: left;
  width: 75%;
}

#recommended-dig-sites ul li {
  font-size: 1.1em;
  line-height: 1.6;
  color: #333;
  margin-bottom: 10px;
}

.tips-section {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.tips-section .text-block {
  flex: 1;
  padding: 10px;
  text-align: left;
}

.tips-section img {
  max-width: 30%;
  height: auto;
  border-radius: 8px;
  margin: 10px;
}

.tips-section .left-image {
  order: -1; /* This ensures the image appears to the left */
}

.recommended-gear {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  margin-top: 20px;
}

.gear-card {
  background-color: #ffffff;
  border: 1px solid #ccc;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  margin: 10px;
  width: 23%;
  text-align: center;
  padding: 20px;
  transition: transform 0.3s;
}

.gear-card:hover {
  transform: translateY(-10px);
}

.gear-card img {
  max-width: 100%;
  border-radius: 8px;
  margin-bottom: 10px;
}

.gear-card h3 {
  font-family: 'Cinzel', serif;
  color: #8b4513;
  font-size: 1.5em;
  margin-bottom: 10px;
}

.gear-card p {
  font-size: 1em;
  line-height: 1.4;
  color: #333;
}

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

a:hover {
  text-decoration: none;
  color: #8b4513;
}

/* Other Dig Sites Section */
#other-dig-sites-dig-sites.other-dig-sites-dig-sites {
  margin: 40px auto;
  padding: 20px;
  background-color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  width: 80%;
  text-align: center;
}

#other-dig-sites-dig-sites h2 {
  font-size: 2em;
  color: #8b4513;
  margin-bottom: 20px;
}

#other-dig-sites-dig-sites p {
  font-size: 1.1em;
  line-height: 1.6;
  color: #333;
  margin-bottom: 20px;
}

.dig-site-cards-wrapper {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
}

.dig-site-card {
  background-color: #ffffff;
  border: 1px solid #ccc;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  margin: 10px;
  width: 23%;
  text-align: center;
  padding: 20px;
  transition: transform 0.3s;
}

.dig-site-card:hover {
  transform: translateY(-10px);
}

.dig-site-card img {
  max-width: 100%;
  border-radius: 8px;
  margin-bottom: 10px;
}

.dig-site-card h3 {
  font-family: 'Cinzel', serif;
  color: #8b4513;
  font-size: 1.5em;
  margin-bottom: 10px;
}

.dig-site-card p {
  font-size: 1em;
  line-height: 1.4;
  color: #333;
}

a {
  text-decoration: none;
  color: #8b4513;
}

a:hover {
  text-decoration: none;
  color: #8b4513;
}

/* Mobile Optimizations */
@media (max-width: 768px) {
  .recommended-gear, .other-dig-sites-dig-sites {
    justify-content: center;
  }

  .gear-card, .dig-site-card {
    width: 45%;
  }
}

@media (max-width: 480px) {
  .gear-card, .dig-site-card {
    width: 100%;
  }
}

/* Individual Dig Site Section */
.dig-site {
  margin: 20px auto;
  padding: 20px;
  background-color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  display: flex;
  flex-direction: column;
  text-align: left;
  width: 75%;
}

.dig-site h3 {
  font-size: 1.5em;
  color: #8b4513;
  margin-bottom: 15px;
}

.dig-site .content-wrapper {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
}

.dig-site img {
  max-width: 25%;
  height: auto;
  border-radius: 8px;
  margin-right: 20px;
}

.dig-site .text-wrapper {
  flex: 1;
  padding-left: 20px;
}

.dig-site p {
  font-size: 1.1em;
  line-height: 1.6;
  color: #333;
  margin-bottom: 15px;
}

.dig-site a.button {
  display: inline-block;
  padding: 10px 20px;
  font-size: 1em;
  color: #ffffff;
  background-color: #8b4513;
  border-radius: 8px;
  text-decoration: none;
  transition: background-color 0.3s;
  margin-top: 15px;
}

.dig-site a.button:hover {
  background-color: #a0522d;
}

/* Mobile Optimizations for Top Utah Dig Sites Section */
@media (max-width: 768px) {
  #top-dig-sites,
  .dig-site {
    width: 90%;
  }

  .dig-site img,
  .dig-site .text-wrapper {
    width: 100%;
    padding: 0;
  }

  .dig-site {
    flex-direction: column;
  }

  .tips-section {
    flex-direction: column;
    align-items: center; /* Centers items horizontally */
  }
  .tips-section .text-block {
    width: 100%;
    text-align: left;
  }
  .tips-section img {
    width: 100%;
    max-width: 100%;
    margin: 20px 0 0 0; /* Adjust top margin if needed */
  }

  /* Make each content-wrapper stack its children vertically */
  #about-dig-sites .content-wrapper {
    flex-direction: column;
    align-items: center;
    text-align: left;
  }
  /* Ensure images take full width on mobile */
  #about-dig-sites .left-image,
  #about-dig-sites .right-image {
    max-width: 100%;
    margin: 10px 0;
  }
  /* Make the text block full width */
  #about-dig-sites .text-block {
    width: 100%;
  }
}

@media (max-width: 480px) {
  #top-dig-sites,
  .dig-site {
    width: 100%;
  }
}

/* Top Dig Sites Section */
#top-dig-sites.top-dig-sites {
  margin: 40px auto;
  padding: 20px;
  background-color: #f9f9f9;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  width: 80%;
  text-align: center;
}

#top-dig-sites h2 {
  font-size: 2em;
  color: #8b4513;
  margin-bottom: 20px;
}

#top-dig-sites p {
  font-size: 1.1em;
  line-height: 1.6;
  color: #333;
  margin-bottom: 20px;
}