/* ============================================
   BLOG PAGE STYLES
   Dove Paints - Dark Luxury Theme
   ============================================ */

/* ---- Hero Banner ---- */
.blog-hero {
    position: relative;
    width: 100%;
    height: 500px;
    overflow: hidden;
    display: flex;
    align-items: center;
}

.blog-hero-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.blog-hero-overlay {
    position: absolute;
    inset: 0;
    display: none;
}

.blog-hero-content {
    position: relative;
    z-index: 2;
    padding: 40px 60px;
    max-width: 1400px;
    width: 100%;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.15);
}

.blog-hero-label {
    display: inline-block;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: #c5920a;
    margin-bottom: 10px;
}

.blog-hero-title {
    font-family: 'Cinzel', serif;
    font-size: 4.5rem;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 12px;
    line-height: 1.15;
}

.blog-hero-desc {
    font-size: 1.05rem;
    color: #333;
    max-width: 580px;
    line-height: 1.6;
    margin-bottom: 16px;
}

/* ---- Breadcrumbs ---- */
.blog-breadcrumb ol {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 0;
    padding: 0;
}

.blog-breadcrumb li {
    font-size: 0.85rem;
    color: rgba(0, 0, 0, 0.5);
}

.blog-breadcrumb li a {
    color: rgba(0, 0, 0, 0.65);
    text-decoration: none;
    transition: color 0.2s;
}

