.text {
    /*
    * Tipos de tipografía
    */
    &--light {
        .text {
            font-family: 'TelefonicaWeb-Light';
            font-weight: 300;
        }
    }
    &--extralight {
        .text {
            font-family: 'TelefonicaWeb-ExtraLight';
            font-weight: 200;
        }
    }
    &--regular {
        .text {
            font-family: 'TelefonicaWeb-Regular';
            font-weight: 400;
        }
    }
    &--hand {
        .text {
            font-family: 'TelefonicaWeb-Hand';
            font-weight: 700;
        }
    }
    &--bold {
        .text {
            font-family: 'TelefonicaWeb-Bold';
            font-weight: 700;
        }
    }
    &--regularitalic {
        .text {
            font-family: 'TelefonicaWeb-RegularItalic';
            font-weight: 400;
        }
    }   
}

/*
* Tamaños responsive
*/
@each $size, $value in $font-sizes {
    @if $size <= 56 {
        $mobile_size: 0;
        $desktop_size: 0;
        $mobile_line: 0;
        $desktop_line: 0;

        .text--#{$size} {
            .text {
                @each $type, $size_t in $value {
                    @if $type == 'mobile' {
                        $mobile_size: $size_t;
                    } @else if $type == 'desktop' {
                        $desktop_size: $size_t;
                    }
                }
                font-size: calc(#{$mobile_size}rem + (#{$desktop_size} - #{$mobile_size}) * ((100vw - 20rem) / (100 - 20)));
                @each $type, $line-h in map-get($line-heights, $size) {
                    @if $type == 'mobile' {
                        $mobile_line: $line-h;
                    } @else if $type == 'desktop' {
                        $desktop_line: $line-h;
                    }
                }
                line-height: calc(#{$mobile_line}rem + (#{$desktop_line} - #{$mobile_line}) * ((100vw - 20rem) / (100 - 20)));
            }
        }
    }
}

/*
* Alineación Responsive
*/
@each $breakpoint in map-keys($mv-layout-grid-breakpoints) {
    @include breakpoint-up($breakpoint) {
      $infix: breakpoint-infix($breakpoint);
  
      .text#{$infix}--left   { text-align: left !important; }
      .text#{$infix}--right  { text-align: right !important; }
      .text#{$infix}--center { text-align: center !important; }
    }
  }

/*
* Colores contextuales
*/
@each $color, $value in $colors {
  @include text-emphasis-variant(".text--#{$color}", $value, true);
}

mv-h1, mv-h2, mv-h3, mv-h4, mv-body, mv-caption {
    display: block;
    position: relative;

    b, strong {
        font-family: 'TelefonicaWeb-Bold';
        font-weight: 700;
    }
}