/* =========================================
   Shared "Explore More Work" project-discovery
   section, used at the end of every Product
   Design case study (and the homepage's
   secondary project grid).
   ========================================= */
.mw-section {
  padding: clamp(48px, 6vw, 88px) 0;
  background: #fff;
}

.mw-rail {
  max-width: 1200px;
  margin: 0 auto;
  padding-left: clamp(16px, 5vw, 5%);
  padding-right: clamp(16px, 5vw, 5%);
}

.mw-head {
  margin-bottom: clamp(20px, 3vw, 30px);
}

.mw-title {
  margin: 0;
  font: 800 clamp(1.4rem, 2.4vw, 1.9rem) / 1.2 "Montserrat", sans-serif;
  color: var(--ink-900, #10131a);
}

.mw-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(16px, 2vw, 24px);
  list-style: none;
  padding: 0;
  margin: 0;
}

@media (max-width: 900px) {
  .mw-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .mw-grid {
    grid-template-columns: 1fr;
  }
}

.mw-card__link {
  position: relative;
  display: block;
  text-decoration: none;
  color: inherit;
  border-radius: var(--radius-md, 14px);
}

.mw-card__fig {
  margin: 0;
  border-radius: var(--radius-sm, 10px);
  overflow: hidden;
  aspect-ratio: 16 / 10;
  background: #eaf3f8;
  border: 1px solid var(--line-soft, rgba(15, 23, 32, 0.08));
  transition: border-color var(--motion-standard, 0.28s) var(--ease-standard, ease),
    box-shadow var(--motion-standard, 0.28s) var(--ease-standard, ease);
}

.mw-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--motion-standard, 0.28s) var(--ease-standard, ease);
}

.mw-card__meta {
  padding: 12px 2px 0;
}

.mw-card__chip {
  margin: 0 0 4px;
  font: 700 0.72rem/1 "Montserrat", sans-serif;
  letter-spacing: 0.01em;
  color: var(--ink-500, #5d6a7e);
  text-transform: uppercase;
}

.mw-card__title {
  margin: 0 0 4px;
  display: flex;
  align-items: center;
  gap: 6px;
  font: 700 1.05rem/1.3 "Montserrat", sans-serif;
  color: var(--ink-900, #10131a);
  transition: color var(--motion-fast, 0.18s) var(--ease-standard, ease);
}

.mw-card__arrow {
  width: 15px;
  height: 15px;
  flex: 0 0 15px;
  transition: transform var(--motion-fast, 0.18s) var(--ease-standard, ease);
}

.mw-card__desc {
  margin: 0 0 6px;
  font-size: 0.9rem;
  line-height: 1.5;
  color: var(--ink-500, #5d6a7e);
}

.mw-card__badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 2px;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--surface-sunken, #f4f5f7);
  color: var(--ink-600, #4b4a4a);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}

@media (hover: hover) {
  .mw-card__link:hover .mw-card__fig {
    border-color: var(--blue, #398fba);
  }

  .mw-card__link:hover .mw-card__img {
    transform: scale(1.04);
  }

  .mw-card__link:hover .mw-card__title {
    color: var(--blue, #398fba);
  }

  .mw-card__link:hover .mw-card__arrow {
    transform: translateX(3px);
  }
}

.mw-card__link:focus-visible {
  outline: 2px solid var(--blue, #398fba);
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
  .mw-card__fig,
  .mw-card__img,
  .mw-card__title,
  .mw-card__arrow {
    transition: none !important;
  }
}

/* Two-item variant of the same grid (e.g. the Web Dev / UI-UX portfolio
   switcher) — same card, same proportions, just two columns instead of
   three so a short list doesn't leave a lopsided gap. */
@media (min-width: 601px) {
  .mw-grid--gateway {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-width: 760px;
    margin-inline: auto;
  }
}
