.gitHubButton { position: absolute; top: 10px; right: 10px; } @media screen and (max-width: 900px) { .gitHubButton { position: absolute; } } @media screen and (max-width: 575px) { .gitHubButton { top: 8px; right: 8px; } }