Files
wordpress-theme-aksrt/assets/css/routes/profile/modals.css
T

605 lines
14 KiB
CSS

/* ==================== Modal 弹窗 ==================== */
.aksrt-modal {
display: none;
position: fixed;
inset: 0;
z-index: 99998;
align-items: center;
justify-content: center;
}
.aksrt-modal.is-open {
display: flex;
}
.aksrt-modal__overlay {
position: absolute;
inset: 0;
background: rgba(0, 0, 0, 0.45);
backdrop-filter: blur(4px);
-webkit-backdrop-filter: blur(4px);
animation: modalFadeIn 0.2s ease forwards;
}
.aksrt-modal__box {
position: relative;
width: 92%;
max-width: 440px;
max-height: 90vh;
overflow-y: auto;
background: var(--surface-1);
border-radius: var(--radius);
box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2), 0 4px 16px rgba(0, 0, 0, 0.08);
animation: modalSlideUp 0.28s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}
@keyframes modalFadeIn { from { opacity: 0 } to { opacity: 1 } }
@keyframes modalSlideUp {
from { opacity: 0; transform: translateY(24px) scale(0.96); }
to { opacity: 1; transform: translateY(0) scale(1); }
}
/* Modal 头部 */
.aksrt-modal__header {
display: flex;
align-items: center;
justify-content: space-between;
padding: 18px 20px;
border-bottom: 1px solid var(--color-line);
}
.aksrt-modal__title-wrap {
display: flex;
align-items: center;
gap: 8px;
}
.aksrt-modal__icon {
display: flex;
align-items: center;
width: 30px;
height: 30px;
border-radius: 8px;
background: var(--color-primary-soft);
color: var(--color-primary);
font-size: 16px;
}
.aksrt-modal__title-wrap h4 {
margin: 0;
font-size: 16px;
font-weight: 700;
color: var(--color-ink);
}
.aksrt-modal__close {
display: flex;
align-items: center;
justify-content: center;
width: 32px;
height: 32px;
border: none;
border-radius: 8px;
background: transparent;
color: var(--color-ink-4);
cursor: pointer;
font-size: 18px;
transition: background 0.15s, color 0.15s;
}
.aksrt-modal__close:hover {
background: var(--surface-2);
color: var(--color-ink);
}
/* Modal 表单字段 */
.aksrt-modal__box form {
padding: 20px;
}
.modal-field {
position: relative;
margin-bottom: 16px;
}
.modal-field label {
display: block;
margin-bottom: 6px;
font-size: 13px;
font-weight: 600;
color: var(--color-ink-2);
}
.modal-field input[type="password"],
.modal-field input[type="email"],
.modal-field input[type="text"] {
display: block;
width: 100%;
padding: 10px 40px 10px 14px;
font-size: 14px;
line-height: 1.5;
color: var(--color-ink);
background: var(--surface-2);
border: 1.5px solid var(--color-line);
border-radius: 8px;
outline: none;
transition: border-color 0.2s, box-shadow 0.2s;
box-sizing: border-box;
}
.modal-field input:focus {
border-color: var(--color-primary);
box-shadow: 0 0 0 3px var(--color-primary-soft);
background: var(--surface-1);
}
.toggle-pwd {
position: absolute;
right: 10px;
top: 31px;
width: 34px;
height: 34px;
border: none;
border-radius: 6px;
background: transparent;
cursor: pointer;
display: flex;
align-items: center;
justify-content: center;
color: var(--color-ink-4);
font-size: 16px;
}
.toggle-pwd:hover {
color: var(--color-ink);
}
/* 只读显示(当前邮箱) */
.readonly-display {
display: block;
padding: 10px 14px;
font-size: 14px;
color: var(--color-ink-4);
background: var(--surface-2);
border: 1.5px solid var(--color-line);
border-radius: 8px;
word-break: break-all;
}
/* 验证码输入组 */
.code-input-group {
display: flex;
gap: 8px;
align-items: stretch;
}
.code-input-group input {
flex: 1;
min-width: 0;
padding: 10px 14px !important;
font-family: inherit !important;
letter-spacing: 2px;
font-weight: 600;
}
.code-send-btn {
flex-shrink: 0;
white-space: nowrap;
min-width: 110px;
}
.code-send-btn.is-counting {
pointer-events: none;
opacity: 0.65;
}
/* 密码强度条 */
.pwd-strength {
display: flex;
gap: 4px;
margin-top: 7px;
height: 4px;
border-radius: 2px;
overflow: hidden;
background: var(--surface-3);
}
.pwd-strength__fill {
width: 0%;
height: 100%;
border-radius: 2px;
transition: width 0.3s ease, background-color 0.3s ease;
background-color: var(--color-error);
}
.pwd-strength__fill.level-weak { width: 33%; background-color: var(--color-error); }
.pwd-strength__fill.level-medium { width: 66%; background-color: var(--color-warning); }
.pwd-strength__fill.level-strong { width: 100%; background-color: var(--color-success); }
.pwd-strength__text {
font-size: 11px;
margin-top: 4px;
font-weight: 500;
transition: color 0.2s;
}
.pwd-strength__text.level-weak { color: var(--color-error); }
.pwd-strength__text.level-medium { color: var(--color-warning); }
.pwd-strength__text.level-strong { color: var(--color-success); }
/* 人机验证容器在弹窗中的适配 */
.aksrt-modal .aksrt-captcha-wrap {
margin: 14px 0 8px;
}
.aksrt-modal .aksrt-captcha-box {
display: block !important;
}
/* Modal 底部按钮栏 */
.aksrt-modal__footer {
display: flex;
justify-content: flex-end;
gap: 10px;
margin-top: 20px;
padding-top: 16px;
border-top: 1px solid var(--color-line);
}
/* ==================== 响应式 ==================== */
@media (max-width: 720px) {
.profile-public-left {
flex: 0 0 180px;
}
.profile-list-item {
padding: 14px;
}
.profile-comment-item {
padding: 14px;
}
}
@media (max-width: 640px) {
.profile-public-header {
flex-direction: column;
align-items: center;
gap: 24px;
}
.profile-public-left {
flex: none;
width: 100%;
}
.profile-public-right {
width: 100%;
text-align: center;
}
.profile-list-header {
flex-direction: column;
align-items: flex-start;
gap: 8px;
}
.profile-status-filter {
width: 100%;
overflow-x: auto;
flex-wrap: nowrap;
scrollbar-width: none;
padding-bottom: 4px;
}
.profile-status-filter::-webkit-scrollbar {
display: none;
}
.profile-status-chip {
flex-shrink: 0;
}
.profile-list-item__head {
flex-direction: column;
gap: 4px;
}
.profile-list-item__date {
font-size: 11px;
}
.profile-list-item__title {
font-size: var(--text-base, 1rem);
}
.profile-list-item__meta {
gap: 6px;
}
.profile-list-item__action {
margin-left: 0;
width: 100%;
justify-content: center;
}
.profile-list-item__meta-spacer {
display: none;
}
.profile-comment-item__meta {
margin-left: 0;
}
}
@media (max-width: 480px) {
.contact-row { flex-wrap: wrap; }
.contact-row .contact-name { flex: 1 1 100%; }
.contact-icon { flex: 0 0 100%; }
.aksrt-modal__box {
max-width: 96%;
border-radius: 12px;
}
.aksrt-modal__header { padding: 14px 16px; }
.aksrt-modal__box form { padding: 16px; }
.security-action-item {
flex-direction: column;
align-items: flex-start;
gap: 12px;
}
.security-action-item > button {
align-self: flex-end;
}
.code-send-btn {
min-width: 94px;
font-size: 12px;
}
.profile-pagination .page-numbers {
min-width: 30px;
height: 30px;
font-size: 12px;
padding: 0 8px;
}
}
/* ============================================================
* v4.0 Zibll-Inspired 用户中心增强
* ============================================================ */
/* 用户统计卡片 */
.user-stats-grid {
display: grid;
grid-template-columns: repeat(4, 1fr);
gap: 12px;
margin-bottom: 20px;
}
.user-stat-card {
text-align: center;
padding: 16px 8px;
border-radius: 8px;
background: var(--surface-3);
transition: transform 0.2s ease;
}
.user-stat-card:hover {
transform: translateY(-2px);
}
.user-stat-card__value {
font-size: 1.25rem;
font-weight: 700;
color: var(--color-primary);
line-height: 1;
margin-bottom: 4px;
}
.user-stat-card__label {
font-size: 11px;
color: var(--color-ink-4);
}
/* 签到面板 */
.signin-panel {
background: var(--surface-page);
border: 1px solid var(--color-line);
border-radius: 8px;
padding: 20px;
margin-bottom: 20px;
}
.signin-panel__header {
display: flex;
align-items: center;
justify-content: space-between;
margin-bottom: 12px;
}
.signin-panel__title {
font-size: 0.9375rem;
font-weight: 700;
display: flex;
align-items: center;
gap: 6px;
}
.signin-panel__title i {
color: var(--color-primary);
}
.signin-panel__streak {
font-size: 12px;
color: var(--color-ink-4);
}
.signin-panel__streak strong {
color: var(--color-primary);
}
.signin-panel__btn {
display: inline-flex;
align-items: center;
gap: 6px;
padding: 8px 20px;
border-radius: 50px;
border: none;
background: var(--color-primary);
color: #fff;
font-size: 14px;
font-weight: 600;
cursor: pointer;
transition: opacity 0.2s ease, transform 0.2s ease;
width: 100%;
justify-content: center;
}
.signin-panel__btn:hover {
opacity: 0.9;
transform: translateY(-1px);
}
.signin-panel__btn:disabled,
.signin-panel__btn.is-signed {
background: var(--surface-3);
color: var(--color-ink-4);
cursor: not-allowed;
transform: none;
}
.signin-panel__btn.is-signed i {
color: var(--color-success, #34a853);
}
.signin-panel__reward {
text-align: center;
font-size: 12px;
color: var(--color-ink-4);
margin-top: 8px;
}
/* 签到日历(简化版) */
.signin-calendar {
display: grid;
grid-template-columns: repeat(7, 1fr);
gap: 4px;
margin-top: 12px;
}
.signin-calendar__day {
width: 100%;
aspect-ratio: 1;
border-radius: 4px;
display: flex;
align-items: center;
justify-content: center;
font-size: 11px;
color: var(--color-ink-4);
background: var(--surface-3);
}
.signin-calendar__day.is-signed {
background: var(--color-primary-soft, rgba(240, 68, 148, 0.15));
color: var(--color-primary);
font-weight: 600;
}
.signin-calendar__day.is-today {
border: 2px solid var(--color-primary);
}
/* 用户等级进度条 */
.user-level-bar {
margin-bottom: 16px;
}
.user-level-bar__header {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 6px;
font-size: 12px;
}
.user-level-bar__label {
font-weight: 600;
color: var(--color-ink);
}
.user-level-bar__exp {
color: var(--color-ink-4);
}
.user-level-bar__track {
height: 6px;
border-radius: 3px;
background: var(--surface-3);
overflow: hidden;
}
.user-level-bar__fill {
height: 100%;
border-radius: 3px;
background: linear-gradient(90deg, var(--color-primary), #667eea);
transition: width 0.5s ease;
}
/* 移动端适配 */
@media (max-width: 640px) {
.user-stats-grid {
grid-template-columns: repeat(2, 1fr);
gap: 8px;
}
.user-stat-card {
padding: 12px 6px;
}
.user-stat-card__value {
font-size: 1rem;
}
}
/* Zibll-style user tabs: one panel outside, flat rows inside. */
.dashboard--public .profile-list,
.dashboard--public .profile-comment-list,
.uc-content #panel-posts .profile-list,
.uc-content #panel-favorites .profile-list,
.uc-content #panel-comments .profile-comment-list {
gap: 0;
}
.dashboard--public .profile-list-item,
.dashboard--public .profile-comment-item,
.uc-content #panel-posts .profile-list-item,
.uc-content #panel-favorites .profile-list-item,
.uc-content #panel-favorites .profile-list[data-list="favorites"] .profile-list-item,
.uc-content #panel-comments .profile-comment-item {
padding: 16px 0;
background: transparent;
border: 0;
border-bottom: 1px solid var(--color-line-soft, rgba(0,0,0,0.06));
border-radius: 0;
box-shadow: none;
}
.dashboard--public .profile-list-item:hover,
.dashboard--public .profile-comment-item:hover,
.uc-content #panel-posts .profile-list-item:hover,
.uc-content #panel-favorites .profile-list-item:hover,
.uc-content #panel-favorites .profile-list[data-list="favorites"] .profile-list-item:hover,
.uc-content #panel-comments .profile-comment-item:hover {
background: transparent;
border-color: var(--color-line-soft, rgba(0,0,0,0.06));
box-shadow: none;
}
.dashboard--public .profile-list-item:first-child,
.dashboard--public .profile-comment-item:first-child,
.uc-content #panel-posts .profile-list-item:first-child,
.uc-content #panel-favorites .profile-list-item:first-child,
.uc-content #panel-comments .profile-comment-item:first-child {
padding-top: 0;
}
.dashboard--public .profile-list-item:last-child,
.dashboard--public .profile-comment-item:last-child,
.uc-content #panel-posts .profile-list-item:last-child,
.uc-content #panel-favorites .profile-list-item:last-child,
.uc-content #panel-comments .profile-comment-item:last-child {
padding-bottom: 0;
border-bottom: 0;
}
.dashboard--public .profile-list[data-list="favorites"] .profile-list-item,
.dashboard--public .profile-list[data-list="favorites"] .profile-list-item:hover {
background: transparent;
border-color: var(--color-line-soft, rgba(0,0,0,0.06));
box-shadow: none;
}
@media (max-width: 640px) {
.dashboard--public .profile-list-item,
.dashboard--public .profile-comment-item,
.uc-content #panel-posts .profile-list-item,
.uc-content #panel-favorites .profile-list-item,
.uc-content #panel-comments .profile-comment-item {
padding: 14px 0;
}
.dashboard--public .profile-list-item:first-child,
.dashboard--public .profile-comment-item:first-child,
.uc-content #panel-posts .profile-list-item:first-child,
.uc-content #panel-favorites .profile-list-item:first-child,
.uc-content #panel-comments .profile-comment-item:first-child {
padding-top: 0;
}
.dashboard--public .profile-list-item:last-child,
.dashboard--public .profile-comment-item:last-child,
.uc-content #panel-posts .profile-list-item:last-child,
.uc-content #panel-favorites .profile-list-item:last-child,
.uc-content #panel-comments .profile-comment-item:last-child {
padding-bottom: 0;
}
}