/* Site footer */
.site-footer {
  width: 100%;
  max-width: 1018px;
  margin: 16px auto 0;
  padding: 16px 20px;

  border-radius: 14px;
  box-sizing: border-box;
}

.site-footer__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.site-footer__link {
  display: inline-block;
  background: none;
  border: none;
  padding: 4px 0;
  margin: 0;
  font-size: 13px;
  line-height: 1.4;
  color: #000205;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color 0.15s ease;
}

.site-footer__link:hover,
.site-footer__link:focus-visible {
  color: #51a351;
}

@media screen and (min-width: 481px) {
  .site-footer__inner {
    flex-direction: row;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px 24px;
  }
}

@media screen and (min-width: 601px) {
  .site-footer {
    padding: 18px 24px;
  }

  .site-footer__link {
    font-size: 14px;
  }
}

/* Modal */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  padding: 16px;
  background: rgba(10, 12, 16, 0.65);
  align-items: center;
  justify-content: center;
  overflow-y: auto;
}

.modal-overlay.is-open {
  display: flex;
}

.modal {
  position: relative;
  width: 100%;
  max-width: 420px;
  max-height: 85vh;
  overflow-y: auto;
  background: #fff;
  border-radius: 16px;
  padding: 40px 20px 24px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
  box-sizing: border-box;
  animation: modal-pop 0.2s ease-out;
}

@keyframes modal-pop {
  from {
    opacity: 0;
    transform: scale(0.96);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

.modal__close {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 32px;
  height: 32px;
  border: none;
  background: transparent;
  color: #666;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, color 0.15s ease;
}

.modal__close:hover,
.modal__close:focus-visible {
  background: #f0f0f0;
  color: #000;
}

.modal__title {
  margin: 0 0 14px;
  padding-right: 24px;
  font-size: 19px;
  font-weight: 700;
  color: #14171f;
}

.modal__body {
  font-size: 14px;
  line-height: 1.6;
  color: #333;
}

.modal__body p {
  margin: 0 0 12px;
}

.modal__body p:last-child {
  margin-bottom: 0;
}

body.modal-open {
  overflow: hidden;
}

@media screen and (min-width: 601px) {
  .modal {
    max-width: 480px;
    padding: 44px 32px 32px;
  }

  .modal__title {
    font-size: 22px;
    margin-bottom: 16px;
  }

  .modal__body {
    font-size: 15px;
  }
}
