@import url(fonts.css);
@import url(constants.css);
@import url(default.css);
@import url(header.css);
@import url(footer.css);
@import url(dialog.css);
@import url(close-button.css);
@import url(loader.css);

.article {
  position: relative;
  width: 370px;
}

.create-article {
  display: flex;
  flex-direction: column;
  justify-content: center;
  margin-top: 30px;
}

.create-article__header {
  display: none;
  justify-content: flex-end;
}

.create-article__form {
  display: none;
  flex-direction: column;
  row-gap: 16px;
  font-style: normal;
  font-weight: 400;
  font-size: 18px;
  line-height: 22px;
  color: var(--font-color--addtional-footer);
}

.create-artilce__form-item {
  width: clamp(230px, 27vw, 520px);
  background-color: transparent;
  border: 1px solid var(--border-color--form);
  border-radius: 5px;
  padding: 18px;
}

.create-artilce__form-item::placeholder {
  font-style: normal;
  font-weight: 400;
  font-size: 18px;
  line-height: 22px;
  color: var(--font-color--placeholder-form);
}

.create-article__button {
  width: 175px;
  height: 50px;
  border-radius: 5px;
  border-color: transparent;
  font-style: normal;
  font-weight: 400;
  font-size: 18px;
  line-height: 22px;
  cursor: pointer;
  transition: all 0.5s ease-in-out;
}

.create-article__button:disabled {
  background-color: var(--background-color--form-buttons-disabled) !important;
  color: white !important;
  cursor: default;
  pointer-events: none;
}

.create-article__button.under-list {
  position: relative;
  z-index: -2;
}

.create-article__submit-button {
  color: var(--background-color--subimt-button-aticle--pale);
  background-color: var(--background-color--subimt-button-aticle);
}

.create-article__refresh-button {
  color: var(--background-color--subimt-button-aticle);
  background-color: var(--background-color--subimt-button-aticle--pale);
}

.article__content {
  border-radius: 5px;
}

.article__date {
  font-style: normal;
  font-weight: 500;
  font-size: 18px;
  line-height: 26px;
  letter-spacing: -0.01em;
}

.article__information {
  font-style: normal;
  font-weight: 400;
  font-size: 15px;
  line-height: 18px;
  letter-spacing: -0.01em;
  color: var(--font-color--addtional);
}

.frontend-article {
  background-color: var(--background-color--frontend);
}

.tennis-article {
  background-color: var(--background-color--tennis);
}

.article__foto {
  border-radius: 5px;
  background-image: url(../assets/article-foto.png);
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  height: 220px;
}

.article__text {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 8px;
  row-gap: 20px;
}

.articles {
  margin-top: 30px;
}

.articles__container {
  margin-top: 30px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 5px;
}

.articles__container:not(:has(.article)) {
  justify-content: center;
}

.articles__container:not(:has(.article))::after {
  content: "Нет статей";
  text-align: center;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100px;
  height: 100px;
  font-style: normal;
  font-weight: 400;
  font-size: 16px;
  line-height: 19px;
  color: var(--font-color--addtional);
}

.article:first-child {
  width: 100%;
}

.article:first-child .article__foto {
  padding: 5px;
  height: 35vw;
  max-height: 600px;
}

