:root {
	color-scheme: dark;
	--br-bg: #07182d;
	--br-line: rgba(159, 181, 210, 0.16);
	--br-text: #ffffff;
	--br-muted: #a9bad1;
	--br-gold: #ff852c;
	--br-green: #52d9a3;
	--br-red: #ff7d8f;
}

* { box-sizing: border-box; }

body {
	margin: 0;
	background:
		radial-gradient(circle at 82% 4%, rgba(115, 87, 255, 0.16), transparent 28%),
		radial-gradient(circle at 12% 92%, rgba(255, 133, 44, 0.08), transparent 30%),
		var(--br-bg);
	color: var(--br-text);
	font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

main {
	width: min(1180px, calc(100% - 32px));
	margin: 0 auto;
	padding: 56px 0 72px;
}

.cjenik-hero {
	position: relative;
	overflow: hidden;
	margin: 0 0 24px;
	padding: clamp(24px, 4vw, 42px);
	border: 1px solid var(--br-line);
	border-radius: 22px;
	background: linear-gradient(145deg, rgba(15, 29, 48, 0.98), rgba(8, 20, 36, 0.98));
	box-shadow: 0 28px 70px rgba(0, 0, 0, 0.24);
}

.cjenik-hero::after {
	content: "";
	position: absolute;
	right: -100px;
	top: -130px;
	width: 330px;
	height: 330px;
	border-radius: 50%;
	background: radial-gradient(circle, rgba(255, 133, 44, 0.16), transparent 66%);
	pointer-events: none;
}

.cjenik-kicker {
	margin: 0 0 8px;
	color: var(--br-gold);
	font-size: 0.78rem;
	font-weight: 800;
	letter-spacing: 0.12em;
	text-transform: uppercase;
}

h1 {
	margin: 0 0 10px;
	color: #fff;
	font-size: clamp(2rem, 4vw, 3rem);
	line-height: 1.08;
	letter-spacing: -0.045em;
}

.cjenik-hero p {
	max-width: 780px;
	margin: 0 0 8px;
	color: #c5d2e2;
	line-height: 1.65;
}

.cjenik-meta { color: var(--br-muted) !important; font-size: 0.92rem; }

.cjenik-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin: 20px 0 0;
}

.cjenik-btn,
.cjenik-page {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 42px;
	padding: 0 16px;
	border: 1px solid transparent;
	border-radius: 10px;
	font: inherit;
	font-size: 0.9rem;
	font-weight: 750;
	text-decoration: none;
	cursor: pointer;
	transition: 140ms ease;
}

