* {
  margin: 0;
  padding: 0;
}

/* ============ 页面骨架：左右分栏 ============ */
#regist {
  width: 100%;
  min-height: 100vh;
  display: flex;
  font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  color: #1f2937;
  background: #f5f7fa;
}

.login-container {
  position: relative;
  display: flex;
  width: 100%;
  min-height: 100vh;
}

/* 右上角：跳转按钮 */
.login-jump-btn {
  top: 0.24rem;
  right: 0.4rem;
  left: auto;
  width: auto;
  z-index: 40;
}

.login-jump-btn .btn {
  margin-left: 0.2rem;
}

/* ============ 左侧品牌区 ============ */
.container-back {
  position: relative;
  width: 50%;
  min-height: 100vh;
  padding: 0.5rem 0.72rem 0.42rem;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--color-primary);
  color: #ffffff;
}

.container-back::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(80% 60% at 100% 0%, rgba(255, 255, 255, 0.18) 0%, rgba(255, 255, 255, 0) 62%),
    linear-gradient(155deg, rgba(3, 14, 12, 0.94) 0%, rgba(3, 14, 12, 0.72) 46%, rgba(3, 14, 12, 0.42) 100%);
}

.container-back::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.055) 1px, transparent 1px);
  background-size: 0.56rem 0.56rem;
  -webkit-mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.9), transparent 78%);
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.9), transparent 78%);
}

.back-line1,
.back-line2,
.back-line3 {
  position: absolute;
  z-index: 1;
  width: 1.4rem;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.22) 0%, rgba(255, 255, 255, 0) 100%);
  transform: rotate(26deg);
  filter: blur(0.18rem);
  opacity: 0.55;
  pointer-events: none;
}

.back-line1 {
  height: 10rem;
  top: -4.6rem;
  left: 51%;
}

.back-line2 {
  width: 0.9rem;
  height: 12rem;
  top: -5rem;
  left: 68%;
  opacity: 0.35;
}

.back-line3 {
  width: 0.6rem;
  height: 9rem;
  top: 1.6rem;
  left: 84%;
  opacity: 0.22;
}

.back-top {
  position: relative;
  z-index: 3;
}

.brand-logo {
  display: block;
  height: 0.4rem;
  width: auto;
}

.back-text {
  position: relative;
  z-index: 3;
  margin: auto 0;
  max-width: 7.4rem;
  padding: 0.4rem 0;
}

.container-back .text-welcome {
  font-family: Bahnschrift, "PingFang SC", sans-serif;
  font-size: 0.62rem;
  line-height: 1;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #ffffff;
}

.container-back .text-title {
  margin-top: 0.2rem;
  font-size: 0.3rem;
  line-height: 1.35;
  font-weight: 600;
  color: #ffffff;
}

.container-back .text-level {
  margin-top: 0.16rem;
  max-width: 5.8rem;
  font-size: 0.15rem;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.68);
}

.back-tags {
  margin-top: 0.36rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.1rem;
}

.back-tag {
  padding: 0.09rem 0.18rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.06);
  font-size: 0.12rem;
  line-height: 1;
  color: rgba(255, 255, 255, 0.82);
  white-space: nowrap;
}

.back-metrics {
  margin-top: 0.3rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.12rem;
}

.back-metric {
  min-width: 1.3rem;
  padding: 0.14rem 0.16rem;
  box-sizing: border-box;
  border-radius: 0.12rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.07);
}

.metric-num {
  font-size: 0.2rem;
  line-height: 1.1;
  font-weight: 700;
  color: #ffffff;
}

.metric-text {
  margin-top: 0.07rem;
  font-size: 0.11rem;
  line-height: 1.2;
  color: rgba(255, 255, 255, 0.6);
}

.back-footer {
  position: relative;
  z-index: 3;
  font-size: 0.1rem;
  line-height: 1;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.34);
}

/* ============ 右侧注册卡片区 ============ */
.container-before {
  position: relative;
  flex: 1;
  min-width: 0;
  min-height: 100vh;
  display: flex;
  overflow-y: auto;
  box-sizing: border-box;
  padding: 0.8rem 0.5rem 0.5rem;
  background: #f5f7fa;
}

