/* ============================================
   Dienstleistungen Admin Styles
   Basierend auf Quote Requests Modal Design & Tischreservierungen-Pro
   ============================================ */

/* Wrap Container */
.simpbook-admin-wrap {
	max-width: 90% !important;
	margin-right: 10px !important;
}

.simpbook-admin-wrap h1 {
	font-size: 28px !important;
	font-weight: 600 !important;
	color: #1d2327 !important;
	margin-bottom: 24px !important;
	padding-bottom: 12px !important;
	border-bottom: 3px solid #28a745 !important;
}

/* ============================================
   Heading Styles
   ============================================ */
.wrap h1.wp-heading-inline {
    display: inline-block;
    margin-right: 5px;
    margin-left: 10px;
}

/* ============================================
   View Toggle Button
   ============================================ */
.view-toggle-container {
	display: flex !important;
	justify-content: space-between !important; 
	justify-content: flex-start;
	align-items: center;
	gap: 10px;
	margin-top: 10px;
	margin-bottom: 15px;
}

.view-toggle-container #add-new-service-btn {
	flex-shrink: 0;
	order: 1;
}

.view-toggle-container .reservierungen-search-container {
	order: 2;
}

.view-toggle-container #toggle-view-btn {
	flex-shrink: 0;
	order: 3;
}

/* ============================================
   Suchfeld Styling
   ============================================ */
.reservierungen-search-container {
	position: relative;
	display: flex;
	align-items: center;
	flex: 1;
	max-width: 400px;
}

.reservierungen-search-container .dashicons-search {
	position: absolute;
	left: 12px;
	color: #8c8f94;
	font-size: 18px;
	pointer-events: none;
	z-index: 1;
}

#dienstleistungen-search-input {
	width: 100%;
	padding: 8px 35px 8px 38px;
	border: 1px solid #8c8f94;
	border-radius: 4px;
	font-size: 14px;
	transition: all 0.2s ease;
	background-color: #fff;
}

#dienstleistungen-search-input:focus {
	border-color: #2271b1;
	box-shadow: 0 0 0 1px #2271b1;
	outline: none;
}

#dienstleistungen-search-input::placeholder {
	color: #8c8f94;
}

#clear-search-btn-dienstleistungen {
	position: absolute;
	right: 8px;
	background: none;
	border: none;
	color: #8c8f94;
	cursor: pointer;
	padding: 4px;
	font-size: 16px;
	transition: color 0.2s ease;
	z-index: 1;
}

#clear-search-btn-dienstleistungen:hover {
	color: #d63638;
}

#clear-search-btn-dienstleistungen:focus {
	outline: none;
	color: #2271b1;
}

#add-new-service-btn.page-title-action {
	display: inline-flex !important;
	visibility: visible !important;
    position: static !important;
    margin: 0 !important;
}

#toggle-view-btn {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	padding: 8px 16px;
	font-weight: 500;
	transition: all 0.2s ease;
	border-radius: 4px;
}

#toggle-view-btn:hover {
	background-color: #2271b1;
	color: white;
	border-color: #2271b1;
}

/* Toggle-Button unter 1200px ausblenden, Container sichtbar lassen */
@media screen and (max-width: 1199px) {
	.view-toggle-container {
		display: flex !important;
	}
	
	#toggle-view-btn {
		display: none !important;
	}
}

/* Mobile: Container anpassen */
@media screen and (max-width: 782px) {
	.view-toggle-container {
		flex-direction: column;
		align-items: center;
		gap: 10px;
		margin-bottom: 0px;
	}
}

/* ============================================
   Tabellen Styles
   ============================================ */

.simpbook-admin-wrap .wp-list-table {
	background: #fff !important;
	border-radius: 8px !important;
	overflow: hidden !important;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05) !important;
	border: 2px solid #667eea !important;
	margin-top: 20px !important;
	width: 100% !important;
	border-collapse: separate !important;
	border-spacing: 0 !important;
}