.cjenik-btn {
	background: linear-gradient(135deg, #ffaa55, #ff852c);
	color: #111924;
	box-shadow: 0 10px 24px rgba(226, 162, 57, 0.16);
}

.cjenik-btn:hover { transform: translateY(-1px); color: #0b1220; }

.cjenik-btn--ghost {
	border-color: var(--br-line);
	background: rgba(255, 255, 255, 0.025);
	color: #e8eef6;
	box-shadow: none;
}

.cjenik-toolbar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 14px;
	margin: 0 0 14px;
}

.cjenik-search { flex: 1 1 360px; }
.cjenik-search input {
	width: min(100%, 460px);
	min-height: 44px;
	padding: 0 14px;
	border: 1px solid var(--br-line);
	border-radius: 11px;
	background: #19304a;
	color: var(--br-text);
	font: inherit;
	outline: none;
}
.cjenik-search input::placeholder { color: #71849d; }
.cjenik-search input:focus { border-color: rgba(255, 133, 44, 0.7); box-shadow: 0 0 0 3px rgba(255, 133, 44, 0.1); }

.cjenik-pager {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 7px;
	margin: 16px 0 0;
}
.cjenik-pager[hidden] { display: none !important; }
.cjenik-page { min-width: 40px; min-height: 38px; padding: 0 12px; border-color: var(--br-line); background: #10263d; color: #dfe6ef; }
.cjenik-page:hover { border-color: rgba(255, 133, 44, 0.45); background: #13243a; }
.cjenik-page.is-current { border-color: rgba(255, 133, 44, 0.55); background: rgba(255, 133, 44, 0.14); color: #ffaa55; }
.cjenik-page-gap { color: var(--br-muted); }

.cjenik-table tr[hidden], .cjenik-upit tr[hidden] { display: none !important; }

.cjenik-table-wrap {
	overflow: auto;
	border: 1px solid var(--br-line);
	border-radius: 16px;
	background: rgba(11, 23, 39, 0.92);
	box-shadow: 0 20px 50px rgba(0, 0, 0, 0.16);
	scrollbar-color: #2e4160 #091728;
	scrollbar-width: thin;
}

.cjenik-table, .cjenik-upit {
	width: 100%;
	border-collapse: collapse;
	font-size: 0.92rem;
}

.cjenik-table th, .cjenik-table td, .cjenik-upit th, .cjenik-upit td {
	padding: 13px 14px;
	border-bottom: 1px solid rgba(159, 181, 210, 0.1);
	text-align: left;
}

.cjenik-table th, .cjenik-upit th {
	background: #10263d;
	color: #aebdd0;
	font-size: 0.72rem;
	font-weight: 800;
	letter-spacing: 0.07em;
	text-transform: uppercase;
}

.cjenik-table tbody tr:hover td, .cjenik-upit tbody tr:hover td { background: rgba(115, 87, 255, 0.045); }
.cjenik-table tbody tr:last-child td, .cjenik-upit tbody tr:last-child td { border-bottom: 0; }
.cjenik-table td:nth-child(n + 3) { white-space: nowrap; font-variant-numeric: tabular-nums; }

.cjenik-upit-title { margin: 30px 0 12px; color: #fff; font-size: 1.3rem; }
.cjenik-upit { overflow: hidden; border: 1px solid var(--br-line); border-radius: 14px; background: rgba(11, 23, 39, 0.92); }
.cjenik-upit td:last-child { white-space: nowrap; }

.cjenik-stock { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; }
.cjenik-stock::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; box-shadow: 0 0 0 3px rgba(255,255,255,.03); }
.cjenik-stock.is-dostupno { color: var(--br-green); }
.cjenik-stock.is-nedostupno { color: var(--br-red); }

a { color: #8dbfff; }
a:hover { color: #b7d5ff; }

.empty, .cjenik-empty-filter {
	padding: 22px;
	border: 1px dashed var(--br-line);
	border-radius: 13px;
	background: rgba(255, 255, 255, 0.025);
	color: var(--br-muted);
}

.back { margin: 28px 0 0; }

.cjenik-btn:focus-visible, .cjenik-page:focus-visible, .cjenik-search input:focus-visible, a:focus-visible {
	outline: 2px solid var(--br-gold);
	outline-offset: 3px;
}

.screen-reader-text { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

@media (max-width: 720px) {
	main { width: min(100% - 20px, 1180px); padding-top: 20px; }
	.cjenik-hero { border-radius: 17px; }
	.cjenik-actions, .cjenik-actions .cjenik-btn { width: 100%; }
	.cjenik-toolbar { align-items: stretch; flex-direction: column; }
	.cjenik-search input { width: 100%; max-width: none; }
	.cjenik-table thead, .cjenik-upit thead { display: none; }
	.cjenik-table, .cjenik-table tbody, .cjenik-table tr, .cjenik-table td,
	.cjenik-upit, .cjenik-upit tbody, .cjenik-upit tr, .cjenik-upit td { display: block; width: 100%; }
	.cjenik-table tr, .cjenik-upit tr { padding: 12px 14px; border-bottom: 1px solid rgba(159, 181, 210, 0.1); }
	.cjenik-table td, .cjenik-upit td { padding: 6px 0; border: 0; white-space: normal; }
	.cjenik-table td::before, .cjenik-upit td::before { content: attr(data-label); display: block; margin-bottom: 2px; color: #7f91aa; font-size: 0.68rem; font-weight: 800; letter-spacing: 0.05em; text-transform: uppercase; }
}

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; } }


/* SIDRENA mobile catalog: same 07/18/2d background, 10/26/3d cards,
 * 28/45/5f borders, and ff/85/2c price accent as Android screens 04–05.
 * data-field is a stable public schema key; visible labels stay translated.
 */
.cjenik-table td[data-field="maloprodajna_cijena"] {
	color: #ff852c;
	font-weight: 800;
	font-variant-numeric: tabular-nums;
}
.cjenik-table td[data-field="sidrena_cijena"] {
	color: #a9bad1;
	font-variant-numeric: tabular-nums;
}
@media (max-width: 720px) {
	.cjenik-table-wrap {
		border: 0;
		background: transparent;
		box-shadow: none;
		overflow: visible;
	}
	.cjenik-table tbody tr {
		margin: 0 0 8px;
		padding: 12px 14px;
		border: 1px solid #28455f;
		border-radius: 12px;
		background: #10263d;
	}
	.cjenik-table tbody tr[data-kind="usluga"] {
		border-color: #36526a;
	}
	.cjenik-table tr[data-kind="usluga"] td[data-field="naziv"] {
		color: #fff;
		font-size: 15px;
		font-weight: 750;
	}
	.cjenik-table tr[data-kind="usluga"] td[data-field="maloprodajna_cijena"] {
		font-size: 16px;
		line-height: 1.45;
	}
	.cjenik-table td[data-field="sidrena_cijena"] {
		color: #a9bad1;
		font-size: 12px;
	}
	.cjenik-table tbody tr td::before {
		color: #a9bad1;
	}
}

/* Public price list: prevent long product names, SKUs and URLs from
 * producing page-level horizontal scrolling on compact phones. */
.cjenik-table-wrap,
.sidrena-cjenik,
.cjenik-toolbar,
.cjenik-search {
    box-sizing: border-box;
    min-width: 0;
    max-width: 100%;
}
.cjenik-table td,
.cjenik-upit td,
.cjenik-hero,
.cjenik-empty-filter {
    overflow-wrap: anywhere;
}
@media (max-width: 720px) {
    .cjenik-table-wrap {
        width: 100%;
    }
    .cjenik-table tbody tr,
    .cjenik-upit tbody tr {
        box-sizing: border-box;
        width: 100%;
        max-width: 100%;
        min-width: 0;
    }
    .cjenik-table td,
    .cjenik-upit td {
        overflow-wrap: anywhere;
        word-break: normal;
    }
    /* Override the more specific desktop nowrap rules for price/URL cells.
     * Long SKUs and public URLs must wrap inside the mobile card, not push
     * the complete document beyond the device viewport. */
    .cjenik-table td:nth-child(n + 3),
    .cjenik-upit td:last-child {
        white-space: normal;
    }
}