.login {
  position: relative;
  margin: auto;
  box-sizing: border-box;
  width: 4.5rem;
  min-width: 340px;
  max-width: 460px;
  padding: 0.44rem 0.4rem 0.38rem;
  border-radius: 14px;
  background: #ffffff;
  box-shadow: 0 0.24rem 0.6rem rgba(16, 24, 40, 0.08), 0 0.04rem 0.12rem rgba(16, 24, 40, 0.04);
  font-family: inherit;
  font-size: 14px;
  line-height: 1.5;
  color: #1f2937;
}

.login-text {
  display: flex;
  flex-direction: column;
}

.login-text-title {
  font-size: 26px;
  line-height: 1.25;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: #101828;
}

.login-text-regist {
  margin-top: 8px;
  font-size: 13px;
  line-height: 1.5;
  color: #98a2b3;
}

.login-text-regist a {
  color: var(--color-primary);
  font-weight: 500;
  cursor: pointer;
}

.login-text-regist a:hover {
  text-decoration: underline;
}

.login-form {
  margin-top: 26px;
}

.login-top {
  display: flex;
  gap: 26px;
  border-bottom: 1px solid #eef1f5;
}

.login-email,
.login-phone {
  position: relative;
  height: auto;
  padding: 0 0 11px;
  font-size: 14px;
  line-height: 1.2;
  color: #98a2b3;
  cursor: pointer;
  white-space: nowrap;
  transition: color 0.2s;
}

.login-email {
  margin-right: 0;
}

.login-email:hover,
.login-phone:hover {
  color: #101828;
}

.login-top .active {
  color: #101828;
  font-weight: 600;
  border-bottom: none;
}

.login-top .active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 2px;
  border-radius: 2px;
  background: var(--color-primary);
}

.form-main {
  margin-top: 22px;
}

.form-item {
  margin-top: 16px;
}

.login .el-input__inner {
  height: 44px;
  line-height: 44px;
  padding: 0 14px;
  font-size: 14px;
  color: #101828;
  border-radius: 8px;
  border-color: #e3e8ef;
  background: #ffffff;
}

.login .el-input__inner::placeholder {
  color: #b4bdc9;
}

.login .el-input__inner:focus {
  border-color: var(--color-primary);
}

.code-item {
  display: flex;
  align-items: center;
  gap: 10px;
}

.code-item .el-input {
  flex: 1;
  min-width: 0;
}

html[theme='emerald'] .login .code-btn.el-button {
  flex: 0 0 auto;
  height: 44px;
  padding: 0 16px;
  font-size: 13px;
  border-radius: 8px;
}

/* 注册表单附加项 */
.custom-form {
  margin-top: 4px;
}

.custom-form .el-form-item {
  margin-bottom: 14px;
}

.custom-form .el-form-item__label {
  padding-bottom: 6px;
  line-height: 1.4;
  font-size: 13px;
  color: #475467;
}

.custom-form .el-select {
  width: 100%;
}

.password-form-item {
  position: relative;
}

.password-rule-popover {
  position: absolute;
  left: 0;
  top: calc(100% + 0.08rem);
  z-index: 20;
  width: 100%;
  box-sizing: border-box;
  padding: 0.16rem 0.2rem;
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.16);
  line-height: 1.4;
}

.password-rule-title {
  margin-bottom: 0.1rem;
  color: #101828;
  font-size: 14px;
  font-weight: 600;
}

.password-rule-item {
  display: flex;
  align-items: flex-start;
  gap: 0.08rem;
  color: #909399;
  font-size: 13px;
  line-height: 20px;
}

.password-rule-item + .password-rule-item {
  margin-top: 0.05rem;
}

.password-rule-item i {
  margin-top: 3px;
  flex: 0 0 auto;
}

.password-rule-item.is-pass {
  color: #21ba45;
}

.rember-item {
  margin-top: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  line-height: 1.5;
}

