/* ================================================== MODA (odjeca.hr partner feed)
 * Same frame as the deal listings: category menu and filter boxes in the left column
 * (#rightcolumn, hidden below 960px like on the deal pages), products in the right one.
 *
 * Look: quiet and editorial. Ink on white, warm grey image tiles, one sale red for prices and
 * discounts, sentence case headings, a single horizontal gutter (--moda-gutter) that every
 * row in the right column aligns to. No gradients over photos.
 */

.moda,
.moda-wrap {
	--moda-ink: #141414;
	--moda-text: #2b2b2b;
	--moda-muted: #767676;
	--moda-faint: #a3a3a3;
	--moda-line: #ececec;
	--moda-line-strong: #d9d9d9;
	--moda-tile: #f5f4f2;
	--moda-sale: #c4161c;
	--moda-gutter: 12px;
	--moda-radius: 4px;
	color: var(--moda-text);
	font: 14px/1.45 pn, Arial, Helvetica, sans-serif;
	-webkit-font-smoothing: antialiased;
}

.moda a,
.moda a:hover {
	color: inherit;
	text-decoration: none;
}

.moda *,
.moda *::before,
.moda *::after {
	box-sizing: border-box;
}

.moda-wrap::after {
	content: "";
	display: table;
	clear: both;
}

/* ---------- right column */
.moda-main {
	float: right;
	width: 750px;
	margin-bottom: 20px;
	background: #fff;
}

/* heading: same look as the deal listing titles (.offers-section-title h2, .title-count) */
.moda-head {
	display: flex;
	align-items: center;
	gap: 10px;
	min-height: 50px;
	padding: 0 var(--moda-gutter);
	border-bottom: 1px solid #e0e8ef;
}

.moda-head__title {
	margin: 0;
	font: bold 14px/1.2 pnb, Arial, sans-serif;
	color: #1a3a52;
	text-transform: uppercase;
}

.moda-head__count {
	flex-shrink: 0;
	margin: 0;
	padding: 0 8px;
	border-radius: 0;
	background: #eef3f7;
	font: bold 12px/20px pnb, Arial, sans-serif;
	color: #6b7d8c;
}

/* category and active filter tags: the deal pages' .subcategory-tags / .subcat-tag / .filter-tag
   (main.css), only the Moda link reset is undone so they keep their own colours */
.moda .subcat-tag,
.moda .filter-tag {
	font-size: 14px;
}

.moda .subcat-tag {
	color: #000;
}

.moda .subcat-tag.active,
.moda .subcat-tag:hover {
	color: #fff;
}

.moda .filter-tag {
	color: #000;
}

/* ---------- mobile filter buttons + panes (desktop uses the left column boxes) */
.moda-filterbar {
	display: none;
	gap: 8px;
	padding: 14px var(--moda-gutter) 0;
}

.moda-fbtn {
	position: relative;
	flex: 1 1 0;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 7px;
	height: 40px;
	padding: 0 10px;
	border: 1px solid var(--moda-line-strong);
	border-radius: var(--moda-radius);
	background: #fff;
	font: 13px/1 pnsb, Arial, sans-serif;
	color: var(--moda-ink);
	cursor: pointer;
}

.moda-fbtn.active {
	border-color: var(--moda-ink);
	box-shadow: inset 0 0 0 1px var(--moda-ink);
}

.moda-fbtn.has-value::after {
	content: "";
	position: absolute;
	top: 7px;
	right: 7px;
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: var(--moda-sale);
}

.moda-pane {
	margin: 10px var(--moda-gutter) 0;
	padding: 16px;
	border: 1px solid var(--moda-line);
	border-radius: var(--moda-radius);
	background: #fff;
}

.moda-pane[hidden] {
	display: none !important;
}

/* ---------- filter forms (left column boxes and mobile panes) */
.moda-filter-box {
	margin-bottom: 20px;
}

.moda-filter-box > summary {
	list-style: none;
	cursor: pointer;
	display: flex;
	align-items: center;
	gap: 6px;
	user-select: none;
}

.moda-filter-box > summary::-webkit-details-marker {
	display: none;
}

.moda-filter-box > summary::after {
	content: "";
	margin-left: auto;
	width: 6px;
	height: 6px;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg);
	transition: transform 0.15s;
}

.moda-filter-box[open] > summary::after {
	transform: rotate(-135deg);
}

.moda-filter-box .btbody {
	padding: 8px 16px 12px;
}

.moda-filter-box#moda-price-box .btbody {
	padding: 14px 16px;
}

/* "Filtriraj" and "Poništi" below each filter (same look as the deal pages' filters) */
.moda-filter-form .moda-apply {
	margin-top: 10px;
}

.moda-wrap a.price-filter-clear {
	display: flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	margin-top: 6px;
	color: #666;
	text-decoration: none;
}

