/* Styles for the container of checkboxes within each category (already defined) */
.amenities-category-items {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 10px;
}

/* Styles for individual checkbox items (input + label) */
.checkbox-item {
    flex: 0 0 calc(33.333% - 7px); /* Approx 3 items per row with 10px gap */
    margin-bottom: 5px;

    /* Ensure checkbox and label are on the same line and aligned */
    display: flex;       /* This makes the checkbox-item a flex container */
    align-items: center; /* This vertically aligns the input and label in the middle */
    line-height: 1.2;    /* Helps with vertical alignment if text height varies */
}

/* Specific rules for the input checkbox within the item */
.checkbox-item input[type="checkbox"] {
    /* Important for consistent alignment and preventing unwanted wrapping */
    display: inline-block; /* Ensures it behaves as an inline element */
    margin-right: 8px;     /* Space between checkbox square and its label text */
    flex-shrink: 0;        /* Prevent checkbox from shrinking if space is tight */
    vertical-align: middle; /* Classic alignment for inline elements */
    width: auto;           /* Prevent fixed width from pushing label down */
    height: auto;          /* Prevent fixed height causing alignment issues */
    /* If you're using Bootstrap's form-check-input, you might need to override its display */
    /* For Bootstrap 4/5: */
    /* display: inline-block !important; */ /* Use !important if needed to override framework */
    /* margin-top: 0; */ /* Bootstrap adds margin-top to its form-check-input */
}

/* Specific rules for the label within the item */
.checkbox-item label {
    flex-grow: 1;         /* Allow label to take available space */
    cursor: pointer;      /* Indicate it's clickable */
    margin-bottom: 0;     /* Remove default margin from labels if any from framework */
    display: inline-block; /* Ensures label behaves as an inline element */
    vertical-align: middle; /* Classic alignment for inline elements */
    white-space: normal;  /* Allow text to wrap if it's too long for the column */
}