@import url("https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,200;0,400;0,500;0,600;0,700;1,400&display=swap");

:root {
  --so-ink: #000;
  --so-muted: #8a8a8a;
  --so-line: #e5e5e5;
  --so-paper: #fdfdfd;
  --so-navy: #1f4790;
  --so-orange: #ff5500;
  --so-orange-deep: #e04c00;
  --so-input: #f4f4f4;
}

html,
body.so-auth-body,
body.vh-100 {
  min-height: 100%;
  min-height: 100dvh;
  margin: 0;
  font-family: Poppins, system-ui, sans-serif;
  background: var(--so-paper) !important;
  color: var(--so-ink);
  overflow-x: hidden;
}

body.so-auth-body,
body.so-auth-body * {
  box-sizing: border-box;
}

a {
  text-decoration: none;
}

.so-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.so-auth {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  width: 100%;
  overflow: hidden;
}

.so-auth-panel {
  position: relative;
  flex: 1 1 50%;
  display: grid;
  align-items: center;
  justify-items: center;
  padding: 48px 40px;
  background: #fff;
  overflow-y: auto;
}

.so-auth-back {
  position: absolute;
  top: 0;
  right: 0;
  z-index: 5;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 44px;
  background: var(--so-orange);
  color: #fff;
  border-radius: 0 0 0 15px;
  transition: background 0.2s ease;
}

.so-auth-back:hover,
.so-auth-back:focus-visible {
  background: var(--so-navy);
  outline: none;
}

.so-auth-back svg {
  width: 22px;
  height: 22px;
  display: block;
}

.so-auth-card {
  width: 100%;
  max-width: 420px;
  text-align: center;
}

.so-auth-head {
  border-bottom: 1px solid var(--so-line);
  margin-bottom: 36px;
}

.so-auth-brand {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin-bottom: 28px;
  color: var(--so-navy);
  font-weight: 700;
  letter-spacing: -0.02em;
  font-size: 1.35rem;
}

.so-auth-brand img {
  width: auto;
  height: auto;
  max-width: 220px;
  max-height: 72px;
  object-fit: contain;
}

.so-auth-card h1 {
  margin: 0 0 36px;
  font-size: 28px;
  font-weight: 600;
  color: #000;
  letter-spacing: 0;
}

.so-auth-card form {
  text-align: left;
}

.so-field {
  margin-bottom: 13px;
}

.so-field input[type="email"],
.so-field input[type="text"],
.so-field input[type="password"] {
  width: 100%;
  height: 52px;
  padding: 15px 24px;
  border: none;
  border-radius: 38px;
  background: var(--so-input);
  color: var(--so-ink);
  font-size: 14px;
  font-family: inherit;
  outline: none;
  appearance: none;
  -webkit-appearance: none;
}

.so-field input::placeholder {
  color: #9a9a9a;
  font-weight: 400;
}

.so-field input:focus {
  box-shadow: 0 0 0 3px rgba(255, 85, 0, 0.18);
}

.so-pass {
  position: relative;
}

.so-pass input {
  padding-right: 52px;
}

.so-pass-toggle {
  position: absolute;
  top: 50%;
  right: 8px;
  width: 40px;
  height: 40px;
  transform: translateY(-50%);
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--so-orange);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.so-pass-toggle svg {
  width: 20px;
  height: 20px;
  display: block;
}

.so-pass-toggle:hover,
.so-pass-toggle:focus-visible {
  background: rgba(255, 85, 0, 0.08);
  outline: none;
}

.so-btn {
  display: block;
  width: 100%;
  height: 52px;
  margin-top: 4px;
  border: 0;
  border-radius: 38px;
  background: var(--so-orange);
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.2s ease;
}

.so-btn:hover,
.so-btn:focus-visible {
  background: var(--so-orange-deep);
  outline: none;
}

.so-or {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 18px 0 14px;
  color: #9a9a9a;
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.so-or::before,
.so-or::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--so-line);
}

.so-google {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  height: 52px;
  border-radius: 38px;
  background: #fff;
  color: #3c4043 !important;
  border: 1px solid #dadce0;
  text-decoration: none !important;
  font-weight: 500;
  font-size: 14px;
  font-family: inherit;
}

