/* Общие стили */
body {
  margin: 0;
  max-width: 1290px;
  font-family: "Noto Sans", Arial, sans-serif;
  line-height: 1.6;
  color: #333;
}

a {
  text-decoration: none;
  color: inherit;
}

.a-btn {
  text-decoration: none;
  color: inherit;
  text-align: center;
}

.btn {
  padding: 10px 20px;
  align-self: center;
  background: #4b7fb4;
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
}

.btn:hover {
  background: #33679b;
}

/* Шапка */
.header {
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  position: relative;
  padding: 20px;
  background-image: linear-gradient(to right, #f8fafc, #33679b);
  border-bottom: 1px solid #ddd;
}

.logo {
  width: 100%;
  max-width: 204px;
  min-width: 120px;
  height: auto;
}

.header-title {
  font-size: clamp(20px, 4vw, 28px);
  font-weight: 600;
  white-space: wrap;
  text-align: right;
  color: #fff;
 }

/* Hero */
.hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
  padding: 60px 20px;
  align-items: center;
  background: #e6eef2;
}

.hero-content {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 0px;
}

.hero-content h1 {
  font-size: clamp(18px, 2.5vw, 26px);;
  font-weight: 500;
  text-align: center;
  margin-block-start: 0;
  }

.hero-content p {
  font-size: clamp(14px, 2vw, 18px);
  font-weight: 300;
  text-align: left;
}

.img-container {
  display: flex;
  flex-direction: column;
}

.hero-img img {
  max-width: 100%;
  border-radius: 12px;
}

/* Карточки */
.cards {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 20px;
  padding: 20px 20px;
}

.card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
  padding: 20px;
  border: 1px solid #ddd;
  border-radius: 12px;
  background: white;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.card-title {
  flex: 1 1 80px;
  }

.card h2 {
  font-size: clamp(20px, 2.5vw, 24px);
  font-weight: 500;
  text-align: center;
  margin-block-start: 0px;
  margin-block-end: 0px;
}

.landing-image {
  max-width: 100%;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.card p {
  font-size: clamp(14px, 2vw, 18px);
  font-weight: 300;
  text-align: center;
}

/* Модалка скрыта по умолчанию */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0; top: 0;
  width: 100%; height: 100%;
  background: rgba(0,0,0,0.8);
  justify-content: center;
  align-items: center;
  flex-direction: column;
}

/* Картинка внутри */
.modal-content {
  max-width: 100%;
  max-height: 90%;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.5);
}

/* Подпись */
#modal-caption {
  margin-top: 15px;
  color: #fff;
  font-size: 16px;
  text-align: center;
}

/* Крестик закрытия */
.modal-close {
  position: absolute;
  top: 20px; right: 30px;
  color: #fff;
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
}
.modal-close:hover {
  color: #ffbf87;
}

footer {
  background-color: #4b7fb4;
  color: white;
  margin: 0 auto;
  text-align: center;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  position: relative;
  padding: 0 1.2rem;
}

#footer-email {
  font-size: clamp(12px, 2vw, 18px);
  font-weight: 400;
  text-align: left;
}

.scroll-top {
  display: none; /* скрыта по умолчанию */
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 45px;
  height: 45px;
  border-radius: 50%;
  background: white;
  color: #333;
  font-size: 22px;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(0,0,0,0.2);
  transition: opacity 0.3s ease;
  z-index: 999;
}
.scroll-top:hover {
  background: #ffbf87; /* твой акцентный цвет */
  color: white;
}

/* 📱 Мобильная версия */

@media (min-width: 1181px) {
  .hero-content p {
    margin-left: 50px;
    margin-right: 60px;
  }
  .hero-content h1 {
    margin-right: 30px;
  }
  }

@media (min-width: 1101px) and (max-width: 1180px) {
  .hero-content p {
    margin-left: 30px;
    margin-right: 30px;
  }
  .hero-content h1 {
    margin-right: 30px;
  }
  }

@media (min-width: 770px) and (max-width: 1100px) {
  .hero {
    gap: 30px;
  }
  
  .hero-text {
  line-height: 1.5;
  }

  .hero-text p {
  margin: 7px;
  font-size: 1.7vw;
   }
   }

@media (max-width: 769px) {
  .header {
    text-align: center;
    align-items: center;
    justify-content: space-evenly;
    padding: 15px 20px;
    position: relative;
  }

  .hero {
    grid-template-columns: 1fr; /* текст и картинка в одну колонку */
    text-align: center;
    gap: 20px;
  }

  .hero-text {
    align-items: center;
  }

  .cards {
    grid-template-columns: 1fr; /* карточки в одну колонку */
  }
}

@media (max-width: 500px) {
  .header-title {
    text-align: center;
  }
}

@media (max-width: 240px) {
  .hero {
    padding: 0px;
    min-width: 160px;
  }
  .landing-image {
  min-width: 150px;
  }

  h1, .header-title {
    font-size: 1.3em;
  }

  h2 {
    font-size: 1.2em;
  }

  p {
    font-size: 16px;
  }
  
  .cards {
  padding: 0px;
  min-width: 160px;
  }

  .card {
  padding: 5px;
  }
  footer {
  padding: 0 10px;
}
}