@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;500;700&family=Roboto+Condensed:wght@400;700&display=swap');

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  position: relative;
  min-height: 100vh;
  overflow-x: hidden;
  background: #0047a8;
  font-family: "Roboto", Arial, Helvetica, sans-serif;
  color: #4b4b4b;
}

.page-bg {
  position: fixed;
  inset: 0;
  background: url("fon.jpg") center center / cover no-repeat;
  z-index: 0;
}

.page-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 56, 140, 0.14);
}

.topbar,
.main,
.footer {
  position: relative;
  z-index: 1;
}

.topbar {
  padding: 28px 0 0;
}

.brand {
  width: min(1080px, calc(100% - 48px));
  margin: 0 auto;
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.brand__logo {
  width: 56px;
  height: auto;
  flex: 0 0 auto;
}

.brand__text {
  color: #ffffff;
  text-transform: uppercase;
  line-height: 1.04;
  padding-top: 1px;
  font-family: "Roboto Condensed", "Arial Narrow", Arial, sans-serif;
}

.brand__small {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0;
  margin-bottom: 3px;
}

.brand__big {
  font-size: 26px;
  font-weight: 700;
  letter-spacing: 0;
}

.main {
  min-height: calc(100vh - 170px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 34px 24px 138px;
}

.login-card {
  width: 640px;
  max-width: 100%;
  background: #e9e9e9;
  border-radius: 2px;
  padding: 40px 60px 36px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.10);
}

.login-card__title {
  margin: 0 0 34px;
  text-align: center;
  font-size: 29px;
  line-height: 1.08;
  font-weight: 700;
  color: #5a5a5a;
  font-family: "Roboto Condensed", "Arial Narrow", Arial, sans-serif;
}

.tabs {
  border-bottom: 1px solid #bcbcbc;
  margin-bottom: 40px;
  display: flex;
  justify-content: flex-start;
}

.tabs__item {
  appearance: none;
  border: 0;
  background: transparent;
  padding: 0 0 17px;
  margin: 0 0 -1px 60px;
  font-size: 21px;
  line-height: 1;
  color: #1f66bf;
  font-weight: 700;
  border-bottom: 2px solid #1f66bf;
  cursor: default;
  letter-spacing: 0;
  font-family: "Roboto Condensed", "Arial Narrow", Arial, sans-serif;
}

.login-form__label {
  display: block;
  margin-bottom: 10px;
  font-size: 15px;
  font-weight: 400;
  color: #666666;
  font-family: "Roboto", Arial, Helvetica, sans-serif;
}

.login-form__input {
  width: 100%;
  height: 48px;
  border: 1px solid #b8b8b8;
  outline: none;
  background: #f3f3f3;
  padding: 0 15px;
  font-size: 15px;
  font-weight: 400;
  color: #666666;
  font-family: "Roboto", Arial, Helvetica, sans-serif;
  box-shadow: none;
}

.login-form__input::placeholder {
  color: #7d7d7d;
}

.login-form__input:focus {
  border-color: #1f66bf;
  background: #ffffff;
}

.login-form__actions {
  margin-top: 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.btn-next {
  width: 246px;
  max-width: 100%;
  height: 52px;
  border: 0;
  background: #bcbcbc;
  color: #ffffff;
  font-size: 17px;
  font-weight: 700;
  cursor: pointer;
  transition: opacity 0.2s ease;
  letter-spacing: 0;
  font-family: "Roboto Condensed", "Arial Narrow", Arial, sans-serif;
}

.btn-next:hover {
  opacity: 0.92;
}

.register-link {
  font-size: 16px;
  font-weight: 400;
  color: #1f66bf;
  text-decoration: none;
  font-family: "Roboto", Arial, Helvetica, sans-serif;
}

.register-link:hover {
  text-decoration: underline;
}

.login-form__note {
  margin: 28px 0 0;
  max-width: 470px;
  font-size: 14px;
  line-height: 1.35;
  color: #666666;
  font-family: "Roboto", Arial, Helvetica, sans-serif;
}

.footer {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  width: min(1080px, calc(100% - 48px));
  margin: 0 auto 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #ffffff;
}

.footer__left {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0;
  font-family: "Roboto Condensed", "Arial Narrow", Arial, sans-serif;
}

.footer__right {
  position: relative;
  color: #ffffff;
  text-decoration: none;
  font-size: 14px;
  font-weight: 400;
  padding-left: 34px;
  font-family: "Roboto", Arial, Helvetica, sans-serif;
}

.footer__right::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  width: 22px;
  height: 22px;
  transform: translateY(-50%);
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='22' viewBox='0 0 22 22' fill='none'%3E%3Cpath d='M7 14H4C3.44772 14 3 13.5523 3 13V4C3 3.44772 3.44772 3 4 3H13C13.5523 3 14 3.44772 14 4V7' stroke='white' stroke-width='1.6'/%3E%3Cpath d='M9 18H18C18.5523 18 19 17.5523 19 17V8C19 7.44772 18.5523 7 18 7H9C8.44772 7 8 7.44772 8 8V17C8 17.5523 8.44772 18 9 18Z' stroke='white' stroke-width='1.6'/%3E%3Cpath d='M11 10H16' stroke='white' stroke-width='1.6'/%3E%3Cpath d='M11 13H16' stroke='white' stroke-width='1.6'/%3E%3C/svg%3E");
}

.footer__right:hover {
  text-decoration: underline;
}

/* Модальное окно (без крестика, с иконкой) */
.modal {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: none;
}

.modal--open {
  display: block;
}

.modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.34);
}

