/* === 专业级：自定义属性弹窗 (2K 现代风) === */

/* 1. 背景遮罩 */
.pd-custom-modal-backdrop {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(15px);
    z-index: 200000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* 2. 弹窗主体 (2K风格) */
.pd-custom-modal-box {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    border: 2px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    width: 480px;
    height: 700px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    /*transform: scale(0.95) translateY(10px);*/
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* 3. 标头区域 (2K风格头部) */
.pd-modal-header {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.3) 0%, transparent 100%);
    padding: 25px 30px 20px;
    position: relative;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    gap: 20px;
    min-height: 120px;
}

/* 球员头像 */
.pd-player-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    border: 3px solid rgba(255, 215, 0, 0.3);
    background: linear-gradient(135deg, #34495e, #2c3e50);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    color: rgba(255, 255, 255, 0.7);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);

}

.pd-player-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.pd-player-avatar .pd-avatar-fallback {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
}

/* 球员信息区域 */
.pd-player-info {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.pd-modal-header h2 {
    margin: 0 0 8px 0;
    color: #fff;
    font-size: 24px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-family: 'Segoe UI', Roboto, sans-serif;
    text-shadow: 0 2px 8px rgba(0,0,0,0.5);
}

.pd-player-details {
    display: flex;
    gap: 20px;
    align-items: center;
    margin-bottom: 8px;
}

.pd-team-info {
    font-size: 16px;
    color: #ffd700;
    font-weight: 600;
}

.pd-position-info {
    font-size: 14px;
    color: #4fc3f7;
    font-weight: 600;
    background: rgba(79, 195, 247, 0.1);
    padding: 4px 12px;
    border-radius: 12px;
    border: 1px solid rgba(79, 195, 247, 0.3);
}

.pd-position-info {
    font-size: 10px;
    color: #1cb913;
    font-weight: 600;
    background: rgba(79, 195, 247, 0.1);
    padding: 0px 3px;
    border-radius: 12px;
    border: 1px solid rgba(79, 195, 247, 0.3);
}

.pd-player-stats {
    display: flex;
    gap: 15px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.7);
}

.pd-stat-item {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* 右上角综评 - 添加点击关闭功能 */
.pd-modal-header .pd-header-ovr {
    position: absolute;
    right: 30px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 42px;
    font-weight: 900;
    font-style: italic;
    color: #ffd700;
    text-shadow: 0 2px 10px rgba(255, 215, 0, 0.5);
    cursor: pointer;
    padding: 10px;
    transition: all 0.3s ease;
    border-radius: 8px;
}

.pd-modal-header .pd-header-ovr:hover {
    background: rgba(255, 215, 0, 0.1);
    transform: translateY(-50%) scale(1.1);
}

.pd-modal-header .pd-header-ovr:active {
    transform: translateY(-50%) scale(0.95);
}

/* 添加关闭提示 todo 以后的提示框可以都用这个方法 */
.pd-header-ovr::after {
    content: '点击关闭';
    position: absolute;
    bottom: -20px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 10px;
    color: rgba(255, 255, 255, 0.5);
    white-space: nowrap;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.pd-modal-header .pd-header-ovr:hover::after {
    opacity: 1;
}

/* 4. 标签页导航 */
.pd-tab-navigation {
    display: flex;
    background: rgba(0, 0, 0, 0.3);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.pd-tab-button {
    flex: 1;
    padding: 15px 20px;
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.pd-tab-button:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.05);
}

.pd-tab-button.pd-active {
    color: #ffd700;
    background: rgba(255, 215, 0, 0.1);
}

.pd-tab-button.pd-active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: #ffd700;
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

/* 5. 标签页内容 */
.pd-tab-content {
    display: none;
    padding: 0;
    overflow-y: auto;
    overflow-x: hidden;
    flex: 1;
}

.pd-tab-content.pd-active {
    display: block;
}

/* 6. 属性标签页内容 */
.pd-attributes-tab .pd-section-title {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.4), transparent);
    padding: 12px 25px;
    font-weight: 700;
    font-size: 16px;
    color: #ffd700;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin: 0;
}

.pd-attributes-grid {
    padding: 15px 25px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.pd-attribute-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s ease;
}

.pd-attribute-item:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateY(-1px);
}

.pd-attribute-label {
    font-weight: 500;
    color: #ccc;
    font-size: 12px;
}

.pd-attribute-value {
    font-weight: 700;
    color: #fff;
    font-family: 'Consolas', monospace;
    font-size: 14px;
}

