stress usually causes both. it can be anything from the coral just didnt ship well, or your parameters were a little bit different compared to that of the tank it came from. it could be a number of other things such as chemicals leeched from soft corals, improper flow, high levels of trace elements or something such as high nitrates or phosphates. could also indicate a pest such as AEFW, red bugs, black bugs, monti eating nudis. possibly too much light. big temperature swings, a fish picking, another coral growing too close.
theres plenty of reasons why a coral will brown or bleach, but those are usually the main reasons.
ive had one or two brown outs and both came back to better than original color within a few months.