/**
 * Blog Page Styles
 * Modern, clean blog listing page following design principles
 *
 * @package TravelSuggest
 * @since 1.0.0
 */

/* ========================================
   HERO SECTION
   ======================================== */

.blog-hero-wrapper {
    width: 100%;
    margin: 0;
    padding: 0;
}

body.page-template-template-blog .blog-hero {
    position: relative;
    width: 100%;
    height: 50vh;
    min-height: 400px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    align-items: flex-end;
    justify-content: flex-start;
    overflow: hidden;
}

body.page-template-template-blog .hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(43, 45, 66, 0.85) 0%, rgba(248, 150, 30, 0.75) 100%);
    z-index: 1;
}

body.page-template-template-blog .hero-content {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem 2rem;
    text-align: left;
}

body.page-template-template-blog .hero-container {
    max-width: 800px;
    margin: 0;
}

body.page-template-template-blog .hero-title {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 800;
    color: #ffffff;
    margin: 0 0 1rem 0;
    line-height: 1.2;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

body.page-template-template-blog .hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.125rem);
    color: rgba(255, 255, 255, 0.95);
    margin: 0;
    line-height: 1.6;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}

/* ========================================
   BLOG CONTAINER & GRID
   ======================================== */

/* Breadcrumbs */
body.page-template-template-blog .ts-breadcrumbs {
    margin-bottom: 2rem;
    padding: 0;
}

.blog-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1.5rem 4rem;
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    margin-bottom: 3rem;
}

/* ========================================
   BLOG CARD - MODERN DESIGN
   ======================================== */

.ts-blog-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: #ffffff;
    border-radius: 12px;
    border: 1px solid hsl(214.3, 31.8%, 91.4%);
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.ts-blog-card:hover {
    transform: translateY(-6px);
    border-color: #f97316;
    box-shadow: 0 12px 24px rgba(249, 115, 22, 0.15);
}

/* Image */
.ts-blog-card__image {
    position: relative;
    width: 100%;
    height: 220px;
    overflow: hidden;
    flex-shrink: 0;
    background: hsl(214.3, 31.8%, 91.4%);
    border-radius: 12px 12px 0 0;
}

.ts-blog-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform 0.4s ease;
}

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

/* Category Badge */
.ts-blog-card__category {
    position: absolute;
    top: 1rem;
    left: 1rem;
    padding: 0.375rem 0.75rem;
    background: rgba(249, 115, 22, 0.95);
    color: #ffffff;
    font-size: 0.8125rem;
    font-weight: 600;
    border-radius: 6px;
    text-transform: uppercase;
    letter-spacing: 0.025em;
    z-index: 2;
    backdrop-filter: blur(4px);
}

/* Card Body */
.ts-blog-card__body {
    flex: 1;
    padding: 1.5rem 1.5rem 0;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.ts-blog-card__title {
    font-size: 1.25rem;
    font-weight: 600;
    line-height: 1.4;
    margin: 0;
}

.ts-blog-card__title a {
    color: hsl(222.2, 84%, 4.9%);
    text-decoration: none;
    transition: color 0.2s ease;
}

.ts-blog-card__title a:hover {
    color: #f97316;
}

.ts-blog-card__excerpt {
    font-size: 0.9375rem;
    line-height: 1.6;
    color: hsl(215.4, 16.3%, 46.9%);
    margin: 0;
    flex: 1;
}

/* Meta */
.ts-blog-card__meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.875rem;
    color: hsl(215.4, 16.3%, 56.9%);
    padding-top: 0.75rem;
    border-top: 1px solid hsl(214.3, 31.8%, 91.4%);
}

.ts-blog-card__date {
    display: flex;
    align-items: center;
    gap: 0.375rem;
}

.ts-blog-card__date svg {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
}

.ts-blog-card__reading-time {
    display: flex;
    align-items: center;
    gap: 0.375rem;
}