.moda-wrap a.price-filter-clear:hover {
	color: #333;
	text-decoration: none;
}

.moda-options {
	display: flex;
	flex-direction: column;
}

/* desktop sidebar: every option list (colors, brands, shops) keeps a fixed height and scrolls,
   so all options are in the list and the "Prikaži sve" fold is not needed there */
@media screen and (min-width: 960px) {
	#rightcolumn .moda-options:not(.moda-dept-options) {
		max-height: 300px;
		overflow-y: auto;
		overscroll-behavior: contain;
		margin-right: -8px;
		padding-right: 8px;
	}

	/* always visible scrollbar (Chrome, Safari): a styled ::-webkit-scrollbar is not an overlay
	   scrollbar, so macOS does not hide it until scrolling */
	#rightcolumn .moda-options:not(.moda-dept-options)::-webkit-scrollbar {
		width: 6px;
	}

	#rightcolumn .moda-options:not(.moda-dept-options)::-webkit-scrollbar-track {
		border-radius: 3px;
		background: #eef2f6;
	}

	#rightcolumn .moda-options:not(.moda-dept-options)::-webkit-scrollbar-thumb {
		border-radius: 3px;
		background: #9fb0bd;
	}

	/* Firefox only: in current Chrome these would switch the styled scrollbar above off */
	@supports (-moz-appearance: none) {
		#rightcolumn .moda-options:not(.moda-dept-options) {
			scrollbar-width: thin;
			scrollbar-color: #9fb0bd #eef2f6;
		}
	}

	.moda-js #rightcolumn .moda-options:not(.is-searching) .moda-check.is-extra {
		display: flex;
	}

	#rightcolumn .moda-options__more {
		display: none !important;
	}
}

/* search field above long brand / shop lists (shown only when the script runs) */
.moda-search {
	display: none;
	position: relative;
	margin: 6px 0 4px;
}

.moda-js .moda-search {
	display: block;
}

.moda-search svg {
	position: absolute;
	left: 11px;
	top: 50%;
	transform: translateY(-50%);
	color: #8a8a8a;
	pointer-events: none;
}

.moda-search__input {
	width: 100%;
	height: 38px;
	padding: 0 12px 0 33px;
	border: 1px solid #d9d9d9;
	border-radius: 4px;
	background: #fff;
	font: 14px/1 pn, Arial, sans-serif;
	color: #141414;
	-webkit-appearance: none;
	appearance: none;
}

.moda-search__input:focus {
	outline: none;
	border-color: #141414;
}

.moda-search__input::placeholder {
	color: #9a9a9a;
}

/* while searching every match is shown, the fold and "Prikaži sve" step aside */
.moda-options.is-searching .moda-check.is-extra {
	display: flex;
}

.moda-options.is-searching .moda-check.is-miss,
.moda-options.is-searching .moda-options__more {
	display: none !important;
}

.moda-options.is-searching .moda-check {
	border-top: 0;
}

.moda-options__none {
	margin: 10px 0 4px;
	font-size: 13px;
	color: #8a8a8a;
}

/* options past the first 8 fold behind "Prikaži sve" (only when the script runs) */
.moda-js .moda-options:not(.is-expanded):not(.is-searching) .moda-check.is-extra {
	display: none;
}

.moda-options__more {
	display: none;
	align-self: flex-start;
	margin: 8px 0 2px;
	padding: 0;
	border: 0;
	background: none;
	font: 13px/1.3 pnsb, Arial, sans-serif;
	color: #146fb0;
	cursor: pointer;
}

.moda-js .moda-options__more {
	display: block;
}

.moda-options__more:hover {
	text-decoration: underline;
}

.moda-check {
	display: flex;
	align-items: center;
	gap: 10px;
	min-height: 34px;
	padding: 6px 0;
	cursor: pointer;
	font: 14px/1.3 pn, Arial, sans-serif;
	color: #2b2b2b;
}

.moda-check + .moda-check {
	border-top: 1px solid #f0f2f4;
}

.moda-check:hover .moda-check__name {
	color: #000;
}

.moda-check input {
	flex-shrink: 0;
	width: 16px;
	height: 16px;
	margin: 0;
	accent-color: #141414;
}

/* color filter swatch (background from the feed: color or gradient). The swatch is the
   checkbox: the real input stays for forms, keyboard and screen readers but is not drawn */
.moda-swatch {
	position: relative;
	flex-shrink: 0;
	width: 22px;
	height: 22px;
	border-radius: 50%;
	box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.15);
	transition: box-shadow 0.15s;
}

.moda-check--color {
	position: relative;
	padding-left: 5px; /* room for the selection ring inside the scrolling list */
}

.moda-check--color input {
	position: absolute;
	left: 0;
	top: 50%;
	width: 1px;
	height: 1px;
	opacity: 0;
	pointer-events: none;
}

