/* ==========================================================================
   案例列表与详情页专属样式 (Portfolio & Portfolio Detail)
   ========================================================================== */

/* --- 案例列表过滤器 (Portfolio Filter) --- */
.portfolio-filter {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 50px;
}

.filter-btn {
    padding: 8px 24px;
    background: transparent;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 30px;
    font-size: 14px;
    color: var(--text-sec);
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: var(--font-sans);
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--dark);
    color: var(--gold);
    border-color: var(--dark);
}

/* --- 案例详情头部信息 (Case Detail Info) --- */
.case-detail-header {
    background: var(--bg-card);
    padding: 60px 5%;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.case-info-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.case-info-item {
    position: relative;
}

.case-info-item:not(:last-child)::after {
    content: '';
    position: absolute;
    right: -15px;
    top: 20%;
    height: 60%;
    width: 1px;
    background: rgba(0, 0, 0, 0.1);
}

.case-info-label {
    font-size: 13px;
    color: var(--text-sec);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 8px;
    display: block;
}

.case-info-value {
    font-size: 18px;
    font-weight: 600;
    color: var(--dark);
    font-family: var(--font-serif);
}

/* --- 案例详情内容区 (Case Detail Content) --- */
.case-article {
    max-width: 1200px;
    margin: 60px auto;
    padding: 0 5%;
}

.case-article p {
    font-size: 16px;
    line-height: 2;
    color: var(--text-sec);
    margin-bottom: 30px;
}

.case-article img {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius-sm);
    margin: 20px 0 40px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

/* --- 案例详情页的独立客户评价区块 (Case Specific Testimonial) --- */
.case-testimonial {
    background: linear-gradient(135deg, rgba(197, 168, 128, 0.1) 0%, rgba(197, 168, 128, 0.02) 100%);
    padding: 60px;
    border-radius: var(--radius-sm);
    margin: 60px 0;
    position: relative;
    border-left: 4px solid var(--gold);
}

.case-testimonial::before {
    content: '"';
    position: absolute;
    top: 20px;
    left: 30px;
    font-size: 80px;
    font-family: var(--font-serif);
    color: rgba(197, 168, 128, 0.3);
    line-height: 1;
}

.case-testi-text {
    font-size: 18px;
    color: var(--dark);
    line-height: 1.8;
    font-weight: 500;
    font-style: italic;
    margin-bottom: 25px;
    position: relative;
    z-index: 2;
}

.case-testi-author {
    display: flex;
    align-items: center;
    gap: 15px;
}

.case-testi-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--dark);
    color: var(--gold);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-family: var(--font-serif);
}

.case-testi-meta strong {
    display: block;
    font-size: 16px;
    color: var(--dark);
    margin-bottom: 4px;
}

.case-testi-meta span {
    font-size: 13px;
    color: var(--text-sec);
}

/* --- 客户评价页面专属 (Testimonials Gallery) --- */
.masonry-gallery {
    column-count: 3;
    column-gap: 30px;
    margin-top: 40px;
}

.chat-screenshot-card {
    break-inside: avoid;
    margin-bottom: 30px;
    position: relative;
    border-radius: var(--radius-sm);
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
    background: #fff;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    display: block;
    text-decoration: none;
}

.chat-screenshot-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.12);
}

.chat-screenshot-card img {
    width: 100%;
    display: block;
    border-bottom: 1px solid rgba(0, 0, 0, 0.03);
}

.chat-screenshot-info {
    padding: 20px;
    background: var(--bg-card);
}

.chat-screenshot-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--dark);
    margin-bottom: 6px;
}

.chat-screenshot-meta {
    font-size: 13px;
    color: var(--text-sec);
}

.chat-screenshot-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.chat-screenshot-card:hover .chat-screenshot-overlay {
    opacity: 1;
}

.chat-screenshot-overlay svg {
    width: 48px;
    height: 48px;
    color: #fff;
    opacity: 0.8;
}

@media (max-width: 992px) {
    .masonry-gallery {
        column-count: 2;
    }
}

@media (max-width: 768px) {
    .case-info-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }

    .case-info-item:nth-child(2)::after {
        display: none;
    }

    .case-info-item:not(:last-child)::after {
        right: -10px;
    }

    .case-testimonial {
        padding: 40px 20px;
    }

    .masonry-gallery {
        column-count: 1;
    }
}