/* Liquid glass skin for the Casdoor sign-in / sign-up pages. */
:root {
  color-scheme: light;
}
html,
body {
  min-height: 100%;
  background:
    radial-gradient(120% 90% at 12% -10%, rgba(150, 140, 255, 0.45) 0%, transparent 58%),
    radial-gradient(110% 80% at 88% 0%, rgba(120, 205, 255, 0.4) 0%, transparent 55%),
    radial-gradient(90% 80% at 50% 110%, rgba(255, 150, 220, 0.32) 0%, transparent 60%),
    linear-gradient(180deg, #fbfbff 0%, #eef1fb 100%) !important;
  background-attachment: fixed !important;
  font-family: "Inter Variable", Inter, -apple-system, BlinkMacSystemFont, "Segoe UI",
    "PingFang SC", "Microsoft YaHei", sans-serif !important;
}
html.dark,
html.dark body {
  background:
    radial-gradient(120% 90% at 10% -10%, rgba(120, 90, 240, 0.5) 0%, transparent 60%),
    radial-gradient(110% 80% at 92% 0%, rgba(60, 160, 220, 0.42) 0%, transparent 58%),
    radial-gradient(90% 80% at 50% 110%, rgba(190, 90, 220, 0.34) 0%, transparent 62%),
    linear-gradient(180deg, #171a2b 0%, #0e1019 100%) !important;
}

.login-page,
.login-page-wrapper {
  background: transparent !important;
}

.login-panel,
.login-panel-content,
.login-form,
.ant-card {
  background:
    linear-gradient(158deg, rgba(255, 255, 255, 0.78) 0%, rgba(255, 255, 255, 0.46) 52%, rgba(226, 232, 255, 0.4) 100%) !important;
  backdrop-filter: blur(28px) saturate(185%);
  -webkit-backdrop-filter: blur(28px) saturate(185%);
  border: 1px solid rgba(255, 255, 255, 0.65) !important;
  border-radius: 28px !important;
  box-shadow:
    0 32px 80px -34px rgba(40, 48, 110, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.85) !important;
}

html.dark .login-panel,
html.dark .login-panel-content,
html.dark .login-form,
html.dark .ant-card {
  background:
    linear-gradient(158deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 55%, rgba(120, 100, 220, 0.14) 100%) !important;
  border-color: rgba(255, 255, 255, 0.14) !important;
  box-shadow:
    0 36px 90px -36px rgba(0, 0, 0, 0.7),
    inset 0 1px 0 rgba(255, 255, 255, 0.16) !important;
}

.login-form .ant-input,
.login-form .ant-input-affix-wrapper,
.login-form .ant-input-password,
.login-form .ant-select-selector,
.ant-input,
.ant-input-affix-wrapper {
  background: rgba(255, 255, 255, 0.62) !important;
  border: 1px solid rgba(150, 160, 200, 0.35) !important;
  border-radius: 14px !important;
  box-shadow: inset 0 1px 3px rgba(40, 48, 110, 0.08) !important;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  color: #1d2130 !important;
}

html.dark .login-form .ant-input,
html.dark .login-form .ant-input-affix-wrapper,
html.dark .login-form .ant-input-password,
html.dark .ant-input,
html.dark .ant-input-affix-wrapper {
  background: rgba(255, 255, 255, 0.07) !important;
  border-color: rgba(255, 255, 255, 0.12) !important;
  color: #eef0ff !important;
}

.ant-btn,
.ant-btn-primary,
.login-button {
  border-radius: 999px !important;
  border: none !important;
  background: linear-gradient(150deg, #7c6cff 0%, #5a7bff 60%, #45a3ff 100%) !important;
  color: #fff !important;
  font-weight: 600 !important;
  box-shadow: 0 18px 38px -18px rgba(90, 100, 255, 0.6) !important;
  transition: transform 150ms ease, filter 200ms ease;
}
.ant-btn:hover,
.ant-btn-primary:hover,
.login-button:hover {
  filter: brightness(1.06);
}
.ant-btn:active,
.ant-btn-primary:active {
  transform: scale(0.985);
}

.ant-tabs-nav::before {
  border-bottom: none !important;
}
.ant-tabs-tab {
  border-radius: 999px !important;
  padding: 6px 16px !important;
  transition: background 180ms ease;
}
.ant-tabs-tab-active {
  background: rgba(124, 108, 255, 0.14) !important;
}
.ant-tabs-ink-bar {
  display: none !important;
}

.login-logo img,
.logo img {
  filter: drop-shadow(0 10px 24px rgba(90, 100, 255, 0.28));
}

.login-panel .title,
.login-panel h1,
.login-panel h2 {
  letter-spacing: -0.02em;
}

/* Living aurora behind the sign-in card. */
body::before {
  content: "";
  position: fixed;
  inset: -22%;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(38% 34% at 22% 28%, rgba(150, 140, 255, 0.55) 0%, transparent 70%),
    radial-gradient(32% 30% at 78% 22%, rgba(110, 200, 255, 0.45) 0%, transparent 72%),
    radial-gradient(40% 36% at 60% 82%, rgba(255, 150, 220, 0.4) 0%, transparent 74%);
  filter: blur(70px) saturate(120%);
  opacity: 0.65;
  animation: casdoor-aurora 26s ease-in-out infinite alternate;
}
html.dark body::before {
  background:
    radial-gradient(38% 34% at 22% 28%, rgba(120, 90, 240, 0.6) 0%, transparent 70%),
    radial-gradient(32% 30% at 78% 22%, rgba(60, 160, 220, 0.5) 0%, transparent 72%),
    radial-gradient(40% 36% at 60% 82%, rgba(190, 90, 220, 0.45) 0%, transparent 74%);
}
@keyframes casdoor-aurora {
  0% { transform: translate3d(-3%, -2%, 0) scale(1); }
  50% { transform: translate3d(2%, 3%, 0) scale(1.06); }
  100% { transform: translate3d(4%, -3%, 0) scale(1.02); }
}
@media (prefers-reduced-motion: reduce) {
  body::before { animation: none; }
}
/* Fine grain over the aurora. */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.03;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
  background-size: 160px 160px;
}
html.dark body::after { opacity: 0.05; }

/* Let the aurora show through the boot placeholder too. */
#casdoor-boot-fallback {
  background: transparent !important;
}
/* Layout polish: one steady column, generous air, a single clear action. */
.login-panel,
.login-panel-content {
  max-width: 440px !important;
  padding: 36px 34px 32px !important;
  border-radius: 32px !important;
}

.login-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.login-form .ant-form-item {
  margin-bottom: 0 !important;
}

.login-form .ant-input,
.login-form .ant-input-affix-wrapper,
.ant-input {
  min-height: 48px;
  font-size: 15px;
  padding: 12px 16px !important;
}

.login-form .ant-btn,
.login-form .login-button,
.ant-btn-primary {
  min-height: 48px;
  font-size: 15px;
  width: 100%;
}

.login-panel .title,
.login-panel h1,
.login-panel h2 {
  font-size: 26px !important;
  line-height: 1.2;
  margin-bottom: 6px !important;
  letter-spacing: -0.02em;
}

.login-logo {
  margin-bottom: 18px !important;
}

.login-logo img {
  width: 64px;
  height: 64px;
  border-radius: 18px;
}

.ant-tabs-nav {
  margin-bottom: 20px !important;
}

.ant-tabs-nav-list {
  gap: 6px;
}

@media (max-width: 480px) {
  .login-panel,
  .login-panel-content {
    max-width: 100% !important;
    margin: 16px !important;
    padding: 26px 22px 24px !important;
    border-radius: 26px !important;
  }
}

/* Entrance and focus states: the page should feel like it settles into place. */
@keyframes glass-in {
  from {
    opacity: 0;
    transform: translateY(16px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.login-panel,
.login-panel-content {
  animation: glass-in 520ms cubic-bezier(0.22, 0.8, 0.24, 1) both;
}

.login-form .ant-input:focus,
.login-form .ant-input-affix-wrapper-focused,
.ant-input:focus {
  border-color: rgba(124, 108, 255, 0.6) !important;
  box-shadow:
    0 0 0 3px rgba(124, 108, 255, 0.18),
    inset 0 1px 2px rgba(40, 48, 110, 0.06) !important;
}

.ant-form-item-explain-error {
  margin-top: 6px;
  font-size: 12px;
  line-height: 1.4;
}

.ant-btn:hover,
.login-button:hover {
  transform: translateY(-1px);
}

.ant-btn:active,
.login-button:active {
  transform: translateY(0) scale(0.99);
}

.ant-btn,
.login-button {
  transition:
    transform 160ms ease,
    filter 200ms ease,
    box-shadow 200ms ease;
}

a {
  color: #6a5cff;
}
html.dark a {
  color: #a89bff;
}

@media (prefers-reduced-motion: reduce) {
  .login-panel,
  .login-panel-content {
    animation: none;
  }
}