* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}
    
body {
    user-select: none;
    min-height: 100vh;
    background: #F5F7FA;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    line-height: 1.5;
    background-image: radial-gradient(#E5E7EB 0.5px, transparent 0.5px);
    background-size: 10px 10px;
}
    
.password-container {
    background: white;
    width: 100%;
    max-width: 480px;
    padding: 2.2rem 1.8rem;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    min-height: 580px;
    display: flex;
    flex-direction: column;
}
    
.password-container:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.05);
}

.logo-container {
    text-align: center;
    margin-bottom: 1.6rem;
}

.logo {
    height: 52px;
    width: auto;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.logo:hover {
    transform: scale(1.05);
}
    
.title {
    text-align: center;
    margin-bottom: 1.8rem;
    color: #1D2129;
}
    
.title h1 {
    font-size: 1.5rem;
    margin-bottom: 0.4rem;
    font-weight: 600;
}
    
.title p {
    color: #6E7681;
    font-size: 0.85rem;
    line-height: 1.4;
}
    
.form-wrapper {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
    
.form-group {
    margin-bottom: 1.4rem;
    position: relative;
}

.label-action-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
    gap: 8px;
}

/* 新密码标签与提示按钮组合容器 */
.new-pwd-label-group {
    display: flex;
    align-items: center;
    gap: 6px; /* 控制标签与按钮的间距 */
}
    
.form-group label {
    color: #1D2129;
    font-weight: 500;
    font-size: 0.85rem;
}
    
.password-input {
    position: relative;
}
    
.password-input input {
    width: 100%;
    padding: 13px 15px;
    padding-right: 40px;
    border: 1px solid #D1D5DB;
    border-radius: 9px;
    font-size: 0.95rem;
    transition: all 0.2s ease;
    background-color: #FFFFFF;
}
    
.password-input input:focus {
    outline: none;
    border-color: #165DFF;
    box-shadow: 0 0 0 3px rgba(22, 93, 255, 0.1);
    transform: scale(1.01);
}

.password-input input.error {
    border-color: #FF4D4F;
    background-color: rgba(255, 77, 79, 0.02);
}
    
.toggle-btn {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #6E7681;
    cursor: pointer;
    font-size: 1rem;
    transition: color 0.2s ease;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}
    
.toggle-btn:hover {
    color: #165DFF;
    background-color: rgba(22, 93, 255, 0.05);
}

/* 密码强度相关样式 */
.password-strength {
    margin-top: 0.5rem;
    height: 5px;
    border-radius: 3px;
    background-color: #F3F4F6;
    overflow: hidden;
    display: none;
}

.password-strength.active {
    display: block;
}

.strength-bar {
    height: 100%;
    width: 0%;
    transition: width 0.3s ease, background-color 0.3s ease;
}

.strength-bar.weak {
    width: 33%;
    background-color: #FF4D4F;
}

.strength-bar.medium {
    width: 66%;
    background-color: #FFAA33;
}

.strength-bar.strong {
    width: 100%;
    background-color: #00B42A;
}

.strength-text {
    font-size: 0.78rem;
    color: #6E7681;
    display: none;
    white-space: nowrap;
    margin-top: 0.2rem;
    min-width: 120px;
    text-align: right;
}

.strength-text.active {
    display: block;
}

/* 密码要求提示框样式（无文字按钮） */
.pwd-hint-container {
    position: relative;
}

.pwd-req-btn {
    background: none;
    border: none;
    color: #6E7681;
    cursor: pointer;
    width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
    padding: 0;
    margin: 0;
    /* 悬停效果强化 */
}

.pwd-req-btn:hover {
    color: #165DFF;
    background-color: rgba(22, 93, 255, 0.08);
    transform: scale(1.1);
}

.pwd-req-btn i {
    font-size: 0.9rem;
}

.pwd-req-list {
    position: absolute;
    top: calc(100% + 5px); /* 贴近按钮下方 */
    left: 0; /* 左对齐按钮，更贴近标签 */
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    padding: 12px 16px;
    width: 230px;
    list-style: none;
    display: none;
    z-index: 10;
}

.pwd-req-list.show {
    display: block;
    animation: fadeIn 0.2s ease forwards;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-5px); }
    to { opacity: 1; transform: translateY(0); }
}

