
/* assets/css/custom-woo-filters.css */

/* Styling for the custom product search form */
.custom-woo-search-wrapper {
    display: flex;
    justify-content: center; /* Center the search form */
    margin: 20px 0; /* Add some margin above and below */
    padding: 15px;
    background-color: #f9f9f9;
    border: 1px solid #ddd;
    border-radius: 8px; /* Rounded corners */
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.custom-woo-search-wrapper .woocommerce-product-search-form {
    display: flex;
    width: 100%;
    max-width: 600px; /* Limit width for larger screens */
}

.custom-woo-search-wrapper .search-field {
    flex-grow: 1; /* Make input take available space */
    padding: 10px 15px;
    border: 1px solid #ccc;
    border-radius: 6px 0 0 6px; /* Rounded left corners */
    outline: none;
    font-size: 16px;
}

.custom-woo-search-wrapper .search-field:focus {
    border-color: #0073aa; /* WordPress primary color */
    box-shadow: 0 0 0 1px #0073aa;
}

.custom-woo-search-wrapper .button {
    padding: 10px 20px;
    background-color: #0073aa; /* WordPress primary color */
    color: #fff;
    border: 1px solid #0073aa;
    border-radius: 0 6px 6px 0; /* Rounded right corners */
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

.custom-woo-search-wrapper .button:hover {
    background-color: #005a87;
    border-color: #005a87;
}

/* Styling for the custom checkbox lists */
.product-categories-checkboxes {
    list-style: none;
    padding: 0;
    margin: 0;
}

.product-categories-checkboxes li {
    margin-bottom: 8px;
}

.product-categories-checkboxes label {
    display: flex; /* Use flexbox for alignment */
    align-items: center; /* Vertically align checkbox and text */
    cursor: pointer;
    font-size: 15px;
    color: #333;
}

.product-categories-checkboxes input[type="checkbox"] {
    margin-right: 8px; /* Space between checkbox and text */
    /* Customize checkbox appearance */
    width: 18px;
    height: 18px;
    accent-color: #0073aa; /* Use WordPress primary color for checked state */
    cursor: pointer;
}

.product-categories-checkboxes .count {
    margin-left: 5px;
    color: #777;
    font-size: 13px;
}

.product-categories-checkboxes .children {
    list-style: none;
    padding-left: 20px; /* Indent child categories */
    margin-top: 5px;
}

/* Optional: Add some basic styling for the products container if needed for AJAX updates */
#custom-woo-products-container {
    opacity: 1;
    transition: opacity 0.3s ease;
}

#custom-woo-products-container.loading {
    opacity: 0.5; /* Fade out products slightly when loading */
    pointer-events: none; /* Prevent clicks during loading */
}

/* Loading spinner (optional, could be an SVG or Font Awesome icon) */
.custom-woo-loading-spinner {
    display: none; /* Hidden by default */
    text-align: center;
    margin: 20px auto;
    font-size: 2em;
    color: #0073aa;
    /* Add a simple spin animation if desired */
    animation: spin 1s linear infinite;
}

.custom-woo-loading-spinner.active {
    display: block;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}