<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">

    <Style TargetType="TextBox">
        <Setter Property="KeyboardNavigation.TabNavigation" Value="None" />
        <Setter Property="FocusVisualStyle" Value="{x:Null}" />
        <Setter Property="Foreground" Value="{DynamicResource TextBrush}" />
        <Setter Property="Background" Value="{DynamicResource ControlBackgroundBrush}" />
        <Setter Property="SnapsToDevicePixels" Value="True" />
        <Setter Property="Padding" Value="12,5,12,5" />
        <Setter Property="HorizontalContentAlignment" Value="Left" />
        <Setter Property="VerticalContentAlignment" Value="Center" />
        <Setter Property="FontSize" Value="{DynamicResource FontSize}" />
        <Setter Property="FontFamily" Value="{DynamicResource FontTitilliumWeb}" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="TextBox">                    
                    <Grid Background="{TemplateBinding Background}">  
                        <ScrollViewer x:Name="PART_ContentHost"
                                      VerticalScrollBarVisibility="{TemplateBinding VerticalScrollBarVisibility}"
                                      HorizontalScrollBarVisibility="{TemplateBinding HorizontalScrollBarVisibility}"/>

                        <Border x:Name="BorderStandard"
                                BorderBrush="{DynamicResource SelectionLightBrush}"
                                BorderThickness="2" Margin="-2" />

                        <Border x:Name="BorderFocus" Margin="-3" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
                                BorderBrush="{DynamicResource SelectionBrush}"
                                BorderThickness="3" Visibility="Hidden" />
                    </Grid>
                    <ControlTemplate.Triggers>
                        <Trigger Property="IsEnabled" Value="False">
                            <Setter Property="Opacity" Value="0.5" />
                        </Trigger>
                        <Trigger Property="IsFocused" Value="True">
                            <Setter Property="Background" Value="{DynamicResource ControlBackgroundDarkBrush}" />                            
                            <Setter Property="Visibility" Value="Visible" TargetName="BorderFocus" />
                            <Setter Property="Visibility" Value="Hidden" TargetName="BorderStandard" />
                        </Trigger>
                        <Trigger Property="IsMouseOver" Value="True">
                            <Setter Property="Background" Value="{DynamicResource ControlBackgroundDarkBrush}" />
                            <Setter Property="Visibility" Value="Visible" TargetName="BorderFocus" />
                            <Setter Property="Visibility" Value="Hidden" TargetName="BorderStandard" />
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
</ResourceDictionary>