.article:not(:first-child) .article__information {
  display: none;
}
.article:not(:first-child) .article__date {
  font-style: normal;
  font-weight: 400;
  font-size: 16px;
  line-height: 19px;
  color: var(-font-color--general);
}
.article:not(:first-child) .article__article-header {
  font-style: normal;
  font-weight: 400;
  font-size: 24px;
  line-height: 29px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.create-article__buttons {
  width: clamp(230px, 27vw, 520px);
  display: flex;
  flex-direction: row;
  justify-content: start;
  align-items: center;
  gap: 15px;
}

.create-artilce__form-item:focus {
  border-color: var(--background-color--subimt-button-aticle);
  box-shadow: 0 0 5px rgb(219, 94, 49, 0.5);
  outline: none;
}

.create-article__input-type {
  display: none;
}

.articles__main {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 30px;
}

.articles__image {
  width: 216px;
  height: 213px;
  background-color: transparent;
  background-image: url(../assets/something.png);
}

.midfull-thought {
  display: inline-block;
  font-style: normal;
  font-weight: 400;
  font-size: 20px;
  line-height: 29px;
  color: var(--font-color--addtional);
  max-width: 900px;
}

.create-article__curtain {
  display: none;
  position: relative;
  left: 0px;
  width: 87vw;
  background-color: white;
}

@media (max-width: 1330px) {
  .articles__main {
    justify-content: space-around;
  }
  .midfull-thought {
    max-width: none;
  }
}

@media (max-width: 1300px) {
  .articles__container {
    justify-content: space-around;
  }
}

@media (max-width: 1010px) {
  .article {
    width: 100%;
  }
  .article__foto {
    height: 44vw;
  }
}

@media (max-width: 636px) {
  .wrapper {
    padding: 0 5px;
  }
  .create-article {
    align-items: center;
  }
  .header__content {
    justify-content: space-around;
  }
  .articles__header,
  .articles__title,
  .midfull-thought {
    text-align: center;
  }
  .article {
    width: clamp(370px, 50vw, 560px);
  }
  .create-article__form {
    align-items: center;
  }
  .create-article__buttons {
    flex-direction: column;
  }
}

@media (max-width: 468px) {
  .contacts__content {
    flex-direction: column;
    align-items: center;
  }
}

@media (hover: hover) {
  .create-article__submit-button:hover {
    background-color: var(--background-color--subimt-button-aticle--pale);
    color: var(--background-color--subimt-button-aticle);
  }
  .create-article__refresh-button:hover {
    color: var(--background-color--subimt-button-aticle--pale);
    background-color: var(--background-color--subimt-button-aticle);
  }
  .custom-select__item:hover {
    background-color: var(--background-color--subimt-button-aticle);
    cursor: pointer;
  }
}

@media (hover: none) {
  .create-article__submit-button:active {
    background-color: var(--background-color--subimt-button-aticle--pale);
    color: var(--background-color--subimt-button-aticle);
  }
  .create-article__refresh-button:active {
    color: var(--background-color--subimt-button-aticle--pale);
    background-color: var(--background-color--subimt-button-aticle);
  }
  .custom-select__item:active {
    background-color: var(--background-color--subimt-button-aticle);
    cursor: pointer;
  }
}

.custom-select {
  position: relative;
  width: clamp(230px, 27vw, 520px);
  background-color: white;
  border: 1px solid var(--border-color--form);
  border-radius: 5px;
  padding: 18px;
  color: black;
  cursor: pointer;
  transition: all 0.5s ease-in-out;
}

.custom-select:focus {
  border-color: var(--background-color--subimt-button-aticle);
  box-shadow: 0 0 5px rgb(219, 94, 49, 0.5);
  outline: none;
}

.custom-select__arrow {
  width: 20px;
  height: 20px;
  background-color: transparent;
  position: absolute;
  top: calc(50% - 10px);
  right: 3%;
  transition: all 0.5s ease-in-out;
  padding-left: 5px;
  box-sizing: border-box;
}

.custom-select__arrow.rotate {
  transform: rotate(90deg);
}

.custom-select__arrow::after,
.custom-select__arrow::before {
  display: block;
  content: "";
  width: 10px;
  height: 2px;
  background-color: black;
  position: absolute;
}

.custom-select__arrow::after {
  transform: rotate(45deg);
  top: calc(50% - 3px);
}

.custom-select__arrow::before {
  transform: rotate(-45deg);
  top: calc(50% + 3px);
}

.custom-select__item {
  color: var(--font-color--addtional);
  width: 80%;
  padding: 10px;
  position: absolute;
  transform: translateY(-75%);
  z-index: -1;
  transition:
    transform 0.5s ease-in-out,
    background-color 0.5s ease-in-out;
  background-color: white;
  border-bottom: 1px solid black;
  border-right: 1px solid black;
  border-left: 1px solid black;
}

.custom-select__item_last {
  border-bottom-left-radius: 5px;
  border-bottom-right-radius: 5px;
}

.custom-select__item.rotate {
  z-index: auto;
}
