/* =========================================================
   Noor Shop - Categories Section
   ========================================================= */
.ns-categories {
  position: relative;
  padding: 88px 0 72px;
  background:
    radial-gradient(900px 280px at 90% 0%, rgba(136, 147, 70, 0.1), transparent 60%),
    radial-gradient(700px 240px at 0% 100%, rgba(7, 28, 31, 0.05), transparent 55%),
    #f7f9f8;
  overflow: hidden;
}

.ns-categories__header {
  max-width: 640px;
  margin: 0 auto 48px;
  text-align: center;
}

.ns-categories__eyebrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 0 0 14px;
  color: var(--ns-green);
  font-family: var(--ltn__heading-font, 'Rajdhani', sans-serif);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

html[lang="ar"] .ns-categories__eyebrow,
html[dir="rtl"] .ns-categories__eyebrow {
  letter-spacing: 0;
}

.ns-categories__eyebrow-line {
  width: 28px;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, #889346, #2a4a11);
}

.ns-categories__title {
  margin: 0 0 12px;
  color: var(--ns-ink);
  font-family: var(--ltn__heading-font, 'Rajdhani', sans-serif);
  font-size: clamp(1.9rem, 3.4vw, 2.75rem);
  font-weight: 700;
  line-height: 1.15;
}

.ns-categories__lead {
  margin: 0 auto;
  max-width: 42ch;
  color: var(--ns-muted);
  font-size: 1rem;
  line-height: 1.7;
}

.ns-categories__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.ns-cat-card {
  position: relative;
  display: block;
  min-height: 280px;
  border-radius: 18px;
  overflow: hidden;
  background: #133236;
  text-decoration: none !important;
  box-shadow: 0 12px 28px rgba(7, 28, 31, 0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.ns-cat-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 36px rgba(7, 28, 31, 0.14);
}

.ns-cat-card__media {
  position: absolute;
  inset: 0;
  display: block;
}

.ns-cat-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transform: scale(1.03);
  transition: transform 0.55s ease;
}

.ns-cat-card:hover .ns-cat-card__media img {
  transform: scale(1.1);
}

.ns-cat-card__fallback {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(145deg, #133236 0%, #2a4a11 100%);
  color: rgba(255, 255, 255, 0.55);
  font-size: 2.4rem;
}

.ns-cat-card__veil {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top,
      rgba(4, 17, 19, 0.88) 0%,
      rgba(4, 17, 19, 0.35) 45%,
      rgba(4, 17, 19, 0.08) 100%);
  transition: background 0.3s ease;
}

.ns-cat-card:hover .ns-cat-card__veil {
  background: linear-gradient(to top,
      rgba(4, 17, 19, 0.92) 0%,
      rgba(42, 74, 17, 0.45) 50%,
      rgba(4, 17, 19, 0.12) 100%);
}

.ns-cat-card__body {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  padding: 22px 20px;
  color: #fff;
}

.ns-cat-card__count {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: rgba(255, 255, 255, 0.88);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  backdrop-filter: blur(6px);
}

html[lang="ar"] .ns-cat-card__count,
html[dir="rtl"] .ns-cat-card__count {
  letter-spacing: 0;
  text-transform: none;
}

.ns-cat-card__name {
  font-family: var(--ltn__heading-font, 'Rajdhani', sans-serif);
  font-size: clamp(1.2rem, 1.8vw, 1.45rem);
  font-weight: 700;
  line-height: 1.25;
  color: #fff;
}

.ns-cat-card__cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
  color: #c5cf8a;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.25s ease, transform 0.25s ease, gap 0.25s ease, color 0.25s ease;
}

html[lang="ar"] .ns-cat-card__cta,
html[dir="rtl"] .ns-cat-card__cta {
  letter-spacing: 0;
  text-transform: none;
}

.ns-cat-card:hover .ns-cat-card__cta {
  opacity: 1;
  transform: translateY(0);
  color: #fff;
  gap: 11px;
}

@media (max-width: 1199px) {
  .ns-categories__grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 991px) {
  .ns-categories {
    padding: 72px 0 56px;
  }

  .ns-categories__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
  }

  .ns-cat-card {
    min-height: 240px;
  }
}

@media (max-width: 575px) {
  .ns-categories {
    padding: 56px 0 40px;
  }

  .ns-categories__header {
    margin-bottom: 28px;
  }

  .ns-categories__grid {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .ns-cat-card {
    min-height: 210px;
    border-radius: 14px;
  }

  .ns-cat-card__body {
    padding: 14px 12px;
  }

  .ns-cat-card__name {
    font-size: 1.05rem;
  }

  .ns-cat-card__cta {
    display: none;
  }
}
