.GridRepCollection { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); margin: 0 auto; padding: 0; transition: opacity 0.14s ease-in-out; justify-items: center; // width: fit-content; width: auto; max-width: 996px; @media (max-width: $tablet) { grid-template-columns: minmax(320px, 1fr); max-width: inherit; width: 100%; } @media (max-width: $phone) { grid-template-columns: 1fr; max-width: inherit; width: 100%; } }