mat-card, how to change default padding
dotless: .mat-card --> mat-card
mat-card { margin: 5px; padding: 5px;}
You must scope them. Angular will take css of its own component first. So if you want to change globally scope them with any class name such as 'custom'.
<mat-card class="custom"></mat-card>
In stylesheet
.custom.mat-card{
//your styles
}
To know more, refer to angular material customizing