.moda-check--color:hover .moda-swatch {
	box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.15), 0 0 0 2px #fff, 0 0 0 3px #9fb0bd;
}

.moda-check--color input:checked + .moda-swatch {
	box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.15), 0 0 0 2px #fff, 0 0 0 4px #115d8c;
}

/* check mark: white, dark on light swatches */
.moda-check--color input:checked + .moda-swatch::after {
	content: "";
	position: absolute;
	left: 8px;
	top: 4px;
	width: 5px;
	height: 10px;
	border: solid #fff;
	border-width: 0 2px 2px 0;
	transform: rotate(45deg);
}

.moda-check--color input:checked + .moda-swatch--white::after,
.moda-check--color input:checked + .moda-swatch--beige::after,
.moda-check--color input:checked + .moda-swatch--gray::after,
.moda-check--color input:checked + .moda-swatch--yellow::after,
.moda-check--color input:checked + .moda-swatch--gold::after,
.moda-check--color input:checked + .moda-swatch--silver::after {
	border-color: #222;
}

.moda-check--color input:checked ~ .moda-check__name {
	font-family: pnsb, Arial, sans-serif;
	color: #000;
}

.moda-check--color input:focus-visible + .moda-swatch {
	outline: 2px solid #115d8c;
	outline-offset: 4px;
}

