/* ==================== 案例详情页面样式 ==================== */

/* 面包屑导航 */
.breadcrumb { 
    background: var(--bg-light); 
    border-bottom: 1px solid var(--border-color); 
}

.breadcrumb-content { 
    max-width: 1200px; 
    margin: 0 auto; 
    padding: 14px 20px; 
    font-size: 14px; 
    color: var(--text-light); 
}

.breadcrumb-content a { 
    color: var(--primary-green); 
    text-decoration: none; 
    font-weight: 500; 
}

.breadcrumb-content a:hover { 
    text-decoration: underline; 
}

.breadcrumb-content span { 
    margin: 0 8px; 
    color: #d1d5db; 
}

/* 案例详情主体 */
.case-detail-section { 
    max-width: 1200px; 
    margin: 0 auto; 
    padding: 30px 20px; 
}

.case-detail-container { 
    display: grid; 
    grid-template-columns: 1fr 360px; 
    gap: 30px; 
}

/* 左侧内容 */
.case-main { 
    background: #fff; 
    border-radius: 16px; 
    overflow: hidden; 
    border: 1px solid var(--border-color); 
}

/* 案例封面图 */
.case-cover { 
    width: 100%; 
    height: 400px; 
    background: linear-gradient(135deg, #19b955 0%, #1ed961 100%); 
    position: relative; 
    overflow: hidden; 
}

.case-cover img { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
}

/* 封面图占位（未上传时显示） */
.case-cover-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.6);
}

.cover-placeholder-icon {
    font-size: 48px;
    margin-bottom: 12px;
    opacity: 0.6;
}

.case-cover-placeholder p {
    font-size: 16px;
    opacity: 0.7;
}

/* 封面图底部标题遮罩 */
.case-cover-overlay { 
    position: absolute; 
    bottom: 0; 
    left: 0; 
    right: 0; 
    padding: 30px; 
    background: linear-gradient(to top, rgba(0,0,0,0.75), transparent); 
    color: white; 
}

.case-cover-title { 
    font-size: 28px; 
    font-weight: 900; 
    margin-bottom: 10px; 
}

.case-cover-category { 
    display: inline-block; 
    padding: 5px 16px; 
    background: var(--primary-green); 
    border-radius: 20px; 
    font-size: 13px; 
    font-weight: 600; 
}

.case-content { 
    padding: 32px; 
}

.case-section { 
    margin-bottom: 36px; 
}

.case-section:last-child { 
    margin-bottom: 0; 
}

.case-section-title { 
    font-size: 20px; 
    font-weight: 700; 
    color: var(--text-dark); 
    margin-bottom: 16px; 
    padding-bottom: 10px; 
    border-bottom: 3px solid var(--primary-green); 
    display: inline-block; 
}

.case-section-content { 
    font-size: 15px; 
    line-height: 1.8; 
    color: var(--text-gray); 
}

.case-section-content p { 
    margin-bottom: 15px; 
}

.case-section-content ul { 
    list-style: none; 
    padding-left: 0; 
}

.case-section-content ul li { 
    padding: 10px 0; 
    padding-left: 28px; 
    position: relative; 
    border-bottom: 1px solid #f3f4f6; 
}

.case-section-content ul li:last-child { 
    border-bottom: none; 
}

.case-section-content ul li:before { 
    content: "✓"; 
    position: absolute; 
    left: 0; 
    color: var(--primary-green); 
    font-weight: bold; 
    font-size: 16px; 
}

/* 标签 */
.tags-list { 
    display: flex; 
    flex-wrap: wrap; 
    gap: 10px; 
}

.tag-item { 
    padding: 5px 16px; 
    background: rgba(25, 185, 85, 0.1); 
    color: var(--primary-green); 
    border-radius: 16px; 
    font-size: 14px; 
    font-weight: 500; 
}

/* 项目截图展示 */
.case-screenshots { 
    display: grid; 
    grid-template-columns: repeat(2, 1fr); 
    gap: 16px; 
}

.screenshot-item { 
    border-radius: 12px; 
    overflow: hidden; 
    border: 1px solid var(--border-color); 
    transition: all 0.3s; 
    cursor: pointer;
}

.screenshot-item:hover { 
    transform: scale(1.03); 
    box-shadow: var(--shadow-md); 
}

.screenshot-item img { 
    width: 100%; 
    height: 220px; 
    object-fit: cover; 
    display: block;
}

/* 板块空状态提示 */
.section-empty {
    color: #b0b8c4;
    font-style: italic;
    font-size: 14px;
    padding: 16px 0;
    text-align: center;
    background: #fafbfc;
    border-radius: 8px;
    border: 1px dashed #e5e7eb;
}

/* 预览地址链接 */
.preview-link {
    color: var(--primary-green);
    font-weight: 600;
    text-decoration: none;
    word-break: break-all;
    transition: color 0.2s;
}

.preview-link:hover {
    color: #14a34a;
    text-decoration: underline;
}

/* 图片查看器遮罩 */
.image-viewer-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
}

.image-viewer-overlay.active {
    opacity: 1;
    visibility: visible;
}

.image-viewer-overlay img {
    max-width: 90%;
    max-height: 90%;
    border-radius: 8px;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.5);
}

.image-viewer-close {
    position: absolute;
    top: 20px;
    right: 30px;
    color: white;
    font-size: 36px;
    cursor: pointer;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    transition: background 0.2s;
}