.simpbook-admin-wrap .wp-list-table thead {
	background: linear-gradient(to bottom, #f8f9fa 0%, #e9ecef 100%) !important;
}

.simpbook-admin-wrap .wp-list-table thead th {
	padding: 16px 12px !important;
	font-weight: 600 !important;
	color: #333 !important;
	font-size: 14px !important;
	border-bottom: 2px solid #28a745 !important;
	text-align: left !important;
	border-top: none !important;
	border-left: none !important;
	border-right: none !important;
}

.simpbook-admin-wrap .wp-list-table thead th:first-child {
	border-left: none !important;
}

.simpbook-admin-wrap .wp-list-table thead th:last-child {
	border-right: none !important;
}

.simpbook-admin-wrap .wp-list-table thead th a {
	color: #333 !important;
	text-decoration: none !important;
	transition: color 0.2s !important;
}

.simpbook-admin-wrap .wp-list-table thead th a:hover {
	color: #28a745 !important;
}

.simpbook-admin-wrap .wp-list-table tbody tr {
	transition: background-color 0.2s !important;
	cursor: pointer !important;
}

.simpbook-admin-wrap .wp-list-table tbody tr:hover {
	background-color: #f0f0f1 !important;
}

.simpbook-admin-wrap .wp-list-table tbody td {
	padding: 14px 12px !important;
	font-size: 14px !important;
	color: #555 !important;
	border-bottom: 1px solid #e8e8e8 !important;
	vertical-align: middle !important;
}

.simpbook-admin-wrap .wp-list-table tbody tr:last-child td {
	border-bottom: none !important;
}

.simpbook-admin-wrap .wp-list-table tbody td a {
	color: #0073aa !important;
	text-decoration: none !important;
	transition: color 0.2s !important;
}

.simpbook-admin-wrap .wp-list-table tbody td a:hover {
	color: #005177 !important;
	text-decoration: underline !important;
}

.simpbook-admin-wrap .wp-list-table tbody td strong {
	color: #1d2327 !important;
	font-weight: 600 !important;
}

/* WordPress Core CSS Überschreibung - Verhindert width: auto !important von WP Core */
.simpbook-admin-wrap .wp-list-table.widefat tr:not(.inline-edit-row):not(.no-items) td:not(.check-column),
.simpbook-admin-wrap .wp-list-table tr:not(.inline-edit-row):not(.no-items) td:not(.check-column) {
	position: relative !important;
	width: inherit !important;
	min-width: inherit !important;
}

/* Globale Spaltenbreiten */
.simpbook-admin-wrap .wp-list-table thead th,
.simpbook-admin-wrap .wp-list-table tbody td {
	min-width: 100px !important;
}

/* Bild-Spalte in der Tabelle (1. Spalte) */
.simpbook-admin-wrap .wp-list-table thead th:nth-child(1),
.simpbook-admin-wrap .wp-list-table tbody td:nth-child(1) {
	width: 5% !important;
	text-align: left !important;
	padding: 8px !important;
}

.simpbook-admin-wrap .wp-list-table tbody td:nth-child(1) img {
	border-radius: 4px;
}

/* Pufferzeit-Spalte (4. Spalte) */
.simpbook-admin-wrap .wp-list-table thead th:nth-child(4),
.simpbook-admin-wrap .wp-list-table tbody td:nth-child(4) {
	width: 10% !important;
}

/* Spezifische Spaltenbreiten für Dienstleistungen - Hohe Spezifität gegen WordPress-Standard-Styles */
.simpbook-admin-wrap .wp-list-table.widefat thead th:nth-child(1),
.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(1) {
	width: 5% !important;
	min-width: 50px !important;
}

.simpbook-admin-wrap .wp-list-table.widefat thead th:nth-child(2),
.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(2) {
	width: 20% !important;
	min-width: 150px !important;
}

.simpbook-admin-wrap .wp-list-table.widefat thead th:nth-child(3),
.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(3) {
	width: 12% !important;
	min-width: 100px !important;
}

.simpbook-admin-wrap .wp-list-table.widefat thead th:nth-child(4),
.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(4) {
	width: 12% !important;
	min-width: 100px !important;
}

.simpbook-admin-wrap .wp-list-table.widefat thead th:nth-child(5),
.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(5) {
	width: 26% !important;
	min-width: 200px !important;
}

/* Child-Elemente in der 5. Spalte (Beschreibung) auf 100% Breite */
.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(5) > * {
	width: 100% !important;
	max-width: 100% !important;
}

.simpbook-admin-wrap .wp-list-table.widefat thead th:nth-child(6),
.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(6) {
	width: 10% !important;
	min-width: 80px !important;
}

.simpbook-admin-wrap .wp-list-table.widefat thead th:nth-child(7),
.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(7) {
	width: 15% !important;
	min-width: 150px !important;
	white-space: nowrap !important;
}

/* ============================================
   Formular Styles
   ============================================ */

.simpbook-admin-wrap .form-table {
	background: #fff !important;
	border-radius: 8px !important;
	padding: 24px !important;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05) !important;
	margin-top: 20px !important;
}

.simpbook-admin-wrap .form-table tr {
	border-bottom: 1px solid #e8e8e8 !important;
	transition: background-color 0.2s !important;
}

.simpbook-admin-wrap .form-table tr:last-child {
	border-bottom: none !important;
}

.simpbook-admin-wrap .form-table tr:hover {
	background-color: #f8f9fa !important;
}

.simpbook-admin-wrap .form-table th {
	padding: 18px 12px !important;
	font-weight: 600 !important;
	color: #555 !important;
	font-size: 14px !important;
	width: 200px !important;
	vertical-align: middle !important;
}

.simpbook-admin-wrap .form-table td {
	padding: 18px 12px !important;
	vertical-align: middle !important;
}

.simpbook-admin-wrap .form-table input[type="text"],
.simpbook-admin-wrap .form-table input[type="number"],
.simpbook-admin-wrap .form-table input[type="email"],
.simpbook-admin-wrap .form-table textarea,
.simpbook-admin-wrap .form-table select {
	width: 100% !important;
	max-width: 400px !important;
	padding: 10px 14px !important;
	border: 1px solid #ddd !important;
	border-radius: 4px !important;
	font-size: 14px !important;
	transition: all 0.2s !important;
	background: #fff !important;
}

.simpbook-admin-wrap .form-table input[type="text"]:focus,
.simpbook-admin-wrap .form-table input[type="number"]:focus,
.simpbook-admin-wrap .form-table input[type="email"]:focus,
.simpbook-admin-wrap .form-table textarea:focus,
.simpbook-admin-wrap .form-table select:focus {
	outline: none !important;
	border-color: #28a745 !important;
	box-shadow: 0 0 0 2px rgba(40, 167, 69, 0.2) !important;
}

.simpbook-admin-wrap .form-table .description {
	margin-top: 8px !important;
	font-size: 13px !important;
	color: #666 !important;
	font-style: italic !important;
	display: block !important;
}

/* ============================================
   Mobile/Tablet Kartenansicht
   ============================================ */

/* Desktop-Tabelle - wird standardmäßig versteckt */
.desktop-dienstleistungen-tabelle {
	display: none;
	width: 100%;
	margin-bottom: 20px;
}

.desktop-dienstleistungen-tabelle.active {
	display: block;
}

