/* ================= BASE STYLES ================= */
.blog-hero {
    position: relative;
    height: 250px;
    background: url('/static/images/image.jpg') center/cover no-repeat;
    display: flex;
    justify-content: center;
    align-items: center;
    color: white;
    text-align: center;
    margin-top: 100px;
    padding: 20px;
}

.blog-hero .overlay {
    background: rgba(0, 0, 0, 0.5);
    padding: 40px;
    border-radius: 10px;
    max-width: 90%;
}

.blog-hero h1 {
    font-size: 2.2rem;
    margin-bottom: 0.5rem;
}

.blog-hero p {
    font-size: 1.1rem;
    line-height: 1.5;
}

.blog-posts {
    padding: 60px 20px;
    background-color: #f9f9f9;
}

.blog-posts .container {
    max-width: 1100px;
    margin: auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.blog-card {
    background-color: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.blog-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 28px rgba(0,0,0,0.15);
}

.blog-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

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

.blog-content {
    padding: 20px;
}

.blog-content h2 {
    font-size: 20px;
    margin-bottom: 10px;
    color: #333;
    line-height: 1.3;
}

.blog-content p {
    font-size: 14px;
    color: #555;
    line-height: 1.6;
}

.stars {
    color: #FFD700;
    margin-bottom: 10px;
    font-size: 16px;
}

.stars i {
    margin-right: 2px;
}

/* ================= RESPONSIVE ================= */

/* Large tablets and laptops */
@media (max-width: 1200px) {
    .blog-posts .container {
        max-width: 95%;
        gap: 25px;
    }
}

/* Tablets */
@media (max-width: 992px) {
    .blog-hero {
        height: 220px;
        margin-top: 90px;
    }

    .blog-hero .overlay {
        padding: 30px 25px;
    }

    .blog-hero h1 {
        font-size: 1.9rem;
    }

    .blog-hero p {
        font-size: 1rem;
    }

    .blog-posts {
        padding: 50px 18px;
    }

    .blog-posts .container {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: 22px;
    }

    .blog-content h2 {
        font-size: 18px;
    }

    .blog-content p {
        font-size: 13.5px;
    }

    .stars {
        font-size: 15px;
    }
}

/* Mobile landscape and small tablets */
@media (max-width: 768px) {
    .blog-hero {
        height: 200px;
        margin-top: 80px;
        padding: 15px;
    }

    .blog-hero .overlay {
        padding: 25px 20px;
        max-width: 95%;
    }

    .blog-hero h1 {
        font-size: 1.6rem;
        margin-bottom: 0.4rem;
    }

    .blog-hero p {
        font-size: 0.95rem;
    }

    .blog-posts {
        padding: 40px 15px;
    }

    .blog-posts .container {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 20px;
    }

    .blog-card img {
        height: 180px;
    }

    .blog-content {
        padding: 18px;
    }

    .blog-content h2 {
        font-size: 17px;
        margin-bottom: 8px;
    }

    .blog-content p {
        font-size: 13px;
        line-height: 1.5;
    }

    .stars {
        font-size: 14px;
        margin-bottom: 8px;
    }
}

/* Small phones */
@media (max-width: 480px) {
    .blog-hero {
        height: 180px;
        margin-top: 70px;
        padding: 12px;
    }

    .blog-hero .overlay {
        padding: 20px 15px;
    }

    .blog-hero h1 {
        font-size: 1.3rem;
    }

    .blog-hero p {
        font-size: 0.85rem;
        line-height: 1.4;
    }

    .blog-posts {
        padding: 30px 12px;
    }

    .blog-posts .container {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .blog-card {
        border-radius: 8px;
    }

    .blog-card img {
        height: 180px;
    }

    .blog-content {
        padding: 16px;
    }

    .blog-content h2 {
        font-size: 16px;
        margin-bottom: 7px;
    }

    .blog-content p {
        font-size: 12.5px;
    }

    .stars {
        font-size: 13px;
    }
}

/* Extra small phones */
@media (max-width: 360px) {
    .blog-hero {
        height: 160px;
    }

    .blog-hero h1 {
        font-size: 1.1rem;
    }

    .blog-hero p {
        font-size: 0.8rem;
    }

    .blog-card img {
        height: 160px;
    }

    .blog-content {
        padding: 14px;
    }

    .blog-content h2 {
        font-size: 15px;
    }

    .blog-content p {
        font-size: 12px;
    }
}