/*
 * Sunsgoods Theme — Blog Archive & Single Post Styles
 *
 * @package Sunsgoods
 */

/* =========================================================================
 * Archive page
 * ========================================================================= */
.blog-archive {
    background: #fff;
    padding: 50px 0 70px;
}

.blog-archive__container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
}

/* Header */
.blog-archive__header {
    text-align: center;
    margin-bottom: 40px;
}

.blog-archive__title {
    font-family: 'Times New Roman', 'oxygen-bold', Arial, sans-serif;
    font-size: 32px;
    font-weight: 700;
    color: #222;
    margin: 0 0 12px;
}

.blog-archive__subtitle {
    font-family: 'Times New Roman', 'oxygen-regular', Arial, sans-serif;
    font-size: 15px;
    color: #666;
    margin: 0;
}

/* =========================================================================
 * 3-column grid — gap 20px
 * ========================================================================= */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

/* =========================================================================
 * Card
 * ========================================================================= */
.blog-card {
    background: #fff;
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
    transition: box-shadow 0.25s, transform 0.25s;
}

.blog-card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.13);
    transform: translateY(-3px);
}

.blog-card__link {
    display: block;
    text-decoration: none;
    color: inherit;
}

/* Thumbnail — fixed 220px height */
.blog-card__thumb {
    width: 100%;
    height: 220px;
    overflow: hidden;
    background: #eee;
}

.blog-card__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s;
}

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

.blog-card__img--placeholder {
    background: linear-gradient(135deg, #ddd 0%, #eee 100%);
}

/* Body */
.blog-card__body {
    padding: 16px 16px 20px;
}

.blog-card__title {
    font-family: 'Times New Roman', 'oxygen-regular', Arial, sans-serif;
    font-size: 15px;
    font-weight: 400;
    line-height: 1.5;
    color: #333;
    margin: 0 0 10px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-align: center;
}

.blog-card__cat {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-family: 'Times New Roman', 'oxygen-regular', Arial, sans-serif;
    font-size: 13px;
    color: #c78a2e;
}

.blog-card__cat-icon {
    flex-shrink: 0;
}

/* =========================================================================
 * Pagination
 * ========================================================================= */
.blog-pagination {
    margin-top: 40px;
    text-align: center;
}

.blog-pagination .nav-links {
    display: flex;
    justify-content: center;
    gap: 6px;
}

.blog-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    color: #555;
    text-decoration: none;
    transition: all 0.2s;
}

.blog-pagination .page-numbers:hover {
    background: #f5f5f5;
    border-color: #bbb;
}

.blog-pagination .page-numbers.current {
    background: #c78a2e;
    border-color: #c78a2e;
    color: #fff;
}

.blog-archive__empty {
    text-align: center;
    color: #999;
    font-size: 16px;
    padding: 60px 0;
}

/* =========================================================================
 * Single post
 * ========================================================================= */
.blog-single {
    background: #fff;
}

/* Hero banner — full-width image with title overlay at bottom */
.blog-single__hero {
    position: relative;
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    height: 600px;
    overflow: hidden;
    background: #1a1a1a;
}

.blog-single__hero-img {
    width: 100%;
    height: 100%;
    max-width: none;
    position: absolute;
    top: 0;
    left: 0;
    object-fit: cover;
    display: block;
}

.blog-single__hero-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.7) 0%, rgba(0,0,0,0) 100%);
    padding: 80px 40px 40px;
}

.blog-single__hero-inner {
    max-width: 1400px;
    margin: 0 auto;
}

.blog-single__title {
    font-family: 'Times New Roman', 'oxygen-bold', Arial, sans-serif;
    font-size: 34px;
    font-weight: 700;
    color: #fff;
    margin: 0;
    line-height: 1.35;
    text-align: center;
    text-shadow: 0 2px 8px rgba(0,0,0,0.4);
}

/* Container */
.blog-single__container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 40px 40px 70px;
}

/* =========================================================================
 * Table of Contents
 * ========================================================================= */
.blog-toc {
    border: 1px solid #c8d8e8;
    border-radius: 4px;
    padding: 24px 28px;
    margin-bottom: 40px;
    background: #fff;
}

