/* Tag page styles */
.tag-header {
    display: flex;
    gap: 40px;
    margin-bottom: 40px;
    align-items: center;
    background: #fff;
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
    margin-top: 20px;
}

.tag-header-content {
    flex: 1;
}

.tag-title {
    font-size: 36px;
    line-height: 1.2;
    margin: 0 0 15px;
    color: #15171A;
    font-weight: 600;
}

.tag-description {
    font-size: 18px;
    line-height: 1.5;
    color: #64666a;
}

.tag-header-image {
    width: 300px;
    height: 200px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
}

.tag-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.post-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

/* Post card styles specific to tag page */
.post-grid .post-card {
    margin: 0;
    display: flex;
    flex-direction: column;
    border-radius: 12px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.post-grid .post-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
}

.post-grid .post-card-image-link {
    display: block;
    position: relative;
    width: 100%;
    height: 0;
    padding-bottom: 60%;
    overflow: hidden;
}

.post-grid .post-card-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.post-grid .post-card-content {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 24px;
    flex: 1;
}

.post-grid .post-card-label {
    display: inline-flex;
    align-items: center;
    padding: 5px 10px;
    background: rgba(115, 115, 115, 0.08);
    border-radius: 999px;
    font-size: 12px;
    font-weight: 500;
    color: #52525B;
    width: fit-content;
}

.post-grid .post-card-title {
    font-size: 20px;
    line-height: 1.4;
    font-weight: 600;
    margin: 0;
    color: #15171A;
}

.post-grid .post-card-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #71717A;
}

.post-grid .post-card-meta-separator {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: #E4E4E7;
}

/* Dark mode support */
.dark-mode .tag-header {
    background: #1a1a1a;
}

.dark-mode .tag-title {
    color: #ffffff;
}

.dark-mode .tag-description {
    color: #9b9b9b;
}

.dark-mode .post-grid .post-card {
    background: #1a1a1a;
}

.dark-mode .post-grid .post-card-title {
    color: #ffffff;
}

.dark-mode .post-grid .post-card-label {
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.8);
}

.dark-mode .post-grid .post-card-meta {
    color: rgba(255, 255, 255, 0.6);
}

.dark-mode .post-grid .post-card-meta-separator {
    background: rgba(255, 255, 255, 0.2);
}

/* Responsive styles */
@media (max-width: 900px) {
    .tag-header {
        flex-direction: column-reverse;
        padding: 20px;
    }
    
    .tag-header-image {
        width: 100%;
        height: 200px;
        margin-bottom: 20px;
    }
    
    .tag-title {
        font-size: 28px;
    }
    
    .tag-description {
        font-size: 16px;
    }
    
    .post-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 20px;
    }
}

@media (max-width: 600px) {
    .post-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .post-grid .post-card-content {
        padding: 16px;
    }
    
    .post-grid .post-card-title {
        font-size: 18px;
    }
}
