/**
 * Supremefoam Product Category Grid Styles
 * 
 * Styles for the [supremefoam-product-catagory-list] shortcode
 */

.supremefoam-product-category-grid {
	display: grid;
	gap: 20px;
	margin: 20px 0;
}

.supremefoam-product-category-grid.columns-1 {
	grid-template-columns: 1fr;
}

.supremefoam-product-category-grid.columns-2 {
	grid-template-columns: repeat(2, 1fr);
}

.supremefoam-product-category-grid.columns-3 {
	grid-template-columns: repeat(3, 1fr);
}

.supremefoam-product-category-grid.columns-4 {
	grid-template-columns: repeat(4, 1fr);
}

.supremefoam-product-category-item {
	position: relative;
	overflow: hidden;
	box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
	transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.supremefoam-product-category-item:hover {
	transform: translateY(-5px);
	box-shadow: 0 8px 15px rgba(0, 0, 0, 0.2);
}

.supremefoam-product-category-link {
	display: block;
	text-decoration: none;
	color: inherit;
}

.supremefoam-product-category-content {
	position: relative;
	height: 120px;
	background-color: #4a4a4a;
	background-size: cover;
	background-position: center;
	background-repeat: no-repeat;
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
}

.supremefoam-product-category-content::before {
	content: '';
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: linear-gradient(135deg, rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.4));
	z-index: 1;
}

.supremefoam-product-category-overlay {
	position: relative;
	z-index: 2;
	text-align: center;
	padding: 20px;
	width: 100%;
}

.supremefoam-product-category-title {
	margin: 0;
	font-size: 18px;
	font-weight: 600;
	color: #ffffff;
	text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
	line-height: 1.3;
	word-wrap: break-word;
}

/* Responsive Design */
@media (max-width: 768px) {
	.supremefoam-product-category-grid.columns-2,
	.supremefoam-product-category-grid.columns-3,
	.supremefoam-product-category-grid.columns-4 {
		grid-template-columns: 1fr;
	}
	
	.supremefoam-product-category-grid {
		gap: 15px;
	}
	
	.supremefoam-product-category-content {
		height: 100px;
	}
	
	.supremefoam-product-category-title {
		font-size: 16px;
	}
	
	.supremefoam-product-category-overlay {
		padding: 15px;
	}
}

@media (max-width: 480px) {
	.supremefoam-product-category-content {
		height: 80px;
	}
	
	.supremefoam-product-category-title {
		font-size: 14px;
	}
	
	.supremefoam-product-category-overlay {
		padding: 10px;
	}
}

/* Hover Effects */
.supremefoam-product-category-item:hover .supremefoam-product-category-content::before {
	background: linear-gradient(135deg, rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.2));
}

.supremefoam-product-category-item:hover .supremefoam-product-category-title {
	text-shadow: 2px 2px 6px rgba(0, 0, 0, 0.7);
}

/* Accessibility */
.supremefoam-product-category-link:focus {
	outline: 3px solid #007cba;
	outline-offset: 2px;
}

.supremefoam-product-category-link:focus .supremefoam-product-category-content {
	transform: scale(1.02);
}

/* Loading animation for background images */
.supremefoam-product-category-content[style*="background-image"] {
	background-color: #666;
}

/* Fallback for categories without images */
.supremefoam-product-category-content:not([style*="background-image"]) {
	background-color: #4a4a4a;
} 