/* Kategorie-Badge in Tabellenansicht */
.simpbook-kategorie-badge {
    display: inline-block;
    background: #2271b1;
    color: #fff;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

/* Mobile/Tablet Kartenansicht - wird standardmäßig angezeigt */
.mobile-dienstleistungen-karten {
	display: flex;
	flex-direction: column;
	gap: 15px;
}

/* Kategorie-Header in Kartenansicht */
.dienstleistung-kategorie-header {
    margin-top: 10px;
    margin-bottom: 5px;
}

.dienstleistung-kategorie-header h3 {
    font-size: 18px;
    font-weight: 600;
    color: #1d2327;
    margin: 0;
    padding-bottom: 8px;
    border-bottom: 2px solid #2271b1;
    display: inline-block;
}

/* Karten-Gruppe */
.dienstleistung-karten-gruppe {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 20px;
}

/* 5 Kacheln: Standard für alle Desktop-Screens */
.dienstleistung-karten-gruppe .dienstleistung-karte {
    flex: 0 0 calc(20% - 8px);
    max-width: 250px;
    min-width: 0;
    box-sizing: border-box;
}

/* 3 Kacheln ab Tablet */
@media (max-width: 1100px) {
    .dienstleistung-karten-gruppe .dienstleistung-karte {
        flex: 0 0 calc(33.333% - 7px);
        max-width: calc(33.333% - 7px);
    }
}

@media (max-width: 750px) {
    .dienstleistung-karten-gruppe .dienstleistung-karte {
        flex: 0 0 calc(50% - 5px);
        max-width: calc(50% - 5px);
    }
}

@media (max-width: 600px) {
    .dienstleistung-karten-gruppe .dienstleistung-karte {
        flex: 0 0 100%;
        max-width: 100%;
    }
}

.mobile-dienstleistungen-karten.hidden {
	display: none;
}

.dienstleistung-karte {
	background: #fff;
	border: 1px solid #b3bce3;
	border-radius: 8px;
	overflow: hidden;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
	cursor: pointer;
	transition: all 0.3s ease;
	display: flex;
	flex-direction: column;
	position: relative;
	touch-action: none;
	-webkit-user-select: none;
	-moz-user-select: none;
	-ms-user-select: none;
	user-select: none;
}

.dienstleistung-karte:hover {
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
	transform: translateY(-2px);
}

.ui-sortable-helper {
	transition: none !important;
	transform: none !important;
}

/* Karte Action-Buttons (Drag + Duplizieren) */
.simpbook-karte-actions {
	position: absolute;
	top: 8px;
	right: 8px;
	z-index: 10;
	display: flex;
	gap: 5px;
}

.simpbook-drag-handle,
.simpbook-duplicate-btn {
	width: 34px;
	height: 34px;
	padding: 0;
	background: rgba(255, 255, 255, 0.88);
	border: 1px solid #ccd1df;
	border-radius: 5px;
	display: flex;
	align-items: center;
	justify-content: center;
	color: #6b7280;
	transition: background 0.18s, color 0.18s, border-color 0.18s;
	outline: none;
	box-shadow: 0 1px 3px rgba(0,0,0,0.10);
}

.simpbook-drag-handle {
	cursor: grab;
}

.simpbook-duplicate-btn {
	cursor: pointer;
}

.simpbook-drag-handle:hover,
.simpbook-duplicate-btn:hover {
	background: #2271b1;
	color: #fff;
	border-color: #2271b1;
}

.simpbook-drag-handle:active,
.ui-sortable-helper .simpbook-drag-handle {
	cursor: grabbing;
	background: #135e96;
	color: #fff;
	border-color: #135e96;
}

.simpbook-duplicate-btn:active {
	background: #135e96;
	color: #fff;
	border-color: #135e96;
}

.simpbook-drag-handle .dashicons,
.simpbook-duplicate-btn .dashicons {
	font-size: 20px;
	width: 20px;
	height: 20px;
	line-height: 20px;
}

/* Placeholder while dragging */
.simpbook-sortable-placeholder {
	background: #eef3fc !important;
	border: 2px dashed #2271b1 !important;
	border-radius: 8px !important;
	visibility: visible !important;
	opacity: 1 !important;
	flex: 0 0 calc(20% - 8px) !important;
	max-width: calc(20% - 8px) !important;
	min-width: 0 !important;
	min-height: 180px !important;
	box-sizing: border-box !important;
}

@media (max-width: 1100px) {
    .simpbook-sortable-placeholder {
        flex: 0 0 calc(33.333% - 7px) !important;
        max-width: calc(33.333% - 7px) !important;
    }
}

@media (max-width: 750px) {
    .simpbook-sortable-placeholder {
        flex: 0 0 calc(50% - 5px) !important;
        max-width: calc(50% - 5px) !important;
    }
}

@media (max-width: 600px) {
    .simpbook-sortable-placeholder {
        flex: 0 0 100% !important;
        max-width: 100% !important;
    }
}

/* Dragged card gets extra shadow */
.dienstleistung-karten-gruppe .ui-sortable-helper {
	box-shadow: 0 8px 24px rgba(0,0,0,0.20) !important;
	transform: rotate(1.5deg) scale(1.02);
}

.dienstleistung-karte-header {
	padding: 16px;
	background: #f8f9fa;
	border-bottom: 1px solid #e0e0e0;
}

.dienstleistung-id {
	font-size: 13px;
	color: #666;
	font-weight: 500;
}

.dienstleistung-karte-bild {
	width: 100%;
	height: 50%;
	background: #f5f5f5;
	overflow: hidden;
	display: flex;
	align-items: center;
	justify-content: center;
}

.dienstleistung-karte-bild img {
	max-width: 100%;
	max-height: 100%;
	object-fit: contain;
}

.dienstleistung-karte-body {
	padding: 10px;
	flex: 1;
	display: flex;
	flex-direction: column;
	gap: 4px;
	overflow: hidden;
}

.dienstleistung-name {
	font-size: 14px;
	font-weight: 600;
	color: #1d2327;
	margin-bottom: 8px;
}

.dienstleistung-info-gruppe {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.dienstleistung-info-zeile {
	display: flex;
	justify-content: space-between;
	font-size: 14px;
	padding: 6px 0;
	border-bottom: 1px solid #f0f0f0;
}

.dienstleistung-info-zeile:last-child {
	border-bottom: none;
}

.info-label {
	font-weight: 600;
	color: #666;
	margin-right: 8px;
}

.info-value {
	color: #333;
	text-align: right;
}

/* ============================================
   Modal Styles (von backend-style_vorlage.css)
   ============================================ */

/* Modal Overlay */
.simpbook-modal {
	display: none !important;
	position: fixed !important;
	top: 0 !important;
	left: 0 !important;
	width: 100% !important;
	height: 100% !important;
	z-index: 100000 !important;
}

.simpbook-modal.active {
	display: block !important;
}

.simpbook-modal-overlay {
	position: absolute !important;
	top: 0 !important;
	left: 0 !important;
	width: 100% !important;
	height: 100% !important;
	background: rgba(0, 0, 0, 0.7) !important;
	backdrop-filter: blur(2px) !important;
}

.simpbook-modal-container {
	position: relative !important;
	width: 100% !important;
	height: 100% !important;
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	padding: 20px !important;
	box-sizing: border-box !important;
	overflow-y: auto !important;
}

/* Modal Content */
.simpbook-modal-container > div {
	position: relative !important;
	background: #fff !important;
	border-radius: 8px !important;
	box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3) !important;
	max-width: 1100px !important;
	width: 100% !important;
	max-height: 90vh !important;
	display: flex !important;
	flex-direction: column !important;
	z-index: 1 !important;
}

.simpbook-modal-body {
	padding: 32px !important;
	overflow-y: auto !important;
	flex: 1 !important;
}

.simpbook-loading {
	text-align: center !important;
	padding: 40px !important;
}

.simpbook-loading p {
	font-size: 16px !important;
	color: #666 !important;
}

/* Details Grid */
.simpbook-details-grid {
	display: grid !important;
	grid-template-columns: repeat(3, 1fr) !important;
	gap: 20px !important;
	margin-bottom: 32px !important;
}

.simpbook-details-section {
	background: linear-gradient(to bottom, #ffffff 0%, #f8f9fa 100%) !important;
	padding: 20px !important;
	border-radius: 8px !important;
	border: 2px solid #667eea !important;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05) !important;
	transition: box-shadow 0.2s !important;
}

.simpbook-details-section:hover {
	box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1) !important;
}

.simpbook-details-section h3 {
	margin: 0 0 18px 0 !important;
	font-size: 16px !important;
	font-weight: 600 !important;
	color: #333 !important;
	border-bottom: 3px solid #28a745 !important;
	padding-bottom: 10px !important;
}

.simpbook-detail-row {
	display: flex !important;
	justify-content: space-between !important;
	align-items: flex-start !important;
	padding: 12px 0 !important;
	border-bottom: 1px solid #e8e8e8 !important;
}

.simpbook-detail-row:last-child {
	border-bottom: none !important;
}

.simpbook-detail-row strong {
	flex: 0 0 45% !important;
	color: #555 !important;
	font-weight: 600 !important;
	font-size: 14px !important;
}

.simpbook-detail-row span,
.simpbook-detail-row a {
	flex: 1 !important;
	text-align: right !important;
	color: #333 !important;
	font-size: 14px !important;
}

.simpbook-detail-row a {
	color: #0073aa !important;
	text-decoration: none !important;
}

.simpbook-detail-row a:hover {
	text-decoration: underline !important;
}

/* Form Elements */
.simpbook-select {
	width: 100% !important;
	padding: 8px 12px !important;
	border: 1px solid #ddd !important;
	border-radius: 4px !important;
	font-size: 14px !important;
	background: #fff !important;
	cursor: pointer !important;
}

.simpbook-select:focus {
	outline: none !important;
	border-color: #28a745 !important;
	box-shadow: 0 0 0 2px rgba(40, 167, 69, 0.2) !important;
}

/* Modal Actions */
.simpbook-modal-actions {
	display: flex !important;
	gap: 12px !important;
	justify-content: flex-end !important;
	padding: 24px 0 0 0 !important;
	border-top: 2px solid #e8e8e8 !important;
	margin-top: 8px !important;
}

.simpbook-modal-actions .button {
	padding: 10px 24px !important;
	font-size: 14px !important;
	font-weight: 600 !important;
	border-radius: 4px !important;
	transition: all 0.2s !important;
}

.simpbook-modal-actions .button-primary {
	background: #28a745 !important;
	border-color: #28a745 !important;
}

.simpbook-modal-actions .button-primary:hover {
	background: #218838 !important;
	border-color: #1e7e34 !important;
}

/* Body Lock when modal open */
body.simpbook-modal-open {
	overflow: hidden !important;
}

/* ============================================
   Status Badges & Action Buttons
   ============================================ */

.simpbook-admin-wrap .status-aktiv {
	color: #46b450 !important;
	font-weight: 600 !important;
}

.simpbook-admin-wrap .status-inaktiv {
	color: #dc3232 !important;
	font-weight: 600 !important;
}

/* ============================================
   Aktionen Buttons
   ============================================ */

/* Aktionen-Spalte - Container für Buttons */
.simpbook-admin-wrap .wp-list-table.widefat tbody td:last-child,
.simpbook-admin-wrap .wp-list-table tbody td:last-child {
	white-space: normal !important;
}

/* Button-Small Styles mit !important */
.simpbook-admin-wrap .wp-list-table.widefat tbody td .button.button-small,
.simpbook-admin-wrap .wp-list-table tbody td .button.button-small {
	display: inline-block !important;
	margin: 2px 4px 2px 0 !important;
	padding: 6px 12px !important;
	font-size: 13px !important;
	line-height: 1.4 !important;
	height: auto !important;
	min-height: auto !important;
	text-decoration: none !important;
	border: 1px solid #ccc !important;
	border-radius: 4px !important;
	background: #f7f7f7 !important;
	color: #555 !important;
	transition: all 0.2s !important;
	white-space: nowrap !important;
	vertical-align: middle !important;
	box-sizing: border-box !important;
}

.simpbook-admin-wrap .wp-list-table.widefat tbody td .button.button-small:hover,
.simpbook-admin-wrap .wp-list-table tbody td .button.button-small:hover {
	background: #fafafa !important;
	border-color: #999 !important;
	color: #23282d !important;
}

.simpbook-admin-wrap .wp-list-table.widefat tbody td .button.button-small.button-primary,
.simpbook-admin-wrap .wp-list-table tbody td .button.button-small.button-primary {
	background: #2271b1 !important;
	border-color: #2271b1 !important;
	color: #fff !important;
}

.simpbook-admin-wrap .wp-list-table.widefat tbody td .button.button-small.button-primary:hover,
.simpbook-admin-wrap .wp-list-table tbody td .button.button-small.button-primary:hover {
	background: #135e96 !important;
	border-color: #135e96 !important;
	color: #fff !important;
}

/* Button-Link-Delete Styles mit !important */
.simpbook-admin-wrap .button-link-delete,
.simpbook-admin-wrap .wp-list-table.widefat tbody td .button.button-small.button-link-delete,
.simpbook-admin-wrap .wp-list-table tbody td .button.button-small.button-link-delete {
	color: #b32d2e !important;
	text-decoration: none !important;
	padding: 6px 12px !important;
	border-radius: 4px !important;
	transition: all 0.2s !important;
	background: #f7f7f7 !important;
	border: 1px solid #dc3232 !important;
	display: inline-block !important;
	margin: 2px 4px 2px 0 !important;
	font-size: 13px !important;
	line-height: 1.4 !important;
	white-space: nowrap !important;
	vertical-align: middle !important;
	box-sizing: border-box !important;
}

.simpbook-admin-wrap .button-link-delete:hover,
.simpbook-admin-wrap .wp-list-table.widefat tbody td .button.button-small.button-link-delete:hover,
.simpbook-admin-wrap .wp-list-table tbody td .button.button-small.button-link-delete:hover {
	background: #dc3545 !important;
	color: #fff !important;
	border-color: #dc3545 !important;
}

/* ============================================
   Responsive Design
   ============================================ */

/* Tablet */
@media screen and (max-width: 1200px) {
	.simpbook-admin-wrap {
		max-width: 95% !important;
	}
	
	/* Toggle-Buttons auf Tablet ausblenden */
	
	/* Tabellen als gestapelte Cards - Spezifisch für .widefat */
	.simpbook-admin-wrap .wp-list-table.widefat {
		width: 100% !important;
		max-width: 100% !important;
		display: block !important;
		border: none !important;
		box-shadow: none !important;
		background: transparent !important;
		margin-top: 20px !important;
	}
	
	/* Tabellen als gestapelte Cards - Fallback für andere Tabellen */
	.simpbook-admin-wrap .wp-list-table {
		display: block !important;
		border: none !important;
		box-shadow: none !important;
		background: transparent !important;
		margin-top: 20px !important;
	}
	
	.simpbook-admin-wrap .wp-list-table.widefat thead,
	.simpbook-admin-wrap .wp-list-table thead {
		display: none !important;
	}
	
	.simpbook-admin-wrap .wp-list-table.widefat tbody,
	.simpbook-admin-wrap .wp-list-table tbody {
		display: block !important;
		width: 100% !important;
		max-width: 100% !important;
	}
	
	.simpbook-admin-wrap .wp-list-table.widefat tbody tr,
	.simpbook-admin-wrap .wp-list-table tbody tr {
		display: block !important;
		background: #fff !important;
		border: 1px solid #e8e8e8 !important;
		border-radius: 8px !important;
		margin-bottom: 16px !important;
		padding: 0 !important;
		box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05) !important;
		cursor: pointer !important;
		transition: all 0.2s !important;
		overflow: hidden !important;
		width: 100% !important;
		max-width: 100% !important;
	}
	
	.simpbook-admin-wrap .wp-list-table.widefat tbody tr:hover,
	.simpbook-admin-wrap .wp-list-table tbody tr:hover {
		box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1) !important;
		transform: translateY(-2px) !important;
	}
	
	.simpbook-admin-wrap .wp-list-table.widefat tbody tr:last-child,
	.simpbook-admin-wrap .wp-list-table tbody tr:last-child {
		margin-bottom: 0 !important;
	}
	
	.simpbook-admin-wrap .wp-list-table.widefat tbody td,
	.simpbook-admin-wrap .wp-list-table tbody td {
		display: flex !important;
		align-items: center !important;
		width: 100% !important;
		max-width: 100% !important;
		padding: 12px 16px !important;
		border: none !important;
		text-align: left !important;
		font-size: 14px !important;
		border-bottom: 1px solid #e8e8e8 !important;
		gap: 10px !important;
	}
	
	/* Inhalt nimmt den Rest des Platzes ein */
	.simpbook-admin-wrap .wp-list-table.widefat tbody td > *,
	.simpbook-admin-wrap .wp-list-table tbody td > * {
		flex: 1 !important;
	}
	
	/* Aktionen-Spalte auf Tablet - Buttons in einer Zeile */
	.simpbook-admin-wrap .wp-list-table.widefat tbody td:last-child,
	.simpbook-admin-wrap .wp-list-table tbody td:last-child {
		flex-wrap: wrap !important;
		gap: 8px !important;
	}
	
	.simpbook-admin-wrap .wp-list-table.widefat tbody td:last-child .button.button-small,
	.simpbook-admin-wrap .wp-list-table tbody td:last-child .button.button-small {
		flex: 0 0 auto !important;
		margin: 0 !important;
	}
	
	/* Spaltenbreiten auf Tablet/Mobile zurücksetzen */
	.simpbook-admin-wrap .wp-list-table.widefat thead th:nth-child(1),
	.simpbook-admin-wrap .wp-list-table.widefat thead th:nth-child(2),
	.simpbook-admin-wrap .wp-list-table.widefat thead th:nth-child(3),
	.simpbook-admin-wrap .wp-list-table.widefat thead th:nth-child(4),
	.simpbook-admin-wrap .wp-list-table.widefat thead th:nth-child(5),
	.simpbook-admin-wrap .wp-list-table.widefat thead th:nth-child(6),
	.simpbook-admin-wrap .wp-list-table.widefat thead th:nth-child(7),
	.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(1),
	.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(2),
	.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(3),
	.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(4),
	.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(5),
	.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(6),
	.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(7) {
		width: 100% !important;
		min-width: 100% !important;
		max-width: 100% !important;
	}
	
	.simpbook-admin-wrap .wp-list-table.widefat tbody td:last-child,
	.simpbook-admin-wrap .wp-list-table tbody td:last-child {
		border-bottom: none !important;
	}
	
	.simpbook-admin-wrap .wp-list-table.widefat tbody td:before,
	.simpbook-admin-wrap .wp-list-table tbody td:before {
		content: attr(data-label) ":" !important;
		font-weight: 600 !important;
		display: inline-block !important;
		flex-shrink: 0 !important;
		min-width: 120px !important;
		max-width: 150px !important;
		color: #23282d !important;
		margin: 0 !important;
		padding: 0 !important;
		border: none !important;
	}
	
	/* Modal Responsive */
	.simpbook-modal-container {
		padding: 10px !important;
	}
	
	.simpbook-modal-container > div {
		max-width: 95% !important;
		max-height: 95vh !important;
	}
	
	.simpbook-details-grid {
		grid-template-columns: 1fr !important;
		gap: 16px !important;
	}
	
	.simpbook-modal-body {
		padding: 20px !important;
	}
	
	.simpbook-modal-actions {
		flex-direction: column !important;
	}
	
	.simpbook-modal-actions .button {
		width: 100% !important;
	}
	
	/* Formular Responsive */
	.simpbook-admin-wrap .form-table {
		padding: 20px 15px !important;
	}
	
	.simpbook-admin-wrap .form-table th,
	.simpbook-admin-wrap .form-table td {
		display: block !important;
		width: 100% !important;
		padding: 10px 15px !important;
		box-sizing: border-box !important;
	}
	
	.simpbook-admin-wrap .form-table th {
		padding-bottom: 5px !important;
		padding-top: 15px !important;
	}
	
	.simpbook-admin-wrap .form-table td {
		padding-top: 5px !important;
		padding-bottom: 15px !important;
	}
}

