index.less 4.85 KB
/* 注册页面样式 */
.register-page {
  min-height: 100vh;
  background-color: #f5f5f5;
  padding-bottom: 200rpx;
}

/* 头像区域 */
.avatar-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 60rpx 0;
  background-color: #fff;
  margin-bottom: 20rpx;
}

.avatar-container {
  position: relative;
  margin-bottom: 20rpx;
}

.avatar-image {
  width: 160rpx;
  height: 160rpx;
  border-radius: 80rpx;
  border: 4rpx solid #f0f0f0;
}

.camera-btn {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 48rpx;
  height: 48rpx;
  background-color: #f97316;
  border-radius: 24rpx;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 4rpx solid #fff;
}

.camera-icon {
  width: 24rpx;
  height: 24rpx;
  color: #fff;
}

.change-avatar-btn {
  padding: 16rpx 32rpx;
  background-color: #f97316;
  border-radius: 40rpx;
}

.change-avatar-text {
  color: #fff;
  font-size: 28rpx;
}

/* 表单容器 */
.form-container {
  background-color: #fff;
  margin: 0 24rpx 40rpx;
  border-radius: 16rpx;
  overflow: hidden;
}

/* 手机号输入容器 */
.phone-input-container {
  display: flex;
  align-items: center;
  width: 100%;
}

.phone-input {
  flex: 1;
  margin-right: 20rpx;
}

.code-btn {
  flex-shrink: 0;
  min-width: 160rpx;
  height: 64rpx;
  background-color: #f97316;
  color: #fff;
  border-radius: 8rpx;
  font-size: 24rpx;
}

.code-btn:disabled {
  background-color: #ccc;
  color: #999;
}

/* 生日选择项 */
.birthday-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 20rpx 0;
}

.birthday-value {
  color: #333;
  font-size: 28rpx;
}

.arrow-icon {
  width: 24rpx;
  height: 24rpx;
  color: #999;
}

/* 学校选择项 */
.school-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 20rpx 0;
}

.school-value {
  color: #333;
  font-size: 28rpx;
}

/* 性别单选组件右对齐 */
// .form-container :deep(.nut-form-item:nth-child(4) .nut-form-item__body) {
//   justify-content: flex-end;
// }

/* 注册按钮区域 */
.register-section {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 40rpx 24rpx;
  background-color: #fff;
  border-top: 1rpx solid #eee;
  z-index: 100;
}

/* 表单项样式调整 */
.form-container :deep(.nut-form-item) {
  padding: 24rpx 32rpx;
  border-bottom: 1rpx solid #f0f0f0;
}

// .form-container :deep(.nut-form-item:last-child) {
//   border-bottom: none;
// }

.form-container .nut-form-item__label {
  font-size: 28rpx;
  color: #333;
  font-weight: 500;
  min-width: 140rpx;
}

.form-container :deep(.nut-input__inner) {
  font-size: 28rpx;
  color: #333;
}

// .form-container :deep(.nut-input__inner::placeholder) {
//   color: #999;
//   font-size: 28rpx;
// }

/* 单选按钮样式 */
.form-container :deep(.nut-radio-group) {
  gap: 40rpx;
}

.form-container :deep(.nut-radio__label) {
  font-size: 28rpx;
  color: #333;
}

.form-container :deep(.nut-radio__icon) {
  width: 32rpx;
  height: 32rpx;
}

/* 弹窗样式调整 */
:deep(.nut-popup) {
  border-radius: 24rpx 24rpx 0 0;
}

:deep(.nut-picker__title) {
  font-size: 32rpx;
  font-weight: 600;
  color: #333;
}

:deep(.nut-date-picker__title) {
  font-size: 32rpx;
  font-weight: 600;
  color: #333;
}

/* 按钮样式 */
:deep(.nut-button--large) {
  height: 88rpx;
  border-radius: 44rpx;
  font-size: 32rpx;
  font-weight: 600;
}

/* Toast 样式 */
:deep(.nut-toast) {
  z-index: 9999;
}

/* 导航栏样式 */
:deep(.nut-navbar) {
  background-color: #f97316;
  color: #fff;
}

:deep(.nut-navbar__title) {
  color: #fff;
  font-size: 36rpx;
  font-weight: 600;
}

:deep(.nut-navbar__left) {
  color: #fff;
}

/* 响应式适配 */
@media screen and (max-width: 375px) {
  .avatar-image {
    width: 140rpx;
    height: 140rpx;
    border-radius: 70rpx;
  }

  .camera-btn {
    width: 40rpx;
    height: 40rpx;
    border-radius: 20rpx;
  }

  .camera-icon {
    width: 20rpx;
    height: 20rpx;
  }

  .form-container :deep(.nut-form-item) {
    padding: 20rpx 24rpx;
  }

  .form-container :deep.nut-form-item__label {
    font-size: 26rpx;
    min-width: 120rpx;
  }

  .form-container :deep(.nut-input__inner) {
    font-size: 26rpx;
  }
}

/* 加载状态 */
.register-section :deep(.nut-button--loading) {
  opacity: 0.7;
}

/* 禁用状态 */
.register-section :deep(.nut-button--disabled) {
  background-color: #ccc !important;
  color: #999 !important;
}

/* 表单验证错误样式 */
// .form-container :deep(.nut-form-item--error .nut-form-item__label) {
//   color: #ff4757;
// }

// .form-container :deep(.nut-form-item--error .nut-input__inner) {
//   border-color: #ff4757;
// }

/* 占位符颜色调整 */
.birthday-value,
.school-value {
  color: #999;
}

// .birthday-item:has(.birthday-value:not(:empty)),
// .school-item:has(.school-value:not(:empty)) {
//   .birthday-value,
//   .school-value {
//     color: #333;
//   }
// }