.blog-toc--collapsed .blog-toc__list {
    display: none;
}

.blog-toc__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.blog-toc__label {
    font-family: 'oxygen-bold', Arial, sans-serif;
    font-size: 16px;
    font-weight: 700;
    color: #1a3560;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.blog-toc__toggle {
    background: #1a3560;
    border: none;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    font-size: 0;
    line-height: 1;
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, transform 0.3s;
}

.blog-toc__toggle::before {
    content: '';
    display: block;
    width: 8px;
    height: 8px;
    border-right: 2px solid #fff;
    border-bottom: 2px solid #fff;
    transform: rotate(45deg);
    margin-top: -2px;
}

.blog-toc--collapsed .blog-toc__toggle::before {
    transform: rotate(-135deg);
    margin-top: 2px;
}

.blog-toc__toggle:hover {
    background: #0d1f3c;
}

.blog-toc__list {
    list-style: none;
    margin: 0;
    padding: 0;
    counter-reset: toc-h2;
}

.blog-toc__list > li {
    margin-bottom: 6px;
}

.blog-toc__list > li > a {
    font-family: 'oxygen-bold', Arial, sans-serif;
    font-size: 15px;
    font-weight: 700;
    color: #1a3560;
    text-decoration: none;
    line-height: 1.6;
    transition: color 0.2s;
}

.blog-toc__list > li > a:hover {
    color: #0d1f3c;
    text-decoration: underline;
}

.blog-toc__sub {
    list-style: none;
    margin: 4px 0 6px 20px;
    padding: 0;
}

.blog-toc__sub li {
    margin-bottom: 4px;
}

.blog-toc__sub a {
    font-family: 'oxygen-regular', Arial, sans-serif;
    font-size: 14px;
    font-weight: 400;
    color: #1a3560;
    text-decoration: none;
    line-height: 1.6;
}

.blog-toc__sub a:hover {
    color: #0d1f3c;
    text-decoration: underline;
}

/* =========================================================================
 * Post content
 * ========================================================================= */
.blog-single__content {
    font-family: 'Times New Roman', 'oxygen-regular', Arial, sans-serif;
    font-size: 16px;
    line-height: 1.8;
    color: #444;
}

.blog-single__content h2,
.blog-single__content h3 {
    font-family: 'Times New Roman', 'oxygen-bold', Arial, sans-serif;
    color: #222;
    margin: 36px 0 16px;
    scroll-margin-top: 80px;
}

.blog-single__content h2 {
    font-size: 24px;
}

.blog-single__content h3 {
    font-size: 20px;
}

.blog-single__content p {
    margin: 0 0 18px;
}

.blog-single__content img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    margin: 20px 0;
}

/* =========================================================================
 * Responsive
 * ========================================================================= */
@media (max-width: 960px) {
    .blog-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .blog-archive {
        padding: 35px 0 50px;
    }

    .blog-archive__container,
    .blog-single__container {
        padding: 0 20px;
    }

    .blog-archive__title {
        font-size: 26px;
    }

    .blog-card__thumb {
        height: 180px;
    }

    .blog-single__hero {
        height: 240px;
        margin: 0;
        border-radius: 0;
    }

    .blog-single__hero-overlay {
        padding: 40px 20px 20px;
    }

    .blog-single__title {
        font-size: 20px;
        line-height: 1.35;
    }

    .blog-single__container {
        padding: 28px 18px 50px;
    }

    .blog-single__content {
        font-size: 15px;
        line-height: 1.75;
    }

    .blog-single__content h2 {
        font-size: 20px;
        margin: 28px 0 12px;
    }

    .blog-single__content h3 {
        font-size: 17px;
        margin: 24px 0 10px;
    }

    .blog-single__content p {
        margin: 0 0 14px;
    }

    .blog-single__content img {
        margin: 14px 0;
    }

    .blog-toc {
        padding: 16px 14px;
        margin-bottom: 28px;
    }

    .blog-toc__label {
        font-size: 14px;
        letter-spacing: 0.5px;
    }

    .blog-toc__list > li > a {
        font-size: 14px;
    }

    .blog-toc__sub {
        margin-left: 14px;
    }

    .blog-toc__sub a {
        font-size: 13px;
    }
}

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

    .blog-card__thumb {
        height: 200px;
    }

    .blog-single__hero {
        height: 200px;
    }

    .blog-single__hero-overlay {
        padding: 32px 16px 16px;
    }

    .blog-single__title {
        font-size: 18px;
    }

    .blog-single__container {
        padding: 24px 16px 40px;
    }

    .blog-single__content {
        font-size: 14.5px;
    }

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

    .blog-single__content h3 {
        font-size: 16px;
    }
}

