/* Modernes Checkbox-Styling für Reservierungen-Liste */

/* ============================================
   View Toggle Button Container
   ============================================ */
.view-toggle-container {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-left: 10px;
	margin-right: 10px;
	gap: 15px;
}

.view-toggle-container .page-title-action {
	flex-shrink: 0;
	order: 1;
}

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

.view-toggle-container #toggle-reservierungen-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;
}

#reservierungen-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;
}

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

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

#clear-search-btn {
	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:hover {
	color: #d63638;
}

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

#toggle-reservierungen-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-reservierungen-view-btn:hover {
	background-color: #2271b1;
	color: white;
	border-color: #2271b1;
}

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

/* Mobile: Container anpassen */
@media screen and (max-width: 782px) {
	.view-toggle-container {
		flex-direction: column;
		align-items: stretch;
		gap: 10px;
        margin-top: 10px;
	}
	
	.view-toggle-container .page-title-action {
		order: 1;
		text-align: center;
	}
	
	.reservierungen-search-container {
		max-width: none;
		width: 100%;
		order: 2;
	}
	
	#toggle-reservierungen-view-btn {
		order: 3;
	}
}

/* ============================================
   Checkbox Styling
   ============================================ */

/* Checkbox Container */
.reservation-checkbox,
#select-all-checkbox {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    width: 20px;
    height: 20px;
    border: 2px solid #8c8f94;
    border-radius: 4px;
    background-color: #fff;
    cursor: pointer;
    position: relative;
    transition: all 0.2s ease;
    margin: 0;
    vertical-align: middle;
}

/* Hover State */
.reservation-checkbox:hover,
#select-all-checkbox:hover {
    border-color: #2271b1;
    box-shadow: 0 0 0 1px rgba(34, 113, 177, 0.2);
}

/* Focus State */
.reservation-checkbox:focus,
#select-all-checkbox:focus {
    outline: none;
    border-color: #2271b1;
    box-shadow: 0 0 0 1px #2271b1;
}

/* Checked State */
.reservation-checkbox:checked,
#select-all-checkbox:checked {
    background-color: #2271b1;
    border-color: #2271b1;
}

/* Checkmark */
.reservation-checkbox:checked::after,
#select-all-checkbox:checked::after {
    content: '';
    position: absolute;
    left: 5px;
    top: 1px;
    width: 6px;
    height: 10px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

/* Disabled State */
.reservation-checkbox:disabled,
#select-all-checkbox:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Bulk Actions Container Styling */
#bulk-actions-container {
    background: #f0f0f1;
    padding: 12px 15px;
    border-radius: 4px;
    border-left: 4px solid #2271b1;
    display: flex;
    align-items: center;
    gap: 15px;
}

#bulk-delete-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 8px 16px;
    font-weight: 500;
    transition: all 0.2s ease;
}

#bulk-delete-btn:hover {
    background-color: #c82333;
    border-color: #bd2130;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(220, 53, 69, 0.3);
}

#bulk-delete-btn:active {
    transform: translateY(0);
}

#selected-count {
    color: #2271b1;
    font-size: 14px;
}

/* Table Cell mit Checkbox */
td input[type="checkbox"],
th input[type="checkbox"] {

    display: block !important;
    margin-left: 5px !important;
    width: 20px !important;
    max-width: none !important;
    margin-right: 8px !important;
    height: 20px !important;

}

/* Checkbox Cell Alignment */
.wp-list-table td:first-child,
.wp-list-table th:first-child {
    text-align: center;
}

/* ============================================
   Einträge pro Seite Dropdown Styling
   ============================================ */
.per-page-selector {
    display: inline-block;
    vertical-align: middle;
    margin-right: 20px;
}

.per-page-selector label {
    font-weight: 600;
    margin-right: 5px;
}

.per-page-selector select {
    padding: 4px 8px;
    border: 1px solid #ddd;
    border-radius: 3px;
    font-size: 14px;
    min-width: 70px;
    background-color: #fff;
    cursor: pointer;
}

.per-page-selector select:hover {
    border-color: #2271b1;
}

.per-page-selector select:focus {
    outline: none;
    border-color: #2271b1;
    box-shadow: 0 0 0 1px #2271b1;
}

.tablenav-pages {
    display: flex;
    align-items: center;
    gap: 15px;
}

.tablenav-pages .displaying-num {
    margin: 0;
}

/* Responsive Anpassungen */
@media screen and (max-width: 782px) {
    .tablenav-pages {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .per-page-selector {
        margin-bottom: 10px;
        float: none !important;
        margin-right: 0 !important;
    }
}