.so-google:hover,
.so-google:focus-visible {
  background: #f8f9fa;
  outline: none;
}

.so-google-icon {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
}

.so-check {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 16px 0 0;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.4;
  color: #222;
}

.so-check input {
  width: 16px;
  height: 16px;
  accent-color: var(--so-orange);
}

.so-check.so-check-terms {
  justify-content: flex-start;
  text-align: left;
  margin: 8px 0 16px;
}

.so-check a {
  color: var(--so-orange);
  font-weight: 600;
}

.so-auth-links {
  margin-top: 20px;
  text-align: center;
  font-size: 14px;
  color: #000;
}

.so-auth-links a {
  color: var(--so-orange);
  font-weight: 600;
}

.so-auth-links p {
  margin: 8px 0 0;
  font-weight: 400;
}

.so-auth-links p a {
  font-weight: 600;
}

.so-alert {
  margin-bottom: 16px;
  padding: 12px 14px;
  border-radius: 14px;
  font-size: 14px;
  text-align: left;
}

.so-alert-ok {
  background: #e8f6ec;
  color: #215c34;
}

.so-alert-err,
.so-field .form-text.text-danger {
  background: #fdecea;
  color: #9b2c2c;
}

.so-field .form-text.text-danger {
  display: block;
  margin-top: 8px;
  padding: 8px 12px;
  border-radius: 12px;
  font-size: 13px;
}

.so-field .form-text.text-danger:empty {
  display: none;
}

.so-auth-art {
  position: relative;
  flex: 1 1 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 38px 36px 24px;
  background: var(--so-navy);
  overflow: hidden;
}

.so-auth-art-title {
  align-self: flex-start;
  margin: 0 0 12px;
  font-weight: 500;
  font-size: clamp(1.4rem, 2.4vw, 1.75rem);
  line-height: 1.25;
  color: #fff;
}

.so-auth-art-title span {
  display: block;
  font-weight: 200;
}

.so-auth-glow {
  position: absolute;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.16), transparent 68%);
  right: -80px;
  bottom: -60px;
  animation: so-float 7s ease-in-out infinite;
}

.so-auth-frame {
  position: relative;
  z-index: 1;
  width: min(420px, 86%);
  margin-top: auto;
  margin-bottom: auto;
}

.so-mascot {
  width: 100%;
  height: auto;
  display: block;
  transform-origin: 50% 80%;
  animation: so-bob 4.6s ease-in-out infinite;
}

.so-figure {
  transform-origin: 140px 268px;
  transition: transform 0.45s ease;
}

.so-hands {
  transform-box: fill-box;
  transform-origin: center;
  transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}

.so-mascot.is-looking .so-figure {
  transform: translateY(-4px);
}

.so-mascot.is-shy .so-hands {
  transform: translateY(-46px) scale(1.05);
}

.so-mascot.is-shy .so-brow-l {
  transform: translate(2px, 4px) rotate(12deg);
  transform-origin: 125px 122px;
}

.so-mascot.is-shy .so-brow-r {
  transform: translate(-2px, 4px) rotate(-12deg);
  transform-origin: 155px 122px;
}

.so-pupil {
  transition: transform 0.12s linear;
}

@keyframes so-bob {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-8px);
  }
}

@keyframes so-float {
  0%,
  100% {
    transform: translate3d(0, 0, 0);
  }
  50% {
    transform: translate3d(12px, -16px, 0);
  }
}

@media (max-width: 860px) {
  .so-auth {
    display: block;
    overflow: visible;
    width: 100%;
  }

  .so-auth-art {
    display: none;
  }

  .so-auth-panel {
    width: 100%;
    min-height: 100vh;
    min-height: 100dvh;
    padding: 56px 18px calc(28px + env(safe-area-inset-bottom, 0px));
    justify-items: stretch;
  }

  .so-auth-card {
    max-width: none;
    width: 100%;
    margin: 0 auto;
  }

  .so-auth-card h1 {
    font-size: 24px;
    margin-bottom: 28px;
  }

  .so-auth-head {
    margin-bottom: 28px;
  }

  .so-google,
  .so-auth-card .so-btn,
  .so-field input[type="email"],
  .so-field input[type="text"],
  .so-field input[type="password"] {
    width: 100%;
    font-size: 16px;
  }
}