/* =========================================================================
 * Blog Single — Bottom Sections (Shared)
 * ========================================================================= */
.blog-section__container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
}

.blog-section__heading {
    font-family: 'Times New Roman', 'oxygen-bold', Arial, sans-serif;
    font-size: 22px;
    font-weight: 700;
    color: #1b569c;
    text-align: center;
    margin: 0;
}

.blog-section__heading--left {
    text-align: left;
}

.blog-section__divider-row {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 30px;
}

.blog-section__divider {
    flex: 1;
    height: 1px;
    background: #1b569c;
}

/* =========================================================================
 * Related Products
 * ========================================================================= */
.blog-related-products {
    padding: 50px 0 40px;
    background: #fff;
}

.blog-rp__grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 20px;
}

.blog-rp__item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: inherit;
    padding: 10px;
    transition: background 0.2s;
}

.blog-rp__item:hover {
    background: #f2f2f2;
}

.blog-rp__img-wrap {
    width: 100%;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 8px;
}

.blog-rp__img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.blog-rp__img--placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #eee 0%, #ddd 100%);
}

.blog-rp__name {
    font-family: 'Times New Roman', 'oxygen-bold', Arial, sans-serif;
    font-size: 14px;
    font-weight: 700;
    text-align: center;
    color: #333;
    margin: 5px 0 0;
    letter-spacing: 0.5px;
}

/* =========================================================================
 * About Section
 * ========================================================================= */
.blog-about-section {
    padding: 40px 0;
    background: #fff;
}

.blog-about-section .blog-section__heading {
    margin-bottom: 20px;
}

.blog-about__row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    align-items: start;
}

.blog-about__text {
    font-family: 'Times New Roman', 'oxygen-regular', Arial, sans-serif;
    font-size: 15px;
    line-height: 1.8;
    color: #555;
}

.blog-about__text p {
    margin: 0 0 16px;
}

.blog-about__img-wrap {
    border-radius: 4px;
    overflow: hidden;
}

.blog-about__img {
    width: 100%;
    height: auto;
    display: block;
}

/* =========================================================================
 * Why Choose Us Section
 * ========================================================================= */
.blog-why-section {
    padding: 40px 0 50px;
    background: #f7f7f7;
}

.blog-why-section .blog-section__heading {
    margin-bottom: 30px;
    font-size: 20px;
    font-style: italic;
}

.blog-why__grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.blog-why__card {
    background: #fff;
    border-radius: 4px;
    padding: 30px 20px;
    text-align: center;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
}

.blog-why__icon {
    color: #1b569c;
    margin-bottom: 14px;
}

.blog-why__icon svg {
    width: 40px;
    height: 40px;
}

.blog-why__title {
    font-family: 'Times New Roman', 'oxygen-bold', Arial, sans-serif;
    font-size: 15px;
    font-weight: 700;
    color: #222;
    margin: 0 0 10px;
    text-transform: uppercase;
}

.blog-why__desc {
    font-family: 'Times New Roman', 'oxygen-regular', Arial, sans-serif;
    font-size: 13px;
    line-height: 1.7;
    color: #666;
    margin: 0;
}

.blog-about__caption {
    display: block;
    text-align: center;
    font-size: 13px;
    color: #888;
    margin-top: 8px;
    font-style: italic;
}

.blog-about__text a {
    color: #1b569c;
    text-decoration: underline;
}

.blog-about__text a:hover {
    color: #0d3a6e;
}

/* =========================================================================
 * R & D Team Section
 * ========================================================================= */