/* Mobile */
@media screen and (max-width: 782px) {
	.simpbook-admin-wrap {
		max-width: 100% !important;
	}
	
	/* Tabellen auf Mobile - 100% Breite */
	.simpbook-admin-wrap .wp-list-table.widefat {
		width: 100% !important;
		max-width: 100% !important;
	}
	
	.simpbook-admin-wrap .form-table {
		padding: 16px !important;
	}
	
	.simpbook-admin-wrap .form-table input[type="text"],
	.simpbook-admin-wrap .form-table input[type="number"],
	.simpbook-admin-wrap .form-table input[type="email"],
	.simpbook-admin-wrap .form-table textarea,
	.simpbook-admin-wrap .form-table select {
		max-width: 100% !important;
	}
	
	.simpbook-admin-wrap .wp-list-table.widefat tbody td,
	.simpbook-admin-wrap .wp-list-table tbody td {
		display: block !important;
		flex-direction: column !important;
		align-items: flex-start !important;
		line-height: 1.6 !important;
		width: 100% !important;
		max-width: 100% !important;
		gap: 0 !important;
	}
	
	/* Mobile: Label über dem Inhalt */
	.simpbook-admin-wrap .wp-list-table.widefat tbody td:before,
	.simpbook-admin-wrap .wp-list-table tbody td:before {
		content: attr(data-label) ":" !important;
		display: block !important;
		width: 100% !important;
		margin-bottom: 8px !important;
		margin-top: 0 !important;
		padding-bottom: 8px !important;
		border-bottom: 1px solid #e8e8e8 !important;
		min-width: auto !important;
		max-width: 100% !important;
		font-weight: 600 !important;
		color: #23282d !important;
		flex-shrink: 0 !important;
	}
	
	/* Mobile: Inhalt unter dem Label */
	.simpbook-admin-wrap .wp-list-table.widefat tbody td > *,
	.simpbook-admin-wrap .wp-list-table tbody td > * {
		display: block !important;
		flex: none !important;
		width: 100% !important;
		margin-top: 0 !important;
		padding-top: 0 !important;
	}
	
	/* Mobile: Aktionen-Buttons */
	.simpbook-admin-wrap .wp-list-table.widefat tbody td:last-child .button.button-small,
	.simpbook-admin-wrap .wp-list-table tbody td:last-child .button.button-small {
		display: inline-block !important;
		margin: 4px 4px 4px 0 !important;
		width: auto !important;
		max-width: 100% !important;
	}
	
	/* Spaltenbreiten auf Mobile zurücksetzen */
	.simpbook-admin-wrap .wp-list-table.widefat thead th:nth-child(1),
	.simpbook-admin-wrap .wp-list-table.widefat thead th:nth-child(2),
	.simpbook-admin-wrap .wp-list-table.widefat thead th:nth-child(3),
	.simpbook-admin-wrap .wp-list-table.widefat thead th:nth-child(4),
	.simpbook-admin-wrap .wp-list-table.widefat thead th:nth-child(5),
	.simpbook-admin-wrap .wp-list-table.widefat thead th:nth-child(6),
	.simpbook-admin-wrap .wp-list-table.widefat thead th:nth-child(7),
	.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(1),
	.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(2),
	.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(3),
	.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(4),
	.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(5),
	.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(6),
	.simpbook-admin-wrap .wp-list-table.widefat tbody td:nth-child(7) {
		width: 100% !important;
		min-width: 100% !important;
		max-width: 100% !important;
	}
	
	/* Modal Mobile */
	.simpbook-modal-container {
		padding: 0 !important;
	}
	
	.simpbook-modal-container > div {
		max-width: 100% !important;
		max-height: 100vh !important;
		border-radius: 0 !important;
		height: 100vh !important;
	}
	
	.simpbook-modal-body {
		padding: 16px !important;
	}
	
	.simpbook-details-section {
		padding: 12px !important;
	}
	
	.simpbook-detail-row {
		flex-direction: column !important;
		padding: 8px 0 !important;
	}
	
	.simpbook-detail-row strong {
		flex: 1 !important;
		margin-bottom: 4px !important;
	}
	
	.simpbook-detail-row span,
	.simpbook-detail-row a,
	.simpbook-detail-row select {
		text-align: left !important;
		width: 100% !important;
	}
	
	.simpbook-modal-actions .button {
		padding: 12px 16px !important;
		font-size: 16px !important;
	}
}

