/* Nordic Poultry – Article Navigator. All rules scoped under .npan / .npan-ui to avoid theme conflicts. */
.npan {
	--npan-accent: #a6803a;
	--npan-ink: #1f2a24;
	--npan-muted: #5f6b64;
	--npan-card: #ffffff;
	--npan-line: rgba(31, 42, 36, 0.09);
	--npan-shadow: 0 1px 2px rgba(31, 42, 36, 0.05), 0 6px 18px rgba(31, 42, 36, 0.06);
	--npan-shadow-hover: 0 2px 4px rgba(31, 42, 36, 0.06), 0 14px 32px rgba(31, 42, 36, 0.10);
	box-sizing: border-box;
	margin: 2em 0;
	font-family: inherit;
	color: var(--npan-ink);
	line-height: 1.4;
}
.npan *, .npan *::before, .npan *::after { box-sizing: border-box; }

.npan .npan__head { margin: 0 0 1.1em; }
.npan .npan__title {
	margin: 0;
	font-size: 0.78em;
	font-weight: 700;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--npan-accent);
	display: flex; align-items: center; gap: .7em;
}
.npan .npan__title::after { content: ""; flex: 0 0 48px; height: 1px; background: currentColor; opacity: .5; }
.npan .npan__subtitle { margin: .35em 0 0; font-size: 1.15em; color: var(--npan-ink); font-weight: 500; }
.npan .npan__toggle { display: none; }

.npan .npan__list {
	list-style: none !important;
	margin: 0 !important;
	padding: 0 !important;
	display: grid;
	gap: 14px;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	counter-reset: none;
}
.npan.npan--cols-2 .npan__list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.npan .npan__item { margin: 0 !important; padding: 0 !important; list-style: none !important; }
.npan .npan__item::before, .npan .npan__item::marker { content: none !important; }

.npan .npan__card {
	position: relative;
	display: flex;
	align-items: center;
	gap: 14px;
	height: 100%;
	padding: 16px 18px;
	background: var(--npan-card);
	border: 1px solid var(--npan-line);
	border-radius: 14px;
	box-shadow: var(--npan-shadow);
	color: var(--npan-ink) !important;
	text-decoration: none !important;
	transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease, background-color .25s ease;
}
.npan .npan__card:hover, .npan .npan__card:focus-visible {
	transform: translateY(-2px);
	box-shadow: var(--npan-shadow-hover);
	border-color: color-mix(in srgb, var(--npan-accent) 40%, transparent);
	outline: none;
}
.npan .npan__card:focus-visible { box-shadow: 0 0 0 3px color-mix(in srgb, var(--npan-accent) 35%, transparent), var(--npan-shadow-hover); }

