/* Base Styles */
body {
  color: #333;
  line-height: 1.6;
}

/* Project Detail Section */
#project-detail {
  padding: 80px 20px;
  background-color: #f0f4f8;
}

#project-detail h2 {
  text-align: center;
  margin-bottom: 40px;
  font-size: 2.5rem;
  color: #2c3e50;
}

.project-detail-container {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 60px;
  max-width: 1200px;
  margin: 0 auto;
  justify-content: center;
}

.project-detail-image {
  flex: 1 1 300px;
  max-width: 400px;
  width: 100%;
  border-radius: 10px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.project-detail-image:hover {
  transform: scale(1.05);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.project-detail-content {
  flex: 2 1 500px;
}

.project-detail-content p {
  margin-bottom: 20px;
  font-size: 1.1rem;
  color: #555;
}

.project-detail-content h3 {
  margin-top: 30px;
  margin-bottom: 15px;
  font-size: 1.8rem;
  color: #2c3e50;
}

.project-detail-content ul {
  list-style-type: disc;
  margin-left: 30px;
  margin-bottom: 20px;
}

.project-detail-content ul li {
  margin-bottom: 10px;
  font-size: 1rem;
  color: #555;
}

/* Technologies Used Section */
#technologies {
  padding: 80px 20px;
  background-color: #ffffff;
}

#technologies h2 {
  text-align: center;
  margin-bottom: 40px;
  font-size: 2.5rem;
  color: #2c3e50;
}

.technologies-container {
  display: flex;
  justify-content: space-around;
  flex-wrap: wrap;
  gap: 40px;
  max-width: 1000px;
  margin: 0 auto;
}

.frontend-section, .backend-section {
  width: 45%;
  margin-bottom: 20px;
  gap: 40px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
}

.frontend-section h3, .backend-section h3{
  width: 100%;
  margin-bottom: 0;
}

/* Responsive: Stack sections on smaller screens */
@media (max-width: 768px) {
  .frontend-section, .backend-section {
    width: 100%;
  }
}


.tech-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 140px;
  font-size: 5em;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.tech-item:hover {
  transform: translateY(-5px);
}

.tech-item img {
  width: 80px;
  height: 80px;
  margin-bottom: 15px;
}

.tech-item p {
  text-align: center;
  font-weight: bold;
  color: #34495e;
  font-size: 1rem;
}

/* Gallery Section */
#gallery {
  padding: 80px 20px;
  background-color: #f0f4f8;
}

#gallery h2 {
  text-align: center;
  margin-bottom: 40px;
  font-size: 2.5rem;
  color: #2c3e50;
}

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

.gallery-item {
  position: relative; /* Für Titel-Overlay */
}

.gallery-item img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.gallery-item img:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

/* Titel-Overlay auf Bildern */
.title-overlay {
  position: static; /* Unter dem Bild */
  background: none; /* Kein Hintergrund */
  color: #2c3e50; /* Textfarbe */
  text-align: center;
  padding: 10px 0;
  font-size: 1rem;
  opacity: 1; /* Immer sichtbar */
  border-radius: 0;
}

.gallery-item img {
  margin-bottom: 5px; /* Abstand zwischen Bild und Titel */
}

.gallery-item:hover .title-overlay {
  opacity: 1; /* Keine Änderung beim Hover */
}

/* Lightbox Styles */
#lightbox {
  display: none;
  position: fixed;
  z-index: 1000;
  padding-top: 20px; /* Weniger Padding oben */
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.9);
  flex-direction: column; /* Elemente vertikal anordnen */
  align-items: center;
  justify-content: center;
}

#lightbox .lightbox-image {
  max-width: 90%;
  max-height: 60vh; /* Begrenze die Höhe auf 60% der Viewport-Höhe */
  animation: zoomIn 0.5s;
  border-radius: 8px;
}

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

#lightbox .lightbox-navigation {
  position: static; /* Unter dem Bild */
  margin-top: 20px;
  display: flex;
  justify-content: center;
  gap: 70px;
}

#lightbox .prev,
#lightbox .next {
  cursor: pointer;
  color: #fff;
  font-size: 40px; /* Verkleinert von 60px */
  padding: 10px;
  user-select: none;
}

#lightbox .lightbox-indicator {
  position: static;
  margin-top: -53px;
  color: #fff;
  font-size: 1rem;
}

#lightbox .lightbox-title {
  position: static; /* Unter den Navigationspfeilen und Zähler */
  margin-top: 40px;
  font-size: 2rem;
  color: #fff;
  text-align: center;
  width: 100%;
}

/* Lightbox Animation */
@keyframes zoomIn {
  from {
    transform: scale(0.7);
  }
  to {
    transform: scale(1);
  }
}

/* Testimonials Section */
#testimonials {
  padding: 80px 20px;
  background-color: #ffffff;
}

