.toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
}

/* Jede Toolgruppe */
.toolbar-group {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding-right: 0.75rem;       /* Platz für den Trenner */
}

/* Buttons unverändert */
.toolbar .tool-btn {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    line-height: 1.2;
}

.toolbar .tool-btn .btn {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    align-items: center;
    justify-content: center;
    text-align: center;
    white-space: normal;
}

.toolbar .btn-group {
    flex-wrap: wrap !important;
}

/* Mobile optimiert */
/* Mobile optimiert */
@media (max-width: 768px) {
    .toolbar {
        gap: 0.25rem;
    }

    .toolbar .tool-btn {
        padding: 0.35rem 0.45rem;
        font-size: 0.85rem;
    }
}

.color-item {
    display: flex;
    align-items: center;
    gap: 8px;
  }

.icolor-box {
    width: 16px;
    height: 16px;
    border: 1px solid #555;
    flex-shrink: 0;
  }
.dropdown .color-box {
    width: 18px;
    height: 18px;
    border-radius: 3px; /* optional hübsch */
    margin-right: 8px;
  }
.dropdown > button {
    display: flex;
    align-items: center;
    gap: 8px;
  }

.dropdown-menu .dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: .35rem .75rem;
 }

.dropdown > button.form-select {
    background-color: #fff;
    color: #212529;
    border: 1px solid #ced4da;
 }

.dropdown > button.form-select:focus {
    outline: 0;
    box-shadow: 0 0 0 0.25rem rgba(0,123,255,.25);
 }

.color-select-button {
    display: flex;
    align-items: start;
    justify-content: space-between;
    padding-right: 2.5rem; /* Platz für Caret */
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 16px;
    justify-content: flex-start;
 }

.color-select-button:focus {
    border-color: #86b7fe;
    box-shadow: 0 0 0 0.25rem rgba(13,110,253,.25);
 }
