/* --- Global Section Styles --- */
.section-title {
    position: relative;
    padding-bottom: 12px;
    margin-bottom: 24px;
    font-weight: 700;
    font-size: 1.7rem;
}

.section-title:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 70px;
    height: 3px;
    background-color: var(--primary-color);
}

.industrial-pattern {
    background-color: var(--bg-light-gray);
    background-image:
        linear-gradient(rgba(0,0,0,0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0,0,0,0.03) 1px, transparent 1px);
    background-size: 20px 20px;
}

.product-content {
    padding: var(--padding-lg) 0;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--gap-default);
    margin-bottom: var(--padding-lg);
}

@media (max-width: 992px) {
    .product-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .product-grid {
        grid-template-columns: 1fr;
    }
}

.product-card {
    background: var(--white-color);
    border-radius: 3px;
    overflow: hidden;
    box-shadow: 0 5px 15px var(--shadow-default);
    transition: all 0.3s ease;
    position: relative;
    height: 100%;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px var(--shadow-hover);
}

.product-image-container {
    position: relative;
    overflow: hidden;
    height: 100%;
}

.product-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.product-card:hover .product-image {
    transform: scale(1.05);
}

.product-info-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    padding: var(--padding-sm);
    color: var(--white-color);
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
}

.product-card:hover .product-info-overlay {
    opacity: 1;
    transform: translateY(0);
}

.product-title {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.product-description {
    font-size: 0.85rem;
    margin-bottom: 0;
    line-height: 1.4;
}

.product-category {
    position: absolute;
    top: 15px;
    background: var(--bg-color-category-badge);
    color: var(--white-color);
    padding: 5px 10px;
    font-size: 0.65rem;
    font-weight: 500;
}

.product-actions {
    padding: var(--padding-sm);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.product-price {
    font-weight: 700;
    color: var(--primary-color);
    font-size: 1.1rem;
}

.product-btn {
    background: var(--bg-color-button);
    color: var(--white-color);
    border: none;
    padding: 8px 15px;
    border-radius: 3px;
    font-size: 0.8rem;
    transition: all 0.3s ease;
}

.product-btn:hover {
    background: var(--bg-color-button-hover);
}

/* --- Pagination Styles --- */
.pagination-container {
    display: flex;
    justify-content: center;
    margin-top: var(--padding-lg);
}

.pagination {
    display: flex;
    list-style: none;
    padding: 0;
    margin: 0;
    gap: 2px;
}

.page-item {
    display: flex;
    align-items: center;
    justify-content: center;
}

.page-link {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 8px;
    border: 1px solid var(--border-color-default);
    border-radius: 3px;
    color: #4a5568; /* Hardcoded, consider adding a variable if it appears elsewhere */
    font-weight: 500;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    background-color: var(--bg-color-pagination);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.page-link:hover {
    background-color: var(--bg-color-pagination-hover);
    border-color: var(--border-color-hover);
    color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px var(--shadow-light);
}

.page-item.active .page-link {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: var(--white-color);
    box-shadow: 0 4px 8px var(--shadow-pagination-active);
}

.page-item.disabled .page-link {
    color: #a0aec0; /* Hardcoded, consider adding a variable */
    pointer-events: none;
    background-color: var(--bg-color-pagination-disabled);
    border-color: var(--border-color-default);
}

.page-item:first-child .page-link,
.page-item:last-child .page-link {
    min-width: auto;
    padding: 0 12px;
}

.page-link i {
    font-size: 0.8rem;
}

.page-item.ellipsis .page-link {
    border: none;
    background: transparent;
    box-shadow: none;
    pointer-events: none;
    min-width: auto;
}

.page-item.ellipsis .page-link:hover {
    transform: none;
    background: transparent;
    color: #4a5568;
}

/* --- Newsletter Form --- */
.newsletter-form {
    position: relative;
}

.newsletter-form input {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid var(--light-gray);
    border-radius: 3px;
    font-size: 0.9rem;
}

.newsletter-form button {
    position: absolute;
    right: 5px;
    top: 5px;
    background: var(--primary-color);
    color: var(--white-color);
    border: none;
    border-radius: 3px;
    padding: 7px 15px;
    transition: all 0.3s ease;
}

.newsletter-form button:hover {
    background: var(--dark-color);
}

/* --- Latest Products Widget --- */
.latest-products-container {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--gap-sm);
    margin-top: var(--padding-sm);
}

.product-item {
    position: relative;
    border-radius: 3px;
    overflow: hidden;
    height: 100px;
    box-shadow: 0 3px 8px var(--shadow-light);
    transition: all 0.3s ease;
}

.product-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px var(--shadow-medium);
}

.product-image-sidebar {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    padding: 10px;
    opacity: 0;
    transition: opacity 0.3s ease;
    display: flex;
    align-items: flex-end;
    height: 100%;
}

.product-item:hover .product-overlay {
    opacity: 1;
}

.product-title-sidebar {
    color: var(--white-color);
    font-size: 0.75rem;
    font-weight: 500;
    margin: 0;
    text-align: center;
    width: 100%;
}

/* --- Blog Content --- */
.blog-content {
    padding: var(--padding-lg) 0;
}

.blog-post {
    margin-bottom: 25px;
    border-radius: 3px;
    overflow: hidden;
    box-shadow: 0 5px 15px var(--shadow-default);
    transition: all 0.3s ease;
    background: var(--white-color);
    display: flex;
    flex-direction: row;
}

.blog-post:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px var(--shadow-hover);
}

