/*------------------------------------*\
    LINKS
\*------------------------------------*/

@use "../../settings";
@use "../../helpers";

a,
.ds_link {
    @include helpers.ds_link;
}

.ds_link {
    background: transparent;
    border: 0;
    display: inline;
    font-size: inherit;
    font-weight: inherit;
    line-height: initial;
    margin: 0;
    min-height: 0;
    min-width: 0;
    padding: 0;
    text-align: left; // .ds_link applied to a button would otherwise have centered text
}

.ds_reversed {
    a,
    .ds_link {
        color: settings.$ds_colour__link--reversed;

        &:focus {
            color: settings.$ds_colour__link--reversed--focus;
        }

        &:hover:not(:focus) {
            background-color: transparent;
            color: settings.$ds_colour__link--reversed--hover;
            outline-color: transparent;
        }
    }
}

a[disabled] {
    pointer-events: none;
}

// no underline on header links
h1, h2, h3, h4 {
    a {
        text-decoration-line: none;

        &:hover:not(:focus) {
            text-decoration-line: underline;
        }
    }
}
