@charset "UTF-8";

:root {
  --sl-brand: #d63384;
  --sl-brand-deep: #a0265a;
  --sl-brand-soft: #fff0f6;
  --sl-ink: #111111;
  --sl-muted: #6b6b6b;
  --sl-line: #f3e2de;
  --sl-surface: #ffffff;
  --sl-page: #fff6f4;
  --sl-auth-background-image: url("/static/index/images/auth/auth_bg.jpg");
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body.sl-auth-body {
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--sl-brand);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: #fff;
  -webkit-font-smoothing: antialiased;
}

.sl-auth {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 440px;
  min-height: 100vh;
  min-height: 100dvh;
  margin: 0 auto;
  color: #fff;
}

.sl-auth::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  background-color: var(--sl-brand);
  background-image:
    linear-gradient(180deg, rgba(50, 17, 35, 0.14) 0%, rgba(39, 12, 32, 0.64) 100%),
    var(--sl-auth-background-image);
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
}

.sl-auth-hero {
  position: relative;
  z-index: 1;
  display: flex;
  flex: 1 0 auto;
  flex-direction: column;
  padding: env(safe-area-inset-top) 20px 34px;
}

.sl-auth-toolbar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  height: 56px;
}

.sl-auth-lang {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  max-width: 60%;
  min-height: 36px;
  margin-right: -4px;
  padding: 0 12px 0 10px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  transition: background 0.18s ease;
}

.sl-auth-lang svg {
  flex: 0 0 18px;
  width: 18px;
  height: 18px;
}

.sl-auth-lang span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sl-auth-lang:active {
  background: rgba(255, 255, 255, 0.32);
}

.sl-auth-hero-inner {
  position: relative;
  z-index: 1;
  margin: auto 0;
  padding: 8px 0;
}

.sl-auth-logo {
  display: grid;
  place-items: center;
  width: clamp(120px, 22vh, 180px);
  aspect-ratio: 1;
  margin: clamp(4px, 2vh, 20px) auto 0;
}

.sl-auth-logo img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
  border-radius: 20px;
}

.sl-auth-logo-fallback {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  border-radius: 24px;
  background: linear-gradient(135deg, var(--sl-brand), var(--sl-brand-deep));
  color: #fff;
  font-size: 42px;
  font-weight: 800;
}

