/* ==============================================
   Case Detail Page Styles
   YourIT - Customer Case Study Detail
============================================== */

/* ==================== Breadcrumb ==================== */
.breadcrumb-nav {
    background: #f8fafb;
    padding: 16px 0;
    border-bottom: 1px solid #e5e8eb;
}

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    list-style: none;
    margin: 0;
    padding: 0;
    font-size: 14px;
}

.breadcrumb li {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #8b95a1;
}

.breadcrumb li:not(:last-child)::after {
    content: '/';
    color: #d1d5db;
}

.breadcrumb a {
    color: #6b7684;
    transition: color 0.2s;
}

.breadcrumb a:hover {
    color: var(--primary);
}

.breadcrumb .active {
    color: #191f28;
    font-weight: 500;
}

/* ==================== Hero Section ==================== */
.case-hero {
    padding: 60px 0 80px;
    background: linear-gradient(180deg, #f8fafb 0%, #ffffff 100%);
}

.case-hero .container {
    display: flex;
    align-items: flex-start;
    gap: 60px;
}

.hero-content {
    flex: 1;
    max-width: 640px;
}

.hero-meta {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.industry-tag {
    padding: 6px 14px;
    background: #f2f4f6;
    color: #4e5968;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
}

.service-tag {
    padding: 6px 14px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
}

.service-tag.infra {
    background: rgba(37, 99, 235, 0.1);
    color: #2563eb;
}

.service-tag.security {
    background: rgba(220, 38, 38, 0.1);
    color: #dc2626;
}

.service-tag.marketing {
    background: rgba(234, 88, 12, 0.1);
    color: #ea580c;
}

.hero-title {
    font-size: 36px;
    font-weight: 800;
    line-height: 1.4;
    color: #191f28;
    margin-bottom: 16px;
    letter-spacing: -0.02em;
}

.hero-subtitle {
    font-size: 18px;
    line-height: 1.7;
    color: #6b7684;
    margin-bottom: 32px;
}

.hero-company {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px 24px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}

.company-logo {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, #00D4AA 0%, #00B4D8 100%);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: 700;
    color: #fff;
}

.company-info h2 {
    font-size: 18px;
    font-weight: 700;
    color: #191f28;
    margin-bottom: 4px;
}

.company-info span {
    font-size: 14px;
    color: #8b95a1;
}

.company-info .company-size::after {
    content: '·';
    margin: 0 8px;
}

.hero-image {
    flex: 0 0 420px;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.12);
}

.hero-image img {
    width: 100%;
    height: auto;
    display: block;
}

/* ==================== Stats Section ==================== */
.case-stats {
    padding: 0;
    margin-top: -40px;
    position: relative;
    z-index: 2;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.stat-card {
    background: #fff;
    border-radius: 20px;
    padding: 32px;
    text-align: center;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
    border: 1px solid #f2f4f6;
}

.stat-value {
    font-size: 42px;
    font-weight: 800;
    background: linear-gradient(135deg, #00D4AA 0%, #00B4D8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 8px;
}

.stat-label {
    font-size: 15px;
    color: #6b7684;
    font-weight: 500;
}

/* ==================== Content Section ==================== */
.case-content {
    padding: 80px 0;
}

.content-wrapper {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 48px;
    align-items: start;
}

.content-main {
    min-width: 0;
}

.content-section {
    margin-bottom: 48px;
    padding-bottom: 48px;
    border-bottom: 1px solid #f2f4f6;
}

.content-section:last-of-type {
    border-bottom: none;
}

.section-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    margin-bottom: 20px;
}

.section-icon.challenge {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
}

.section-icon.solution {
    background: rgba(0, 212, 170, 0.1);
    color: #00D4AA;
}

.section-icon.result {
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
}

.content-section h3 {
    font-size: 24px;
    font-weight: 700;
    color: #191f28;
    margin-bottom: 20px;
}

.section-content {
    font-size: 16px;
    line-height: 1.9;
    color: #4e5968;
}

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

.section-content ul,
.section-content ol {
    margin: 16px 0;
    padding-left: 24px;
}

.section-content li {
    margin-bottom: 8px;
}

/* Full Content (Rich Text) */
.full-content {
    border-bottom: none;
    padding-bottom: 0;
}

.rich-content {
    font-size: 16px;
    line-height: 1.9;
    color: #4e5968;
}

.rich-content h2 {
    font-size: 28px;
    font-weight: 700;
    color: #191f28;
    margin: 48px 0 20px;
}

.rich-content h3 {
    font-size: 22px;
    font-weight: 700;
    color: #191f28;
    margin: 40px 0 16px;
}

.rich-content h4 {
    font-size: 18px;
    font-weight: 600;
    color: #191f28;
    margin: 32px 0 12px;
}

.rich-content p {
    margin-bottom: 20px;
}

.rich-content img {
    max-width: 100%;
    border-radius: 12px;
    margin: 24px 0;
}

.rich-content blockquote {
    border-left: 4px solid var(--primary);
    padding-left: 20px;
    margin: 24px 0;
    font-style: italic;
    color: #6b7684;
}

.rich-content pre {
    background: #1e293b;
    color: #e2e8f0;
    padding: 20px;
    border-radius: 12px;
    overflow-x: auto;
    margin: 24px 0;
}

.rich-content code {
    background: #f2f4f6;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 14px;
}

/* Tags */
.content-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 40px;
}

.tag {
    padding: 8px 16px;
    background: #f8fafb;
    border: 1px solid #e5e8eb;
    border-radius: 20px;
    font-size: 14px;
    color: #6b7684;
}

/* Share Section */
.share-section {
    display: flex;
    align-items: center;
    gap: 16px;
    padding-top: 32px;
    border-top: 1px solid #f2f4f6;
}

.share-label {
    font-size: 14px;
    font-weight: 600;
    color: #6b7684;
}

.share-buttons {
    display: flex;
    gap: 10px;
}

.share-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #f2f4f6;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: #6b7684;
    cursor: pointer;
    transition: all 0.2s;
}

