#login-container,
#signup-container {
  padding: 24px;
  display: flex;
  gap: 24px;
  width: 100%;
  min-height: 100vh;
  box-sizing: border-box;
  align-items: stretch;
}

#login-container.center-container,
#signup-container.center-container {
  justify-content: center;
}

#login-container.full-height,
#signup-container.full-height {
  height: 100%;
}

.auth-block,
.auth-preview {
  width: 50%;
  flex: 1 1 50%;
  min-width: 0;
}

.auth-block {
  background-color: #fff;
  border-radius: 8px;
  padding: 50px 110px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 30px;
}

.logo-title {
  font-size: 30px;
  line-height: 1;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 30px;
}

.auth-field {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.auth-label {
  font-size: 20px;
  line-height: 1;
  text-align: start;
}

.auth-label span {
  color: #645ed6;
}

.auth-tip {
  font-size: 16px;
  line-height: 1;
  color: rgba(51, 51, 51, 0.5);
}

.auth-error {
  font-size: 16px;
  color: #B8044D;
}

.auth-field input {
  border-radius: 8px;
}
.auth-field input:focus {
  box-shadow: 0 0 0 0.0625rem #645ed6;
  border-color: #645ed6;
}

.auth-field input::placeholder {
  font-size: 18px;
  line-height: 1;
  color: rgba(51, 51, 51, 0.5);
}

.auth-rememberable {
  display: flex;
  justify-content: space-between;
}

.auth-checkbox {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 30px;
}

.auth-checkbox input[type=checkbox] {
  width: 30px;
  height: 30px;
  margin: 0;
  border-width: 2px;
}

.auth-checkbox input[type=checkbox]:active,
.auth-checkbox input[type=checkbox]:focus,
.auth-checkbox input[type=checkbox]:hover,
.auth-checkbox input[type=checkbox]:focus-visible,
.auth-checkbox input[type=checkbox]:checked {
  border-color: rgba(100, 94, 214, 0.5);
  box-shadow: none;
}

.auth-checkbox input[type=checkbox]:checked {
  background-color: #645ed6;
}

.auth-link {
  font-size: 20px;
  line-height: 1;
  color: #645ed6;
  text-decoration: none;
}

.auth-link:hover {
  text-decoration: underline;
}

.auth-button {
  background: linear-gradient(
    90deg,
    rgba(100, 94, 214, 1) 0%,
    rgba(109, 73, 253, 1) 60%,
    rgba(72, 66, 160, 1) 120%
  );
  background-size: 200% 100%;
  background-position: left center;
  color: #fff;
  border: none;
  padding: 12px 20px;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.3s ease;
  width: 100%;
  text-align: center;
  transition: background-position 0.6s ease;
}

.auth-button:hover {
  background-position: right center;
}

.auth-button--link {
  display: block;
  text-decoration: none;
  text-align: center;
}

.auth-button--secondary {
  background: #e2e8fc;
  color: #17204e;
  background-size: 100% 100%;
}

.auth-button--secondary:hover {
  background-position: center;
  opacity: 0.96;
}

.auth-form--role {
  gap: 10px;
}

.auth-role-subtitle {
  margin: -10px 0 0;
}

.auth-logo .logo-1 {
  width: 35px;
  height: auto;
}

.auth-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(51, 51, 51, 0.5);;
  font-weight: 600;
  font-size: 20px;
}

.auth-divider span{
  margin: 0 15px;
}

.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: rgba(51, 51, 51, 0.5);
}

.auth-bottom {
  text-align: center;
  color: rgba(51, 51, 51, 0.5);;
  font-size: 20px;
}

.auth-bottom-link {
  color: #333;
  margin-left: 4px;
  text-decoration: none;
  transition: 0.3s;
}

.auth-bottom-link:hover {
  color: rgba(100, 94, 214, 1);
}


.auth-preview {
  display: flex;
  max-width: 100%;
}

.auth-image {
  border-radius: 8px;
  width: 100%;
  height: 100%;
  min-height: 100%;
  object-fit: cover;
  display: block;
}