.npan .npan__marker {
	flex: 0 0 auto;
	display: inline-flex; align-items: center; justify-content: center;
	width: 38px; height: 38px;
	border-radius: 10px;
	background: color-mix(in srgb, var(--npan-accent) 12%, transparent);
	color: var(--npan-accent);
	font-size: .8em; font-weight: 700; letter-spacing: .04em;
	font-variant-numeric: tabular-nums;
	transition: background-color .25s ease, color .25s ease;
}
.npan .npan__marker svg { width: 20px; height: 20px; }
.npan .npan__text { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.npan .npan__label { font-weight: 600; font-size: 1em; }
.npan .npan__desc { font-size: .85em; color: var(--npan-muted); }
.npan .npan__arrow {
	flex: 0 0 auto; width: 18px; height: 18px;
	color: var(--npan-accent); opacity: .55;
	transition: transform .25s ease, opacity .25s ease;
}
.npan .npan__card:hover .npan__arrow { transform: translateX(3px); opacity: 1; }

/* Vertical (standing) cards */
.npan.npan--vertical .npan__card { flex-direction: column; align-items: flex-start; padding: 20px; min-height: 150px; }
.npan.npan--vertical .npan__text { flex: 1 1 auto; }
.npan.npan--vertical .npan__arrow { align-self: flex-end; }

/* Active section */
.npan .npan__card.is-active { border-color: var(--npan-accent); background: color-mix(in srgb, var(--npan-accent) 6%, var(--npan-card)); }
.npan .npan__card.is-active .npan__marker { background: var(--npan-accent); color: #fff; }

/* Mobile */
@media (max-width: 900px) {
	.npan .npan__list, .npan.npan--cols-2 .npan__list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
	.npan { margin: 1.5em 0; }
	.npan .npan__list, .npan.npan--cols-2 .npan__list { grid-template-columns: 1fr; gap: 8px; }
	.npan.npan--m-two .npan__list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.npan .npan__card, .npan.npan--vertical .npan__card { flex-direction: row; align-items: center; min-height: 0; padding: 12px 14px; border-radius: 12px; gap: 12px; }
	.npan.npan--m-two .npan__card { flex-direction: column; align-items: flex-start; }
	.npan.npan--m-two .npan__arrow { display: none; }
	.npan .npan__marker { width: 32px; height: 32px; }
	.npan .npan__desc { display: none; }
	.npan .npan__subtitle { font-size: 1em; }

	.npan.npan--m-accordion { border: 1px solid var(--npan-line); border-radius: 14px; background: var(--npan-card); box-shadow: var(--npan-shadow); padding: 14px 16px; }
	.npan.npan--m-accordion .npan__head { margin: 0; display: grid; grid-template-columns: 1fr auto; align-items: center; }
	.npan.npan--m-accordion .npan__subtitle { display: none; }
	.npan.npan--m-accordion .npan__toggle {
		display: inline-flex; align-items: center; gap: 6px; grid-row: 1; grid-column: 2;
		background: none; border: 0; padding: 6px 0; margin: 0; cursor: pointer;
		color: var(--npan-ink); font: inherit; font-weight: 600; font-size: .9em;
	}
	.npan.npan--m-accordion .npan__toggle svg { width: 18px; height: 18px; transition: transform .25s ease; }
	.npan.npan--m-accordion.is-open .npan__toggle svg { transform: rotate(180deg); }
	.npan.npan--m-accordion .npan__list { display: none; margin-top: 12px !important; }
	.npan.npan--m-accordion.is-open .npan__list { display: grid; }
	.npan.npan--m-accordion .npan__card { box-shadow: none; }
}

@media (prefers-reduced-motion: reduce) {
	.npan .npan__card, .npan .npan__arrow { transition: none; }
}

/* Floating UI (progress bar, sticky + back-to-top buttons) */
.npan-ui-progress {
	position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 99990;
	background: transparent; pointer-events: none;
}
.npan-ui-progress > span { display: block; height: 100%; width: 0; background: var(--npan-accent, #a6803a); transition: width .1s linear; }
body.admin-bar .npan-ui-progress { top: 32px; }
@media (max-width: 782px) { body.admin-bar .npan-ui-progress { top: 46px; } }

.npan-ui-fab {
	position: fixed; right: 20px; bottom: 20px; z-index: 99980;
	display: flex; flex-direction: column; align-items: flex-end; gap: 8px;
	opacity: 0; transform: translateY(12px); pointer-events: none;
	transition: opacity .25s ease, transform .25s ease;
}
.npan-ui-fab.is-visible { opacity: 1; transform: none; pointer-events: auto; }
.npan-ui-fab button {
	display: inline-flex; align-items: center; gap: 8px;
	font: inherit; font-size: 14px; font-weight: 600; line-height: 1;
	padding: 12px 16px; margin: 0; border: 0; border-radius: 999px; cursor: pointer;
	background: #fff; color: #1f2a24;
	box-shadow: 0 2px 4px rgba(0,0,0,.06), 0 10px 28px rgba(0,0,0,.14);
	transition: transform .2s ease;
}
.npan-ui-fab button:hover { transform: translateY(-2px); }
.npan-ui-fab button.npan-ui-primary { background: var(--npan-accent, #a6803a); color: #fff; }
.npan-ui-fab svg { width: 16px; height: 16px; }
@media (max-width: 640px) { .npan-ui-fab { right: 12px; bottom: 12px; } .npan-ui-fab button { padding: 11px 14px; font-size: 13px; } }