.modal__window {
  position: absolute;
  top: 50%;
  left: 50%;
  width: min(720px, calc(100% - 40px));
  height: auto;
  min-height: 300px;
  max-height: 80vh;
  overflow-y: auto;
  transform: translate(-50%, -50%);
  background: #ffffff;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.25);
  border-radius: 18px;
}

.modal__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 20px 0;
}

.modal__title {
  font-size: 24px;
  font-weight: 700;
  color: #d32f2f;      /* красный */
  text-align: center;
  margin-bottom: 20px;
  font-family: "Roboto Condensed", "Arial Narrow", Arial, sans-serif;
}

.modal__icon {
  width: 80px;          /* увеличенная иконка */
  height: auto;
  margin-bottom: 20px;
}

.modal__message {
  font-size: 16px;
  line-height: 1.4;
  color: #333;
  text-align: left;
  margin-bottom: 20px;
  padding: 0 0.5cm;
  white-space: normal;
  word-break: break-word;
}

.modal__numbers {
  text-align: left;
  padding: 0 0.5cm;
  font-size: 16px;
  font-weight: 500;
  color: #1f66bf;
}

.modal__number {
  margin-top: 8px;
  white-space: nowrap;
}

.modal__content {
  width: 100%;
  padding: 0 0.5cm;
  font-size: 18px;
  line-height: 1.5;
  white-space: pre-line;
  word-break: break-word;
  color: #333;
  text-align: left;
}

@media (max-width: 900px) {
  .brand__logo {
    width: 52px;
  }

  .brand__small {
    font-size: 10px;
  }

  .brand__big {
    font-size: 23px;
  }

  .login-card {
    padding: 34px 28px 30px;
  }

  .tabs__item {
    margin-left: 0;
    font-size: 19px;
  }

  .login-card__title {
    font-size: 25px;
  }

  .footer {
    width: calc(100% - 32px);
    margin-bottom: 18px;
  }

  .footer__left {
    font-size: 16px;
  }

  .footer__right {
    font-size: 14px;
  }
}

@media (max-width: 640px) {
  .topbar {
    padding-top: 20px;
  }

  .brand {
    width: calc(100% - 32px);
    gap: 12px;
  }

  .brand__logo {
    width: 46px;
  }

  .brand__big {
    font-size: 20px;
  }

  .main {
    padding: 30px 16px 120px;
  }

  .login-card {
    padding: 28px 20px 24px;
  }

  .login-card__title {
    font-size: 22px;
  }

  .tabs {
    margin-bottom: 28px;
  }

  .tabs__item {
    font-size: 18px;
  }

  .login-form__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .btn-next {
    width: 100%;
  }

  .register-link {
    text-align: center;
  }

  .footer {
    position: relative;
    width: calc(100% - 32px);
    margin: 0 auto 20px;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .footer__right {
    padding-left: 30px;
  }

  .footer__right::before {
    width: 20px;
    height: 20px;
  }

  .modal__window {
    width: calc(100% - 32px);
  }
} /* ← закрываем медиазапрос @media (max-width: 640px) */

/* Активная кнопка (синяя) – должна быть вне медиазапроса */
.btn-next--active {
  background: #ff8833;
  cursor: pointer;
}

.btn-next--active:hover {
  background: #e67300;
  opacity: 0.92;
}
.btn-spinner {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 2px solid #fff;
  border-radius: 50%;
  border-top-color: transparent;
  animation: spin 0.6s linear infinite;
  vertical-align: middle;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.btn-next--active {
  background: #ff8833;
  cursor: pointer;
}

.btn-next--active:hover {
  background: #e67300;
  opacity: 0.92;
}
}