.project-item {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border: 3px solid #52adc8;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  text-align: justify;
  padding: 32px; /* Added padding inside the container */
}

.project-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3) !important;
}

/* Title */
.project-item h2 {
  padding-bottom: 12px;
  margin-top: 0; /* Remove default top margin */
}

.project-item h2::after {
  content: "";
  display: block;
  width: 60px;
  height: 3px;
  background-color: #52adc8;
  margin-top: 8px;
  border-radius: 2px;
}

/* Tech Stack */
.tech-stack {
  padding: 12px 16px;
  border-radius: 8px;
  border-left: 4px solid #52adc8;
  margin: 20px 0; /* Add vertical spacing */
}

.tech-stack h3 {
  margin: 0 0 4px 0;
}

/* Description */
.project-item p {
  line-height: 1.7;
  text-align: justify;
  margin: 20px 0; /* Add vertical spacing */
}

.read-more-btn {
  background: none;
  border: none;
  padding-left: 6px;
  font-weight: bold;
  cursor: pointer;
}

/* Carousel */
.project-carousel {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  padding: 16px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  margin: 20px 0; /* Add vertical spacing */
}

.carousel-container {
  position: relative;
  width: 100%;
}

.carousel-slide {
  display: none;
}

.carousel-slide.active {
  display: block;
  animation: fadeIn 0.5s ease-in-out;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.carousel-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  border: none;
  padding: 12px 16px;
  cursor: pointer;
  font-size: 20px;
  z-index: 10;
}

.carousel-nav:hover {
  transform: translateY(-50%) scale(1.1);
}

.carousel-nav.prev { left: 8px; }
.carousel-nav.next { right: 8px; }

.carousel-indicators {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 12px;
}

.carousel-indicator {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

/* More space between projects */
.project-item + .project-item {
  margin-top: 60px; /* Increased spacing between consecutive projects */
}

/* ---------- DARK THEME ---------- */
html[data-theme="dark"] .project-item {
  background: #2d3748;
  color: #e2e8f0;
}

html[data-theme="dark"] .project-item h2 {
  color: #e2e8f0;
}

html[data-theme="dark"] .tech-stack {
  background: #1a202c;
}

html[data-theme="dark"] .tech-stack h3 {
  color: #cbd5e0;
}

html[data-theme="dark"] .tech-stack li {
  color: #a0aec0;
}

html[data-theme="dark"] .project-item p {
  color: #cbd5e0;
}

html[data-theme="dark"] .read-more-btn {
  color: #52adc8;
}

html[data-theme="dark"] .read-more-btn:hover {
  color: #7dd3f0;
}

html[data-theme="dark"] .project-carousel {
  background: white;
}

html[data-theme="dark"] .carousel-nav {
  background: rgba(45, 55, 72, 0.8);
  color: #52adc8;
}

html[data-theme="dark"] .carousel-nav:hover {
  background: rgba(45, 55, 72, 0.95);
  color: #7dd3f0;
}

html[data-theme="dark"] .carousel-indicator {
  background: #4a5568;
}

html[data-theme="dark"] .carousel-indicator.active {
  background: #52adc8;
}

html[data-theme="dark"] .presentation__container:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

/* ---------- LIGHT THEME ---------- */
html[data-theme="light"] .project-item {
  background: #ffffff;
  color: #000;
}

html[data-theme="light"] .project-item h2 {
  color: #000;
}

html[data-theme="light"] .tech-stack {
  background: #ffffff;
}

html[data-theme="light"] .tech-stack h3 {
  color: #000;
}

html[data-theme="light"] .tech-stack li {
  color: #000;
}

html[data-theme="light"] .project-item p {
  color: #000;
}

html[data-theme="light"] .project-carousel {
  background: #ffffff;
}

html[data-theme="light"] .carousel-nav {
  background: rgba(255, 255, 255, 0.9);
  color: #52adc8;
}

html[data-theme="light"] .carousel-nav:hover {
  background: #ffffff;
  color: #0088a1;
}

html[data-theme="light"] .carousel-indicator {
  background: rgba(82, 173, 200, 0.3);
}

html[data-theme="light"] .carousel-indicator.active {
  background: #52adc8;
}

html[data-theme="light"] .read-more-btn {
  color: #52adc8;
}

html[data-theme="light"] .read-more-btn:hover {
  color: #0088a1;
}