/* ========================================
   FOOTWEAR COLLECTION - PAGE SPECIFIC STYLES
   ======================================== */

/* ========================================
   PAGE CONTAINER
   ======================================== */

.collection-page {
	background-color: #ffffff;
	width: 100%;
}

/* ========================================
   FILTER CONTROLS
   ======================================== */

.filter-controls {
	margin-top: 260px;
	padding: 0 94px;
	width: 100%;
}

.filter-toggle-btn {
	display: inline-flex;
	height: 32px;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 6px 16px 6px 8px;
	border-radius: 8px;
	border: 1px solid #cac4d0;
	background: transparent;
	cursor: pointer;
	outline: none;
	transition: background-color 0.2s ease;
}

.filter-toggle-btn:hover {
	background-color: #f5f5f5;
}

.filter-toggle-btn:active {
	background-color: #e0e0e0;
}

.filter-toggle-btn--active {
	background-color: #000000;
	border-color: #000000;
}

.filter-toggle-btn--active:hover {
	background-color: #333333;
}

.filter-toggle-btn--active .filter-toggle-btn__text {
	color: #ffffff;
}

.filter-toggle-btn--active .filter-toggle-btn__icon {
	filter: brightness(0) invert(1);
}

.filter-toggle-btn__icon {
	width: 18px;
	height: 18px;
}

.filter-toggle-btn__text {
	font-family: var(--m3-label-large-font-family);
	font-weight: var(--m3-label-large-font-weight);
	color: #49454f;
	font-size: var(--m3-label-large-font-size);
	text-align: center;
	letter-spacing: var(--m3-label-large-letter-spacing);
	line-height: var(--m3-label-large-line-height);
	white-space: nowrap;
	font-style: var(--m3-label-large-font-style);
}

.filter-controls__chips {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 8px 0px;
}

/* Chip click functionality styles only */
.chip {
	cursor: pointer;
	user-select: none;
	transition: opacity 0.2s ease;
}

.chip:hover {
	opacity: 0.8;
}

/* ========================================
   PRODUCT COLLECTION - GRID LAYOUT
   ======================================== */

.product-collection {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 23px 19px;
	width: 100%;
	margin-bottom: 78px;
	padding: 0 94px;
}

/* Product Card */
.collection-product {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	text-decoration: none;
	gap: 12px;
}

.collection-product__image {
	width: 100%;
	height: auto;
	aspect-ratio: 1;
	border-radius: 6px;
	background-size: cover;
	background-position: 50% 50%;
}

/* Color Options */
.collection-product__colors {
	display: flex;
	align-items: center;
	height: 16px;
	gap: 6.5px;
}

.collection-product__color {
	width: 16px;
	height: 16px;
	border-radius: 8px;
	display: inline-block;
	/* Essential button reset styles only */
	padding: 0;
	margin: 0;
	border: none;
	background: none;
	outline: none;
	cursor: pointer;
}

.collection-product__color.active {
	border: 2.23px solid #ffffff;
}

/* Product Info */
.collection-product__info {
	display: flex;
	flex-direction: column;
}

.collection-product__name {
	font-family: 'Trim-Bold', Helvetica;
	font-weight: 700;
	color: #000000;
	font-size: 18px;
	line-height: 27px;
	letter-spacing: 0;
	margin: 0;
}

.collection-product__description {
	font-family: 'Inter', Helvetica;
	font-weight: 400;
	color: #828282;
	font-size: 12px;
	line-height: 18px;
	letter-spacing: 0;
	margin: 0;
}

/* Featured Images */
.collection-featured {
	object-fit: cover;
	border-radius: 6px;
	width: 100%;
	height: 100%;
}

/* Large featured image spans 2 columns */
.collection-featured--large,
.collection-featured[data-grid-span='2'] {
	grid-column: span 2;
}

/* Small featured image takes 1 column */
.collection-featured--small {
	grid-column: span 1;
}

/* ========================================
   FILTER SIDEBAR
   ======================================== */

/* Overlay */
.filter-overlay {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background-color: rgba(0, 0, 0, 0.5);
	z-index: 999;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.3s ease, visibility 0.3s ease;
}

.filter-overlay--active {
	opacity: 1;
	visibility: visible;
}

/* Sidebar Container */
.filter-sidebar {
	position: fixed;
	top: 0;
	right: 0;
	width: 400px;
	height: 100%;
	background-color: #ffffff;
	box-shadow: -4px 0 20px rgba(0, 0, 0, 0.1);
	z-index: 1000;
	transform: translateX(100%);
	transition: transform 0.3s ease;
	overflow-y: auto;
	scrollbar-width: thin;
	scrollbar-color: #d0d0d0 transparent;
}

.filter-sidebar--active {
	transform: translateX(0);
}

.filter-sidebar::-webkit-scrollbar {
	width: 6px;
}

.filter-sidebar::-webkit-scrollbar-track {
	background: transparent;
}

.filter-sidebar::-webkit-scrollbar-thumb {
	background-color: #d0d0d0;
	border-radius: 3px;
}

.filter-sidebar::-webkit-scrollbar-thumb:hover {
	background-color: #a0a0a0;
}

/* Sidebar Layout */
.filter-sidebar__content {
	height: 100%;
	display: flex;
	flex-direction: column;
}