/* Card Footer Button */
.ts-blog-card__button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem 1.5rem;
    margin: 0;
    background: hsl(0, 0%, 98%);
    border-top: 1px solid hsl(214.3, 31.8%, 91.4%);
    border-radius: 0 0 11px 11px;
    color: hsl(215.4, 16.3%, 46.9%);
    font-size: 0.9375rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
}

.ts-blog-card__button:hover {
    background: #f97316;
    color: #ffffff;
    border-top-color: #f97316;
}

.ts-blog-card__button svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    transition: transform 0.2s ease;
}

.ts-blog-card__button:hover svg {
    transform: translateX(4px);
}

/* ========================================
   LOAD MORE BUTTON
   ======================================== */

.blog-load-more-wrap {
    text-align: center;
    margin-top: 3rem;
}

#blog-load-more {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 2rem;
    background: #f97316;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(249, 115, 22, 0.2);
}

#blog-load-more:hover {
    background: #ea580c;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(249, 115, 22, 0.3);
}

#blog-load-more:disabled {
    background: hsl(214.3, 31.8%, 91.4%);
    color: hsl(215.4, 16.3%, 56.9%);
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* ========================================
   NO POSTS STATE
   ======================================== */

.blog-no-posts {
    text-align: center;
    padding: 5rem 2rem;
    max-width: 600px;
    margin: 0 auto;
}

.blog-no-posts .no-posts-icon {
    margin-bottom: 1.5rem;
}

.blog-no-posts .no-posts-icon svg {
    width: 64px;
    height: 64px;
    color: hsl(215.4, 16.3%, 76.9%);
}

.blog-no-posts h2 {
    font-size: 1.75rem;
    font-weight: 700;
    color: hsl(222.2, 84%, 4.9%);
    margin: 0 0 1rem 0;
}

.blog-no-posts p {
    font-size: 1.125rem;
    color: hsl(215.4, 16.3%, 46.9%);
    margin: 0;
    line-height: 1.6;
}

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

/* Tablet (768px - 1024px) */
@media (max-width: 1024px) {
    body.page-template-template-blog .blog-hero {
        height: 45vh;
        min-height: 350px;
    }

    .blog-container {
        padding: 3rem 1.25rem;
    }

    .blog-grid {
        gap: 1.75rem;
    }

    .ts-blog-card__image {
        height: 200px;
    }

    .ts-blog-card__title {
        font-size: 1.125rem;
    }
}

/* Mobile (max-width: 767px) */
@media (max-width: 767px) {
    body.page-template-template-blog .blog-hero {
        height: 40vh;
        min-height: 300px;
    }

    body.page-template-template-blog .hero-content {
        padding: 0 1rem;
    }

    body.page-template-template-blog .hero-title {
        font-size: clamp(1.75rem, 6vw, 2.5rem);
        margin-bottom: 0.75rem;
    }

    body.page-template-template-blog .hero-subtitle {
        font-size: 0.9375rem;
    }

    .blog-container {
        padding: 2.5rem 1rem;
    }

    .blog-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        margin-bottom: 2.5rem;
    }

    .ts-blog-card__image {
        height: 180px;
    }

    .ts-blog-card__body {
        padding: 1.25rem;
    }

    .ts-blog-card__title {
        font-size: 1.125rem;
    }

    .ts-blog-card__excerpt {
        font-size: 0.875rem;
    }

    .ts-blog-card__meta {
        font-size: 0.8125rem;
        gap: 0.75rem;
    }

    .ts-blog-card__button {
        padding: 0.75rem 1rem;
        font-size: 0.875rem;
    }

    .blog-load-more-wrap {
        margin-top: 2.5rem;
    }

    #blog-load-more {
        width: 100%;
        padding: 0.875rem 1.5rem;
    }

    .blog-no-posts {
        padding: 4rem 1.5rem;
    }

    .blog-no-posts h2 {
        font-size: 1.5rem;
    }

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

/* Very Small Mobile (max-width: 480px) */
@media (max-width: 480px) {
    .ts-blog-card__category {
        font-size: 0.75rem;
        padding: 0.25rem 0.625rem;
    }

    .ts-blog-card__image {
        height: 160px;
    }
}

