@each $tuple in 'ok' #5cff56, 'warning' #ff4b41, 'favorite' #d16059 { .#{nth($tuple, 1)} { color: #{nth($tuple, 2)}; } } @each $tuple in 'green' #61BD6D, 'red' #D14841, 'blue' #2C82C9, 'orange' #FBA026, 'lightblue' #54ACD2, 'yellow' #FAC51C, 'purple' #553982, 'pink' #ffa6e3, 'grey' #dcdcdc, 'darkred' #B8312F, 'darkgreen' #41A85F, 'darkblue' #2969B0 { .#{nth($tuple, 1)} { background: #{nth($tuple, 2)}; } }