.moda-check__name {
	min-width: 0;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

/* department options: the deal pages' radio boxes (.deal-quicklinks / .deal-link in main.css);
   only the Moda link reset (.moda a) is undone so they keep their colours */
.moda a.deal-link {
	color: #146fb0;
}

.moda a.deal-link:hover {
	color: #0f5a90;
}

.moda a.deal-link.active {
	color: #fff;
}

/* spacing between the radio circle and the label as a margin: the flex `gap` of .deal-link is
   ignored by browsers without flex gap support (older Safari), which glued them together */
.moda-dept-options .deal-link {
	gap: 0;
}

.moda-dept-options .deal-link::before {
	margin-right: 8px;
}

.moda-dept__name {
	min-width: 0;
	overflow: hidden;
	text-overflow: ellipsis;
}

.moda-dept__count {
	margin-left: auto;
	padding-left: 6px;
	font: 12px/1 pn, Arial, sans-serif;
	opacity: 0.7;
	font-variant-numeric: tabular-nums;
}

.moda-check__count {
	margin-left: auto;
	font-size: 12px;
	color: #a3a3a3;
	font-variant-numeric: tabular-nums;
}

.moda-btn {
	display: inline-block;
	padding: 11px 20px;
	border: 0;
	border-radius: var(--moda-radius);
	background: var(--moda-ink);
	color: #fff;
	font: 13px/1 pnsb, Arial, sans-serif;
	letter-spacing: 0.04em;
	cursor: pointer;
}

.moda a.moda-btn {
	color: #fff;
}

/* ---------- product grid + cards */
.moda-results {
	padding: 22px var(--moda-gutter) 28px;
}

.moda-grid {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 22px 10px;
}

.moda-card__link {
	display: flex;
	flex-direction: column;
	height: 100%;
	cursor: pointer;
}

.moda-card__link:focus-visible {
	outline: 2px solid var(--moda-ink);
	outline-offset: 3px;
}

.moda-card__media {
	position: relative;
	/* most shop photos are 2:3 (model shots), so they fill the tile without side bands */
	aspect-ratio: 2 / 3;
	background: var(--moda-tile);
	border-radius: var(--moda-radius);
	overflow: hidden;
}

/* packshots on white blend into the tile; photos of models stay as they are */
.moda-card__media img {
	width: 100%;
	height: 100%;
	object-fit: contain;
	mix-blend-mode: multiply;
	display: block;
	transition: transform 0.4s ease;
}

.moda-card__media img.is-fallback {
	padding: 28%;
	opacity: 0.35;
}

.moda-card__link:hover .moda-card__media img {
	transform: scale(1.035);
}

.moda-badge {
	position: absolute;
	left: 10px;
	padding: 6px 9px;
	border-radius: 2px;
	font: 14px/1 pnsb, Arial, sans-serif;
	letter-spacing: 0.03em;
}

.moda-badge--sale {
	top: 10px;
	background: var(--moda-sale);
	color: #fff;
}

.moda-badge--new {
	top: 42px;
	font-size: 11px;
	background: #fff;
	color: var(--moda-ink);
	text-transform: uppercase;
	letter-spacing: 0.08em;
}

.moda-card__fav {
	position: absolute;
	top: 10px;
	right: 10px;
	display: inline-flex;
	align-items: center;
	gap: 4px;
	padding: 4px 7px;
	border-radius: 999px;
	background: #fff;
	color: var(--moda-ink);
	font: 11px/1 pnsb, Arial, sans-serif;
}

.moda-card__fav svg {
	color: var(--moda-sale);
}

.moda-card__body {
	display: flex;
	flex-direction: column;
	gap: 4px;
	flex: 1;
	padding: 8px 2px 0;
}

/* shop name on hover at the bottom of the photo, like the deal cards (.offer-portal-name in main.css) */
.moda-card__link:hover .offer-portal-name {
	display: block;
	opacity: 1;
}

.moda-card__title {
	margin: 0;
	font: 13px/1.4 pn, Arial, sans-serif;
	color: var(--moda-text);
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.moda-card__brand {
	font-family: pnsb, Arial, sans-serif;
	color: var(--moda-ink);
}

.moda-card__price {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 2px 8px;
	margin: auto 0 0;
	padding-top: 2px;
}

.moda-price {
	font: 15px/1.2 pnsb, Arial, sans-serif;
	color: var(--moda-sale);
	font-variant-numeric: tabular-nums;
}

.moda-price__from {
	font: 12px pn, Arial, sans-serif;
}

.moda-price--old {
	font-size: 12px;
	color: var(--moda-faint);
}

/* ---------- homepage carousels (inside the .featured-section frame of main.css) */
/* no blue frame (gaps and bottom padding of the deal carousels): product cards sit on white */
.featured-fashion .featured-section-scroll-wrap {
	background: #fff;
}

.moda-carousel {
	list-style: none;
	margin: 0;
}

.moda-carousel .moda-card {
	flex: 0 0 200px;
	min-width: 0;
	padding: 10px 10px 14px;
	background: #fff;
	scroll-snap-align: start;
}

.moda-carousel .moda-card__media {
	border-radius: 2px;
}

/* ---------- load more (same button as the deal pages, #main-offers > a in main.css), empty state */
.moda-more {
	margin: 28px 0 6px;
}

.moda a.moda-loadmore {
	display: block;
	max-width: 660px;
	height: 44px;
	margin: 0 auto;
	padding: 0 30px;
	border: 1px solid #3892cf;
	box-sizing: border-box;
	background: linear-gradient(180deg, #1a7cb8 0%, #115d8c 100%);
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15), inset 0 1px 0 rgba(255, 255, 255, 0.12);
	color: #fff;
	text-shadow: 0 -1px rgba(0, 0, 0, 0.15);
	text-align: center;
	text-transform: uppercase;
	font: bold 18px/42px pnb, Arial, Helvetica, sans-serif;
	transition: all 0.2s ease;
}

.moda a.moda-loadmore:hover {
	background: linear-gradient(180deg, #1e8fd4 0%, #146fb0 100%);
	box-shadow: 0 3px 10px rgba(0, 0, 0, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.15);
	color: #fff;
	transform: translateY(-1px);
}

.moda a.moda-loadmore.is-loading {
	opacity: 0.6;
	pointer-events: none;
}

.moda-empty {
	text-align: center;
	padding: 56px var(--moda-gutter);
	color: var(--moda-muted);
}


/* "Na vrh" button (#float-panel / a.floatlink.top of the deal pages, shown on scroll by main.js):
   desktop only on Moda, the mobile layout has the filter bar at the top */
@media screen and (max-width: 959px) {
	.moda-float-panel {
		display: none !important;
	}
}

/* ---------- breakpoints */
@media screen and (min-width: 1280px) {
	.moda-main {
		width: 920px;
	}

	.moda-grid {
		grid-template-columns: repeat(4, minmax(0, 1fr));
	}
}

@media screen and (min-width: 1440px) {
	.moda-main {
		width: 1025px;
	}
}

@media screen and (max-width: 959px) {
	.moda,
	.moda-wrap {
		--moda-gutter: 10px;
	}

	.moda-main {
		float: none;
		width: 100%;
	}

	.moda-filterbar {
		display: flex;
	}

	

	.moda-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 18px 8px;
	}
}

@media screen and (min-width: 600px) and (max-width: 959px) {
	.moda-grid {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

@media screen and (max-width: 767px) {
	.moda-head {
		min-height: 0;
		padding: 12px var(--moda-gutter) 8px;
		border-bottom: 0;
	}

	.moda-head__title {
		font: 800 16px/1.2 pnsb, -apple-system, Arial, sans-serif;
		color: #222;
	}

	.moda-head__count {
		font: 700 11px/18px pnsb, Arial, sans-serif;
	}
}

@media screen and (max-width: 599px) {
	.moda-carousel .moda-card {
		flex-basis: 158px;
	}

	.moda-badge--sale {
		font-size: 12px;
		padding: 5px 7px;
	}

	.moda-badge--new {
		top: 36px;
	}

	.moda-results {
		padding-top: 18px;
	}
}
