﻿/*!
Theme Name: Woof Meow Shop Child
Theme URI: https://woofmeow.ca/
Description: Child theme for the Woof Meow Shop theme to implement curated storefront functionality.
Version: 1.1.1
Author: Woof Meow
Author URI: https://woofmeow.ca/
Template: woofmeow-shop
*/

/* Import parent theme styles */
@import url("../woofmeow-shop/style.css");
@import url("../woofmeow-shop/woocommerce.css");

/* Add custom styles for curated storefront */
.curated-shop-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Shop by Category section */
.shop-by-category {
    margin: 40px 0;
}

.shop-by-category h2 {
    text-align: center;
    margin-bottom: 30px;
    font-size: 28px;
    color: #ffffff;
}

.category-cards {
    display: grid;
    gap: 14px;
    margin-bottom: 40px;
    max-width: 1280px;
    margin: 0 auto;
}

/* Homepage-matched Card Styling & #4ADE80 Green Hover Glow */
.category-box {
    background-color: #1E1E22;
    border: 1px solid #2E2E34;
    border-top: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
    cursor: pointer;
}

.category-box:hover {
    transform: translateY(-6px);
    border-color: #4ADE80;
    box-shadow: 0 12px 32px rgba(74, 222, 128, 0.25);
}

.category-box a {
    display: flex;
    flex-direction: column;
    height: 100%;
    text-decoration: none;
    color: inherit;
}

.category-image-wrapper {
    width: 100%;
    aspect-ratio: 1 / 1;
    background-color: #111111;
    overflow: hidden;
    position: relative;
    height: auto;
}

.category-box .category-image-wrapper img,
.category-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    margin: 0;
    padding: 0;
    transition: transform 0.3s ease;
}

.category-box:hover .category-image {
    transform: scale(1.04);
}

.category-image-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #18181B;
    color: #A1A1AA;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.category-title-banner {
    background-color: #1E1E22;
    border-top: 1px solid #2E2E34;
    padding: 16px 12px;
    text-align: center;
    margin-top: auto;
}

.category-box h3,
.category-title-banner h3 {
    color: #ffffff !important;
    font-size: 16px;
    font-weight: 800;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    margin: 0;
}

/* Best Sellers section */
.best-sellers, .on-sale {
    margin: 40px 0;
}

.best-sellers h2, .on-sale h2 {
    text-align: center;
    margin-bottom: 30px;
    font-size: 28px;
    color: #ffffff;
}

/* Shop by Brands section */
.shop-by-brands {
    margin: 40px 0;
}

.shop-by-brands h2 {
    text-align: center;
    margin-bottom: 30px;
    font-size: 28px;
    color: #ffffff;
}

.brand-pills {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
    margin-bottom: 40px;
}

.brand-pill {
    background-color: #1E1E22;
    border: 1px solid #2E2E34;
    border-radius: 9999px;
    padding: 10px 20px;
    color: #E4E4E7;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.25s ease;
}

.brand-pill:hover {
    background-color: #25252B;
    border-color: #4ADE80;
    color: #4ADE80;
    box-shadow: 0 0 12px rgba(74, 222, 128, 0.25);
    transform: translateY(-2px);
}

/* Full Catalog section */
.full-catalog {
    margin: 40px 0;
}

.full-catalog h2 {
    text-align: center;
    margin-bottom: 30px;
    font-size: 28px;
    color: #ffffff;
}

/* Responsive adjustments */
/* Desktop/laptop viewports (min-width: 900px) */
@media (min-width: 900px) {
    .category-cards {
        grid-template-columns: repeat(6, minmax(0, 1fr));
    }
    
    .category-cards.subcategory-cards {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        max-width: 1200px;
        gap: 18px;
    }
}

/* Responsive adjustments for smaller screens */
@media (max-width: 1024px) {
    .category-cards {
        grid-template-columns: repeat(3, 1fr);
        gap: 16px;
    }
    
    .category-cards.subcategory-cards {
        grid-template-columns: repeat(3, 1fr);
        gap: 18px;
    }
}