/* Header */
.filter-sidebar__header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 24px;
	border-bottom: 1px solid #e0e0e0;
}

.filter-sidebar__title {
	font-family: 'Trim-Bold', Helvetica;
	font-weight: 700;
	font-size: 24px;
	line-height: 32px;
	color: #000000;
	margin: 0;
}

.filter-sidebar__close {
	background: none;
	border: none;
	cursor: pointer;
	padding: 8px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 50%;
	transition: background-color 0.2s ease;
}

.filter-sidebar__close:hover {
	background-color: #f5f5f5;
}

.filter-sidebar__close:focus {
	outline: 2px solid #007bff;
	outline-offset: 2px;
}

.filter-sidebar__close-icon {
	width: 24px;
	height: 24px;
	color: #000000;
}

/* Body */
.filter-sidebar__body {
	flex: 1;
	padding: 24px;
}

/* Filter Sections */
.filter-section {
	margin-bottom: 32px;
}

.filter-section:last-child {
	margin-bottom: 0;
}

.filter-section__title {
	font-family: 'Inter', Helvetica;
	font-weight: 600;
	font-size: 16px;
	line-height: 24px;
	color: #000000;
	margin: 0 0 16px 0;
}

.filter-section__options {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

/* Custom Checkbox */
.filter-option {
	display: flex;
	align-items: center;
	cursor: pointer;
	position: relative;
	padding-left: 32px;
	line-height: 20px;
	user-select: none;
}

.filter-option__input {
	position: absolute;
	opacity: 0;
	cursor: pointer;
	height: 0;
	width: 0;
}

.filter-option__checkbox {
	position: absolute;
	left: 0;
	top: 50%;
	transform: translateY(-50%);
	height: 20px;
	width: 20px;
	background-color: #ffffff;
	border: 2px solid #000000;
	border-radius: 3px;
	transition: all 0.2s ease;
}

.filter-option:hover .filter-option__checkbox {
	border-color: #333333;
}

.filter-option__input:checked ~ .filter-option__checkbox {
	background-color: #ffffff;
	border-color: #000000;
}

/* Inner square for checked state */
.filter-option__input:checked ~ .filter-option__checkbox::after {
	content: '';
	position: absolute;
	top: 2px;
	left: 2px;
	right: 2px;
	bottom: 2px;
	background-color: #000000;
	border-radius: 1px;
}

.filter-option__label {
	font-family: 'Inter', Helvetica;
	font-weight: 400;
	font-size: 14px;
	line-height: 20px;
	color: #333333;
}

.filter-option:focus-within .filter-option__checkbox {
	outline: 2px solid #007bff;
	outline-offset: 2px;
}

/* ========================================
   SELECTED FILTERS ROW
   ======================================== */

.filter-controls__selected-filters {
	margin-bottom: 8px;
}

.selected-filters__list {
	display: flex;
	align-items: center;
	gap: 8px;
	flex-wrap: wrap;
}

.selected-filter-tag {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 4px 8px 4px 12px;
	background-color: #f5f5f5;
	border: 1px solid #d0d0d0;
	border-radius: 16px;
	font-family: 'Inter', Helvetica;
	font-size: 12px;
	font-weight: 400;
	color: #333333;
	line-height: 16px;
}

.selected-filter-tag__text {
	white-space: nowrap;
}

.selected-filter-tag__remove {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 16px;
	height: 16px;
	background: none;
	border: none;
	border-radius: 50%;
	cursor: pointer;
	padding: 0;
	transition: background-color 0.2s ease;
}

.selected-filter-tag__remove:hover {
	background-color: #e0e0e0;
}

.selected-filter-tag__remove-icon {
	width: 12px;
	height: 12px;
	stroke: #666666;
	stroke-width: 2;
}

.selected-filter-tag__remove:hover .selected-filter-tag__remove-icon {
	stroke: #333333;
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */

/* Tablet - 3 columns */
@media (max-width: 1024px) {
	.product-collection {
		grid-template-columns: repeat(3, 1fr);
		padding: 0 40px;
	}
}

/* Mobile - 2 columns */
@media (max-width: 768px) {
	.filter-controls {
		padding: 0 20px;
		margin-top: 180px;
	}

	.product-collection {
		grid-template-columns: repeat(2, 1fr);
		gap: 15px;
		padding: 0 20px;
	}

	/* Featured images span full width on mobile */
	.collection-featured--large,
	.collection-featured[data-grid-span='2'] {
		grid-column: span 2;
	}

	.collection-featured--small {
		grid-column: span 1;
	}

	.filter-controls__chips {
		flex-wrap: wrap;
	}

	.filter-sidebar {
		width: 100%;
	}
}

/* Small Mobile - Still 2 columns but smaller gap */
@media (max-width: 480px) {
	.product-collection {
		gap: 10px;
		padding: 0 15px;
	}

	.filter-sidebar {
		width: 100vw;
	}

	.filter-sidebar__header {
		padding: 16px;
	}

	.filter-sidebar__body {
		padding: 16px;
	}

	.filter-section {
		margin-bottom: 24px;
	}
}

/* Very small screens - 1 column */
@media (max-width: 320px) {
	.product-collection {
		grid-template-columns: 1fr;
	}

	.collection-featured--large,
	.collection-featured[data-grid-span='2'],
	.collection-featured--small {
		grid-column: span 1;
	}
}

