//
//  Variables
//  _____________________________________________

$checkout-shipping-policy-action__color         : $link__color !default;
$checkout-shipping-policy-tooltip__width        : 420px !default;
$checkout-shipping-policy-tooltip-mobile__width : 300px !default;

//
//  Common
//  _____________________________________________

.checkout-shipping-method {
    position: relative;
}

.shipping-policy-block {
    &.field-tooltip {
        top: 12px;

        .field-tooltip-action {
            @include lib-css(color, $checkout-shipping-policy-action__color);
            cursor: pointer;

            &:before {
                display: none;
            }

            span {
                @extend .abs-visually-hidden-reset;
            }
        }

        .field-tooltip-content {
            @extend .abs-add-box-sizing;
            @extend .abs-checkout-tooltip-content-position-top;
            @include lib-css(width, $checkout-shipping-policy-tooltip__width);
            top: $indent__l;
        }
    }
}

//
//  Mobile
//  _____________________________________________

@include max-screen($screen__s) {
    .shipping-policy-block {
        &.field-tooltip {
            margin-bottom: $indent__base;
            position: relative;
            right: auto;
            top: auto;

            .field-tooltip-content {
                @include lib-css(width, $checkout-shipping-policy-tooltip-mobile__width);
                right: auto;

                &:before,
                &:after {
                    right: auto;
                }
            }
        }
    }
}