#testimonials h2 {
  text-align: center;
  margin-bottom: 40px;
  font-size: 2.5rem;
  color: #2c3e50;
}

.testimonials-container {
  display: flex;
  flex-direction: column;
  gap: 40px;
  max-width: 800px;
  margin: 0 auto;
}

.testimonial-item {
  background-color: #ecf0f1;
  padding: 20px 25px; /* Angepasst für mobile Ansicht */
  border-left: 5px solid #3498db;
  border-radius: 4px;
  position: relative;
  font-style: italic;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.testimonial-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.testimonial-item::before {
  content: open-quote;
  font-size: 3rem; /* Verkleinert von 4rem */
  color: #3498db;
  position: absolute;
  top: -10px;
  left: 15px;
}

.testimonial-item p {
  margin-bottom: 20px;
  font-size: 1.1rem;
  color: #555;
}

.testimonial-item h4 {
  margin-top: 15px;
  text-align: right;
  font-style: normal;
  color: #2c3e50;
  font-weight: bold;
  font-size: 0.9rem; /* Verkleinert von 1rem */
}

/* Project Not Found Section */
#project-not-found {
  padding: 80px 20px;
  background-color: #f0f4f8;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
}

.project-not-found-container {
  background-color: #ffffff;
  padding: 30px 20px; /* Angepasst für mobile Ansicht */
  border-radius: 10px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
  text-align: center;
  max-width: 600px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.project-not-found-container:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.project-not-found-container p {
  font-size: 1.1rem; /* Verkleinert von 1.3rem */
  color: #555555;
  margin-bottom: 30px;
}

.project-not-found-container .btn {
  background-color: #3498db;
  color: #ffffff;
  padding: 10px 20px; /* Angepasst für mobile Ansicht */
  text-decoration: none;
  border-radius: 4px;
  font-size: 0.9rem; /* Verkleinert von 1rem */
  transition: background-color 0.3s ease, transform 0.3s ease;
}

.project-not-found-container .btn:hover {
  background-color: #2980b9;
  transform: scale(1.05);
}

/* Main container for the gallery */
#project-images {
  width: 1000px; /* Slightly wider for more breathing room */
  height: 700px; /* Increased height */
  background-color: #fff;
  border-radius: 16px;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

/* Main image wrapper styling */
.main-image-wrapper {
  position: relative;
  flex: 1; /* Takes up remaining space above thumbnails */
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-bottom: 2px solid #ddd;
  padding: 20px;
  transition: background-color 0.3s ease;
}

/* Main image styling */
.main-image {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: 16px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* Scale up the main image slightly on hover */
.main-image-wrapper:hover .main-image {
  transform: scale(1.02);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

/* Banner styling (title & description overlay) */
.banner {
  position: absolute;
  bottom: 0;
  width: 100%;
  background: rgba(0, 0, 0, 0.7);
  color: white;
  padding: 15px 20px;
  text-align: left;
  box-sizing: border-box;
  opacity: 0;
  transition: opacity 0.4s ease;
}

/* Make the banner appear on hover */
.main-image-wrapper:hover .banner {
  opacity: 1;
}

.banner h3 {
  margin: 0 0 5px;
  text-align: left;
  color: white;
  font-size: 1.3rem;
}

.banner p {
  margin: 0;
  color: white;
  font-size: 0.95rem;
}

/* Thumbnail container below the main image */
.thumbnail-container {
  height: 185px; /* Slightly taller to accommodate bigger thumbnails and text */
  display: flex;
  align-items: center;
  gap: 12px;
  overflow-x: auto;
  padding: 15px;
  scrollbar-width: thin;
  scrollbar-color: #007BFF #f4f4f9;
  background: #f9f9f9;
  border-top: 2px solid #ddd;
}

/* WebKit scrollbar customizations */
.thumbnail-container::-webkit-scrollbar {
  height: 8px;
}

.thumbnail-container::-webkit-scrollbar-track {
  background: #f4f4f9;
  border-radius: 4px;
}

.thumbnail-container::-webkit-scrollbar-thumb {
  background: #007BFF;
  border-radius: 4px;
}

/* Thumbnail styling */
.thumbnail {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px; /* Space between image and title */
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  width: 90px; /* Slightly bigger than original */
  overflow: hidden;
  border-radius: 12px;
}

/* Thumbnail image styling */
.thumbnail img {
  width: 90px;
  height: 90px;
  object-fit: cover;
  border-radius: 12px 12px 12px 12px;
  transition: transform 0.2s ease, border-radius 0.2s ease;
  user-select: none;
}

.thumbnail p {
  font-size: 0.85rem;
  color: #555;
  text-align: center;
  margin: 0;
}

/* Hover effect for thumbnails */
.thumbnail:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.thumbnail:hover > img {
  border-radius: 12px 12px 0 0;
}