.sl-auth-hearts {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.sl-auth-hearts svg {
  position: absolute;
  color: #fff;
}

.sl-auth-heart-1 {
  top: 38%;
  left: 7%;
  width: 22px;
  height: 22px;
  opacity: 0.16;
  transform: rotate(-14deg);
}

.sl-auth-heart-2 {
  top: 30%;
  right: 9%;
  width: 14px;
  height: 14px;
  opacity: 0.12;
  transform: rotate(12deg);
}

.sl-auth-heart-3 {
  top: 78%;
  left: 18%;
  width: 18px;
  height: 18px;
  opacity: 0.1;
  transform: rotate(-6deg);
}

.sl-auth-sheet {
  position: relative;
  z-index: 1;
  display: flex;
  flex: 0 0 auto;
  flex-direction: column;
  padding: 26px 20px calc(20px + env(safe-area-inset-bottom));
  background: transparent;
  color: #fff;
}

.sl-auth-title {
  margin: 0;
  color: #fff;
  font-size: 24px;
  font-weight: 800;
  line-height: 1.3;
  letter-spacing: -0.01em;
  text-shadow: 0 2px 12px rgba(37, 10, 28, 0.28);
}

.sl-auth-subtitle {
  margin: 4px 0 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: 13px;
  line-height: 1.5;
}

.sl-auth-form {
  margin-top: 22px;
}

.sl-field + .sl-field {
  margin-top: 16px;
}

.sl-field-label {
  display: block;
  margin-bottom: 7px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
}

.sl-field-box {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 56px;
  padding: 0 12px 0 16px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 8px 24px rgba(25, 8, 26, 0.14), inset 0 1px rgba(255, 255, 255, 0.9);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.sl-field-box:focus-within {
  border-color: #fff;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.22), 0 10px 28px rgba(25, 8, 26, 0.2);
}

.sl-field-icon {
  flex: 0 0 20px;
  width: 20px;
  height: 20px;
  color: var(--sl-brand-deep);
}

.sl-field-box:focus-within .sl-field-icon {
  color: var(--sl-brand);
}

.sl-field-control {
  flex: 1;
  min-width: 0;
  height: 24px;
  padding: 0 3px;
  border: 0;
  outline: none;
  background: transparent;
  color: var(--sl-ink);
  font-size: 16px;
  font-family: inherit;
  line-height: 1.4;
}

.sl-field-control::placeholder {
  color: #b9a9a6;
  font-size: 15px;
}

.sl-field-eye {
  display: grid;
  flex: 0 0 36px;
  place-items: center;
  width: 36px;
  height: 36px;
  margin-right: -6px;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #7e6871;
  cursor: pointer;
}

.sl-field-eye svg {
  width: 20px;
  height: 20px;
}

.sl-field-eye:active {
  background: var(--sl-brand-soft);
}

.sl-auth-submit {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  min-height: 56px;
  margin-top: 24px;
  padding: 12px 16px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(105deg, #7048e8 0%, #c832a4 100%);
  box-shadow: 0 10px 24px rgba(71, 28, 145, 0.3), inset 0 1px rgba(255, 255, 255, 0.33);
  color: #fff;
  font-family: inherit;
  font-size: 17px;
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
  transition: filter 0.18s ease, transform 0.18s ease;
}

.sl-auth-submit:not(:disabled):active {
  transform: scale(0.985);
  filter: brightness(0.96);
}

.sl-auth-submit:disabled {
  opacity: 0.72;
  box-shadow: none;
  cursor: default;
}

.sl-auth-switch {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 4px 8px;
  margin-top: 22px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 14px;
  line-height: 1.5;
  text-align: center;
}

.sl-auth-switch a,
.sl-auth-switch button {
  min-height: 32px;
  padding: 4px 2px;
  border: 0;
  background: transparent;
  color: #fff;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  text-decoration: underline;
  text-decoration-thickness: 1.5px;
  text-underline-offset: 4px;
  cursor: pointer;
}

.sl-auth-footer {
  margin-top: auto;
  padding-top: 28px;
  text-align: center;
}

.sl-lang-popup {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 4000;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(28, 28, 32, 0.45);
}

.sl-lang-popup.is-open {
  display: flex;
}

.sl-lang-dialog {
  width: min(340px, calc(100vw - 40px));
  max-height: calc(100dvh - 40px);
  overflow-y: auto;
  padding: 20px;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 24px 80px rgba(28, 28, 32, 0.15);
  color: #24252a;
}

.sl-lang-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.sl-lang-heading h2 {
  margin: 0;
  color: #17181c;
  font-size: 18px;
  font-weight: 700;
}

.sl-lang-close {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 50%;
  background: #f3f3f5;
  color: #6b6b73;
  cursor: pointer;
}

.sl-lang-options {
  display: grid;
  gap: 8px;
}

.sl-lang-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  min-height: 48px;
  padding: 10px 14px;
  border: 1px solid #e9e9ed;
  border-radius: 12px;
  background: #fff;
  color: #24252a;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}

.sl-lang-option.is-active {
  border-color: var(--sl-brand);
  background: var(--sl-brand-soft);
  color: var(--sl-brand-deep);
}

@media (prefers-reduced-motion: no-preference) {
  .sl-auth-hero-inner {
    animation: sl-auth-fade 0.48s ease both;
  }
  .sl-auth-sheet {
    animation: sl-auth-rise 0.52s cubic-bezier(0.2, 0.7, 0.2, 1) both;
  }
  .sl-auth-hearts svg {
    animation: sl-auth-float 7s ease-in-out infinite alternate;
  }
  .sl-auth-heart-2 {
    animation-duration: 9s;
    animation-delay: -3s;
  }
  .sl-auth-heart-3 {
    animation-duration: 11s;
    animation-delay: -6s;
  }
}

@keyframes sl-auth-fade {
  0% { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: none; }
}

@keyframes sl-auth-rise {
  0% { opacity: 0; transform: translateY(32px); }
  to { opacity: 1; transform: none; }
}

@keyframes sl-auth-float {
  0% { translate: 0 0; }
  to { translate: 0 -10px; }
}

@media (max-width: 359px) {
  .sl-auth-hero,
  .sl-auth-sheet {
    padding-inline: 16px;
  }
}

@media (min-width: 640px) {
  .sl-auth {
    padding-bottom: 40px;
  }
  .sl-auth-sheet {
    padding: 32px 28px 28px;
  }
  .sl-auth-hero {
    padding-bottom: 30px;
  }
}

/* layui layer 提示：避免继承 auth 页白色文字 */
.layui-layer,
.layui-layer-dialog,
.layui-layer-msg,
.layui-layer-hui,
.layui-layer-content,
.layui-layer-padding {
  color: #333 !important;
}

.layui-layer-msg .layui-layer-content {
  color: #333 !important;
}

.layui-layer-title {
  color: #333 !important;
}

.layui-layer-btn a {
  color: #333 !important;
}
