/**
 * Empire Five Athletics - Category Pages Styles
 *
 * @package Empire_Five_Child
 * @since 1.0.0
 */

/* ========== Category Page Layout ========== */

/* Full width reset for category pages */
body.empire-category-page .site-content,
body.empire-category-page #primary,
body.empire-category-page .content-area,
body.empire-category-page .site-main {
    width: 100%;
    max-width: 100%;
    margin: 0;
    padding: 0;
}

.category-page {
    overflow-x: hidden;
    width: 100%;
}

/* Force container centering for category pages */
.category-page .empire-container,
body.empire-category-page .empire-container {
    width: 100%;
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 40px;
    padding-right: 40px;
}

/* Override GeneratePress default content container */
body.empire-category-page .inside-article,
body.empire-category-page .entry-content,
body.empire-category-page .container,
body.empire-category-page .grid-container {
    max-width: 100%;
    width: 100%;
    margin: 0;
    padding: 0;
}

/* ========== Page Hero ========== */
.page-hero {
    position: relative;
    min-height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--empire-primary);
    padding: 120px 0 60px;
    width: 100%;
}

.page-hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--empire-primary) 0%, var(--empire-secondary) 100%);
}

.page-hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 40, 104, 0.3);
}

.page-hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
}

.page-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 800;
    color: var(--empire-white);
    margin-bottom: 16px;
}

.page-subtitle {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.9);
    max-width: 600px;
    margin: 0 auto;
}

/* ========== Page Section - Intro Content ========== */
.page-section {
    padding: 80px 0 40px;
    background: var(--empire-white);
}

.page-section .empire-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
}

/* Beautiful Section Heading */
.intro-content {
    max-width: 900px;
    margin: 0 auto;
    text-align: center;
}

.intro-content .section-heading {
    font-size: clamp(1.75rem, 3vw, 2.25rem);
    font-weight: 800;
    color: var(--empire-primary);
    margin: 0 0 24px;
    text-transform: uppercase;
    letter-spacing: 2px;
    position: relative;
    display: inline-block;
    padding-bottom: 20px;
}

/* Elegant underline accent */
.intro-content .section-heading::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, var(--empire-accent), var(--empire-primary));
    border-radius: 2px;
}

.intro-content .section-text {
    font-size: 1.1rem;
    color: var(--empire-text);
    line-height: 1.9;
    margin-bottom: 16px;
}

.intro-content .section-text strong {
    color: var(--empire-accent);
    font-weight: 700;
}

.intro-content .section-meta {
    font-size: 1rem;
    color: var(--empire-text-light);
    line-height: 1.8;
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid var(--empire-gray-light);
}

/* ========== Category Products Section ========== */
.category-products {
    padding: 40px 0 80px;
    background: var(--empire-white);
    width: 100%;
}

.category-products .empire-container {
    text-align: center;
}

.products-grid-full {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    text-align: left;
    gap: 30px;
}

/* Reuse product card styles from home.css */
.category-page .product-card {
    display: block;
    text-decoration: none;
    background: var(--empire-white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.category-page .product-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
}

.category-page .product-image {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: var(--empire-gray-light);
}

.category-page .product-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.category-page .product-card:hover .product-img {
    transform: scale(1.1);
}

.category-page .product-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--empire-primary) 0%, var(--empire-secondary) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.category-page .product-placeholder::after {
    content: attr(data-label);
    color: rgba(255, 255, 255, 0.3);
    font-size: 1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.category-page .product-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 40, 104, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.category-page .product-card:hover .product-overlay {
    opacity: 1;
}

.category-page .view-more {
    color: var(--empire-white);
    font-weight: 600;
    padding: 12px 24px;
    border: 2px solid var(--empire-white);
    border-radius: var(--radius-full);
    transform: translateY(20px);
    transition: all 0.4s ease;
}

.category-page .product-card:hover .view-more {
    transform: translateY(0);
}

.category-page .product-name {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--empire-primary);
    padding: 20px 20px 8px;
}

.category-page .product-desc {
    font-size: 0.9rem;
    color: var(--empire-text-light);
    padding: 0 20px 20px;
}

/* ========== Category CTA ========== */
.category-cta {
    padding: 80px 0;
    background: var(--empire-gray-light);
}

.cta-box {
    text-align: center;
    padding: 60px 40px;
    background: var(--empire-primary);
    border-radius: var(--radius-xl);
    color: var(--empire-white);
}

.cta-box h2 {
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 800;
    margin-bottom: 16px;
    color: var(--empire-white);
}

.cta-box p {
    font-size: 1.1rem;
    opacity: 0.9;
    margin-bottom: 30px;
}

.cta-box .btn-primary {
    background: var(--empire-accent);
    color: var(--empire-white);
}

.cta-box .btn-primary:hover {
    background: var(--empire-accent-hover);
}

/* ========== Responsive ========== */
@media (max-width: 1200px) {
    .products-grid-full {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 992px) {
    .products-grid-full {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
}

@media (max-width: 768px) {
    .page-hero {
        min-height: 250px;
        padding: 100px 0 50px;
    }

    .page-section {
        padding: 50px 0 30px;
    }

    .page-section .empire-container {
        padding: 0 20px;
    }

    .intro-content .section-heading {
        font-size: 1.5rem;
        letter-spacing: 1px;
        padding-bottom: 16px;
    }

    .intro-content .section-heading::after {
        width: 60px;
        height: 3px;
    }

    .intro-content .section-text {
        font-size: 1rem;
        line-height: 1.8;
    }

    .intro-content .section-meta {
        font-size: 0.95rem;
    }

    .category-products {
        padding: 30px 0 50px;
    }

    .products-grid-full {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .category-cta {
        padding: 50px 0;
    }

    .cta-box {
        padding: 40px 24px;
    }
}

@media (max-width: 480px) {
    .intro-content .section-heading {
        font-size: 1.25rem;
        letter-spacing: 1px;
    }

    .intro-content .section-text {
        font-size: 0.95rem;
    }
}