.post-thumb-container {
    position: relative;
    flex: 0 0 40%;
    max-width: 40%;
}

.post-thumb {
    height: 100%;
    overflow: hidden;
    position: relative;
}

.post-thumb img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.blog-post:hover .post-thumb img {
    transform: scale(1.05);
}

.post-date-badge {
    position: absolute;
    top: 15px;
    background: var(--bg-color-category-badge);
    color: var(--white-color);
    width: 70px;
    height: 60px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    box-shadow: 0 3px 10px var(--shadow-medium);
    z-index: 2;
}

.post-date-badge .day {
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1;
}

.post-date-badge .month {
    font-size: 0.8rem;
    text-transform: uppercase;
    margin-top: 3px;
}

.post-content {
    padding: var(--padding-md);
    flex: 0 0 60%;
    max-width: 60%;
}

.post-meta {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
    font-size: 0.8rem;
    color: var(--text-color-muted);
}

.post-meta span {
    margin-right: var(--padding-sm);
}

.post-meta i {
    margin-right: 5px;
    color: var(--primary-color);
}

.post-title {
    font-size: 1.2rem;
    margin-bottom: 12px;
    font-weight: 600;
}

.post-title a {
    color: var(--dark-color);
    transition: all 0.3s ease;
}

.post-title a:hover {
    color: var(--primary-color);
}

.post-excerpt {
    color: var(--text-color-secondary);
    margin-bottom: var(--padding-sm);
    font-size: 0.9rem;
    line-height: 1.6;
}

@media (max-width: 991.98px) {
    .blog-post {
        flex-direction: column;
    }

    .post-thumb-container {
        flex: 0 0 100%;
        max-width: 100%;
        height: 220px;
    }

    .post-content {
        flex: 0 0 100%;
        max-width: 100%;
    }
}

      
/* Detail Page Styles */
.article-header {
    margin-bottom: 30px;
}

.article-title {
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 15px;
    color: var(--dark-color);
}

.article-meta {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
    font-size: 0.9rem;
    color: #666;
}

.article-meta span {
    margin-right: 20px;
    display: flex;
    align-items: center;
}

.article-meta i {
    margin-right: 8px;
    color: var(--primary-color);
}

.article-featured-image {
    margin-bottom: 30px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.article-featured-image img {
    width: 100%;
    height: auto;
    display: block;
}

.article-content {
    font-size: 1rem;
    line-height: 1.8;
    color: #444;
}

.article-content h2 {
    font-size: 1.8rem;
    margin-top: 40px;
    margin-bottom: 20px;
    color: var(--dark-color);
    font-weight: 600;
}

.article-content h3 {
    font-size: 1.5rem;
    margin-top: 30px;
    margin-bottom: 15px;
    color: var(--dark-color);
    font-weight: 600;
}

.article-content p {
    margin-bottom: 20px;
    text-align: justify;
}

.article-content blockquote {
    border-left: 4px solid var(--primary-color);
    padding-left: 20px;
    margin: 30px 0;
    font-style: italic;
    color: #555;
    background: #f9f9f9;
    padding: 20px;
    border-radius: 0 5px 5px 0;
}

.article-content ul, .article-content ol {
    margin-bottom: 20px;
    padding-left: 20px;
}

.article-content li {
    margin-bottom: 10px;
}

.article-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 20px 0;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
}

.article-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 40px 0 20px;
}

.article-tags a {
    background: #f0f2f5;
    color: #555;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.article-tags a:hover {
    background: var(--primary-color);
    color: white;
}

.article-share {
    display: flex;
    align-items: center;
    margin: 30px 0;
    padding: 20px 0;
    border-top: 1px solid #eee;
    border-bottom: 1px solid #eee;
}

.article-share span {
    font-weight: 600;
    margin-right: 15px;
    color: var(--dark-color);
}

.share-buttons {
    display: flex;
    gap: 10px;
}

.share-button {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    transition: all 0.3s ease;
}

.share-button.facebook {
    background: #3b5998;
}

.share-button.twitter {
    background: #1da1f2;
}

.share-button.linkedin {
    background: #0077b5;
}

.share-button.whatsapp {
    background: #25d366;
}

.share-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2);
}

.related-articles {
    margin: 60px 0 30px;
}

.related-title {
    font-size: 1.5rem;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 2px solid #eee;
    position: relative;
}

.related-title::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 70px;
    height: 2px;
    background-color: var(--primary-color);
}

@media (max-width: 767.98px) {
    .article-title {
        font-size: 1.8rem;
    }
    
    .article-meta {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .article-meta span {
        margin-bottom: 10px;
    }
    
    .article-share {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .article-share span {
        margin-bottom: 15px;
    }
}