/* 6个等级的颜色定义 */
.pd-rank-1 { color: #ffd700; text-shadow: 0 0 5px rgba(255, 215, 0, 0.5);  } /* 顶级 - 金色 */
.pd-rank-2 { color: #2196f3;  text-shadow: 0 0 3px rgba(76, 126, 175, 0.3);} /* 良好 - 蓝色 */
.pd-rank-3 { color: #4caf50;  text-shadow: 0 0 3px rgba(76, 175, 80, 0.3);} /* 优秀 - 绿色 */
.pd-rank-4 { color: #ffffff; } /* 较差 - 白色 */
.pd-rank-5 { color: #cf8365; } /* 极差 - 橙色 */

/* 7. 技能标签页内容 */
.pd-skills-tab .pd-skills-list {
    padding: 20px 25px;
}

.pd-skill-category {
    margin-bottom: 20px;
}

.pd-skill-category-title {
    font-size: 14px;
    color: #4fc3f7;
    font-weight: 600;
    margin-bottom: 10px;
    padding-bottom: 5px;
    border-bottom: 1px solid rgba(79, 195, 247, 0.3);
}

.pd-skill-item {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    padding: 12px 15px;
    margin-bottom: 8px;
    border-left: 3px solid;
    transition: all 0.3s ease;
}

.pd-skill-item:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateX(2px);
}

/* 技能等级颜色 */
.pd-skill-item.pd-grade-1 { border-left-color: #757575; }
.pd-skill-item.pd-grade-2 { border-left-color: #4caf50; }
.pd-skill-item.pd-grade-3 { border-left-color: #2196f3; }
.pd-skill-item.pd-grade-4 { border-left-color: #9c27b0; }
.pd-skill-item.pd-grade-5 { border-left-color: #ff9800; }

.pd-skill-name {
    font-weight: 600;
    margin-bottom: 5px;
    font-size: 13px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.pd-skill-item.pd-grade-1 .pd-skill-name { color: #bdbdbd; }
.pd-skill-item.pd-grade-2 .pd-skill-name { color: #81c784; }
.pd-skill-item.pd-grade-3 .pd-skill-name { color: #64b5f6; }
.pd-skill-item.pd-grade-4 .pd-skill-name { color: #ba68c8; }
.pd-skill-item.pd-grade-5 .pd-skill-name { color: #ffb74d; }

.pd-skill-type {
    font-size: 10px;
    color: #4fc3f7;
    background: rgba(79, 195, 247, 0.1);
    padding: 2px 6px;
    border-radius: 4px;
    margin-left: 8px;
}

.pd-skill-description {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.4;
}

/* 8. 数据标签页内容 (预留) */
.pd-placeholder {
    padding: 40px 25px;
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
    font-style: italic;
}

/* 9. 滚动条美化 */
.pd-tab-content::-webkit-scrollbar { width: 6px; }
.pd-tab-content::-webkit-scrollbar-track { background: rgba(0,0,0,0.2); border-radius: 3px; }
.pd-tab-content::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.3);
    border-radius: 3px;
}
.pd-tab-content::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.5); }

/* 10. 测试按钮样式 */
.pd-test-button {
    margin: 20px;
    padding: 12px 24px;
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.pd-test-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(52, 152, 219, 0.4);
}

/* 在现有的CSS文件中添加以下样式 */
.pd-stats-container {
    max-height: 400px;
    overflow-y: auto;
    overflow-x: auto;
}

.pd-stats-container::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

.pd-stats-container::-webkit-scrollbar-track {
    background: rgba(0,0,0,0.2);
    border-radius: 3px;
}

.pd-stats-container::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.3);
    border-radius: 3px;
}

.pd-stats-container::-webkit-scrollbar-thumb:hover {
    background: rgba(255,255,255,0.5);
}

#pd-stats-table th, #pd-stats-table td {
    white-space: nowrap;
}

#pd-stats-table tbody tr:hover {
    background: rgba(255,255,255,0.05) !important;
}


/* 属性描述提示栏样式 */
.pd-notice-bar {
    grid-column: span 3; /* 占满整行 */
    background: rgba(255, 235, 59, 0.1);
    border-radius: 4px;
    margin-top: 8px;
    padding: 0;
    height: 0;
    opacity: 0;
    overflow: hidden;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
}

.pd-notice-bar.active {
    height: 32px;
    padding: 0 12px;
    opacity: 1;
    border: 1px solid rgba(255, 235, 59, 0.3);
}

.pd-notice-text {
    color: #ffeb3b;
    font-size: 12px;
    font-style: italic;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 增加属性项的可点击反馈 */
.pd-attribute-item {
    cursor: pointer;
    user-select: none;
}
.pd-attribute-item:active {
    transform: scale(0.95);
    background: rgba(255, 255, 255, 0.15);
}