findme-miniprogram-frontend/subpackages/profile/personal-details/personal-details.wxss

283 lines
6.1 KiB
Text
Raw Normal View History

2025-12-27 17:16:03 +08:00
/* 全局背景与字体 */
page, .personal {
height: 100%;
background: #000000;
padding: 30rpx;
display: flex;
flex-direction: column;
position: relative;
}
/* 容器 */
.personal-container {
/* flex: 1; */
background: transparent;
overflow-y: auto;
-webkit-overflow-scrolling: touch;
}
/* 卡片基础 */
.card {
background: rgb(105 105 105 / 30%);
border-radius: 18rpx;
/* 减小整体内边距,给行内元素更多可用宽度 */
padding: 12rpx 14rpx;
margin-bottom: 20rpx;
box-shadow: 0 6rpx 18rpx rgba(0,0,0,0.6);
color: #e8e8e8;
}
/* 头像区域 */
.avatar-area {
display: flex;
align-items: center;
justify-content: space-between;
}
.avatar-area .left .label {
font-size: 26rpx;
color: #cfcfcf;
}
/* .avatar-right {
display: flex;
align-items: center;
} */
.avatar-img {
width: 110rpx;
height: 110rpx;
border-radius: 50%;
background: #000000;
margin-left: 18rpx;
margin-right: 18rpx;
display: block;
}
/* 头像外层容器(如有使用) */
.avatar-wrap {
width: 110rpx;
height: 110rpx;
border-radius: 50%;
overflow: hidden;
background: #000;
margin-left: 18rpx;
margin-right: 18rpx;
box-shadow: 0 6rpx 18rpx rgba(0,0,0,0.4);
}
/* 头像占位样式(无头像时) */
.avatar-placeholder {
width: 110rpx;
height: 110rpx;
border-radius: 50%;
background: linear-gradient(135deg, #151516 0%, #0F0F11 100%);
display: flex;
align-items: center;
justify-content: center;
color: #e8e8e8;
font-size: 40rpx;
margin-left: 18rpx;
margin-right: 18rpx;
box-shadow: 0 6rpx 18rpx rgba(0,0,0,0.4);
}
.chev {
color: #9b9b9b;
font-size: 30rpx;
margin-left: 8rpx;
}
/* 小按钮样式 */
.icon-btn {
/* 小按钮,移除强制宽度,允许在小屏上收缩 */
display: inline-flex;
align-items: center;
justify-content: center;
min-width: 28rpx;
width: 120rpx;
padding: 4rpx 8rpx;
font-size: 26rpx;
background-color: rgb(143 49 255 / 32%);
box-sizing: border-box;
flex: 0 0 auto;
line-height: 1;
}
/* 输入框样式 */
.input {
font-size: 24rpx;
/* 可见的文本颜色 */
color: #ffffff;
/* 右对齐输入 */
text-align: right;
flex: 1 1 auto; /* 主动占满剩余空间 */
width: auto;
min-width: 0; /* 允许在 flex 容器中收缩,避免换行 */
border: none; /* 移除默认边框 */
background: transparent;
padding: 0 0 0 8rpx;
}
/* 个人简介 */
.intro-box {
background: rgb(105 105 105 / 30%);
border-radius: 12rpx;
padding: 16rpx;
min-height: 140rpx;
}
.intro-text {
color: #bfbfbf;
line-height: 1.6;
font-size: 24rpx;
white-space: normal;
word-wrap: break-word;
word-break: break-word;
}
/* 编辑态 textarea */
.textarea {
width: 95%;
min-height: 80rpx;
max-height: 200rpx;
background: #0b0d0e;
color: #ddd;
border-radius: 12rpx;
padding: 16rpx;
font-size: 24rpx;
border: 1rpx solid rgba(255,255,255,0.02);
}
.intro-actions {
display: flex;
justify-content: flex-end;
margin-top: 12rpx;
}
.btn {
padding: 10rpx 20rpx;
margin-left: 12rpx;
border-radius: 12rpx;
font-size: 24rpx;
border: none;
}
.cancel {
background: transparent;
color: #9b9b9b;
border: 1rpx solid rgba(255,255,255,0.03);
}
.save {
background: linear-gradient(90deg,#00c2a8,#00a3ff);
color: #fff;
}
/* 卡片样式 */
.intro-card .row {
display: flex;
flex-wrap: nowrap; /* 禁止换行,保证左侧标签与右侧内容在同一行 */
justify-content: space-between;
align-items: center;
/* 减小行内上下与左右内边距,释放水平空间 */
padding: 22rpx 8rpx;
border-bottom: 1rpx solid rgba(255,255,255,0.02);
}
.intro-card .row:last-child { border-bottom: none; }
.left { color: #cfcfcf; font-size: 26rpx; /* 固定或最小宽度,避免被压缩换行 */
/* 将左侧最小宽度适度减小,给输入留出更多空间 */
min-width: 88rpx;
flex: 0 0 auto;
white-space: nowrap; /* 防止标签内换行 */
}
.right { display:flex; align-items:center; flex: 1 1 auto; justify-content: flex-end; gap: 6rpx; }
.value { color: #e3e3e3; font-size: 26rpx; margin-right: 10rpx; }
/* 底部选择面板sheet与遮罩 */
.mask {
position: fixed;
left: 0;
top: 0;
width: 100%;
height: 100%;
background: rgba(0,0,0,0.5);
z-index: 50;
}
.sheet {
position: fixed;
left: 0;
right: 0;
bottom: 0;
z-index: 60;
background: #0f1112;
border-top-left-radius: 28rpx;
border-top-right-radius: 28rpx;
padding: 18rpx;
box-shadow: 0 -8rpx 30rpx rgba(0,0,0,0.6);
}
.sheet-handle {
width: 80rpx;
height: 6rpx;
background: rgba(255,255,255,0.06);
border-radius: 6rpx;
margin: 6rpx auto 12rpx;
}
.sheet-title {
display:flex;
justify-content:space-between;
align-items:center;
padding-bottom: 12rpx;
border-bottom: 1rpx solid rgba(255,255,255,0.03);
}
.sheet-title text { color: white; font-size: 28rpx; }
.sheet-done {
background: transparent;
color: #9aa0a6;
border: none;
font-size: 24rpx;
}
.sheet-list {
max-height: 420rpx;
margin-top: 12rpx;
padding-bottom: 12rpx;
}
.sheet-item {
padding: 16rpx 12rpx;
display:flex;
justify-content:space-between;
align-items:center;
border-bottom: 1rpx solid rgba(255,255,255,0.02);
font-size: 26rpx;
color: #d7d7d7;
}
.sheet-item.active {
background: rgba(0,160,255,0.06);
color: #00a3ff;
}
.sheet-check { color: #00a3ff; font-size: 28rpx; }
/* 保存按钮容器 - 参考 phone-next 样式 */
.save-button-container {
display: flex;
justify-content: center;
align-items: center;
margin-top: 40rpx;
box-sizing: border-box;
padding: 0 30rpx;
}
.save-button {
height: 100rpx;
width: 240rpx;
background: linear-gradient(135deg, #000000, #232323);
color: white;
text-align: center;
line-height: 100rpx;
border: 1rpx solid #4e4e4e;
border-radius: 60rpx;
font-size: 40rpx;
font-weight: 500;
box-shadow:
4rpx 4rpx 30rpx rgba(91, 196, 245, 0.1),
0 4rpx 8rpx rgba(255, 255, 255, 0.2) inset;
transition: all 0.2s ease;
}
.save-button:active {
box-shadow:
0 -16rpx 32rpx rgba(18, 158, 240, 0.1) inset, /* 内层上阴影(凹陷) */
0 4rpx 8rpx rgba(0, 0, 0, 0.1) inset; /* 内层下阴影 */
transform: translateY(4rpx); /* 向下偏移,强化"按下"感 */
}