/* ========================================== */
/* Verfuegbarkeit (Availability) UI           */
/* ========================================== */
.simpbook-avail-option-wrap {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

.simpbook-avail-option-label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 14px;
    border: 2px solid #ddd;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    background: #fff;
    transition: border-color .2s, background .2s, color .2s;
    user-select: none;
}

.simpbook-avail-option-label:hover {
    border-color: #999;
    background: #f6f6f6;
}

.simpbook-avail-option-label.active {
    border-color: #00a32a;
    background: #f0fff4;
    color: #1a6b2a;
    font-weight: 600;
}

.simpbook-avail-option-label input[type="radio"] {
    accent-color: #00a32a;
    margin: 0;
}

/* Weekday grid */
.simpbook-avail-weekdays {
    background: #f9f9f9;
    border: 1px solid #e5e5e5;
    border-radius: 6px;
    padding: 12px;
    margin-bottom: 8px;
}

.simpbook-weekday-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
}

@media (min-width: 900px) {
    .simpbook-weekday-grid {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    }
}

.simpbook-weekday-item {
    background: #fff;
    border: 1px solid #dcdcde;
    border-radius: 4px;
    padding: 8px 10px;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    min-width: 0;
    overflow: hidden;
}

.simpbook-weekday-check-label {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-weight: 600;
    white-space: nowrap;
    flex-shrink: 0;
    min-width: 50px;
}

