* {
  box-sizing: border-box;
}

body {
  font-family: "Roboto", sans-serif;
  padding-top: 44px;
}

.main {
  background: linear-gradient(
    180deg,
    rgba(245, 245, 245, 0) 1.04%,
    #f5f5f5 100%
  );
  padding-bottom: 2vh;
}

.container {
  max-width: 1200px;
  margin: auto;
}

.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 40px;
}

.input {
  background: #ffffff;
  border: 1px solid #d9d9d9;
  border-radius: 2px;
  height: 40px;
  min-width: 120px;
  font-size: 16px;
  line-height: 24px;
  padding-left: 35px;
  background-repeat: no-repeat;
  background-position: left 11px center;
}

.input-address {
  flex: 0.8;
  background-image: url(../img/home.svg);
}

.input-search {
  width: 300px;
  background-image: url(../img/search.svg);
}

.buttons {
  display: flex;
}

.button {
  align-items: center;
  flex-wrap: wrap;
  height: 40px;
  padding: 8px 15px;
  background: #ffffff;
  border: 1px solid #d9d9d9;
  box-sizing: border-box;
  box-shadow: 0px 0px 2px rgba(0, 0, 0, 0.0015);
  border-radius: 2px;
  color: #595959;
  font-size: 16px;
  cursor: pointer;
}

.button:hover {
  background: #f1f1f1;
}

.button-primary {
  background: #1890ff;
  border: 1px solid #1890ff;
  color: #fff;
  margin-right: 10px;
}

.button-primary:hover {
  background: #4ca6fa;
}

.button-icon {
  margin-right: 6px;
  vertical-align: middle;
}

.button-text {
  vertical-align: middle;
}

.promo {
  box-shadow: 0px 7px 12px rgba(158, 158, 163, 0.1);
  background: #fff1b8;
  border-radius: 10px;
  padding: 68px 78px;
  background-image: url(../img/banner.png);
  background-repeat: no-repeat;
  background-position: right -200px center;
  margin-bottom: 56px;
}

.promo-title {
  font-style: normal;
  font-weight: bold;
  font-size: 39px;
  line-height: 46px;
  color: #302c34;
}

.promo-text {
  max-width: 540px;
  font-style: normal;
  font-weight: normal;
  font-size: 24px;
  line-height: 28px;
  color: #302c34;
}

.restourant .section-heading {
  display: flex;
  justify-content: left;
}

.restourant .rating {
  margin-right: 26px;
  margin-left: 26px;
  font-weight: bold;
  font-size: 18px;
  line-height: 32px;
}

.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 44px;
}

.section-title {
  font-style: normal;
  font-weight: bold;
  font-size: 36px;
  line-height: 42px;
  color: #000000;
  margin: 0;
}

.cards {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
}

.card {
  background: #ffffff;
  box-shadow: 0px 4px 12px rgba(0, 0, 0, 0.05);
  border-radius: 7px;
  overflow: hidden;
  margin-bottom: 30px;
  flex-basis: 31%;
}

.card-image {
  width: 384px;
  height: 250px;
  object-fit: cover;
}

.card-text {
  padding-top: 20px;
  padding-bottom: 35px;
  padding-left: 23px;
  padding-right: 23px;
}

.card-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.card-title {
  margin: 0;
  font-style: normal;
  font-weight: bold;
  font-style: 24px;
  line-height: 32px;
}

.card-title > a {
  text-decoration: none;
  color: #000000;
}

.card-title > a:hover {
  color: #686868;
}

.card-tag {
  font-style: normal;
  font-weight: normal;
  font-style: 12px;
  line-height: 20px;
  color: #ffffff;
  background: #262626;
  border-radius: 2px;
  padding: 1px 8px;
}

.card-info {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
}

.rating {
  color: #ffc107;
  margin-right: 26px;
  font-weight: bold;
  font-size: 18px;
  line-height: 32px;
}

.price,
.category {
  font-size: 18px;
  line-height: 32px;
  color: #8c8c8c;
}

.price {
  margin-right: 10px;
}

.category {
  text-overflow: ellipsis;
  overflow: hidden;
  white-space: nowrap;
  max-width: 150px;
}

.price:after {
  content: "";
  width: 5px;
  height: 5px;
  background-color: #8c8c8c;
  display: inline-block;
  vertical-align: middle;
  border-radius: 50%;
  margin-left: 10px;
}

.restourant .card-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
}

.restourant .card-title {
  height: 45px;
  overflow: hidden;
  font-weight: normal;
  font-size: 20px;
  line-height: 25px;
}

.restourant .card-description {
  padding-top: 10px;
  padding-bottom: 25px;
  padding-right: 23px;
  font-size: 16px;
  line-height: 21px;
  color: #8c8c8c;
}

.restourant .card-price {
  font-weight: bold;
  font-size: 20px;
}

.footer {
  /* padding: 60px 0; */
}