.share-btn:hover {
    background: var(--primary);
    color: #fff;
}

.share-btn.copied {
    background: #10b981;
    color: #fff;
}

/* ==================== Sidebar ==================== */
.content-sidebar {
    position: relative;
}

.sidebar-card {
    background: #fff;
    border-radius: 20px;
    padding: 32px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    border: 1px solid #f2f4f6;
}

.sidebar-card.sticky {
    position: sticky;
    top: 100px;
}

.sidebar-card h4 {
    font-size: 18px;
    font-weight: 700;
    color: #191f28;
    margin-bottom: 12px;
}

.sidebar-card > p {
    font-size: 14px;
    line-height: 1.7;
    color: #6b7684;
    margin-bottom: 24px;
}

.btn-consult {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #00D4AA 0%, #00B4D8 100%);
    color: #fff;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s;
    margin-bottom: 24px;
}

.btn-consult:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 212, 170, 0.35);
}

.contact-info {
    padding-top: 24px;
    border-top: 1px solid #f2f4f6;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

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

.contact-item i {
    width: 36px;
    height: 36px;
    background: #f8fafb;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    color: var(--primary);
}

.contact-item .label {
    display: block;
    font-size: 12px;
    color: #8b95a1;
    margin-bottom: 2px;
}

.contact-item a,
.contact-item span:not(.label) {
    font-size: 14px;
    font-weight: 600;
    color: #191f28;
}

.contact-item a:hover {
    color: var(--primary);
}

/* ==================== Related Cases ==================== */
.related-cases {
    padding: 80px 0;
    background: #f8fafb;
}

.related-cases h3 {
    font-size: 28px;
    font-weight: 700;
    color: #191f28;
    margin-bottom: 32px;
    text-align: center;
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.related-card {
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
    transition: all 0.3s;
}

.related-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.12);
}

