/* Projects Section */
.projects-section {
  padding: 5rem 1.5rem;
  background-color: var(--bg-white);
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  max-width: 1200px;
  margin: 0 auto;
}

.project-item {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: var(--shadow-md);
  aspect-ratio: 4 / 3;
  cursor: pointer;
}

.project-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.project-item:hover .project-image {
  transform: scale(1.08);
}

.project-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 92, 153, 0.92) 0%, rgba(0, 92, 153, 0.4) 40%, transparent 70%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.5rem;
  transition: background 0.4s ease;
  z-index: 1;
}

.project-item:hover .project-overlay {
  background: linear-gradient(to top, rgba(0, 92, 153, 0.95) 10%, rgba(15, 23, 42, 0.6) 100%);
}

.project-category {
  display: inline-block;
  background: var(--accent-yellow);
  color: var(--text-dark);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 0.2rem 0.65rem;
  border-radius: 3px;
  margin-bottom: 0.5rem;
  width: fit-content;
}

.project-title {
  color: var(--bg-white);
  font-size: 1.15rem;
  font-weight: 600;
  line-height: 1.3;
}

/* Project Lightbox Modal */
.modal {
  display: none;
  position: fixed;
  z-index: 2000;
  inset: 0;
  background-color: rgba(15, 23, 42, 0.95);
  backdrop-filter: blur(5px);
  justify-content: center;
  align-items: center;
  padding: 2rem;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.modal.active {
  display: flex;
  opacity: 1;
}

.modal-content {
  position: relative;
  max-width: 900px;
  width: 100%;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.modal-image {
  max-width: 100%;
  max-height: 70vh;
  object-fit: contain;
  border-radius: 6px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
  border: 3px solid rgba(255, 255, 255, 0.1);
}

.modal-caption {
  margin-top: 1rem;
  color: var(--bg-white);
  font-size: 1.1rem;
  text-align: center;
  font-weight: 500;
  max-width: 600px;
}

.modal-close {
  position: absolute;
  top: -40px;
  right: 0;
  color: var(--bg-white);
  font-size: 2rem;
  font-weight: 300;
  cursor: pointer;
  transition: var(--transition-smooth);
  background: none;
  border: none;
}

.modal-close:hover {
  color: var(--accent-yellow);
  transform: scale(1.1);
}
