/**
 * Washington Home Improvements - Blog Page
 * Clean blog layout
 */

/* ========================================
   BLOG HERO
   ======================================== */

.blog-hero {
    background: linear-gradient(135deg, #1a2332 0%, #2a3e50 50%, #3d5a6e 100%);
    padding: var(--space-3xl) 0 var(--space-2xl);
    position: relative;
    overflow: hidden;
}

/* Blueprint pattern overlay */
.blog-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(135, 206, 235, 0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(135, 206, 235, 0.02) 1px, transparent 1px);
    background-size: 50px 50px;
    opacity: 0.5;
    z-index: 1;
}

.blog-hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.blog-hero-title {
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    font-weight: 900;
    color: white;
    margin-bottom: var(--space-xl);
    letter-spacing: -1px;
    display: inline-block;
    position: relative;
}

/* Animated Graphite Underline */
.blog-hero-title .title-underline {
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 4px;
    background: linear-gradient(90deg, transparent, #6c757d, transparent);
    animation: underlineExpand 2s ease-out forwards;
    animation-delay: 0.3s;
}

@keyframes underlineExpand {
    0% {
        width: 0;
        opacity: 0;
    }
    50% {
        opacity: 1;
    }
    100% {
        width: 150px;
        opacity: 1;
    }
}

.blog-hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.125rem);
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.8;
    margin-top: var(--space-md);
}

/* ========================================
   BLOG POSTS SECTION
   ======================================== */

.blog-posts-section {
    padding: var(--space-3xl) 0;
    background: #f8f9fa;
}

.blog-content-wrapper {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: var(--space-2xl);
    max-width: 1400px;
    margin: 0 auto;
}

/* ========================================
   BLOG POSTS GRID
   ======================================== */

.blog-posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: var(--space-xl);
    margin-bottom: var(--space-2xl);
}

.blog-post-card {
    background: white;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

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

.blog-post-image {
    width: 100%;
    height: 240px;
    overflow: hidden;
    position: relative;
    background: linear-gradient(135deg, #1a2332 0%, #2a3e50 100%);
}

.blog-post-image a {
    display: block;
    width: 100%;
    height: 100%;
}

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

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

.blog-post-date {
    position: absolute;
    top: var(--space-md);
    right: var(--space-md);
    background: linear-gradient(135deg, #ff9100 0%, #ff7c00 100%);
    color: white;
    padding: var(--space-sm);
    border-radius: var(--radius-md);
    text-align: center;
    min-width: 60px;
    box-shadow: 0 4px 10px rgba(255, 145, 0, 0.3);
}

.post-day {
    display: block;
    font-size: 1.5rem;
    font-weight: 900;
    line-height: 1;
}

.post-month {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    margin-top: 2px;
}

.blog-post-content {
    padding: var(--space-lg);
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.blog-post-meta {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    margin-bottom: var(--space-md);
    font-size: 0.875rem;
}

.post-category {
    color: #ff9100;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.5px;
}

.post-reading-time {
    color: #6c757d;
}

.blog-post-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1a2332;
    margin-bottom: var(--space-md);
    line-height: 1.4;
}

.blog-post-title a {
    color: #1a2332;
    text-decoration: none;
    transition: color 0.3s ease;
}

.blog-post-title a:hover {
    color: #ff9100;
}

.blog-post-excerpt {
    color: #555;
    line-height: 1.7;
    margin-bottom: var(--space-lg);
    flex-grow: 1;
}

.blog-post-read-more {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    color: #ff9100;
    font-weight: 700;
    text-decoration: none;
    font-size: 0.9375rem;
    transition: all 0.3s ease;
}

.blog-post-read-more:hover {
    gap: var(--space-sm);
    color: #ff7c00;
}

.blog-post-read-more svg {
    transition: transform 0.3s ease;
}

.blog-post-read-more:hover svg {
    transform: translateX(3px);
}

/* ========================================
   NO POSTS MESSAGE
   ======================================== */

.no-posts {
    text-align: center;
    padding: var(--space-3xl);
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

.no-posts h3 {
    font-size: 1.5rem;
    color: #1a2332;
    margin-bottom: var(--space-md);
}

.no-posts p {
    color: #6c757d;
}

/* ========================================
   PAGINATION
   ======================================== */

.blog-pagination {
    margin-top: var(--space-2xl);
}

.blog-pagination .page-numbers {
    display: flex;
    gap: var(--space-sm);
    justify-content: center;
    align-items: center;
    list-style: none;
    padding: 0;
    margin: 0;
}

.blog-pagination .page-numbers li {
    list-style: none;
}

.blog-pagination a,
.blog-pagination .current {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 45px;
    height: 45px;
    padding: 0 var(--space-md);
    background: white;
    color: #1a2332;
    text-decoration: none;
    border-radius: var(--radius-md);
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.blog-pagination .current {
    background: linear-gradient(135deg, #ff9100 0%, #ff7c00 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(255, 145, 0, 0.3);
}

.blog-pagination a:hover {
    background: #1a2332;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

/* ========================================
   SIDEBAR
   ======================================== */

.blog-sidebar {
    display: flex;
    flex-direction: column;
    gap: var(--space-xl);
}

.sidebar-widget {
    background: white;
    padding: var(--space-xl);
    border-radius: var(--radius-lg);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

.widget-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1a2332;
    margin-bottom: var(--space-lg);
    padding-bottom: var(--space-md);
    border-bottom: 3px solid #ff9100;
}

.category-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.category-list li {
    margin-bottom: var(--space-sm);
}

.category-list a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--space-sm) 0;
    color: #555;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.category-list a:hover {
    color: #ff9100;
    padding-left: var(--space-sm);
}

.category-list .count {
    color: #6c757d;
    font-size: 0.875rem;
}

.recent-posts-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.recent-posts-list li {
    padding: var(--space-md) 0;
    border-bottom: 1px solid #e9ecef;
}

.recent-posts-list li:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.recent-posts-list a {
    color: #1a2332;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9375rem;
    line-height: 1.5;
    transition: color 0.3s ease;
    display: block;
    margin-bottom: var(--space-xs);
}

.recent-posts-list a:hover {
    color: #ff9100;
}

.recent-post-date {
    display: block;
    color: #6c757d;
    font-size: 0.8125rem;
}

/* Sidebar CTA */
.sidebar-cta {
    background: linear-gradient(135deg, #1a2332 0%, #2a3e50 100%);
    color: white;
}

.sidebar-cta .widget-title {
    color: white;
    border-bottom-color: #87CEEB;
}

.sidebar-cta p {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: var(--space-lg);
}

.sidebar-cta-button {
    display: block;
    text-align: center;
    padding: var(--space-md) var(--space-lg);
    background: linear-gradient(135deg, #ff9100 0%, #ff7c00 100%);
    color: white;
    text-decoration: none;
    font-weight: 700;
    border-radius: var(--radius-md);
    transition: all 0.3s ease;
}

.sidebar-cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 145, 0, 0.4);
}

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

@media (max-width: 1024px) {
    .blog-content-wrapper {
        grid-template-columns: 1fr;
    }

    .blog-sidebar {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: var(--space-lg);
    }
}

@media (max-width: 768px) {
    .blog-posts-grid {
        grid-template-columns: 1fr;
        gap: var(--space-lg);
    }

    .blog-sidebar {
        grid-template-columns: 1fr;
    }

    .blog-posts-section {
        padding: var(--space-2xl) var(--space-md);
    }
}

@media (max-width: 480px) {
    .blog-hero {
        padding: var(--space-2xl) var(--space-md);
    }

    .blog-post-card {
        margin: 0;
    }
}