.simpbook-weekday-item-times {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-wrap: nowrap;
    font-size: 12px;
    color: #646970;
    flex: 1;
}

.simpbook-weekday-item-times input.simpbook-time-input {
    width: 100px;
}

.simpbook-weekday-item .simpbook-time-input:disabled {
    opacity: 0.35;
    cursor: not-allowed;
}

/* Special dates */
.simpbook-avail-special {
    background: #f9f9f9;
    border: 1px solid #e5e5e5;
    border-radius: 6px;
    padding: 12px;
    margin-bottom: 8px;
}

.simpbook-avail-special-datepicker-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    flex-wrap: wrap;
}

.simpbook-avail-special-datepicker-wrap input[type="text"] {
    width: 140px;
}

.simpbook-avail-special-dates-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.simpbook-avail-special-date-row {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #fff;
    border: 1px solid #dcdcde;
    border-radius: 4px;
    padding: 6px 10px;
    flex-wrap: wrap;
}

.simpbook-avail-special-date-display {
    font-weight: 600;
    min-width: 110px;
    color: #1d2327;
    font-size: 13px;
}

.simpbook-avail-special-date-row label {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: #646970;
}

.simpbook-avail-special-date-row input.simpbook-time-input {
    width: 100px;
}

/* availability CSS added */