.image-viewer-close:hover {
    background: rgba(255, 255, 255, 0.3);
}

.image-viewer-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: white;
    font-size: 28px;
    cursor: pointer;
    width: 52px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    transition: background 0.2s;
    user-select: none;
}

.image-viewer-nav:hover {
    background: rgba(255, 255, 255, 0.3);
}

.image-viewer-prev {
    left: 20px;
}

.image-viewer-next {
    right: 20px;
}

.image-viewer-counter {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
}

/* 右侧信息 */
.case-sidebar { 
    display: flex; 
    flex-direction: column; 
    gap: 20px; 
}

.sidebar-card { 
    background: #fff; 
    border-radius: 16px; 
    padding: 24px; 
    border: 1px solid var(--border-color); 
}

.sidebar-card-title { 
    font-size: 17px; 
    font-weight: 700; 
    color: var(--text-dark); 
    margin-bottom: 18px; 
    padding-bottom: 12px; 
    border-bottom: 2px solid var(--primary-green); 
    display: flex; 
    align-items: center; 
    gap: 8px; 
}

.sidebar-card-title::before { 
    content: ''; 
    display: inline-block; 
    width: 4px; 
    height: 18px; 
    background: var(--primary-green); 
    border-radius: 2px; 
}

/* 案例信息 */
.case-info-list { 
    list-style: none; 
}

.case-info-item { 
    display: flex; 
    justify-content: space-between; 
    padding: 12px 0; 
    border-bottom: 1px solid #f3f4f6; 
}

.case-info-item:last-child { 
    border-bottom: none; 
}

.case-info-label { 
    color: var(--text-light); 
    font-size: 14px; 
}

.case-info-value { 
    color: var(--text-dark); 
    font-weight: 600; 
    font-size: 14px; 
}

/* 联系方式 */
.contact-item { 
    display: flex; 
    align-items: center; 
    gap: 14px; 
    padding: 14px; 
    background: var(--bg-light); 
    border-radius: 12px; 
    margin-bottom: 10px; 
    transition: all 0.3s; 
}

.contact-item:last-child { 
    margin-bottom: 0; 
}

.contact-item:hover { 
    background: rgba(25, 185, 85, 0.05); 
}

.contact-icon { 
    width: 42px; 
    height: 42px; 
    background: linear-gradient(135deg, #19b955 0%, #1ed961 100%); 
    border-radius: 50%; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    color: white; 
    font-size: 18px; 
    flex-shrink: 0; 
}

.contact-text { 
    flex: 1; 
}

.contact-text label { 
    display: block; 
    font-size: 12px; 
    color: var(--text-light); 
    margin-bottom: 2px; 
}

.contact-text span { 
    font-size: 15px; 
    font-weight: 600; 
    color: var(--text-dark); 
}

/* 咨询按钮 */
.contact-cta { 
    margin-top: 16px; 
}

.contact-cta a { 
    display: block; 
    text-align: center; 
    padding: 14px; 
    background: linear-gradient(135deg, #19b955 0%, #1ed961 100%); 
    color: white; 
    border-radius: 24px; 
    font-size: 16px; 
    font-weight: 600; 
    text-decoration: none; 
    transition: all 0.3s; 
    box-shadow: 0 4px 12px rgba(25, 185, 85, 0.3); 
}

.contact-cta a:hover { 
    transform: translateY(-2px); 
    box-shadow: 0 6px 20px rgba(25, 185, 85, 0.4); 
}

/* 二维码 */
.qrcode-box { 
    text-align: center; 
}

.qrcode-box img { 
    width: 180px; 
    height: 180px; 
    border: 2px solid var(--border-color); 
    border-radius: 12px; 
    margin-bottom: 12px; 
}

.qrcode-box p { 
    font-size: 14px; 
    color: var(--text-gray); 
}

/* 相关案例 */
.related-case { 
    display: flex; 
    gap: 14px; 
    padding: 14px 0; 
    border-bottom: 1px solid #f3f4f6; 
    cursor: pointer; 
    transition: all 0.3s; 
    text-decoration: none; 
}

.related-case:last-child { 
    border-bottom: none; 
}

.related-case:hover { 
    background: var(--bg-light); 
    margin: 0 -24px; 
    padding: 14px 24px; 
    border-radius: 8px; 
}

.related-case-img { 
    width: 80px; 
    height: 60px; 
    border-radius: 8px; 
    overflow: hidden; 
    flex-shrink: 0; 
}

.related-case-img img { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
}

.related-case-info { 
    flex: 1; 
}

.related-case-title { 
    font-size: 14px; 
    font-weight: 600; 
    color: var(--text-dark); 
    margin-bottom: 4px; 
    overflow: hidden; 
    text-overflow: ellipsis; 
    white-space: nowrap; 
}

.related-case-views { 
    font-size: 12px; 
    color: var(--text-light); 
}

/* 响应式 */
@media (max-width: 1024px) {
    .case-detail-container { 
        grid-template-columns: 1fr; 
    }
    
    .case-sidebar { 
        display: grid; 
        grid-template-columns: repeat(2, 1fr); 
    }
}

@media (max-width: 768px) {
    .case-sidebar { 
        grid-template-columns: 1fr; 
    }
    
    .case-screenshots { 
        grid-template-columns: 1fr; 
    }
    
    .case-cover { 
        height: 260px; 
    }
    
    .case-cover-title { 
        font-size: 22px; 
    }
}