/* Role selection page (Figma 28) */
.role-page {
  --role-canvas: #f0f3fd;
  --role-primary: #645ed6;
  --role-secondary: #e2e8fc;
  --role-secondary-text: #17204e;
  --role-text: #18204f;
  --role-muted: #a7adbd;
  --role-promo-start: #6d49fd;
  --role-promo-end: #162e35;
  --role-screen-width: 1400px;
  --role-screen-height: 800px;

  position: fixed;
  inset: 0;
  z-index: 1;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: var(--role-canvas);
  font-family: Inter, Arial, sans-serif;
  color: var(--role-text);
}

.role-page__screen {
  position: relative;
  width: var(--role-screen-width);
  height: var(--role-screen-height);
  transform: scale(min(1, calc(100vw / 1400), calc(100vh / 800)));
  transform-origin: center center;
  overflow: hidden;
  background: var(--role-canvas);
}

.role-page__panel {
  position: absolute;
  top: 23px;
  left: 29px;
  width: 664px;
  height: 780px;
  background: #fff;
  border-radius: 9px;
  overflow: hidden;
}

.role-page__content {
  position: absolute;
  left: 108px;
  top: 246px;
  width: 451px;
}

.role-page__mark {
  display: block;
  width: 48px;
  height: auto;
  margin: 0 0 20px;
}

.role-page__title {
  margin: 0 0 5px;
  font-size: 28px;
  line-height: 35px;
  font-weight: 700;
  letter-spacing: -0.45px;
  color: var(--role-text);
}

.role-page__subtitle {
  margin: 0 0 27px;
  font-size: 13px;
  line-height: 19px;
  color: var(--role-muted);
}

.role-page__actions {
  display: grid;
  gap: 13px;
}

.role-page__button {
  width: 451px;
  height: 58px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 8px;
  color: var(--role-secondary-text);
  background: var(--role-secondary);
  font-size: 16px;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  transition: filter 0.16s ease, transform 0.08s ease;
}

.role-page__button--primary {
  color: #fff;
  background: var(--role-primary);
}

.role-page__button:hover {
  filter: brightness(1.04);
}

.role-page__button:active {
  transform: translateY(1px);
}

.role-page__promo {
  position: absolute;
  left: 700px;
  top: 27px;
  width: 664px;
  height: 781px;
  border-radius: 9px;
  overflow: hidden;
  background: linear-gradient(135deg, var(--role-promo-start) 0%, var(--role-promo-end) 100%);
}

.role-page__promo-logo {
  position: absolute;
  z-index: 2;
  left: 46px;
  top: 44px;
  width: 85px;
  height: 70px;
  object-fit: contain;
  display: block;
}

.role-page__promo-title {
  position: absolute;
  z-index: 2;
  left: 46px;
  top: 142px;
  width: 553px;
  margin: 0;
  color: #fff;
  font-size: 28px;
  line-height: 32px;
  font-weight: 700;
  letter-spacing: -0.25px;
}

.role-page__promo-shot {
  position: absolute;
  z-index: 1;
  left: 46px;
  top: 235px;
  width: 645px;
  height: auto;
  display: block;
  user-select: none;
  pointer-events: none;
}

.role-page__login {
  position: absolute;
  left: 108px;
  top: 80px;
  width: 451px;
}

.role-page__login-form {
  display: flex;
  flex-direction: column;
  gap: 22px;
  margin-top: 27px;
}

.role-page__field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.role-page__field label {
  font-size: 19px;
  line-height: 23px;
  font-weight: 400;
  color: var(--role-text);
}

.role-page__field label span {
  color: var(--role-primary);
}

.role-page__field input {
  width: 100%;
  height: 58px;
  padding: 0 19px;
  border: 1px solid #dde3ef;
  border-radius: 8px;
  outline: none;
  background: #fff;
  color: var(--role-text);
  font-size: 16px;
  line-height: 58px;
  box-sizing: border-box;
  transition: border-color 0.16s ease, box-shadow 0.16s ease;
}

.role-page__field input::placeholder {
  color: #8e96b0;
  opacity: 1;
}

.role-page__field input:focus {
  border-color: var(--role-primary);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--role-primary) 12%, transparent);
}

.role-page__options {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 34px;
}

.role-page__remember {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--role-text);
  font-size: 19px;
  line-height: 27px;
  cursor: pointer;
  user-select: none;
}

