<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:av="using:Microsoft.UI.Xaml.Controls.AnimatedVisuals"
    xmlns:controls="using:CharacterMap.Controls"
    xmlns:core="using:CharacterMap.Core"
    xmlns:h="using:CharacterMap.Helpers"
    xmlns:muxc="using:Microsoft.UI.Xaml.Controls"
    xmlns:primitives="using:Microsoft.UI.Xaml.Controls.Primitives"
    xmlns:toolkit="using:Microsoft.Toolkit.Uwp.UI.Controls">

    <ResourceDictionary.ThemeDictionaries>
        <ResourceDictionary x:Key="Default">
            <Color x:Key="SolidBackgroundFillColorBase">#202020</Color>
            <SolidColorBrush x:Key="DefaultPageBackgroundBrush" Color="{StaticResource SolidBackgroundFillColorBase}" />
            <SolidColorBrush x:Key="DefaultHostBrush" Color="{StaticResource SolidBackgroundFillColorBase}" />
            <StaticResource x:Key="AltHostBrush" ResourceKey="CardBackgroundFillColorDefaultBrush" />
            <SolidColorBrush x:Key="PaneCollapsedBackgroundBrush" Color="Transparent" />
        </ResourceDictionary>
        <ResourceDictionary x:Key="Light">
            <Color x:Key="SolidBackgroundFillColorBase">#F3F3F3</Color>
            <SolidColorBrush x:Key="DefaultPageBackgroundBrush" Color="{StaticResource SolidBackgroundFillColorBase}" />
            <SolidColorBrush x:Key="DefaultHostBrush" Color="{ThemeResource SolidBackgroundFillColorBase}" />
            <StaticResource x:Key="AltHostBrush" ResourceKey="CardBackgroundFillColorDefaultBrush" />
            <SolidColorBrush x:Key="PaneCollapsedBackgroundBrush" Color="Transparent" />
        </ResourceDictionary>
    </ResourceDictionary.ThemeDictionaries>

    <x:Boolean x:Key="SupportsFluentAnimation">True</x:Boolean>
    <x:Boolean x:Key="SupportsShadows">False</x:Boolean>
    <x:Boolean x:Key="SupportsTabs">True</x:Boolean>
    <x:Double x:Key="MinTitleBarHeight">40</x:Double>
    <CornerRadius x:Key="CardCornerRadius">8</CornerRadius>
    <CornerRadius x:Key="InfoBarCornerRadius">4</CornerRadius>
    <CornerRadius x:Key="CommandToggleCornerRadius">3</CornerRadius>

    <FontFamily x:Key="ContentControlThemeFontFamily">Segoe UI Variable Text, XamlAutoFontFamily</FontFamily>
    <FontFamily x:Key="SymbolThemeFontFamily">Segoe Fluent Icons, Segoe MDL2 Assets</FontFamily>

    <BrushTransition x:Key="QuickBrushTransition" Duration="0:0:0.06" />

    <StaticResource x:Key="InfoBarBackgroundBrush" ResourceKey="SystemControlBackgroundAccentBrush" />




    <!--  TEXT STYLES  -->
    <Style x:Key="HeaderStyle" TargetType="TextBlock">
        <Setter Property="OpticalMarginAlignment" Value="TrimSideBearings" />
        <Setter Property="FontWeight" Value="Normal" />
        <Setter Property="FontSize" Value="14" />
        <Setter Property="Margin" Value="0 0 0 4" />
    </Style>

    <Style x:Key="BaseTextStyle" BasedOn="{StaticResource BaseTextBlockStyle}" TargetType="TextBlock">
        <Setter Property="FontWeight" Value="Normal" />
        <Setter Property="FontSize" Value="13" />
        <Setter Property="Foreground" Value="{ThemeResource TextFillColorSecondaryBrush}" />
    </Style>

    <Style x:Key="SectionHeaderTextBlockStyle" BasedOn="{StaticResource SubheaderTextBlockStyle}" TargetType="TextBlock">
        <Setter Property="FontSize" Value="28" />
        <Setter Property="core:Properties.StyleKey" Value="SectionHeaderTextBlockStyle" />
        <Setter Property="FontFamily" Value="{StaticResource ContentControlThemeFontFamily}" />
        <Setter Property="FontWeight" Value="SemiBold" />
        <Setter Property="LineHeight" Value="20" />
        <Setter Property="Margin" Value="0 10 0 4" />
    </Style>




    <!--  MISC CONTROLS  -->

    <Style TargetType="controls:PreviewTip">
        <Setter Property="Foreground" Value="{ThemeResource ToolTipForegroundBrush}" />
        <Setter Property="Background" Value="{ThemeResource ToolTipBackgroundBrush}" />
        <Setter Property="BorderBrush" Value="{ThemeResource ToolTipBorderBrush}" />
        <Setter Property="BorderThickness" Value="{ThemeResource ToolTipBorderThemeThickness}" />
        <Setter Property="FontSize" Value="{ThemeResource ToolTipContentThemeFontSize}" />
        <Setter Property="Padding" Value="{StaticResource ToolTipBorderPadding}" />
        <Setter Property="CornerRadius" Value="{ThemeResource ControlCornerRadius}" />
    </Style>

    <Style x:Name="NumberBoxSpinButtonStyle" TargetType="RepeatButton">
        <Setter Property="IsTabStop" Value="False" />
        <Setter Property="MinWidth" Value="34" />
        <Setter Property="VerticalAlignment" Value="Stretch" />
        <Setter Property="Background" Value="{ThemeResource TextControlBackground}" />
        <Setter Property="BorderBrush" Value="{ThemeResource TextControlBorderBrush}" />
        <Setter Property="BorderThickness" Value="1" />
        <Setter Property="FontFamily" Value="{ThemeResource SymbolThemeFontFamily}" />
    </Style>

    <Style x:Key="DefaultThemeToolTipStyle" TargetType="ToolTip">
        <Setter Property="Foreground" Value="{ThemeResource ToolTipForegroundBrush}" />
        <Setter Property="Background" Value="{ThemeResource ToolTipBackgroundBrush}" />
        <Setter Property="BackgroundSizing" Value="InnerBorderEdge" />
        <Setter Property="BorderBrush" Value="{ThemeResource ToolTipBorderBrush}" />
        <Setter Property="BorderThickness" Value="{ThemeResource ToolTipBorderThemeThickness}" />
        <Setter Property="FontFamily" Value="{ThemeResource ContentControlThemeFontFamily}" />
        <Setter Property="FontSize" Value="{ThemeResource ToolTipContentThemeFontSize}" />
        <Setter Property="Padding" Value="{StaticResource ToolTipBorderPadding}" />
        <Setter Property="MaxWidth" Value="400" />
        <Setter Property="CornerRadius" Value="{ThemeResource ControlCornerRadius}" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ToolTip">
                    <ContentPresenter
                        x:Name="LayoutRoot"
                        MaxWidth="{TemplateBinding MaxWidth}"
                        Padding="{TemplateBinding Padding}"
                        Background="{TemplateBinding Background}"
                        BackgroundSizing="{TemplateBinding BackgroundSizing}"
                        BorderBrush="{TemplateBinding BorderBrush}"
                        BorderThickness="{TemplateBinding BorderThickness}"
                        Content="{TemplateBinding Content}"
                        ContentTemplate="{TemplateBinding ContentTemplate}"
                        ContentTransitions="{TemplateBinding ContentTransitions}"
                        CornerRadius="{TemplateBinding CornerRadius}"
                        RenderTransformOrigin="0.5 0.5"
                        TextWrapping="Wrap">
                        <ContentPresenter.RenderTransform>
                            <CompositeTransform />
                        </ContentPresenter.RenderTransform>
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="OpenStates">
                                <VisualStateGroup.Transitions>
                                    <VisualTransition From="Opened" To="Closed">
                                        <Storyboard>
                                            <FadeOutThemeAnimation TargetName="LayoutRoot" />
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetName="LayoutRoot" Storyboard.TargetProperty="(UIElement.RenderTransform).(CompositeTransform.ScaleX)">
                                                <EasingDoubleKeyFrame KeyTime="0" Value="1" />
                                                <SplineDoubleKeyFrame KeySpline="0.7 0.0 1.0 0.5" KeyTime="0:0:0.2" Value="0.7" />
                                            </DoubleAnimationUsingKeyFrames>
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetName="LayoutRoot" Storyboard.TargetProperty="(UIElement.RenderTransform).(CompositeTransform.ScaleY)">
                                                <EasingDoubleKeyFrame KeyTime="0" Value="1" />
                                                <SplineDoubleKeyFrame KeySpline="0.7 0.0 1.0 0.5" KeyTime="0:0:0.2" Value="0.7" />
                                            </DoubleAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualTransition>
                                    <VisualTransition From="Closed" To="Opened">
                                        <Storyboard>
                                            <DoubleAnimation
                                                Storyboard.TargetName="LayoutRoot"
                                                Storyboard.TargetProperty="Opacity"
                                                From="0"
                                                To="1"
                                                Duration="0:0:0.1" />
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetName="LayoutRoot" Storyboard.TargetProperty="(UIElement.RenderTransform).(CompositeTransform.ScaleX)">
                                                <EasingDoubleKeyFrame KeyTime="0" Value="1" />
                                                <EasingDoubleKeyFrame KeyTime="0:0:0.0001" Value="0.7" />
                                                <SplineDoubleKeyFrame KeySpline="0 0 0 1" KeyTime="0:0:0.5" Value="1" />
                                            </DoubleAnimationUsingKeyFrames>
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetName="LayoutRoot" Storyboard.TargetProperty="(UIElement.RenderTransform).(CompositeTransform.ScaleY)">
                                                <EasingDoubleKeyFrame KeyTime="0" Value="1" />
                                                <EasingDoubleKeyFrame KeyTime="0:0:0.0001" Value="0.7" />
                                                <SplineDoubleKeyFrame KeySpline="0 0 0 1" KeyTime="0:0:0.5" Value="1" />
                                            </DoubleAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualTransition>
                                </VisualStateGroup.Transitions>
                                <VisualState x:Name="Closed">
                                    <Storyboard>
                                        <!--  Do not use Setters here, ToolTip source code *requires* a storyboard  -->
                                        <DoubleAnimation
                                            Storyboard.TargetName="LayoutRoot"
                                            Storyboard.TargetProperty="Opacity"
                                            To="0"
                                            Duration="0:0:0" />
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Opened">
                                    <Storyboard>
                                        <DoubleAnimation
                                            Storyboard.TargetName="LayoutRoot"
                                            Storyboard.TargetProperty="Opacity"
                                            To="1"
                                            Duration="0:0:0" />
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                    </ContentPresenter>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="DefaultToolTipStyle" BasedOn="{StaticResource DefaultThemeToolTipStyle}" TargetType="ToolTip" />

    <Style BasedOn="{StaticResource DefaultThemeToolTipStyle}" TargetType="ToolTip" />

    <Style TargetType="controls:ModalPagePresenter">
        <Setter Property="ContentBackground" Value="Transparent" />
        <Setter Property="TitleBackgroundBrush" Value="Transparent" />
        <Setter Property="AllowShadows" Value="False" />
        <Setter Property="Background" Value="{ThemeResource DefaultPageBackgroundBrush}" />
    </Style>

    <Style x:Key="DefaultThemeContentDialogStyle" BasedOn="{StaticResource DefaultContentDialogStyle}" TargetType="ContentDialog" />

    <Style x:Key="DefaultThemeListViewItemStyle" BasedOn="{StaticResource DefaultListViewItemStyle}" TargetType="ListViewItem">
        <Setter Property="HorizontalAlignment" Value="Stretch" />
        <Setter Property="HorizontalContentAlignment" Value="Stretch" />
        <Setter Property="VerticalContentAlignment" Value="Center" />
        <Setter Property="BorderThickness" Value="0 0.5 1 0.5" />
        <Setter Property="h:FluentAnimation.PointerOverAxis" Value="Horizontal" />
        <Setter Property="h:FluentAnimation.PointerOverOffset" Value="3" />
        <Setter Property="Padding" Value="2 1" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ListViewItem">
                    <ListViewItemPresenter
                        x:Name="Presenter"
                        HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"
                        VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}"
                        CheckBoxBrush="{ThemeResource ListViewItemCheckBoxBrush}"
                        CheckBrush="{ThemeResource ListViewItemCheckBrush}"
                        CheckMode="{ThemeResource ListViewItemCheckMode}"
                        ContentMargin="{TemplateBinding Padding}"
                        ContentTransitions="{TemplateBinding ContentTransitions}"
                        Control.IsTemplateFocusTarget="True"
                        CornerRadius="4"
                        DisabledOpacity="{ThemeResource ListViewItemDisabledThemeOpacity}"
                        DragBackground="{ThemeResource ListViewItemDragBackground}"
                        DragForeground="{ThemeResource ListViewItemDragForeground}"
                        DragOpacity="{ThemeResource ListViewItemDragThemeOpacity}"
                        FocusBorderBrush="{ThemeResource ListViewItemFocusBorderBrush}"
                        FocusSecondaryBorderBrush="{ThemeResource ListViewItemFocusSecondaryBorderBrush}"
                        FocusVisualMargin="{TemplateBinding FocusVisualMargin}"
                        FocusVisualPrimaryBrush="{TemplateBinding FocusVisualPrimaryBrush}"
                        FocusVisualPrimaryThickness="{TemplateBinding FocusVisualPrimaryThickness}"
                        FocusVisualSecondaryBrush="{TemplateBinding FocusVisualSecondaryBrush}"
                        FocusVisualSecondaryThickness="{TemplateBinding FocusVisualSecondaryThickness}"
                        PlaceholderBackground="{ThemeResource ListViewItemPlaceholderBackground}"
                        PointerOverBackground="{ThemeResource ListViewItemBackgroundPointerOver}"
                        PointerOverForeground="{ThemeResource ListViewItemForegroundPointerOver}"
                        PressedBackground="{ThemeResource ListViewItemBackgroundPressed}"
                        ReorderHintOffset="{ThemeResource ListViewItemReorderHintThemeOffset}"
                        SelectedBackground="{ThemeResource ListViewItemBackgroundSelected}"
                        SelectedForeground="{ThemeResource ListViewItemForegroundSelected}"
                        SelectedPointerOverBackground="{ThemeResource ListViewItemBackgroundSelectedPointerOver}"
                        SelectedPressedBackground="{ThemeResource ListViewItemBackgroundSelectedPressed}"
                        SelectionCheckMarkVisualEnabled="{ThemeResource ListViewItemSelectionCheckMarkVisualEnabled}">
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup
                                x:Name="CommonStates"
                                h:FluentAnimation.PointerOver="TemplateContent"
                                h:FluentAnimation.PointerOverAxis="Horizontal"
                                h:FluentAnimation.Pressed="TemplateContent">
                                <VisualState x:Name="Normal" />
                                <VisualState x:Name="Selected" />
                                <VisualState x:Name="PointerOver" />
                                <VisualState x:Name="PointerOverSelected" />
                                <VisualState x:Name="PointerOverPressed" />
                                <VisualState x:Name="Pressed" />
                                <VisualState x:Name="PressedSelected" />
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                    </ListViewItemPresenter>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="DefaultThemeGridViewItemStyle" TargetType="GridViewItem">
        <Setter Property="Background" Value="Transparent" />
        <Setter Property="BorderThickness" Value="1" />
        <Setter Property="Foreground" Value="{ThemeResource SystemControlForegroundBaseHighBrush}" />
        <Setter Property="TabNavigation" Value="Local" />
        <Setter Property="IsHoldingEnabled" Value="False" />
        <Setter Property="HorizontalContentAlignment" Value="Stretch" />
        <Setter Property="VerticalContentAlignment" Value="Stretch" />
        <Setter Property="Margin" Value="0,0,4,4" />
        <Setter Property="AllowDrop" Value="False" />
        <Setter Property="UseSystemFocusVisuals" Value="True" />
        <Setter Property="h:FluentAnimation.Pressed" Value="TemplateContent" />
        <Setter Property="h:FluentAnimation.PointerOver" Value="TemplateContent" />
        <Setter Property="h:FluentAnimation.PointerOverOffset" Value="-3" />
        <Setter Property="FocusVisualMargin" Value="-2" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="GridViewItem">
                    <ContentPresenter
                        x:Name="ContentPresenter"
                        Margin="{TemplateBinding Padding}"
                        HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                        VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                        Background="{TemplateBinding Background}"
                        BackgroundTransition="{StaticResource QuickBrushTransition}"
                        BorderBrush="{TemplateBinding BorderBrush}"
                        BorderThickness="{TemplateBinding BorderThickness}"
                        ContentTransitions="{TemplateBinding ContentTransitions}"
                        Control.IsTemplateFocusTarget="True"
                        CornerRadius="4"
                        FocusVisualMargin="{TemplateBinding FocusVisualMargin}"
                        FocusVisualSecondaryBrush="{ThemeResource SystemControlHighlightListLowBrush}"
                        FocusVisualSecondaryThickness="2">
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal" />

                                <VisualState x:Name="PointerOver">
                                    <VisualState.Setters>
                                        <Setter Target="ContentPresenter.BorderBrush" Value="{ThemeResource CardStrokeColorDefaultBrush}" />
                                        <Setter Target="ContentPresenter.BorderThickness" Value="1" />
                                    </VisualState.Setters>
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContentPresenter" Storyboard.TargetProperty="Background">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource CardBackgroundFillColorSecondaryBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>

                                <VisualState x:Name="Pressed">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContentPresenter" Storyboard.TargetProperty="Background">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource CardBackgroundFillColorSecondaryBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>

                                <VisualState x:Name="Selected">
                                    <VisualState.Setters>
                                        <Setter Target="ContentPresenter.BorderBrush" Value="{ThemeResource CardStrokeColorDefaultBrush}" />
                                        <Setter Target="ContentPresenter.BorderThickness" Value="1" />
                                    </VisualState.Setters>
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContentPresenter" Storyboard.TargetProperty="Background">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource CardBackgroundFillColorDefaultBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>

                                <VisualState x:Name="PointerOverSelected">
                                    <VisualState.Setters>
                                        <Setter Target="ContentPresenter.BorderBrush" Value="{ThemeResource CardStrokeColorDefaultBrush}" />
                                        <Setter Target="ContentPresenter.BorderThickness" Value="1" />
                                    </VisualState.Setters>
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContentPresenter" Storyboard.TargetProperty="Background">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource CardBackgroundFillColorSecondaryBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>

                                <VisualState x:Name="PressedSelected">
                                    <VisualState.Setters>
                                        <Setter Target="ContentPresenter.BorderBrush" Value="{ThemeResource CardStrokeColorDefaultBrush}" />
                                        <Setter Target="ContentPresenter.BorderThickness" Value="1" />
                                    </VisualState.Setters>
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContentPresenter" Storyboard.TargetProperty="Background">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource CardBackgroundFillColorSecondaryBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                    </ContentPresenter>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="DefaultThemeGridViewItemStyle2" TargetType="GridViewItem">
        <Setter Property="FontFamily" Value="{ThemeResource ContentControlThemeFontFamily}" />
        <Setter Property="FontSize" Value="{ThemeResource ControlContentThemeFontSize}" />
        <Setter Property="Background" Value="{ThemeResource GridViewItemBackground}" />
        <Setter Property="Foreground" Value="{ThemeResource GridViewItemForeground}" />
        <Setter Property="TabNavigation" Value="Local" />
        <Setter Property="IsHoldingEnabled" Value="True" />
        <Setter Property="HorizontalContentAlignment" Value="Center" />
        <Setter Property="VerticalContentAlignment" Value="Center" />
        <Setter Property="Margin" Value="0,0,4,4" />
        <Setter Property="MinWidth" Value="{ThemeResource GridViewItemMinWidth}" />
        <Setter Property="MinHeight" Value="{ThemeResource GridViewItemMinHeight}" />
        <Setter Property="AllowDrop" Value="False" />
        <Setter Property="UseSystemFocusVisuals" Value="{StaticResource UseSystemFocusVisuals}" />
        <Setter Property="CornerRadius" Value="4" />
        <Setter Property="FocusVisualMargin" Value="-2" />
        <Setter Property="FocusVisualPrimaryBrush" Value="{ThemeResource GridViewItemFocusVisualPrimaryBrush}" />
        <Setter Property="FocusVisualPrimaryThickness" Value="2" />
        <Setter Property="FocusVisualSecondaryBrush" Value="{ThemeResource GridViewItemFocusVisualSecondaryBrush}" />
        <Setter Property="FocusVisualSecondaryThickness" Value="1" />
        <Setter Property="h:FluentAnimation.PointerOverOffset" Value="-3" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="GridViewItem">
                    <ListViewItemPresenter
                        x:Name="Root"
                        HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"
                        VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}"
                        CheckBoxBrush="{ThemeResource GridViewItemCheckBoxBrush}"
                        CheckBrush="{ThemeResource GridViewItemCheckBrush}"
                        CheckMode="{ThemeResource GridViewItemCheckMode}"
                        ContentMargin="{TemplateBinding Padding}"
                        ContentTransitions="{TemplateBinding ContentTransitions}"
                        Control.IsTemplateFocusTarget="True"
                        CornerRadius="{TemplateBinding CornerRadius}"
                        DisabledOpacity="{ThemeResource ListViewItemDisabledThemeOpacity}"
                        DragBackground="{ThemeResource GridViewItemDragBackground}"
                        DragForeground="{ThemeResource GridViewItemDragForeground}"
                        DragOpacity="{ThemeResource ListViewItemDragThemeOpacity}"
                        FocusBorderBrush="{ThemeResource GridViewItemFocusBorderBrush}"
                        FocusSecondaryBorderBrush="{ThemeResource GridViewItemFocusSecondaryBorderBrush}"
                        FocusVisualMargin="{TemplateBinding FocusVisualMargin}"
                        FocusVisualPrimaryBrush="{TemplateBinding FocusVisualPrimaryBrush}"
                        FocusVisualPrimaryThickness="{TemplateBinding FocusVisualPrimaryThickness}"
                        FocusVisualSecondaryBrush="{TemplateBinding FocusVisualSecondaryBrush}"
                        FocusVisualSecondaryThickness="{TemplateBinding FocusVisualSecondaryThickness}"
                        PlaceholderBackground="{ThemeResource GridViewItemPlaceholderBackground}"
                        PointerOverBackground="{ThemeResource GridViewItemBackgroundPointerOver}"
                        PointerOverForeground="{ThemeResource GridViewItemForegroundPointerOver}"
                        PressedBackground="{ThemeResource GridViewItemBackgroundPressed}"
                        ReorderHintOffset="{ThemeResource GridViewItemReorderHintThemeOffset}"
                        SelectedBackground="{ThemeResource GridViewItemBackgroundSelected}"
                        SelectedForeground="{ThemeResource GridViewItemForegroundSelected}"
                        SelectedPointerOverBackground="{ThemeResource GridViewItemBackgroundSelectedPointerOver}"
                        SelectedPressedBackground="{ThemeResource GridViewItemBackgroundSelectedPressed}"
                        SelectionCheckMarkVisualEnabled="{ThemeResource GridViewItemSelectionCheckMarkVisualEnabled}">
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup
                                x:Name="CommonStates"
                                h:FluentAnimation.PointerOver="TemplateContent"
                                h:FluentAnimation.PointerOverAxis="Horizontal"
                                h:FluentAnimation.Pressed="TemplateContent">
                                <VisualState x:Name="Normal" />
                                <VisualState x:Name="Selected" />
                                <VisualState x:Name="PointerOver" />
                                <VisualState x:Name="PointerOverSelected" />
                                <VisualState x:Name="PointerOverPressed" />
                                <VisualState x:Name="Pressed" />
                                <VisualState x:Name="PressedSelected" />
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                    </ListViewItemPresenter>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style TargetType="muxc:RadioButtons">
        <Setter Property="Background" Value="{ThemeResource CardBackgroundFillColorDefaultBrush}" />
        <Setter Property="BorderBrush" Value="{ThemeResource CardStrokeColorDefaultBrush}" />
        <Setter Property="BorderThickness" Value="1" />
        <Setter Property="CornerRadius" Value="{ThemeResource ControlCornerRadius}" />
        <Setter Property="IsTabStop" Value="False" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="muxc:RadioButtons">
                    <Grid
                        x:Name="ControlRoot"
                        Background="{TemplateBinding Background}"
                        BackgroundTransition="{StaticResource QuickBackgroundTransition}"
                        BorderBrush="{TemplateBinding BorderBrush}"
                        BorderThickness="{TemplateBinding BorderThickness}"
                        CornerRadius="{TemplateBinding CornerRadius}">
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal" />
                                <VisualState x:Name="Disabled">
                                    <VisualState.Setters>
                                        <Setter Target="ControlRoot.Opacity" Value="0.4" />
                                    </VisualState.Setters>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <muxc:ItemsRepeater x:Name="InnerRepeater">
                            <muxc:ItemsRepeater.Layout>
                                <primitives:ColumnMajorUniformToLargestGridLayout
                                    ColumnSpacing="{TemplateBinding Tag}"
                                    RowSpacing="{ThemeResource RadioButtonsRowSpacing}"
                                    MaxColumns="{Binding MaxColumns, RelativeSource={RelativeSource Mode=TemplatedParent}}" />
                            </muxc:ItemsRepeater.Layout>
                        </muxc:ItemsRepeater>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="DefaultSettingsPresenterStyle" TargetType="controls:SettingsPresenter">
        <Setter Property="IsTabStop" Value="False" />
        <Setter Property="Padding" Value="16,14,16,14" />
        <Setter Property="FontFamily" Value="{StaticResource ContentControlThemeFontFamily}" />
        <Setter Property="CornerRadius" Value="4" />
        <Setter Property="MinHeight" Value="67" />
        <Setter Property="IconSize" Value="24" />
        <Setter Property="VerticalContentAlignment" Value="Center" />
        <Setter Property="Background" Value="{ThemeResource CardBackgroundFillColorDefaultBrush}" />
        <Setter Property="BorderBrush" Value="{ThemeResource CardStrokeColorDefaultBrush}" />
        <Setter Property="BorderThickness" Value="1" />
        <Setter Property="Margin" Value="0 4" />
        <Setter Property="BottomCornerRadius" Value="0 0 4 4" />
        <Setter Property="ItemsPanel">
            <Setter.Value>
                <ItemsPanelTemplate>
                    <StackPanel Spacing="0" />
                </ItemsPanelTemplate>
            </Setter.Value>
        </Setter>
        <Setter Property="ItemContainerStyle">
            <Setter.Value>
                <Style TargetType="ContentPresenter">
                    <Setter Property="BorderThickness" Value="0 0 0 1" />
                    <Setter Property="Background" Value="{ThemeResource LayerFillColorDefaultBrush}" />
                    <Setter Property="Padding" Value="16 8 16 8" />
                    <Setter Property="BorderBrush" Value="{ThemeResource CardStrokeColorDefaultBrush}" />
                </Style>
            </Setter.Value>
        </Setter>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="controls:SettingsPresenter">
                    <Grid>
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="PlacementGroups">
                                <VisualState x:Name="RightPlacementState" />
                                <VisualState x:Name="BottomPlacementState">
                                    <VisualState.Setters>
                                        <Setter Target="Presenter.(Grid.Row)" Value="1" />
                                        <Setter Target="Presenter.(Grid.Column)" Value="1" />
                                        <Setter Target="Presenter.Margin" Value="0 12 0 0" />
                                        <Setter Target="TopRow.Height" Value="Auto" />
                                        <Setter Target="BottomRow.Height" Value="*" />
                                    </VisualState.Setters>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="IconStates">
                                <VisualState x:Name="NoIconState" />
                                <VisualState x:Name="IconState">
                                    <VisualState.Setters>
                                        <Setter Target="IconPresenter.Visibility" Value="Visible" />
                                    </VisualState.Setters>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="DescriptionStates">
                                <VisualState x:Name="NoDescriptionState" />
                                <VisualState x:Name="DescriptionState">
                                    <VisualState.Setters>
                                        <Setter Target="Description.Visibility" Value="Visible" />
                                    </VisualState.Setters>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="ItemsGroup">
                                <VisualState x:Name="NoItemsState" />
                                <VisualState x:Name="HasItemsState">
                                    <VisualState.Setters>
                                        <Setter Target="TopCardRoot.CornerRadius" Value="4 4 0 0" />
                                        <Setter Target="ItemsRoot.Visibility" Value="Visible" />
                                    </VisualState.Setters>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <Grid.RowDefinitions>
                            <RowDefinition Height="*" />
                            <RowDefinition Height="Auto" />
                        </Grid.RowDefinitions>
                        <Grid
                            x:Name="TopCardRoot"
                            Padding="{TemplateBinding Padding}"
                            VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                            Background="{TemplateBinding Background}"
                            BackgroundTransition="{StaticResource QuickBrushTransition}"
                            BorderBrush="{TemplateBinding BorderBrush}"
                            BorderThickness="{TemplateBinding BorderThickness}"
                            CornerRadius="{TemplateBinding CornerRadius}">
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="Auto" />
                                <ColumnDefinition Width="*" />
                                <ColumnDefinition Width="Auto" />
                            </Grid.ColumnDefinitions>
                            <Grid.RowDefinitions>
                                <RowDefinition x:Name="TopRow" Height="*" />
                                <RowDefinition x:Name="BottomRow" Height="Auto" />
                            </Grid.RowDefinitions>

                            <ContentControl
                                x:Name="IconPresenter"
                                x:Load="False"
                                Width="{TemplateBinding IconSize}"
                                Height="{TemplateBinding IconSize}"
                                Margin="0 0 18 0"
                                Visibility="Collapsed" />

                            <Grid
                                Grid.Column="1"
                                HorizontalAlignment="Stretch"
                                VerticalAlignment="Center"
                                Transitions="{StaticResource RepositionTransitions}">
                                <Grid.RowDefinitions>
                                    <RowDefinition Height="Auto" />
                                    <RowDefinition Height="Auto" />
                                </Grid.RowDefinitions>
                                <ContentPresenter
                                    HorizontalAlignment="Stretch"
                                    Content="{TemplateBinding Title}"
                                    FontFamily="{TemplateBinding FontFamily}"
                                    FontSize="14" />
                                <ContentPresenter
                                    x:Name="Description"
                                    x:Load="False"
                                    Grid.Row="1"
                                    Margin="0 2 0 0"
                                    Content="{TemplateBinding Description}"
                                    FontFamily="{TemplateBinding FontFamily}"
                                    FontSize="12.666"
                                    Foreground="{ThemeResource TextFillColorSecondaryBrush}"
                                    TextWrapping="Wrap"
                                    Visibility="Collapsed" />
                            </Grid>

                            <ContentPresenter
                                x:Name="Presenter"
                                Grid.Column="2"
                                Margin="18 0 0 0"
                                Content="{TemplateBinding Content}"
                                FontFamily="{TemplateBinding FontFamily}" />
                        </Grid>

                        <Border
                            x:Name="ItemsRoot"
                            x:Load="False"
                            Grid.Row="1"
                            core:Properties.ClipToBounds="True"
                            Visibility="Collapsed">
                            <!--  Animate the border below  -->
                            <Border
                                BorderBrush="{TemplateBinding BorderBrush}"
                                BorderThickness="1 0 1 1"
                                CornerRadius="{TemplateBinding BottomCornerRadius}">
                                <ItemsPresenter Margin="0 0 0 -2" />
                            </Border>
                        </Border>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="SubItemSettingsPresenterStyle" BasedOn="{StaticResource DefaultSettingsPresenterStyle}" TargetType="controls:SettingsPresenter">
        <Setter Property="Padding" Value="0 0 0 0" />
        <Setter Property="BorderThickness" Value="0" />
        <Setter Property="CornerRadius" Value="0" />
        <Setter Property="Margin" Value="0" />
        <Setter Property="Background" Value="Transparent" />
    </Style>

    <Style TargetType="controls:ContentGroup">
        <Setter Property="IsTabStop" Value="False" />
        <Setter Property="Padding" Value="16,14,16,14" />
        <Setter Property="FontFamily" Value="{StaticResource ContentControlThemeFontFamily}" />
        <Setter Property="CornerRadius" Value="4" />
        <Setter Property="MinHeight" Value="67" />
        <Setter Property="Background" Value="{ThemeResource CardBackgroundFillColorDefaultBrush}" />
        <Setter Property="BorderBrush" Value="{ThemeResource CardStrokeColorDefaultBrush}" />
        <Setter Property="BorderThickness" Value="1" />
        <Setter Property="Margin" Value="0 8 0 4" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="controls:ContentGroup">
                    <StackPanel>
                        <TextBlock
                            Margin="0 12"
                            FontWeight="SemiBold"
                            Text="{TemplateBinding Text}" />

                        <Grid
                            Padding="{TemplateBinding Padding}"
                            Background="{TemplateBinding Background}"
                            BackgroundTransition="{StaticResource RootBackgroundTransition}"
                            BorderBrush="{TemplateBinding BorderBrush}"
                            BorderThickness="{TemplateBinding BorderThickness}"
                            CornerRadius="{TemplateBinding CornerRadius}">
                            <ItemsPresenter Margin="0 0" />
                        </Grid>
                    </StackPanel>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="QuickCompareContainerStyle" BasedOn="{StaticResource ChromelessButtonStyle}" TargetType="Button">
        <Setter Property="IsTabStop" Value="False" />
        <Setter Property="Padding" Value="16,14,16,4" />
        <Setter Property="FontFamily" Value="{StaticResource ContentControlThemeFontFamily}" />
        <Setter Property="CornerRadius" Value="4" />
        <Setter Property="VerticalAlignment" Value="Stretch" />
        <Setter Property="MinHeight" Value="0" />
        <Setter Property="Background" Value="{ThemeResource CardBackgroundFillColorDefaultBrush}" />
        <Setter Property="BorderBrush" Value="{ThemeResource CardStrokeColorDefaultBrush}" />
        <Setter Property="BorderThickness" Value="1" />
        <Setter Property="Margin" Value="0 8 0 4" />
        <Setter Property="h:FluentAnimation.PointerOverOffset" Value="-4" />
        <Setter Property="h:FluentAnimation.PointerOver" Value="ContentGroupRoot" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="Button">
                    <ContentPresenter
                        x:Name="Presenter"
                        Padding="{TemplateBinding Padding}"
                        Background="{TemplateBinding Background}"
                        BackgroundTransition="{StaticResource RootBackgroundTransition}"
                        BorderBrush="{TemplateBinding BorderBrush}"
                        BorderThickness="{TemplateBinding BorderThickness}"
                        Content="{TemplateBinding Content}"
                        CornerRadius="{TemplateBinding CornerRadius}">
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal">
                                    <Storyboard>
                                        <PointerUpThemeAnimation Storyboard.TargetName="Presenter" />
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="PointerOver">
                                    <VisualState.Setters>
                                        <Setter Target="Presenter.Background" Value="{ThemeResource ButtonBackgroundPointerOver}" />
                                        <Setter Target="Presenter.BorderBrush" Value="{ThemeResource ButtonBorderBrushPointerOver}" />
                                    </VisualState.Setters>
                                    <Storyboard>
                                        <PointerUpThemeAnimation Storyboard.TargetName="Presenter" />
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Pressed">
                                    <Storyboard>
                                        <PointerDownThemeAnimation Storyboard.TargetName="Presenter" />
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="Presenter" Storyboard.TargetProperty="Background">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource CardBackgroundFillColorSecondaryBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                    </ContentPresenter>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="CompareCardStyle" TargetType="controls:ContentGroup">
        <Setter Property="IsTabStop" Value="False" />
        <Setter Property="h:FluentAnimation.PointerOverOffset" Value="-4" />
        <Setter Property="h:FluentAnimation.PointerOver" Value="ContentBorder" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="controls:ContentGroup">
                    <Grid x:Name="ContentGroupRoot" RowSpacing="4">
                        <Grid.RowDefinitions>
                            <RowDefinition Height="*" />
                            <RowDefinition Height="Auto" />
                            <RowDefinition Height="4" />
                        </Grid.RowDefinitions>

                        <ContentPresenter
                            x:Name="Title"
                            Grid.Row="1"
                            Content="{TemplateBinding Text}"
                            FontWeight="Normal" />

                        <ContentPresenter Content="{TemplateBinding SecondaryContent}" />
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style TargetType="GridViewItem">
        <Setter Property="Background" Value="Transparent" />
        <Setter Property="BorderThickness" Value="1" />
        <Setter Property="Foreground" Value="{ThemeResource SystemControlForegroundBaseHighBrush}" />
        <Setter Property="TabNavigation" Value="Local" />
        <Setter Property="IsHoldingEnabled" Value="False" />
        <Setter Property="HorizontalContentAlignment" Value="Stretch" />
        <Setter Property="VerticalContentAlignment" Value="Stretch" />
        <Setter Property="Margin" Value="0,0,4,4" />
        <Setter Property="AllowDrop" Value="False" />
        <Setter Property="UseSystemFocusVisuals" Value="True" />
        <Setter Property="FocusVisualMargin" Value="-2" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="GridViewItem">
                    <ContentPresenter
                        x:Name="ContentPresenter"
                        Margin="{TemplateBinding Padding}"
                        HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                        VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                        Background="{TemplateBinding Background}"
                        BackgroundTransition="{StaticResource QuickBrushTransition}"
                        BorderBrush="{TemplateBinding BorderBrush}"
                        BorderThickness="{TemplateBinding BorderThickness}"
                        ContentTransitions="{TemplateBinding ContentTransitions}"
                        Control.IsTemplateFocusTarget="True"
                        CornerRadius="4"
                        FocusVisualMargin="{TemplateBinding FocusVisualMargin}"
                        FocusVisualSecondaryBrush="{ThemeResource SystemControlHighlightListLowBrush}"
                        FocusVisualSecondaryThickness="2">
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal" />

                                <VisualState x:Name="PointerOver">
                                    <VisualState.Setters>
                                        <Setter Target="ContentPresenter.BorderBrush" Value="{ThemeResource CardStrokeColorDefaultBrush}" />
                                        <Setter Target="ContentPresenter.BorderThickness" Value="1" />
                                    </VisualState.Setters>
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContentPresenter" Storyboard.TargetProperty="Background">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource CardBackgroundFillColorSecondaryBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>

                                <VisualState x:Name="Pressed">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContentPresenter" Storyboard.TargetProperty="Background">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource CardBackgroundFillColorSecondaryBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>

                                <VisualState x:Name="Selected">
                                    <VisualState.Setters>
                                        <Setter Target="ContentPresenter.BorderBrush" Value="{ThemeResource CardStrokeColorDefaultBrush}" />
                                        <Setter Target="ContentPresenter.BorderThickness" Value="1" />
                                    </VisualState.Setters>
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContentPresenter" Storyboard.TargetProperty="Background">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource CardBackgroundFillColorDefaultBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>

                                <VisualState x:Name="PointerOverSelected">
                                    <VisualState.Setters>
                                        <Setter Target="ContentPresenter.BorderBrush" Value="{ThemeResource CardStrokeColorDefaultBrush}" />
                                        <Setter Target="ContentPresenter.BorderThickness" Value="1" />
                                    </VisualState.Setters>
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContentPresenter" Storyboard.TargetProperty="Background">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource CardBackgroundFillColorSecondaryBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>

                                <VisualState x:Name="PressedSelected">
                                    <VisualState.Setters>
                                        <Setter Target="ContentPresenter.BorderBrush" Value="{ThemeResource CardStrokeColorDefaultBrush}" />
                                        <Setter Target="ContentPresenter.BorderThickness" Value="1" />
                                    </VisualState.Setters>
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContentPresenter" Storyboard.TargetProperty="Background">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource CardBackgroundFillColorSecondaryBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                    </ContentPresenter>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <DataTemplate x:Key="FontListGroupHeaderTemplate">
        <controls:UXButton
            x:Name="Root"
            Margin="0"
            Padding="0"
            HorizontalAlignment="Stretch"
            HorizontalContentAlignment="Stretch"
            IsHitTestVisible="True"
            Style="{StaticResource TransparentButton}">
            <Grid>
                <Border
                    Margin="15,0"
                    BorderBrush="{ThemeResource ApplicationForegroundThemeBrush}"
                    BorderThickness="0,0,0,1"
                    Opacity="0.2" />
                <TextBlock
                    x:Name="Text"
                    Padding="15,8,15,10"
                    HorizontalAlignment="Stretch"
                    VerticalAlignment="Stretch"
                    FontSize="30"
                    FontWeight="SemiBold"
                    Text="{Binding Key}" />
            </Grid>
        </controls:UXButton>
    </DataTemplate>

    <Style x:Key="FontListGridViewItemStyle" BasedOn="{StaticResource DefaultGridViewItemStyle}" TargetType="GridViewItem">
        <Setter Property="core:Properties.PointerOverAnimation" Value="Text" />
        <Setter Property="h:FluentAnimation.PointerOverAxis" Value="Horizontal" />
    </Style>

    <Style TargetType="toolkit:GridSplitter">
        <Setter Property="IsTabStop" Value="True" />
        <Setter Property="UseSystemFocusVisuals" Value="True" />
        <Setter Property="HorizontalAlignment" Value="Stretch" />
        <Setter Property="VerticalAlignment" Value="Stretch" />
        <Setter Property="IsFocusEngagementEnabled" Value="True" />
        <Setter Property="MinWidth" Value="12" />
        <Setter Property="MinHeight" Value="16" />
        <Setter Property="BorderThickness" Value="0 0" />
        <Setter Property="Background" Value="{ThemeResource SystemControlHighlightChromeHighBrush}" />
        <Setter Property="GripperForeground" Value="{ThemeResource SystemControlForegroundAltHighBrush}" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="toolkit:GridSplitter">
                    <Grid
                        x:Name="RootGrid"
                        Background="{TemplateBinding Background}"
                        BorderBrush="{TemplateBinding BorderBrush}"
                        BorderThickness="{TemplateBinding BorderThickness}">
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="GridSplitterStates">
                                <VisualState x:Name="Normal" />
                                <VisualState x:Name="PointerOver">
                                    <VisualState.Setters>
                                        <Setter Target="RootGrid.Background" Value="{ThemeResource AppBarButtonBackgroundPointerOver}" />
                                    </VisualState.Setters>
                                </VisualState>
                                <VisualState x:Name="Pressed">
                                    <VisualState.Setters>
                                        <Setter Target="RootGrid.Background" Value="{ThemeResource AppBarButtonBackgroundPressed}" />
                                    </VisualState.Setters>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <ContentPresenter
                            HorizontalContentAlignment="Stretch"
                            VerticalContentAlignment="Stretch"
                            Content="{TemplateBinding Element}" />
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>




    <!--  FLYOUT  -->

    <x:Double x:Key="FontListFlyoutFontSize">14</x:Double>

    <Style x:Key="FontListFlyoutStyle" TargetType="MenuFlyoutPresenter">
        <Setter Property="FontSize" Value="{StaticResource FontListFlyoutFontSize}" />
        <Setter Property="CornerRadius" Value="8" />
        <Setter Property="Margin" Value="0 -4 0 0" />
        <Setter Property="Padding" Value="0" />
        <Setter Property="BorderThickness" Value="1" />
    </Style>

    <Style x:Key="DefaultFlyoutStyle" BasedOn="{StaticResource FontListFlyoutStyle}" TargetType="MenuFlyoutPresenter" />

    <Style x:Key="ThemeMenuFlyoutItemStyle" TargetType="MenuFlyoutItem">
        <Setter Property="Background" Value="{ThemeResource MenuFlyoutItemBackground}" />
        <Setter Property="BorderBrush" Value="{ThemeResource MenuFlyoutItemBackgroundBrush}" />
        <Setter Property="BorderThickness" Value="{ThemeResource MenuFlyoutItemBorderThickness}" />
        <Setter Property="Foreground" Value="{ThemeResource MenuFlyoutItemForeground}" />
        <Setter Property="Padding" Value="{StaticResource MenuFlyoutItemThemePadding}" />
        <Setter Property="FontSize" Value="{ThemeResource ControlContentThemeFontSize}" />
        <Setter Property="HorizontalContentAlignment" Value="Stretch" />
        <Setter Property="VerticalContentAlignment" Value="Center" />
        <Setter Property="UseSystemFocusVisuals" Value="{StaticResource UseSystemFocusVisuals}" />
        <Setter Property="KeyboardAcceleratorPlacementMode" Value="Hidden" />
        <Setter Property="CornerRadius" Value="{ThemeResource ControlCornerRadius}" />
        <Setter Property="h:FluentAnimation.PointerDownScale" Value="0.95" />
        <Setter Property="h:FluentAnimation.PointerOverAxis" Value="Horizontal" />
        <Setter Property="h:FluentAnimation.PointerOverOffset" Value="3" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="MenuFlyoutItem">
                    <Border
                        x:Name="LayoutRoot"
                        Margin="{StaticResource MenuFlyoutItemMargin}"
                        Padding="{TemplateBinding Padding}"
                        Background="{TemplateBinding Background}"
                        BackgroundTransition="{StaticResource BackgroundTransition}"
                        BorderBrush="{TemplateBinding BorderBrush}"
                        BorderThickness="{TemplateBinding BorderThickness}"
                        CornerRadius="{TemplateBinding CornerRadius}">
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup
                                x:Name="CommonStates"
                                h:FluentAnimation.PointerOver="{Binding ElementName=TextBlock}"
                                h:FluentAnimation.Pressed="{Binding ElementName=ContentRoot}">
                                <VisualState x:Name="Normal" />
                                <VisualState x:Name="PointerOver">
                                    <VisualState.Setters>
                                        <Setter Target="LayoutRoot.Background" Value="{ThemeResource MenuFlyoutItemBackgroundPointerOver}" />
                                        <Setter Target="TextBlock.Foreground" Value="{ThemeResource MenuFlyoutItemForegroundPointerOver}" />
                                        <Setter Target="KeyboardAcceleratorTextBlock.Foreground" Value="{ThemeResource MenuFlyoutItemKeyboardAcceleratorTextForegroundPointerOver}" />
                                    </VisualState.Setters>
                                </VisualState>
                                <VisualState x:Name="Pressed">
                                    <VisualState.Setters>
                                        <Setter Target="LayoutRoot.Background" Value="{ThemeResource MenuFlyoutItemBackgroundPressed}" />
                                        <Setter Target="TextBlock.Foreground" Value="{ThemeResource MenuFlyoutItemForegroundPressed}" />
                                        <Setter Target="KeyboardAcceleratorTextBlock.Foreground" Value="{ThemeResource MenuFlyoutItemKeyboardAcceleratorTextForegroundPressed}" />
                                    </VisualState.Setters>
                                </VisualState>
                                <VisualState x:Name="Disabled">
                                    <VisualState.Setters>
                                        <Setter Target="LayoutRoot.Background" Value="{ThemeResource MenuFlyoutItemBackgroundDisabled}" />
                                        <Setter Target="TextBlock.Foreground" Value="{ThemeResource MenuFlyoutItemForegroundDisabled}" />
                                        <Setter Target="KeyboardAcceleratorTextBlock.Foreground" Value="{ThemeResource MenuFlyoutItemKeyboardAcceleratorTextForegroundDisabled}" />
                                    </VisualState.Setters>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="CheckPlaceholderStates">
                                <VisualState x:Name="NoPlaceholder" />
                                <VisualState x:Name="CheckPlaceholder">
                                    <VisualState.Setters>
                                        <Setter Target="TextBlock.Margin" Value="{ThemeResource MenuFlyoutItemPlaceholderThemeThickness}" />
                                    </VisualState.Setters>
                                </VisualState>
                                <VisualState x:Name="IconPlaceholder">
                                    <VisualState.Setters>
                                        <Setter Target="TextBlock.Margin" Value="{ThemeResource MenuFlyoutItemPlaceholderThemeThickness}" />
                                        <Setter Target="IconRoot.Visibility" Value="Visible" />
                                    </VisualState.Setters>
                                </VisualState>
                                <VisualState x:Name="CheckAndIconPlaceholder">
                                    <VisualState.Setters>
                                        <Setter Target="TextBlock.Margin" Value="{ThemeResource MenuFlyoutItemDoublePlaceholderThemeThickness}" />
                                        <Setter Target="IconRoot.Margin" Value="{ThemeResource MenuFlyoutItemPlaceholderThemeThickness}" />
                                        <Setter Target="IconRoot.Visibility" Value="Visible" />
                                    </VisualState.Setters>
                                </VisualState>
                            </VisualStateGroup>
                            <!--  Narrow padding is only applied when flyout was invoked with pen, mouse or keyboard.  -->
                            <!--  Default padding is applied for all other cases including touch.  -->
                            <VisualStateGroup x:Name="PaddingSizeStates">
                                <VisualState x:Name="DefaultPadding" />
                                <VisualState x:Name="NarrowPadding">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="LayoutRoot" Storyboard.TargetProperty="Padding">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource MenuFlyoutItemThemePaddingNarrow}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="KeyboardAcceleratorTextVisibility">
                                <VisualState x:Name="KeyboardAcceleratorTextCollapsed" />
                                <VisualState x:Name="KeyboardAcceleratorTextVisible">
                                    <VisualState.Setters>
                                        <Setter Target="KeyboardAcceleratorTextBlock.Visibility" Value="Visible" />
                                    </VisualState.Setters>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <Grid x:Name="ContentRoot">
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="*" />
                                <ColumnDefinition Width="Auto" />
                            </Grid.ColumnDefinitions>
                            <Viewbox
                                x:Name="IconRoot"
                                x:Load="False"
                                Width="16"
                                Height="16"
                                HorizontalAlignment="Left"
                                VerticalAlignment="Center"
                                Visibility="Collapsed">
                                <ContentPresenter Content="{TemplateBinding Icon}" Foreground="{Binding ElementName=TextBlock, Path=Foreground}" />
                            </Viewbox>
                            <TextBlock
                                x:Name="TextBlock"
                                HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                                VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                                Foreground="{TemplateBinding Foreground}"
                                Text="{TemplateBinding Text}"
                                TextTrimming="{ThemeResource MenuFlyoutItemTextTrimming}" />
                            <TextBlock
                                x:Name="KeyboardAcceleratorTextBlock"
                                x:Load="False"
                                Grid.Column="1"
                                MinWidth="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=TemplateSettings.KeyboardAcceleratorTextMinWidth}"
                                Margin="24,4,0,0"
                                HorizontalAlignment="Right"
                                VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                                AutomationProperties.AccessibilityView="Raw"
                                Foreground="{ThemeResource MenuFlyoutItemKeyboardAcceleratorTextForeground}"
                                HorizontalTextAlignment="Right"
                                Style="{ThemeResource CaptionTextBlockStyle}"
                                Text="{TemplateBinding KeyboardAcceleratorTextOverride}"
                                Visibility="Collapsed" />

                            <TextBlock
                                Grid.Column="1"
                                Margin="24,0,0,0"
                                HorizontalAlignment="Right"
                                VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                                FontFamily="{StaticResource SymbolThemeFontFamily}"
                                Foreground="{ThemeResource MenuFlyoutItemKeyboardAcceleratorTextForeground}"
                                HorizontalTextAlignment="Right"
                                Opacity="0.7"
                                Style="{ThemeResource CaptionTextBlockStyle}"
                                Text="{Binding RelativeSource={RelativeSource Mode=TemplatedParent}, Path=(core:Properties.IconString)}" />
                        </Grid>

                    </Border>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="ThemeMenuFlyoutSubItemStyle" TargetType="MenuFlyoutSubItem">
        <Setter Property="Background" Value="{ThemeResource MenuFlyoutSubItemBackground}" />
        <Setter Property="BorderBrush" Value="{ThemeResource MenuFlyoutSubItemBackgroundBrush}" />
        <Setter Property="BorderThickness" Value="{ThemeResource MenuFlyoutSubItemBorderThickness}" />
        <Setter Property="Foreground" Value="{ThemeResource MenuFlyoutSubItemForeground}" />
        <Setter Property="Padding" Value="{StaticResource MenuFlyoutItemThemePadding}" />
        <Setter Property="FontSize" Value="{ThemeResource ControlContentThemeFontSize}" />
        <Setter Property="HorizontalContentAlignment" Value="Stretch" />
        <Setter Property="VerticalContentAlignment" Value="Center" />
        <Setter Property="UseSystemFocusVisuals" Value="{StaticResource UseSystemFocusVisuals}" />
        <Setter Property="CornerRadius" Value="{ThemeResource ControlCornerRadius}" />
        <Setter Property="core:Properties.PointerOverAnimation" Value="SubItemChevron,TextBlock|X" />
        <Setter Property="core:Properties.PointerAnimationOffset" Value="3" />
        <Setter Property="h:FluentAnimation.PointerDownScale" Value="0.95" />
        <!--<Setter Property="h:FluentAnimation.PointerOverAxis" Value="Horizontal" />
        <Setter Property="h:FluentAnimation.PointerOverOffset" Value="4" />-->
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="MenuFlyoutSubItem">
                    <Grid
                        x:Name="LayoutRoot"
                        Margin="{StaticResource MenuFlyoutItemMargin}"
                        Padding="{TemplateBinding Padding}"
                        Background="{TemplateBinding Background}"
                        BackgroundTransition="{StaticResource BackgroundTransition}"
                        BorderBrush="{TemplateBinding BorderBrush}"
                        BorderThickness="{TemplateBinding BorderThickness}"
                        CornerRadius="{TemplateBinding CornerRadius}">

                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates" h:FluentAnimation.Pressed="{Binding ElementName=ContentRoot}">
                                <VisualState x:Name="Normal" />

                                <VisualState x:Name="PointerOver">
                                    <VisualState.Setters>
                                        <Setter Target="LayoutRoot.Background" Value="{ThemeResource MenuFlyoutSubItemBackgroundPointerOver}" />
                                        <Setter Target="TextBlock.Foreground" Value="{ThemeResource MenuFlyoutSubItemForegroundPointerOver}" />
                                        <Setter Target="SubItemChevron.Foreground" Value="{ThemeResource MenuFlyoutSubItemChevronPointerOver}" />
                                        <Setter Target="IconContent.Foreground" Value="{ThemeResource MenuFlyoutSubItemForegroundPointerOver}" />
                                    </VisualState.Setters>
                                </VisualState>

                                <VisualState x:Name="Pressed">
                                    <VisualState.Setters>
                                        <Setter Target="LayoutRoot.Background" Value="{ThemeResource MenuFlyoutSubItemBackgroundPressed}" />
                                        <Setter Target="TextBlock.Foreground" Value="{ThemeResource MenuFlyoutSubItemForegroundPressed}" />
                                        <Setter Target="SubItemChevron.Foreground" Value="{ThemeResource MenuFlyoutSubItemChevronPressed}" />
                                        <Setter Target="IconContent.Foreground" Value="{ThemeResource MenuFlyoutSubItemForegroundPressed}" />
                                    </VisualState.Setters>
                                </VisualState>
                                <VisualState x:Name="SubMenuOpened">
                                    <VisualState.Setters>
                                        <Setter Target="LayoutRoot.Background" Value="{ThemeResource MenuFlyoutSubItemBackgroundSubMenuOpened}" />
                                        <Setter Target="TextBlock.Foreground" Value="{ThemeResource MenuFlyoutSubItemForegroundSubMenuOpened}" />
                                        <Setter Target="SubItemChevron.Foreground" Value="{ThemeResource MenuFlyoutSubItemChevronSubMenuOpened}" />
                                        <Setter Target="IconContent.Foreground" Value="{ThemeResource MenuFlyoutSubItemForegroundSubMenuOpened}" />
                                    </VisualState.Setters>
                                </VisualState>

                                <VisualState x:Name="Disabled">
                                    <VisualState.Setters>
                                        <Setter Target="LayoutRoot.Background" Value="{ThemeResource MenuFlyoutSubItemBackgroundDisabled}" />
                                        <Setter Target="TextBlock.Foreground" Value="{ThemeResource MenuFlyoutSubItemForegroundDisabled}" />
                                        <Setter Target="SubItemChevron.Foreground" Value="{ThemeResource MenuFlyoutSubItemChevronDisabled}" />
                                        <Setter Target="IconContent.Foreground" Value="{ThemeResource MenuFlyoutSubItemForegroundDisabled}" />
                                    </VisualState.Setters>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="CheckPlaceholderStates">
                                <VisualState x:Name="NoPlaceholder" />
                                <VisualState x:Name="CheckPlaceholder">
                                    <VisualState.Setters>
                                        <Setter Target="TextBlock.Margin" Value="{ThemeResource MenuFlyoutItemPlaceholderThemeThickness}" />
                                    </VisualState.Setters>
                                </VisualState>
                                <VisualState x:Name="IconPlaceholder">
                                    <VisualState.Setters>
                                        <Setter Target="TextBlock.Margin" Value="{ThemeResource MenuFlyoutItemPlaceholderThemeThickness}" />
                                        <Setter Target="IconRoot.Visibility" Value="Visible" />
                                    </VisualState.Setters>
                                </VisualState>
                                <VisualState x:Name="CheckAndIconPlaceholder">
                                    <VisualState.Setters>
                                        <Setter Target="TextBlock.Margin" Value="{ThemeResource MenuFlyoutItemDoublePlaceholderThemeThickness}" />
                                        <Setter Target="IconRoot.Margin" Value="{ThemeResource MenuFlyoutItemPlaceholderThemeThickness}" />
                                        <Setter Target="IconRoot.Visibility" Value="Visible" />
                                    </VisualState.Setters>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="PaddingSizeStates">
                                <VisualState x:Name="DefaultPadding" />
                                <VisualState x:Name="NarrowPadding">

                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="LayoutRoot" Storyboard.TargetProperty="Padding">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource MenuFlyoutItemThemePaddingNarrow}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>

                        </VisualStateManager.VisualStateGroups>
                        <Grid Name="ContentRoot">
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="*" />
                                <ColumnDefinition Width="Auto" />
                            </Grid.ColumnDefinitions>
                            <Viewbox
                                x:Name="IconRoot"
                                Grid.Column="0"
                                Width="16"
                                Height="16"
                                HorizontalAlignment="Left"
                                VerticalAlignment="Center"
                                Visibility="Collapsed">
                                <ContentPresenter x:Name="IconContent" Content="{TemplateBinding Icon}" />
                            </Viewbox>
                            <TextBlock
                                x:Name="TextBlock"
                                Grid.Column="0"
                                HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                                VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                                Foreground="{TemplateBinding Foreground}"
                                Text="{TemplateBinding Text}"
                                TextTrimming="{ThemeResource MenuFlyoutItemTextTrimming}" />
                            <FontIcon
                                x:Name="SubItemChevron"
                                Grid.Column="1"
                                Margin="{StaticResource MenuFlyoutItemChevronMargin}"
                                AutomationProperties.AccessibilityView="Raw"
                                FontFamily="{ThemeResource SymbolThemeFontFamily}"
                                FontSize="12"
                                Foreground="{ThemeResource MenuFlyoutSubItemChevron}"
                                Glyph="&#xE974;"
                                MirroredWhenRightToLeft="True" />
                        </Grid>

                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style BasedOn="{StaticResource DefaultMenuFlyoutItemStyle}" TargetType="MenuFlyoutItem" />




    <!--  CHECKBOX  -->
    <Style x:Key="DefaultThemeCheckBoxStyle" BasedOn="{StaticResource DefaultCheckBoxStyle}" TargetType="CheckBox">
        <Setter Property="core:Properties.PointerOverAnimation" Value="ContentPresenter|X" />
        <Setter Property="core:Properties.PointerAnimationOffset" Value="3" />
        <Setter Property="core:Properties.PointerPressedAnimation" Value="ContentPresenter|Scale" />
        <Setter Property="core:Properties.ClickAnimation" Value="ContentPresenter|Scale" />
        <Setter Property="core:Properties.ClickAnimationOffset" Value="0.93" />
        <Setter Property="Padding" Value="8,5,4,0" />
        <!--<Setter Property="h:FluentAnimation.PointerOver" Value="ContentPresenter" />
        <Setter Property="h:FluentAnimation.Pressed" Value="ContentPresenter" />
        <Setter Property="h:FluentAnimation.PointerDownScale" Value="0.93" />-->
    </Style>




    <!--  RADIOBUTTON  -->
    <Style x:Key="DefaultThemeRadioButtonStyle" BasedOn="{StaticResource DefaultRadioButtonStyle}" TargetType="controls:UXRadioButton">
        <Setter Property="Padding" Value="8,6,3,0" />
        <Setter Property="h:FluentAnimation.PointerDownScale" Value="0.95" />
        <Setter Property="h:FluentAnimation.PointerOver" Value="ContentPresenter" />
        <Setter Property="h:FluentAnimation.PointerOverAxis" Value="Horizontal" />
        <Setter Property="h:FluentAnimation.PointerOverOffset" Value="3" />
        <Setter Property="h:FluentAnimation.Pressed" Value="ContentPresenter" />
        <Setter Property="h:FluentAnimation.UsePointerOver" Value="True" />
    </Style>




    <!--  COMBOBOX  -->

    <Style x:Key="DefaultThemeComboBoxStyle" BasedOn="{StaticResource DefaultComboBoxStyle}" TargetType="controls:UXComboBox">
        <Setter Property="CornerRadius" Value="4" />
        <Setter Property="h:FluentAnimation.PointerOverOffset" Value="3" />
        <Setter Property="h:FluentAnimation.PointerOver" Value="DropDownGlyph" />
        <Setter Property="h:FluentAnimation.Pressed" Value="ContentPresenter" />
        <Setter Property="h:FluentAnimation.PointerDownScale" Value="0.95" />
    </Style>

    <Style BasedOn="{StaticResource DefaultThemeComboBoxStyle}" TargetType="controls:UXComboBox" />

    <!--<Style x:Key="DefaultThemeComboBoxItemStyle" BasedOn="{StaticResource DefaultComboBoxItemStyle}" TargetType="ComboBoxItem">
        <Setter Property="h:FluentAnimation.PointerOverOffset" Value="3" />
        <Setter Property="h:FluentAnimation.PointerOverAxis" Value="Horizontal" />
        <Setter Property="h:FluentAnimation.PointerOver" Value="ContentPresenter" />
        <Setter Property="h:FluentAnimation.Pressed" Value="ContentPresenter" />
        <Setter Property="h:FluentAnimation.PointerDownScale" Value="0.95" />
    </Style>-->

    <Style x:Key="DefaultThemeComboBoxItemStyle" BasedOn="{StaticResource DefaultComboBoxItemStyle}" TargetType="controls:UXComboBoxItem">
        <Setter Property="h:FluentAnimation.PointerOverOffset" Value="3" />
        <Setter Property="h:FluentAnimation.PointerOverAxis" Value="Horizontal" />
        <Setter Property="h:FluentAnimation.PointerOver" Value="ContentPresenter" />
        <Setter Property="h:FluentAnimation.Pressed" Value="ContentPresenter" />
        <Setter Property="h:FluentAnimation.PointerDownScale" Value="0.95" />
    </Style>

    <Style x:Key="VariantComboBoxStyle" TargetType="controls:UXComboBox">
        <Setter Property="Padding" Value="12,5,0,7" />
        <Setter Property="MinWidth" Value="{ThemeResource ComboBoxThemeMinWidth}" />
        <Setter Property="MinHeight" Value="40" />
        <Setter Property="Background" Value="{ThemeResource AppBarButtonBackground}" />
        <Setter Property="Foreground" Value="{ThemeResource AppBarButtonForeground}" />
        <Setter Property="BorderBrush" Value="{ThemeResource AppBarButtonBorderBrush}" />
        <Setter Property="BorderThickness" Value="1" />
        <Setter Property="TabNavigation" Value="Once" />
        <Setter Property="ScrollViewer.HorizontalScrollBarVisibility" Value="Disabled" />
        <Setter Property="ScrollViewer.VerticalScrollBarVisibility" Value="Auto" />
        <Setter Property="ScrollViewer.HorizontalScrollMode" Value="Disabled" />
        <Setter Property="ScrollViewer.VerticalScrollMode" Value="Auto" />
        <Setter Property="ScrollViewer.IsVerticalRailEnabled" Value="True" />
        <Setter Property="ScrollViewer.IsDeferredScrollingEnabled" Value="False" />
        <Setter Property="ScrollViewer.BringIntoViewOnFocusChange" Value="True" />
        <Setter Property="HorizontalContentAlignment" Value="Stretch" />
        <Setter Property="HorizontalAlignment" Value="Left" />
        <Setter Property="VerticalAlignment" Value="Top" />
        <Setter Property="h:FluentAnimation.PointerOverOffset" Value="2" />
        <Setter Property="FontFamily" Value="{ThemeResource ContentControlThemeFontFamily}" />
        <Setter Property="CornerRadius" Value="{ThemeResource ControlCornerRadius}" />
        <Setter Property="FontSize" Value="{ThemeResource ControlContentThemeFontSize}" />
        <Setter Property="UseSystemFocusVisuals" Value="{ThemeResource IsApplicationFocusVisualKindReveal}" />
        <Setter Property="ItemContainerStyle" Value="{StaticResource DefaultThemeComboBoxItemStyle}" />
        <Setter Property="ItemsPanel">
            <Setter.Value>
                <ItemsPanelTemplate>
                    <CarouselPanel />
                </ItemsPanelTemplate>
            </Setter.Value>
        </Setter>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="controls:UXComboBox">
                    <Grid x:Name="LayoutRoot">
                        <Grid.Resources>
                            <Storyboard x:Key="OverlayOpeningAnimation">
                                <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity">
                                    <DiscreteDoubleKeyFrame KeyTime="0:0:0" Value="0.0" />
                                    <SplineDoubleKeyFrame KeySpline="0.1,0.9 0.2,1.0" KeyTime="0:0:0.383" Value="1.0" />
                                </DoubleAnimationUsingKeyFrames>
                            </Storyboard>
                            <Storyboard x:Key="OverlayClosingAnimation">
                                <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity">
                                    <DiscreteDoubleKeyFrame KeyTime="0:0:0" Value="1.0" />
                                    <SplineDoubleKeyFrame KeySpline="0.1,0.9 0.2,1.0" KeyTime="0:0:0.216" Value="0.0" />
                                </DoubleAnimationUsingKeyFrames>
                            </Storyboard>
                        </Grid.Resources>

                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup
                                x:Name="CommonStates"
                                h:FluentAnimation.PointerOver="{Binding ElementName=DropDownGlyph}"
                                h:FluentAnimation.Pressed="{Binding ElementName=PresentationRoot}">
                                <VisualState x:Name="Normal" />

                                <VisualState x:Name="PointerOver">
                                    <VisualState.Setters>
                                        <Setter Target="Background.Background" Value="{ThemeResource AppBarButtonBackgroundPointerOver}" />
                                        <Setter Target="Background.BorderBrush" Value="{ThemeResource AppBarButtonBorderBrushPointerOver}" />
                                    </VisualState.Setters>
                                </VisualState>

                                <VisualState x:Name="Pressed">
                                    <VisualState.Setters>
                                        <Setter Target="Background.Background" Value="{ThemeResource AppBarButtonBackgroundPressed}" />
                                        <Setter Target="Background.BorderBrush" Value="{ThemeResource AppBarButtonBorderBrushPressed}" />
                                    </VisualState.Setters>
                                </VisualState>

                                <VisualState x:Name="Disabled">
                                    <VisualState.Setters>
                                        <Setter Target="DropDownGlyph.Opacity" Value="0" />
                                        <Setter Target="Background.BorderBrush" Value="Transparent" />
                                    </VisualState.Setters>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="FocusStates">
                                <VisualState x:Name="Focused">

                                    <Storyboard>
                                        <DoubleAnimation
                                            Storyboard.TargetName="HighlightBackground"
                                            Storyboard.TargetProperty="Opacity"
                                            To="1"
                                            Duration="0" />
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="HighlightBackground" Storyboard.TargetProperty="BorderBrush">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ComboBoxBackgroundBorderBrushFocused}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContentPresenter" Storyboard.TargetProperty="Foreground">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ComboBoxForegroundFocused}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="DropDownGlyph" Storyboard.TargetProperty="Foreground">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ComboBoxDropDownGlyphForegroundFocused}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="FocusedPressed">

                                    <Storyboard>
                                        <DoubleAnimation
                                            Storyboard.TargetName="HighlightBackground"
                                            Storyboard.TargetProperty="Opacity"
                                            To="1"
                                            Duration="0" />
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContentPresenter" Storyboard.TargetProperty="Foreground">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ComboBoxForegroundFocusedPressed}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="DropDownGlyph" Storyboard.TargetProperty="Foreground">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ComboBoxDropDownGlyphForegroundFocusedPressed}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Unfocused" />
                                <VisualState x:Name="PointerFocused" />
                                <VisualState x:Name="FocusedDropDown">

                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames
                                            Storyboard.TargetName="PopupBorder"
                                            Storyboard.TargetProperty="Visibility"
                                            Duration="0">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="DropDownStates">
                                <VisualState x:Name="Opened">

                                    <Storyboard>
                                        <SplitOpenThemeAnimation
                                            ClosedTargetName="ContentPresenter"
                                            OffsetFromCenter="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=TemplateSettings.DropDownOffset}"
                                            OpenedLength="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=TemplateSettings.DropDownOpenedHeight}"
                                            OpenedTargetName="PopupBorder" />
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Closed">

                                    <Storyboard>
                                        <SplitCloseThemeAnimation
                                            ClosedTargetName="ContentPresenter"
                                            OffsetFromCenter="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=TemplateSettings.DropDownOffset}"
                                            OpenedLength="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=TemplateSettings.DropDownOpenedHeight}"
                                            OpenedTargetName="PopupBorder" />
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>

                        </VisualStateManager.VisualStateGroups>

                        <Border
                            x:Name="Background"
                            Grid.ColumnSpan="2"
                            Margin="2"
                            VerticalAlignment="Stretch"
                            Background="{TemplateBinding Background}"
                            BackgroundSizing="{TemplateBinding BackgroundSizing}"
                            BorderBrush="{TemplateBinding BorderBrush}"
                            BorderThickness="{TemplateBinding BorderThickness}"
                            Control.IsTemplateFocusTarget="True"
                            CornerRadius="{TemplateBinding CornerRadius}">
                            <Border.BackgroundTransition>
                                <BrushTransition Duration="0:0:0.083" />
                            </Border.BackgroundTransition>
                        </Border>

                        <Border
                            x:Name="HighlightBackground"
                            Grid.ColumnSpan="2"
                            Margin="2"
                            Background="{ThemeResource ComboBoxBackgroundUnfocused}"
                            BorderBrush="{ThemeResource ComboBoxBackgroundBorderBrushUnfocused}"
                            BorderThickness="{TemplateBinding BorderThickness}"
                            Opacity="0" />

                        <Grid x:Name="PresentationRoot">
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="*" />
                                <ColumnDefinition Width="36" />
                            </Grid.ColumnDefinitions>

                            <ContentPresenter
                                x:Name="ContentPresenter"
                                Margin="{TemplateBinding Padding}"
                                HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                                VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                                Visibility="Collapsed" />

                            <StackPanel
                                x:Name="VariantRoot"
                                Margin="{TemplateBinding Padding}"
                                HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                                VerticalAlignment="{TemplateBinding VerticalContentAlignment}">
                                <ContentPresenter
                                    MinHeight="0"
                                    Content="{TemplateBinding PreContent}"
                                    Foreground="{ThemeResource TextControlPlaceholderForeground}" />
                                <ContentPresenter
                                    Content="{TemplateBinding SelectedItem}"
                                    FontFamily="{StaticResource ContentControlThemeFontFamily}"
                                    FontSize="{TemplateBinding FontSize}"
                                    FontStyle="Normal"
                                    FontWeight="{TemplateBinding FontWeight}" />
                                <ContentPresenter
                                    MinHeight="0"
                                    Content="{TemplateBinding SecondaryContent}"
                                    Foreground="{ThemeResource TextControlPlaceholderForeground}" />
                            </StackPanel>

                            <FontIcon
                                x:Name="DropDownGlyph"
                                Grid.Column="1"
                                Margin="0,10,10,10"
                                HorizontalAlignment="Right"
                                VerticalAlignment="Center"
                                h:CompositionFactory.OpacityDuration="0:0:0.1"
                                AutomationProperties.AccessibilityView="Raw"
                                FontFamily="{ThemeResource SymbolThemeFontFamily}"
                                FontSize="12"
                                Foreground="{ThemeResource ComboBoxDropDownGlyphForeground}"
                                Glyph="&#xE70D;"
                                IsHitTestVisible="False" />

                        </Grid>

                        <Popup x:Name="Popup">
                            <Border
                                x:Name="PopupBorder"
                                Margin="0,-1,0,-1"
                                HorizontalAlignment="Stretch"
                                Background="{ThemeResource ComboBoxDropDownBackground}"
                                BorderBrush="{ThemeResource ComboBoxDropDownBorderBrush}"
                                BorderThickness="{ThemeResource ComboBoxDropdownBorderThickness}"
                                CornerRadius="{TemplateBinding CornerRadius}">
                                <ScrollViewer
                                    x:Name="ScrollViewer"
                                    MinWidth="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ActualWidth}"
                                    AutomationProperties.AccessibilityView="Raw"
                                    BringIntoViewOnFocusChange="{TemplateBinding ScrollViewer.BringIntoViewOnFocusChange}"
                                    FontWeight="Normal"
                                    Foreground="{ThemeResource ComboBoxDropDownForeground}"
                                    HorizontalScrollBarVisibility="{TemplateBinding ScrollViewer.HorizontalScrollBarVisibility}"
                                    HorizontalScrollMode="{TemplateBinding ScrollViewer.HorizontalScrollMode}"
                                    IsDeferredScrollingEnabled="{TemplateBinding ScrollViewer.IsDeferredScrollingEnabled}"
                                    IsHorizontalRailEnabled="{TemplateBinding ScrollViewer.IsHorizontalRailEnabled}"
                                    IsVerticalRailEnabled="{TemplateBinding ScrollViewer.IsVerticalRailEnabled}"
                                    VerticalScrollBarVisibility="{TemplateBinding ScrollViewer.VerticalScrollBarVisibility}"
                                    VerticalScrollMode="{TemplateBinding ScrollViewer.VerticalScrollMode}"
                                    VerticalSnapPointsAlignment="Near"
                                    VerticalSnapPointsType="OptionalSingle"
                                    ZoomMode="Disabled">
                                    <ItemsPresenter Margin="{ThemeResource ComboBoxDropdownContentMargin}" />
                                </ScrollViewer>
                            </Border>
                        </Popup>

                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>


    <!--  BUTTONS  -->

    <Style x:Key="DefaultThemeButtonStyle" BasedOn="{StaticResource DefaultButtonStyle}" TargetType="Button">
        <Setter Property="h:FluentAnimation.Pressed" Value="ContentPresenter" />
        <Setter Property="h:FluentAnimation.PointerOver" Value="ContentPresenter.Content" />
        <Setter Property="h:FluentAnimation.PointerOverOffset" Value="-2" />
        <Setter Property="core:Properties.ToolTipStyleKey" Value="DefaultThemeToolTipStyle" />
    </Style>

    <Style BasedOn="{StaticResource DefaultThemeButtonStyle}" TargetType="controls:UXButton" />

    <Style x:Key="TransparentButton" TargetType="controls:UXButton">
        <Setter Property="Background" Value="{ThemeResource AppBarButtonBackground}" />
        <Setter Property="Foreground" Value="{ThemeResource AppBarButtonForeground}" />
        <Setter Property="BorderBrush" Value="{ThemeResource AppBarButtonBorderBrush}" />
        <Setter Property="BorderThickness" Value="1" />
        <Setter Property="Padding" Value="8,4,8,5" />
        <Setter Property="HorizontalAlignment" Value="Stretch" />
        <Setter Property="HorizontalContentAlignment" Value="Stretch" />
        <Setter Property="VerticalAlignment" Value="Center" />
        <Setter Property="FontFamily" Value="{ThemeResource ContentControlThemeFontFamily}" />
        <Setter Property="FontWeight" Value="Normal" />
        <Setter Property="FontSize" Value="{ThemeResource ControlContentThemeFontSize}" />
        <Setter Property="CornerRadius" Value="{ThemeResource ControlCornerRadius}" />
        <Setter Property="FocusVisualMargin" Value="-3" />
        <Setter Property="h:FluentAnimation.UsePointerOver" Value="False" />
        <Setter Property="core:Properties.ToolTipStyleKey" Value="DefaultThemeToolTipStyle" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="controls:UXButton">
                    <Grid
                        x:Name="Root"
                        Margin="2"
                        Background="Transparent"
                        CornerRadius="{TemplateBinding CornerRadius}">
                        <Grid.BackgroundTransition>
                            <BrushTransition Duration="0:0:0.083" />
                        </Grid.BackgroundTransition>
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup
                                x:Name="CommonStates"
                                h:FluentAnimation.PointerOver="{Binding ElementName=FluentContentPresenter}"
                                h:FluentAnimation.Pressed="{Binding ElementName=ContentRoot}">
                                <VisualState x:Name="Normal" />
                                <VisualState x:Name="PointerOver">
                                    <VisualState.Setters>
                                        <Setter Target="AppBarButtonInnerBorder.Background" Value="{ThemeResource AppBarButtonBackgroundPointerOver}" />
                                        <Setter Target="AppBarButtonInnerBorder.BorderBrush" Value="{ThemeResource AppBarButtonBorderBrushPointerOver}" />
                                        <!--<Setter Target="FluentContentPresenter.Foreground" Value="{ThemeResource AppBarButtonForegroundPointerOver}" />-->
                                    </VisualState.Setters>
                                </VisualState>
                                <VisualState x:Name="Pressed">
                                    <VisualState.Setters>
                                        <Setter Target="AppBarButtonInnerBorder.Background" Value="{ThemeResource AppBarButtonBackgroundPressed}" />
                                        <Setter Target="AppBarButtonInnerBorder.BorderBrush" Value="{ThemeResource AppBarButtonBorderBrushPressed}" />
                                        <!--<Setter Target="FluentContentPresenter.Foreground" Value="{ThemeResource AppBarButtonForegroundPressed}" />-->
                                    </VisualState.Setters>
                                </VisualState>
                                <VisualState x:Name="Disabled">
                                    <VisualState.Setters>
                                        <Setter Target="Root.Opacity" Value="0.4" />
                                    </VisualState.Setters>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="HintStates">
                                <VisualState x:Name="HintHidden" />
                                <VisualState x:Name="HintVisible">
                                    <VisualState.Setters>
                                        <Setter Target="HintColumn.Width" Value="24" />
                                        <Setter Target="DropDownGlyph.Visibility" Value="Visible" />
                                    </VisualState.Setters>
                                </VisualState>
                            </VisualStateGroup>

                            <VisualStateGroup x:Name="LabelStates">
                                <VisualState x:Name="LabelHidden" />
                                <VisualState x:Name="LabelVisible">
                                    <VisualState.Setters>
                                        <Setter Target="FluentContentPresenter.Height" Value="32" />
                                        <Setter Target="FluentContentPresenter.VerticalAlignment" Value="Top" />
                                        <Setter Target="LabelPresenter.Visibility" Value="Visible" />
                                    </VisualState.Setters>
                                </VisualState>
                            </VisualStateGroup>

                            <VisualStateGroup x:Name="ActiveStates">
                                <VisualState x:Name="IsActive">
                                    <VisualState.Setters>
                                        <Setter Target="FluentContentPresenter.Foreground" Value="{ThemeResource AppBarButtonForegroundPointerOver}" />
                                        <Setter Target="Root.Background" Value="{ThemeResource SystemControlForegroundAccentBrush}" />
                                    </VisualState.Setters>
                                </VisualState>
                                <VisualState x:Name="IsNotActive" />
                            </VisualStateGroup>

                        </VisualStateManager.VisualStateGroups>

                        <Border
                            x:Name="AppBarButtonInnerBorder"
                            VerticalAlignment="Stretch"
                            Background="{TemplateBinding Background}"
                            BackgroundSizing="{TemplateBinding BackgroundSizing}"
                            BackgroundTransition="{StaticResource BackgroundTransition}"
                            BorderBrush="{TemplateBinding BorderBrush}"
                            BorderThickness="{TemplateBinding BorderThickness}"
                            Control.IsTemplateFocusTarget="True" />

                        <Grid x:Name="ContentRoot">
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="*" />
                                <ColumnDefinition x:Name="HintColumn" Width="0" />
                            </Grid.ColumnDefinitions>

                            <ContentPresenter
                                x:Name="FluentContentPresenter"
                                Padding="{TemplateBinding Padding}"
                                HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"
                                VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}"
                                AutomationProperties.AccessibilityView="Raw"
                                Content="{TemplateBinding Content}"
                                ContentTemplate="{TemplateBinding ContentTemplate}"
                                ContentTransitions="{TemplateBinding ContentTransitions}"
                                Foreground="{TemplateBinding Foreground}" />

                            <TextBlock
                                x:Name="LabelPresenter"
                                x:Load="False"
                                Margin="0 0 0 6"
                                HorizontalAlignment="Center"
                                VerticalAlignment="Bottom"
                                FontSize="11.333"
                                Foreground="{ThemeResource TextControlPlaceholderForeground}"
                                Text="{TemplateBinding Label}"
                                Visibility="Collapsed" />

                            <muxc:AnimatedIcon
                                x:Name="DropDownGlyph"
                                x:Load="False"
                                Grid.Column="1"
                                Height="14"
                                Margin="0,10,10,10"
                                HorizontalAlignment="Right"
                                VerticalAlignment="Center"
                                h:CompositionFactory.OpacityDuration="0:0:0.1"
                                AutomationProperties.AccessibilityView="Raw"
                                Foreground="{ThemeResource ApplicationForegroundThemeBrush}"
                                IsHitTestVisible="False"
                                Visibility="Collapsed">
                                <av:AnimatedChevronDownSmallVisualSource />
                                <muxc:AnimatedIcon.FallbackIconSource>
                                    <muxc:FontIconSource
                                        FontFamily="{ThemeResource SymbolThemeFontFamily}"
                                        FontSize="12"
                                        Foreground="{ThemeResource ComboBoxDropDownGlyphForeground}"
                                        Glyph="&#xE70D;" />
                                </muxc:AnimatedIcon.FallbackIconSource>
                            </muxc:AnimatedIcon>

                        </Grid>

                    </Grid>

                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="TransparentHintButton" BasedOn="{StaticResource TransparentButton}" TargetType="controls:UXButton">
        <Setter Property="IsHintVisible" Value="True" />
        <Setter Property="core:Properties.SupportAnimatedIcon" Value="True" />
    </Style>

    <Style x:Key="MapInfoButtonStyle" BasedOn="{StaticResource TransparentButton}" TargetType="controls:UXButton">
        <Setter Property="Foreground" Value="{ThemeResource SystemControlForegroundAccentBrush}" />
        <Setter Property="Height" Value="42" />
        <Setter Property="MinWidth" Value="42" />
        <Setter Property="h:FluentAnimation.PointerOver" Value="DropDownGlyph" />
        <Setter Property="h:FluentAnimation.PointerOverOffset" Value="2" />
        <Setter Property="h:FluentAnimation.PointerDownScale" Value="0.9" />
        <Setter Property="h:FluentAnimation.UsePointerOver" Value="True" />
    </Style>

    <Style x:Key="DefaultThemeAppBarButtonStyle" BasedOn="{StaticResource TransparentButton}" TargetType="controls:UXButton">
        <Setter Property="HorizontalAlignment" Value="Left" />
        <Setter Property="VerticalAlignment" Value="Top" />
        <Setter Property="Width" Value="50" />
        <Setter Property="Padding" Value="0" />
    </Style>

    <Style x:Key="DevToolsAppBarButtonStyle" BasedOn="{StaticResource DefaultThemeAppBarButtonStyle}" TargetType="controls:UXButton">
        <Setter Property="Height" Value="52" />
        <Setter Property="IsLabelVisible" Value="True" />
        <Setter Property="h:FluentAnimation.UsePointerOver" Value="True" />
    </Style>

    <Style x:Key="CopyButtonStyle" BasedOn="{StaticResource DevToolsAppBarButtonStyle}" TargetType="controls:UXButton">
        <Setter Property="Height" Value="50" />
        <Setter Property="Width" Value="50" />
        <Setter Property="IsLabelVisible" Value="False" />
    </Style>

    <Style x:Key="LabelAppBarButtonStyle" TargetType="AppBarButton">
        <Setter Property="Background" Value="{ThemeResource AppBarButtonBackground}" />
        <Setter Property="Foreground" Value="{ThemeResource AppBarButtonForeground}" />
        <Setter Property="BorderBrush" Value="{ThemeResource AppBarButtonBorderBrush}" />
        <Setter Property="BorderThickness" Value="1" />
        <Setter Property="HorizontalAlignment" Value="Left" />
        <Setter Property="VerticalAlignment" Value="Stretch" />
        <Setter Property="FontFamily" Value="{ThemeResource ContentControlThemeFontFamily}" />
        <Setter Property="FontWeight" Value="Normal" />
        <Setter Property="Padding" Value="12" />
        <Setter Property="MaxWidth" Value="NaN" />
        <Setter Property="Width" Value="NaN" />
        <Setter Property="CornerRadius" Value="{ThemeResource ControlCornerRadius}" />
        <Setter Property="UseSystemFocusVisuals" Value="{StaticResource UseSystemFocusVisuals}" />
        <Setter Property="AllowFocusOnInteraction" Value="False" />
        <Setter Property="h:FluentAnimation.PointerOverAxis" Value="Horizontal" />
        <Setter Property="h:FluentAnimation.PointerOverOffset" Value="2" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="AppBarButton">
                    <Grid x:Name="Root" Background="Transparent">

                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup
                                x:Name="CommonStates"
                                h:FluentAnimation.PointerOver="{Binding ElementName=LabelPresenter}"
                                h:FluentAnimation.Pressed="{Binding ElementName=ContentRoot}">
                                <VisualState x:Name="Normal" />
                                <VisualState x:Name="PointerOver">
                                    <VisualState.Setters>
                                        <Setter Target="AppBarButtonInnerBorder.Background" Value="{ThemeResource AppBarButtonBackgroundPointerOver}" />
                                        <Setter Target="AppBarButtonInnerBorder.BorderBrush" Value="{ThemeResource AppBarButtonBorderBrushPointerOver}" />
                                        <Setter Target="Content.Foreground" Value="{ThemeResource AppBarButtonForegroundPointerOver}" />
                                    </VisualState.Setters>
                                </VisualState>
                                <VisualState x:Name="Pressed">
                                    <VisualState.Setters>
                                        <Setter Target="AppBarButtonInnerBorder.Background" Value="{ThemeResource AppBarButtonBackgroundPressed}" />
                                        <Setter Target="AppBarButtonInnerBorder.BorderBrush" Value="{ThemeResource AppBarButtonBorderBrushPressed}" />
                                        <Setter Target="Content.Foreground" Value="{ThemeResource AppBarButtonForegroundPressed}" />
                                    </VisualState.Setters>
                                </VisualState>
                                <VisualState x:Name="Disabled">
                                    <VisualState.Setters>
                                        <Setter Target="Root.Opacity" Value="0.4" />
                                    </VisualState.Setters>
                                </VisualState>
                                <VisualState x:Name="OverflowNormal" />
                                <VisualState x:Name="OverflowPointerOver">
                                    <VisualState.Setters>
                                        <Setter Target="AppBarButtonInnerBorder.Background" Value="{ThemeResource AppBarButtonBackgroundPointerOver}" />
                                        <Setter Target="AppBarButtonInnerBorder.BorderBrush" Value="{ThemeResource AppBarButtonBorderBrushPointerOver}" />
                                        <Setter Target="Content.Foreground" Value="{ThemeResource AppBarButtonForegroundPointerOver}" />
                                    </VisualState.Setters>
                                    <Storyboard>
                                        <PointerUpThemeAnimation TargetName="ContentRoot" />
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="OverflowPressed">
                                    <VisualState.Setters>
                                        <Setter Target="AppBarButtonInnerBorder.Background" Value="{ThemeResource AppBarButtonBackgroundPressed}" />
                                        <Setter Target="AppBarButtonInnerBorder.BorderBrush" Value="{ThemeResource AppBarButtonBorderBrushPressed}" />
                                        <Setter Target="Content.Foreground" Value="{ThemeResource AppBarButtonForegroundPressed}" />
                                    </VisualState.Setters>
                                    <Storyboard>
                                        <PointerDownThemeAnimation TargetName="ContentRoot" />
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="OverflowSubMenuOpened">
                                    <VisualState.Setters>
                                        <Setter Target="AppBarButtonInnerBorder.Background" Value="{ThemeResource AppBarButtonBackgroundSubMenuOpened}" />
                                        <Setter Target="AppBarButtonInnerBorder.BorderBrush" Value="{ThemeResource AppBarButtonBorderBrushSubMenuOpened}" />
                                        <Setter Target="Content.Foreground" Value="{ThemeResource AppBarButtonForegroundSubMenuOpened}" />
                                    </VisualState.Setters>
                                    <Storyboard>
                                        <PointerUpThemeAnimation TargetName="ContentRoot" />
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>

                        <Border
                            x:Name="AppBarButtonInnerBorder"
                            Margin="2"
                            VerticalAlignment="Stretch"
                            Background="{TemplateBinding Background}"
                            BackgroundSizing="{TemplateBinding BackgroundSizing}"
                            BorderBrush="{TemplateBinding BorderBrush}"
                            BorderThickness="{TemplateBinding BorderThickness}"
                            Control.IsTemplateFocusTarget="True"
                            CornerRadius="{TemplateBinding CornerRadius}">
                            <Border.BackgroundTransition>
                                <BrushTransition Duration="0:0:0.083" />
                            </Border.BackgroundTransition>
                        </Border>

                        <StackPanel
                            x:Name="ContentRoot"
                            Padding="{TemplateBinding Padding}"
                            Orientation="Horizontal">

                            <ContentPresenter
                                x:Name="Content"
                                Content="{TemplateBinding Icon}"
                                Foreground="{TemplateBinding Foreground}" />

                            <TextBlock
                                x:Name="LabelPresenter"
                                Margin="12 0 0 0"
                                VerticalAlignment="Center"
                                FontSize="12"
                                Text="{TemplateBinding Label}" />
                        </StackPanel>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="DefaultMenuButtonStyle" TargetType="controls:MenuButton">
        <Setter Property="Background" Value="Transparent" />
        <Setter Property="Foreground" Value="{ThemeResource ButtonForeground}" />
        <Setter Property="BorderBrush" Value="Transparent" />
        <Setter Property="BorderThickness" Value="0" />
        <Setter Property="Margin" Value="12,2,12,2" />
        <Setter Property="Padding" Value="0" />
        <Setter Property="HorizontalAlignment" Value="Stretch" />
        <Setter Property="HorizontalContentAlignment" Value="Stretch" />
        <Setter Property="VerticalAlignment" Value="Center" />
        <Setter Property="VerticalContentAlignment" Value="Center" />
        <Setter Property="FontFamily" Value="{ThemeResource ContentControlThemeFontFamily}" />
        <Setter Property="FontWeight" Value="Normal" />
        <Setter Property="FontSize" Value="14" />
        <Setter Property="CornerRadius" Value="4" />
        <Setter Property="FocusVisualMargin" Value="-3" />
        <Setter Property="MinHeight" Value="36" />
        <Setter Property="h:FluentAnimation.UsePointerOver" Value="True" />
        <Setter Property="h:FluentAnimation.PointerOverOffset" Value="3" />
        <Setter Property="h:FluentAnimation.PointerOverAxis" Value="Horizontal" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="controls:MenuButton">
                    <Grid
                        x:Name="RootGrid"
                        core:Properties.ToolTip="{TemplateBinding Content}"
                        Background="{TemplateBinding Background}"
                        BorderBrush="{TemplateBinding BorderBrush}"
                        BorderThickness="{TemplateBinding BorderThickness}"
                        CornerRadius="{TemplateBinding CornerRadius}">
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup
                                x:Name="CommonStates"
                                h:FluentAnimation.PointerOver="{Binding ElementName=ContentPresenter}"
                                h:FluentAnimation.Pressed="{Binding ElementName=ContentRoot}">
                                <VisualState x:Name="Normal" />
                                <VisualState x:Name="PointerOver">
                                    <VisualState.Setters>
                                        <Setter Target="ContentBorder.Background" Value="{ThemeResource AppBarButtonBackgroundPointerOver}" />
                                    </VisualState.Setters>
                                </VisualState>
                                <VisualState x:Name="Pressed">
                                    <VisualState.Setters>
                                        <Setter Target="ContentBorder.Background" Value="{ThemeResource AppBarButtonBackgroundPointerOver}" />
                                    </VisualState.Setters>
                                </VisualState>
                                <VisualState x:Name="Disabled">
                                    <VisualState.Setters>
                                        <Setter Target="RootGrid.Opacity" Value="0.5" />
                                    </VisualState.Setters>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="CheckStates">
                                <VisualState x:Name="Checked">
                                    <VisualState.Setters>
                                        <Setter Target="IconPresenter.Foreground" Value="{ThemeResource ButtonForeground}" />
                                        <Setter Target="SelectionIndicator.Visibility" Value="Visible" />
                                        <Setter Target="RootGrid.Background" Value="#0FFFFFFF" />
                                    </VisualState.Setters>
                                </VisualState>
                                <VisualState x:Name="Unchecked">
                                    <VisualState.Setters>
                                        <Setter Target="IconPresenter.Foreground" Value="{ThemeResource ButtonForeground}" />
                                    </VisualState.Setters>
                                </VisualState>
                                <VisualState x:Name="Indeterminate">
                                    <VisualState.Setters>
                                        <Setter Target="IconPresenter.Foreground" Value="{ThemeResource ButtonForeground}" />
                                    </VisualState.Setters>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>

                        <Rectangle
                            x:Name="SelectionIndicator"
                            x:Load="False"
                            Width="3"
                            Height="16"
                            HorizontalAlignment="Left"
                            Fill="{ThemeResource SystemAccentColor}"
                            RadiusX="2"
                            RadiusY="2"
                            Visibility="Collapsed" />

                        <Border
                            x:Name="ContentBorder"
                            Background="Transparent"
                            BackgroundTransition="{StaticResource BackgroundTransition}"
                            CornerRadius="{TemplateBinding CornerRadius}">
                            <Grid x:Name="ContentRoot">
                                <Grid.ColumnDefinitions>
                                    <ColumnDefinition Width="36" />
                                    <ColumnDefinition Width="*" />
                                </Grid.ColumnDefinitions>

                                <Viewbox
                                    x:Name="IconBox"
                                    Width="16"
                                    Height="16"
                                    HorizontalAlignment="Center"
                                    VerticalAlignment="Center">
                                    <ContentPresenter x:Name="IconPresenter" Content="{TemplateBinding Icon}" />
                                </Viewbox>

                                <ContentPresenter
                                    x:Name="ContentPresenter"
                                    Grid.Column="1"
                                    Padding="{TemplateBinding Padding}"
                                    HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"
                                    VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}"
                                    AutomationProperties.AccessibilityView="Raw"
                                    Content="{TemplateBinding Content}"
                                    ContentTemplate="{TemplateBinding ContentTemplate}"
                                    ContentTransitions="{TemplateBinding ContentTransitions}" />
                            </Grid>
                        </Border>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>




    <!--  TEXTBOX  -->

    <Style x:Key="DefaultThemeAutoSuggestBoxTextBoxStyle" TargetType="TextBox">
        <Setter Property="Foreground" Value="{ThemeResource TextControlForeground}" />
        <Setter Property="BorderBrush" Value="{ThemeResource TextControlBorderBrush}" />
        <Setter Property="SelectionHighlightColor" Value="{ThemeResource TextControlSelectionHighlightColor}" />
        <Setter Property="BorderThickness" Value="{ThemeResource TextControlBorderThemeThickness}" />
        <Setter Property="FontFamily" Value="{ThemeResource ContentControlThemeFontFamily}" />
        <Setter Property="FontSize" Value="{ThemeResource ControlContentThemeFontSize}" />
        <Setter Property="ScrollViewer.HorizontalScrollMode" Value="Auto" />
        <Setter Property="ScrollViewer.VerticalScrollMode" Value="Auto" />
        <Setter Property="ScrollViewer.HorizontalScrollBarVisibility" Value="Hidden" />
        <Setter Property="ScrollViewer.VerticalScrollBarVisibility" Value="Hidden" />
        <Setter Property="ScrollViewer.IsDeferredScrollingEnabled" Value="False" />
        <Setter Property="MinHeight" Value="{ThemeResource TextControlThemeMinHeight}" />
        <Setter Property="MinWidth" Value="{ThemeResource TextControlThemeMinWidth}" />
        <Setter Property="Padding" Value="{ThemeResource TextControlThemePadding}" />
        <Setter Property="UseSystemFocusVisuals" Value="{ThemeResource IsApplicationFocusVisualKindReveal}" />
        <Setter Property="ContextFlyout" Value="{StaticResource TextControlCommandBarContextFlyout}" />
        <Setter Property="SelectionFlyout" Value="{StaticResource TextControlCommandBarSelectionFlyout}" />
        <Setter Property="CornerRadius" Value="{ThemeResource ControlCornerRadius}" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="TextBox">
                    <Grid>

                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal">
                                    <VisualState.Setters>
                                        <Setter Target="ContentElement.HorizontalScrollMode" Value="Disabled" />
                                    </VisualState.Setters>
                                </VisualState>

                                <VisualState x:Name="Disabled">

                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="BorderElement" Storyboard.TargetProperty="Background">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource TextControlBackgroundDisabled}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="BorderElement" Storyboard.TargetProperty="BorderBrush">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource TextControlBorderBrushDisabled}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContentElement" Storyboard.TargetProperty="Foreground">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource TextControlForegroundDisabled}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="PlaceholderTextContent" Storyboard.TargetProperty="Foreground">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{Binding PlaceholderForeground, RelativeSource={RelativeSource TemplatedParent}, TargetNullValue={ThemeResource TextControlPlaceholderForegroundDisabled}}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>

                                <VisualState x:Name="PointerOver">
                                    <VisualState.Setters>
                                        <Setter Target="ContentElement.HorizontalScrollMode" Value="Disabled" />
                                    </VisualState.Setters>
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="BorderElement" Storyboard.TargetProperty="BorderBrush">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource TextControlBorderBrushPointerOver}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="BorderElement" Storyboard.TargetProperty="Background">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource TextControlBackgroundPointerOver}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="PlaceholderTextContent" Storyboard.TargetProperty="Foreground">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{Binding PlaceholderForeground, RelativeSource={RelativeSource TemplatedParent}, TargetNullValue={ThemeResource TextControlPlaceholderForegroundPointerOver}}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContentElement" Storyboard.TargetProperty="Foreground">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource TextControlForegroundPointerOver}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Focused">

                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="PlaceholderTextContent" Storyboard.TargetProperty="Foreground">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{Binding PlaceholderForeground, RelativeSource={RelativeSource TemplatedParent}, TargetNullValue={ThemeResource TextControlPlaceholderForegroundFocused}}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="BorderElement" Storyboard.TargetProperty="Background">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource TextControlBackgroundFocused}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="BorderElement" Storyboard.TargetProperty="BorderBrush">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource TextControlBorderBrushFocused}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="BorderElement" Storyboard.TargetProperty="BorderThickness">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource TextControlBorderThemeThicknessFocused}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContentElement" Storyboard.TargetProperty="Foreground">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource TextControlForegroundFocused}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>

                            </VisualStateGroup>
                            <VisualStateGroup x:Name="ButtonStates">
                                <VisualState x:Name="ButtonVisible" />
                                <VisualState x:Name="ButtonCollapsed" />

                            </VisualStateGroup>

                        </VisualStateManager.VisualStateGroups>

                        <Border
                            x:Name="BorderElement"
                            Grid.Row="1"
                            Grid.RowSpan="1"
                            Grid.Column="0"
                            Grid.ColumnSpan="2"
                            MinWidth="{TemplateBinding MinWidth}"
                            MinHeight="{TemplateBinding MinHeight}"
                            Background="{TemplateBinding Background}"
                            BackgroundTransition="{StaticResource BackgroundTransition}"
                            BorderBrush="{TemplateBinding BorderBrush}"
                            BorderThickness="{TemplateBinding BorderThickness}"
                            Control.IsTemplateFocusTarget="True"
                            CornerRadius="{TemplateBinding CornerRadius}" />
                        <ScrollViewer
                            x:Name="ContentElement"
                            Grid.Row="1"
                            Grid.Column="0"
                            Margin="{TemplateBinding BorderThickness}"
                            Padding="{TemplateBinding Padding}"
                            HorizontalAlignment="Stretch"
                            AutomationProperties.AccessibilityView="Raw"
                            Foreground="{TemplateBinding Foreground}"
                            HorizontalScrollBarVisibility="{TemplateBinding ScrollViewer.HorizontalScrollBarVisibility}"
                            HorizontalScrollMode="{TemplateBinding ScrollViewer.HorizontalScrollMode}"
                            IsDeferredScrollingEnabled="{TemplateBinding ScrollViewer.IsDeferredScrollingEnabled}"
                            IsHorizontalRailEnabled="{TemplateBinding ScrollViewer.IsHorizontalRailEnabled}"
                            IsTabStop="False"
                            IsVerticalRailEnabled="{TemplateBinding ScrollViewer.IsVerticalRailEnabled}"
                            VerticalScrollBarVisibility="{TemplateBinding ScrollViewer.VerticalScrollBarVisibility}"
                            VerticalScrollMode="{TemplateBinding ScrollViewer.VerticalScrollMode}"
                            ZoomMode="Disabled" />

                        <!--<TextBlock
                            x:Name="PlaceholderTextContentPresenter"
                            Grid.Row="1"
                            Grid.Column="0"
                            Grid.ColumnSpan="2"
                            Margin="{TemplateBinding BorderThickness}"
                            Padding="{TemplateBinding Padding}"
                            Foreground="{Binding PlaceholderForeground, RelativeSource={RelativeSource TemplatedParent}, TargetNullValue={ThemeResource TextControlPlaceholderForeground}}"
                            IsHitTestVisible="False"
                            Text="{TemplateBinding PlaceholderText}" />-->

                        <StackPanel
                            x:Name="PlaceholderTextContentPresenter"
                            Grid.Row="1"
                            Grid.ColumnSpan="1"
                            Margin="{TemplateBinding BorderThickness}"
                            Padding="{TemplateBinding Padding}"
                            Orientation="Horizontal"
                            Spacing="8">
                            <FontIcon
                                x:Name="PlaceholderIcon"
                                FontFamily="{ThemeResource SymbolThemeFontFamily}"
                                FontSize="12"
                                Foreground="{Binding ElementName=PlaceholderTextContent, Path=Foreground}"
                                Glyph="&#xE721;" />
                            <ContentControl
                                x:Name="PlaceholderTextContent"
                                Content="{TemplateBinding PlaceholderText}"
                                FontStyle="Italic"
                                Foreground="{ThemeResource TextControlPlaceholderForeground}"
                                IsHitTestVisible="False"
                                IsTabStop="False" />
                        </StackPanel>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style BasedOn="{StaticResource DefaultThemeAutoSuggestBoxStyle}" TargetType="AutoSuggestBox" />

    <Style x:Key="DefaultThemeAutoSuggestBoxStyle" TargetType="AutoSuggestBox">
        <Setter Property="VerticalAlignment" Value="Top" />
        <Setter Property="IsTabStop" Value="False" />
        <Setter Property="MaxSuggestionListHeight" Value="500" />
        <Setter Property="FontFamily" Value="{ThemeResource ContentControlThemeFontFamily}" />
        <Setter Property="FontSize" Value="{ThemeResource ControlContentThemeFontSize}" />
        <Setter Property="TextBoxStyle" Value="{StaticResource DefaultThemeAutoSuggestBoxTextBoxStyle}" />
        <Setter Property="CornerRadius" Value="{ThemeResource ControlCornerRadius}" />
        <Setter Property="BorderThickness" Value="0 0 0 1" />
        <Setter Property="ItemContainerStyle">
            <Setter.Value>
                <Style BasedOn="{StaticResource DefaultThemeListViewItemStyle}" TargetType="ListViewItem">
                    <Setter Property="HorizontalAlignment" Value="Stretch" />
                    <Setter Property="HorizontalContentAlignment" Value="Stretch" />
                    <Setter Property="Margin" Value="0 0 0 6" />
                    <Setter Property="Padding" Value="18 8 16 12" />
                </Style>
            </Setter.Value>
        </Setter>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="AutoSuggestBox">
                    <Grid x:Name="LayoutRoot">
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="DropDownStates">
                                <VisualStateGroup.Transitions>
                                    <VisualTransition From="*" To="Opened">
                                        <Storyboard>
                                            <!--<ObjectAnimationUsingKeyFrames Storyboard.TargetName="TextBox" Storyboard.TargetProperty="CornerRadius">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="4 4 4 0" />
                                            </ObjectAnimationUsingKeyFrames>-->
                                            <DoubleAnimation
                                                Storyboard.TargetName="SuggestionsPopup"
                                                Storyboard.TargetProperty="Opacity"
                                                From="0"
                                                To="1"
                                                Duration="0:0:0.1">
                                                <DoubleAnimation.EasingFunction>
                                                    <CircleEase EasingMode="EaseOut" />
                                                </DoubleAnimation.EasingFunction>
                                            </DoubleAnimation>
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetName="PopupTransform" Storyboard.TargetProperty="TranslateY">
                                                <SplineDoubleKeyFrame KeyTime="0" Value="-160" />
                                                <SplineDoubleKeyFrame KeySpline="0.1 0.9 0.2 1" KeyTime="0:0:0.3" Value="0" />
                                            </DoubleAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualTransition>
                                </VisualStateGroup.Transitions>
                                <VisualState x:Name="Opened">
                                    <!--<Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="TextBox" Storyboard.TargetProperty="CornerRadius">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="4 4 4 0" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>-->
                                </VisualState>
                                <VisualState x:Name="Closed">
                                    <!--<Storyboard>
                                        <SplitCloseThemeAnimation
                                            ClosedTargetName="ContentPresenter"
                                            OffsetFromCenter="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=TemplateSettings.DropDownOffset}"
                                            OpenedLength="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=TemplateSettings.DropDownOpenedHeight}"
                                            OpenedTargetName="SuggestionsContainer" />
                                    </Storyboard>-->
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <TextBox
                            x:Name="TextBox"
                            Width="{TemplateBinding Width}"
                            Margin="0"
                            BorderThickness="{TemplateBinding BorderThickness}"
                            Canvas.ZIndex="0"
                            CornerRadius="{TemplateBinding CornerRadius}"
                            Description="{TemplateBinding Description}"
                            DesiredCandidateWindowAlignment="BottomEdge"
                            FontFamily="{TemplateBinding FontFamily}"
                            FontSize="{TemplateBinding FontSize}"
                            FontStretch="{TemplateBinding FontStretch}"
                            FontWeight="{TemplateBinding FontWeight}"
                            Header="{TemplateBinding Header}"
                            PlaceholderText="{TemplateBinding PlaceholderText}"
                            ScrollViewer.BringIntoViewOnFocusChange="False"
                            Style="{TemplateBinding TextBoxStyle}"
                            UseSystemFocusVisuals="{TemplateBinding UseSystemFocusVisuals}" />

                        <Popup x:Name="SuggestionsPopup" Grid.ColumnSpan="2">
                            <Border core:Properties.ClipToBounds="true">
                                <Border
                                    x:Name="SuggestionsContainer"
                                    Padding="{ThemeResource AutoSuggestListMargin}"
                                    Background="{ThemeResource AutoSuggestBoxSuggestionsListBackground}"
                                    BorderBrush="{ThemeResource AutoSuggestBoxSuggestionsListBorderBrush}"
                                    BorderThickness="{ThemeResource AutoSuggestListBorderThemeThickness}"
                                    CornerRadius="0 0 8 8">
                                    <Border.RenderTransform>
                                        <CompositeTransform x:Name="PopupTransform" />
                                    </Border.RenderTransform>
                                    <ListView
                                        x:Name="SuggestionsList"
                                        MaxHeight="{TemplateBinding MaxSuggestionListHeight}"
                                        Margin="{ThemeResource AutoSuggestListPadding}"
                                        core:Properties.ToolTipMemberPath="{Binding RelativeSource={RelativeSource Mode=TemplatedParent}, Path=(core:Properties.ToolTipMemberPath)}"
                                        DisplayMemberPath="{TemplateBinding DisplayMemberPath}"
                                        Footer="{Binding RelativeSource={RelativeSource Mode=TemplatedParent}, Path=(core:Properties.Footer)}"
                                        IsItemClickEnabled="True"
                                        ItemContainerStyle="{TemplateBinding ItemContainerStyle}"
                                        ItemContainerTransitions="{StaticResource NoTransitions}"
                                        ItemTemplate="{TemplateBinding ItemTemplate}"
                                        ItemTemplateSelector="{TemplateBinding ItemTemplateSelector}">
                                        <ListView.GroupStyle>
                                            <GroupStyle HidesIfEmpty="True">
                                                <GroupStyle.HeaderContainerStyle>
                                                    <Style TargetType="ListViewHeaderItem">
                                                        <Setter Property="Padding" Value="12 12 0 4" />
                                                        <Setter Property="Margin" Value="0" />
                                                        <Setter Property="MinHeight" Value="0" />
                                                        <Setter Property="BorderBrush" Value="Transparent" />
                                                        <Setter Property="Template">
                                                            <Setter.Value>
                                                                <ControlTemplate TargetType="ListViewHeaderItem">
                                                                    <ContentPresenter
                                                                        Margin="{TemplateBinding Padding}"
                                                                        Content="{TemplateBinding Content}"
                                                                        ContentTemplate="{TemplateBinding ContentTemplate}"
                                                                        FontSize="12"
                                                                        FontWeight="SemiBold"
                                                                        Opacity="0.6"
                                                                        Visibility="{Binding Path=Content.Key, Converter={StaticResource VisConverter}, RelativeSource={RelativeSource Mode=TemplatedParent}, FallbackValue=Collapsed, TargetNullValue=Collapsed}" />
                                                                </ControlTemplate>
                                                            </Setter.Value>
                                                        </Setter>
                                                    </Style>
                                                </GroupStyle.HeaderContainerStyle>
                                            </GroupStyle>
                                        </ListView.GroupStyle>
                                    </ListView>
                                </Border>

                            </Border>
                        </Popup>
                    </Grid>

                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>




    <!--  TOGGLESWITCH  -->

    <x:Double x:Key="ToggleSwitchThemeMinWidth">0</x:Double>

    <Style x:Key="DefaultToggleSwitchStyle" TargetType="ToggleSwitch">
        <Setter Property="Foreground" Value="{ThemeResource ToggleSwitchContentForeground}" />
        <Setter Property="HorizontalAlignment" Value="Left" />
        <Setter Property="VerticalAlignment" Value="Center" />
        <Setter Property="HorizontalContentAlignment" Value="Left" />
        <Setter Property="FontFamily" Value="{ThemeResource ContentControlThemeFontFamily}" />
        <Setter Property="FontSize" Value="{ThemeResource ControlContentThemeFontSize}" />
        <Setter Property="ManipulationMode" Value="System,TranslateX" />
        <Setter Property="MinWidth" Value="0" />
        <Setter Property="UseSystemFocusVisuals" Value="{StaticResource UseSystemFocusVisuals}" />
        <Setter Property="FocusVisualMargin" Value="-7,-3,-7,-3" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ToggleSwitch">
                    <Grid
                        Background="{TemplateBinding Background}"
                        BorderBrush="{TemplateBinding BorderBrush}"
                        BorderThickness="{TemplateBinding BorderThickness}"
                        CornerRadius="{TemplateBinding CornerRadius}">

                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal" />

                                <VisualState x:Name="PointerOver">

                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="OuterBorder" Storyboard.TargetProperty="Stroke">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchStrokeOffPointerOver}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="OuterBorder" Storyboard.TargetProperty="Fill">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchFillOffPointerOver}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobOff" Storyboard.TargetProperty="Fill">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchKnobFillOffPointerOver}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobOn" Storyboard.TargetProperty="Fill">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchKnobFillOnPointerOver}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobBounds" Storyboard.TargetProperty="Fill">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchFillOnPointerOver}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobBounds" Storyboard.TargetProperty="Stroke">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchStrokeOnPointerOver}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchAreaGrid" Storyboard.TargetProperty="Background">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchContainerBackgroundPointerOver}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>

                                <VisualState x:Name="Pressed">

                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="OuterBorder" Storyboard.TargetProperty="Stroke">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchStrokeOffPressed}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="OuterBorder" Storyboard.TargetProperty="Fill">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchFillOffPressed}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobBounds" Storyboard.TargetProperty="Fill">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchFillOnPressed}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobBounds" Storyboard.TargetProperty="Stroke">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchStrokeOnPressed}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobOff" Storyboard.TargetProperty="Fill">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchKnobFillOffPressed}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobOn" Storyboard.TargetProperty="Fill">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchKnobFillOnPressed}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchAreaGrid" Storyboard.TargetProperty="Background">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchContainerBackgroundPressed}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>

                                <VisualState x:Name="Disabled">

                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="HeaderContentPresenter" Storyboard.TargetProperty="Foreground">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchHeaderForegroundDisabled}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="OffContentPresenter" Storyboard.TargetProperty="Foreground">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchContentForegroundDisabled}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="OnContentPresenter" Storyboard.TargetProperty="Foreground">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchContentForegroundDisabled}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="OuterBorder" Storyboard.TargetProperty="Stroke">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchStrokeOffDisabled}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="OuterBorder" Storyboard.TargetProperty="Fill">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchFillOffDisabled}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobBounds" Storyboard.TargetProperty="Fill">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchFillOnDisabled}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobBounds" Storyboard.TargetProperty="Stroke">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchStrokeOnDisabled}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobOff" Storyboard.TargetProperty="Fill">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchKnobFillOffDisabled}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobOn" Storyboard.TargetProperty="Fill">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchKnobFillOnDisabled}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchAreaGrid" Storyboard.TargetProperty="Background">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource ToggleSwitchContainerBackgroundDisabled}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>

                            </VisualStateGroup>
                            <VisualStateGroup x:Name="ToggleStates">

                                <VisualStateGroup.Transitions>
                                    <VisualTransition
                                        x:Name="DraggingToOnTransition"
                                        GeneratedDuration="0"
                                        From="Dragging"
                                        To="On">

                                        <Storyboard>
                                            <RepositionThemeAnimation FromHorizontalOffset="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=TemplateSettings.KnobCurrentToOnOffset}" TargetName="SwitchKnob" />
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobBounds" Storyboard.TargetProperty="Opacity">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="1" />
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetName="OuterBorder" Storyboard.TargetProperty="Opacity">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="0" />
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobOn" Storyboard.TargetProperty="Opacity">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="1" />
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobOff" Storyboard.TargetProperty="Opacity">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="0" />
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualTransition>
                                    <VisualTransition
                                        x:Name="OnToDraggingTransition"
                                        GeneratedDuration="0"
                                        From="On"
                                        To="Dragging">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobBounds" Storyboard.TargetProperty="Opacity">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="1" />
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobOn" Storyboard.TargetProperty="Opacity">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="1" />
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobOff" Storyboard.TargetProperty="Opacity">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="0" />
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualTransition>
                                    <VisualTransition
                                        x:Name="DraggingToOffTransition"
                                        GeneratedDuration="0"
                                        From="Dragging"
                                        To="Off">

                                        <Storyboard>
                                            <RepositionThemeAnimation FromHorizontalOffset="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=TemplateSettings.KnobCurrentToOffOffset}" TargetName="SwitchKnob" />
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobBounds" Storyboard.TargetProperty="Opacity">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="0" />
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobOn" Storyboard.TargetProperty="Opacity">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="0" />
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobOff" Storyboard.TargetProperty="Opacity">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="1" />
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualTransition>
                                    <VisualTransition
                                        x:Name="OnToOffTransition"
                                        GeneratedDuration="0"
                                        From="On"
                                        To="Off">

                                        <Storyboard>
                                            <RepositionThemeAnimation FromHorizontalOffset="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=TemplateSettings.KnobOnToOffOffset}" TargetName="SwitchKnob" />
                                        </Storyboard>
                                    </VisualTransition>
                                    <VisualTransition
                                        x:Name="OffToOnTransition"
                                        GeneratedDuration="0"
                                        From="Off"
                                        To="On">

                                        <Storyboard>
                                            <RepositionThemeAnimation FromHorizontalOffset="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=TemplateSettings.KnobOffToOnOffset}" TargetName="SwitchKnob" />
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobBounds" Storyboard.TargetProperty="Opacity">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="1" />
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetName="OuterBorder" Storyboard.TargetProperty="Opacity">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="0" />
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobOn" Storyboard.TargetProperty="Opacity">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="1" />
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobOff" Storyboard.TargetProperty="Opacity">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="0" />
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualTransition>
                                </VisualStateGroup.Transitions>
                                <VisualState x:Name="Dragging" />
                                <VisualState x:Name="Off" />
                                <VisualState x:Name="On">

                                    <Storyboard>
                                        <DoubleAnimation
                                            Storyboard.TargetName="KnobTranslateTransform"
                                            Storyboard.TargetProperty="X"
                                            To="20"
                                            Duration="0" />
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobBounds" Storyboard.TargetProperty="Opacity">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="1" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="OuterBorder" Storyboard.TargetProperty="Opacity">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobOn" Storyboard.TargetProperty="Opacity">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="1" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SwitchKnobOff" Storyboard.TargetProperty="Opacity">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>

                            </VisualStateGroup>
                            <VisualStateGroup x:Name="ContentStates">
                                <VisualState x:Name="OffContent">

                                    <Storyboard>
                                        <DoubleAnimation
                                            Storyboard.TargetName="OffContentPresenter"
                                            Storyboard.TargetProperty="Opacity"
                                            To="1"
                                            Duration="0" />
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="OffContentPresenter" Storyboard.TargetProperty="IsHitTestVisible">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <x:Boolean>True</x:Boolean>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="OnContent">

                                    <Storyboard>
                                        <DoubleAnimation
                                            Storyboard.TargetName="OnContentPresenter"
                                            Storyboard.TargetProperty="Opacity"
                                            To="1"
                                            Duration="0" />
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="OnContentPresenter" Storyboard.TargetProperty="IsHitTestVisible">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <x:Boolean>True</x:Boolean>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>

                            </VisualStateGroup>

                        </VisualStateManager.VisualStateGroups>

                        <Grid.RowDefinitions>
                            <RowDefinition Height="Auto" />
                            <RowDefinition Height="*" />
                        </Grid.RowDefinitions>

                        <ContentPresenter
                            x:Name="HeaderContentPresenter"
                            x:DeferLoadStrategy="Lazy"
                            Grid.Row="0"
                            Margin="{ThemeResource ToggleSwitchTopHeaderMargin}"
                            VerticalAlignment="Top"
                            AutomationProperties.AccessibilityView="Raw"
                            Content="{TemplateBinding Header}"
                            ContentTemplate="{TemplateBinding HeaderTemplate}"
                            Foreground="{ThemeResource ToggleSwitchHeaderForeground}"
                            IsHitTestVisible="False"
                            TextWrapping="Wrap"
                            Visibility="Collapsed" />
                        <Grid
                            Grid.Row="1"
                            HorizontalAlignment="Left"
                            VerticalAlignment="Top">

                            <Grid.RowDefinitions>
                                <RowDefinition Height="{ThemeResource ToggleSwitchPreContentMargin}" />
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="{ThemeResource ToggleSwitchPostContentMargin}" />
                            </Grid.RowDefinitions>

                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="Auto" />
                                <ColumnDefinition Width="12" MaxWidth="12" />
                                <ColumnDefinition Width="Auto" />
                            </Grid.ColumnDefinitions>
                            <Grid
                                x:Name="SwitchAreaGrid"
                                Grid.RowSpan="3"
                                Grid.ColumnSpan="3"
                                Margin="0,5"
                                Background="{ThemeResource ToggleSwitchContainerBackground}"
                                Control.IsTemplateFocusTarget="True" />
                            <ContentPresenter
                                x:Name="OffContentPresenter"
                                Grid.RowSpan="3"
                                Grid.Column="2"
                                HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                                VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                                AutomationProperties.AccessibilityView="Raw"
                                Content="{TemplateBinding OffContent}"
                                ContentTemplate="{TemplateBinding OffContentTemplate}"
                                Foreground="{TemplateBinding Foreground}"
                                IsHitTestVisible="False"
                                Opacity="0" />
                            <ContentPresenter
                                x:Name="OnContentPresenter"
                                Grid.RowSpan="3"
                                Grid.Column="2"
                                HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                                VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                                AutomationProperties.AccessibilityView="Raw"
                                Content="{TemplateBinding OnContent}"
                                ContentTemplate="{TemplateBinding OnContentTemplate}"
                                Foreground="{TemplateBinding Foreground}"
                                IsHitTestVisible="False"
                                Opacity="0" />
                            <Rectangle
                                x:Name="OuterBorder"
                                Grid.Row="1"
                                Width="40"
                                Height="20"
                                Fill="{ThemeResource ToggleSwitchFillOff}"
                                RadiusX="10"
                                RadiusY="10"
                                Stroke="{ThemeResource ToggleSwitchStrokeOff}"
                                StrokeThickness="{ThemeResource ToggleSwitchOuterBorderStrokeThickness}" />
                            <Rectangle
                                x:Name="SwitchKnobBounds"
                                Grid.Row="1"
                                Width="40"
                                Height="20"
                                Fill="{ThemeResource ToggleSwitchFillOn}"
                                Opacity="0"
                                RadiusX="10"
                                RadiusY="10"
                                Stroke="{ThemeResource ToggleSwitchStrokeOn}"
                                StrokeThickness="{ThemeResource ToggleSwitchOnStrokeThickness}" />
                            <Grid
                                x:Name="SwitchKnob"
                                Grid.Row="1"
                                Width="20"
                                Height="20"
                                HorizontalAlignment="Left">
                                <Ellipse
                                    x:Name="SwitchKnobOn"
                                    Width="10"
                                    Height="10"
                                    Fill="{ThemeResource ToggleSwitchKnobFillOn}"
                                    Opacity="0" />
                                <Ellipse
                                    x:Name="SwitchKnobOff"
                                    Width="10"
                                    Height="10"
                                    Fill="{ThemeResource ToggleSwitchKnobFillOff}" />
                                <Grid.RenderTransform>
                                    <TranslateTransform x:Name="KnobTranslateTransform" />
                                </Grid.RenderTransform>
                            </Grid>
                            <Thumb
                                x:Name="SwitchThumb"
                                Grid.RowSpan="3"
                                Grid.ColumnSpan="3"
                                AutomationProperties.AccessibilityView="Raw">
                                <Thumb.Template>
                                    <ControlTemplate TargetType="Thumb">
                                        <Rectangle Fill="Transparent" />
                                    </ControlTemplate>
                                </Thumb.Template>
                            </Thumb>

                        </Grid>

                    </Grid>

                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="DefaultThemeToggleSwitchStyle" BasedOn="{StaticResource DefaultToggleSwitchStyle}" TargetType="ToggleSwitch" />

    <Style BasedOn="{StaticResource DefaultToggleSwitchStyle}" TargetType="ToggleSwitch" />




    <!--  SLIDER  -->

    <Style x:Key="DefaultThemeSliderStyle" BasedOn="{StaticResource DefaultSliderStyle}" TargetType="Slider">
        <Setter Property="h:FluentAnimation.PointerOver" Value="HorizontalThumb" />
    </Style>




</ResourceDictionary>
