/* ========== 密码强度检测器专属样式 ========== */

/* 主容器 */
.pwdstrength-container {
    max-width: 700px;
    margin: 20px auto;
    padding: 0 10px;
}

/* 区域标题样式 */
.pwdstrength-section-title {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin: 0 0 15px 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.pwdstrength-section-title .material-icons {
    font-size: 20px;
    color: #2196F3;
}

/* 密码输入区域 */
.pwdstrength-input-section {
    position: relative;
    margin-bottom: 25px;
}

.pwdstrength-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    border: 2px solid #e0e3eb;
    border-radius: 8px;
    overflow: hidden;
    transition: border-color 0.3s;
}

.pwdstrength-input-wrapper:focus-within {
    border-color: #2196F3;
}

.pwdstrength-input {
    flex: 1;
    padding: 14px 16px;
    font-size: 16px;
    border: none;
    outline: none;
    font-family: 'Courier New', monospace;
    background: #fafbfc;
}

.pwdstrength-toggle-visibility {
    padding: 10px 14px;
    background: none;
    border: none;
    cursor: pointer;
    color: #666;
    transition: color 0.3s;
    display: flex;
    align-items: center;
}

.pwdstrength-toggle-visibility:hover {
    color: #2196F3;
}

.pwdstrength-toggle-visibility .material-icons {
    font-size: 22px;
}

/* 强度等级显示条 */
.pwdstrength-meter-container {
    margin-bottom: 25px;
}

.pwdstrength-meter-label {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.pwdstrength-meter-text {
    font-size: 14px;
    font-weight: 500;
    color: #666;
}

.pwdstrength-meter-level {
    font-size: 14px;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 12px;
    transition: all 0.3s;
}

.pwdstrength-level-very-weak {
    background: #ffebee;
    color: #c62828;
}

.pwdstrength-level-weak {
    background: #fff3e0;
    color: #ef6c00;
}

.pwdstrength-level-medium {
    background: #fff8e1;
    color: #f9a825;
}

.pwdstrength-level-strong {
    background: #e8f5e9;
    color: #2e7d32;
}

.pwdstrength-level-very-strong {
    background: #e3f2fd;
    color: #1565c0;
}

.pwdstrength-meter-bar {
    height: 8px;
    background: #e8eaed;
    border-radius: 4px;
    overflow: hidden;
}

.pwdstrength-meter-fill {
    height: 100%;
    width: 0%;
    border-radius: 4px;
    transition: width 0.4s ease, background-color 0.4s ease;
}

/* 安全评分卡片 */
.pwdstrength-score-card {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 25px;
    border: 1px solid #e8eaed;
}

.pwdstrength-score-card h4 {
    margin: 0 0 15px 0;
    font-size: 16px;
    color: #333;
    display: flex;
    align-items: center;
}

.pwdstrength-score-card h4 .material-icons {
    font-size: 20px;
    color: #2196F3;
    margin-right: 6px;
}

.pwdstrength-score-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 15px;
}

.pwdstrength-score-item {
    text-align: center;
    padding: 12px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.pwdstrength-score-value {
    font-size: 28px;
    font-weight: bold;
    color: #2196F3;
    margin-bottom: 5px;
}

.pwdstrength-score-label {
    font-size: 12px;
    color: #888;
}

/* 改进建议区域 */
.pwdstrength-suggestions {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
    border: 1px solid #e8eaed;
}

.pwdstrength-suggestions h4 {
    margin: 0 0 15px 0;
    font-size: 16px;
    color: #333;
    display: flex;
    align-items: center;
}

.pwdstrength-suggestions h4 .material-icons {
    font-size: 20px;
    color: #2196F3;
    margin-right: 6px;
}

.pwdstrength-suggestion-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.pwdstrength-suggestion-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 0;
    border-bottom: 1px solid #e8eaed;
    font-size: 14px;
}

.pwdstrength-suggestion-item:last-child {
    border-bottom: none;
}

.pwdstrength-suggestion-item .material-icons {
    font-size: 18px;
    margin-top: 2px;
    flex-shrink: 0;
}

.pwdstrength-icon-pass {
    color: #4caf50;
}

.pwdstrength-icon-fail {
    color: #f44336;
}

.pwdstrength-suggestion-text {
    color: #555;
}

/* 密码统计信息 */
.pwdstrength-stats {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    margin-bottom: 20px;
    padding: 12px 16px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e8eaed;
}

.pwdstrength-stat-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    color: #555;
}

.pwdstrength-stat-item .material-icons {
    font-size: 18px;
    color: #2196F3;
}

.pwdstrength-stat-item strong {
    color: #2196F3;
    font-weight: 600;
}

/* 操作按钮 */
.pwdstrength-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #e8eaed;
}

.pwdstrength-actions .btn {
    min-width: 140px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.pwdstrength-actions .btn .material-icons {
    font-size: 18px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .pwdstrength-container {
        margin: 15px auto;
    }

    .pwdstrength-score-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .pwdstrength-stats {
        gap: 12px;
    }

    .pwdstrength-actions {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .pwdstrength-input {
        font-size: 14px;
        padding: 12px 14px;
    }

    .pwdstrength-score-grid {
        grid-template-columns: 1fr;
    }

    .pwdstrength-score-value {
        font-size: 24px;
    }
}