.role-page__remember input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.role-page__checkmark {
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  border: 1px solid #dde3ef;
  border-radius: 8px;
  background: #fff;
  display: grid;
  place-items: center;
}

.role-page__remember input:checked + .role-page__checkmark::after {
  content: "";
  width: 12px;
  height: 7px;
  border-left: 2px solid var(--role-primary);
  border-bottom: 2px solid var(--role-primary);
  transform: translateY(-1px) rotate(-45deg);
}

.role-page__link {
  color: var(--role-primary);
  text-decoration: none;
  font-size: 19px;
  line-height: 27px;
}

.role-page__link:hover {
  text-decoration: underline;
}

.role-page__submit {
  width: 100%;
  margin-top: 5px;
}

.role-page__divider {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 15px;
  color: #a9afbd;
  font-size: 19px;
  line-height: 24px;
  font-weight: 500;
}

.role-page__divider::before,
.role-page__divider::after {
  content: "";
  height: 1px;
  background: #dfe3eb;
}

.role-page__register {
  margin: 0;
  text-align: center;
  color: var(--role-muted);
  font-size: 16px;
  line-height: 24px;
}

.role-page__panel--form {
  display: flex;
  flex-direction: column;
}

.role-page__login--signup {
  top: 32px;
  right: 48px;
  bottom: 32px;
  left: 108px;
  width: auto;
  max-height: none;
  overflow-x: hidden;
  overflow-y: auto;
  padding-right: 8px;
  padding-bottom: 8px;
  box-sizing: border-box;
  -webkit-overflow-scrolling: touch;
}

.role-page__login--signup .role-page__mark {
  width: 40px;
  margin-bottom: 12px;
}

.role-page__login--signup .role-page__title {
  font-size: 24px;
  line-height: 30px;
}

.role-page__login--signup .role-page__subtitle {
  margin-bottom: 16px;
  font-size: 12px;
  line-height: 17px;
}

.role-page__login-form--compact {
  gap: 12px;
  margin-top: 16px;
}

.role-page__login-form--compact .role-page__field {
  gap: 6px;
}

.role-page__login-form--compact .role-page__field label {
  font-size: 16px;
  line-height: 20px;
}

.role-page__login-form--compact .role-page__field input {
  height: 48px;
  line-height: 48px;
  padding: 0 16px;
  font-size: 14px;
}

.role-page__login-form--compact .role-page__submit {
  margin-top: 0;
}

.role-page__login-form--compact .role-page__divider {
  font-size: 16px;
  line-height: 20px;
  gap: 12px;
}

.role-page__login-form--compact .role-page__register {
  font-size: 14px;
  line-height: 20px;
}

.role-page__error {
  font-size: 14px;
  line-height: 18px;
  color: #b8044d;
}

.role-page__hint {
  font-size: 14px;
  line-height: 18px;
  color: var(--role-muted);
  font-style: normal;
}

@media (max-width: 960px) {
  .role-page__screen {
    width: 100%;
    height: auto;
    min-height: 100vh;
    transform: none;
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 16px;
    overflow: auto;
  }

  .role-page__panel,
  .role-page__promo {
    position: static;
    width: 100%;
    max-width: 520px;
    margin: 0 auto;
    height: auto;
    min-height: 0;
  }

  .role-page__content,
  .role-page__login {
    position: static;
    width: min(451px, calc(100% - 48px));
    margin: 0 auto;
    padding: 33px 0 28px;
  }

  .role-page__login--signup {
    top: auto;
    right: auto;
    bottom: auto;
    left: auto;
    max-height: none;
    overflow: visible;
    padding-right: 0;
    padding-bottom: 0;
  }

  .role-page__login-form {
    margin-top: 20px;
  }

  .role-page__submit,
  .role-page__button {
    width: 100%;
  }

  .role-page__promo {
    min-height: 280px;
    padding-bottom: 24px;
  }

  .role-page__promo-logo,
  .role-page__promo-title {
    position: static;
    width: auto;
    margin: 24px 24px 0;
  }

  .role-page__promo-title {
    margin-bottom: 16px;
  }

  .role-page__promo-shot {
    position: static;
    display: block;
    width: calc(100% - 48px);
    max-width: 618px;
    margin: 0 auto;
  }
}