.blog-breadcrumb li a:hover {
    color: var(--accent-glow-primary, #e8b923);
}

.blog-breadcrumb li::after {
    content: '/';
    margin-left: 6px;
    color: rgba(0, 0, 0, 0.35);
}

.blog-breadcrumb li:last-child::after {
    display: none;
}

/* ---- Main Section ---- */
.blog-main-section {
    padding: 60px 24px 40px;
    background: #ffffff;
}

.blog-container {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 40px;
    align-items: start;
}

/* ---- Sidebar ---- */
.blog-sidebar {
    position: sticky;
    top: 100px;
    background: #f8f8f8;
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 12px;
    padding: 28px 24px;
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.blog-sidebar-close {
    display: none;
}

.sidebar-block {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.sidebar-title {
    font-size: 1rem;
    font-weight: 700;
    color: #1a1a1a;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--accent-glow-primary, #e8b923);
}

/* ---- Search ---- */
.blog-search-wrapper {
    position: relative;
}

.blog-search-input {
    width: 100%;
    padding: 12px 16px 12px 42px;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 8px;
    color: #1a1a1a;
    font-size: 0.9rem;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
    font-family: inherit;
}

.blog-search-input::placeholder {
    color: rgba(0, 0, 0, 0.4);
}

.blog-search-input:focus {
    border-color: var(--accent-glow-primary, #e8b923);
    box-shadow: 0 0 0 2px rgba(232, 185, 35, 0.15);
}

.blog-search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(0, 0, 0, 0.45);
    font-size: 0.85rem;
    pointer-events: none;
}

/* ---- Categories ---- */
.sidebar-category-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.category-link {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 14px;
    border-radius: 8px;
    text-decoration: none;
    color: rgba(0, 0, 0, 0.7);
    font-size: 0.9rem;
    transition: all 0.2s;
}

.category-link:hover {
    background: rgba(0, 0, 0, 0.05);
    color: #000;
}

.category-link.active-category {
    background: var(--accent-glow-primary, #e8b923);
    color: #000;
    font-weight: 600;
}

.category-count {
    background: rgba(0, 0, 0, 0.06);
    padding: 2px 10px;
    border-radius: 12px;
    font-size: 0.78rem;
    font-weight: 600;
}

.active-category .category-count {
    background: rgba(0, 0, 0, 0.15);
    color: #000;
}

/* ---- Tags ---- */
.sidebar-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag-chip {
    padding: 6px 14px;
    background: rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 20px;
    color: rgba(0, 0, 0, 0.7);
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
}

.tag-chip:hover {
    background: rgba(232, 185, 35, 0.12);
    border-color: var(--accent-glow-primary, #e8b923);
    color: var(--accent-glow-primary, #e8b923);
}

.tag-chip.active-tag {
    background: var(--accent-glow-primary, #e8b923);
    color: #000;
    border-color: var(--accent-glow-primary, #e8b923);
    font-weight: 600;
}

/* ---- Promo Card ---- */
.sidebar-promo-card {
    background: linear-gradient(135deg, rgba(232, 185, 35, 0.12), rgba(232, 185, 35, 0.04));
    border: 1px solid rgba(232, 185, 35, 0.2);
    border-radius: 12px;
    overflow: hidden;
}

.promo-card-inner {
    padding: 24px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.promo-icon {
    font-size: 2rem;
    color: var(--accent-glow-primary, #e8b923);
}

.promo-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0;
}

.promo-text {
    font-size: 0.85rem;
    color: rgba(0, 0, 0, 0.65);
    line-height: 1.5;
    margin: 0;
}

.promo-btn {
    display: inline-block;
    margin-top: 8px;
    padding: 10px 24px;
    background: var(--accent-glow-primary, #e8b923);
    color: #000;
    font-weight: 700;
    font-size: 0.85rem;
    border-radius: 8px;
    text-decoration: none;
    transition: opacity 0.2s, transform 0.2s;
}

.promo-btn:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

/* ---- Content Header ---- */
.blog-content-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 28px;
}

.mobile-sidebar-toggle {
    display: none;
}

.blog-sort-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-left: auto;
}

.sort-label {
    font-size: 0.85rem;
    color: rgba(0, 0, 0, 0.6);
    white-space: nowrap;
}

.blog-sort-select {
    padding: 8px 14px;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 8px;
    color: #1a1a1a;
    font-size: 0.85rem;
    font-family: inherit;
    outline: none;
    cursor: pointer;
    appearance: auto;
}

.blog-sort-select option {
    background: #fff;
    color: #1a1a1a;
}

/* ---- Featured Card ---- */
.blog-featured-card {
    margin-bottom: 36px;
    border-radius: 16px;
    overflow: hidden;
    background: #f8f8f8;
    border: 1px solid rgba(0, 0, 0, 0.08);
    transition: border-color 0.3s, box-shadow 0.3s;
}

.blog-featured-card:hover {
    border-color: rgba(232, 185, 35, 0.5);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.featured-card-link {
    display: grid;
    grid-template-columns: 1fr 1fr;
    text-decoration: none;
    color: inherit;
}

.featured-image-wrap {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16/9;
}

.featured-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

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

.featured-card-content {
    padding: 36px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 12px;
}

.featured-card-title {
    font-size: 1.55rem;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0;
    line-height: 1.3;
}

.featured-card-desc {
    font-size: 0.92rem;
    color: rgba(0, 0, 0, 0.65);
    line-height: 1.6;
    margin: 0;
}

.featured-card-meta {
    display: flex;
    gap: 18px;
    font-size: 0.8rem;
    color: rgba(0, 0, 0, 0.5);
    margin-top: 4px;
}

.featured-card-meta i {
    margin-right: 5px;
}

.featured-read-more {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--accent-glow-primary, #e8b923);
    font-weight: 600;
    font-size: 0.9rem;
    margin-top: 8px;
    transition: gap 0.2s;
}

.blog-featured-card:hover .featured-read-more {
    gap: 12px;
}

/* ---- Blog Card Badges ---- */
.blog-card-badge {
    position: absolute;
    top: 14px;
    left: 14px;
    padding: 5px 14px;
    border-radius: 6px;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    z-index: 2;
}

.badge-color-inspiration {
    background: rgba(232, 185, 35, 0.9);
    color: #000;
}

.badge-exterior {
    background: rgba(220, 80, 60, 0.9);
    color: #fff;
}

.badge-interior {
    background: rgba(70, 140, 200, 0.9);
    color: #fff;
}

.badge-guides {
    background: rgba(100, 180, 120, 0.9);
    color: #000;
}

.badge-maintenance {
    background: rgba(160, 120, 200, 0.9);
    color: #fff;
}

.badge-tips {
    background: rgba(230, 150, 50, 0.9);
    color: #000;
}

/* ---- Blog Posts Grid ---- */
.blog-posts-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-bottom: 40px;
}

.blog-post-card {
    border-radius: 12px;
    overflow: hidden;
    background: #f8f8f8;
    border: 1px solid rgba(0, 0, 0, 0.08);
    transition: border-color 0.3s, transform 0.3s, box-shadow 0.3s;
}

.blog-post-card:hover {
    border-color: rgba(232, 185, 35, 0.5);
    transform: translateY(-4px);
    box-shadow: 0 12px 36px rgba(0, 0, 0, 0.1);
}

.post-card-link {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
    height: 100%;
}

.post-card-image-wrap {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16/10;
}

.post-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

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

.post-card-content {
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
}

.post-card-title {
    font-size: 1rem;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.post-card-desc {
    font-size: 0.84rem;
    color: rgba(0, 0, 0, 0.6);
    line-height: 1.55;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex: 1;
}

.post-card-meta {
    display: flex;
    gap: 14px;
    font-size: 0.76rem;
    color: rgba(0, 0, 0, 0.45);
    margin-top: 4px;
}

.post-card-meta i {
    margin-right: 4px;
}

.post-read-more {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--accent-glow-primary, #e8b923);
    font-weight: 600;
    font-size: 0.84rem;
    margin-top: 6px;
    transition: gap 0.2s;
}

.blog-post-card:hover .post-read-more {
    gap: 10px;
}

/* ---- Empty State ---- */
.blog-empty-state {
    text-align: center;
    padding: 80px 24px;
    color: rgba(0, 0, 0, 0.5);
}

.empty-state-icon {
    font-size: 3rem;
    color: rgba(0, 0, 0, 0.15);
    margin-bottom: 16px;
}

.blog-empty-state h3 {
    font-size: 1.2rem;
    color: rgba(0, 0, 0, 0.7);
    margin: 0 0 8px;
}

.blog-empty-state p {
    font-size: 0.9rem;
    margin: 0;
}

/* ---- Pagination ---- */
.blog-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 20px;
}

.pagination-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 20px;
    background: #f8f8f8;
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 8px;
    color: rgba(0, 0, 0, 0.7);
    font-size: 0.85rem;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s;
}

.pagination-btn:hover:not(:disabled) {
    background: rgba(232, 185, 35, 0.1);
    border-color: var(--accent-glow-primary, #e8b923);
    color: var(--accent-glow-primary, #e8b923);
}

.pagination-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.pagination-numbers {
    display: flex;
    gap: 4px;
}

.page-num {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 8px;
    color: rgba(0, 0, 0, 0.6);
    font-size: 0.85rem;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s;
}

.page-num:hover {
    background: rgba(0, 0, 0, 0.05);
    color: #000;
}

.page-num.active-page {
    background: var(--accent-glow-primary, #e8b923);
    color: #000;
    font-weight: 700;
    border-color: var(--accent-glow-primary, #e8b923);
}

/* ---- CTA Section ---- */
.blog-cta-section {
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    padding: 80px 24px;
    text-align: center;
}

.blog-cta-container {
    max-width: 700px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.blog-cta-title {
    font-family: 'Cinzel', serif;
    font-size: 2rem;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0;
    letter-spacing: 1px;
}

.blog-cta-subtitle {
    font-size: 1rem;
    color: var(--accent-glow-primary, #e8b923);
    font-weight: 600;
    margin: 0;
}

.blog-cta-text {
    font-size: 0.92rem;
    color: rgba(0, 0, 0, 0.6);
    line-height: 1.7;
    margin: 0;
}

.blog-cta-btn {
    display: inline-block;
    margin-top: 8px;
    padding: 14px 36px;
    background: var(--accent-glow-primary, #e8b923);
    color: #000;
    font-weight: 700;
    font-size: 0.95rem;
    border-radius: 8px;
    text-decoration: none;
    transition: opacity 0.2s, transform 0.2s;
}

.blog-cta-btn:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

/* ---- Visually Hidden (a11y) ---- */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

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

@media (max-width: 1200px) {
    .blog-posts-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 960px) {
    .blog-hero {
        height: 400px;
    }

    .blog-hero-title {
        font-size: 3.2rem;
    }

    .blog-container {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .blog-sidebar {
        display: none;
        position: fixed;
        inset: 0;
        z-index: 1000;
        background: #fff;
        border: none;
        border-radius: 0;
        padding: 80px 24px 24px;
        overflow-y: auto;
        top: 0;
    }

    .blog-sidebar.open {
        display: flex;
    }

    .blog-sidebar-close {
        display: flex;
        align-items: center;
        justify-content: center;
        position: absolute;
        top: 20px;
        right: 20px;
        width: 40px;
        height: 40px;
        background: rgba(0, 0, 0, 0.08);
        border: none;
        border-radius: 8px;
        color: #1a1a1a;
        font-size: 1.2rem;
        cursor: pointer;
        z-index: 1001;
    }

    .mobile-sidebar-toggle {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        padding: 10px 18px;
        background: #f8f8f8;
        border: 1px solid rgba(0, 0, 0, 0.12);
        border-radius: 8px;
        color: #1a1a1a;
        font-size: 0.85rem;
        font-family: inherit;
        cursor: pointer;
        transition: all 0.2s;
    }

    .mobile-sidebar-toggle:hover {
        background: rgba(232, 185, 35, 0.1);
        border-color: var(--accent-glow-primary, #e8b923);
    }

    .featured-card-link {
        grid-template-columns: 1fr;
    }

    .featured-card-content {
        padding: 24px;
    }

    .featured-card-title {
        font-size: 1.3rem;
    }
}

@media (max-width: 768px) {
    .blog-hero {
        margin: 15vw 0;
        height: 320px;
    }

    .blog-hero-content {
        padding: 13px 20px 36px;
    }

    .blog-hero-title {
        font-size: 2.6rem;
    }

    .blog-hero-desc {
        font-size: 0.9rem;
    }

    .blog-main-section {
        padding: 32px 16px;
    }

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

    .blog-cta-section {
        padding: 50px 16px;
    }

    .blog-cta-title {
        font-size: 1.5rem;
    }
}

@media (max-width: 480px) {
    .blog-hero {
        height: 260px;
    }

    .blog-hero-title {
        font-size: 2rem;
    }

    .blog-content-header {
        flex-direction: column;
        gap: 12px;
        align-items: stretch;
    }

    .blog-sort-wrapper {
        margin-left: 0;
        justify-content: space-between;
    }

    .blog-featured-card .featured-card-content {
        padding: 18px;
    }

    .featured-card-title {
        font-size: 1.1rem;
    }
}

/* ============================================
   ARTICLE READER OVERLAY
   ============================================ */

.article-overlay {
    position: fixed;
    inset: 0;
    z-index: 2000;
    background: rgba(15, 15, 20, 0.55);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.28s ease, visibility 0.28s ease;
}

.article-overlay.open {
    opacity: 1;
    visibility: visible;
}

.article-modal-wrap {
    position: relative;
    width: 100%;
    max-width: 860px;
    max-height: 92vh;
    transform: scale(0.96) translateY(10px);
    opacity: 0;
    transition: transform 0.32s cubic-bezier(0.18, 0.89, 0.32, 1.02), opacity 0.25s ease;
}

.article-overlay.open .article-modal-wrap {
    transform: scale(1) translateY(0);
    opacity: 1;
}

.article-modal-scroll {
    max-height: 92vh;
    overflow-y: auto;
    overscroll-behavior: contain;
    background: #ffffff;
    border-radius: 14px;
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.3);
    -webkit-overflow-scrolling: touch;
}

.article-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    z-index: 6;
    width: 38px;
    height: 38px;
    border: none;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.06);
    color: #333;
    font-size: 1rem;
    line-height: 1;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s, color 0.2s;
}

.article-modal-close:hover {
    background: rgba(0, 0, 0, 0.12);
    color: #000;
}

/* ---- Article Content ---- */
.article-body {
    padding: 44px 36px 56px;
}

.article-wrap {
    max-width: 700px;
    margin: 0 auto;
}

.article-category {
    display: inline-block;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #c5920a;
    margin-bottom: 12px;
}

.article-title {
    font-family: 'Cinzel', serif;
    font-size: 2.1rem;
    line-height: 1.25;
    color: #1a1a1a;
    margin: 0 0 14px;
}

.article-intro {
    font-size: 1.05rem;
    line-height: 1.7;
    color: #4a4a4a;
    margin: 0 0 16px;
}

.article-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
    font-size: 0.82rem;
    color: #8a8a8a;
    padding-bottom: 20px;
    border-bottom: 1px solid #eeeeee;
}

.article-figure {
    margin: 26px 0 0;
}

.article-figure img {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border-radius: 12px;
}

.article-content {
    margin-top: 28px;
}

.article-content h2 {
    font-size: 1.45rem;
    line-height: 1.35;
    color: #1a1a1a;
    margin: 34px 0 12px;
}

.article-content h3 {
    font-size: 1.12rem;
    color: #1a1a1a;
    margin: 26px 0 10px;
}

.article-content p {
    font-size: 1rem;
    line-height: 1.8;
    color: #444;
    margin: 0 0 16px;
}

.article-content ul,
.article-content ol {
    margin: 0 0 18px;
    padding-left: 22px;
    color: #444;
    line-height: 1.7;
}

.article-content li {
    margin: 8px 0;
}

.article-content strong {
    color: #1a1a1a;
    font-weight: 700;
}

.article-footer {
    margin-top: 44px;
    padding-top: 22px;
    border-top: 1px solid #eeeeee;
}

.article-footer-label {
    display: block;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #9a9a9a;
    margin-bottom: 12px;
}

.article-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.article-tag-chip {
    padding: 6px 14px;
    background: #f4f4f4;
    border-radius: 20px;
    color: #555;
    font-size: 0.8rem;
    font-weight: 500;
}

@media (max-width: 640px) {
    .article-overlay {
        padding: 0;
    }

    .article-modal-wrap,
    .article-modal-scroll {
        max-width: none;
        max-height: 100%;
        border-radius: 0;
    }

    .article-modal-scroll {
        height: 100vh;
        height: 100dvh;
    }

    .article-body {
        padding: 40px 20px 48px;
    }

    .article-title {
        font-size: 1.6rem;
    }

    .article-content h2 {
        font-size: 1.3rem;
    }
}