@media (max-width: 768px) {
    .category-cards {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .brand-pills {
        gap: 10px;
    }
    
    .brand-pill {
        padding: 8px 16px;
        font-size: 14px;
    }
    
    .shop-by-category h2,
    .best-sellers h2,
    .on-sale h2,
    .shop-by-brands h2,
    .full-catalog h2 {
        font-size: 24px;
    }
}

@media (max-width: 480px) {
    .category-cards {
        grid-template-columns: 1fr;
    }
    
    .curated-shop-container {
        padding: 0 15px;
    }
}

/* Custom styles for WooCommerce placeholders */
.woocommerce-placeholder {
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 8px;
}
.category-cards.subcategory-cards { 
    grid-template-columns: repeat(4, 1fr); 
}

@media (max-width: 1024px) { 
    .category-cards.subcategory-cards { 
        grid-template-columns: repeat(3, 1fr); 
    } 
}

@media (max-width: 768px) { 
    .category-cards.subcategory-cards { 
        grid-template-columns: repeat(2, 1fr); 
    } 
}

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

/* Responsive 6-card grid & gapless image fill (v1.0.6) */
.category-cards {
    display: grid !important;
    grid-template-columns: repeat(6, 1fr) !important;
    gap: 18px !important;
}

@media (max-width: 1280px) {
    .category-cards {
        grid-template-columns: repeat(3, 1fr) !important;
    }
}

@media (max-width: 768px) {
    .category-cards {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

@media (max-width: 480px) {
    .category-cards {
        grid-template-columns: 1fr !important;
    }
}

.category-box {
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
}

.category-box > a {
    display: flex !important;
    flex-direction: column !important;
    height: 100% !important;
    text-decoration: none !important;
}

.category-image-wrapper {
    width: 100% !important;
    height: 210px !important;
    flex: 1 0 auto !important;
    overflow: hidden !important;
    background-color: #1E1E22 !important;
    margin: 0 !important;
    padding: 0 !important;
}

.category-box .category-image-wrapper img,
.category-image {
    width: 100% !important;
    height: 100% !important;
    max-width: none !important;
    max-height: none !important;
    object-fit: cover !important;
    object-position: center !important;
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
}

.category-title-banner {
    flex-shrink: 0 !important;
    margin-top: 0 !important;
}
/* Mobile compact 2-column grid & sleek tile proportions (v1.0.8) */
@media (max-width: 768px) {
    .curated-shop-container {
        padding-left: 12px !important;
        padding-right: 12px !important;
    }

    .shop-by-category h2,
    .full-catalog h2 {
        font-size: 1.35rem !important;
        margin-bottom: 14px !important;
    }

    .category-cards,
    .category-cards.subcategory-cards {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 12px !important;
    }

    .category-box {
        border-radius: 10px !important;
    }

    .category-image-wrapper {
        height: 125px !important;
    }

    .category-title-banner {
        padding: 10px 8px !important;
    }

    .category-title-banner h3 {
        font-size: 0.85rem !important;
        letter-spacing: 0.04em !important;
        line-height: 1.2 !important;
    }

    /* Trim mobile header spacing so content sits higher above the fold */
    .site-header .custom-logo,
    header img {
        max-height: 36px !important;
        width: auto !important;
    }
}

/* Compact single-row header & above-the-fold spacing on category pages (v1.1.0) */
.tax-product_cat .woocommerce-breadcrumb,
.tax-product_cat .woocommerce-products-header {
    display: none !important;
}

.tax-product_cat .site-main,
.tax-product_cat #primary,
.tax-product_cat .content-area {
    padding-top: 12px !important;
    margin-top: 0 !important;
}

.curated-subcategory-view .shop-by-category {
    margin-top: 12px !important;
    margin-bottom: 24px !important;
}

.curated-section-header {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.curated-subarchive-header {
    max-width: 1280px;
    margin: 12px auto 18px;
    padding: 0 20px;
}

.curated-section-header .curated-back-link {
    justify-self: start;
}

.curated-section-header h2,
.curated-section-header .curated-inline-title {
    margin: 0 !important;
    text-align: center;
    font-size: 26px;
    font-weight: 800;
    color: #ffffff;
    line-height: 1.2;
}

.curated-back-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 14px;
    background-color: #1E1E22;
    border: 1px solid #2E2E34;
    border-radius: 8px;
    color: #E4E4E7;
    font-size: 13.5px;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.curated-back-link:hover {
    border-color: #4ADE80;
    color: #4ADE80;
    background-color: #25252B;
}

@media (max-width: 768px) {
    .curated-section-header {
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        justify-content: space-between;
        gap: 8px;
        margin-bottom: 14px;
    }

    .curated-subarchive-header {
        padding: 0 12px;
        margin: 10px auto 14px;
    }

    .curated-header-spacer {
        display: none;
    }

    .curated-section-header h2,
    .curated-section-header .curated-inline-title {
        font-size: 1.25rem !important;
        text-align: right;
    }

    .curated-back-link {
        padding: 6px 10px;
        font-size: 12.5px;
    }
}

/* Tighten main /shop/ page top spacing & header padding so all 6 cards sit cleanly above the fold (v1.1.1) */
.post-type-archive-product .woocommerce-breadcrumb,
.post-type-archive-product .woocommerce-products-header {
    display: none !important;
}

.post-type-archive-product .site-main,
.post-type-archive-product #primary,
.post-type-archive-product .content-area {
    padding-top: 8px !important;
    margin-top: 0 !important;
}

.curated-shop-container .shop-by-category {
    margin-top: 8px !important;
    margin-bottom: 24px !important;
}

.curated-shop-container .shop-by-category > h2 {
    margin-top: 0 !important;
    margin-bottom: 18px !important;
}

/* Slim down site header vertical padding slightly on desktop */
.site-header,
header.site-header,
.main-header-bar {
    padding-top: 10px !important;
    padding-bottom: 10px !important;
    min-height: 0 !important;
}
