/* Mega menu logic */
.megamenu {
  position: relative;
}

.megamenu-content {
  display: none;
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%); /* centers it horizontally */
  
  background-color: #fff;
  padding: 30px;
  width: 90%;
  max-width: 900px; /* optional: max width to control layout */
  min-width: 500px;
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
  z-index: 999;

  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 30px;
}

/* Show on hover */
.megamenu:hover .megamenu-content {
  display: grid;
}

/* Columns */
.megamenu-column a {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  text-decoration: none;
  color: #333;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.3s ease;
}

.megamenu-column a:hover {
  color: #0077cc;
}

.megamenu-column img {
  margin-top: 10px;
  width: 48px;
  height: auto;
  transition: transform 0.3s ease;
}

.megamenu-column a:hover img {
  transform: scale(1.1);
}
