/* Popust uz kupovinu – prodavnica */

.pup-cart-offers { margin: 0 0 24px; }

.pup-offer {
	border: 2px dashed #e9bfdc;
	border-radius: 8px;
	padding: 18px 20px;
	margin: 0 0 16px;
	background: #fff;
}

.pup-title { margin: 0 0 6px; font-size: 1.15em; line-height: 1.3; }
.pup-hint { margin: 0 0 12px; opacity: .75; font-size: .95em; }

.pup-products { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 8px; }

.pup-product label {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 8px 10px;
	border: 1px solid #e5e5e5;
	border-radius: 6px;
	cursor: pointer;
	margin: 0;
	transition: border-color .15s, background .15s;
}
.pup-product label:hover { border-color: #c9c9c9; }
.pup-product.is-selected label { border-color: #2e7d32; background: #f3faf3; }
.pup-product input { margin: 0; flex: 0 0 auto; }

.pup-thumb img { width: 56px; height: 56px; object-fit: contain; display: block; }
.pup-info { display: flex; flex-direction: column; gap: 2px; }
.pup-name { font-weight: 600; }
.pup-price del { opacity: .6; margin-right: 4px; }
.pup-price ins { text-decoration: none; font-weight: 700; color: #2e7d32; }

.pup-msg { margin: 0 0 8px; min-height: 0; }
.pup-msg:empty { display: none; }
.pup-error { color: #b32d2e; }
.pup-success { color: #2e7d32; font-weight: 600; margin: 8px 0 16px; }

.pup-submit[disabled] { opacity: .6; cursor: wait; }

/* Iskačući prozor */
body.pup-lock { overflow: hidden; }

.pup-overlay {
	position: fixed;
	inset: 0;
	z-index: 999999;
	background: rgba(0, 0, 0, .55);
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
	opacity: 0;
	transition: opacity .2s;
}
.pup-overlay.pup-open { opacity: 1; }

.pup-modal {
	position: relative;
	background: #fff;
	border-radius: 10px;
	width: 100%;
	max-width: 520px;
	max-height: 90vh;
	overflow-y: auto;
	padding: 28px 22px 16px;
	box-shadow: 0 10px 40px rgba(0, 0, 0, .25);
}
.pup-modal .pup-offer { border: 0; padding: 0; margin-bottom: 12px; }

.pup-close {
	position: absolute;
	top: 6px;
	right: 10px;
	background: none !important;
	border: 0 !important;
	font-size: 28px;
	line-height: 1;
	color: #555 !important;
	cursor: pointer;
	padding: 4px 8px !important;
	box-shadow: none !important;
}

.pup-modal-footer { text-align: center; border-top: 1px solid #eee; padding-top: 10px; }
.pup-no-thanks {
	background: none !important;
	border: 0 !important;
	color: #777 !important;
	text-decoration: underline;
	cursor: pointer;
	box-shadow: none !important;
	padding: 4px 8px !important;
	font-size: .95em;
}

/* Obaveštenje na stranici proizvoda */
.pup-notice {
	display: flex;
	align-items: center;
	gap: 10px;
	margin: 0 0 14px;
	padding: 10px 12px;
	border-radius: 6px;
	background: #fdf3f9;
	border: 1px solid #f0d3e6;
	line-height: 1.4;
}
.pup-badge {
	flex: 0 0 auto;
	background: #e94c89;
	color: #fff;
	font-weight: 700;
	font-size: .85em;
	padding: 4px 8px;
	border-radius: 4px;
	white-space: nowrap;
}
.pup-notice-gift .pup-badge { background: #2e7d32; }

/* Bedž „Akcija!“ i opis akcije na karticama proizvoda */
.pup-flash[data-pup-id] { cursor: help; }

/* Rezervni izgled bedža – :where() ima nultu specifičnost, pa stil teme uvek ima prednost. */
:where(.pup-own-flash) {
	position: absolute;
	top: 20px;
	left: 20px;
	z-index: 9;
	background: #5ec99a;
	color: #fff;
	font-size: 12px;
	font-weight: 700;
	line-height: 1.2;
	text-transform: uppercase;
	padding: 7px 11px;
	border-radius: 2px;
}

.pup-tip {
	display: none;
	position: absolute;
	z-index: 99999;
	width: 260px;
	max-width: calc(100vw - 16px);
	padding: 10px 12px;
	background: #fff;
	color: #333;
	border: 1px solid #e5e5e5;
	border-radius: 6px;
	box-shadow: 0 6px 20px rgba(0, 0, 0, .15);
	text-align: left;
	font-size: 13px;
	font-weight: 400;
	line-height: 1.35;
}
.pup-tip.is-visible { display: block; }
.pup-tip::before { /* most između bedža i prozora, da hover ne prekine */
	content: "";
	position: absolute;
	top: -8px;
	left: 0;
	right: 0;
	height: 8px;
}

.pup-fp-rule + .pup-fp-rule { margin-top: 10px; padding-top: 10px; border-top: 1px solid #eee; }
.pup-fp-title { font-weight: 700; font-size: 14px; color: #2e7d32; margin-bottom: 2px; }
.pup-fp-note { color: #555; margin-bottom: 6px; }
.pup-fp-items { display: grid; gap: 6px; }
.pup-fp-item { display: flex; align-items: center; gap: 8px; }
.pup-fp-item img { width: 40px !important; height: 40px !important; object-fit: contain; flex: 0 0 40px; margin: 0 !important; }
.pup-fp-info { display: flex; flex-direction: column; }
.pup-fp-name { font-weight: 600; color: #333; }
.pup-fp-price, .pup-fp-price .amount { color: #2e7d32; font-weight: 700; }
.pup-fp-more { color: #777; font-size: 12px; }

/* Bedž u više redova: tema često ima fiksnu visinu bedža, pa je poništavamo. */
.pup-flash.pup-multiline {
	height: auto !important;
	min-height: 0 !important;
	line-height: 1.25 !important;
	white-space: nowrap !important;
	text-align: center;
	padding-top: 6px !important;
	padding-bottom: 6px !important;
}

/* Popust na količinu u korpi */
.pup-qty-note { color: #2e7d32; font-weight: 600; }
.pup-savings .pup-savings-amount { color: #2e7d32; }
