/*!
 * Licensed to the Apache Software Foundation (ASF) under one or more
 * contributor license agreements.  See the NOTICE file distributed with
 * this work for additional information regarding copyright ownership.
 * The ASF licenses this file to You under the Apache License, Version 2.0
 * (the "License"); you may not use this file except in compliance with
 * the License.  You may obtain a copy of the License at
 *
 *    http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 *
 */

@use '@angular/material' as mat;

:root {
    .mat-mdc-icon-button .mat-mdc-button-persistent-ripple {
        border-radius: 6px;
    }
    @include mat.button-overrides(
        (
            filled-container-shape: 20px,
            outlined-outline-color: var(--mat-sys-outline),
            outlined-label-text-color: var(--mat-sys-on-surface),
            filled-label-text-weight: 400,
            filled-label-text-tracking: -0.01em,
            outlined-label-text-tracking: -0.01em,
            text-container-shape: 6px,
            text-label-text-tracking: -0.01em,
            filled-hover-state-layer-opacity: 0.2,
        )
    );

    .btn-secondary {
        @include mat.button-overrides(
            (
                filled-container-color: var(--color-bg-1),
                filled-label-text-color: var(--mat-sys-primary),
                text-hover-state-layer-opacity: 1,
                filled-label-text-weight: 400,
            )
        );
    }

    .mat-basic {
        border: 1px solid var(--mat-sys-surface-container-high);
        @include mat.button-overrides(
            (
                filled-container-color: var(--mat-sys-surface-container-high),
                filled-label-text-color: var(--mat-sys-primary),
                text-hover-state-layer-opacity: 1,
                filled-label-text-weight: 400,
            )
        );
    }

    .btn-warn {
        @include mat.button-overrides(
            (
                filled-container-color: var(--mat-sys-error-container),
                filled-label-text-color: var(--mat-sys-on-error-container),
                text-hover-state-layer-opacity: 1,
                filled-label-text-weight: 400,
            )
        );
    }

    .mdc-button.small-button {
        padding: 0.25em 0.75em;
        font-size: 0.8em;
        max-height: 20px;
        line-height: 10px;
    }

    .mdc-button.small-button-add {
        padding: 0.25em 0.75em;
        font-size: 0.8em;
        max-height: 75px;
        line-height: 25px;
    }

    .mdc-raised-button.small-button-add-inverted {
        padding: 0.25em 0.75em;
        font-size: 0.8em;
        max-height: 75px;
        line-height: 25px;
        background: white;
        border: 1.5px solid var(--mat-sys-primary);
        color: var(--mat-sys-primary);
    }
}
