/* Mitgelieferte Schrift (SIL Open Font License, siehe fonts/OFL.txt) –
   Ersatz, falls „Aptos“ (Schrift der Vorlage) nicht installiert ist. */
@font-face { font-family: 'Carlito'; src: local('Carlito'), url('fonts/Carlito-Regular.ttf') format('truetype'); font-weight: normal; font-style: normal; }
@font-face { font-family: 'Carlito'; src: local('Carlito Bold'), url('fonts/Carlito-Bold.ttf') format('truetype'); font-weight: bold; font-style: normal; }
@font-face { font-family: 'Carlito'; src: local('Carlito Italic'), url('fonts/Carlito-Italic.ttf') format('truetype'); font-weight: normal; font-style: italic; }

.nwk-app {
	--nwk-blue: #156082;
	--nwk-line: #c9d3da;
	font-family: inherit;
	max-width: 1200px;
	margin: 1.5em auto;
	color: #1d2327;
}
.nwk-app *, .nwk-app *::before, .nwk-app *::after { box-sizing: border-box; }

.nwk-toolbar {
	display: flex;
	flex-wrap: wrap;
	gap: 12px 20px;
	align-items: flex-end;
	justify-content: space-between;
	margin-bottom: 10px;
}
.nwk-fields { display: flex; flex-wrap: wrap; gap: 10px; flex: 1 1 420px; }
.nwk-field { display: flex; flex-direction: column; font-size: 13px; flex: 1 1 140px; margin: 0; }
.nwk-field span { font-weight: 600; margin-bottom: 3px; }
.nwk-app input[type="text"] {
	font: inherit;
	font-size: 15px;
	padding: 6px 9px;
	border: 1px solid #8c9aa4;
	border-radius: 4px;
	background: #fff;
	color: #1d2327;
	width: 100%;
	min-height: 36px;
	margin: 0;
}
.nwk-app input[type="text"]:focus { outline: 2px solid var(--nwk-blue); outline-offset: 1px; border-color: var(--nwk-blue); }

.nwk-buttons { display: flex; flex-wrap: wrap; gap: 6px; }
.nwk-app .nwk-btn {
	font: inherit;
	font-size: 14px;
	line-height: 1.2;
	padding: 8px 12px;
	min-height: 36px;
	border: 1px solid #8c9aa4;
	border-radius: 4px;
	background: #f6f7f7;
	color: #1d2327;
	cursor: pointer;
	text-transform: none;
	letter-spacing: normal;
	box-shadow: none;
}
.nwk-app .nwk-btn:hover { background: #e9ecee; }
.nwk-app .nwk-btn:focus-visible { outline: 2px solid var(--nwk-blue); outline-offset: 2px; }
.nwk-app .nwk-btn:disabled { opacity: .45; cursor: default; }
.nwk-app .nwk-primary { background: var(--nwk-blue); border-color: var(--nwk-blue); color: #fff; }
.nwk-app .nwk-primary:hover { background: #0f4a65; }
.nwk-app .nwk-danger { color: #a1251b; border-color: #d9a7a2; background: #fff; }
.nwk-app .nwk-danger:hover { background: #fcf0ef; }
.nwk-app .nwk-small { padding: 4px 9px; min-height: 30px; }

.nwk-hint { font-size: 13px; color: #50575e; margin: 0 0 10px; }

.nwk-sheet {
	position: relative;
	width: 100%;
	aspect-ratio: 841.92 / 595.32;
	background: #fff;
	border: 1px solid var(--nwk-line);
	box-shadow: 0 2px 10px rgba(0, 0, 0, .08);
}
.nwk-svg {
	display: block;
	width: 100%;
	height: 100%;
	cursor: crosshair;
	touch-action: none;
	user-select: none;
	-webkit-user-select: none;
}
.nwk-pt { cursor: grab; }
.nwk-pt .nwk-label { cursor: move; }
.nwk-pt:hover .nwk-dot, .nwk-active .nwk-dot { fill: var(--nwk-blue); }
.nwk-active .nwk-label { fill: var(--nwk-blue); }

.nwk-editor {
	position: absolute;
	z-index: 10;
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	width: 280px;
	max-width: calc(100% - 8px);
	padding: 8px;
	background: #fff;
	border: 1px solid #8c9aa4;
	border-radius: 6px;
	box-shadow: 0 6px 20px rgba(0, 0, 0, .18);
}
.nwk-editor[hidden] { display: none; }
.nwk-editor input[type="text"] { flex: 1 1 100%; }
.nwk-where { flex: 1 1 100%; font-size: 12px; color: #50575e; }

.nwk-listbox { margin-top: 12px; font-size: 14px; }
.nwk-listbox summary { cursor: pointer; font-weight: 600; padding: 6px 0; }
.nwk-list { margin: 6px 0 10px; padding-left: 1.6em; }
.nwk-list li { margin: 4px 0; }
.nwk-list li > * { vertical-align: middle; }
.nwk-list input[type="text"] { width: 220px !important; max-width: 50%; display: inline-block; }
.nwk-area { display: inline-block; margin: 0 8px; font-size: 12px; color: #50575e; min-width: 170px; }

@media (max-width: 600px) {
	.nwk-area { display: block; margin: 2px 0; }
	.nwk-list input[type="text"] { max-width: 75%; }
}

/* Fallback, falls jemand die ganze Seite über das Browser-Menü druckt */
@media print {
	.nwk-toolbar, .nwk-hint, .nwk-listbox, .nwk-editor { display: none !important; }
	.nwk-sheet { border: 0; box-shadow: none; }
	.nwk-svg .nwk-ui { display: none; }
	body.nwk-window { background: #fff; }
	.nwk-app.nwk-fullscreen { padding: 0; }
	.nwk-fullscreen .nwk-sheet { width: 100% !important; }
}

/* ---------- Eigenes Fenster ---------- */
body.nwk-window {
	margin: 0;
	background: #e8ecef;
	font-family: system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
}
.nwk-app.nwk-fullscreen {
	max-width: none;
	margin: 0;
	padding: 10px 16px 24px;
}
.nwk-fullscreen .nwk-toolbar { margin-bottom: 6px; }
.nwk-fullscreen .nwk-hint { margin-bottom: 8px; }
.nwk-fullscreen .nwk-sheet { margin: 0 auto; border-color: #b7c2ca; }
.nwk-fullscreen .nwk-listbox { max-width: 900px; margin-left: auto; margin-right: auto; }

/* Link im WordPress-Inhalt */
a.nwk-open-link { font-weight: 600; }
