/**
 * Global Archive Template Styles
 */

/* Container */
.tc-archive-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 20px;
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

/* Header Section */
.tc-archive-header {
    text-align: center;
    margin-bottom: 60px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    padding: 20px;
    position: relative;
    border-radius: 12px;
}

/* Background Image Mode (Desktop Only) */
@media (min-width: 1025px) {
    .tc-archive-header.tc-has-bg-image {
        max-width: 100%;
        /* Full width container within constraints or specific height section */
        height: 400px;
        background-size: cover;
        background-position: center;
        background-repeat: no-repeat;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        color: #fff;
        /* Ensure text is visible on bg */
        margin-bottom: 60px;
        border-radius: 0;
        /* Full width feel or keep radius if boxed */
        position: relative;
    }

    .tc-archive-header.tc-has-bg-image::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.5);
        /* Overlay */
        z-index: 1;
    }

    .tc-archive-header.tc-has-bg-image .tc-header-inner {
        position: relative;
        z-index: 2;
        max-width: 800px;
    }

    .tc-archive-header.tc-has-bg-image .tc-archive-title {
        color: #fff;
    }

    .tc-archive-header.tc-has-bg-image .tc-archive-short-description {
        color: rgba(255, 255, 255, 0.9);
    }

    .tc-archive-header.tc-has-bg-image .tc-archive-count {
        background: rgba(255, 255, 255, 0.2);
        color: #fff;
    }
}

.tc-archive-title {
    font-size: 42px;
    font-weight: 700;
    color: #333;
    margin-bottom: 15px;
    line-height: 1.2;
}

.tc-archive-short-description {
    font-size: 20px;
    color: #555;
    line-height: 1.5;
    margin-bottom: 20px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.tc-archive-description.tc-desc-bottom {
    margin-bottom: 0;
    margin-top: 60px;
    text-align: center;
    border-top: 1px solid #eee;
    padding-top: 40px;
}

.tc-archive-count {
    display: inline-block;
    background: #f0f0f0;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 14px;
    color: #555;
    font-weight: 600;
}

/* Grid Layout */
.tc-archive-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

/* Card Styling */
.tc-archive-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
    border: 1px solid #eee;
}

.tc-archive-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.12);
}

.tc-card-image {
    position: relative;
    padding-top: 66.67%;
    /* 3:2 Aspect Ratio */
    overflow: hidden;
    background-color: #f5f5f5;
}

.tc-card-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.tc-archive-card:hover .tc-card-image img {
    transform: scale(1.05);
}

.tc-card-content {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.tc-card-meta {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #999;
    margin-bottom: 10px;
    font-weight: 600;
}

.tc-card-title {
    font-size: 20px;
    font-weight: 700;
    margin: 0 0 10px 0;
    line-height: 1.4;
    color: #222;
}

.tc-card-title a {
    text-decoration: none;
    color: inherit;
    transition: color 0.2s ease;
}

.tc-card-title a:hover {
    color: #0073aa;
    /* Accent Color */
}

.tc-card-excerpt {
    font-size: 15px;
    color: #666;
    line-height: 1.6;
    margin-bottom: 20px;
    flex-grow: 1;
}

/* Button */
.tc-card-footer {
    margin-top: auto;
}

.tc-card-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: #000;
    color: #fff;
    text-decoration: none;
    padding: 12px 24px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s ease;
    width: 100%;
    box-sizing: border-box;
}

.tc-card-btn:hover {
    background-color: #333;
    color: #fff;
    transform: translateY(-1px);
}

.tc-card-btn i {
    margin-left: 8px;
    transition: transform 0.2s ease;
}

.tc-card-btn:hover i {
    transform: translateX(4px);
}

/* Responsive Breakpoints */
@media (max-width: 1024px) {
    .tc-archive-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
    }
}

@media (max-width: 768px) {
    .tc-archive-container {
        padding: 40px 15px;
    }

    .tc-archive-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }

    .tc-archive-title {
        font-size: 32px;
    }
}

@media (max-width: 480px) {
    .tc-archive-grid {
        grid-template-columns: 1fr;
    }

    .tc-archive-title {
        font-size: 28px;
    }
}