.footer-block {
  height: 155px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-nav {
  margin-left: 35px;
  margin-right: auto;
}

.footer-link {
  display: inline-block;
  color: #595959;
  text-decoration: none;
  font-style: normal;
  font-weight: normal;
  font-size: 18px;
  line-height: 21px;
}

.footer-link:not(:last-child) {
  margin-right: 15px;
}

.social-links {
  display: flex;
  align-items: center;
}

.social-link:not(:last-child) {
  margin-right: 21px;
}

.modal {
  display: none;
  position: fixed;
  width: 100%;
  height: 100%;
  left: 0;
  top: 0;
  background: rgba(0, 0, 0, 0.4);
}

.show {
  display: flex;
}

.modal-dialog {
  width: 95%;
  max-width: 780px;
  /* min-height: 552px; */
  background: #ffffff;
  border-radius: 5px;
  margin: auto;
  padding: 40px 45px;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 45px;
}

.modal-title {
  margin: 0;
  font-style: normal;
  font-weight: bold;
  font-size: 36px;
  line-height: 42px;
}

.modal .close {
  font-size: 36px;
  border: none;
  background-color: transparent;
}

.modal .close:focus {
  border: none;
  border-radius: 5px;
  outline: -webkit-focus-ring-color auto 0px;
  background-color: rgba(212, 212, 212, 0.2);
}

.modal-body {
  margin-bottom: 52px;
}

.food-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding-bottom: 8px;
  border-bottom: 1px solid #d9d9d9;
  margin-bottom: 15px;
}

.food-name {
  font-size: 18px;
  line-height: 32px;
}

.food-price {
  margin-left: auto;
  margin-right: 47px;
  font-weight: bold;
  font-size: 20px;
  line-height: 32px;
}

.food-counter {
  display: flex;
  align-items: center;
}

.modal .counter-button {
  width: 39px;
  height: 32px;
  background: #ffffff;
  color: #40a9ff;
  border: 1px solid #40a9ff;
  box-sizing: border-box;
  border-radius: 2px;
  font-weight: normal;
  font-size: 14px;
  line-height: 22px;
}

.modal .counter {
  align-items: center;
  text-align: center;
  font-size: 16px;
  line-height: 24px;
  margin-left: 10px;
  margin-right: 10px;
}

.modal-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-buttons {
  display: flex;
  align-items: center;
}

.modal-pricetag {
  background: #262626;
  border-radius: 5px;
  color: #fff;
  padding: 15px 20px;
  font-size: 20px;
  line-height: 23px;
}

@media (max-width: 1366px) {
  .container {
    max-width: 960px;
  }
  .promo {
    background-size: 550px;
    background-position: center right -200px;
  }
  .category,
  .price {
    font-size: 14px;
    text-overflow: ellipsis;
  }
}

@media (max-width: 992px) {
  .container {
    max-width: 750px;
  }
  .promo {
    padding: 50px;
    background-size: 490px;
    background-position: center right -240px;
  }
  .promo-text {
    font-size: 18px;
    max-width: 400px;
  }
  .promo-title {
    font-size: 32px;
  }
  .card {
    flex-basis: 49%;
  }
  .footer-link {
    font-size: 16px;
  }
}

@media (max-width: 768px) {
  .container {
    max-width: 560px;
  }
  .promo {
    padding: 40px;
    background-size: 460px;
    background-position: center right -220px;
  }
  .promo-title {
    font-size: 24px;
    line-height: 32px;
  }
  .promo-text {
    font-size: 18px;
    line-height: 25px;
    max-width: 300px;
  }
  .card-title {
    font-size: 18px;
  }
  .card-info {
    flex-wrap: wrap;
  }
  .rating {
    flex-basis: 100%;
  }
  .restourant .rating {
    flex-basis: unset;
  }
}

@media (max-width: 578px) {
  .container {
    width: 90%;
  }
  .header {
    flex-wrap: wrap;
  }
  .input-address {
    flex-basis: 100%;
    margin-top: 15px;
    order: 5;
  }
  .promo {
    background-image: none;
  }
  .promo-title {
    margin-bottom: 10px;
  }
  .section-title {
    font-size: 20px;
  }
  .card {
    flex-basis: 100%;
  }
  .card-image {
    width: 100%;
  }
  .footer {
    padding: 30px 0;
  }
  .footer-block {
    align-items: flex-start;
  }
  .footer-nav {
    margin-left: 0;
    margin-right: 0;
    order: 0;
    display: flex;
    flex-direction: column;
  }
  .footer-logo {
    margin-right: 15px;
    order: 1;
  }
  .social-links {
    order: 2;
  }
}

@media (max-width: 480px) {
  .button {
    display: flex;
    min-height: 40px;
  }
  .button-icon {
    margin-right: 0;
  }
  .button-text {
    display: none;
  }
  .promo {
    padding: 20px;
    margin-bottom: 26px;
  }
  .section-heading {
    flex-wrap: wrap;
  }
  .input-search {
    width: 100%;
  }
  .footer-block {
    flex-wrap: wrap;
    flex-direction: column;
    align-items: center;
  }
  .footer-logo {
    order: 0;
    margin-bottom: 20px;
  }
  .footer-nav {
    margin-bottom: 20px;
    text-align: center;
  }
  .footer-link {
    line-height: 35px;
  }
  .footer-link:not(:last-child) {
    margin-right: 0;
  }
}
