.project-grid {
  display: grid;
  gap: 1rem;
  justify-content: center;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
}

@media (min-width: 768px) {
  .project-grid {
    grid-template-columns: repeat(auto-fit, minmax(24rem, 1fr));
  }
}

@media (min-width: 1200px) {
  .project-grid {
    grid-template-columns: repeat(auto-fit, minmax(30rem, 1fr));
  }
}

/* project-card layout */
.project-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  align-self: start;
  justify-self: center;
  gap: 1rem;
  text-align: center;
  padding: 1rem;
  border-radius: 8px;
  background: var(--background);
  text-decoration: none;
  color: inherit;
  transition: box-shadow 0.3s ease, transform 0.2s ease;
}

.project-card:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
  transform: translateY(-2px);
}

.project-card img {
  max-width: 100%;
  border-radius: 4px;
}

.project-card h3,
.project-card p {
  margin: 0;
}

/* Optional: Remove underline on hover if using global link styles */
.project-card::after {
  display: none;
}