/* PKN Feedback Button — tijdelijke acceptatiefeedback */

.pkn-feedback-root {
	--pkn-fb-accent: #e85d04;
	--pkn-fb-accent-hover: #c44f03;
	--pkn-fb-text: #1a1a1a;
	--pkn-fb-muted: #5c5c5c;
	--pkn-fb-border: #d8d8d8;
	--pkn-fb-bg: #ffffff;
	--pkn-fb-shadow: 0 4px 24px rgba(0, 0, 0, 0.15);
	--pkn-fb-radius: 8px;
	--pkn-fb-z: 99990;
	font-family: inherit;
}

.pkn-feedback-toggle {
	position: fixed;
	right: 1rem;
	bottom: 1rem;
	z-index: var(--pkn-fb-z);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	max-width: calc(100vw - 2rem);
	padding: 0.75rem 1.1rem;
	border: none;
	border-radius: 999px;
	background: var(--pkn-fb-accent);
	color: #fff;
	font-size: 0.9rem;
	font-weight: 600;
	line-height: 1.3;
	cursor: pointer;
	box-shadow: var(--pkn-fb-shadow);
	transition: background 0.15s ease, transform 0.15s ease;
}

.pkn-feedback-toggle:hover,
.pkn-feedback-toggle:focus-visible {
	background: var(--pkn-fb-accent-hover);
	outline: 2px solid #fff;
	outline-offset: 2px;
}

.pkn-feedback-toggle[aria-expanded="true"] {
	transform: translateY(-2px);
}

.pkn-feedback-panel {
	position: fixed;
	right: 1rem;
	bottom: 4.5rem;
	z-index: calc(var(--pkn-fb-z) + 1);
	width: min(22rem, calc(100vw - 2rem));
	max-height: calc(100vh - 6rem);
	overflow: auto;
	padding: 1rem 1.1rem 1.1rem;
	border-radius: var(--pkn-fb-radius);
	background: var(--pkn-fb-bg);
	color: var(--pkn-fb-text);
	box-shadow: var(--pkn-fb-shadow);
}

.pkn-feedback-panel[hidden] {
	display: none !important;
}

.pkn-feedback-panel__header {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 0.5rem;
	margin-bottom: 0.75rem;
}

.pkn-feedback-panel__title {
	margin: 0;
	font-size: 1.05rem;
	font-weight: 700;
	line-height: 1.3;
}

.pkn-feedback-panel__close {
	flex-shrink: 0;
	width: 2rem;
	height: 2rem;
	border: none;
	border-radius: 4px;
	background: transparent;
	color: var(--pkn-fb-muted);
	font-size: 1.5rem;
	line-height: 1;
	cursor: pointer;
}

.pkn-feedback-panel__close:hover,
.pkn-feedback-panel__close:focus-visible {
	background: #f2f2f2;
	color: var(--pkn-fb-text);
	outline: none;
}

.pkn-feedback-form__intro {
	margin: 0 0 0.85rem;
	font-size: 0.82rem;
	color: var(--pkn-fb-muted);
	line-height: 1.45;
}

.pkn-feedback-scope {
	margin: 0;
	padding: 0;
	border: none;
}

.pkn-feedback-scope legend {
	margin-bottom: 0.5rem;
	font-size: 0.85rem;
	font-weight: 600;
}

.pkn-feedback-scope__switch {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 0;
	padding: 3px;
	border: 1px solid var(--pkn-fb-border);
	border-radius: 999px;
	background: #f4f4f4;
}

.pkn-feedback-scope__segment {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	margin: 0;
	padding: 0.5rem 0.55rem;
	border-radius: 999px;
	font-size: 0.82rem;
	font-weight: 600;
	line-height: 1.25;
	text-align: center;
	color: var(--pkn-fb-muted);
	cursor: pointer;
	transition: color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.pkn-feedback-scope__segment input {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.pkn-feedback-scope__segment span {
	pointer-events: none;
}

.pkn-feedback-scope__segment.is-active,
.pkn-feedback-scope__segment:has(input:checked) {
	background: var(--pkn-fb-bg);
	color: var(--pkn-fb-text);
	box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12);
}

.pkn-feedback-scope__segment:has(input:focus-visible) {
	outline: 2px solid rgba(232, 93, 4, 0.45);
	outline-offset: 1px;
}

.pkn-feedback-page-context {
	margin: 0.5rem 0 0;
	padding: 0.45rem 0.55rem;
	font-size: 0.8rem;
	color: var(--pkn-fb-muted);
	background: #f8f8f8;
	border-radius: 4px;
	border-left: 3px solid var(--pkn-fb-accent);
}

.pkn-feedback-page-context.is-hidden {
	display: none;
}

.pkn-feedback-field {
	margin-bottom: 0.75rem;
}

.pkn-feedback-field label {
	display: block;
	margin-bottom: 0.3rem;
	font-size: 0.85rem;
	font-weight: 600;
}

.pkn-feedback-field .required {
	color: var(--pkn-fb-accent);
}

.pkn-feedback-field input,
.pkn-feedback-field select,
.pkn-feedback-field textarea {
	width: 100%;
	padding: 0.5rem 0.6rem;
	border: 1px solid var(--pkn-fb-border);
	border-radius: 4px;
	background: #fff;
	color: var(--pkn-fb-text);
	font: inherit;
	font-size: 0.9rem;
	box-sizing: border-box;
}

.pkn-feedback-field textarea {
	resize: vertical;
	min-height: 5rem;
}

.pkn-feedback-field input:focus,
.pkn-feedback-field select:focus,
.pkn-feedback-field textarea:focus {
	border-color: var(--pkn-fb-accent);
	outline: 2px solid rgba(232, 93, 4, 0.2);
	outline-offset: 0;
}

.pkn-feedback-honeypot {
	position: absolute;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
	opacity: 0;
	pointer-events: none;
}

.pkn-feedback-status {
	margin: 0 0 0.75rem;
	padding: 0.55rem 0.65rem;
	border-radius: 4px;
	font-size: 0.85rem;
	line-height: 1.4;
}

.pkn-feedback-status[hidden] {
	display: none !important;
}

.pkn-feedback-status.is-success {
	background: #e8f5e9;
	color: #1b5e20;
}

.pkn-feedback-status.is-error {
	background: #fdecea;
	color: #b71c1c;
}

.pkn-feedback-actions {
	display: flex;
	justify-content: flex-end;
}

.pkn-feedback-submit {
	padding: 0.55rem 1rem;
	border: none;
	border-radius: 4px;
	background: var(--pkn-fb-accent);
	color: #fff;
	font: inherit;
	font-size: 0.9rem;
	font-weight: 600;
	cursor: pointer;
}

.pkn-feedback-submit:hover:not(:disabled),
.pkn-feedback-submit:focus-visible:not(:disabled) {
	background: var(--pkn-fb-accent-hover);
	outline: 2px solid rgba(232, 93, 4, 0.35);
	outline-offset: 2px;
}

.pkn-feedback-submit:disabled {
	opacity: 0.65;
	cursor: not-allowed;
}

@media (max-width: 480px) {
	.pkn-feedback-toggle {
		right: 0.75rem;
		bottom: 0.75rem;
		font-size: 0.82rem;
		padding: 0.65rem 0.9rem;
	}

	.pkn-feedback-panel {
		right: 0.75rem;
		bottom: 4rem;
		width: calc(100vw - 1.5rem);
	}
}