.blog-team-section {
    padding: 40px 0 60px;
    background: #fff;
}

.blog-team-section .blog-section__heading {
    margin-bottom: 24px;
}

.blog-team__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.blog-team__item {
    margin: 0;
    overflow: hidden;
    border-radius: 4px;
}

.blog-team__img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
}

.blog-team__caption {
    display: block;
    text-align: center;
    font-size: 14px;
    color: #444;
    padding: 10px 0;
    background: #f9f9f9;
    font-weight: 600;
}

/* =========================================================================
 * Product Testing Section
 * ========================================================================= */
.blog-testing-section {
    padding: 40px 0;
    background: #fff;
}

.blog-testing-section .blog-section__heading {
    margin-bottom: 24px;
}

.blog-testing__intro {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    align-items: start;
    margin-bottom: 24px;
}

.blog-testing__banner {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 4px;
}

.blog-testing__intro-text {
    font-family: 'Times New Roman', 'oxygen-regular', Arial, sans-serif;
    font-size: 15px;
    line-height: 1.8;
    color: #555;
}

.blog-testing__intro-text p {
    margin: 0;
}

.blog-testing__row {
    display: grid;
    gap: 5px;
    margin-bottom: 5px;
}

.blog-testing__row--2 {
    grid-template-columns: repeat(2, 1fr);
}

.blog-testing__row--3 {
    grid-template-columns: repeat(3, 1fr);
}

.blog-testing__item {
    margin: 0;
    overflow: hidden;
    border-radius: 0;
}

.blog-testing__item img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
}

/* =========================================================================
 * Production Process Section
 * ========================================================================= */
.blog-production-section {
    padding: 40px 0 60px;
    background: #fff;
}

.blog-production-section .blog-section__heading {
    margin-bottom: 24px;
}

.blog-production__gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 5px;
}

.blog-production__item {
    margin: 0;
    overflow: hidden;
    border-radius: 0;
}

.blog-production__item img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}

/* =========================================================================
 * Bottom Sections — Responsive
 * ========================================================================= */
@media (max-width: 960px) {
    .blog-rp__grid {
        grid-template-columns: repeat(3, 1fr);
    }

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

    .blog-why__grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .blog-testing__intro {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .blog-team__img,
    .blog-testing__item img {
        height: 200px;
    }

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

@media (max-width: 768px) {
    .blog-section__container {
        padding: 0 18px;
    }

    .blog-section__heading {
        font-size: 18px;
    }

    .blog-section__divider-row {
        gap: 12px;
        margin-bottom: 22px;
    }

    .blog-related-products,
    .blog-about-section,
    .blog-team-section,
    .blog-testing-section,
    .blog-production-section {
        padding: 32px 0;
    }

    .blog-why-section {
        padding: 32px 0 36px;
    }

    .blog-rp__grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }

    .blog-rp__item {
        padding: 6px;
    }

    .blog-rp__name {
        font-size: 13px;
    }

    .blog-team__grid,
    .blog-production__gallery {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }

    .blog-testing__row--3 {
        grid-template-columns: repeat(2, 1fr);
    }

    .blog-team__img,
    .blog-testing__item img,
    .blog-production__item img {
        height: 160px;
    }

    .blog-about__text {
        font-size: 14px;
        line-height: 1.75;
    }

    .blog-why__card {
        padding: 22px 14px;
    }

    .blog-why__icon svg {
        width: 32px;
        height: 32px;
    }

    .blog-why__title {
        font-size: 14px;
    }

    .blog-why__desc {
        font-size: 12.5px;
        line-height: 1.65;
    }

    .blog-team__caption,
    .blog-about__caption {
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .blog-section__container {
        padding: 0 14px;
    }

    .blog-rp__grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .blog-why__grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .blog-team__grid,
    .blog-production__gallery {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .blog-testing__row--2,
    .blog-testing__row--3 {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .blog-team__img,
    .blog-testing__item img,
    .blog-production__item img {
        height: 200px;
    }

    .blog-section__heading {
        font-size: 16px;
    }

    .blog-rp__name {
        font-size: 12px;
    }
}
