@import '../component/header.css';
@import '../component/footer.css';

main {
  min-height: calc(100vh - var(--header-height) - 4vh);
}

h2.heading {
  padding: 80px 0;
  font-size: 42px;
  font-weight: bold;
  text-align: center;
  background-color: black;
  color: white;
}

/********* Intro */
.intro {
  height: calc(100vh - var(--header-height) - 2vh);
  background-color: white;
  margin: auto;
  text-align: center;
}

.intro .hook {
  padding: 20px 10px;
  height: 50%;
  box-sizing: border-box;
  background-image: url("/img/toyota-mr2.jpg");
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center right;
  display: grid;
  align-content: flex-end;
}

.hook p {
  font-size: 16px;
  line-height: 1.8;
  filter: none;
  color: white;
  margin-bottom: 0;
}

.hook .title {
  padding: 0 40px;
  font-size: 28px;
  font-weight: bold;
  line-height: 1.3;
  filter: none;
}

.intro .mailing-list {
  padding: 40px var(--master-padding);
  height: 50%;
  box-sizing: border-box;
  text-align: left;
  line-height: 1.3;
  display: grid;
  align-content: center;
  grid-gap: 10px;
}

.mailing-list .email-result {
  margin-top: 4px;
}

.email-form {
  display: grid;
  grid-auto-flow: row;
  grid-gap: 16px;
}

.email-form input, .email-form button {
  padding: 18px 12px;
  font-size: 1rem;
  border-radius: 2px;
}

.email-form input {
  border: 1px solid #ddd;
}

.email-form button {
  background-color: #cc0000;
  font-weight: bold;
  border: 0px;
  color: white;
}

.email-form button:hover {
  cursor: pointer;
}

@media only screen and (min-width: 600px) {
  .email-form {
    grid-auto-flow: column;
    grid-template-columns: 1fr auto;
  }

  .email-form button {
    min-width: 200px;
  }
}

/********* Listing */
.listing {
  margin: 0 auto;
  padding-bottom: 100px;
  display: grid;
  align-content: center;
  grid-gap: 30px;
}

.listing-item {
  border-radius: 2px;
  display: grid;
}

.listing-item a {
  background-color: #fafafa;
}

.listing-item img {
  margin: auto;
  max-height: 350px;
  display: block;
  width: 100%;
  object-fit: cover;
}

.listing-item .label {
  padding: 12px;
}

@media only screen and (min-width: 600px) {
  .listing {
    margin-top: 30px;
    padding-left: 20px;
    padding-right: 20px;
    max-width: 1300px;
    grid-auto-flow: row;
    grid-template-columns: repeat(2, 1fr);
  }

  .listing-item {
    grid-template-rows: 2fr 1fr;
  }

  .listing-item img {
    height: 100%;
    border-radius: 2px;
  }

  .listing-item .label {
    padding: 12px 0;
  }
}

@media only screen and (min-width: 1000px) {
  .listing {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media only screen and (min-width: 1200px) {
  .listing {
    grid-template-columns: repeat(4, 1fr);
  }
}
