/* 分享功能样式 */

/* 分享按钮 */
.share-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border: 1px solid #e0e0e0;
    border-radius: 20px;
    background: #fff;
    color: #333;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    cursor: pointer;
}

.share-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* 不同平台的分享按钮样式 */
.share-btn[data-platform="wechat"]:hover {
    background: #07C160;
    color: white;
    border-color: #07C160;
}

.share-btn[data-platform="weibo"]:hover {
    background: #E6162D;
    color: white;
    border-color: #E6162D;
}

.share-btn[data-platform="qq"]:hover {
    background: #12B7F5;
    color: white;
    border-color: #12B7F5;
}

.share-btn[data-platform="linkedin"]:hover {
    background: #0077B5;
    color: white;
    border-color: #0077B5;
}

.share-btn[data-platform="twitter"]:hover {
    background: #1DA1F2;
    color: white;
    border-color: #1DA1F2;
}

.share-btn[data-platform="facebook"]:hover {
    background: #1877F2;
    color: white;
    border-color: #1877F2;
}

/* 分享按钮组 */
.share-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* 微信分享模态框 */
.wechat-share-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
}

.wechat-share-content {
    background: white;
    border-radius: 12px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    max-width: 400px;
    width: 90%;
}

.wechat-share-content h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 15px;
    color: #333;
}

.wechat-share-content p {
    margin-bottom: 20px;
    color: #666;
    font-size: 14px;
}

.qr-code {
    margin-bottom: 25px;
}

.qr-code img {
    width: 200px;
    height: 200px;
    border: 1px solid #e0e0e0;
    padding: 10px;
    border-radius: 8px;
}

.close-btn {
    background: #f5f5f5;
    border: none;
    padding: 10px 20px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    color: #333;
    cursor: pointer;
    transition: all 0.3s ease;
}

.close-btn:hover {
    background: #e0e0e0;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .share-buttons {
        flex-direction: column;
    }

    .share-btn {
        justify-content: center;
    }

    .wechat-share-content {
        padding: 20px;
    }

    .qr-code img {
        width: 150px;
        height: 150px;
    }
}

/* 工具页面的分享按钮 */
.tool-share {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #e0e0e0;
}

.tool-share h4 {
    margin-bottom: 15px;
    font-size: 14px;
    font-weight: 600;
    color: #333;
}

/* 博客页面的分享按钮 */
.post-share {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #e0e0e0;
}

.post-share .share-label {
    font-weight: 600;
    margin-right: 10px;
    color: #333;
}

/* 分享计数 */
.share-count {
    margin-left: 5px;
    font-size: 12px;
    color: #999;
}

/* 分享提示 */
.share-tooltip {
    position: relative;
}

.share-tooltip:hover::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 12px;
    white-space: nowrap;
    margin-bottom: 5px;
    z-index: 1000;
}

.share-tooltip:hover::before {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    border-width: 5px;
    border-style: solid;
    border-color: rgba(0, 0, 0, 0.8) transparent transparent transparent;
    margin-bottom: -10px;
    z-index: 1000;
}