/*filter*/
.filter-bar {
    margin-top: 70px;
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    align-items: center;
}

.filter-bar input,
.filter-bar select,
.filter-bar button {
    padding: 0.5rem 1rem;
    font-size: 1rem;
}





.container {
    margin-top: 40px;
    display: flex;
    width: 1200px;
    justify-content: space-evenly;
    flex-wrap: wrap;
    margin: 0 auto;
}
.card {
    position: relative; /* needed for absolute positioning of pseudo-element */
    display: flex;
    flex-direction: column;
    width: 350px;
    height: 450px; /* default fixed height */
    margin: 10px;
    background-color: #fff;
    border-radius: 10px;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    transition: height 0.3s ease;
}

.card-label {
    position: absolute;
    top: 10px;
    left: 10px;
    font-size: 14px;
    font-weight: bold;
    text-transform: uppercase;
    color: black; /* fallback */
    pointer-events: none;
}



.card-header img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}
.card-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
    padding: 20px;
    line-height: 1.5rem;
    gap: 10px;
}

.tag {
    background: #cccccc;
    border-radius: 50px;
    font-size: 12px;
    margin: 0;
    color: #fff;
    padding: 2px 10px;
    text-transform: uppercase;
    cursor: pointer;
}
.tag-teal {
    background-color: #26adad;
}
.tag-purple {
    background-color: #346693;
}
.tag-pink {
    background-color: #f48079;
}

.card-body p {
    font-size: 13px;
    margin: 0 0 0;
    display: -webkit-box;
    -webkit-line-clamp: 3;       /* Limit to 3 lines */
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}
.user {
    width: 100%;
    display: flex;
    justify-content: flex-end; /* push content to the right */
    align-items: center;
    margin-top: auto; /* stays at the bottom */
    gap: 10px;
}


.user img {
    border-radius: 50%;
    width: 40px;
    height: 40px;
    margin-right: 10px;
}
.user-info h5 {
    margin: 0;
}
.user-info small {
    color: #545d7a;
}

@media (max-width: 1024px) {
    .card {
        height: 400px;
        width: 100%;
        max-width: 300px;
    }
}

@media (max-width: 768px) {
    .card {
        height: 350px;
    }
}

@media (max-width: 480px) {
    .card {
        height: 300px;
        width: 90%;
    }
}



/*blog posts*/

.card-link {
    color: inherit;
    text-decoration: none;
    display: block;
    height: 100%;
}

/* Blog post layout */
.blog-post {
    max-width: 800px;
    margin: 2rem auto;
    padding: 1rem;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

.post-header img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    border-radius: 10px;
}

.post-body {
    padding: 1.5rem 1rem;
}

.post-body h1 {
    font-size: 2rem;
    margin-top: 1rem;
}

.post-body article {
    margin-top: 2rem;
    line-height: 1.6rem;
}

.post-body article h2 {
    margin-top: 1.5rem;
    font-size: 1.4rem;
}