/* ============================================
   DATEPICKER STYLES (Verfügbarkeit - special dates)
   ============================================ */

div.ui-datepicker {
    font-size: 14px;
    border-radius: 4px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.15);
    z-index: 100002 !important;
    width: 260px !important;
    padding: 0 !important;
    background-color: #ffffff !important;
    border: 1px solid #ddd !important;
}

.ui-datepicker-header {
    background: var(--simpbook-container-bg, #2271b1) !important;
    color: var(--simpbook-text-color, #ffffff) !important;
    border-radius: 4px 4px 0 0;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    padding: 5px !important;
    border-bottom: 1px solid rgba(0,0,0,0.15);
}

.ui-datepicker-prev {
    order: 1;
    flex-shrink: 0;
    position: relative !important;
    top: auto !important;
    left: auto !important;
    right: auto !important;
    background-color: var(--simpbook-button-color) !important;
    border: none !important;
    cursor: pointer;
    margin-left: 5px !important;
}

.ui-datepicker-title {
    order: 2;
    flex-grow: 1;
    text-align: center !important;
    margin: 0 0.5em !important;
    line-height: 1.8em !important;
    font-weight: bold;
    color: var(--simpbook-text-color, #ffffff) !important;
}

.ui-datepicker-next {
    order: 3;
    flex-shrink: 0;
    position: relative !important;
    top: auto !important;
    left: auto !important;
    right: auto !important;
    background-color: var(--simpbook-button-color) !important;
    border: none !important;
    cursor: pointer;
    margin-right: 5px !important;
}

.ui-datepicker-prev .ui-icon,
.ui-datepicker-next .ui-icon {
    background-image: none !important;
    text-indent: -9999px !important;
    overflow: hidden;
    width: 1.2em;
    height: 1.2em;
    display: inline-block;
    position: relative;
    vertical-align: middle;
}

.ui-datepicker-prev .ui-icon::before {
    content: '';
    display: block;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23FFFFFF'%3E%3Cpath d='M11.043 1.561a.75.75 0 00-1.061 0L4.779 6.764a.75.75 0 000 1.06L9.982 13.03a.75.75 0 101.06-1.061L6.37 7.294l4.673-4.673a.75.75 0 000-1.06z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center center;
    background-size: contain;
}

.ui-datepicker-next .ui-icon::before {
    content: '';
    display: block;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23FFFFFF'%3E%3Cpath d='M5.018 1.561a.75.75 0 011.061 0l5.203 5.203a.75.75 0 010 1.06l-5.203 5.203a.75.75 0 11-1.06-1.061L9.63 7.294 5.018 2.622a.75.75 0 010-1.06z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center center;
    background-size: contain;
}

.ui-datepicker-calendar {
    width: 100%;
    border-collapse: collapse;
    margin: 0;
}

.ui-datepicker-calendar th {
    background-color: #f7f7f7 !important;
    color: #333 !important;
    padding: 5px 2px !important;
    font-size: 12px !important;
    line-height: 1.2 !important;
    text-align: center;
    font-weight: bold;
}

.ui-datepicker-calendar td {
    padding: 1px !important;
    border: none;
}

.ui-datepicker-calendar td a.ui-state-default,
.ui-datepicker-calendar td span.ui-state-default {
    display: block !important;
    box-sizing: border-box !important;
    width: 100% !important;
    text-align: center !important;
    text-decoration: none !important;
    padding: 5px 2px !important;
    font-size: 13px !important;
    line-height: 1.4em !important;
    border-radius: 3px !important;
    border: 1px solid #ddd !important;
    color: #333 !important;
    background: #fdfdfd !important;
    opacity: 1.0 !important;
}

.ui-datepicker-calendar td a.ui-state-hover {
    background: #e0f7ff !important;
    border-color: #99d1ff !important;
    color: #004a7c !important;
}

.ui-datepicker-calendar td.ui-datepicker-today a.ui-state-default,
.ui-datepicker-calendar td.ui-datepicker-today span.ui-state-default {
    background: #fffadd !important;
    border-color: #fcefae !important;
    color: #363636 !important;
    font-weight: bold;
}

.ui-datepicker-calendar td.ui-datepicker-current-day a.ui-state-default,
.ui-datepicker-calendar td.ui-datepicker-current-day span.ui-state-default {
    background: var(--simpbook-container-bg, #2271b1) !important;
    color: var(--simpbook-text-color, #ffffff) !important;
    border-color: rgba(0,0,0,0.2) !important;
    font-weight: bold;
}

/* Deaktivierte Tage (Vergangenheit / außerhalb Monat) — gleiche Farbe wie Header */
.ui-datepicker .ui-state-disabled .ui-state-default {
    opacity: 0.7 !important;
    background: var(--simpbook-tile-bg, #f5f5f5) !important;
    color: rgba(0,0,0,0.5) !important;
    cursor: not-allowed !important;
    border: 1px solid rgba(0,0,0,0.1) !important;
}
/* Mehr-spezifische Regel für span/a innerhalb deaktivierter td (wie neue-reservierung.css) */
.ui-datepicker-calendar td.ui-state-disabled span.ui-state-default,
.ui-datepicker-calendar td.ui-state-disabled a.ui-state-default {
    background-color: var(--simpbook-tile-bg, #f5f5f5) !important;
    color: rgba(0,0,0,0.5) !important;
    opacity: 0.7 !important;
    border-color: rgba(0,0,0,0.1) !important;
    cursor: not-allowed !important;
}

/* Ausgeschlossene Tage (Feiertage/Schließtage) — sichtbar aber wählbar */
.ui-datepicker .simpbook-avail-dp-excluded a.ui-state-default {
    background: #fff3f3 !important;
    border: 2px solid #d63638 !important;
    color: #d63638 !important;
    font-weight: 600;
}
.ui-datepicker .simpbook-avail-dp-excluded a.ui-state-hover {
    background: #fce8e8 !important;
    border-color: #b32d2e !important;
}

/* Spezielle Schließtage (Feiertage & Spez. Öffnungszeiten, Status=geschlossen) — roter Rahmen wie ausgeschlossene Tage, klickbar */
.ui-datepicker .simpbook-avail-dp-spez-closed a.ui-state-default {
    background: #fff3f3 !important;
    border: 2px solid #d63638 !important;
    color: #d63638 !important;
    font-weight: 600;
    text-decoration: none !important;
}
.ui-datepicker .simpbook-avail-dp-spez-closed a.ui-state-hover {
    background: #fce8e8 !important;
    border-color: #b32d2e !important;
}

/* Normalerweise geschlossene Wochentage — orangefarbener Hinweis, trotzdem wählbar */
.ui-datepicker .simpbook-avail-dp-closed a.ui-state-default {
    background: #fff8f0 !important;
    border: 2px solid #dba617 !important;
    color: #7a5600 !important;
}
.ui-datepicker .simpbook-avail-dp-closed a.ui-state-hover {
    background: #feeece !important;
    border-color: #c08000 !important;
}
