/* Ряд карточек.
   Класс один на все ряды — сколько бы абонементов ни добавили.
   align-items: stretch вместо flex-start: карточки в ряду тянутся
   до высоты самой высокой, и цена у всех оказывается на одной линии,
   а не там, где закончилось описание. */
.flex-container {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: stretch;
  color: white;
  text-align: center;
  margin-top: 50px;
  line-height: 2;
}

@media only screen and (max-width: 852.98px) {
  .flex-container {
    flex-direction: column;
  }
  /* У второго и следующих рядов верхний отступ лишний:
     в колонку карточки и так идут вплотную. */
  .flex-container + .flex-container {
    margin-top: 0px;
  }
}
.whole_abons{
  background-image: url(../images/abons/abonsbackground.webp);
  background-position: top;
  background-size: 100%;
}
.aboncontainer {
  display: flex;
  flex-direction: column;
  position: relative;
  line-height: 1.5;
  width: 28%;
  margin-top: 20px;
}

/* Цена прижимается к низу карточки — это и выравнивает её по ряду.
   У картинки и подписей вертикальный margin:auto приходится убрать:
   в растянутой колонке он начинает делить свободное место между всеми
   и съезжает вся карточка, а не только цена. */
.aboncontainer > .abonement { margin-top: 0; margin-bottom: 10px; }
.aboncontainer > .title     { margin-top: 0; margin-bottom: 0; }
.aboncontainer > .text1     { margin-top: 10px; margin-bottom: 10px; }
.aboncontainer > .text2     { margin-top: 0; margin-bottom: 0; }
.aboncontainer > a          { margin-top: auto; }

/* Отступ перед кнопкой «Запись онлайн»: раньше она прилипала
   к нижнему ряду цен. */
.abon-zapis {
  width: fit-content;
  margin: 45px auto 0;
}

@media only screen and (max-width: 852.98px) {
  /* В колонке карточки идут одна под другой, тянуть их незачем. */
  .aboncontainer > a {
    margin-top: 10px;
  }
  .abon-zapis {
    margin-top: 25px;
  }
}

.abonement {
  width: 90%;
  border-radius: 10px;
  margin: auto;
  transition: 0.2s ease-in-out;
  margin-bottom: 10px;
}

.abonement_back{
  opacity: 0;
  position: absolute;
  left: 5%;
  width: 90%;
  border-radius: 10px;
  margin-bottom: 10px;
  transition: 0.2s ease-in-out;
}
.abonement_back:hover {
  opacity: 1;
  transition: 0.2s ease-in-out;
}
.abonement:hover {
  opacity: 0;
  transition: 0.2s ease-in-out;
}

.title{
  font-family: 'Downcome';
  letter-spacing: normal;
  width: fit-content;
  margin: auto;
  transform: scaleX(1.5) skewX(4deg);
  font-style: italic;
  font-size: 20px;
}
.text1{
  font-size: 1.05rem;
  width: 90%;
  line-height: 1;
  margin: 10px auto;
}
.text2{
  font-size: 1.05rem;
  margin: auto;
  padding-top: 5px;
  width: fit-content;
}
.bottom{
  width: fit-content;
  padding: 0 5px 0 5px;
  margin: auto;
  margin-top: 10px;
  background: linear-gradient(180deg, rgba(52,52,52,1) 5%, rgba(10,234,9,1) 100%);
  border-radius: 7px;
  color: black;
  font-size: 25px;
  font-family: 'Downcome';
  letter-spacing: normal;
  transform: scaleX(1.5);
  cursor: pointer;
  /* font-style: italic; */
}
.contbottom{
width: 70%;
text-align: center;
margin: auto;
padding-bottom: 30px;
}
.contbottomtexttitle{
  font-size: 30px;
}

.contbottomtext{
  font-size: 13px;
}
@media only screen and (max-width: 1224px) {
  .title{
    font-size: 30px;
  }
  .text1{
    font-size: 0.8rem;
    width: 80%;
  }
  .text2{
    font-size: 0.8rem;
    padding-top: 5px;
  }
  .bottom{
    padding: 0 5px 0 5px;
    margin-top: 10px;
    font-size: 20px;
  }
}
@media only screen and (max-width: 924px) {
  .title{
    font-size: 25px;
  }
  .text1{
    font-size: 0.7rem;
    width: 80%;
  }
  .text2{
    font-size: 0.7rem;
    padding-top: 5px;
  }
  .bottom{
    padding: 0 5px 0 5px;
    margin-top: 10px;
    font-size: 15px;
  }
  .contbottom{
    padding-top: 50px;
    padding-bottom: 50px;
  }
  .contbottomtexttitle{
    font-size: 25px;
  }
  
  .contbottomtext{
    font-size: 8px;
  }
}
@media only screen and (max-width: 852.98px) {
  .aboncontainer {
    width: 80%;
    margin-top: 20px;
    margin: auto;
  }
  .text1{
    font-size: 0.9rem;
    width: 80%;
  }
  .text2{
    font-size: 0.9rem;
    padding-top: 5px;
  }
}
@media only screen and (max-width: 500px) {
  .aboncontainer {
    line-height: 1.9;
    margin-top: 0px;
    margin-bottom: 15px;
  }
.title{
  font-size: 28px;
  width: fit-content;
  margin: auto;
  right: 0;
  left: 0;
}
.text1{
  font-size: 15px;
  width: 90%;
}
.text2{
  font-size: 15px;
  width: 90%;
}
.bottom{
  font-size: 25px;
}
.contbottom{
width: 90%;
text-align: center;
margin: auto;
padding-top: 30px;
padding-bottom: 30px;
}
.contbottomtexttitle{
  font-size: 20px;
}

.contbottomtext{
  font-size: 14px;
}
}
@media only screen and (max-width: 410px) {
  .aboncontainer {
    line-height: 1.9;
    margin-top: 0px;
  }
.title{
  font-size: 26px;
  width: fit-content;
  margin: auto;
  right: 0;
  left: 0;
}
.text1{
  font-size: 14px;
  width: 90%;
}
.text2{
  font-size: 14px;
  width: 90%;
}
.bottom{
  font-size: 26px;
}
.contbottom{
width: 90%;
text-align: center;
margin: auto;
padding-top: 30px;
padding-bottom: 30px;
}
.contbottomtexttitle{
  font-size: 19px;
}

.contbottomtext{
  font-size: 14px;
}
}