.buch-fe-wrap {
	max-width: 520px;
	margin: 0 auto;
	font-size: 16px;
}

.buch-fe-login-status {
	font-size: 13px;
	color: #555;
	margin-bottom: 12px;
	padding: 8px 10px;
	background: #e8f0fe;
	border-radius: 6px;
}
.buch-fe-login-status a { color: #2271b1; }

.buch-fe-scan {
	margin-bottom: 18px;
}

.buch-fe-scan label {
	display: block;
	font-weight: 600;
	margin-bottom: 6px;
}

.buch-fe-barcode-row {
	display: flex;
	gap: 8px;
	align-items: center;
}

.buch-fe-barcode-row input {
	flex: 1;
	padding: 12px 14px;
	font-size: 18px;
	border: 2px solid #ccc;
	border-radius: 8px;
}

.buch-btn {
	padding: 12px 16px;
	font-size: 15px;
	font-weight: 600;
	border: none;
	border-radius: 8px;
	cursor: pointer;
	background: #2271b1;
	color: #fff;
	white-space: nowrap;
}
.buch-btn:hover { background: #135e96; }
.buch-btn:disabled { opacity: 0.6; cursor: not-allowed; }
.buch-btn.secondary {
	background: #6c757d;
}
.buch-btn.secondary:hover { background: #5a6268; }
.buch-btn.primary {
	width: 100%;
	padding: 14px;
	font-size: 16px;
	margin-top: 12px;
}

.buch-fe-status {
	margin-top: 10px;
	padding: 8px 12px;
	border-radius: 6px;
	font-size: 14px;
	min-height: 20px;
}
.buch-fe-status.loading { background: #e8f0fe; color: #1a56db; }
.buch-fe-status.success { background: #d4edda; color: #155724; }
.buch-fe-status.error { background: #f8d7da; color: #721c24; }

#buch-fe-reader {
	margin-top: 12px;
	border-radius: 8px;
	overflow: hidden;
}

.buch-fe-form {
	margin-top: 16px;
	padding: 16px;
	background: #f8f9fa;
	border-radius: 10px;
	border: 1px solid #e0e0e0;
}

.buch-fe-form label {
	display: block;
	font-weight: 600;
	margin: 10px 0 4px;
	font-size: 14px;
}

.buch-fe-form input[type="text"],
.buch-fe-form input[type="number"],
.buch-fe-form textarea {
	width: 100%;
	padding: 10px 12px;
	font-size: 15px;
	border: 1px solid #ccc;
	border-radius: 6px;
	box-sizing: border-box;
}

.buch-fe-row {
	display: flex;
	gap: 12px;
	flex-wrap: wrap;
}
.buch-fe-col {
	flex: 1;
	min-width: 100px;
}

.buch-fe-cover-preview {
	text-align: center;
	margin-bottom: 12px;
}
.buch-fe-cover-preview img {
	max-width: 140px;
	max-height: 200px;
	border-radius: 4px;
	box-shadow: 0 2px 8px rgba(0,0,0,0.12);
}

.buch-fe-more { margin-top: 12px; font-size: 14px; }
.buch-fe-more summary { cursor: pointer; color: #2271b1; padding: 6px 0; }

.buch-msg {
	padding: 12px 14px;
	border-radius: 8px;
	margin-bottom: 14px;
	font-weight: 500;
}
.buch-msg.success { background: #d4edda; color: #155724; border: 1px solid #c3e6cb; }
.buch-msg.error { background: #f8d7da; color: #721c24; border: 1px solid #f5c6cb; }

.buch-dup-box {
	background: #fff3cd;
	border: 1px solid #ffc107;
	border-radius: 8px;
	padding: 14px;
	margin-bottom: 14px;
	text-align: center;
}
.buch-dup-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	justify-content: center;
	margin-top: 10px;
}
.buch-dup-actions .buch-btn { flex: 1; min-width: 100px; }

#buch-fe-skip {
	display: none;
	width: 100%;
	margin-top: 10px;
	padding: 14px;
	font-size: 16px;
	font-weight: 600;
	background: #6c757d;
	color: #fff;
	border: none;
	border-radius: 8px;
	cursor: pointer;
	pointer-events: auto;
	position: relative;
	z-index: 20;
}
#buch-fe-skip:active {
	background: #5a6268;
}

@media (max-width: 480px) {
	.buch-fe-barcode-row {
		flex-wrap: wrap;
	}
	.buch-fe-barcode-row input {
		width: 100%;
		flex: none;
	}
}

/* Login-Formular */
.buch-bib-login {
	max-width: 360px;
	margin: 40px auto;
	padding: 28px 24px;
	background: #f8f9fa;
	border: 1px solid #e0e0e0;
	border-radius: 12px;
	text-align: center;
}
.buch-bib-login h3 {
	margin: 0 0 8px;
	font-size: 1.3em;
}
.buch-bib-login p {
	color: #555;
	margin-bottom: 16px;
}
.buch-bib-login-form label {
	display: block;
	text-align: left;
	font-weight: 600;
	margin-bottom: 4px;
	font-size: 14px;
}
.buch-bib-login-form input[type="password"] {
	width: 100%;
	padding: 12px 14px;
	font-size: 16px;
	border: 2px solid #ccc;
	border-radius: 8px;
	box-sizing: border-box;
	margin-bottom: 14px;
}
.buch-bib-login-form .buch-btn {
	width: 100%;
}

.buch-search-scan .buch-fe-barcode-row {
	display: flex;
	gap: 8px;
	align-items: center;
}
.buch-search-scan .buch-fe-barcode-row input {
	flex: 1;
	padding: 12px 14px;
	font-size: 16px;
	border: 2px solid #ccc;
	border-radius: 8px;
}
#buch-search-reader {
	margin-top: 12px;
	border-radius: 8px;
	overflow: hidden;
}

/* Kamera: flaches Fenster (~40% der früheren Höhe) */
.buch-cam-reader {
	max-height: 160px !important;
	overflow: hidden;
	border-radius: 8px;
	margin-top: 10px;
	background: #000;
}
.buch-cam-reader video,
.buch-cam-reader canvas {
	max-height: 160px !important;
	width: 100% !important;
	object-fit: cover !important;
}
/* Scan-Rahmen flacher halten */
.buch-cam-reader #qr-shaded-region {
	border-width: thin !important;
}

.buch-fe-next {
	width: 100%;
	margin-top: 12px;
	padding: 14px !important;
	font-size: 16px !important;
	font-weight: 600 !important;
	background: #6c757d !important;
	color: #fff !important;
}
.buch-fe-next:hover { background: #5a6268 !important; }

.buch-fe-photo-hint {
	font-size: 12px;
	color: #666;
	margin: 6px 0 0;
}

.buch-cam-controls {
	display: flex;
	align-items: center;
}
.buch-cam-controls .buch-btn {
	flex: 1;
	min-width: 120px;
}

.buch-dup-actions-2 {
	margin-top: 8px;
}

.buch-fe-check-label {
	display: flex;
	align-items: center;
	gap: 8px;
	font-weight: 600;
	cursor: pointer;
	margin: 0 !important;
}
.buch-fe-check-label input[type="checkbox"] {
	width: auto !important;
	margin: 0;
}

.buch-fe-form select {
	width: 100%;
	padding: 10px 12px;
	font-size: 15px;
	border: 1px solid #ccc;
	border-radius: 6px;
	box-sizing: border-box;
	background: #fff;
}

.buch-fe-price-links a {
	color: #2271b1;
	text-decoration: none;
}
.buch-fe-price-links a:hover { text-decoration: underline; }
.buch-price-hint { color: #666; margin-right: 4px; }
