@font-face {
  font-family: 'Avenir Next';
  src: url('/assets/fonts/AvenirNextCyr-Regular.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
}

@font-face {
  font-family: 'Avenir Next';
  src: url('/assets/fonts/AvenirNextCyr-Demi.ttf') format('truetype');
  font-weight: 600;
  font-style: normal;
}

@font-face {
  font-family: 'Avenir Next';
  src: url('/assets/fonts/AvenirNextCyr-Bold.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
:root {
  --login-blue: #0048ff;
  --login-blue-light: #a7d6ff;
  --login-blue-hover: #0048ff;
}
body {
  font-family: "Avenir Next", sans-serif;
  background: #fff;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}
body > form {
  height: auto;
}
.card {
  width: 100%;
  max-width: 390px;
  min-height: 100svh;
  background: #fff;
  position: relative;
  overflow: hidden;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 40px 80px;
}
.card::before {
  content: "";
  position: absolute;
  top: -35%;
  left: -65%;
  width: 90%;
  height: 170%;
  background: linear-gradient(
    110deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(110, 178, 255, 0.08) 46%,
    rgba(255, 255, 255, 0.52) 50%,
    rgba(110, 178, 255, 0.08) 54%,
    rgba(255, 255, 255, 0) 100%
  );
  transform: rotate(-12deg);
  filter: blur(3px);
  animation: aurora-sweep 10.5s ease-in-out infinite;
  pointer-events: none;
  z-index: 0;
}
.logo-wrap {
  margin-bottom: 52px;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  opacity: 0;
  transform: translateY(10px);
  animation: reveal-up 540ms cubic-bezier(0.2, 0.8, 0.2, 1) 80ms forwards;
}
.logo-wrap > img {
  width: 100%;
}
.tagline {
  display: flex;
  align-items: center;
  margin-bottom: 40px;
  user-select: none;
  flex-wrap: nowrap;
  opacity: 0;
  transform: translateY(10px);
  animation: reveal-up 520ms cubic-bezier(0.2, 0.8, 0.2, 1) 180ms forwards;
}
.word-group {
  display: inline-flex;
  cursor: default;
}
.letter-cap {
  font-size: 18px;
  font-weight: 700;
  color: var(--login-blue);
  line-height: 1;
  transition: color 0.15s;
}
.letter-rest {
  font-size: 13px;
  font-weight: 400;
  color: var(--login-blue-light);
  line-height: 1;
  transition: color 0.15s, font-weight 0.15s;
  align-self: flex-end;
  padding-bottom: 1px;
}
.word-group:hover .letter-rest {
  color: var(--login-blue-hover);
  font-weight: 700;
}
.word-group:hover .letter-cap {
  color: var(--login-blue-hover);
}
.tl-dot {
  width: 5px;
  height: 5px;
  background: var(--login-blue-light);
  margin: 0 7px 3px;
  flex-shrink: 0;
}

.form {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 28px;
  opacity: 0;
  transform: translateY(10px);
  animation: reveal-up 520ms cubic-bezier(0.2, 0.8, 0.2, 1) 280ms forwards;
}

.deploy-alert {
  width: 100%;
  border-radius: 12px;
  padding: 12px 14px;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.45;
  border: 1px solid transparent;
}
.deploy-alert-danger {
  color: #8f1d2c;
  background: #ffe9ec;
  border-color: #ffc7cf;
}
.deploy-alert-info {
  color: #1f4f84;
  background: #eaf4ff;
  border-color: #c8e1ff;
}
.input-wrap {
  position: relative;
  width: 100%;
}
.input-wrap label {
  display: block;
  font-size: 11px;
  font-weight: 600;
  color: #888;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 6px;
  padding-left: 4px;
  transition: color 0.15s;
}
.input-wrap:focus-within label {
  color: var(--login-blue);
}
.input-wrap input {
  width: 100%;
  border: 1.5px solid #e0e6f0;
  border-radius: 12px;
  padding: 13px 44px 13px 16px;
  font-size: 15px;
  font-family: "Avenir Next", sans-serif;
  font-weight: 600;
  color: #111;
  background: #fafbff;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}
.input-wrap input::placeholder {
  color: #c0c8d8;
  font-weight: 400;
}
.input-wrap input:focus {
  border-color: var(--login-blue);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(0, 72, 255, 0.08);
}
.input-wrap .icon {
  position: absolute;
  right: 14px;
  bottom: 14px;
  color: #b0bcd0;
  pointer-events: none;
  transition: color 0.15s;
}
.input-wrap:focus-within .icon {
  color: var(--login-blue);
}
.input-wrap .toggle-pw {
  pointer-events: all;
  cursor: pointer;
}
.forgot {
  align-self: flex-end;
  font-size: 12px;
  font-weight: 600;
  color: var(--login-blue);
  text-decoration: none;
  margin-top: -4px;
  opacity: 0.75;
  transition: opacity 0.15s;
}
.forgot:hover {
  opacity: 1;
}

.btn-signin {
  width: 100%;
  background: var(--login-blue);
  color: #fff;
  border: none;
  border-radius: 12px;
  position: relative;
  overflow: hidden;
  padding: 15px;
  font-size: 16px;
  font-family: "Avenir Next", sans-serif;
  font-weight: 700;
  cursor: pointer;
  letter-spacing: 0.03em;
  transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
  box-shadow: 0 6px 22px rgba(0, 72, 255, 0.28);
  opacity: 0;
  transform: translateY(10px);
  animation: reveal-up 520ms cubic-bezier(0.2, 0.8, 0.2, 1) 380ms forwards;
}
.btn-signin:hover {
  background: var(--login-blue-hover);
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(4, 138, 255, 0.35);
}
.btn-signin:active {
  transform: translateY(0);
}
.btn-signin:disabled {
  opacity: 0.7;
  transform: none;
  cursor: not-allowed;
}
.btn-signin:disabled::before {
  animation: none;
  opacity: 0;
}

@keyframes aurora-sweep {
  0%,
  100% {
    transform: translateX(0) rotate(-12deg);
    opacity: 0.52;
  }
  50% {
    transform: translateX(220%) rotate(-12deg);
    opacity: 0.86;
  }
}

@keyframes reveal-up {
  from {
    opacity: 0;
    transform: translateY(50px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (min-width: 640px) {
  body {
    background: linear-gradient(135deg, #e8f0ff 0%, #f5f8ff 50%, #e0eaff 100%);
  }
  .card {
    min-height: unset;
    border-radius: 28px;
    box-shadow: 0 32px 80px rgba(0, 72, 255, 0.11),
      0 2px 8px rgba(0, 0, 0, 0.05);
    padding: 90px 80px;
  }
}
