*, *:before, *:after {
  box-sizing: border-box;
}

.grid {
  max-width: 1000px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
}
.grid-item {
  min-width: 250px;
  max-width: 250px;
  flex: 1 1 250px;
  padding-left: 0.5rem;
  padding-right: 0.5rem;
  margin-bottom: 1rem;
}

.wrapper {
  min-height: 100vh;
  padding: 2rem 0;
  background: #1b1b1b;
  color: #e4e4e8;
  text-align: center;
  font-family: "Arial", sans-serif;
}
.wrapper h1 {
  font-size: 2.125em;
  line-height: 1.5;
}
.wrapper p {
  font-size: 1em;
  line-height: 1.5;
  margin-bottom: 1rem;
  color: #c4c4c8;
}

.grid-item figure {
  padding: 0;
  margin: 0;
  box-shadow: 0px 0px 6px 0px rgba(0, 0, 0, 0.05);
}
.grid-item figure img {
  display: block;
  max-width: 100%;
}
.grid-item figcaption {
  display: block;
  font-style: bold;
  padding: 0.625rem 0.5rem;
  background: #474952;
}
/* Add a black background color to the top navigation */
.topnav {
  position: relative;
  background-color: #333;
  overflow: hidden;
}

/* Style the links inside the navigation bar */
.topnav a {
  float: left;
  color: #f2f2f2;
  text-align: center;
  padding: 18.5px 16px;
  text-decoration: none;
  font-family: "Arial", sans-serif;
  font-size: 17px;
}

/* Change the color of links on hover */
.topnav a:hover {
  background-color: #8a8a8a;
  color: black;
}

/* Add a color to the active/current link */
.topnav a.active {
  background-color: #04AA6D;
  color: white;
}

/* Centered section inside the top navigation */
.topnav-centered a {
  float: none;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

/* Right-aligned section inside the top navigation */
.topnav-right {
  float: right;
}

/* Responsive navigation menu - display links on top of each other instead of next to each other (for mobile devices) */
@media screen and (max-width: 600px) {
  .topnav a, .topnav-right {
    float: none;
    display: block;
  }

  .topnav-centered a {
    position: relative;
    top: 0;
    left: 0;
    transform: none;
  }
}
