<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
                    xmlns:sc="using:SearchUI.Controls"
                    xmlns:tm="using:SearchUI.TemplateManager"
                    x:Key="Shared.Rating_8_1_RP">
    <ResourceDictionary.ThemeDictionaries>
        <ResourceDictionary x:Key="Default">
            <SolidColorBrush x:Key="Local.RatingStarFullBrush"
                             Color="#FF333333" />
            <SolidColorBrush x:Key="Local.RatingStarEmptyBrush"
                             Color="#FF999999" />
        </ResourceDictionary>
        <ResourceDictionary x:Key="HighContrast">
            <SolidColorBrush x:Key="Local.RatingStarFullBrush"
                             Color="{ThemeResource ImmersiveLightDisabledTextColor}" />
            <SolidColorBrush x:Key="Local.RatingStarEmptyBrush"
                             Color="{ThemeResource ImmersiveLightPrimaryTextColor}" />
        </ResourceDictionary>
    </ResourceDictionary.ThemeDictionaries>
    
    <Style x:Key="Horizontal"
           TargetType="sc:ResultContentControl">
        <Setter Property="Foreground"
                Value="{ThemeResource Local.RatingStarFullBrush}" />
        <Setter Property="Background"
                Value="{ThemeResource Local.RatingStarEmptyBrush}" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate>
                    <TextBlock FontFamily="Segoe UI Symbol"
                               HorizontalAlignment="Left"
                               UseLayoutRounding="False"                               
                               Text="{Binding Extended:ratingText.System_Search_Contents}"
                               AutomationProperties.AutomationId="RatingStar">
                        <TextBlock.Foreground>
                            <LinearGradientBrush EndPoint="1, 0.5"
                                                 StartPoint="0, 0.5">
                                <GradientStop Color="{Binding Foreground.Color, RelativeSource={RelativeSource TemplatedParent}}"
                                              Offset="{Binding Extended:normalizedRating.System_Search_Contents}" />
                                <GradientStop Color="{Binding Background.Color, RelativeSource={RelativeSource TemplatedParent}}"
                                              Offset="{Binding Extended:normalizedRating.System_Search_Contents}" />
                            </LinearGradientBrush>
                        </TextBlock.Foreground>
                    </TextBlock>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
</ResourceDictionary>