.related-thumb {
    height: 180px;
    overflow: hidden;
    background: #f2f4f6;
}

.related-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.related-card:hover .related-thumb img {
    transform: scale(1.05);
}

.related-info {
    padding: 20px 24px 24px;
}

.related-industry {
    font-size: 12px;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 8px;
    display: block;
}

.related-info h4 {
    font-size: 18px;
    font-weight: 700;
    color: #191f28;
    margin-bottom: 8px;
}

.related-info p {
    font-size: 14px;
    color: #6b7684;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ==================== CTA Section ==================== */
.case-cta {
    padding: 100px 0;
    background: linear-gradient(135deg, #00D4AA 0%, #00B4D8 100%);
}

.cta-content {
    text-align: center;
    color: #fff;
}

.cta-content h2 {
    font-size: 36px;
    font-weight: 800;
    margin-bottom: 16px;
}

.cta-content p {
    font-size: 18px;
    opacity: 0.9;
    margin-bottom: 40px;
}

.cta-buttons {
    display: flex;
    justify-content: center;
    gap: 16px;
}

.btn-primary-lg {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 18px 32px;
    background: #fff;
    color: var(--primary);
    border-radius: 16px;
    font-size: 17px;
    font-weight: 700;
    transition: all 0.3s;
}

.btn-primary-lg:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.2);
}

.btn-secondary-lg {
    display: inline-flex;
    align-items: center;
    padding: 18px 32px;
    background: transparent;
    border: 2px solid rgba(255, 255, 255, 0.5);
    color: #fff;
    border-radius: 16px;
    font-size: 17px;
    font-weight: 600;
    transition: all 0.3s;
}

.btn-secondary-lg:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: #fff;
}

/* ==================== Responsive ==================== */
@media (max-width: 1024px) {
    .case-hero .container {
        flex-direction: column;
    }

    .hero-content {
        max-width: 100%;
    }

    .hero-image {
        flex: none;
        width: 100%;
        max-width: 500px;
    }

    .content-wrapper {
        grid-template-columns: 1fr;
    }

    .content-sidebar {
        order: -1;
    }

    .sidebar-card.sticky {
        position: relative;
        top: 0;
    }

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

@media (max-width: 768px) {
    .case-hero {
        padding: 40px 0 60px;
    }

    .hero-title {
        font-size: 28px;
    }

    .hero-subtitle {
        font-size: 16px;
    }

    .hero-company {
        padding: 16px 20px;
    }

    .company-logo {
        width: 48px;
        height: 48px;
        font-size: 20px;
    }

    .stats-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .stat-card {
        padding: 24px;
    }

    .stat-value {
        font-size: 32px;
    }

    .case-content {
        padding: 48px 0;
    }

    .content-section h3 {
        font-size: 20px;
    }

    .related-grid {
        grid-template-columns: 1fr;
    }

    .case-cta {
        padding: 60px 0;
    }

    .cta-content h2 {
        font-size: 26px;
    }

    .cta-buttons {
        flex-direction: column;
    }

    .btn-primary-lg,
    .btn-secondary-lg {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .breadcrumb {
        font-size: 12px;
    }

    .hero-meta {
        flex-wrap: wrap;
    }

    .hero-title {
        font-size: 24px;
    }

    .share-section {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* ==================== Animations ==================== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.content-section {
    animation: fadeInUp 0.6s ease-out forwards;
}

.content-section:nth-child(1) { animation-delay: 0.1s; }
.content-section:nth-child(2) { animation-delay: 0.2s; }
.content-section:nth-child(3) { animation-delay: 0.3s; }

.stat-card {
    animation: fadeInUp 0.5s ease-out forwards;
}

.stat-card:nth-child(1) { animation-delay: 0.1s; }
.stat-card:nth-child(2) { animation-delay: 0.2s; }
.stat-card:nth-child(3) { animation-delay: 0.3s; }
