/* Tech Stack Section - Base Styles */
.tech-stack-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 1.25rem;
  padding: 1.5rem 0.5rem;
  max-width: 1440px;
  margin: 0 auto;
}

.tech-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.5rem 0.5rem;
  border-radius: 12px;
  background: white;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid rgba(0, 0, 0, 0.05);
}

.tech-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--tech-color, #257eebc4);
  transition: all 0.3s ease;
}

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

.tech-icon {
  width: 48px;
  height: 48px;
  object-fit: contain;
  margin-bottom: 0.75rem;
  transition: transform 0.3s ease;
}

.tech-item:hover .tech-icon {
  transform: scale(1.1);
}

.tech-name {
  font-size: 0.8rem;
  font-weight: 600;
  color: #1f2937;
  text-align: center;
  margin-top: 0.5rem;
  transition: color 0.2s ease;
  pointer-events: none;
}

/* Large Desktop */
@media (min-width: 1600px) {
  .tech-stack-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 1.5rem;
    padding: 2rem 1rem;
  }
  
  .tech-icon {
    width: 56px;
    height: 56px;
  }
  
  .tech-name {
    font-size: 0.9rem;
    margin-top: 0.75rem;
  }
}

@media (min-width: 1200px) and (max-width: 1599px) {
  .tech-stack-grid {
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 1.25rem;
    padding: 1.5rem;
  }
  
  .tech-icon {
    width: 48px;
    height: 48px;
  }
  
  .tech-name {
    font-size: 0.85rem;
  }
}

@media (min-width: 992px) and (max-width: 1199px) {
  .tech-stack-grid {
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 1.25rem;
    padding: 1.25rem;
  }
  
  .tech-icon {
    width: 44px;
    height: 44px;
  }
  
  .tech-name {
    font-size: 0.8rem;
  }
}

@media (min-width: 768px) and (max-width: 991px) {
  .tech-stack-grid {
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    gap: 1rem;
    padding: 1rem;
  }
  
  .tech-item {
    padding: 1.25rem 0.5rem;
  }
  
  .tech-icon {
    width: 40px;
    height: 40px;
  }
  
  .tech-name {
    font-size: 0.75rem;
  }
}

@media (min-width: 576px) and (max-width: 767px) {
  .tech-stack-grid {
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 0.875rem;
    padding: 0.875rem;
  }
  
  .tech-item {
    padding: 1rem 0.5rem;
  }
  
  .tech-icon {
    width: 36px;
    height: 36px;
  }
  
  .tech-name {
    font-size: 0.7rem;
  }
}

@media (max-width: 575px) {
  .tech-stack-grid {
    grid-template-columns: repeat(auto-fill, minmax(90px, 1fr));
    gap: 0.75rem;
    padding: 0.75rem;
  }
  
  .tech-item {
    padding: 0.875rem 0.25rem;
  }
  
  .tech-icon {
    width: 32px;
    height: 32px;
  }
  
  .tech-name {
    font-size: 0.65rem;
    margin-top: 0.5rem;
  }
}

/* Animation */
.tech-stack-category {
  animation: fadeInUp 0.6s ease-out forwards;
  opacity: 0;
}

.tech-stack-category:nth-child(1) { animation-delay: 0.1s; }
.tech-stack-category:nth-child(2) { animation-delay: 0.2s; }
.tech-stack-category:nth-child(3) { animation-delay: 0.3s; }
.tech-stack-category:nth-child(4) { animation-delay: 0.4s; }

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(15px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
