/* Product Grid */
.product-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(220px, 1fr));
    gap: 18px;
    padding: 0 24px;
    margin-bottom: 32px;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

.product-card {
    background-color: var(--white);
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    transition: var(--transition);
    cursor: pointer;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.product-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
    border-color: var(--primary-beige);
}

.product-image-wrapper {
    position: relative;
    width: 100%;
    padding-top: 100%;
    background-color: #f5f5f5;
    overflow: hidden;
}

.product-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.product-card:hover .product-image {
    transform: scale(1.05);
}

.wishlist-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: var(--white);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
    z-index: 5;
}

.wishlist-btn:hover {
    background-color: var(--primary-beige);
    transform: scale(1.1);
}

.wishlist-btn svg {
    width: 20px;
    height: 20px;
    stroke: var(--primary-navy);
    fill: none;
    transition: var(--transition);
}

.wishlist-btn.active svg {
    fill: #E74C3C;
    stroke: #E74C3C;
}

.product-info {
    padding: 12px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.product-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 6px;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.product-price {
    font-size: 14px;
    font-weight: 700;
    color: var(--secondary-navy);
    margin-bottom: 8px;
}

.product-tags {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
    margin-top: auto;
}

.product-tag {
    display: inline-block;
    padding: 3px 8px;
    background-color: #f0f0f0;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    font-size: 10px;
    color: var(--text-light);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Product List View (for category page) */
.product-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 0 16px;
}

.product-list-item {
    display: flex;
    gap: 12px;
    background-color: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    transition: var(--transition);
}

.product-list-item:hover {
    box-shadow: var(--shadow);
    border-color: var(--primary-beige);
}

.product-list-image {
    width: 100px;
    height: 100px;
    object-fit: cover;
    flex-shrink: 0;
}

.product-list-info {
    flex: 1;
    padding: 12px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.product-list-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 4px;
}

.product-list-price {
    font-size: 16px;
    font-weight: 700;
    color: var(--secondary-navy);
    margin-bottom: 8px;
}

.product-list-rating {
    font-size: 12px;
    color: var(--text-light);
}

/* Skeleton Loader */
.skeleton {
    background: linear-gradient(
        90deg,
        #f0f0f0 25%,
        #e0e0e0 50%,
        #f0f0f0 75%
    );
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

.product-card.skeleton {
    cursor: default;
}

.product-card.skeleton:hover {
    transform: none;
    box-shadow: none;
}

.skeleton-image {
    width: 100%;
    padding-top: 100%;
    background-color: #e0e0e0;
    border-radius: 8px 8px 0 0;
}

.skeleton-text {
    height: 12px;
    margin: 8px 0;
    border-radius: 4px;
}

/* Responsive Grid */
@media (max-width: 768px) {
    .product-grid {
        grid-template-columns: repeat(2, minmax(160px, 1fr));
        gap: 12px;
        padding: 0 16px;
    }

    .product-name {
        font-size: 12px;
    }

    .product-price {
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .product-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
        padding: 0 8px;
    }

    .product-card {
        border-radius: 6px;
    }

    .product-info {
        padding: 10px;
    }

    .product-name {
        font-size: 11px;
    }

    .product-price {
        font-size: 12px;
    }

    .product-tag {
        font-size: 9px;
        padding: 2px 6px;
    }

    .wishlist-btn {
        width: 32px;
        height: 32px;
    }

    .wishlist-btn svg {
        width: 18px;
        height: 18px;
    }
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 60px 20px;
}

.empty-state-icon {
    font-size: 48px;
    margin-bottom: 16px;
}

.empty-state-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.empty-state-text {
    font-size: 14px;
    color: var(--text-light);
    margin-bottom: 24px;
}

.empty-state-btn {
    padding: 12px 24px;
    background-color: var(--primary-beige);
    color: var(--text-dark);
    border: none;
    border-radius: 4px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.empty-state-btn:hover {
    background-color: #d4c5b8;
    transform: translateY(-2px);
}
