html, body {
    min-height: 100vh;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.list-group-item.active {
    background-color: transparent !important;
    color: inherit !important;
    border-color: var(--bs-primary) !important;
    border-width: 1px 0px 1px 0px !important;
    border-style: solid !important;
}

/* Style pour les options de Select2 avec indicateur de couleur */
.folder-option-with-color {
    display: flex;
    align-items: center;
}

.folder-color-indicator {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 3px;
    margin-right: 8px;
}

/* Style des badges de tags */
.badge.tag-item {
    font-size: 0.875rem;
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.badge.tag-item .position-absolute {
    position: static !important;
    transform: none !important;
    margin-left: 0 !important;
}

/* Style du formulaire d'édition des tags */
.tag-edit-form {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.tag-edit-form .input-group {
    margin: 0;
}

.tag-edit-form .form-control-sm {
    height: calc(1.5em + 0.5rem + 2px);
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
    line-height: 1.5;
}

/* Styles pour les catégories de tags */
.tag-category-item {
    padding: 0.5em 1em;
    display: inline-block;
    margin-right: 0.5em;
    margin-bottom: 0.5em;
    transition: all 0.3s ease;
    text-decoration: none;
    border-top-width: 1px !important;
    border-bottom-width: 1px !important;
}

.tag-category-item:hover {
    text-decoration: none;
    color: white;
}

.tag-category-item.selected {
    color: white;
}

/* Styles pour les badges de tags */
.badge.tag-item {
    padding: 0.3rem;
    font-size: 0.85em;
    display: inline-flex;
    align-items: center;
    height: 2em;
    text-decoration: none;
    border-width: 1px !important;
    border-style: solid !important;
}

.badge.tag-item a {
    color: inherit;
    text-decoration: none;
}

.badge.tag-item:hover {
    color: white;
}

.badge.tag-item.selected {
    color: white;
}

.badge.tag-item .btn-badge {
    background-color: transparent;
    border: none;
    color: inherit;
    font-size: 0.7em;
    padding: 0.1em 0.3em;
    line-height: 1;
    height: 1.5em;
    width: 1.5em;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 0.25rem;
    transition: all 0.3s ease;
}

.badge.tag-item .btn-badge:hover {
    background-color: rgba(0, 0, 0, 0.1);
}

.badge.tag-item .position-absolute {
    right: 0.3em;
    top: 50%;
    transform: translateY(-50%);
    gap: 2px;
}

.tag-edit-form {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    margin-left: 5px;
}

.tag-edit-form .form-control {
    height: calc(1.5em + .75rem + 2px);
    padding: .375rem .75rem;
    font-size: .85em;
    line-height: 1.5;
    border-radius: .25rem;
}

.tag-edit-form .btn-badge {
    height: calc(1.5em + .75rem + 2px);
    padding: .375rem .75rem;
    font-size: .85em;
    line-height: 1.5;
    border-radius: .25rem;
}

.select2-container--bootstrap-5 {
    display: inline-block;
}

#main-bookmark-form .select2-container {
    flex: 1 1 30%;
}

#main-bookmark-form .select2-selection {
    border-radius: 0;
    height: 31px;
    min-height: 31px;
}

#main-bookmark-form .select2-search__field {
    padding: 6px;
}



#main-bookmark-form .select2-selection--multiple {
    padding: 0;
}

#main-bookmark-form .select2-selection--multiple .select2-selection__rendered {
    margin: 0;
    padding: 0;
}

#main-bookmark-form .select2-selection--multiple .select2-selection__choice {
    margin: 1px;
    padding: 1px 5px 1px 5px;
}

#main-bookmark-form .select2-container .select2-results__option {
    text-align: left;
    padding: 6px;
}

#main-bookmark-form .select2-selection--multiple .select2-selection__choice,
#main-bookmark-form .select2-container .select2-results__option {
    border-width: 1px !important;
    border-style: solid !important;
    border-radius: 0.25rem;
    font-size: 0.85em;
    display: inline-flex;
    align-items: center;
}

#main-bookmark-form .select2-selection--multiple .select2-selection__choice {
    background-color: transparent;
    color: inherit;
}

#main-bookmark-form .select2-container .select2-results__option--selected,
#main-bookmark-form .select2-container .select2-results__option--highlighted {
    color: white;
}
.bookmark-list-item:hover {
    /* back ground color a little gray */
    background-color: gainsboro;
}

/* Styles pour le défilement vertical responsive */
@media (min-width: 768px) {
    body {
        height: 100vh;
        overflow: hidden;
    }

    #folder-workspace, #bookmark-workspace, #tag-workspace {
        height: calc(100vh - 64px);
        overflow-y: scroll;
    }
}