.read-text {
  flex: 1;
  padding: 0;
  font-size: 12px;
  line-height: 1.6;
  font-weight: 400;
  color: #98a2b3;
}

.read-item {
  margin-top: 14px;
}

.read-item a {
  color: var(--color-primary);
  cursor: pointer;
}

.login .read-item .el-checkbox__label {
  font-size: 13px;
  line-height: 1.6;
  color: #667085;
  white-space: normal;
}

html[theme='emerald'] .login .login-btn.el-button {
  width: 100%;
  height: 46px;
  padding: 0;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: #ffffff;
  border-radius: 8px;
  border-color: var(--color-primary);
  background-color: var(--color-primary);
}

html[theme='emerald'] .login .login-btn.el-button:hover,
html[theme='emerald'] .login .login-btn.el-button:focus {
  border-color: var(--color-primary);
  background-color: var(--color-primary);
  filter: brightness(0.92);
}

.line-item {
  margin-top: 22px;
}

.line-item .el-divider--horizontal {
  margin: 0;
}

.line-item .el-divider__text {
  background: #ffffff;
  padding: 0 12px;
}

.line-item .text {
  font-size: 12px;
  color: #98a2b3;
}

/* ============ 移动端：上下堆叠 ============ */
@media screen and (max-width: 750px) {
  #regist {
    display: block;
    min-height: 100vh;
    background: #f2f4f7;
  }

  .login-container {
    display: block;
    min-height: 100vh;
    padding-bottom: 0.3rem;
  }

  .login-jump-btn {
    top: 0.26rem;
    right: 0.26rem;
  }

  .container-back {
    width: 100%;
    min-height: 4.2rem;
    padding: 0.46rem 0.36rem 0.4rem;
    border-radius: 0 0 0.4rem 0.4rem;
  }

  .brand-logo {
    height: 0.52rem;
  }

  .back-text {
    margin: 0.36rem 0 0;
    max-width: 100%;
    padding: 0;
  }

  .container-back .text-welcome {
    font-size: 0.5rem;
  }

  .container-back .text-title {
    margin-top: 0.12rem;
    font-size: 0.32rem;
  }

  .container-back .text-level {
    margin-top: 0.1rem;
    max-width: 100%;
    font-size: 0.2rem;
  }

  .back-tags,
  .back-metrics,
  .back-footer {
    display: none;
  }

  .container-before {
    display: block;
    min-height: 0;
    padding: 0.3rem 0.24rem 0.1rem;
    overflow: visible;
    background: transparent;
  }

  .login {
    width: 100%;
    min-width: 0;
    max-width: none;
    margin: 0;
    padding: 0.5rem 0.34rem 0.4rem;
    border-radius: 0.28rem;
  }

  .login-text-title {
    font-size: 0.42rem;
  }

  .login-text-regist {
    margin-top: 0.1rem;
    font-size: 0.24rem;
  }

  .login-form {
    margin-top: 0.4rem;
  }

  .login-top {
    gap: 0.5rem;
  }

  .login-email,
  .login-phone {
    font-size: 0.26rem;
    padding-bottom: 0.14rem;
  }

  .form-main {
    margin-top: 0.32rem;
  }

  .form-item {
    margin-top: 0.26rem;
  }

  .login .el-input__inner {
    height: 0.86rem;
    line-height: 0.86rem;
    padding: 0 0.22rem;
    font-size: 0.25rem;
  }

  .code-item {
    gap: 0.12rem;
  }

  html[theme='emerald'] .login .code-btn.el-button {
    height: 0.86rem;
    padding: 0 0.2rem;
    font-size: 0.23rem;
  }

  html[theme='emerald'] .login .login-btn.el-button {
    height: 0.9rem;
    font-size: 0.28rem;
  }

  .read-text {
    font-size: 0.21rem;
  }

  #regist .el-checkbox__label {
    font-size: 0.24rem;
  }

  .login .read-item .el-checkbox__label {
    font-size: 0.22rem;
  }

  .read-item .check-div {
    display: flex;
    white-space: inherit;
  }

  .custom-form .el-form-item__label {
    font-size: 0.24rem;
  }
}