.pwd-req-list li {
    font-size: 0.8rem;
    color: #6E7681;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 6px;
}

.pwd-req-list li:last-child {
    margin-bottom: 0;
}

.pwd-req-list li.valid {
    color: #00B42A;
}

.pwd-req-list li i {
    font-size: 0.85rem;
}
    
/* 按钮样式 */
.btn {
    width: 100%;
    padding: 13px;
    background: #165DFF;
    color: white;
    border: none;
    border-radius: 9px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-top: 0.6rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
}
    
.btn:hover:not(:disabled) {
    background: #0E42D2;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(22, 93, 255, 0.2);
}

.btn:active:not(:disabled) {
    transform: scale(0.98);
    box-shadow: none;
}
    
.btn:disabled {
    background: #E5E7EB;
    color: #9CA3AF;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}
    
/* 错误提示样式 */
.current-pwd-error {
    margin-top: 0.5rem;
    padding: 7px 11px;
    border-radius: 8px;
    background-color: rgba(255, 77, 79, 0.08);
    border: 1px solid rgba(255, 77, 79, 0.2);
    font-size: 0.8rem;
    color: #FF4D4F;
    display: none;
    align-items: center;
    gap: 5px;
    box-shadow: 0 2px 4px rgba(255, 77, 79, 0.05);
    transition: all 0.2s ease;
}

.current-pwd-error.show {
    display: flex;
}

.inline-message {
    font-size: 0.8rem;
    display: none;
    align-items: center;
    gap: 4px;
    white-space: nowrap;
    color: #FF4D4F;
}

.inline-message.show {
    display: flex;
}

/* 成功提示样式 */
.block-message {
    margin-top: 1rem;
    padding: 11px 15px;
    border-radius: 9px;
    text-align: center;
    font-size: 0.85rem;
    display: none;
    align-items: center;
    justify-content: center;
    gap: 7px;
    transition: opacity 0.3s ease, transform 0.3s ease;
    transform: translateY(5px);
    opacity: 0;
    background-color: #F0FFF4;
    color: #00B42A;
    border: 1px solid #C6F7D0;
}

.block-message.show {
    display: flex;
    transform: translateY(0);
    opacity: 1;
}

/* 忘记密码链接样式 */
.form-hint {
    font-size: 0.8rem;
    color: #165DFF;
    text-decoration: none;
    transition: color 0.2s ease;
    white-space: nowrap;
}

.form-hint:hover {
    text-decoration: underline;
    color: #0E42D2;
}

/* 表单禁用样式 */
.form-disabled input {
    background-color: #F9FAFB;
    cursor: not-allowed;
}

.form-disabled .toggle-btn {
    cursor: not-allowed;
    color: #D1D5DB;
    background: none;
}
    
/* 移动端适配 */
@media (max-width: 380px) {
    .password-container {
        padding: 1.8rem 1.2rem;
        min-height: 540px;
    }
    
    .title h1 {
        font-size: 1.4rem;
    }

    .logo {
        height: 48px;
    }

    .password-input input {
        padding: 12px 14px;
        padding-right: 38px;
        font-size: 0.9rem;
    }

    .btn {
        padding: 12px;
        font-size: 0.9rem;
    }
    
    .label-action-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
    }
    
    .form-hint, .strength-text, .inline-message {
        font-size: 0.75rem;
    }

    .strength-text {
        text-align: left;
        min-width: auto;
    }

    .pwd-req-list {
        width: 100%;
        left: 0;
    }

    .current-pwd-error {
        padding: 6px 10px;
        font-size: 0.75rem;
    }
}