/* ========================================
   ONLINE STORE STYLES
   ======================================== */

.hero {
    position: relative;
    height: 400px;
    display: flex;
    align-items: center;
    overflow: hidden;
    width: 100%;
}

.hero picture {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

.hero picture source,
.hero picture img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.hero h1 {
    font-size: 60px;
    font-weight: 700;
    margin-bottom: 20px;
    max-width: 660px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

.hero-intro {
    max-width: 660px;
}

.hero-intro p {
    font-size: 1.3rem;
    font-weight: 400;
    line-height: 1.6;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.5);
}

.hero-container {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 1440px;
    margin: 0 auto;
}

.product-container {
    width: 100%;
    max-width: 1440px;
    margin: 0 auto;
    padding: 60px 0;
    box-sizing: border-box;
}

.product-list-group {
    margin-bottom: 30px;
}

.product-list-heading {
    display: none;
}

.product-menu {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
}

.product-menu-btn {
    background-color: #f5f5f5;
    border: 2px solid #ddd;
    color: #333;
    padding: 10px 20px;
    border-radius: 3px;
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: pointer;
    text-transform: none;
}

.product-menu-btn.is-checked {
    background-color: #003D7C;
    border-color: #003D7C;
    color: #fff;
}

.product-menu-btn:hover {
    background-color: #004185;
    border-color: #004185;
    color: #fff;
}

.filters-select {
    width: 100%;
    padding: 12px 40px 12px 15px;
    border: 2px solid #003D7C;
    border-radius: 4px;
    background-color: #fff;
    font-size: 1rem;
    color: #333;
    appearance: none;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24'%3E%3Cpath fill='%23004185' d='M7.41 8.59L12 13.17l4.59-4.58L18 10l-6 6-6-6 1.41-1.41z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 15px center;
    background-size: 30px;
    margin-top: 0;
}

.mobile-filter-dropdown {
    display: none;
    margin-bottom: 20px;
}

.grid {
    max-width: 1440px;
    margin: 0 auto !important;
    position: relative;
}

.grid::after {
    content: '';
    display: block;
    clear: both;
}

.online-store-product-item {
    width: calc(25% - 20px);
    margin: 10px;
    padding: 20px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    transition: box-shadow 0.3s ease, opacity 0.3s ease, top 0.4s ease, left 0.4s ease;
    display: flex;
    flex-direction: column;
    min-height: 450px;
}

.online-store-product-item:hover {
    box-shadow: 0 5px 20px rgba(0,0,0,0.12);
}

.product-img {
    position: relative;
    margin-bottom: 15px;
    text-align: center;
    overflow: hidden;
    border-radius: 4px;
}

.product-img img {
    max-width: 100%;
    height: auto;
    transition: transform 0.3s ease;
}

.online-store-product-item:hover .product-img img {
    transform: scale(1.05);
}

/* Out of stock state */
.online-store-product-item.out-of-stock .product-img img {
    filter: grayscale(0.6);
    opacity: 0.7;
}

.online-store-product-item.out-of-stock {
    opacity: 0.95;
}

.out-of-stock-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #c0392b;
    color: #fff;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    padding: 4px 9px;
    border-radius: 4px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.18);
    z-index: 2;
}

.online-store-product-item .title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #003D7C;
    margin-bottom: 8px;
    line-height: 1.3;
}

.online-store-product-item .price {
    font-size: 1.5rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 10px;
}

.online-store-product-item .price sup {
    font-size: 0.8rem;
    vertical-align: super;
    top: 0 !important;
    position: relative;
}

.online-store-product-item .desc {
    font-size: 0.9rem;
    color: #666;
    line-height: 1.5;
    margin-bottom: 15px;
    flex-grow: 1;
}

.online-store-product-item a {
    text-decoration: none;
    color: inherit;
}

/* Shopify button container - pushes to bottom */
.shopify-button-container {
    margin-top: auto;
}

/* ========================================
   ISOTOPE FILTER ANIMATIONS
   ======================================== */

/* Hide filtered-out items immediately - no jumping/sliding */
.isotope-hidden {
    display: none !important;
    opacity: 0;
}

/* Fade-in animation for products */
.online-store-product-item.fade-in {
    animation: fadeInProduct 0.4s ease forwards;
}

@keyframes fadeInProduct {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========================================
   MEDIA QUERIES
   ======================================== */

/* Tablet - 768px to 1024px */
@media (min-width: 768px) and (max-width: 1024px) {
    .hero-container {
        padding-inline: 3rem;
    }
    .product-container {
        padding-inline: 3rem;
    }
    .online-store-product-item {
        width: calc(33.333% - 20px);
        max-width: 275px;
        min-height: 500px;
    }
}

/* Mobile - max 767px */
@media (max-width: 767px) {
    .hero h1 {
        font-size: 38px;
        line-height: 45px;
    }
    .hero-container {
        padding-inline: 1.6rem;
    }
    .product-list-heading {
        display: block;
        background: #003D7C;
        border-radius: 4px;
        margin-bottom: 10px;
    }
    .product-list-heading a {
        display: block;
        padding: 15px 20px;
        color: #fff;
        text-decoration: none;
        font-weight: 600;
    }
    .product-list-heading .fa {
        float: right;
        transition: transform 0.3s;
    }
    .product-list-heading a[aria-expanded="true"] .fa {
        transform: rotate(180deg);
    }
    .mobile-filter-dropdown {
        display: block;
    }
    .product-list-group {
        display: none;
    }
    .product-menu {
        display: none;
    }
    .product-container {
        padding-inline: 1.6rem;
    }
    .online-store-product-item {
        width: calc(100% - 20px);
        max-width: max-content;
    }
}

/* Small Mobile - max 575px */
@media (max-width: 575px) {
    .online-store-product-item {
        width: calc(100% - 20px);
    }
}
