/**
 * Categories Section Styles
 *
 * @package BaitAlKaram
 */

.categories {
  padding: clamp(60px, 7vw, 96px) 0 clamp(24px, 4vw, 48px);
}

.categories-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: clamp(32px, 4vw, 48px);
}

.categories-heading p {
  margin: 0 0 6px;
  color: var(--red);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.5px;
}

.categories-heading h2 {
  margin: 0;
  font-size: clamp(28px, 3vw, 44px);
  font-weight: 700;
  color: var(--ink);
  line-height: 1.2;
}

.categories-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--red);
  font-size: 14px;
  font-weight: 600;
  padding-bottom: 6px;
  border-bottom: 1.5px solid var(--red);
  transition: all 0.3s ease;
}

.categories-link .jelly-arrow {
  width: 18px;
  height: 12px;
  transition: transform 0.32s ease;
}

.categories-link:hover {
  color: var(--red-deep);
  border-bottom-color: var(--red-deep);
}

.categories-link:hover .jelly-arrow {
  transform: translateX(-4px);
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(16px, 2.5vw, 36px);
}

.category-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  color: var(--ink);
  padding: 16px 12px;
  border-radius: 12px;
  transition: all 0.35s ease;
}

.category-image {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 50%;
  overflow: hidden;
  position: relative;
  display: block;
  background: #ffffff;
  border: 1px solid var(--line);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04);
  transition: border-color 0.38s ease, transform 0.38s ease, box-shadow 0.38s ease;
}

.category-image::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(186, 32, 41, 0) 40%, rgba(186, 32, 41, 0.25));
  opacity: 0;
  transition: opacity 0.38s ease;
}

.category-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.card-hob img { object-position: 80% center; }
.card-oven img { object-position: 78% center; }
.card-microwave img { object-position: center 32%; }
.card-hood img { object-position: center 46%; }

.category-name {
  margin-top: 18px;
  font-size: 17px;
  font-weight: 600;
  color: var(--ink);
  transition: color 0.32s ease;
}

.category-action {
  margin-top: 6px;
  color: var(--red);
  font-size: 13px;
  font-weight: 500;
  opacity: 0.85;
  transition: opacity 0.32s ease, transform 0.32s ease;
}

.category-card:hover {
  transform: translateY(-4px);
}

.category-card:hover .category-image {
  border-color: var(--red);
  box-shadow: 0 12px 28px rgba(186, 32, 41, 0.16);
  transform: scale(1.03);
}

.category-card:hover .category-image::after {
  opacity: 1;
}

.category-card:hover img {
  transform: scale(1.08);
}

.category-card:hover .category-name {
  color: var(--red);
}

.category-card:hover .category-action {
  opacity: 1;
  transform: translateY(-2px);
}

@media (max-width: 850px) {
  .category-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 24px 18px;
  }
}

@media (max-width: 700px) {
  .categories {
    padding: 48px 0 20px;
  }
  .categories-heading {
    align-items: flex-start;
    margin-bottom: 28px;
  }
  .categories-heading p { font-size: 12px; }
  .categories-heading h2 { font-size: 28px; }
  .categories-link { font-size: 13px; margin-top: 14px; }
  .category-name { font-size: 15px; margin-top: 14px; }
}
